新聞中心
這篇文章主要介紹“phpStudy安裝ssl證書教程”,在日常操作中,相信很多人在phpStudy安裝ssl證書教程問題上存在疑惑,小編查閱了各式資料,整理出簡單好用的操作方法,希望對大家解答”phpStudy安裝ssl證書教程”的疑惑有所幫助!接下來,請跟著小編一起來學(xué)習(xí)吧!
目前創(chuàng)新互聯(lián)已為近1000家的企業(yè)提供了網(wǎng)站建設(shè)、域名、網(wǎng)站空間、網(wǎng)站運(yùn)營、企業(yè)網(wǎng)站設(shè)計(jì)、漢源網(wǎng)站維護(hù)等服務(wù),公司將堅(jiān)持客戶導(dǎo)向、應(yīng)用為本的策略,正道將秉承"和諧、參與、激情"的文化,與客戶和合作伙伴齊心協(xié)力一起成長,共同發(fā)展。
一、修改apache目錄下的 httpd.conf 配置文件 1、#LoadModule ssl_module modules/mod_ssl.so 刪除行首的配置語句注釋符號“#” 2、增加一條引用語句 Include conf/vhostsssl.conf 二、 1、在conf文件夾中創(chuàng)建一個vhostsssl.conf配置文件。 2、編輯 vhostsssl.conf 文件,增加如下內(nèi)容: Listen 443SSLEngine on SSLProtocol all -SSLv2 -SSLv3 SSLCipherSuite HIGH:MEDIUM:!aNULL:!MD5 SSLCertificateFile "D:\phpStudy\SSL\2_trustauth.cn.crt" SSLCertificateKeyFile "D:\phpStudy\SSL\trustauth.cn.key" SSLCertificateChainFile "D:\phpStudy\SSL\1_root_bundle.crt" DocumentRoot "c:\WWW\jsdxnb" 其中 SSLCertificateFile 是指證書公鑰 SSLCertificateKeyFile 是指證書私鑰 SSLCertificateChainFile 是指根證書 三、phpstudy 配置指定路徑訪問 https(我這一步?jīng)]有配置,不行的話可以在 .htaccess 文件中配置)。Options +Indexes +FollowSymLinks +ExecCGI AllowOverride All Order allow,deny Allow from all Require all granted RewriteEngine on RewriteBase / RewriteCond %{SERVER_PORT} !^443$ RewriteRule ^.*$ https://%{SERVER_NAME}%{REQUEST_URI} [L,R] 四、保存退出,并重啟Apache。 ps: Apache 啟動不了,一般是配置文件不對,請大家耐心排查。一般啟動不了是因?yàn)橹芭渲眠^SSL或者文件配置錯誤! 一般目錄:phpStudy安裝軟件安裝目錄,C:\phpStudy\Apache\conf 以下是備用代碼,這個也可以用。
Listen 443 SSLEngine On SSLCertificateFile “D:/ssl/2_www.trustauth.cn.crt” SSLCertificateKeyFile “D:/ssl/3_www.trustauth.cn.key” SSLCertificateChainFile “D:/ssl/1_root_www.trustauth.cn.crt” #…… DocumentRoot “D:/APP” ServerName xs.xingshili.vip:443 |
到此,關(guān)于“phpStudy安裝ssl證書教程”的學(xué)習(xí)就結(jié)束了,希望能夠解決大家的疑惑。理論與實(shí)踐的搭配能更好的幫助大家學(xué)習(xí),快去試試吧!若想繼續(xù)學(xué)習(xí)更多相關(guān)知識,請繼續(xù)關(guān)注創(chuàng)新互聯(lián)網(wǎng)站,小編會繼續(xù)努力為大家?guī)砀鄬?shí)用的文章!
文章題目:phpStudy安裝ssl證書教程
分享網(wǎng)址:http://www.ef60e0e.cn/article/pgogdp.html