1

I have a Stack Exchange OpenID identity, but I want to add one more because it's very uncomfortable for me to use that one. I go to my account, click My Logins, then Add More Logins..., then go to manually enter my OpenID. I have tried with several combinations, and this is what happened. Note that casa.formauri.es is my home and www.formauri.es is a host in a paid hosting. Port 80 is blocked for my home; the HTTP port is 9980.

  • If I enter http://casa.formauri.es:9980/pgimeno/openid.php then nothing at all shows up in the Apache logs, and the response I get is that no OpenID server is found. I suspect the port is being ignored.

  • If I enter https://www.formauri.es/personal/pgimeno/openid.php then something similar shows up, but quicker. I suspect that's because the certificate is self-signed (I can't have one from a trusted authority).

  • Updated - see edit 3 below

    If I enter http://www.formauri.es/personal/pgimeno/openid.php then I am redirected to a page apparently contacted in HTTP mode through port 443, because the URL looks like this: http://www.formauri.es:443/personal/pgimeno/openid.php?openid.identity=blahblahblah

    Note the HTTP protocol but port 443. If I then edit the URL to remove the 443, I get a similar page like this: http://www.formauri.es:443/personal/pgimeno/openid.php?openid.mode=accept and if I remove the 443 again, I get the referrer confirmation page of my OpenID. If I accept it, I get the password prompt (it's HTTP Basic Auth to avoid being sent in plaintext) then it happens again: http://www.formauri.es:443/personal/pgimeno/openid.php?openid.mode=accept&accepted=yes

    After three more removals of the port I finally get the response from the StackExchange server:

    Unable to log in with your OpenID provider:

    Error occurred while sending a direct message or getting the response.

  • If I enter http://www.formauri.es:80/personal/pgimeno/openid.php the result is the same as above.

  • (As per Edit2) If I enter http://casa.formauri.es:443/pgimeno/openid.php after enabling that port for non-SSL mode in my home then it succeeds, but that's not a sensible option.

That exhausts my options. It would seem that the server is sending the request through port 443 even when the protocol is HTTP, and also that it's ignoring the port parameter that I specify. Feel free to use the given URLs for any tests (there's no registration though so you won't be able to get past the password prompt).

Edit1: Another site (qt-project.org) has the very same problem, so it looks like a problem in the upstream underlying library, whatever it is. OpenStreetMap, Wordpress, LiveJournal and others accept my home ID without problems. Maybe it has an option to force HTTPS and it is on and it works by merely forcing port 443? If so it won't let me use Stack Exchange whatsoever. End Edit1.

Edit2: I found a provisional workaround by enabling port 443 on my home (casa.formauri.es) without enabling SSL. Using http://casa.formauri.es:443/pgimeno/openid.php succeeded in this case. But it was a test and (1) I don't want to have that port open and (2) it's really bad practice to use the HTTPS port for anything else than HTTPS.

I also see that the tag "multiple-accounts" was added. However this problem is related only to openid, and has nothing to do with having multiple accounts. It would have happened also if I tried to register for the first time using openid in the first place. End Edit2.

Edit 3: It turns out that I was bitten by https://issues.apache.org/bugzilla/show_bug.cgi?id=45833 which resulted in PHP being lied by Apache about the port number ($_SERVER['SERVER_PORT'] was 443 even when connecting through port 80). I apologize.

The problem remains that I can't connect to my preferred server (my home) through port 9980, but now at least I can login easily and without hacks. End Edit3.

0

It turns out that I was bitten by https://issues.apache.org/bugzilla/show_bug.cgi?id=45833 which resulted in PHP being lied by Apache about the port number ($_SERVER['SERVER_PORT'] was 443 even when connecting through port 80).

Setting UseCanonicalPhysicalPort to ON in Apache solved the problem in the remote hosting.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .