Discussion:
NSS_NoDB_Init returns failure code -8192
Abhishek Rahirikar
2009-08-14 12:27:52 UTC
Permalink
Hello:

I am using NSS_NoDB_Init() function to initialize the NSS (I have used
PR_Init() before this call as said in the documentation).

After passing NULL as the argument, I am getting SECFailure as return value.

PR_GetError returned value -8192 which says : An I/O error occurred during
authentication; or an error occurred during crypto operation (other than
signature verification).

So I tried to debug for the problem. Here is more information that I found:

In the NSS_Init

SECMODModule *module =
SECMOD_LoadModule(moduleSpec,NULL,PR_TRUE);

After this call the module have a non-NULL value. But "module->loaded" is
false hence I think the code returns SECFailure.

The string moduleSpec for me is: (I think should be default for all
NSS_NoDB_Init calls)

name="NSS Internal Module" parameters="configdir='' certPrefix=''
keyPrefix='' secmod=''
flags=readOnly,noCertDB,noModDB,forceOpen,optimizeSpace updatedir=''
updateCertPrefix='' updateKeyPrefix='' updateid='' updateTokenDescription=''
" NSS="flags=internal,moduleDB,moduleDBOnly,critical"


Can anyone please point me towards what may have gone wrong? Which points
need to be checked to get to the solution.
I am stuck with the problem for past 2 days.

Thanks.
-Abhishek
--
dev-tech-crypto mailing list
dev-tech-***@lists.mozilla.org
https://lists.mozilla.org/listinfo/dev-tech-crypto
Wan-Teh Chang
2009-08-14 12:56:05 UTC
Permalink
Post by Abhishek Rahirikar
I am using NSS_NoDB_Init() function to initialize the NSS (I have used
PR_Init() before this call as said in the documentation).
After passing NULL as the argument, I am getting SECFailure as return value.
PR_GetError returned value -8192 which says : An I/O error occurred during
authentication; or an error occurred during crypto operation (other than
signature verification).
Hi,

Set a breakpoint in NSC_Initialize. When the breakpoint is hit,
step inside nsc_CommonInitialize and find out which function
call fails. In particular, see if RNG_RNGInit fails.

I guess your libfreebl3.so (or freebl3.dll) library is not installed
properly.

What version of NSS are you using?

Wan-Teh
--
dev-tech-crypto mailing list
dev-tech-***@lists.mozilla.org
https://lists.mozilla.org/listinfo/dev-tech-crypto
Loading...