I have a firewall that is the SSL terminator and sets the remote_user header. This header should be passed onto an application, however we have an nginx proxy sitting in the middle.
Browser over SSL -> Firewall proxy -> Nginx proxy -> App
I cannot for the life of me figure out how to pass the remote_user header to the App from the Firewall. Nginx seems to swallow it. $remote_user doesn't have it (which makes sense). $http_remote_user doesn't have it (which doesn't make sense). I tried to find it in $proxy_add_* but couldn't.
How do I proxy pass the remote_user header when the SSL terminator isn't nginx?
EDIT1: Other things I have tried:
proxy_pass_request_headers on;
proxy_pass_header remote_user;
proxy_set_header other_user $http_remote_user;
proxy_pass http://scooterlabs.com/echo;