In the Linux kernel, the following vulnerability has been resolved:
netdevsim: use condresched() in nsimdevtrapreport_work()
I am still seeing many syzbot reports hinting that syzbot might fool nsimdevtrapreportwork() with hundreds of ports [1]
Lets use condresched(), and systemunboundwq instead of implicit systemwq.
[1] INFO: task syz-executor:20633 blocked for more than 143 seconds. Not tainted 6.12.0-rc2-syzkaller-00205-g1d227fcc7222 #0 "echo 0 > /proc/sys/kernel/hungtasktimeoutsecs" disables this message. task:syz-executor state:D stack:25856 pid:20633 tgid:20633 ppid:1 flags:0x00004006 ... NMI backtrace for cpu 1 CPU: 1 UID: 0 PID: 16760 Comm: kworker/1:0 Not tainted 6.12.0-rc2-syzkaller-00205-g1d227fcc7222 #0 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 09/13/2024 Workqueue: events nsimdevtrapreportwork RIP: 0010:sanitizercovtracepc+0x0/0x70 kernel/kcov.c:210 Code: 89 fb e8 23 00 00 00 48 8b 3d 04 fb 9c 0c 48 89 de 5b e9 c3 c7 5d 00 0f 1f 00 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 <f3> 0f 1e fa 48 8b 04 24 65 48 8b 0c 25 c0 d7 03 00 65 8b 15 60 f0 RSP: 0018:ffffc90000a187e8 EFLAGS: 00000246 RAX: 0000000000000100 RBX: ffffc90000a188e0 RCX: ffff888027d3bc00 RDX: ffff888027d3bc00 RSI: 0000000000000000 RDI: 0000000000000000 RBP: ffff88804a2e6000 R08: ffffffff8a4bc495 R09: ffffffff89da3577 R10: 0000000000000004 R11: ffffffff8a4bc2b0 R12: dffffc0000000000 R13: ffff88806573b503 R14: dffffc0000000000 R15: ffff8880663cca00 FS: 0000000000000000(0000) GS:ffff8880b8700000(0000) knlGS:0000000000000000 CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033 CR2: 00007fc90a747f98 CR3: 000000000e734000 CR4: 00000000003526f0 DR0: 0000000000000000 DR1: 000000000000002b DR2: 0000000000000000 DR3: 0000000000000000 DR6: 00000000ffff0ff0 DR7: 0000000000000400 Call Trace: <NMI> </NMI> <TASK> _localbhenableip+0x1bb/0x200 kernel/softirq.c:382 spinunlockbh include/linux/spinlock.h:396 [inline] nsimdevtrapreport drivers/net/netdevsim/dev.c:820 [inline] nsimdevtrapreportwork+0x75d/0xaa0 drivers/net/netdevsim/dev.c:850 processonework kernel/workqueue.c:3229 [inline] processscheduledworks+0xa63/0x1850 kernel/workqueue.c:3310 workerthread+0x870/0xd30 kernel/workqueue.c:3391 kthread+0x2f0/0x390 kernel/kthread.c:389 retfromfork+0x4b/0x80 arch/x86/kernel/process.c:147 retfromforkasm+0x1a/0x30 arch/x86/entry/entry64.S:244 </TASK>
[
{
"id": "CVE-2024-50155-154bacf3",
"deprecated": false,
"signature_version": "v1",
"signature_type": "Line",
"digest": {
"line_hashes": [
"307925435560810766540969463292883237536",
"87509942967054109196981944981036072823",
"106173198394962867752966044500214019941",
"212892677131466458688147410141151711245",
"287095868830722891500060926481182213226",
"312970336342193375967676674513739729512",
"159522478735306309146891089866916797807",
"149740707725786980320965356381238621305",
"271565343789074000222191231884876044360",
"18843643960138663747724402766469745187",
"49062492321492827722244680034982161661",
"164042809546958004531467552033833528589",
"24974361576200623229255132685519034514",
"212624464307948492800693841936252363341",
"86657138833713092066173161887633069166",
"77021985013021109208894188475838752642",
"23077725811939567611802764925711360692"
],
"threshold": 0.9
},
"target": {
"file": "drivers/net/netdevsim/dev.c"
},
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@a1494d532e28598bde7a5544892ef9c7dbfafa93"
},
{
"id": "CVE-2024-50155-215886da",
"deprecated": false,
"signature_version": "v1",
"signature_type": "Function",
"digest": {
"function_hash": "334281818197897393213546861034139863849",
"length": 536.0
},
"target": {
"file": "drivers/net/netdevsim/dev.c",
"function": "nsim_dev_trap_report_work"
},
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@a1494d532e28598bde7a5544892ef9c7dbfafa93"
},
{
"id": "CVE-2024-50155-39a0d739",
"deprecated": false,
"signature_version": "v1",
"signature_type": "Line",
"digest": {
"line_hashes": [
"307925435560810766540969463292883237536",
"87509942967054109196981944981036072823",
"106173198394962867752966044500214019941",
"212892677131466458688147410141151711245",
"287095868830722891500060926481182213226",
"312970336342193375967676674513739729512",
"159522478735306309146891089866916797807",
"149740707725786980320965356381238621305",
"271565343789074000222191231884876044360",
"18843643960138663747724402766469745187",
"49062492321492827722244680034982161661",
"164042809546958004531467552033833528589",
"24974361576200623229255132685519034514",
"212624464307948492800693841936252363341",
"86657138833713092066173161887633069166",
"77021985013021109208894188475838752642",
"23077725811939567611802764925711360692"
],
"threshold": 0.9
},
"target": {
"file": "drivers/net/netdevsim/dev.c"
},
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@681ce79ab6fba2f8d1c5ea60239f0086baebd0d3"
},
{
"id": "CVE-2024-50155-486b2f71",
"deprecated": false,
"signature_version": "v1",
"signature_type": "Line",
"digest": {
"line_hashes": [
"307925435560810766540969463292883237536",
"87509942967054109196981944981036072823",
"106173198394962867752966044500214019941",
"212892677131466458688147410141151711245",
"287095868830722891500060926481182213226",
"312970336342193375967676674513739729512",
"159522478735306309146891089866916797807",
"149740707725786980320965356381238621305",
"271565343789074000222191231884876044360",
"18843643960138663747724402766469745187",
"49062492321492827722244680034982161661",
"164042809546958004531467552033833528589",
"24974361576200623229255132685519034514",
"212624464307948492800693841936252363341",
"86657138833713092066173161887633069166",
"77021985013021109208894188475838752642",
"23077725811939567611802764925711360692"
],
"threshold": 0.9
},
"target": {
"file": "drivers/net/netdevsim/dev.c"
},
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@24973f4b64f93232a48fe78029385de762a2418d"
},
{
"id": "CVE-2024-50155-5d4fddd6",
"deprecated": false,
"signature_version": "v1",
"signature_type": "Line",
"digest": {
"line_hashes": [
"307925435560810766540969463292883237536",
"87509942967054109196981944981036072823",
"106173198394962867752966044500214019941",
"212892677131466458688147410141151711245",
"287095868830722891500060926481182213226",
"312970336342193375967676674513739729512",
"159522478735306309146891089866916797807",
"149740707725786980320965356381238621305",
"271565343789074000222191231884876044360",
"18843643960138663747724402766469745187",
"49062492321492827722244680034982161661",
"164042809546958004531467552033833528589",
"24974361576200623229255132685519034514",
"212624464307948492800693841936252363341",
"86657138833713092066173161887633069166",
"77021985013021109208894188475838752642",
"23077725811939567611802764925711360692"
],
"threshold": 0.9
},
"target": {
"file": "drivers/net/netdevsim/dev.c"
},
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@32f054f93937b548c61b3bf57d8f4aefc50f3b16"
},
{
"id": "CVE-2024-50155-5e852cf7",
"deprecated": false,
"signature_version": "v1",
"signature_type": "Function",
"digest": {
"function_hash": "334281818197897393213546861034139863849",
"length": 536.0
},
"target": {
"file": "drivers/net/netdevsim/dev.c",
"function": "nsim_dev_trap_report_work"
},
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@681ce79ab6fba2f8d1c5ea60239f0086baebd0d3"
},
{
"id": "CVE-2024-50155-7dfbefb4",
"deprecated": false,
"signature_version": "v1",
"signature_type": "Function",
"digest": {
"function_hash": "334281818197897393213546861034139863849",
"length": 536.0
},
"target": {
"file": "drivers/net/netdevsim/dev.c",
"function": "nsim_dev_trap_report_work"
},
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@32f054f93937b548c61b3bf57d8f4aefc50f3b16"
},
{
"id": "CVE-2024-50155-8104b950",
"deprecated": false,
"signature_version": "v1",
"signature_type": "Function",
"digest": {
"function_hash": "268548023390347157638489580699083206066",
"length": 1615.0
},
"target": {
"file": "drivers/net/netdevsim/dev.c",
"function": "nsim_dev_traps_init"
},
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@32f054f93937b548c61b3bf57d8f4aefc50f3b16"
},
{
"id": "CVE-2024-50155-95f947c7",
"deprecated": false,
"signature_version": "v1",
"signature_type": "Function",
"digest": {
"function_hash": "334281818197897393213546861034139863849",
"length": 536.0
},
"target": {
"file": "drivers/net/netdevsim/dev.c",
"function": "nsim_dev_trap_report_work"
},
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@24973f4b64f93232a48fe78029385de762a2418d"
},
{
"id": "CVE-2024-50155-cb9bcf62",
"deprecated": false,
"signature_version": "v1",
"signature_type": "Function",
"digest": {
"function_hash": "268548023390347157638489580699083206066",
"length": 1615.0
},
"target": {
"file": "drivers/net/netdevsim/dev.c",
"function": "nsim_dev_traps_init"
},
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@681ce79ab6fba2f8d1c5ea60239f0086baebd0d3"
},
{
"id": "CVE-2024-50155-fe568221",
"deprecated": false,
"signature_version": "v1",
"signature_type": "Function",
"digest": {
"function_hash": "268548023390347157638489580699083206066",
"length": 1615.0
},
"target": {
"file": "drivers/net/netdevsim/dev.c",
"function": "nsim_dev_traps_init"
},
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@a1494d532e28598bde7a5544892ef9c7dbfafa93"
},
{
"id": "CVE-2024-50155-ffa1c9ea",
"deprecated": false,
"signature_version": "v1",
"signature_type": "Function",
"digest": {
"function_hash": "268548023390347157638489580699083206066",
"length": 1615.0
},
"target": {
"file": "drivers/net/netdevsim/dev.c",
"function": "nsim_dev_traps_init"
},
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@24973f4b64f93232a48fe78029385de762a2418d"
}
]