我正在尝试使用apache和xampp将HTTP设置为HTTPS。我遵循了本教程Tutorial,只是对xampp配置进行了更改。当我执行所有操作并重新启动apache并尝试访问HTTPS时清除缓存时,它会将我重定向到正确的页面,但是它指出URL不安全,并且证书的状态为
无效This CA Root certificate is not trusted because it is not in the Trusted Root Certification Authorities store.
这是我配置的所有记事本文件,我尝试更改端口,修改apache,但它无法正常工作。任何帮助表示赞赏。
httpd-vhosts
<VirtualHost kakomedia.local>
DocumentRoot "C:/xampp/htdocs/kakomedia/public"
ServerName kakomedia.local
ServerAlias kakomedia.local
</VirtualHost>
httpd-ssl
Listen 443
<VirtualHost _default_:443>
# General setup for the virtual host
DocumentRoot "C:/xampp/htdocs/kakomedia"
ServerName kakomedia.local:443
ServerAdmin admin@example.com
ErrorLog "C:/xampp/apache/logs/ssl_error.log"
TransferLog "C:/xampp/apache/logs/ssl_access.log"
SSLEngine on
SSLCertificateFile "conf/key/certificate.crt"
SSLCertificateKeyFile "conf/key/private.key"
CustomLog "C:/xampp/apache/logs/ssl_request.log" \
"%t %h %{SSL_PROTOCOL}x %{SSL_CIPHER}x \"%r\" %b"
</VirtualHost>
httpd
Listen 80
And I uncommented what needs here.
主机
127.0.0.1 localhost
127.0.0.1 kakomedia.local
127.0.0.1 kakomedia.local
::1