summaryrefslogtreecommitdiffstats
path: root/crypto/asn1
diff options
context:
space:
mode:
authorPauli <pauli@openssl.org>2021-04-06 10:23:12 +1000
committerPauli <pauli@openssl.org>2021-04-07 23:29:10 +1000
commitccf19c23c03ff0355d5008f73b77a0e22ee8ca8c (patch)
tree29d29a4f51895fbc17b6c523290453d669f546c4 /crypto/asn1
parent44e82b813fbec93664fa355a65024a56f6eb82d7 (diff)
Disallow ASN.1 enumerated types to be treated as strings.
They are actually integers. Problem reported by: Scott McPeak <scott.g.mcpeak@gmail.com> Reviewed-by: Tomas Mraz <tomas@openssl.org> (Merged from https://github.com/openssl/openssl/pull/14774)
Diffstat (limited to 'crypto/asn1')
-rw-r--r--crypto/asn1/tasn_dec.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/crypto/asn1/tasn_dec.c b/crypto/asn1/tasn_dec.c
index 0987c2ece3..00a76cc825 100644
--- a/crypto/asn1/tasn_dec.c
+++ b/crypto/asn1/tasn_dec.c
@@ -66,7 +66,7 @@ static const unsigned long tag2bit[32] = {
/* tags 4- 7 */
B_ASN1_OCTET_STRING, 0, 0, B_ASN1_UNKNOWN,
/* tags 8-11 */
- B_ASN1_UNKNOWN, B_ASN1_UNKNOWN, B_ASN1_UNKNOWN, B_ASN1_UNKNOWN,
+ B_ASN1_UNKNOWN, B_ASN1_UNKNOWN, 0, B_ASN1_UNKNOWN,
/* tags 12-15 */
B_ASN1_UTF8STRING, B_ASN1_UNKNOWN, B_ASN1_UNKNOWN, B_ASN1_UNKNOWN,
/* tags 16-19 */