在配置之前请先准备证书。
参考http://www.jianshu.com/p/97883f720ad9
tomcat9文档:
http://tomcat.apache.org/tomcat-9.0-doc/ssl-howto.html
配置server.xml
8443改为443不用端口访问,类似80端口
<!-- Define a SSL Coyote HTTP/1.1 Connector on port 8443 -->
<Connector
protocol="org.apache.coyote.http11.Http11NioProtocol"
port="443" maxThreads="200"
scheme="https" secure="true" SSLEnabled="true"
keystoreFile="D:/Java/jdk1.8.0_77/caskeystore" keystorePass="123456"
clientAuth="false" sslProtocol="TLS"/>
启动访问
https://cas.demo.com