We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 3fef07c commit 40e4a66Copy full SHA for 40e4a66
1 file changed
src/pk/asn1/der/bit/der_decode_raw_bit_string.c
@@ -78,7 +78,7 @@ int der_decode_raw_bit_string(const unsigned char *in, unsigned long inlen,
78
blen = ((dlen - 1) << 3) - (in[x++] & 7);
79
80
/* too many bits? */
81
- if (blen/8 > *outlen) {
+ if ((blen + 7)/8 > *outlen) {
82
*outlen = blen;
83
return CRYPT_BUFFER_OVERFLOW;
84
}
0 commit comments