Reverse-proxy and x-forwarded-for

Are you having trouble getting Virtual Radar Server installed and running? If so then this is the place to ask about it.
Post Reply
magic51
Posts: 4
Joined: Wed Jun 06, 2018 2:57 pm

Reverse-proxy and x-forwarded-for

Post by magic51 »

Hi!

I have a HAproxy in front of a VRS-server (2.4.4 Windows). Working great, but an issue with the source-ip for the users, which shows as the ha-proxy IP instead of the users real IP. The HAproxy is on a different VLAN/subnet than the VRS-server (both on private IP:s) but is adding X-Forwarded-For headers.

In this post its mentioned https://forum.virtualradarserver.co.uk/ ... 6884#p6884
However, I did have a look at the rules for determining the client's IP address when the request comes through a proxy - basically it's taken from the X-Forwarded-For header, but only if the proxy is on the LAN. If the request originates from a public internet address then X-Forward-For headers are ignored.
Its not quite clear in the response above, does the reverse-proxy has to be on a private IP or on the same subnet as the VRS-server? Is this still applicable on 2.4.4? Not sure which version was at the time of the comment in 2017.

Just so i know where to troubleshoot!

Thanks!
Post Reply