Vincent.Chan‘s Blog

          常用鏈接

          統(tǒng)計(jì)

          積分與排名

          網(wǎng)站

          最新評(píng)論

          配置 Apache 2.2.x + SSL

          1 基礎(chǔ) (可選)

          • 編輯APACHE_HOME/conf/httpd.conf中的以下directives和tags,
            ServerRoot, ServerAdmin, ServerName, DocumentRoot, 
            <Directory %DocumentRoot%>, DirectoryIndex, ScriptAlias /cgi-bin/,
            <Directory %cgi-bin%>
          • 去掉以下語(yǔ)句的注釋,
            Include conf/extra/httpd-manual.conf

          2 生成RSA密鑰 (private key)

          下面兩個(gè)命令都可以生成密鑰,

              openssl genrsa -des3 -out server.key
          openssl genrsa -out server.key

          -des3選項(xiàng)可以加密生成的密鑰, 但是Win32平臺(tái)不支持加密密鑰,啟動(dòng)Apache時(shí)會(huì)產(chǎn)生以下錯(cuò)誤信息, "SSLPassPhraseDialog builtin is not supported on Win32"

          3 生成自簽署證書(shū) (self-signed certificate)

          在OpenSSL源碼的"openssl\apps"目錄可以找到openssl.cnf (OpenSSL配置文件).

              openssl req -config openssl.cnf -new -x509 -key server.key -out 
          server.crt -days 365

          4 編輯APACHE_HOME/conf/httpd.conf

          去掉以下語(yǔ)句的注釋,

             Include conf/extra/httpd-ssl.conf

          5 編輯 conf/extra/httpd-ssl.conf

          • SSLMutex標(biāo)簽的值改為default
          • 編輯以下directives(可選),
            DocumentRoot, ServerName, ServerAdmin, ErrorLog, TransferLog, 
            SSLCertificateFile, SSLCertificateKeyFile

          posted on 2006-05-06 19:05 Vincent.Chen 閱讀(3303) 評(píng)論(0)  編輯  收藏 所屬分類(lèi): 雜文

          主站蜘蛛池模板: 红原县| 如皋市| 拜泉县| 八宿县| 邛崃市| 达日县| 阿鲁科尔沁旗| 秦安县| 宁河县| 北京市| 文安县| 镶黄旗| 台南县| 务川| 平凉市| 若尔盖县| 镇雄县| 盐边县| 芜湖市| 平安县| 和平县| 喀喇沁旗| 苍南县| 墨竹工卡县| 桑植县| 古交市| 高密市| 前郭尔| 蚌埠市| 白朗县| 桦甸市| 乐陵市| 安新县| 巩义市| 隆安县| 蒙自县| 安多县| 丽江市| 大邑县| 淄博市| 寿光市|