How to enable https access in apache under win7? ?

WBOY
Release: 2016-10-10 11:56:10
Original
1235 people have browsed it

环境: window7 + apache2.4 + php7.0 + mysql5.7
本地如何配置 https://myweb.com 这样的安全链接访问??

我百度 | 谷歌都搜过了,也尝试着做过,这是我仿照的网址:http://blog.csdn.net/ybb35068...

生成了证书,将证 书放在了 apache根目录下的 conf 文件夹中(server.crt , server.key),配置文件中开启 ssl_mod ,并开启了 httpd-ssl.conf 。

在httpd-ssl.conf 中我是这样配置的:

Listen 443 (将这个注释掉了,不然会报错:443端口已被使用,我是从这个网站中决定这样做的:http://superuser.com/question...)

自己再添加了一个虚拟主机:

<code><VirtualHost ftl.com:443>
  ServerName ftl.com
  DocumentRoot 'd:/web/frontToolLib' # 和 httpd-vhost.conf 中 ftl.com 的一致
  SSLEngine on
  SSLCertificateFile '${SRVROOT}/conf/server.crt'
  SSLCertificateKeyFile '${SRVROOT}/conf/server.key'
</VirtualHost>
</code>
Copy after login
Copy after login

然后配置 httpd-vhosts.conf 文件

<code>NameVirtualHost ftl.com:443
<VirtualHost *:80>
  ServerName ftl.com
  DocumentRoot 'd:/web/frontToolLib'
  <Directory 'd:/web/frontToolLib'>...</Directory>
  <IfModule dir_module>...</IfModule>
</VirtualHost>
</code>
Copy after login
Copy after login

保存,重启 apache 后,能够正常启动。不过访问的时候:

How to enable https access in apache under win7? ?

折腾死人了,能否就在这儿提供一个最新版的 windows 下 配置 apache 开启 https 安全访问的教程??

拜谢大神了!!

回复内容:

环境: window7 + apache2.4 + php7.0 + mysql5.7
本地如何配置 https://myweb.com 这样的安全链接访问??

我百度 | 谷歌都搜过了,也尝试着做过,这是我仿照的网址:http://blog.csdn.net/ybb35068...

生成了证书,将证 书放在了 apache根目录下的 conf 文件夹中(server.crt , server.key),配置文件中开启 ssl_mod ,并开启了 httpd-ssl.conf 。

在httpd-ssl.conf 中我是这样配置的:

Listen 443 (将这个注释掉了,不然会报错:443端口已被使用,我是从这个网站中决定这样做的:http://superuser.com/question...)

自己再添加了一个虚拟主机:

<code><VirtualHost ftl.com:443>
  ServerName ftl.com
  DocumentRoot 'd:/web/frontToolLib' # 和 httpd-vhost.conf 中 ftl.com 的一致
  SSLEngine on
  SSLCertificateFile '${SRVROOT}/conf/server.crt'
  SSLCertificateKeyFile '${SRVROOT}/conf/server.key'
</VirtualHost>
</code>
Copy after login
Copy after login

然后配置 httpd-vhosts.conf 文件

<code>NameVirtualHost ftl.com:443
<VirtualHost *:80>
  ServerName ftl.com
  DocumentRoot 'd:/web/frontToolLib'
  <Directory 'd:/web/frontToolLib'>...</Directory>
  <IfModule dir_module>...</IfModule>
</VirtualHost>
</code>
Copy after login
Copy after login

保存,重启 apache 后,能够正常启动。不过访问的时候:

How to enable https access in apache under win7? ?

折腾死人了,能否就在这儿提供一个最新版的 windows 下 配置 apache 开启 https 安全访问的教程??

拜谢大神了!!

Related labels:
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template
About us Disclaimer Sitemap
php.cn:Public welfare online PHP training,Help PHP learners grow quickly!