黄聪

论SEO对人类的重要性,请看我的博客:hcsem.com

  博客园 :: 首页 :: 博问 :: 闪存 :: 新随笔 :: 联系 :: 订阅 订阅 :: 管理 ::

假设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/

posted on 2022-01-28 11:16  黄聪  阅读(331)  评论(1编辑  收藏  举报