1:打开tomcat的conf文件夹下的server.xml
默认配置的是
<Connector port="18080" protocol="HTTP/1.1"
connectionTimeout="20000"
redirectPort="18443" />
改为
<Connector port="18080" protocol="HTTP/1.1" SSLEnabled="true"
maxThreads="150" scheme="https" secure="true"
clientAuth="false" sslProtocol="TLS" keystoreFile="d:/123456.pfx" keystoreType="PKCS12" keystorePass="123456" />
重启tomcat后就生效了,https配置成功后,http就访问不了了,只能用https访问