其他分享
首页 > 其他分享> > XAMPP本地配置SSL

XAMPP本地配置SSL

作者:互联网

假设XAMPP安装目录为:H:\_xampp

 

1、配置 C:\Windows\System32\drivers\etc\hosts 

127.0.0.1 test.com
127.0.0.1 www.test.com

 

2、下载证书,复制到 H:\_xampp\apache\conf 

key.rar

 

3、修改 httpd-ssl.conf 添加端口

Listen 8443

 

4、修改 H:\_xampp\apache\conf\extra\httpd-vhosts.conf 添加网站路径

NameVirtualHost *:8443

<VirtualHost *:8443>
    ServerName localhost
    DocumentRoot H:\_xampp\htdocs\test
    SSLEngine on
    SSLProxyEngine on
    SSLCertificateFile "H:\_xampp\apache\conf\key\server.crt"
    SSLCertificateKeyFile "H:\_xampp\apache\conf\key\server.key"
    <Directory "/">
        Options None
        AllowOverride All
        Order allow,deny
        Allow From All
    </Directory>
</VirtualHost>

 

5、重启 Apache

6、访问 https://www.test.com:8443/

标签:key,xampp,本地,SSL,XAMPP,conf,8443,test,apache
来源: https://www.cnblogs.com/huangcong/p/15852235.html