Win a copy of Cross-Platform Desktop Applications: Using Node, Electron, and NW.js this week in the JavaScript forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

What value is to be set in javax.net.ssl.trustStore?  RSS feed

 
Yogesh Gandhi
Ranch Hand
Posts: 226
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I have one file that is provided to me by the customer (i.e. server.cer)

I used a command something like below to create a keystore.ks file

keytool -import -alias bob -file bob.crt -keystore keystore.ks

I add this to

System.setProperty("javax.net.ssl.trustStore", "keystore.ks");

Can someone please confirm if I am doing it right?

And why not should I do

System.setProperty("javax.net.ssl.trustStore", "server.cer");


Please do let me know your views.


 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!