Bob I already have all the arguments and how to pass them through C_Initialize ok. What I don't know how to do is to create a custom softtoken that can be used by Netscape, without touching anything in the Mozilla softoken directory. Right now I have to modify the pkcs11.c module to allow me to intercept the NSC_Initialize function, direct it to my C_Initialize, then setup the parms and call NSC_Initialize. This allows me to define the location of my own databases, change the slot/token name, etc. That works, but I would have thought that there is a simpler and cleaner way without messing with the mozilla libraries.
Trying to set the vector to my C_Initialize function in the C_GetFunctionList does not work, or at least I cannot get it to work. Besides the RSA PKCS11 specs states that this should never be done. And on top of that, I am trying to get to the point where I only call the mozilla dll's and not do static links. Ken "Robert Relyea" <[EMAIL PROTECTED]> wrote in message [EMAIL PROTECTED]">news:[EMAIL PROTECTED]... > Unfortunately the softoken needs the database configuration information > in order to operation. I've been meaning to pick some 'defaults', or > pull them out of the environment if the parameter strings are not > provided, but haven't had time. > > If you wanted to provide changes where softoken would look at an > environment variable if the parameter strings have not been provided, I > would be happy to include them in NSS. > > If you are writting an application, I posted how the parameters are > supposed to be passed through the INIT_ARGs of C_Initialize, though this > is a proposed amendment to the PKCS #11 standard, which has not been > adopted yet. That posting was several months ago, so you would have to > search the archives. That doc should be part of the NSS 3.4 > documentation when it's released. > > bob > > Kenneth R. Robinette wrote: > > What is the "correct" method of using the new softokn3.dll as a unique > > software token? I see where you can modify the pkcs11.c module to add your > > own logic in the function nsc_CommonInitialize, to point to the desired > > databases, change the token name, etc. but is this the preferred method? > > Since the C_Initialize function is already contained within pkcs11.c, I > > don't see a way to do so without modifying pkcs11.c itself. > > > > Ken > > > > > > > > >
