zoukankan      html  css  js  c++  java
  • Apache 开启 Https

    1. 准备所需工具:

    1) apache httpd2.4 浏览

    2) Win32 OpenSSL v1.0.2d 浏览

    2. 安装

    2.1 安装Apache2.4服务

    php环境搭建 浏览

    2.2 安装OpenSSL

    双击Win64OpenSSL-1_0_2d.exe进行安装即可。

    3. 生成密钥

    进入%OpenSSL%in目录

    1) 生成密钥

    openssl genrsa 1024 > server.key

    2) 生成证书请求文件

    openssl req -config D:Program_FilesApache24confopenssl.cnf -new -key server.key > server.csr

    3) 生成证书

    openssl req -config D:Program_FilesApache24confopenssl.cnf -x509 -days 365 -key server.key -in server.csr > server.crt

    4. 配置

    1) 将生成的server.key和server.crt文件拷贝到 D:Program_FilesApache24conf

    2) 修改 D:Program_FilesApache24confextrahttpd-ssl.conf 

    SSLCertificateFile "D:/Program_Files/Apache24/conf/server.crt"
    
    SSLCertificateKeyFile "D:/Program_Files/Apache24/conf/server.key"

    注意将此文件中所有的 "c:/apache24" 替换成你自己的安装目录

    3) 修改 httpd.conf 文件

    LoadModule ssl_module /opt/taobao/install/httpd/modules/mod_ssl.so
    
    LoadModule socache_shmcb_module modules/mod_socache_shmcb.so
    
    # Secure (SSL/TLS) connections
    Include conf/extra/httpd-ssl.conf

    4) 重启Apache服务

    5) 打开网页 https://localhost

    4. 参考

    1) apache https配置步骤 浏览

  • 相关阅读:
    [原]OS X 10.9 Mavericks
    [原]iOS Makefile Template
    [原]Escape From the iOS Sanbox on Jailbreak Device
    串->串的表示和实现
    队列->队列的应用(银行业务模拟)
    队列->队列的表示和实现
    栈->栈与递归
    栈->栈的应用
    栈->栈的基本定义
    线性表->应用->一元多项式
  • 原文地址:https://www.cnblogs.com/swordy/p/4675696.html
Copyright © 2011-2022 走看看