Skip to content
Permalink
Browse files

Fixed out of bounds access in ASN.1 Octet string

Credit to OSS-Fuzz
  • Loading branch information...
frankmorgner committed Aug 27, 2019
1 parent 412a614 commit a3fc7693f3a035a8a7921cffb98432944bb42740
Showing with 1 addition and 1 deletion.
  1. +1 −1 src/libopensc/asn1.c
@@ -1469,7 +1469,7 @@ static int asn1_decode_entry(sc_context_t *ctx,struct sc_asn1_entry *entry,

/* Strip off padding zero */
if ((entry->flags & SC_ASN1_UNSIGNED)
&& obj[0] == 0x00 && objlen > 1) {
&& objlen > 1 && obj[0] == 0x00) {
objlen--;
obj++;
}

0 comments on commit a3fc769

Please sign in to comment.
You can’t perform that action at this time.