Larry Melton wrote, On 2008-06-23 15:29: > We would like our java application to create a mozilla cert store if one > doesn't already exist, similar to the way firefox does. We currently > install firefox and create a new profile specifically for our application. > It seems that some IE types start convulsing on the floor if you suggest > that you need to install firefox on their system, so we're in the process of > embedding mozilla in our app with xulrunner. Everything works mostly, but > now we need to create our own cert store. Where is the mozilla cert store > created (I presume some where in nss)? Is there a cooresponding call in JSS > to do this? (If necessary, we can recompile JSS, but haven't tried > compiling NSS.) > > CryptoManager.InitializationValues() seems to require that the database > files be present. It would be wonderful if there were a flag to create the > files if they're not already present. Point me in the right direction and I > can do it myself.
NSS has a bunch of different initialization routines, but they all fit into two categories: - those that open the DBs "read only", and - those that open the DBs "read/write". The read-only functions will fail if the DBs don't exist. The read/write functions will create the DBs if they don't exist. It's that simple. JSS and PSM provide methods to open DBs. Just use one that opens them RW. Actually, I think ALL of PSM's methods open them RW. JSS has some of each flavor. _______________________________________________ dev-tech-crypto mailing list dev-tech-crypto@lists.mozilla.org https://lists.mozilla.org/listinfo/dev-tech-crypto