I have a certificate and private key files which are created by my colleague. There are placed in Apache /etc/apache/ssl
directory and all the configurations set properly.
I opened the site with https://
and got "certificate not trusted" error and also "url not matching", so I added it to Trusted Root Certificate Authorities.
But it didn't fix the error, issue still persist. When I looked into the certificate details, I can see "issued to" and "issued by" are having different values.
Try 1:
I have created my own certificate and private key files with the below command and reloaded Apache configurations.
sudo openssl req -x509 -nodes -days 365 -newkey rsa:2048 -keyout /etc/apache2/ssl/apache.key -out /etc/apache2/ssl/apache.crt
This certificate having "issued by" and "issued to" as same values. After this again I opened the site with https://
and got "certificate not trusted" error, this time without "url not matching" error. I added this certificate to Trusted Root Certificate Authorities and I am able to see green status and site is encrypted.
Why am not able to make it work with the existing certificate?