Ssl – Apache sending wrong SSL certificate on some connections / browsers

apache-2.2sslssl-certificate

I have a bit of a strange problem and I hope someone can help!

I have just moved servers (both Linux running Apache 2.2) and re-installed everything and pretty much everything is back up and running, however I am getting an error where the SSL certificate is appearing correctly (web browsers are gettign the padlock etc.) in all browsers apart from IE 8 on Windows XP.

It doesn't seem to be that IE8 doesn't trust the cert I have it – seems to be that this browser is seeing the default (self signed) SSLCertificateKeyFile from my ssl.conf rather than the once specified in httpd.conf, and this is causing the security error to show in IE8.

Also from a couple of the web based SSL checkers, when I use exactly the same domain name, one will show my correct GeoTrust cert and another will show the self-signed one!

I changed the DNS well over a week ago so I don't think it is that, plus the cert details given by IE8 for the self-signed cert match the self-signed one on the server.

Any help would be much appreciated as this really has me stumped!

Thanks

Stuart

Best Answer

Do you have any sites still configured to use the self-signed cert? Dig through your virtualhosts, or just rename the self-signed cert's file and then see if apache will successfully restart, or whether it errors out trying to load that certificate.

As @HUB stated, you likely have success serving the correct certificate to clients support TLS SNI, but for clients that don't support it, they get the first certificate that Apache loaded for that port - which is the self-signed certificate.