首页 > 代码库 > 转:Tomcat 配置8443 https

转:Tomcat 配置8443 https

问:

已经按网上的方法配置了8443端口 端口能够启动
并生成了证书:
keytool -genkey -alias tomcat -keyalg RSA -keysize 1024 -validity 365 -keystore tomcat.keystore


<Connector className="org.apache.catalina.connector.http.HttpConnector"
          port="8443" minProcessors="5" maxProcessors="75"
          enableLookups="true"
    acceptCount="10" debug="0" scheme="https" secure="true">
    <Factory className="org.apache.catalina.net.SSLServerSocketFactory"
          clientAuth="false" keystoreFile="tomcat.keystore"
          keystorePass="tomcat" protocol="TLS"/>
  </Connector>

但输入https://localhost:8443没有反应 
请高人指点

 

解决:

 <Connector port="8443" protocol="HTTP/1.1" SSLEnabled="true"
               maxThreads="150" scheme="https" secure="true"
               clientAuth="false" sslProtocol="TLS"
                keystoreFile="gx_gs.jks" keystorePass="newsky" />

这样配置就可以了,网上的资料很多都是互相抄袭99%是错的,我看官方文档自己弄出来 在这里共享一下

 

转自:http://bbs.csdn.net/topics/380035634

转:Tomcat 配置8443 https