diff options
Diffstat (limited to 'src/libsec')
-rw-r--r-- | src/libsec/port/x509.c | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/src/libsec/port/x509.c b/src/libsec/port/x509.c index 60b3d073..2bbf8538 100644 --- a/src/libsec/port/x509.c +++ b/src/libsec/port/x509.c @@ -2077,8 +2077,7 @@ digest_certinfo(Bytes *cert, DigestFun digestfun, uchar *digest) if(tag_decode(&p, pend, &tag, &isconstr) != ASN_OK || tag.class != Universal || tag.num != SEQUENCE || length_decode(&p, pend, &length) != ASN_OK || - p+length > pend || - p+length < p) + length > pend - p) return; info = p; if(ber_decode(&p, pend, &elem) != ASN_OK || elem.tag.num != SEQUENCE) |