myPlex User Login for different ATVs

There is no 'auto detection' in the plexconnect installer for synology, exactly for this reason, the user has to enter the 'real' ip of the NAS.

I'm assuming he is using one of the more recent installers :-)

Yeah actually I tried the latest installer (0.3-6) provided in the forum and followed all the instructions (multiple times so far  :rolleyes: ).

I don't think it has to do with the link aggregation, since the switch is managing the trunking and the applications can access the ip without knowing anything about the trunking. The installation runs at a remote location, so unfortunately I cannot test it right now without trunking. But the idea about the web server sounds interesting. I changed the port of the plexconnect web server because of the used port 80 of the Synology web server, which I couldn't change on the DSM 5.0 software anymore. But the plexconnect on the latest ATV software uses the ssl port 443 anyway right? So who is forwarding my request...?

Tribune - PlexConnect uses both, 443 (for first contact) and 80 later on.

bwynants - I am not looking for the PlexConnect internal IP auto detection. I am okay with fixed settings there.

The trouble is the IP of the aTVs... in the logs you will find (shorted...):

X-Forwarded-For: 192.168.179.49

PlexConnectUDID=C0HM122EFF54

'aTVAddress': '192.168.179.3'

X-Forwarded-For: 192.168.179.47

PlexConnectUDID=C0HM18NCFF54

'aTVAddress': '192.168.179.3'

-> two different aTVs accessing PlexConnect. Unfortunately we can not add the UDID to all iOS http requests - we rely on an unique aTVAddress (usually the real IP) to map the correct aTV/UDID.

This normally works great - except when you are trying to access PlexConnect from the far-far Internet using your router's public IP, as the aTV hides behind that public IP in that case.

Now we seem to see the same issue with Synology... my understanding is, it does some IP/port forwarding, changing the "sender IP" on the fly, but (luckily for us...) adding the "X-Forwarded-For" to the header.

Do you see those "X-Forwarded-For" tags as well? Is that kind of standard - then we could check for their existence and prefer that over the incoming IP...

Edit: http://en.wikipedia.org/wiki/X-Forwarded-For

Tribune88: I just committed a fix. Please give it a try... got an early OK from bwynants already. :-D

synology installer is updated to plexconnect_noarch_0.3-7.spk

Oh nice! Thanks a lot! Unfortunately I just came home from the house with the installation. I can install it remotely, but nobody can check it with an ATV there. I will reply when I am there for the next time and try the new version. 

So you´re involving the X-Forwarded information as well? Otherwise I would have tried to get the synology web server to another port than port 80. 

Having some discussion with minion about his issues identifying external aTVs...

Unfortunately the router didn't seem to add those X-Forwarded tags, used here to help with the NAS forwarding.

But in the http headers there was another line unique: the Cookies.

Cookie: s_vi=[CS]v1|28F5884685012602-60000106A0030AE2[CE]
Cookie: s_vi=[CS]v1|28EECFF585011C1F-4000010C802937A2[CE]
 
I wonder, if we could
- reuse this data to get your two/three aTVs identified?
- save our own cookie on the aTV for later identification?
 
Does anybody have any insights? Any details about cookies on aTV and their usage?
Just asking... :-D

I just committed a bugfix that should help PlexConnect in identifying the requesting aTV. It's not 100%, so it wouldn't help all those issues (especially when having multiple aTVs connected over WAN), but it sure should improve things.

Please give it a try... 

Thanks! I will give you feedback as soon as I can test it at my remote location. 

This topic was automatically closed 90 days after the last reply. New replies are no longer allowed.