-
Notifications
You must be signed in to change notification settings - Fork 224
[HELP] Show the correct public IP #590
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Comments
@sangandi You can't because in your setup, Zoraxy doesn't aware of your public ip address. What it sees is that
Besides, I have no idea why you would need your public ip (I assume you mean the server public IP instead of the client, as the client IP is already written in the log as 80.187.xxx, which will also get forwarded with |
I'm actually concerned about safety. If there are too many incorrect login attempts, the IP should be blocked for a certain period of time. Only when I use zoraxy is the IP of zoraxy always blocked and not the IP of the original client. Here again what exactly I mean. example.com --> Sophos XGS --> Zoraxy --> Server 37.42.173.221 --> 192.168.1.1 --> 192.168.1.218 --> 192.168.1.200 My server is now blocking zoraxy's IP after too many failed login attempts. This means no one can log in anymore. if I don't use zoraxy example.com --> Sophos XGS --> Server 37.42.173.221 --> 192.168.1.1 --> 192.168.1.200 Then my server blocks the IP addresses of the customer if there are too many failed login attempts. |
@sangandi Ok you mean client public IP address instead of server. You can get the client IP address in your upstream server from the first value of X-Forwarded-For header or X-Real-IP header. If your server are using non standard way to get the client IP, you can use custom header function to overwrite it manually. See more here |
@tobychui Thank you for your quick response. Something like that? Do you have an example for me? |
@sangandi The X-Real-IP, if not provided by downstream, will get automatically fill in by Zoraxy. So you do not need to explicitly set it in custom header. You need to pick a header that your upstream use to identify the client public IP address. Since I don't know what server software you are using, you need to figure it out yourself with some trial and error. |
What happened?
Zoraxy does not forward the public IP to the back servers.
Describe what have you tried
All sorts of things with the X-Header and other settings.
Describe the networking setup you are using
Additional context
When I log in to a service behind zoraxy, the zoraxy IP is always displayed and not the public IP.
My structure is as follows.:
example.com --> Sophos XGS --> Zoraxy --> Server
My public IP is: 123.321.123.321 but in the log of my server always the IP of zoraxy is displayed (192.168.1.218). My Sophos has the: 192.168.1.1.
How do I get the public IP address to display on my server? (in the log)
Here is a log from zoraxy and from my server
The text was updated successfully, but these errors were encountered: