summaryrefslogtreecommitdiff
path: root/net
diff options
context:
space:
mode:
authorEric Sesterhenn <eric.sesterhenn@x41-dsec.de>2017-10-09 07:01:14 +0200
committerPablo Neira Ayuso <pablo@netfilter.org>2017-10-24 18:29:15 +0200
commite8daf27c2fea38e16a791780952aa5dff1c409fe (patch)
treeb4620670545b79f1f4861f1d46abe2a70266b024 /net
parentce49480dba8666cba0106e8e31a942c9ce4c438a (diff)
netfilter: nf_ct_h323: Out Of Bound Read in Netfilter Conntrack
Add missing counter decrement to prevent out of bounds memory read. Signed-off-by: Eric Sesterhenn <eric.sesterhenn@x41-dsec.de> Acked-by: Florian Westphal <fw@strlen.de> Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
Diffstat (limited to 'net')
-rw-r--r--net/netfilter/nf_conntrack_h323_asn1.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/net/netfilter/nf_conntrack_h323_asn1.c b/net/netfilter/nf_conntrack_h323_asn1.c
index 7831aa1effc9..cf1bf2605c10 100644
--- a/net/netfilter/nf_conntrack_h323_asn1.c
+++ b/net/netfilter/nf_conntrack_h323_asn1.c
@@ -877,6 +877,7 @@ int DecodeQ931(unsigned char *buf, size_t sz, Q931 *q931)
if (sz < 1)
break;
len = *p++;
+ sz--;
if (sz < len)
break;
p += len;