52杰奇论坛

 找回密码
 立即注册
搜索
热搜: 活动 交友 discuz
查看: 4889|回复: 0

护卫神apache|nginx大师站点添加ssl证书,实现https访问

[复制链接]

598

主题

251

回帖

100万

积分

管理员

Rank: 9Rank: 9Rank: 9

积分
1004948
发表于 2022-4-23 16:00:00 | 显示全部楼层 |阅读模式

环境:护卫神 apache大师 2.1.0,Windows 2012

过程:

1. 安装好 “护卫神 apache大师” 软件,开设站点,如本例 mp.anqun.org





2. 编辑 C:\HwsApacheMaster\Apache\conf\httpd.conf 文件,搜索 mod_ssl,移除注释符号#(本例第124行); 同理,让 httpd-ssl.conf 配置文件也生效




3. 编辑 C:\HwsApacheMaster\Apache\conf\extra\httpd-ssl.conf 文件,修改 SSLSessionCache 文件的存储路径,使之有效;之后新建一个https的站点配置内容,如本例的 mp.anqun.org,证书文件保存在 C:\HwsApacheMaster\Apache\conf\ssl 目录内
[url=]复制代码[/url]
  • #   Inter-Process Session Cache:
  • #   Configure the SSL Session Cache: First the mechanism
  • #   to use and second the expiring timeout (in seconds).
  • #SSLSessionCache         "dbm:E:/Huweishen.com/HwsApacheMaster/Apache2.2/logs/ssl_scache"
  • # SSLSessionCache        "shmcb:E:/Huweishen.com/HwsApacheMaster/Apache2.2/logs/ssl_scache(512000)"
  • SSLSessionCache        "shmcb:logs/ssl_scache(512000)"
  • SSLSessionCacheTimeout  300
  • #   Semaphore:
  • #   Configure the path to the mutual exclusion semaphore the
  • #   SSL engine uses internally for inter-process synchronization.
  • SSLMutex default
  • ##
  • ## SSL Virtual Host Context
  • ##
  • <VirtualHost *:443>
  •         SSLEngine on
  •         SSLCipherSuite ALL:!ADH:!EXPORT56:RC4+RSA:+HIGH:+MEDIUM:+LOW:+SSLv2:+EXP
  •         SSLCertificateFile      "conf\ssl\1_mp.anqun.org_bundle.crt"
  •         SSLCertificateKeyFile   "conf\ssl\2_mp.anqun.org.key"
  •         ServerName      "mp.anqun.org"
  •         DocumentRoot    "C:\HwsApacheMaster\wwwroot\mp_f75yPU"
  •    <Directory "C:/HwsApacheMaster/wwwroot/mp_f75yPU">
  •         Options FollowSymLinks ExecCGI
  •     #AddHandler fcgid-script .php
  •     #FcgidWrapper "/php-cgi.exe" .php
  •         DirectoryIndex index.html index.htm index.php default.php index.jsp
  •         AllowOverride All
  •         Order Deny,Allow
  •         Allow from all
  •     </Directory>
  • </VirtualHost>




4. 重启apache,在浏览器里测试,https访问有效(需在实例安全组规则里开放443端口)



回复

使用道具 举报

您需要登录后才可以回帖 登录 | 立即注册

本版积分规则

Archiver|手机版|小黑屋|52杰奇论坛  

GMT+8, 2024-4-29 12:09 , Processed in 0.112952 second(s), 27 queries .

Powered by Discuz! X3.4

© 2001-2023 Discuz! Team.

快速回复 返回顶部 返回列表