This is a bug in JSS. When you initialize CryptoManager, it will 
uninstall the Sun provider. To prevent this, you need to initialize 
CryptoManager with a CryptoManager.InitializationValues object, and set 
its "removeSunProvider" field to false.

This bug is fixed in JSS 3.2.

[EMAIL PROTECTED] wrote:
>  am trying to write an application to create
> certificate requests for 
> users and retrieve the results.  The problem is
> when I try to 
> combine the two in one app.
> 
> The class to forward the requests is
> essentially:
> 
> import java.io.*;
> import java.net.*;
> import javax.net.ssl.*;
> 
> public class httpsReq {
> 
> public int forwardCSR (CertificationRequest csr)
> {
>       try {
>               URL url = new URL(https://caserver/enroll
>               URLConnection urlConn = url.openConnection();
>       ...
>       } catch (Exception e) {
>       }
> }
> 
> 
> In the main method,  I do:
> 
> System.setProperty("java.protocol.handler.pkgs",
>       "com.sun.net.ssl.internal.www.protocol");
> System.setProperty("javax.net.ssl.trustStoreType",
> "jks");
> System.setProperty("javax.net.ssl.trustStore",
> "path to store");
> System.setProperty("javax.net.ssl.trustStorePasswo
> rd",
>  "changeit");
> 
> 
> The line that causes the problem is:
> CryptoManager.initialize("path to store");
> 
> This line is necessary for the creation of the
> cert signing request, 
> but just having this line causes the httpsReq
> method to return an 
> SSLsocket error: cannot find jks
> 
> I move the call to the https method around and
> found it works 
> before the CryptoManager.initialize line, but not
> after.  Anyone 
> have an idea what is wrong here?
> 
> 



Reply via email to