Very puzzling and important problem. Here's the summary:
Using wget, curl, and openssl s_client:
- Server can successfully connect to remote https address
- Remote client can successfully connect to server
- Server cannot connect to itself
For the last entry, I think openssl gives the most informative error:
4321:error:140770FC:SSL routines:SSL23_GET_SERVER_HELLO:unknown protocol:s23_clnt.c:601:
I was running this server on 32-bit arch originally. I reinstalled on a new 64-bit arch platform. Previously there were no SSL problems. I am using a signed cert from comodo...but also tried using a self-signed cert created on the new installation...no luck. Even directly copying the /etc/ssl and /etc/apache2 dirs from my backup and restarting has done nothing.