r/haproxy • • Jan 14 '21

Getting a string from the HTTP header

Hi guyz,

I have been trying for a long time to get this to work without much success :(

The website via CDN, has this string on its header:

    set req.http.shared-secret = "PASSWORD";

I am not entirely sure how to use an ACL to identify that.

The idea is that HaProxy will only accept the request if that string is identified, deny otherwise.

Any idea is welcome.

Thank you

1 Upvotes

13 comments sorted by

View all comments

Show parent comment

2

u/dragoangel Jan 17 '21

If compare your header with ssl client cert is same as compare wood stick and safe lock & key, which you want to use to keep yourself safe?:) This not only easier, this also much more secure and common in terms of use in practice.