我在AWS Ec2 Amazon Linux上并试图使用Let的加密.当我第一次安装Let's Encrypt几个月后,我没有任何更新证书的问题.但现在我收到此错误,无法续订.
# ./certbot-auto --debug
Error: couldn't get currently installed version for /opt/eff.org/certbot/venv/bin/letsencrypt:
Traceback (most recent call last):
File "/opt/eff.org/certbot/venv/bin/letsencrypt", line 7, in <module>
from certbot.main import main
File "/opt/eff.org/certbot/venv/local/lib/python2.7/dist-packages/certbot/main.py", line 7, in <module>
import zope.component
File "/opt/eff.org/certbot/venv/local/lib/python2.7/dist-packages/zope/component/__init__.py", line 16, in <module>
from zope.interface import Interface
ImportError: No module named interface
Run Code Online (Sandbox Code Playgroud)
我试过unset PYTHON_INSTALL_LAYOUT和升级pip,virtualenv.没运气.
这个问题似乎更相似Letsencrypt ImportError:在更新时,亚马逊linux上没有名为interface的模块但是dirctory是不同的.不确定我想要的/opt/eff.org/certbot/venv/bin/letsencrypt
当我碰到这个不寻常的问题时,我刚刚开始在我的应用程序中实现对App Links的支持.
按照Android Studio应用链接工具中的步骤,我很快就能够进行必要的更改.但是,当我开始验证数字资产链接文件与我的网站的关联时,我收到了一个错误.
最初,我认为访问链接可能有一些错误.我尝试使用多个浏览器访问该链接,并且没有错误.
当我环顾四周寻找类似问题的人时,我发现了这篇文章.我试图关联的网站也使用了LetsEncrypt生成的SSL证书.所以,我尝试了另一个使用LetsEncrypt SSL的网站 - 结果相同.然后我使用了一个使用RapidSSL生成的SSL和宾果游戏的网站 - 它有效!
我不确定App Links团队是否注意到了这一点.但任何人都可以帮忙得到答案吗?
谢谢!
如果您有一个仅使用 Apache(可能使用 PHP)的网站,该网站位于:
/home/www/mywebsite/
/home/www/mywebsite/index.php
/home/www/mywebsite/style.css
Run Code Online (Sandbox Code Playgroud)
然后,很容易certbot设置--webroot-path:
./certbot-auto certonly --webroot --webroot-path /home/www/mywebsite/
--domain example.com --domain www.example.com --email a@example.com
Run Code Online (Sandbox Code Playgroud)
问题:当使用由 NodeJS 或 Python Flask 或 Bottle 运行的网站时,通过 WSGI (mod_wsgi) 或简单代理链接到 Apache(我知道在 Python 的情况下不推荐后者)
RewriteEngine On
RewriteRule /(.*) http://localhost:5000/$1 [P,L]
Run Code Online (Sandbox Code Playgroud)
应该是什么--webroot-path?
更具体地说,如果我们有:
/home/www/mywebsite/ (Pyton example)
/home/www/mywebsite/myapp.py
/home/www/mywebsite/myapp.sqlite
/home/www/mywebsite/static/style.css
...
Run Code Online (Sandbox Code Playgroud)
或者
/home/www/mywebsite/ (NodeJS example)
/home/www/mywebsite/myapp.js
/home/www/mywebsite/myapp.sqlite
/home/www/mywebsite/static/style.css
...
Run Code Online (Sandbox Code Playgroud)
--webroot-path那么选择as就没有意义了/home/www/mywebsite/,对吧?
事实上,我不希望任何其他程序/脚本(例如 LetsEncrypt certbot)来摆弄我的 .py 文件。
无论如何,--webroot-pathin是certbot做什么的?那里的文件会被分析、解析吗?
我想用Let's Encrypt(带手动挑战)生成一个CRT/KEY耦合SSL文件.
我正在尝试这样的事情:
certbot certonly --manual -d mydomain.com
Run Code Online (Sandbox Code Playgroud)
但我只在我的文件中获取这些文件/etc/letsencrypt/live/mydomain.com folder:
我错过了什么吗?
最近,我尝试在裸机服务器上使用 microk8s 和默认入口控制器设置 LetsEncrypt。
我在网上找到了一些非常有用的指南,但似乎最近对 microk8s 进行了更新,改变了入口控制器的配置方式。
为了节省大家的时间,我准确地写下了我所做的事情。
如果您遇到困难或需要更好地理解,这里有一些有用的资源。
https://cert-manager.io/docs/installation/kubernetes/
https://cert-manager.io/docs/tutorials/acme/ingress/
该链接对于故障排除非常有用
我一直在尝试为我们的一个项目生成SSL证书,该证书在没有IP限制的Azure VM上运行.但是,生成的质询文件会引发404错误,无法通过Web访问.
我尝试过以下方法:
以上工作都没有让我很难使用此服务生成SSL.知道如何让它可以访问吗?我已经完全访问了特定的应用程序池标识,因此在这种情况下权限似乎不是问题,它只是在IIS中处理扩展文件的方式.
任何帮助表示赞赏.
谢谢,维沙尔
我现在正在努力让请求库GET使用Let的加密证书对我的网站执行简单的请求.一切都很好的网站,我可以从Chrome访问它就好了.(我现在正在运行OSX El Capitan).
首先,我尝试GET向网站提出请求:
>>> import requests
>>> requests.get('https://example.com')
Run Code Online (Sandbox Code Playgroud)
这给了我:
requests.exceptions.SSLError: [SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed (_ssl.c:590)
Run Code Online (Sandbox Code Playgroud)
然后我尝试了各种各样的东西,包括获取Let的加密权限证书,以下openssl命令成功验证我的站点的证书:
> openssl s_client -CAfile ./letsencryptauthorityx1.pem -connect example.com:443
Run Code Online (Sandbox Code Playgroud)
其输出包括以下内容:
...
SSL-Session:
Protocol : TLSv1
Cipher : DHE-RSA-AES256-SHA
Session-ID: ...
Session-ID-ctx:
Master-Key: ...
Key-Arg : None
Start Time: 1452865123
Timeout : 300 (sec)
Verify return code: 0 (ok)
---
Run Code Online (Sandbox Code Playgroud)
也许我在这里遗漏了一些东西,但它看起来好像我的网站已经根据我提供的Let's Encrypt授权证书进行了验证.所以,我很高兴地将我的Python代码更改为:
>>> requests.get('https://example.com', verify='./letsencryptauthorityx1.pem')
Run Code Online (Sandbox Code Playgroud)
但我仍然不断收到requests.exceptions.SSLError错误.我也尝试使用DER权威证书的格式,但后来我收到以下错误requests:
requests.exceptions.SSLError: …Run Code Online (Sandbox Code Playgroud) 我们正在使用Windows 2012 Server R2.
我们正在尝试自动创建LetsEncrypt证书.我们正在使用LetsEncrypt-Win-Simple(https://github.com/Lone-Coder/letsencrypt-win-simple).
一旦创建了证书(通过LetsEncrypt.exe),我们就会调用一个.bat脚本(使用--script和--scriptparameters标志).这将运行powershell.exe并尝试创建必要的IIS绑定..bat文件中的行是:
powershell.exe -file c:\temp\SSLIISBinding.ps1 %1 %2 %3 %4
Run Code Online (Sandbox Code Playgroud)
%1-4是LetsEncrypt传入的args.在powershell脚本中,我们尝试运行的命令是:
$iis_host_name = $args[0]
$iis_site_name = $args[1]
$certificate_hash = $args[2]
$certificate_store = $args[3]
"IIS Host Name: " + $iis_host_name
"IIS Site Name: " + $iis_site_name
"Certificate Hash: " + $certificate_hash
"Certificate Store: " + $certificate_store
$guid = [guid]::NewGuid().ToString("B")
netsh http add sslcert hostnameport="${iis_host_name}:443" certhash=$certificate_hash certstorename=$certificate_store appid="$guid"
New-WebBinding -name $iis_site_name -Protocol https -HostHeader $iis_host_name -Port 443 -SslFlags 1
Run Code Online (Sandbox Code Playgroud)
args传入.bat罚款,因为我们输出它们并且它们正确显示.
如果我们自己运行.bat文件,它就能完美运行.如果它被LetsEncrypt.exe调用则失败,报告以下问题:
New-WebBinding : Cannot retrieve the dynamic …Run Code Online (Sandbox Code Playgroud) 购买自定义SSL证书与从Let's Encrypt提供的免费证书中获取证书之间的主要区别(可能是pro/con列表).这就是我们的Web应用程序中只有简单的https
PS我相信你明白我想做什么.
从历史上看,我们已经在工作中使用了LetsEncrypt,但我们使用的nginx容器已经安装了Openssl.
lets-encrypt ×10
ssl ×3
https ×2
openssl ×2
android ×1
apache ×1
applinks ×1
batch-file ×1
cert-manager ×1
certbot ×1
flask ×1
iis ×1
iis-8 ×1
kubernetes ×1
microk8s ×1
node.js ×1
powershell ×1
python ×1
security ×1
windows ×1