首页 > 解决方案 > 无法解决letsencrypt错误,原因未知

问题描述

我想使用 Let's encrypt 颁发 SSL / TLS 证书。我更改了 Nginx 设置,安装了 certbot 并尝试运行它。但是,错误的原因尚不清楚,也无法解决。

我使用 Ubuntu、Nginx、Gunicorn。服务器是 DigitalOcean。

这就是我认为的原因。请告诉我是否还有其他原因。

这是我执行的命令。

sudo certbot certonly --webroot -w /var/www/letsencypt/ -d letyu.com

/var/log/letsencrypt/letsencrypt.log

Traceback (most recent call last):
  File "/usr/bin/certbot", line 11, in <module>
    load_entry_point('certbot==0.23.0', 'console_scripts', 'certbot')()
  File "/usr/lib/python3/dist-packages/certbot/main.py", line 1266, in main
    return config.func(config, plugins)
  File "/usr/lib/python3/dist-packages/certbot/main.py", line 1157, in certonly
    lineage = _get_and_save_cert(le_client, config, domains, certname, lineage)
  File "/usr/lib/python3/dist-packages/certbot/main.py", line 118, in _get_and_save_cert
    lineage = le_client.obtain_and_enroll_certificate(domains, certname)
  File "/usr/lib/python3/dist-packages/certbot/client.py", line 350, in obtain_and_enroll_certificate
    cert, chain, key, _ = self.obtain_certificate(domains)
  File "/usr/lib/python3/dist-packages/certbot/client.py", line 294, in obtain_certificate
    orderr = self._get_order_and_authorizations(csr.data, self.config.allow_subset_of_names)
  File "/usr/lib/python3/dist-packages/certbot/client.py", line 330, in _get_order_and_authorizations
    authzr = self.auth_handler.handle_authorizations(orderr, best_effort)
  File "/usr/lib/python3/dist-packages/certbot/auth_handler.py", line 80, in handle_authorizations
    self._respond(aauthzrs, resp, best_effort)
  File "/usr/lib/python3/dist-packages/certbot/auth_handler.py", line 153, in _respond
    self._poll_challenges(aauthzrs, chall_update, best_effort)
  File "/usr/lib/python3/dist-packages/certbot/auth_handler.py", line 224, in _poll_challenges
    raise errors.FailedChallenges(all_failed_achalls)
certbot.errors.FailedChallenges: Failed authorization procedure. letyu.com (http-01): urn:acme:error:unauthorized :: The client lacks sufficient authorization :: Invalid response from http://letyu.com/.well-known/acme-challenge/_F6gkBb9_-OHATmw9JEUiAB6_xZGnZUghV7fgppnvEk []: "<html>\r\n<head><title>404 Not Found</title></head>\r\n<body bgcolor=\"white\">\r\n<center><h1>404 Not Found</h1></center>\r\n<hr><center>"

标签: ubuntunginxlets-encryptcertbot

解决方案


推荐阅读