]> git.karo-electronics.de Git - karo-tx-linux.git/commit
netfilter: xt_limit: have r->cost != 0 case work
authorJan Engelhardt <jengelh@inai.de>
Fri, 21 Sep 2012 22:26:52 +0000 (22:26 +0000)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Sun, 21 Oct 2012 16:28:00 +0000 (09:28 -0700)
commit7ae3bb7d050f8c7e3ef46c830968f3bb5ca2e232
tree02f3770d015be5a50890e3d3354d855c238d284d
parentaee054fb840f6fca8067a42f44df0e2a22e0378c
netfilter: xt_limit: have r->cost != 0 case work

commit 82e6bfe2fbc4d48852114c4f979137cd5bf1d1a8 upstream.

Commit v2.6.19-rc1~1272^2~41 tells us that r->cost != 0 can happen when
a running state is saved to userspace and then reinstated from there.

Make sure that private xt_limit area is initialized with correct values.
Otherwise, random matchings due to use of uninitialized memory.

Signed-off-by: Jan Engelhardt <jengelh@inai.de>
Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
Acked-by: David Miller <davem@davemloft.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
net/netfilter/xt_limit.c