Listener IP via nginx proxy

Read 3344 times
After issues with getting built in reverse proxy going I am now using nginx for reverse HTTPS proxy for stream.

The issue with this is listener IP is shown as proxy IP, is there any way of geting centova to accept the X-Real-IP header as listener IP?
After issues with getting built in reverse proxy going I am now using nginx for reverse HTTPS proxy for stream.

The issue with this is listener IP is shown as proxy IP, is there any way of geting centova to accept the X-Real-IP header as listener IP?

Hello deck8,

This is a known drawback of using vanilla Nginx as a reverse proxy, since it doesn't know how to pass along the listener's information to Shoutcast and Icecast.

You can fix this by using Centova Cast's own stream proxy instead, which has been modified to pass along said information, thus avoiding this very issue.

If you need help setting up Centova Cast's own stream proxy, just open a ticket to the support department, and our staff will be happy to assist.

Regards.
You can see how Centova achieve their nginx proxy via this config file: etc/web.d/include.d/cc-proxy.conf

It appears the user agent header is modified to contain the origin ip address:
proxy_set_header                User-Agent "$http_user_agent [ip:$remote_addr]";

I would expect this is then picked up and used by the Centova Cast control panel for use in things like the reports etc...

In my experience all connections via stream proxies still appear as the proxy server IP (rather than the listeners IP) to the actual Icecast / Shoutcast server. The problem with this is that you can't then block rouge listeners who come in via the proxy. This is even more of an issue because you can't disable / enable the proxy on a per account basis, only on the whole server.