问题描述
当我尝试在 Windows 7 中启用 SSL(编辑 server.xml 以启用端口:8443 作为 HTTPS)时,它没有被启用.有时它显示(连接到本地主机..)并保持挂起.我使用的是 Windows 7 64 位/4GB RAM Tomcat 6.0(netbeans 包),jre 1.6(64 位).
When i try to enable the SSL (editing server.xml to enable port:8443 as HTTPS) in Windows 7, its not getting enabled. sometimes it shows (connected to localhost..) and remains hanged.I'm using Windows 7 64-bits/4GB RAM Tomcat 6.0(netbeans bundle), jre 1.6(64-bit).
推荐答案
我让它在我的情况下工作,问题是使用的协议.在文件 server.xml 中,将连接器选项 protocol="HTTP/1.1" 更改为 protocol="org.apache.coyote.http11.Http11NioProtocol"
I made it work on my case, the problem is the protocol used.In the file server.xml change the connector option protocol="HTTP/1.1" to protocol="org.apache.coyote.http11.Http11NioProtocol"
该部分应如下所示.
<Connector port="8443" protocol="org.apache.coyote.http11.Http11NioProtocol" SSLEnabled="true"
maxThreads="150" scheme="https" secure="true"
clientAuth="false" sslProtocol="TLS"
keystoreFile="C:\pathtocert\cert.bin"
keystorePass="****" />
这篇关于SSL 启用:Windows 7 中的 Tomcat的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!