diff --git a/src/jwe.c b/src/jwe.c index 5d46c51..ddd26e9 100644 --- a/src/jwe.c +++ b/src/jwe.c @@ -2259,7 +2259,7 @@ static void r_jwe_remove_padding(unsigned char * text, size_t * text_len, unsign unsigned char pad = text[(*text_len)-1], i; int pad_ok = 1; - if (pad && pad < (unsigned char)block_size) { + if (pad && pad <= (unsigned char)block_size) { for (i=0; i