P.P*_*ter 23 debian ssl-certificate lets-encrypt debian-stretch
如果我尝试访问具有 certbot 颁发的 debian 9 证书的 HTTPS 服务器,则会收到以下错误:
# curl -v https://hu.dbpedia.org/
* Trying 195.111.2.82...
* TCP_NODELAY set
* Connected to hu.dbpedia.org (195.111.2.82) port 443 (#0)
* ALPN, offering h2
* ALPN, offering http/1.1
* Cipher selection: ALL:!EXPORT:!EXPORT40:!EXPORT56:!aNULL:!LOW:!RC4:@STRENGTH
* successfully set certificate verify locations:
* CAfile: /etc/ssl/certs/ca-certificates.crt
CApath: /etc/ssl/certs
* TLSv1.2 (OUT), TLS header, Certificate Status (22):
* TLSv1.2 (OUT), TLS handshake, Client hello (1):
* TLSv1.2 (IN), TLS handshake, Server hello (2):
* TLSv1.2 (IN), TLS handshake, Certificate (11):
* TLSv1.2 (OUT), TLS alert, Server hello (2):
* SSL certificate problem: certificate has expired
* Curl_http_done: called premature == 1
* stopped the pause stream!
* Closing connection 0
curl: (60) SSL certificate problem: certificate has expired
Run Code Online (Sandbox Code Playgroud)
但是,如果我在 debian 10 中尝试相同的命令,它会成功。
我尝试使用 rsync 将所有 ca 证书从 debian 10 虚拟机复制到 debian 9 虚拟机(到 /usr/local/share/ca-certificates),然后运行,update-ca-certificates
似乎添加了 400 多个证书。不幸的是,这没有帮助。这并不奇怪,因为显然 debian 9 和 10 上都有相同的证书。
我的问题是:如何从 debian 9 机器访问带有 certbot 证书的网站而不完全忽略证书验证
ger*_*tas 33
警告!请规划操作系统升级路径。以下建议仅应在紧急情况下应用,以快速修复关键系统。
以下解决方案适用于 Debian Jessy 8,并且也适用于缺少更新的 Stretch 9。我刚刚测试过docker run -it debian:jessie bash
,apt-get update && apt-get install curl
.
前:
# curl -I https://hu.dbpedia.org
curl: (60) SSL certificate problem: certificate has expired
More details here: http://curl.haxx.se/docs/sslcerts.html
....
Run Code Online (Sandbox Code Playgroud)
首先检查您是否存在违规的 DST 根 CA X3 证书:
# grep X3 /etc/ca-certificates.conf
mozilla/DST_Root_CA_X3.crt
Run Code Online (Sandbox Code Playgroud)
旧的 Debian 版本也有正确的 ISRG Root X1:
# grep X1 /etc/ca-certificates.conf
mozilla/ISRG_Root_X1.crt
Run Code Online (Sandbox Code Playgroud)
这将禁用 X3:
# sed -i '/^mozilla\/DST_Root_CA_X3/s/^/!/' /etc/ca-certificates.conf && update-ca-certificates -f
Run Code Online (Sandbox Code Playgroud)
您的域对curl 的响应良好:
# curl -I https://hu.dbpedia.org/
HTTP/1.1 200 OK
...
Run Code Online (Sandbox Code Playgroud)
再次,请计划升级。
Håk*_*ist 26
首先,Debian 9 已停产。但由于客户可能不在你的控制之下,你当然可能想在这次破坏中尝试迎合他们。
我认为虽然问题只提到了certbot
,但它确实是专门针对 Letscrypt 的。
(该工具certbot
本身是一个 ACME 协议客户端,也与其他基于 ACME 的 CA 一起使用,因此这里存在一些混淆的空间。)
当前的问题似乎是以下因素的组合:
如果您提供新的 LE 证书链,并且不尝试额外兼容,只是以新根 (X1) 结尾,则它允许 libssl 1.0 工作(但随后您会失去与真正旧 Android 的兼容性)。
除此之外,其他 CA(ACME 或其他)可能是值得考虑的选择。
小智 6
对于 Debian 8 和 9,我只是这样做来更新主机上的证书,并且不再出现错误 60: SSL 证书问题:证书已过期: https: //github.com/xenetis/letsencrypt-expiration
只要运行,它应该可以工作:
wget -O - https://raw.githubusercontent.com/xenetis/letsencrypt-expiration/main/letsencrypt-expiration.sh | bash
Run Code Online (Sandbox Code Playgroud)
小智 5
DST Root CA X3 根证书已于 2021 年 9 月 30 日 14:01:15 GMT 过期。它被用作 Let\xe2\x80\x99s 的认证路径之一 加密证书 旧的 cURL 版本有一个错误,会导致过期的根连接失败,而不是尝试本地 ca 存储中的其他根。
\n截至 2021 年 9 月 30 日,curl 的 ca 商店 ( https://curl.se/docs/caextract.html ) 仍包含过期的 DST Root CA X3 根证书,因此更新它无法解决问题。您可以更新 cURL(在某些情况下可能相当具有挑战性)或编辑本地 ca 存储 (fe /etc/pki/tls/certs/ca-bundle.crt) 并在“DST Root CA X3”行后手动删除证书
\n 归档时间: |
|
查看次数: |
22638 次 |
最近记录: |