My configuration is correct the error i am facing is unauthorized

Here is my site conf file:

VirtualHost *:80>
    ServerName bfganalytics.com
    ServerAlias www.bfganalytics.com
    DocumentRoot /var/www/html/bfg-outfitters/public

    <Directory "/var/www/html/bfg-outfitters/public">
        AllowOverride All
        Options FollowSymLinks
        Require all granted
    </Directory>


    ErrorLog ${APACHE_LOG_DIR}/bfganalytics-error.log
    CustomLog ${APACHE_LOG_DIR}/bfganalytics-access.log combined
</VirtualHost>

This is the issue I am facing:
root@srv616167:/etc/apache2/sites-available# sudo certbot --apache -d bfganalytics.com -d www.bfganalytics.com
Saving debug log to /var/log/letsencrypt/letsencrypt.log
Requesting a certificate for bfganalytics.com and www.bfganalytics.com

Certbot failed to authenticate some domains (authenticator: apache). The Certificate Authority reported these problems:
Domain: bfganalytics.com
Type: unauthorized
Detail: 145.223.120.72: Invalid response from http://bfganalytics.com/.well-known/acme-challenge/zgka9ayhtZejB4WuNVOzrWZ3oObcUJtxALRI-keVybo: 400

Domain: www.bfganalytics.com
Type: unauthorized
Detail: 145.223.120.72: Invalid response from http://www.bfganalytics.com/.well-known/acme-challenge/NOIuwWkEl2qyN90zMnhUFPUxJPKySno2VKzTBSnx_O0: 400

Hint: The Certificate Authority failed to verify the temporary Apache configuration changes made by Certbot. Ensure that the listed domains point to this Apache server and that it is accessible from the internet.

Some challenges have failed.
Ask for help or search for solutions at https://community.letsencrypt.org. See the logfile /var/log/letsencrypt/letsencrypt.log or re-run Certbot with -v for more details.

Hi @faheem-tecspine, and welcome to the LE community forum :slight_smile:

Please show:
sudo apachectl -t -D DUMP_VHOSTS

1 Like

Your server is using fresh certificates you got about 2.5H hours ago.

Do you still need help?

2 Likes

I suppose they realized that "sites-available" and "sites-enabled" aren't always one and the same.

2 Likes

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