Quantcast
Channel: HAProxy community - Latest topics
Viewing all articles
Browse latest Browse all 4849

Haproxy acl on ip range with ip from header instead of src

$
0
0

Howdy Folks,

I understand that it is possible to create an acl for IP ranges based on src like:
acl white_list src 192.168.1.0/24 192.168.10.0/24
But is it possible to do the same if the IP is based on an http header? I tried something like:
acl white_list req.hdr(X-Actual-IP) 192.168.1.0/24 192.168.10.0/24
and it doesn’t work, I’m assuming it’s doing a string match which isn’t what I want. Is there a way to treat the value of a request header as an IP in an acl?

Cheers,
Kelvin

1 post - 1 participant

Read full topic


Viewing all articles
Browse latest Browse all 4849

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>