I would like to deny all the traffic on haProxy, unless path is:
- /
- /somepath
- /someorherpath
Currently I have these rules:
acl allowed_pages path_beg /
acl allowed_pages path_beg /somepath
acl allowed_pages path_beg /someotherpath
http-request allow if allowed_pages
# if not allowed path/network, deny
http-request deny
But is not working as the / (root) rule allows for example /somethingthatisnotallower for example.
What am I missing here?
Edit: I have tried like this:
http request deny if !allowed_pages
But Im stil able to access /notwantedpath for example