使用 Laragon Apache 问题启用 SSL

Enabling SSL with Laragon Apache issue

我从 ZeroSSL 获得了 90 天的免费 SSL 证书,其中包含 3 个文件:ca_bundle.crt、certificates.crt 和 private.key。然后放入C:\laragon\etc\ssl

编辑 C:\laragon\etc\apache2\sites-enabled[=31=]-default.conf

<VirtualHost _default_:80>
    <Directory "C:/laragon/www">
        AllowOverride All
        Require all granted
    </Directory>
</VirtualHost>
<VirtualHost _default_:443>
    <Directory "C:/laragon/www">
        AllowOverride All
        Require all granted
    </Directory>

    SSLEngine on
    SSLCertificateFile       C:/laragon/etc/ssl/certificate.crt
    SSLCertificateKeyFile    C:/laragon/etc/ssl/private.key
    SSLCertificateChainFile  C:/laragon/etc/ssl/ca_bundle.crt
    
#SSLCertificateFile      C:/laragon/etc/ssl/laragon.crt
#SSLCertificateKeyFile   C:/laragon/etc/ssl/laragon.key
</VirtualHost>

C:\laragon\etc\apache2\httpd-ssl.conf 已由 Laragon 自动编辑

Listen 443

SSLCipherSuite HIGH:MEDIUM:!MD5:!RC4
SSLProxyCipherSuite HIGH:MEDIUM:!MD5:!RC4

SSLHonorCipherOrder on 

SSLProtocol all -SSLv3
SSLProxyProtocol all -SSLv3

SSLSessionCache "shmcb:logs/ssl_scache(512000)"
SSLSessionCacheTimeout  300

C:\laragon\bin\apache\httpd-2.4.47-win64-VS16\conf\httpd.conf 也由 Laragon 自动编辑

<IfModule ssl_module>
SSLRandomSeed startup builtin
SSLRandomSeed connect builtin
</IfModule>

AcceptFilter http none
AcceptFilter https none
EnableSendfile Off
EnableMMAP Off

IncludeOptional "C:/laragon/etc/apache2/alias/*.conf"
IncludeOptional "C:/laragon/etc/apache2/sites-enabled/*.conf"
Include "C:/laragon/etc/apache2/httpd-ssl.conf"
Include "C:/laragon/etc/apache2/mod_php.conf"

但 SSL 仅适用于本地。

从 Internet 访问时无法正常工作并显示错误消息 -

This site can’t be reached - took too long to respond

.

我哪里做错了?请帮忙,谢谢。

请忽略以上问题。

找到答案了,是因为我忘了关闭443端口的防火墙。

对不起