生成TomcatSSL证书

一、生成证书

keytool -genkeypair -alias "tomcat" -keyalg "RSA" -keystore "d:\tomcat.keystore" 

二、配置到tomcat的server.xml文件中

<Connector port="8443" protocol="org.apache.coyote.http11.Http11NioProtocol"
               maxThreads="150" SSLEnabled="true" scheme="https" secure="true"
               clientAuth="false" sslProtocol="TLS"
               keystoreFile="tomcat.keystore" 
               keystorePass="123456" />


注:相对路径直接放到tomat目录中即可


(1)