How to develop https site with Spring 3.x?

后端 未结 4 1350
夕颜
夕颜 2021-01-02 14:40

I am a newbie in Spring based web development.

Our site is Spring based and is currently http based (so quite insecure). Since, the site is not live yet, we are send

4条回答
  •  甜味超标
    2021-01-02 15:23

    Thanks for all the help guys. I will re-iterate what I did just for my own record purposes.

    First of all, the link provided by nont about 'Tomcat for SSL' was really helpful. I read all about SSL and Tomcat there and this is what I did:

    On the command prompt, enter: keytool -genkey -alias tomcat -keyalg RSA The above command asked me some simple questions needed for a Certificate. I used the password 'changeit' wherever asked (as that is the default password).

    On finishing with the above command, it generated a keystore file in C:/Documents and Settings//.keystore I copied this .keystore file to tomcat/conf/myKeyStore.jks

    Then I added the following to conf/server.xml :

    
    

    And that's it!! Next time, I ran tomcat my old http link did not work. Then I tried adding sweet 's' to http with a port number of 8443 and lo! everything was up and running again.

    Thanks nont for the wonderful link!!

提交回复
热议问题