Changes

Jump to: navigation, search

NSS Shared DB

690 bytes added, 01:21, 5 February 2008
Database Merge
To merge 2 databases, the application simply opens the both databases and calls the new PK11_MergeTokens() call. PK11_MergeTokens() has the following signature:
 
#include <pk11pub.h>
SECStatus PK11_MergeTokens(
void *pwdata);
WhereParameters:  ''targetSlot'' A pointer to the target slot or database to merge into. ''sourceSlot'' A pointer to the target slot or database to merge from. ''log'' An optional pointer which returns a link list of errors that may have occured during the merge.
targetSlot''pwdata'' password arg
The ''targetSlot'' and ''sourceSlot'' parameters could be slots that are simply looked up, or additional databases opened with SECMOD_OpenUserDB().
logReturns:
pwdataThe function returns one of these values:* If successful, SECSuccess.* If one or more entries failed to merge, return SECFailure. PORT_SetError() is set to the value of the last failing entry. All the failed entries are returned in the variable ''log''.
Example:
<pre>
439
edits

Navigation menu