[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <20250520162617.35163-1-kuniyu@amazon.com>
Date: Tue, 20 May 2025 09:25:30 -0700
From: Kuniyuki Iwashima <kuniyu@...zon.com>
To: <y04609127@...il.com>
CC: <davem@...emloft.net>, <edumazet@...gle.com>, <horms@...nel.org>,
<kuba@...nel.org>, <linux-kernel@...r.kernel.org>, <netdev@...r.kernel.org>,
<pabeni@...hat.com>
Subject: Re: [BUG] INFO: rcu detected stall in unix_seqpacket_sendmsg
From: Guoyu Yin <y04609127@...il.com>
Date: Mon, 19 May 2025 15:32:09 +0800
> Hi,
>
> I found a crash related to unix_seqpacket_sendmsg. The kernel reports
> an RCU stall in unix_seqpacket_sendmsg.
>
> From my analysis, the stall occurs when user space calls
> unix_seqpacket_sendmsg (via sendfile or similar syscalls) with crafted
> parameters, causing the kernel to enter unix_dgram_sendmsg and
> eventually get stuck in sock_alloc_send_pskb or related memory
> allocation routines. This leads to long-lasting blocking in memory
> allocation, triggering an RCU stall.
>
> The root cause seems to be insufficient validation of the message
> length or socket state in unix_seqpacket_sendmsg/unix_dgram_sendmsg,
> allowing user space to trigger resource exhaustion or deadlock
> scenarios.
>
> I recommend investigating:
> The behavior of Unix domain socket send logic (unix_dgram_sendmsg and
> unix_seqpacket_sendmsg) under abnormal conditions.
>
> This can be reproduced on:
>
> HEAD commit:
>
> fac04efc5c793dccbd07e2d59af9f90b7fc0dca4
>
> report: https://pastebin.com/raw/JJyvCmCn
I don't think this is related to AF_UNIX.
>
> console output : https://pastebin.com/raw/TUPGLzqh
>
> kernel config: https://pastebin.com/raw/zrj9jd1V
>
> C reproducer : https://pastebin.com/raw/ZzAVZ1ua
You may want to slim this down to a minimal repro.
Also, please make sure you run syzkaller on the latest kernel or
the latest LTS kernel.
> [ 67.058143] CPU: 2 UID: 0 PID: 4456 Comm: syz-executor.1 Not tainted 6.13.0-rc5-00012-g0bc21e701a6f #2
Powered by blists - more mailing lists