diff options
author | nelson%bolyard.com <devnull@localhost> | 2009-03-31 22:40:18 +0000 |
---|---|---|
committer | nelson%bolyard.com <devnull@localhost> | 2009-03-31 22:40:18 +0000 |
commit | 42047c9a9b60e6d6ed2387d47ac4c3059c507424 (patch) | |
tree | 257cc5d1606af1db5e5adac56f00295b89dc9fc3 | |
parent | f31ac0d86fd0d7227e7217a7bdbb0de8478beb4a (diff) | |
download | nss-hg-42047c9a9b60e6d6ed2387d47ac4c3059c507424.tar.gz |
Bug 480280: Add missing SEC_ASN1_GET macro invocations. r=rrelyea
-rw-r--r-- | security/nss/lib/softoken/legacydb/lgattr.c | 3 | ||||
-rw-r--r-- | security/nss/lib/softoken/legacydb/lgcreate.c | 3 | ||||
-rw-r--r-- | security/nss/lib/softoken/pkcs11.c | 3 | ||||
-rw-r--r-- | security/nss/lib/softoken/pkcs11c.c | 6 |
4 files changed, 10 insertions, 5 deletions
diff --git a/security/nss/lib/softoken/legacydb/lgattr.c b/security/nss/lib/softoken/legacydb/lgattr.c index 8c53ed6ab..344644888 100644 --- a/security/nss/lib/softoken/legacydb/lgattr.c +++ b/security/nss/lib/softoken/legacydb/lgattr.c @@ -617,7 +617,8 @@ lg_FindECPublicKeyAttribute(NSSLOWKEYPublicKey *key, CK_ATTRIBUTE_TYPE type, key->u.ec.publicValue.len); } else { SECItem *pubValue = SEC_ASN1EncodeItem(NULL, NULL, - &(key->u.ec.publicValue), SEC_OctetStringTemplate); + &(key->u.ec.publicValue), + SEC_ASN1_GET(SEC_OctetStringTemplate)); CK_RV crv; if (!pubValue) { return CKR_HOST_MEMORY; diff --git a/security/nss/lib/softoken/legacydb/lgcreate.c b/security/nss/lib/softoken/legacydb/lgcreate.c index d4fcca69e..ab6c652f7 100644 --- a/security/nss/lib/softoken/legacydb/lgcreate.c +++ b/security/nss/lib/softoken/legacydb/lgcreate.c @@ -474,7 +474,8 @@ lg_createPublicKeyObject(SDB *sdb, CK_KEY_TYPE key_type, goto done; } rv= SEC_QuickDERDecodeItem(arena, &pubKey2Space, - SEC_OctetStringTemplate, pubKey); + SEC_ASN1_GET(SEC_OctetStringTemplate), + pubKey); if (rv != SECSuccess) { /* decode didn't work, just try the pubKey */ PORT_FreeArena(arena, PR_FALSE); diff --git a/security/nss/lib/softoken/pkcs11.c b/security/nss/lib/softoken/pkcs11.c index 71eaefb6e..c5c2a8e2b 100644 --- a/security/nss/lib/softoken/pkcs11.c +++ b/security/nss/lib/softoken/pkcs11.c @@ -1659,7 +1659,8 @@ NSSLOWKEYPublicKey *sftk_GetPubKey(SFTKObject *object,CK_KEY_TYPE key_type, SECStatus rv; rv = SEC_QuickDERDecodeItem(arena, &publicValue, - SEC_OctetStringTemplate, &pubKey->u.ec.publicValue); + SEC_ASN1_GET(SEC_OctetStringTemplate), + &pubKey->u.ec.publicValue); /* nope, didn't decode correctly */ if ((rv != SECSuccess) || (publicValue.data[0] != EC_POINT_FORM_UNCOMPRESSED) diff --git a/security/nss/lib/softoken/pkcs11c.c b/security/nss/lib/softoken/pkcs11c.c index 49f00109f..d45c6ff5f 100644 --- a/security/nss/lib/softoken/pkcs11c.c +++ b/security/nss/lib/softoken/pkcs11c.c @@ -4022,7 +4022,8 @@ dhgn_done: sftk_item_expand(&ecPriv->publicValue)); } else { SECItem *pubValue = SEC_ASN1EncodeItem(NULL, NULL, - &ecPriv->publicValue, SEC_OctetStringTemplate); + &ecPriv->publicValue, + SEC_ASN1_GET(SEC_OctetStringTemplate)); if (!pubValue) { crv = CKR_ARGUMENTS_BAD; goto ecgn_done; @@ -5899,7 +5900,8 @@ key_and_mac_derive_fail: } rv = SEC_QuickDERDecodeItem(arena, &newPoint, - SEC_OctetStringTemplate, &ecPoint); + SEC_ASN1_GET(SEC_OctetStringTemplate), + &ecPoint); if (rv != SECSuccess) { goto ec_loser; } |