ratsume / lightopenid

Automatically exported from code.google.com/p/lightopenid
0 stars 0 forks source link

Login fails when using non-standard server port #61

Closed GoogleCodeExporter closed 8 years ago

GoogleCodeExporter commented 8 years ago
If you use a non-standard server port, login will fail because the port is 
dropped from the return URL when using default settings.  
LightOpenID::__construct($host) should handle the port number and include it 
when building trustRoot and returnURL if port isn't a standard port number for 
the protocol.

Original issue reported on code.google.com by jason.ma...@gmail.com on 9 Jul 2012 at 5:45

GoogleCodeExporter commented 8 years ago
It does work if you put "example.org:8080" as your hostname.

If you'd want to automatically detect the port number -- I don't know of a sane 
way of doing this. `$_SERVER['SERVER_PORT']` doesn't work, because it returns 
the port number the server listens on, not the port number that was accessed -- 
this isn't the same in all cases (for example, when redirecting ports on a 
firewall).

Original comment by mewp...@gmail.com on 13 Jul 2012 at 6:28