How to add x-forward-for client IP to HTTP header in VyOS?

Hi everyone,

I want preserves the IP address of the user who requested the web page. How to configure this in VyOS? Or anyone here even tried this in VyOS? Thanks

How does your config looks without this option? Your requirement is not clear. There should be some web service or proxy.

I have webproxy setup in VyOS listening to router’s IP 192.168.1.17. My web server’s IP address is 192.168.1.66. I have IPoE clients with IP address 10.10.1.X/24. I want to know the IPoE client IP address (10.10.1.x/24) when they are accessing the web server.

set firewall group address-group allowip
set firewall group address-group denyip
set firewall ipv4 forward filter default-action ‘accept’
set firewall ipv4 forward filter rule 9 action ‘accept’
set firewall ipv4 forward filter rule 9 destination address ‘192.168.1.0/24’
set firewall ipv4 forward filter rule 9 source group address-group ‘denyip’
set firewall ipv4 forward filter rule 10 action ‘accept’
set firewall ipv4 forward filter rule 10 outbound-interface interface-name ‘eth0’
set firewall ipv4 forward filter rule 10 source group address-group ‘allowip’
set firewall ipv4 forward filter rule 11 action ‘drop’
set firewall ipv4 forward filter rule 11 source group address-group ‘denyip’
set interfaces ethernet eth0 address ‘dhcp’
set interfaces loopback lo
set nat destination rule 99 destination port ‘80’
set nat destination rule 99 protocol ‘tcp’
set nat destination rule 99 source group address-group ‘denyip’
set nat destination rule 99 translation address ‘192.168.1.66’
set nat destination rule 99 translation port ‘80’
set nat source rule 100 outbound-interface ‘eth0’
set nat source rule 100 source address ‘10.10.1.0/24’
set nat source rule 100 translation address ‘masquerade’
set service dns forwarding allow-from ‘10.10.1.0/24’
set service dns forwarding cache-size ‘0’
set service dns forwarding listen-address ‘10.10.1.1’
set service webproxy listen-address 192.168.1.17

It is hardcoded in the code
Add please a feature request to get it configurable https://vyos.dev/
Expected option for configuration

forwarded_for on