## Ensure X-Forwarded-For is set for the auth request.
acl hdr-xff_exists req.hdr(X-Forwarded-For) -m found
http-request set-header X-Forwarded-For %[src] if !hdr-xff_exists
option forwardfor
to my HAProxy-Configuration. But Hassio wont work with option forwardfor. I got “400 Bad request” if i set this option.
I have already tried to do something like
http-request set-header X-Forwarded-For %[src] if !hdr-xff_exists !hassio-host
where hassio-host is a acl hassio-host hdr(host) -i hassio.-example.com or something like http-request del-header but nothing worked.
I want to understand why Hassio has Problems with “option forwardfor”
I have already read HTTP - Home Assistant but maybe not fully understand.
Mhh but where the second “X-Forwarded-For” can come from and how i can debug it? I find a few things with “curl” but i was unable to see X-Forwarded-For-headers there. This header is only between home-assistant and proxy or? How can i see that?
Okay i just changed option forwardfor to option forwardfor if-none
Hassio is working again and (i hope) Authelia is happy to now. But i am rellay wondering where the “second” Forward-For will come from.
“Optional: Add the if-none argument to add the header only when it is not already present:”