* [PATCH nf] netfilter: nft_socket: remove WARN_ON_ONCE with giant cgroup tree
@ 2025-08-07 10:05 Pablo Neira Ayuso
2025-08-07 10:37 ` Florian Westphal
0 siblings, 1 reply; 3+ messages in thread
From: Pablo Neira Ayuso @ 2025-08-07 10:05 UTC (permalink / raw)
To: netfilter-devel
syzbot managed to reach this WARN_ON_ONCE with a giant cgroup tree,
remove it.
WARNING: CPU: 0 PID: 5853 at net/netfilter/nft_socket.c:220 nft_socket_init+0x2f4/0x3d0 net/netfilter/nft_socket.c:220
Reported-by: syzbot+a225fea35d7baf8dbdc3@syzkaller.appspotmail.com
Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
---
net/netfilter/nft_socket.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/net/netfilter/nft_socket.c b/net/netfilter/nft_socket.c
index 35d0409b0095..36affbb697c2 100644
--- a/net/netfilter/nft_socket.c
+++ b/net/netfilter/nft_socket.c
@@ -217,7 +217,7 @@ static int nft_socket_init(const struct nft_ctx *ctx,
level += err;
/* Implies a giant cgroup tree */
- if (WARN_ON_ONCE(level > 255))
+ if (level > 255)
return -EOPNOTSUPP;
priv->level = level;
--
2.30.2
^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: [PATCH nf] netfilter: nft_socket: remove WARN_ON_ONCE with giant cgroup tree
2025-08-07 10:05 [PATCH nf] netfilter: nft_socket: remove WARN_ON_ONCE with giant cgroup tree Pablo Neira Ayuso
@ 2025-08-07 10:37 ` Florian Westphal
2025-08-07 11:14 ` Pablo Neira Ayuso
0 siblings, 1 reply; 3+ messages in thread
From: Florian Westphal @ 2025-08-07 10:37 UTC (permalink / raw)
To: Pablo Neira Ayuso; +Cc: netfilter-devel
Pablo Neira Ayuso <pablo@netfilter.org> wrote:
> syzbot managed to reach this WARN_ON_ONCE with a giant cgroup tree,
> remove it.
>
> WARNING: CPU: 0 PID: 5853 at net/netfilter/nft_socket.c:220 nft_socket_init+0x2f4/0x3d0 net/netfilter/nft_socket.c:220
I looked at the repro and as far as i could see it just passes
a large NFTA_SOCKET_LEVEL attribute value.
I'd propose:
syzbot managed to reach this WARN_ON_ONCE by passing a huge level
value, remove it.
Patch is correct though.
Acked-by: Florian Westphal <fw@strlen.de>
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [PATCH nf] netfilter: nft_socket: remove WARN_ON_ONCE with giant cgroup tree
2025-08-07 10:37 ` Florian Westphal
@ 2025-08-07 11:14 ` Pablo Neira Ayuso
0 siblings, 0 replies; 3+ messages in thread
From: Pablo Neira Ayuso @ 2025-08-07 11:14 UTC (permalink / raw)
To: Florian Westphal; +Cc: netfilter-devel
On Thu, Aug 07, 2025 at 12:37:08PM +0200, Florian Westphal wrote:
> Pablo Neira Ayuso <pablo@netfilter.org> wrote:
> > syzbot managed to reach this WARN_ON_ONCE with a giant cgroup tree,
> > remove it.
> >
> > WARNING: CPU: 0 PID: 5853 at net/netfilter/nft_socket.c:220 nft_socket_init+0x2f4/0x3d0 net/netfilter/nft_socket.c:220
>
> I looked at the repro and as far as i could see it just passes
> a large NFTA_SOCKET_LEVEL attribute value.
>
> I'd propose:
>
> syzbot managed to reach this WARN_ON_ONCE by passing a huge level
> value, remove it.
I guess it is both, huge level value and giant cgroup tree.
Anyway, I take this description.
> Patch is correct though.
>
> Acked-by: Florian Westphal <fw@strlen.de>
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2025-08-07 11:14 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-08-07 10:05 [PATCH nf] netfilter: nft_socket: remove WARN_ON_ONCE with giant cgroup tree Pablo Neira Ayuso
2025-08-07 10:37 ` Florian Westphal
2025-08-07 11:14 ` Pablo Neira Ayuso
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).