mirror of
https://github.com/wolfSSL/wolfssl.git
synced 2025-07-29 18:27:29 +02:00
check attrib->value and attrib->valueSz before use
This commit is contained in:
@ -3447,6 +3447,9 @@ static int wc_PKCS7_VerifyContentMessageDigest(PKCS7* pkcs7,
|
||||
}
|
||||
|
||||
/* advance past attrib->value ASN.1 header and length */
|
||||
if (attrib->value == NULL || attrib->valueSz == 0)
|
||||
return ASN_PARSE_E;
|
||||
|
||||
if (attrib->value[idx++] != ASN_OCTET_STRING)
|
||||
return ASN_PARSE_E;
|
||||
|
||||
|
Reference in New Issue
Block a user