0

I used certbot to call cloudflare's api and installed let's encrypt's SSL certificate for my website. my vps install centos7 and apache ,my website is wordpress I use cloudflare's strict(full) mode, my website can be opened, but there is no lock pattern in front of the domain name, and it shows "not secure" I wrote these in the apache file /etc/httpd/conf/httpd.conf:

<VirtualHost *:443>
ServerAdmin admin@mydomain.com
DocumentRoot /var/www/html
ServerName www.mydomain.com
ServerAlias mydomain.com
ErrorLog /var/log/httpd/mydomain.com-error.log
CustomLog /var/log/httpd/mydomain.com-acces.log common
SSLProtocol all -SSLv2 -SSLv3
SSLCipherSuite HIGH:!RC4:!MD5:!aNULL:!eNULL:!NULL:!DH:!EDH:!EXP:+MEDIUM

SSLEngine on
    SSLCertificateFile /etc/letsencrypt/live/mydomain.com/cert.pem
    SSLCertificateKeyFile /etc/letsencrypt/live/mydomain.com/privkey.pem
    SSLCertificateChainFile /etc/letsencrypt/live/mydomain.com/fullchain.pem
</VirtualHost>

but nothing changed what should I do now?

Ou Lee
  • 31
  • 1
  • Does the SSL certificate work when you type `https://` before the domain? – Obvious_Grapefruit Sep 03 '22 at 03:04
  • So you need to force SSL by redirecting `http://` to `https://`. – Obvious_Grapefruit Sep 03 '22 at 03:13
  • I opened port 80 at the same time. Can both ports 80 and 443 be open at the same time? I write 80 port like this: ` DocumentRoot /var/www/html ServerName www.mydomain.com ServerAlias mydomain.com ErrorLog /var/log/httpd/mydomain.com-error.log CustomLog /var/log/httpd/mydomain.com-acces.log common ` – Ou Lee Sep 03 '22 at 03:16
  • is the 443 port I write on my post is all right? @ Obvious_Grapefruit – Ou Lee Sep 03 '22 at 03:18
  • Please refer to this answer and see if it helps: https://stackoverflow.com/a/4923331/9240389 – Obvious_Grapefruit Sep 03 '22 at 03:21
  • I install mod_ssl with this `yum -y install mod_ssl` and it success but I can not find this `LoadModule ssl_module modules/mod_ssl.so` on the file `/etc/httpd/conf/httpd.conf` – Ou Lee Sep 03 '22 at 03:21
  • I see that answer and I add `Redirect / https://examole.com/` and it works ! thankyou very much – Ou Lee Sep 03 '22 at 03:42

0 Answers0