Can't access files with dot operator in server to do acme test

I'm getting the following error.

I'm using

and it cannot access files in folders with a dot in front which is needed for the webroot challenge.

Is there another way around this that doesn't require accessing files with dot's in front of them? I also raised an issue with the developer of that c++ library here:

Please fill out the fields below so we can help you better. Note: you must provide your domain name to get help. Domain names for issued certificates are all made public in Certificate Transparency logs (e.g. crt.sh | example.com), so withholding your domain name here does not increase secrecy, but only makes it harder for us to provide help.

My domain is: infinitysheriff.com

I ran this command:

reset; sudo certbot certonly --webroot --webroot-path /root/web/www -d infinitysheriff.com -d www.infinitysheriff.com

It produced this output:

Saving debug log to /var/log/letsencrypt/letsencrypt.log


You have an existing certificate that contains a portion of the domains you
requested (ref: /etc/letsencrypt/renewal/infinitysheriff.com.conf)

It contains these names: infinitysheriff.com

You requested these names for the new certificate: infinitysheriff.com,
www.infinitysheriff.com.

Do you want to expand and replace this existing certificate with the new
certificate?


(E)xpand/(C)ancel: E
Renewing an existing certificate for infinitysheriff.com and www.infinitysheriff.com

Certbot failed to authenticate some domains (authenticator: webroot). The Certificate Authority reported these problems:
Domain: www.infinitysheriff.com
Type: unauthorized
Detail: 66.96.162.131: Invalid response from http://www.infinitysheriff.com/.well-known/acme-challenge/gq0gOyimsELbdJMJdvnyi0sx-CfsBOmysKqKcYEeUJg: 404

Hint: The Certificate Authority failed to download the temporary challenge files created by Certbot. Ensure that the listed domains serve their content from the provided --webroot-path/-w and that files created there can be downloaded 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.

My web server is (include version):

cpp-httplib

The operating system my web server runs on is (include version):

Ubuntu 22.04

My hosting provider, if applicable, is:

I can login to a root shell on my machine (yes or no, or I don't know): yes

I'm using a control panel to manage my site (no, or provide the name and version of the control panel): no

The version of my client is (e.g. output of certbot --version or certbot-auto --version if you're using Certbot):

certbot 1.31.0

1 Like

There are two other options:

  • The TLS-ALPN challenge, with also works with your webserver, but via HTTPS rather than HTTP. It doesn't use a challenge file like the HTTP challenge does, so it might work.
  • The DNS challenge, which doesn't use your webserver at all--it (effectively) requires that you be able to make automated updates to your DNS records, so that a challenge token can be added as a TXT record and then removed once the challenge succeeds. This token is dynamic, so you can't just leave the same token in place for renewals.
4 Likes

As @danb35 point out there are 3 Challenge Types HTTP-01, DNS-01, and TLS-ALPN-01 in use today.
You can find more information on Challenge Types here Challenge Types - Let's Encrypt listing Pros and Cons of each type.

2 Likes

How did you get the current certificate with the single name?

3 Likes

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