diff options
Diffstat (limited to 'security/nss/lib/certdb/certv3.c')
-rw-r--r-- | security/nss/lib/certdb/certv3.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/security/nss/lib/certdb/certv3.c b/security/nss/lib/certdb/certv3.c index d27fc1ba0d..f00b88f1d7 100644 --- a/security/nss/lib/certdb/certv3.c +++ b/security/nss/lib/certdb/certv3.c @@ -213,7 +213,7 @@ CERT_CheckCertUsage(CERTCertificate *cert, unsigned char usage) if (rv == SECFailure) { rv = (PORT_GetError() == SEC_ERROR_EXTENSION_NOT_FOUND) ? SECSuccess : SECFailure; - } else if (!keyUsage.data || !(keyUsage.data[0] & usage)) { + } else if (!keyUsage.data || !keyUsage.len || !(keyUsage.data[0] & usage)) { PORT_SetError(SEC_ERROR_CERT_USAGES_INVALID); rv = SECFailure; } |