通配符如何生成https?
server {
server_name subdomain.domain.com www.subdomain.domain.com *.subdomain.domain.com ~^(.*)\.subdomain\.domain\.com$;
}目前,对于普通域,我生成的证书如下所示:
sudo certbot --nginx -d example.com发布于 2020-05-27 20:41:43
对于通配符,只需使用*添加另一个条目
sudo certbot --nginx -d *.example.com -d example.com发布于 2021-05-12 22:33:58
我使用following来生成通配符证书,它就像charm一样工作。在这里,我们正在进行dns质询,因此您应该能够访问您的dns,以创建在创建证书时将被读取的条目。
sudo certbot certonly --manual -d *.example.com -d example.com \
--email admin@example.com --agree-tos \
--preferred-challenges dns-01 \
--server https://acme-v02.api.letsencrypt.org/directory希望这些信息能对你有所帮助
发布于 2020-06-08 04:25:53
使用您的命令,您将通过HTTP-Challenge颁发证书。Let's Encrypt不支持通过HTTP-Challenge签发通配符证书。
这是一个关于我们加密支持的挑战类型的链接:https://letsencrypt.org/docs/challenge-types/
对于通配符证书,您需要通过DNS质询颁发证书。因此,您需要API访问您的主机提供商或动态dns提供商。Certbot为他们中的一些人提供了一些插件,这里有一个链接到Certbot-DNS- Plugins -Site:https://certbot.eff.org/docs/using.html#dns-plugins
如果您的提供商未列出,则不能使用Certbot颁发通配符-Certs。还有其他一些工具支持DNS-Challenges让我们像acme.sh一样加密,这里有一个到Github-Repository的链接:https://github.com/acmesh-official/acme.sh
我希望我能在这方面帮到你。
Bananenkönig
https://stackoverflow.com/questions/62028459
复制相似问题