diff options
author | David S. Miller <davem@davemloft.net> | 2021-06-23 12:31:28 -0700 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2021-06-23 12:31:28 -0700 |
commit | a7b62112f0abf58a7f6d2bdfef40b637a4a1c4d4 (patch) | |
tree | 72f7b2ce595c5c4b1c49b12eb37e8c21564ba6de /net/netfilter/nfnetlink_hook.c | |
parent | 0a36a75c6818800c67057458376e99b5f77c2a1f (diff) | |
parent | 24610ed80df65a564d6165d15505a950d05f9f5a (diff) | |
download | linux-stable-a7b62112f0abf58a7f6d2bdfef40b637a4a1c4d4.tar.gz linux-stable-a7b62112f0abf58a7f6d2bdfef40b637a4a1c4d4.tar.bz2 linux-stable-a7b62112f0abf58a7f6d2bdfef40b637a4a1c4d4.zip |
Merge git://git.kernel.org/pub/scm/linux/kernel/git/pablo/nf-next
Pablo Neira Ayuso says:
====================
Netfilter updates for net-next
The following patchset contains Netfilter updates for net-next:
1) Skip non-SCTP packets in the new SCTP chunk support for nft_exthdr,
from Phil Sutter.
2) Simplify TCP option sanity check for TCP packets, also from Phil.
3) Add a new expression to store when the rule has been used last time.
4) Pass the hook state object to log function, from Florian Westphal.
5) Document the new sysctl knobs to tune the flowtable timeouts,
from Oz Shlomo.
6) Fix snprintf error check in the new nfnetlink_hook infrastructure,
from Dan Carpenter.
====================
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/netfilter/nfnetlink_hook.c')
-rw-r--r-- | net/netfilter/nfnetlink_hook.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/net/netfilter/nfnetlink_hook.c b/net/netfilter/nfnetlink_hook.c index 58fda6ac663b..50b4e3c9347a 100644 --- a/net/netfilter/nfnetlink_hook.c +++ b/net/netfilter/nfnetlink_hook.c @@ -126,8 +126,10 @@ static int nfnl_hook_dump_one(struct sk_buff *nlskb, #ifdef CONFIG_KALLSYMS ret = snprintf(sym, sizeof(sym), "%ps", ops->hook); - if (ret < 0 || ret > (int)sizeof(sym)) + if (ret >= sizeof(sym)) { + ret = -EINVAL; goto nla_put_failure; + } module_name = strstr(sym, " ["); if (module_name) { |