Hi, I'm getting the same error, on an Amazon Linux 2023.
Tried the test below: certbot certonly --standalone --dry-run --debug-challenges -v -d (domain)
and pulsed at "Press Enter to Continue".
But the http://mydomain got me to a This site cannot be reached error.
Tried to start my web application using a self-signed cert, and it started fine on port 80 and 443. I guess port 80 and 443 should be opened up for certbot. Any other reason why I'm getting the error?
Hint: The Certificate Authority failed to download the challenge files from the temporary standalone webserver started by Certbot on port 80. Ensure that the listed domains point to this machine and that it can accept inbound connections from the internet.
For --standalone only HTTP and port 80 are involved. And, technically, not for Certbot. Certbot, as the ACME Client, makes the cert request to Let's Encrypt, the ACME Server. It is the LE Server that sends an HTTP request to your domain to prove you control it. It is this request that is failing and for which port 80 needs to be open.
While Certbot is running and paused can you open another session into that EC2 and show output of this?
sudo ss -pant | grep -i listen | grep ':80'
If ss is not available try same command but with netstat
By the way, I have two EC2 instances in the same network with the same inbound rules. The cert got successfully installed and renewed on another EC2 instance, but right now failing on this one.
Yes. certbot --standalone is still running (not pressed enter yet). I have the same security settings on both EC2 instances. What else should I look at?
I don't see any block on port 80. Plus, I was able to install/renew the cert on isam-dev.astrion.us successfully, which is on the same VPC. Anything else I can look into?
You said you had your webapp running on port 80 earlier. Were you able to connect to it using HTTP on port 80 from some device on the public internet?
You could stop Certbot and instead run your own app on port 80. Then if you can't connect to it from the public internet you know it's your networking problem. I am already convinced of that but it might help to be using your own app as you seek advice from networking specialists.
We are not a general purpose help site for networking problems. We often point out common reasons for those and educate about tools to help debug. We have already strayed well beyond that
Can confirm port 80 is not responding but that may be because nothing is listening on port 80. Start a temporary web server and try connecting to it from an external network. Could also be a firewall on the host.
Once you get basic port 80 http working externally your HTTP domain validation will likely start working.
Just tried the certbot dryrun on isam-dev.astrion.us, which is on the same VPC. certbot certonly --standalone --dry-run --debug-challenges -v -d isam-dev.astrion.us
And got it thru successfully. So looks like the inbound rules are correct, and the issue is in this EC2 instance only. Did you mean the network issue only happens to this instance?
mentioned:
URL:
http://isam-dev.astrion.us/.well-known/acme-challenge/vZQMLL5FvLXUXGXMIOdCmIR9R-7ynmjsqxfcORJ9B4Y
Expected value:
vZQMLL5FvLXUXGXMIOdCmIR9R-7ynmjsqxfcORJ9B4Y.HqP0TZifuxRHrKf6szMg47cBLwzG4QlUvUnG4gRwSN8
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
Press Enter to Continue
Waiting for verification...
Cleaning up challenges
The dry run was successful.```
It went through fine even though I was getting the same site can't be reached page while trying the http://isam-dev.astrion.us/.well-known/acme-challenge/vZQMLL5FvLXUXGXMIOdCmIR9R-7ynmjsqxfcORJ9B4Y before pressing the enter on isam-dev.astrion.us.