Messy Let'sEncrypt SSL install. Https automatically loads for domain name but not for internal links


#1

Did a Wordpress one-click-install on Digital Ocean droplet and migrated my database. After everything was setup I tried installing Let’s encrypt SSL and faced few interruptions like console freezing up, python-certbot-apache not found, multiple v-host issue etc. I managed to install the SSL for both domain.com and www.domain.com and the SSL labs test for both verify that the SSL certificates are working. When I enter domain.com and press enter, it automatically changes to https://www.domain.com, all good. Certbot renewal dry run works fine too.

Now here is the problem, all the internal links on the website pointing to www.domain.com still stay http and wont automatically change to https. I can force https through wordpress plugins but I am not sure if this is the right way. Neither do I know if the SSL certificate for www.domain.com has been installed correctly. How do i fix this?

This is my default.conf file if needed

<VirtualHost *:80>
        ServerAdmin webmaster@localhost
        DocumentRoot /var/www/html

        <Directory /var/www/html/>
            Options FollowSymLinks
            AllowOverride All
            Require all granted
        </Directory>

        ErrorLog ${APACHE_LOG_DIR}/error.log
        CustomLog ${APACHE_LOG_DIR}/access.log combined
RewriteEngine on
RewriteCond %{SERVER_NAME} =domain.com
RewriteRule ^ https://%{SERVER_NAME}%{REQUEST_URI} [END,NE,R=permanent]
</VirtualHost>

And this is my 000-default-le-ssl.conf file. I selected this for www.domain.com when prompted to choose between two v-hosts

IfModule mod_ssl.c>
<VirtualHost *:443>
    ServerAdmin webmaster@localhost
    DocumentRoot /var/www/html

    <Directory /var/www/html/>
        Options FollowSymLinks
        AllowOverride All
        Require all granted
    </Directory>

    ErrorLog ${APACHE_LOG_DIR}/error.log
    CustomLog ${APACHE_LOG_DIR}/access.log combined
ServerName domain.com
Include /etc/letsencrypt/options-ssl-apache.conf
ServerAlias www.domain.com
SSLCertificateFile /etc/letsencrypt/live/domain.com/fullchain.pem
SSLCertificateKeyFile /etc/letsencrypt/live/domain.com/privkey.pem
</VirtualHost>
</IfModule>

#2

Hi @SSLbaby

this is not a problem of your certificate. And it’s not a problem of your webserver configuration.

You have to change the links in your wordpress database or configuration.

PS: What’s your domain name?


#3

My domain name is cutebabyblog.com

Could you please check it and see it if I have installed the SSL incorrectly?


#4

Your website looks good. The Letsencrypt-certificate is created yesterday - Mittwoch, 29. August 2018, 13:20:21.

No mixed content warnings. You can use (FireFox or Chrome) Ctrl + Shift + I to open the console. There are http links are shown. But I see no warnings.


#5

Thank you so much. I’m relieved to hear that. I appreciate your help.

One last thing though, for example, on this page https://www.cutebabyblog.com/cute-baby-images/ search for the term ‘baby boys pictures’ and click on it. It makes the site go from https to http. Is this not a sign of wrong implementation of SSL certificate?


#6

I came to

https://www.cutebabyblog.com/?s=baby+boys+pictures

There is all https and no mixed content warnings.

If you see http, then this isn’t a problem of your ssl certificate. It’s a problem of your website / Content Management System orelse, what you use.

If someone changes his website from http to https, there are sometimes a lot of things to change. But the correct installed certificate is only one / the first step.


#7

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.