title: Getting PrivilegedActionException: com.sun.xml.internal.messaging.saaj.SOAPExceptionImpl: Message send failed.while invoking web service
body: <p>I am having https service url. I wrote java client using SAAJ. but i am getting the below exception:-- </p>
  
  <p>java.security.PrivilegedActionException: com.sun.xml.internal.messaging.saaj.SOAPExceptionImpl: Message send failed 
  sun.security.validator.ValidatorException: PKIX path building failed: sun.security.provider.certpath.SunCertPathBuilderException: unable to find valid certification path to requested target </p>
  
  <blockquote>
    <blockquote>
      <p>I exported the certificate from service URL (using browser.) and saved as jssecacerts 
      Then imporetd this by using the following command--> keytool -import -file jssecacerts -keystore cacerts </p>
    </blockquote>
  </blockquote>
  
  <p>Now I wrote the java client using SAAJ as below:- </p>
  
  <pre><code>System.setProperty("javax.net.ssl.keyStore", "C:/Program  Files/Java/jre6/lib/security/cacerts"); 
  System.setProperty("javax.net.ssl.keyStorePassword", "changeit"); 
  URL url = new URL("https://whatever.com/service"); 
  SOAPConnectionFactory scf = SOAPConnectionFactory.newInstance(); 
  connection = scf.createConnection(); 
  response = connection.call(message, url); 
  </code></pre>
  
  <p>I dont know where I am wrong...Please help...me....I am in seriously in trouble.. 
  Thanks in Advance..</p>