summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authornelson%bolyard.com <devnull@localhost>2007-12-12 03:22:14 +0000
committernelson%bolyard.com <devnull@localhost>2007-12-12 03:22:14 +0000
commitba4b42eeffaaed746078177e2d36177aceecabae (patch)
tree8aab54b0f2a893dbdfd23f70a786d833d6acffdd
parentfcffed7360cfebf91c7813c9d1de12382f8bd599 (diff)
downloadnss-hg-ba4b42eeffaaed746078177e2d36177aceecabae.tar.gz
Bug 353714: key search functions ignore the nickname argument,
r=rrelyea,julien.pierre
-rw-r--r--security/nss/lib/softoken/pkcs11.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/security/nss/lib/softoken/pkcs11.c b/security/nss/lib/softoken/pkcs11.c
index fbb73622d..7061059ce 100644
--- a/security/nss/lib/softoken/pkcs11.c
+++ b/security/nss/lib/softoken/pkcs11.c
@@ -4476,7 +4476,7 @@ sftk_key_collect(DBT *key, DBT *data, void *arg)
tmpDBKey.type = siBuffer;
PORT_Assert(keyData->keyHandle);
- if (!keyData->strict && keyData->id) {
+ if (!keyData->strict && keyData->id && keyData->id->data) {
SECItem result;
PRBool haveMatch= PR_FALSE;
unsigned char hashKey[SHA1_LENGTH];
@@ -5089,7 +5089,7 @@ sftk_searchTokenList(SFTKSlot *slot, SFTKSearchResults *search,
/* keys */
if (classFlags & (NSC_PRIVATE|NSC_PUBLIC|NSC_KEY)) {
- PRBool mustStrict = ((classFlags & NSC_KEY) != 0) && (name.len != 0);
+ PRBool mustStrict = (name.len != 0);
sftk_searchKeys(slot, &key_id, isLoggedIn, classFlags, search,
mustStrict, pTemplate, ulCount);
}