darkassassin07 434 Posted July 14, 2018 Share Posted July 14, 2018 While working with @@pir8radio to solve my reverse proxy woes, He discovered that a couple of my users didn't have passwords... After checking through all my users everyone had a password set, so I reset the users that were not asking for a password and it still wasn't working correctly... It took some messing around, but I found the culprit. If you enable in-network sign in with my easy pin code and do not set a pin code, your password is no longer required no matter how you are accessing emby instead of no password on LAN and password on WAN as I would have thought. The reason this had been setup was so that these users would not require a password while at home, but they would still be protected externally. This has been setup as-is for months now, I had no idea these users were unprotected as they are never really used from wan... Link to comment Share on other sites More sharing options...
Luke 37250 Posted July 14, 2018 Share Posted July 14, 2018 If you enable in-network sign in with my easy pin code and do not set a pin code, your password is no longer required no matter how you are accessing emby instead of no password on LAN and password on WAN as I would have thought. this isn't true. It's because your proxy is configured in a way that emby can't tell the difference between a lan and a wan request. your options would be either to resolve that (preferable), or just not use this feature. Link to comment Share on other sites More sharing options...
darkassassin07 434 Posted July 14, 2018 Author Share Posted July 14, 2018 (edited) I am passing these headers to emby with each request: proxy_set_header HOST $host; proxy_set_header X-Real-IP $remote_addr; proxy_set_header Range $http_range; proxy_set_header If-Range $http_if_range; proxy_set_header X-Forwarded-Proto $scheme; proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; proxy_http_version 1.1;Emby just seems to be ignoring them. (Specifically 'X-Real-IP') This is all im supposed to be doing to pass that info to emby right? Edited July 14, 2018 by darkassassin07 Link to comment Share on other sites More sharing options...
Luke 37250 Posted July 14, 2018 Share Posted July 14, 2018 check x-forwarded-for. Link to comment Share on other sites More sharing options...
darkassassin07 434 Posted July 15, 2018 Author Share Posted July 15, 2018 If I change that line to read: proxy_set_header X-Forwarded-For $remote_addr; I still get the same results. Im not really sure what you mean Link to comment Share on other sites More sharing options...
Luke 37250 Posted July 15, 2018 Share Posted July 15, 2018 @@pir8radio may be able to share his config. Link to comment Share on other sites More sharing options...
pir8radio 1293 Posted July 15, 2018 Share Posted July 15, 2018 If I change that line to read: proxy_set_header X-Forwarded-For $remote_addr; I still get the same results. Im not really sure what you mean @@pir8radio may be able to share his config. Your initial setup was correct, proxy_set_header X-Real-IP $remote_addr; proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; Some things to check: If nginx is on the same PC as your emby server I would make sure your nginx is sending to http://127.0.0.1 Maybe set your "Lan Networks" Ip's in emby too. Make sure you don't have caching setup or setup incorrectly in nginx, I've seen instances where nginx would cache the login info on some application servers. In your emby dashboard and under activity, the remote user logins should show a remote IP address listed for each, not your router, or nginx IP. Make sure your nginx logs AND emby logs are showing external IP's for the external users. 1 Link to comment Share on other sites More sharing options...
darkassassin07 434 Posted July 15, 2018 Author Share Posted July 15, 2018 - The nginx server is on a separate machine on the same subnet. - I dont have caching setup - remote user logins show as the ip of the nxinx machine not the real external ip. - nginx log shows the real ip, emby log shows nginx ip Link to comment Share on other sites More sharing options...
pir8radio 1293 Posted July 15, 2018 Share Posted July 15, 2018 - The nginx server is on a separate machine on the same subnet. - I dont have caching setup - remote user logins show as the ip of the nxinx machine not the real external ip. - nginx log shows the real ip, emby log shows nginx ip Hum... what thread did you post your config in again? can you link to it or repost your nginx config? You should see the external IP's what OS is each running on, nginx and emby? 1 Link to comment Share on other sites More sharing options...
darkassassin07 434 Posted July 15, 2018 Author Share Posted July 15, 2018 Config is here: https://emby.media/community/index.php?/topic/60678-odd-get-requests/page-1 NGINX is running on a raspberry pi 3b, raspbian os Emby is on a win7 pro machine Link to comment Share on other sites More sharing options...
Solution pir8radio 1293 Posted July 15, 2018 Solution Share Posted July 15, 2018 (edited) Config is here: https://emby.media/community/index.php?/topic/60678-odd-get-requests/page-1 NGINX is running on a raspberry pi 3b, raspbian os Emby is on a win7 pro machine Try moving your "set header" settings into the /emby/ location block, what happens? proxy_set_header HOST $host; proxy_set_header X-Real-IP $remote_addr; proxy_set_header Range $http_range; proxy_set_header If-Range $http_if_range; proxy_set_header X-Forwarded-Proto $scheme; proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; Edited July 15, 2018 by pir8radio 2 Link to comment Share on other sites More sharing options...
darkassassin07 434 Posted July 15, 2018 Author Share Posted July 15, 2018 (edited) I had a couple min while at work so I added the X-Forwarded-For to /emby/ and the external IP is now showing up in emby.Problem solved.Thanks for taking the time to help me with these issues guys /edit This is what I missed :/ I didn't realize I had to re-define all my 'proxy_set_header's if I wanted to add/change one. proxy_set_header "These directives are inherited from the previous level if and only if there are no proxy_set_header directives defined on the current level" Edited July 15, 2018 by darkassassin07 Link to comment Share on other sites More sharing options...
pir8radio 1293 Posted July 16, 2018 Share Posted July 16, 2018 (edited) I had a couple min while at work so I added the X-Forwarded-For to /emby/ and the external IP is now showing up in emby. Problem solved. Thanks for taking the time to help me with these issues guys /edit This is what I missed :/ I didn't realize I had to re-define all my 'proxy_set_header's if I wanted to add/change one. proxy_set_header "These directives are inherited from the previous level if and only if there are no proxy_set_header directives defined on the current level" NP, I can't even get an "answered" or a thumbs up, no love i tell ya'' Jk. EDIT: lol i really was just kidding... glad its working for you now. Edited July 16, 2018 by pir8radio 1 Link to comment Share on other sites More sharing options...
darkassassin07 434 Posted July 16, 2018 Author Share Posted July 16, 2018 Have allll the thumbs lol 1 Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now