프로그래밍/Java

HTTPClient SSL Client Auth 샘플소스

jonelove71 2010. 8. 4. 14:44

Protocol authhttps = new Protocol("https",  new AuthSSLProtocolSocketFactory(
     new URL("file:./Cert/client.jks"), "1q2w3e4r",
     new URL("file:./Cert/client.jks"), "1q2w3e4r"), 8443); 
   
HttpClient httpClient = new HttpClient();
httpClient.getHostConfiguration().setHost("localhost", 8443, authhttps);

참고하세요