SSL certificate problem in a web service proxy

前端 未结 3 2073
梦毁少年i
梦毁少年i 2021-01-22 15:12

I am building a JAVA web service client in which i connect to a service.

This service has a ssl certificate verification.

How to call this service using ssl cert

3条回答
  •  南笙
    南笙 (楼主)
    2021-01-22 15:50

    All you need to do is injecting the server root certificate to your JDK/JRE environments by using the following command line: -

    keytool -importcerts -trustcacerts -file  -alias  -keystore 
    

    The default [your_keystore] is

     1. /jre/lib/security/cacerts
     2. /lib/security/cacerts
    

    The default password is changeit.

    When you call the web service, just mention the

    "https://:/Path/To/Services"
    

    I hope this may help to achieve your requirement.

    Regards,

    Charlee Ch.

提交回复
热议问题