-1

I have this site that I can access by using http://example.com but, if I change http for https, I get an error that states my connection isn't secure and the legend "NET::ERR_CERT_COMMON_NAME_INVALID" in Chrome. A similar problem happens with other browsers.

I don't know much about servers or SSL certificates so, any insight or suggestion about this will be really appreciated.

  • have you seen http://stackoverflow.com/questions/27294589/creating-self-signed-certificate-for-domain-and-subdomains-neterr-cert-commo ? – wenny May 26 '16 at 05:50

1 Answers1

1

The hostname in the URL must match the subject(s) of the certificate or this error will happen. For example if you have a certificate which is valid only for www.example.com then accessing the site as example.com (without www) will lead to this error.

Which site is accessible by HTTP depends only on DNS and the setup of the web server. For HTTPS the certificate must also match. It can be that your certificate adds more restrictions than the rest of your setup in which case HTTP will work for a specific domain but HTTPS will lead to the error you see.

Steffen Ullrich
  • 114,247
  • 10
  • 131
  • 172