mirror of
https://github.com/vanhoefm/fragattacks.git
synced 2025-01-29 08:14:02 -05:00
X.509: Fix v3 parsing with issuerUniqueID/subjectUniqueID present
The current position pointer was not updated when issuerUniqueID or subjectUniqueID were present. This could result in extensions being ignored. Signed-off-by: Jouni Malinen <j@w1.fi>
This commit is contained in:
parent
2e3f286253
commit
144f10446a
@ -1348,7 +1348,8 @@ static int x509_parse_tbs_certificate(const u8 *buf, size_t len,
|
||||
wpa_printf(MSG_DEBUG, "X509: issuerUniqueID");
|
||||
/* TODO: parse UniqueIdentifier ::= BIT STRING */
|
||||
|
||||
if (hdr.payload + hdr.length == end)
|
||||
pos = hdr.payload + hdr.length;
|
||||
if (pos == end)
|
||||
return 0;
|
||||
|
||||
if (asn1_get_next(pos, end - pos, &hdr) < 0 ||
|
||||
@ -1366,7 +1367,8 @@ static int x509_parse_tbs_certificate(const u8 *buf, size_t len,
|
||||
wpa_printf(MSG_DEBUG, "X509: subjectUniqueID");
|
||||
/* TODO: parse UniqueIdentifier ::= BIT STRING */
|
||||
|
||||
if (hdr.payload + hdr.length == end)
|
||||
pos = hdr.payload + hdr.length;
|
||||
if (pos == end)
|
||||
return 0;
|
||||
|
||||
if (asn1_get_next(pos, end - pos, &hdr) < 0 ||
|
||||
|
Loading…
Reference in New Issue
Block a user