From 7df1be9d3ef7f86c1e39df4a8a6cd0b203e2dd8b Mon Sep 17 00:00:00 2001 From: bol-van Date: Fri, 25 Mar 2022 20:22:15 +0300 Subject: [PATCH] nfqws: prevent out-of-bound access --- nfq/protocol.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/nfq/protocol.c b/nfq/protocol.c index de65f2a..26baea9 100644 --- a/nfq/protocol.c +++ b/nfq/protocol.c @@ -462,7 +462,7 @@ bool QUICDefragCrypto(const uint8_t *clean,size_t clean_len, uint8_t *defrag,siz if (pos>=clean_len) return false; - if ((pos+tvb_get_size(clean[pos])>clean_len)) return false; + if ((pos+tvb_get_size(clean[pos])>=clean_len)) return false; pos += tvb_get_varint(clean+pos, &offset); if ((pos+tvb_get_size(clean[pos])>clean_len)) return false;