由于我的配置的性质,我被迫手动加载证书。
我的配置如下所示:servername mydomain.com
ServerAlias www.mydomain.com
邮箱:ServerAdmin Webmaster@mydomain.com
文档根目录“/var/sentora/hostdata/myusername/public_html/mydomain_com”
PHPADMIN_VALUE OPEN_BASEDIR“/var/sentora/hostdata/myusername/public_html/mydomain_com:/var/sentora/temp/”
Php_admin_value suhosin.ecutor.unc.Blacklist“passthu,show_source,shell_exec,system,pcntl_exec,popen,plose,proc_open,proc_ice,proc_Terminate,proc_get_atus,proc_lose,leak,apache_Child_Terminate,POSIX_KILL,POSIX_MKFIFIO,POSIX_setpgid,POSIX_setsid,POSIX_setuid,Essceshellcmd,Essceshellarg,exec”
错误日志“/var/sentora/logs/domains/myusername/mydomain.com-error.log”
CustomLog“/var/sentora/logs/domains/myusername/mydomain.com-access.log”组合
CustomLog“/var/sentora/logs/domains/myusername/mydomain.com-bandwidth.log”通用选项+后续符号链接-索引
允许覆盖全部
需要所有GrattedAddType应用程序/x-HTTPD-php.php3.php
DirectoryIndex index.html index.htm index.php index.asp index.aspx index.jsp index.jspa index.shtml index.shtm
#自定义全局设置(如果存在)
#自定义VH设置(如果存在)
SSLEngine打开
SSL认证文件/etc/letsENCRYPT/live/mydomain.com/cert.pem
SSL证书密钥文件/etc/letsencrypt/live/mydomain.com/privkey.pem
SSL认证链文件/etc/letsencrypt/live/mydomain.com/chain.pemServerName myDomain.com
ServerAlias www.mydomain.com
邮箱:ServerAdmin Webmaster@mydomain.com
重写引擎打开
重写条件%{SERVER_PORT}^443$
我为这个愚蠢的问题道歉,但我对SSL证书还是个新手。,对不起,我的水晶球已经损坏了…
你能给我们提供更多的细节吗?你是怎么拿到证书的?(输入的命令?)错误?
确切的问题是什么?
您是否提供了带有-d mydomain.com-d www.mydomain.com的letsENCRYPT命令,还是只为mydomain.com提供了一个-d?只提供了-d mydomain.com
我想这就是问题所在?,可能是…查看带有openssl x509-noout-text-in/etc/letsENCRYPT/live/mydomain.com/cert.pem的证书,并查看x509v3主题替代名称::后面的“dns:”条目,它可能只包含mydomain.com,但您也希望拥有www-版本。你也应该加上第二个-d。你可以在这个列表中有很多很多的域名,那么现在呢?我是用正确的命令申请新证书,还是有“正确”的方法?,r00t:
只有-d mydomain.com
是的,您需要指定所有的子域,即使是显而易见的子域也是如此(其他域名可以自动指定,LE不可以)。使用以下内容申请新证书:
-d域名.com-d www.domain.com
它将生成一个对两个站点都有效的证书。好的,谢谢你们两个帮助我,现在它工作得很好。
@奥西里斯,抱歉弄坏了你的水晶球。这是一张猫的照片。