X509 Client certificate - how to prompt user for Master Password
[email protected] Wed, 24 Sep 2008 01:35:50 -0700 (PDT)
| Newsgroups | gmane.comp.mozilla.devel.java |
|---|---|
| Organization | http://groups.google.com |
| Message-ID | <2a318b15-76df-418e-aff4-234ee8283b20@r15g2000prh.googlegroups.com> |
Hi There, I'm working with the SWT Browser widget inside a Web Browser view I am creating and I am trying to get it to connect to a SSL enabled website that requests a clientside certificate. I'm using XulRunner 1.8 (Mozilla 2) in Java i.e JavaXPCOM. I can use nsIX509CertDB to import the PKCS12 keystore that holds the client side certificate and so long as the browser then remains open I can connect to websites requesting my user cert without problem. However, when I restart the browser I can no longer access the SSL enabled site, the client certificate is still in there (I can see that by calling findCertNicknames). It doesn't prompt me for a password for the keystore which I am guessing is the problem (i.e. the session where I import it the password I use on the keystore remains in memory to be accessed, when I shut it down and restart it the password isn't known, its not asking me for it and everything is failing quietly.) The only way I can then get it to work is to blow away the user profile and reimport the cert with password etc, not exactly a suitable solution. Does anyone know how to get XPCOM to prompt the user for the password to mozillas user cert keystore? Or method by which I can provide the password to XPCOM programmatically? Thanks! Will.