From 1e048e0321383d27e6c8005e31b06c2cd2b2bdf6 Mon Sep 17 00:00:00 2001 From: "wtchang%redhat.com" Date: Mon, 31 Jul 2006 18:31:07 +0000 Subject: [PATCH] Bugzilla Bug 336509: put the FIPS token in the Error state only when the continuous RNG test fails. git-svn-id: svn://10.0.0.236/trunk@206178 18797224-902f-48f8-a5cc-f745e15eee43 --- mozilla/security/nss/lib/softoken/pkcs11.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/mozilla/security/nss/lib/softoken/pkcs11.c b/mozilla/security/nss/lib/softoken/pkcs11.c index 5e63f746370..8249385836e 100644 --- a/mozilla/security/nss/lib/softoken/pkcs11.c +++ b/mozilla/security/nss/lib/softoken/pkcs11.c @@ -1537,8 +1537,10 @@ sftk_GenerateSecretCKA_ID(NSSLOWKEYDBHandle *handle, SECItem *id, char *label) (++retries <= SFTK_KEY_MAX_RETRIES)); if ((rv != SECSuccess) || (retries > SFTK_KEY_MAX_RETRIES)) { + if (rv != SECSuccess) { + sftk_fatalError = PR_TRUE; + } crv = CKR_DEVICE_ERROR; /* random number generator is bad */ - sftk_fatalError = PR_TRUE; PORT_Free(id->data); id->data = NULL; id->len = 0;