| 0/0 |
2026/05/25 23:29 |
flow |
assessment-security |
38m
Results: map[DenialOfService:true Explanation:**Analysis of the Bug Report**
**1. Nature of the Bug:**
The bug report indicates an RCU (Read-Copy-Update) stall. The kernel logs show:
* `rcu: INFO: rcu_preempt detected stalls on CPUs/tasks:`
* `rcu: rcu_preempt kthread starved for 3256 jiffies!`
* Repeated warnings: `bridge0: received packet on bridge_slave_0 with own
address as source address`
The stack traces reveal that the CPU is heavily occupied with processing network
packets in the softirq context (`net_rx_action` -> `process_backlog` ->
`br_handle_frame` -> `br_flood` -> `dev_queue_xmit`).
This is a classic Layer 2 network loop (broadcast storm). When interfaces (like
`veth` pairs) are bridged together in a loop without Spanning Tree Protocol
(STP) enabled or properly configured, a single broadcast or multicast packet
will be flooded endlessly across the loop.
Because the packet processing happens in the `NET_RX_SOFTIRQ` context, the
continuous stream of looping packets consumes 100% of the CPU. This softirq
storm starves other normal tasks on the CPU. In this specific crash, a task
(`syz.3.109`) was preempted by a timer interrupt while holding an
`rcu_read_lock()` (during KASAN stack unwinding). Because the CPU was
subsequently overwhelmed by the network softirq storm, the preempted task never
got a chance to resume and release the RCU lock, completely blocking the RCU
grace period and triggering the RCU stall detector.
**2. Security Impact:**
* **Exploitable:** No. This is a resource exhaustion issue (CPU starvation).
There is no memory corruption, use-after-free, or out-of-bounds access involved.
The KASAN frames in the stack trace are merely KASAN performing routine memory
checks during stack unwinding triggered by the RCU stall detector, not a bug
detection.
* **Denial of Service:** Yes. The broadcast storm consumes all available CPU
cycles on the affected cores, leading to RCU stalls, soft lockups, and
eventually a kernel panic (if `panic_on_rcu_stall` or `softlockup_panic` is
enabled).
* **Accessible From Unprivileged Processes:** No. Creating network bridges,
`veth` pairs, and altering their topology requires `CAP_NET_ADMIN` privileges.
* **Accessible From User Namespaces:** Yes. An unprivileged user can create a
new user namespace and a new network namespace. Within this isolated network
namespace, the user gains `CAP_NET_ADMIN` and can freely create bridges, `veth`
interfaces, and intentionally wire them into a loop to trigger the softirq storm
on the host CPU.
* **Network Trigger:** False. While it involves network packets, the root cause
is the malicious/misconfigured local network topology setup. A remote attacker
cannot trigger this unless the administrator has already misconfigured the
network to contain a loop.
**Conclusion:**
This is a local Denial-of-Service (DoS) vulnerability caused by a softirq
broadcast storm. It is not exploitable for privilege escalation or code
execution but can be reliably triggered by an unprivileged user leveraging user
and network namespaces to exhaust host CPU resources. Exploitable:false FilesystemTrigger:false NetworkTrigger:false PeripheralTrigger:false RemoteTrigger:false Unprivileged:false UserNamespace:true VMGuestTrigger:true VMHostTrigger:false]
|
| 1/1 |
2026/05/25 23:29 |
action |
syz-repro-to-c-repro |
0m
Results:
|
| 2/1 |
2026/05/25 23:29 |
action |
kernel-checkouter |
0m
Results: map[KernelSrc:/app/workdir/cache/src/74c832176fe15c88a2a67daecb81ddc348e5a912]
|
| 3/1 |
2026/05/25 23:29 |
action |
kernel-builder |
23m
Results: map[KernelObj:/app/workdir/cache/build/a33b9eface1da6ad0df8ab2b519692487438bfae]
|
| 4/1 |
2026/05/25 23:52 |
action |
codesearch-prepare |
12m
Results: map[Index:codesearch-index]
|
| 5/1 |
2026/05/26 00:05 |
agent |
expert |
3m
Model:
Results: map[DenialOfService:true Exploitable:false FilesystemTrigger:false NetworkTrigger:false PeripheralTrigger:false RemoteTrigger:false Unprivileged:false UserNamespace:true VMGuestTrigger:true VMHostTrigger:false]
Instruction:
You are an experienced Linux kernel security engineer. Your task is to analyze given kernel bug report
and determine its security impact based on the following dimensions.
Use the provided tools to examine the source code, check for capability checks (e.g., capable(), ns_capable()),
and understand the nature of the bug. Analyze the given kernel build and configuration.
You can check the kernel config by grepping ".config" file; you can check kernel cmdline by greeping
".config" file for "CONFIG_CMDLINE=". Assume sysctl parameters have default values.
But analyze for the corresponding production build w/o debugging tools enabled (like KASAN, KMSAN, UBSAN).
Try different strategies when analyzing the bug:
- think of ways in which the vulnerable code is unreachable
- or the other way around: try to come up with different ideas of how an unprivileged user can reach the bug
If still unsure err on the side of the bug being non-exploitable/not-accessible.
In the final reply, provide a reasoning for your assessment.
Analysis dimensions:
* Exploitable:
Determine if the bug can result in memory corruption or elevated privileges.
Memory safety issues are almost always exploitable (KASAN or UBSAN reports for use-after-free, out-of-bounds;
refcounting issues, corrupted lists, etc). When kernel is crashing on a completly wild pointer access
(e.g. user-space address, or non-canonical address, but not on NULL or address corresponding to KASAN shadow
for NULL address), including both data accesses and control tranfers, that's also usually implies possibility
of exploitation. Such reports usually say "unable to handle kernel paging request".
Uses of uninitialized values detected by KMSAN may be exploitable b/c attacker frequently can affect uninit
values with spraying techniques. However, for these exploitabability depends on how exactly the uninit value
is used in the code, and what it affects.
Think of what happens after the bug is triggered. Some bugs cause kernel panic and halt execution,
they are harder to exploit. For example, BUG reports halts the kernel. However, WARNING reports don't halt
execution in production builds. Debug bug detection tools (like KASAN, KMSAN, KCSAN, UBSAN) are also not enabled
in production builds, so attacker can freely exploit these bugs w/o being detected by these tools.
If you see an integer overflow, think how the overflowed value used later (if it's used as allocation size,
or an array index). If you see an out-of-bounds read, think if it's followed by an out-of-bounds write as well.
Some KCSAN data-races may be exploitable by skilled attackers as well. Think what data structures got corrupted
as the result of data races and how. However, note that kernel has lots of "benign" data races that don't lead
to any runtime misbehavior at all.
* Denial Of Service:
Determine if the bug can result in denial-of-service. Most bugs can, since they cause system crash,
hangs, deadlocks, or resource leaks. This is mostly applicable to WARNING bugs that won't cause system crash
in production. For these think what will be consequences of the violation of the kernel assumptions flagged
by the WARNING. In some cases the unexpected condition is also properly handled by the normal control flow
(e.g. with "if (WARN_ON(...))"), these won't cause denial-of-service. If the condition is not handled,
then it may or may not cause denial-of-service.
* Accessible From Unprivileged Processes:
Determine if the bug can be reached from a typical (non-root) user process that does NOT have any special capabilities
(like CAP_SYS_ADMIN, CAP_NET_ADMIN, CAP_NET_RAW, CAP_PERFMON) or access to device nodes restricted to root.
Assume that unprivileged_bpf_disabled=1, that is eBPF loading is not accessible. However, cBPF (classical BPF)
is still accessible to non-root processes.
Assume that user namespaces are not accessible, that is, the process cannot get the mentioned capabilities even
within a new user namespace (checked by ns_capable() function in the kernel sources).
* Accessible From User Namespaces:
Determine if the bug can be reached within a user-namespace where the process has all capabilities
(including CAP_SYS_ADMIN, CAP_NET_ADMIN, CAP_NET_RAW, CAP_PERFMON). Such capabilities are checked with ns_capable()
function in the kernel sources.
* VM Guest Trigger:
Determine if the bug can be triggered from the context of a typical KVM guest (e.g., set up by a QEMU VMM).
Consider accesses to standard Linux host paravirtualized features (virtio-blk, virtio-net, etc.),
and handling of VM exits in the KVM code.
* VM Host Trigger in The Confidetial Computing Context:
Determine if the bug can be triggered in a confidential computing guest kernel from the context of a KVM host.
Consider access to standard Linux guest paravirtualized features (virtio-blk, virtio-net, etc.).
* Ethernet Network Trigger:
Determine if the bug can be triggered by processing ingress network Ethernet traffic, either directly (network stack)
or via drivers exposed to network data.
* Other Remote Trigger:
Determine if the bug can be triggered by processing remote traffic other than Ethernet (Wifi, Bluetooth, NFC, etc).
* Peripheral Trigger:
Determine if the bug can be triggered via an untrusted peripheral device that can be physically plugged
into a system, such as a USB device or a niche hardware driver handling external hardware inputs.
This is particularly important for mobile and desktop environments where users can plug in unknown devices.
* Malicious Filesystem Trigger:
Determine if the bug can be triggered by the kernel mounting and parsing a malicious filesystem image.
This is highly critical for Desktop and Mobile environments where external media or downloaded images
might be auto-mounted.
Don't make assumptions about the kernel source code (it may be different from what you assume it is).
Extensively use the provided code access tools (codesearch-*, git-*, grepper, etc)
to examine the actual source code, and confirm any assumptions.
Prefer calling several tools at the same time to save round-trips.
Use set-results tool to provide results of the analysis.
It must be called exactly once before the final reply.
Ignore results of this tool.
Prompt:
The kernel bug report is:
bridge0: received packet on bridge_slave_0 with own address as source address (addr:aa:aa:aa:aa:aa:0c, vlan:0)
bridge0: received packet on veth0_to_bridge with own address as source address (addr:f6:05:fc:fc:e9:2f, vlan:0)
rcu: INFO: rcu_preempt detected stalls on CPUs/tasks:
rcu: Tasks blocked on level-0 rcu_node (CPUs 0-1): P6496/1:b..l
rcu: (detected by 0, t=10502 jiffies, g=21149, q=1545 ncpus=1)
task:syz.3.109 state:R running task stack:28440 pid:6496 tgid:6486 ppid:5830 task_flags:0x400040 flags:0x00080002
Call Trace:
<TASK>
context_switch kernel/sched/core.c:5298 [inline]
__schedule+0xfee/0x6120 kernel/sched/core.c:6911
preempt_schedule_irq+0x50/0x90 kernel/sched/core.c:7238
irqentry_exit+0x17b/0x670 kernel/entry/common.c:239
asm_sysvec_apic_timer_interrupt+0x1a/0x20 arch/x86/include/asm/idtentry.h:697
RIP: 0010:kasan_mem_to_shadow include/linux/kasan.h:65 [inline]
RIP: 0010:kasan_byte_accessible+0xe/0x30 mm/kasan/generic.c:210
Code: 2e 0f 1f 84 00 00 00 00 00 0f 1f 00 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 0f 1f 40 d6 48 b8 00 00 00 00 00 fc ff df <48> c1 ef 03 48 01 c7 0f b6 07 3c 07 0f 96 c0 c3 cc cc cc cc 66 66
RSP: 0018:ffffc90004de76d0 EFLAGS: 00000202
RAX: dffffc0000000000 RBX: 0000000000000000 RCX: 0000000000000002
RDX: 0000000000000000 RSI: ffffffff81b7c011 RDI: ffffffff8e7e7760
RBP: ffffffff8e7e7760 R08: 0000000000000000 R09: 0000000000000000
R10: ffffc90004de7830 R11: 0000000000000000 R12: ffffffff81b7c011
R13: 0000000000000000 R14: 0000000000000000 R15: 0000000000000000
__kasan_check_byte+0x13/0x50 mm/kasan/common.c:573
kasan_check_byte include/linux/kasan.h:402 [inline]
lock_acquire kernel/locking/lockdep.c:5842 [inline]
lock_acquire+0x148/0x380 kernel/locking/lockdep.c:5825
rcu_lock_acquire include/linux/rcupdate.h:312 [inline]
rcu_read_lock include/linux/rcupdate.h:850 [inline]
class_rcu_constructor include/linux/rcupdate.h:1193 [inline]
unwind_next_frame+0xd1/0x1ea0 arch/x86/kernel/unwind_orc.c:495
__unwind_start+0x3d1/0x7f0 arch/x86/kernel/unwind_orc.c:773
unwind_start arch/x86/include/asm/unwind.h:64 [inline]
arch_stack_walk+0x73/0xf0 arch/x86/kernel/stacktrace.c:24
stack_trace_save+0x8e/0xc0 kernel/stacktrace.c:122
kasan_save_stack+0x30/0x50 mm/kasan/common.c:57
kasan_save_track+0x14/0x30 mm/kasan/common.c:78
unpoison_slab_object mm/kasan/common.c:340 [inline]
__kasan_slab_alloc+0x89/0x90 mm/kasan/common.c:366
kasan_slab_alloc include/linux/kasan.h:253 [inline]
slab_post_alloc_hook mm/slub.c:4538 [inline]
slab_alloc_node mm/slub.c:4866 [inline]
kmem_cache_alloc_noprof+0x241/0x6e0 mm/slub.c:4873
lsm_inode_alloc security/security.c:229 [inline]
security_inode_alloc+0x3b/0x2c0 security/security.c:1190
inode_init_always_gfp+0xced/0x1040 fs/inode.c:307
inode_init_always include/linux/fs.h:2922 [inline]
alloc_inode+0x8e/0x250 fs/inode.c:354
new_inode+0x22/0x1c0 fs/inode.c:1185
debugfs_get_inode fs/debugfs/inode.c:72 [inline]
__debugfs_create_file+0x105/0x4f0 fs/debugfs/inode.c:433
debugfs_create_file_full+0x41/0x60 fs/debugfs/inode.c:460
kvm_create_vm_debugfs virt/kvm/kvm_main.c:1067 [inline]
kvm_create_vm virt/kvm/kvm_main.c:1203 [inline]
kvm_dev_ioctl_create_vm virt/kvm/kvm_main.c:5499 [inline]
kvm_dev_ioctl+0x16c7/0x1a50 virt/kvm/kvm_main.c:5541
vfs_ioctl fs/ioctl.c:51 [inline]
__do_sys_ioctl fs/ioctl.c:597 [inline]
__se_sys_ioctl fs/ioctl.c:583 [inline]
__x64_sys_ioctl+0x18e/0x210 fs/ioctl.c:583
do_syscall_x64 arch/x86/entry/syscall_64.c:63 [inline]
do_syscall_64+0x106/0xf80 arch/x86/entry/syscall_64.c:94
entry_SYSCALL_64_after_hwframe+0x77/0x7f
RIP: 0033:0x7eff52f9c799
RSP: 002b:00007eff53e33028 EFLAGS: 00000246 ORIG_RAX: 0000000000000010
RAX: ffffffffffffffda RBX: 00007eff53216360 RCX: 00007eff52f9c799
RDX: 0000000000000000 RSI: 000000000000ae01 RDI: 0000000000000006
RBP: 00007eff53032c99 R08: 0000000000000000 R09: 0000000000000000
R10: 0000000000000000 R11: 0000000000000246 R12: 0000000000000000
R13: 00007eff532163f8 R14: 00007eff53216360 R15: 00007ffe05f42038
</TASK>
rcu: rcu_preempt kthread starved for 3256 jiffies! g21149 f0x0 RCU_GP_WAIT_FQS(5) ->state=0x0 ->cpu=0
rcu: Unless rcu_preempt kthread gets sufficient CPU time, OOM is now expected behavior.
rcu: RCU grace-period kthread stack dump:
task:rcu_preempt state:R running task stack:27736 pid:16 tgid:16 ppid:2 task_flags:0x208040 flags:0x00080000
Call Trace:
<TASK>
context_switch kernel/sched/core.c:5298 [inline]
__schedule+0xfee/0x6120 kernel/sched/core.c:6911
__schedule_loop kernel/sched/core.c:6993 [inline]
schedule+0xdd/0x390 kernel/sched/core.c:7008
schedule_timeout+0x127/0x280 kernel/time/sleep_timeout.c:99
rcu_gp_fqs_loop+0x1a9/0x900 kernel/rcu/tree.c:2095
rcu_gp_kthread+0x179/0x230 kernel/rcu/tree.c:2297
kthread+0x370/0x450 kernel/kthread.c:436
ret_from_fork+0x754/0xd80 arch/x86/kernel/process.c:158
ret_from_fork_asm+0x1a/0x30 arch/x86/entry/entry_64.S:245
</TASK>
rcu: Stack dump where RCU GP kthread last ran:
CPU: 0 UID: 0 PID: 3413 Comm: kworker/R-bat_e Not tainted syzkaller #0 PREEMPT(full)
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 02/12/2026
Workqueue: bat_events batadv_tt_purge
RIP: 0010:on_stack arch/x86/include/asm/stacktrace.h:55 [inline]
RIP: 0010:stack_access_ok+0x4b/0x1d0 arch/x86/kernel/unwind_orc.c:409
Code: 83 ec 08 0f b6 04 02 84 c0 74 08 3c 03 0f 8e 3f 01 00 00 8b 13 85 d2 74 65 48 b8 00 00 00 00 00 fc ff df 48 8d 7b 08 48 89 fa <48> c1 ea 03 80 3c 02 00 0f 85 24 01 00 00 48 8d 7b 10 4c 8b 6b 08
RSP: 0018:ffffc90000006810 EFLAGS: 00000202
RAX: dffffc0000000000 RBX: ffffc900000068b0 RCX: ffffffff92171e0c
RDX: ffffc900000068b8 RSI: ffffc90000007990 RDI: ffffc900000068b8
RBP: ffffc90000007990 R08: ffffffff92171e10 R09: 0000000000000007
R10: 0000000000000200 R11: 0000000000095c74 R12: 0000000000000008
R13: ffffc900000068b0 R14: ffffc90000007998 R15: ffffc900000068e4
FS: 0000000000000000(0000) GS:ffff888124343000(0000) knlGS:0000000000000000
CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: 0000001b3110eff8 CR3: 0000000025bd4000 CR4: 00000000003526f0
Call Trace:
<IRQ>
deref_stack_reg arch/x86/kernel/unwind_orc.c:419 [inline]
unwind_next_frame+0xb0b/0x1ea0 arch/x86/kernel/unwind_orc.c:600
arch_stack_walk+0x94/0xf0 arch/x86/kernel/stacktrace.c:25
stack_trace_save+0x8e/0xc0 kernel/stacktrace.c:122
kasan_save_stack+0x30/0x50 mm/kasan/common.c:57
kasan_save_track+0x14/0x30 mm/kasan/common.c:78
kasan_save_free_info+0x3b/0x70 mm/kasan/generic.c:584
poison_slab_object mm/kasan/common.c:253 [inline]
__kasan_slab_free+0x5f/0x80 mm/kasan/common.c:285
kasan_slab_free include/linux/kasan.h:235 [inline]
slab_free_hook mm/slub.c:2685 [inline]
slab_free mm/slub.c:6165 [inline]
kmem_cache_free+0x124/0x6a0 mm/slub.c:6295
__skb_ext_put+0x102/0x2f0 net/core/skbuff.c:7252
__skb_ext_del+0xf8/0x380 net/core/skbuff.c:7219
skb_ext_del include/linux/skbuff.h:5073 [inline]
nf_bridge_info_free net/bridge/br_netfilter_hooks.c:156 [inline]
br_nf_dev_queue_xmit+0x7ab/0x2a20 net/bridge/br_netfilter_hooks.c:919
NF_HOOK include/linux/netfilter.h:318 [inline]
NF_HOOK include/linux/netfilter.h:312 [inline]
br_nf_post_routing+0xcbb/0x16a0 net/bridge/br_netfilter_hooks.c:966
nf_hook_entry_hookfn include/linux/netfilter.h:158 [inline]
nf_hook_slow+0xbf/0x220 net/netfilter/core.c:623
nf_hook include/linux/netfilter.h:273 [inline]
NF_HOOK include/linux/netfilter.h:316 [inline]
br_forward_finish+0x261/0x4d0 net/bridge/br_forward.c:66
br_nf_hook_thresh+0x30d/0x420 net/bridge/br_netfilter_hooks.c:1167
br_nf_forward_finish+0x693/0xb30 net/bridge/br_netfilter_hooks.c:662
NF_HOOK include/linux/netfilter.h:318 [inline]
NF_HOOK include/linux/netfilter.h:312 [inline]
br_nf_forward_ip.part.0+0x61e/0x820 net/bridge/br_netfilter_hooks.c:716
br_nf_forward_ip net/bridge/br_netfilter_hooks.c:676 [inline]
br_nf_forward+0xfe5/0x19f0 net/bridge/br_netfilter_hooks.c:773
nf_hook_entry_hookfn include/linux/netfilter.h:158 [inline]
nf_hook_slow+0xbf/0x220 net/netfilter/core.c:623
nf_hook include/linux/netfilter.h:273 [inline]
NF_HOOK include/linux/netfilter.h:316 [inline]
__br_forward+0x2f6/0x970 net/bridge/br_forward.c:115
deliver_clone net/bridge/br_forward.c:131 [inline]
maybe_deliver+0xf0/0x180 net/bridge/br_forward.c:191
br_flood+0x193/0x650 net/bridge/br_forward.c:238
br_handle_frame_finish+0xff4/0x1f60 net/bridge/br_input.c:229
br_nf_hook_thresh+0x30d/0x420 net/bridge/br_netfilter_hooks.c:1167
br_nf_pre_routing_finish_ipv6+0x769/0xfb0 net/bridge/br_netfilter_ipv6.c:154
NF_HOOK include/linux/netfilter.h:318 [inline]
br_nf_pre_routing_ipv6+0x39c/0x8b0 net/bridge/br_netfilter_ipv6.c:184
br_nf_pre_routing+0x90d/0x1550 net/bridge/br_netfilter_hooks.c:508
nf_hook_entry_hookfn include/linux/netfilter.h:158 [inline]
nf_hook_bridge_pre net/bridge/br_input.c:291 [inline]
br_handle_frame+0xcdd/0x1520 net/bridge/br_input.c:442
__netif_receive_skb_core.constprop.0+0x6c5/0x3550 net/core/dev.c:6063
__netif_receive_skb_one_core+0xb0/0x1e0 net/core/dev.c:6174
__netif_receive_skb+0x1f/0x120 net/core/dev.c:6289
process_backlog+0x37a/0x1580 net/core/dev.c:6640
__napi_poll.constprop.0+0xaf/0x450 net/core/dev.c:7704
napi_poll net/core/dev.c:7767 [inline]
net_rx_action+0xa40/0xf20 net/core/dev.c:7924
handle_softirqs+0x1eb/0x9e0 kernel/softirq.c:622
do_softirq kernel/softirq.c:523 [inline]
do_softirq+0xac/0xe0 kernel/softirq.c:510
</IRQ>
<TASK>
__local_bh_enable_ip+0xf8/0x120 kernel/softirq.c:450
spin_unlock_bh include/linux/spinlock.h:395 [inline]
batadv_tt_global_purge net/batman-adv/translation-table.c:2250 [inline]
batadv_tt_purge+0x25d/0xbd0 net/batman-adv/translation-table.c:3510
process_one_work+0xa23/0x19a0 kernel/workqueue.c:3276
process_scheduled_works kernel/workqueue.c:3359 [inline]
rescuer_thread+0x905/0x14a0 kernel/workqueue.c:3583
kthread+0x370/0x450 kernel/kthread.c:436
ret_from_fork+0x754/0xd80 arch/x86/kernel/process.c:158
ret_from_fork_asm+0x1a/0x30 arch/x86/entry/entry_64.S:245
</TASK>
net_ratelimit: 6311 callbacks suppressed
bridge0: received packet on veth0_to_bridge with own address as source address (addr:f6:05:fc:fc:e9:2f, vlan:0)
bridge0: received packet on bridge_slave_0 with own address as source address (addr:aa:aa:aa:aa:aa:0c, vlan:0)
bridge0: received packet on bridge_slave_0 with own address as source address (addr:aa:aa:aa:aa:aa:1b, vlan:0)
bridge0: received packet on veth0_to_bridge with own address as source address (addr:aa:aa:aa:aa:aa:0c, vlan:0)
bridge0: received packet on veth0_to_bridge with own address as source address (addr:f6:05:fc:fc:e9:2f, vlan:0)
bridge0: received packet on veth0_to_bridge with own address as source address (addr:aa:aa:aa:aa:aa:0c, vlan:0)
bridge0: received packet on bridge_slave_0 with own address as source address (addr:aa:aa:aa:aa:aa:1b, vlan:0)
bridge0: received packet on bridge_slave_0 with own address as source address (addr:aa:aa:aa:aa:aa:0c, vlan:0)
bridge0: received packet on veth0_to_bridge with own address as source address (addr:f6:05:fc:fc:e9:2f, vlan:0)
bridge0: received packet on bridge_slave_0 with own address as source address (addr:aa:aa:aa:aa:aa:0c, vlan:0)
net_ratelimit: 9269 callbacks suppressed
bridge0: received packet on bridge_slave_0 with own address as source address (addr:aa:aa:aa:aa:aa:0c, vlan:0)
bridge0: received packet on veth0_to_bridge with own address as source address (addr:f6:05:fc:fc:e9:2f, vlan:0)
bridge0: received packet on bridge_slave_0 with own address as source address (addr:aa:aa:aa:aa:aa:0c, vlan:0)
bridge0: received packet on bridge_slave_0 with own address as source address (addr:aa:aa:aa:aa:aa:1b, vlan:0)
bridge0: received packet on veth0_to_bridge with own address as source address (addr:aa:aa:aa:aa:aa:0c, vlan:0)
bridge0: received packet on veth0_to_bridge with own address as source address (addr:f6:05:fc:fc:e9:2f, vlan:0)
bridge0: received packet on veth0_to_bridge with own address as source address (addr:aa:aa:aa:aa:aa:0c, vlan:0)
bridge0: received packet on bridge_slave_0 with own address as source address (addr:aa:aa:aa:aa:aa:1b, vlan:0)
bridge0: received packet on bridge_slave_0 with own address as source address (addr:aa:aa:aa:aa:aa:0c, vlan:0)
bridge0: received packet on veth0_to_bridge with own address as source address (addr:f6:05:fc:fc:e9:2f, vlan:0)
Reply: **Analysis of the Bug Report**
**1. Nature of the Bug:**
The bug report indicates an RCU (Read-Copy-Update) stall. The kernel logs show:
* `rcu: INFO: rcu_preempt detected stalls on CPUs/tasks:`
* `rcu: rcu_preempt kthread starved for 3256 jiffies!`
* Repeated warnings: `bridge0: received packet on bridge_slave_0 with own address as source address`
The stack traces reveal that the CPU is heavily occupied with processing network packets in the softirq context (`net_rx_action` -> `process_backlog` -> `br_handle_frame` -> `br_flood` -> `dev_queue_xmit`).
This is a classic Layer 2 network loop (broadcast storm). When interfaces (like `veth` pairs) are bridged together in a loop without Spanning Tree Protocol (STP) enabled or properly configured, a single broadcast or multicast packet will be flooded endlessly across the loop.
Because the packet processing happens in the `NET_RX_SOFTIRQ` context, the continuous stream of looping packets consumes 100% of the CPU. This softirq storm starves other normal tasks on the CPU. In this specific crash, a task (`syz.3.109`) was preempted by a timer interrupt while holding an `rcu_read_lock()` (during KASAN stack unwinding). Because the CPU was subsequently overwhelmed by the network softirq storm, the preempted task never got a chance to resume and release the RCU lock, completely blocking the RCU grace period and triggering the RCU stall detector.
**2. Security Impact:**
* **Exploitable:** No. This is a resource exhaustion issue (CPU starvation). There is no memory corruption, use-after-free, or out-of-bounds access involved. The KASAN frames in the stack trace are merely KASAN performing routine memory checks during stack unwinding triggered by the RCU stall detector, not a bug detection.
* **Denial of Service:** Yes. The broadcast storm consumes all available CPU cycles on the affected cores, leading to RCU stalls, soft lockups, and eventually a kernel panic (if `panic_on_rcu_stall` or `softlockup_panic` is enabled).
* **Accessible From Unprivileged Processes:** No. Creating network bridges, `veth` pairs, and altering their topology requires `CAP_NET_ADMIN` privileges.
* **Accessible From User Namespaces:** Yes. An unprivileged user can create a new user namespace and a new network namespace. Within this isolated network namespace, the user gains `CAP_NET_ADMIN` and can freely create bridges, `veth` interfaces, and intentionally wire them into a loop to trigger the softirq storm on the host CPU.
* **Network Trigger:** False. While it involves network packets, the root cause is the malicious/misconfigured local network topology setup. A remote attacker cannot trigger this unless the administrator has already misconfigured the network to contain a loop.
**Conclusion:**
This is a local Denial-of-Service (DoS) vulnerability caused by a softirq broadcast storm. It is not exploitable for privilege escalation or code execution but can be reliably triggered by an unprivileged user leveraging user and network namespaces to exhaust host CPU resources.
|
| 6/2 |
2026/05/26 00:05 |
llm |
expert |
0m
Model:
Tokens:
input: 11850
output: 43
thoughts: 4185
Thoughts: **RCU Stall in Bridge Forwarding: A Deep Dive**
Okay, so I'm looking at this bug report, and it screams "RCU stall." The kernel's complaining about the RCU preempt kthread being starved for CPU time, which means we're likely hitting OOM territory if it doesn't get enough resources. The stack trace points me directly to `rcu_gp_fqs_loop`, and the CPU stack shows a `batadv_tt_purge` running inside a workqueue, but interrupted by heavy softirq processing of network packets.
My initial thought is a network loop. I see the logs are filled with "received packet on bridge_slave_0 with own address as source address." That's classic bridge loop behavior. The `br_flood` function is key here, which would lead to packets being sent out of every port. With a misconfigured bridge, that packet will just bounce around until the CPU is maxed out. These kind of situations can occur when STP is disabled and packets get injected into the system in a loop.
So, is this a bug or a misconfiguration? Well, users can create bridges and veth pairs within their network namespaces to trigger this. I've dealt with this before. It's essentially a local DoS, but it requires CAP_NET_ADMIN in a user namespace. Easy peasy for a user to accomplish. This isn't exploitable in the traditional sense, as it isn't something that can be achieved remotely. Instead, it's just a misconfiguration on the local machine. It would be remotely exploitable if a remote attacker could send packets that trigger a loop, but that setup is the issue.
Let's dive deeper into the code though. The trace highlights a standard bridge forwarding path: `br_flood` -> `maybe_deliver` -> `__br_forward` -> `br_nf_forward` and so on, with netfilter enabled. If the ports are looped together, the packets will flood endlessly, starving the CPU. The `br_handle_frame` routine drops the packet, but if it's already looping, it may be too late to make any sort of difference.
Is this actually considered a vulnerability? It's generally accepted that root in a network namespace can cause a loop and DoS the system. I have considered that the kernel may have mitigations, but in general, an Ethernet loop will keep looping until the queue is full. And this is likely what is being observed. But if the loop is fast enough, it will just keep one CPU pegged. This is a bug because it causes the RCU stall, which could lead to a panic.
Now, I'm thinking about other factors here. `batadv_tt_purge` is in the trace too. Batman-adv is for ad-hoc mesh networks, creating virtual interfaces. Does this mean batman-adv is part of the problem? The log is clear: "received packet on bridge_slave_0 with own address as source address". Now I need to check `br_handle_frame`. I can see there is a drop from `br_handle_frame` due to a received packet that has the bridge's own MAC address. So, I see a warning, but then what happens next? The packets are looped.
So, in summary:
* **Exploitable:** No
* **DenialOfService:** Yes
* **Unprivileged:** No (requires user namespace to get CAP\_NET\_ADMIN)
* **UserNamespace:** Yes
* **VMGuestTrigger:** Yes (can be done inside a VM)
* **VMHostTrigger:** No
* **NetworkTrigger:** No (requires local setup of the loop, though a remote packet could trigger the loop if it's already set up, but the setup is the issue)
* **RemoteTrigger:** No
* **PeripheralTrigger:** No
* **FilesystemTrigger:** No
So, this looks like a straightforward bridge loop triggered by a local misconfiguration. The RCU stall is a symptom of the CPU getting hammered by softirqs in the bridge forwarding path, specifically when the source address matches the bridge address. I'm going to mark this as a misconfiguration issue rather than a new bug, but it would be good to document the potential for this kind of DoS clearly.
|
| 7/2 |
2026/05/26 00:06 |
tool |
codesearch-definition-source |
0m
Args: map[ContextFile:net/bridge/br_input.c IncludeLines:true Name:br_handle_frame]
Results: map[SourceCode: 335: /*
336: * Return NULL if skb is handled
337: * note: already called with rcu_read_lock
338: */
339: static rx_handler_result_t br_handle_frame(struct sk_buff **pskb)
340: {
341: enum skb_drop_reason reason = SKB_DROP_REASON_NOT_SPECIFIED;
342: struct net_bridge_port *p;
343: struct sk_buff *skb = *pskb;
344: const unsigned char *dest = eth_hdr(skb)->h_dest;
345:
346: if (unlikely(skb->pkt_type == PACKET_LOOPBACK))
347: return RX_HANDLER_PASS;
348:
349: if (!is_valid_ether_addr(eth_hdr(skb)->h_source)) {
350: reason = SKB_DROP_REASON_MAC_INVALID_SOURCE;
351: goto drop;
352: }
353:
354: skb = skb_share_check(skb, GFP_ATOMIC);
355: if (!skb)
356: return RX_HANDLER_CONSUMED;
357:
358: memset(skb->cb, 0, sizeof(struct br_input_skb_cb));
359: br_tc_skb_miss_set(skb, false);
360:
361: p = br_port_get_rcu(skb->dev);
362: if (p->flags & BR_VLAN_TUNNEL)
363: br_handle_ingress_vlan_tunnel(skb, p, nbp_vlan_group_rcu(p));
364:
365: if (unlikely(is_link_local_ether_addr(dest))) {
366: u16 fwd_mask = p->br->group_fwd_mask_required;
367:
368: /*
369: * See IEEE 802.1D Table 7-10 Reserved addresses
370: *
371: * Assignment Value
372: * Bridge Group Address 01-80-C2-00-00-00
373: * (MAC Control) 802.3 01-80-C2-00-00-01
374: * (Link Aggregation) 802.3 01-80-C2-00-00-02
375: * 802.1X PAE address 01-80-C2-00-00-03
376: *
377: * 802.1AB LLDP 01-80-C2-00-00-0E
378: *
379: * Others reserved for future standardization
380: */
381: fwd_mask |= p->group_fwd_mask;
382: switch (dest[5]) {
383: case 0x00: /* Bridge Group Address */
384: /* If STP is turned off,
385: then must forward to keep loop detection */
386: if (p->br->stp_enabled == BR_NO_STP ||
387: fwd_mask & (1u << dest[5]))
388: goto forward;
389: *pskb = skb;
390: __br_handle_local_finish(skb);
391: return RX_HANDLER_PASS;
392:
393: case 0x01: /* IEEE MAC (Pause) */
394: reason = SKB_DROP_REASON_MAC_IEEE_MAC_CONTROL;
395: goto drop;
396:
397: case 0x0E: /* 802.1AB LLDP */
398: fwd_mask |= p->br->group_fwd_mask;
399: if (fwd_mask & (1u << dest[5]))
400: goto forward;
401: *pskb = skb;
402: __br_handle_local_finish(skb);
403: return RX_HANDLER_PASS;
404:
405: default:
406: /* Allow selective forwarding for most other protocols */
407: fwd_mask |= p->br->group_fwd_mask;
408: if (fwd_mask & (1u << dest[5]))
409: goto forward;
410: }
411:
412: BR_INPUT_SKB_CB(skb)->promisc = false;
413:
414: /* The else clause should be hit when nf_hook():
415: * - returns < 0 (drop/error)
416: * - returns = 0 (stolen/nf_queue)
417: * Thus return 1 from the okfn() to signal the skb is ok to pass
418: */
419: if (NF_HOOK(NFPROTO_BRIDGE, NF_BR_LOCAL_IN,
420: dev_net(skb->dev), NULL, skb, skb->dev, NULL,
421: br_handle_local_finish) == 1) {
422: return RX_HANDLER_PASS;
423: } else {
424: return RX_HANDLER_CONSUMED;
425: }
426: }
427:
428: if (unlikely(br_process_frame_type(p, skb)))
429: return RX_HANDLER_PASS;
430:
431: forward:
432: if (br_mst_is_enabled(p))
433: goto defer_stp_filtering;
434:
435: switch (p->state) {
436: case BR_STATE_FORWARDING:
437: case BR_STATE_LEARNING:
438: defer_stp_filtering:
439: if (ether_addr_equal(p->br->dev->dev_addr, dest))
440: skb->pkt_type = PACKET_HOST;
441:
442: return nf_hook_bridge_pre(skb, pskb);
443: default:
444: reason = SKB_DROP_REASON_BRIDGE_INGRESS_STP_STATE;
445: drop:
446: kfree_skb_reason(skb, reason);
447: }
448: return RX_HANDLER_CONSUMED;
449: }
SourceFile:net/bridge/br_input.c]
|
| 8/2 |
2026/05/26 00:06 |
llm |
expert |
0m
Model:
Tokens:
input: 18943
output: 24
thoughts: 39
Thoughts: Okay, let's see... I'm looking at this code, specifically around `br_handle_frame`, and I'm not immediately seeing that specific warning message: "received packet on %s with own address as source address". That's a little unusual. I was expecting to find it there. Time to search for it, then. Let's dig in and find where this is happening.
|
| 9/2 |
2026/05/26 00:06 |
tool |
grepper |
0m
Args: map[Expression:received packet on.*with own address as source address]
Results: map[Output:net/bridge/br_fdb.c=989=void br_fdb_update(struct net_bridge *br, struct net_bridge_port *source,
--
net/bridge/br_fdb.c-1002- if (net_ratelimit())
net/bridge/br_fdb.c:1003: br_warn(br, "received packet on %s with own address as source address (addr:%pM, vlan:%u)\n",
net/bridge/br_fdb.c-1004- source->dev->name, addr, vid);
]
|
| 10/2 |
2026/05/26 00:06 |
llm |
expert |
0m
Model:
Tokens:
input: 19248
output: 45
thoughts: 28
Thoughts: Okay, here's my take on those thoughts, framed as my own:
**Analyzing a Potential FDB Issue**
Right, so I've got a hunch it's originating in `br_fdb_update`. Okay, let's dive into that routine. I need to take a look at the code and see exactly what's going on within that function. Time to check `br_fdb_update` and get to the root of the problem.
|
| 11/2 |
2026/05/26 00:06 |
tool |
codesearch-definition-source |
0m
Args: map[ContextFile:net/bridge/br_fdb.c IncludeLines:true Name:br_fdb_update]
Results: map[SourceCode: 989: void br_fdb_update(struct net_bridge *br, struct net_bridge_port *source,
990: const unsigned char *addr, u16 vid, unsigned long flags)
991: {
992: struct net_bridge_fdb_entry *fdb;
993:
994: /* some users want to always flood. */
995: if (hold_time(br) == 0)
996: return;
997:
998: fdb = fdb_find_rcu(&br->fdb_hash_tbl, addr, vid);
999: if (likely(fdb)) {
1000: /* attempt to update an entry for a local interface */
1001: if (unlikely(test_bit(BR_FDB_LOCAL, &fdb->flags))) {
1002: if (net_ratelimit())
1003: br_warn(br, "received packet on %s with own address as source address (addr:%pM, vlan:%u)\n",
1004: source->dev->name, addr, vid);
1005: } else {
1006: unsigned long now = jiffies;
1007: bool fdb_modified = false;
1008:
1009: if (now != READ_ONCE(fdb->updated)) {
1010: WRITE_ONCE(fdb->updated, now);
1011: fdb_modified = __fdb_mark_active(fdb);
1012: }
1013:
1014: /* fastpath: update of existing entry */
1015: if (unlikely(source != READ_ONCE(fdb->dst) &&
1016: !test_bit(BR_FDB_STICKY, &fdb->flags))) {
1017: br_switchdev_fdb_notify(br, fdb, RTM_DELNEIGH);
1018: WRITE_ONCE(fdb->dst, source);
1019: fdb_modified = true;
1020: /* Take over HW learned entry */
1021: if (unlikely(test_bit(BR_FDB_ADDED_BY_EXT_LEARN,
1022: &fdb->flags)))
1023: clear_bit(BR_FDB_ADDED_BY_EXT_LEARN,
1024: &fdb->flags);
1025: /* Clear locked flag when roaming to an
1026: * unlocked port.
1027: */
1028: if (unlikely(test_bit(BR_FDB_LOCKED, &fdb->flags)))
1029: clear_bit(BR_FDB_LOCKED, &fdb->flags);
1030: }
1031:
1032: if (unlikely(test_bit(BR_FDB_ADDED_BY_USER, &flags))) {
1033: set_bit(BR_FDB_ADDED_BY_USER, &fdb->flags);
1034: if (test_and_clear_bit(BR_FDB_DYNAMIC_LEARNED,
1035: &fdb->flags))
1036: atomic_dec(&br->fdb_n_learned);
1037: }
1038: if (unlikely(fdb_modified)) {
1039: trace_br_fdb_update(br, source, addr, vid, flags);
1040: fdb_notify(br, fdb, RTM_NEWNEIGH, true);
1041: }
1042: }
1043: } else {
1044: spin_lock(&br->hash_lock);
1045: fdb = fdb_create(br, source, addr, vid, flags);
1046: if (fdb) {
1047: trace_br_fdb_update(br, source, addr, vid, flags);
1048: fdb_notify(br, fdb, RTM_NEWNEIGH, true);
1049: }
1050: /* else we lose race and someone else inserts
1051: * it first, don't bother updating
1052: */
1053: spin_unlock(&br->hash_lock);
1054: }
1055: }
SourceFile:net/bridge/br_fdb.c]
|
| 12/2 |
2026/05/26 00:06 |
llm |
expert |
0m
Model:
Tokens:
input: 20629
output: 24
thoughts: 361
Thoughts: **My Assessment of the Bridge Loop Warning**
Okay, so `br_fdb_update` throws a warning when it sees a packet with a source MAC that's local to the bridge, meaning it's either coming from the bridge itself or one of its ports. That's a classic loop scenario β the packet is bouncing back on itself. The system rate-limits this warning, which is good. Importantly, the packet itself isn't dropped here; the Forwarding Database (FDB) entry *isn't* updated, and the packet just keeps on moving.
If this packet is a broadcast, multicast, or destined for an unknown MAC, it gets flooded. If there's a loop, that flood just amplifies the problem, creating an endless cycle, ultimately leading to an RCU stall.
My immediate thought is: what's preventing this? Ah, right, STP (Spanning Tree Protocol). STP is *designed* to prevent these very scenarios. If STP is off, you're practically inviting a broadcast storm. This is inherent to how Ethernet bridging works. The kernel bridge, of course, *allows* you to disable STP, which is where things get interesting.
So, if an unprivileged user, in a user namespace, can create a bridge, disable STP, and deliberately create a loop, they can trigger a broadcast storm. This can eat up 100% of a CPU's softirq processing, starving other tasks. This includes those crucial RCU kthreads, causing those frustrating RCU stalls.
The question then becomes: is this a security vulnerability? Generally, resource exhaustion by root *in* a user namespace is a known issue. However, sometimes specific loop conditions are considered bugs if they bypass intended limits. But here, we are just talking about standard, expected bridging behavior, with the expected implications. I think the answer is probably no, it's just the expected outcome of removing safety measures. However, I should check the commit history, just in case someone has addressed this.
|
| 13/2 |
2026/05/26 00:06 |
tool |
git-log |
0m
Args: map[MessageRegexps:[bridge rcu stall]]
Results: map[Output:d9f15a9de44a Revert "clocksource/drivers/riscv: Events are stopped during CPU suspend"
]
|
| 14/2 |
2026/05/26 00:06 |
llm |
expert |
0m
Model:
Tokens:
input: 21480
output: 22
thoughts: 15
Thoughts: Okay, here's my interpretation of those thoughts, crafted for an expert audience, presented in the first person:
**Navigating Network Instabilities**
Alright, I'm facing a potential network issue. Time to start digging. The symptoms I'm seeing strongly suggest either a *bridge loop* scenario or a full-blown *broadcast storm*. These are the usual suspects when you encounter this level of congestion and instability. Both can wreak havoc, so I'm going to start by querying the system logs and monitoring tools, starting with those key search terms. I'll need to correlate any logged events with the recent configuration changes or outages to nail down the root cause. My primary focus is pinpointing where those redundant paths might exist or if some rogue device is sending excessive traffic. Let's see what the initial searches turn up.
|
| 15/2 |
2026/05/26 00:06 |
tool |
git-log |
0m
Args: map[MessageRegexps:[bridge loop]]
Results: map[Output:b826d2c0b0ec pmdomain: bcm: bcm2835-power: Increase ASB control timeout
6a5e64c75e82 PCI: Add pbus_mem_size_optional() to handle optional sizes
0b2edc531e0b net: dsa: sja1105: let phylink help with the replay of link callbacks
34c702ea0497 PCI: Change pci_dev variable from 'bridge' to 'dev'
a3f433c57c46 drm/display: bridge_connector: get/put the panel_bridge
13adb8c97846 drm/display: bridge_connector: get/put the stored bridges
a154f141604a PCI: Fix regression in pci_bus_distribute_available_resources()
2be300f9a0b6 drm/display: bridge_connector: get/put the stored bridges
4292a1e45fd4 PCI: Refactor distributing available memory to use loops
7dc58aa7f1b3 PCI: Use pbus_select_window() during BAR resize
]
|
| 16/2 |
2026/05/26 00:06 |
llm |
expert |
0m
Model:
Tokens:
input: 21980
output: 47
thoughts: 4404
Thoughts: **Analysis of "bridge loop RCU stall" - A Deep Dive**
Okay, let's break this down. First, checking for a CVE... probably not. This "bridge loop RCU stall" is almost certainly a user-created loop. Since it requires `CAP_NET_ADMIN` in a user namespace, it's not a security vulnerability in the classic sense. It's a DoS, plain and simple, and the exploit is to misconfigure the network. The key is in the netns.
The syzbot report is pointing at an `rcu_preempt` stall during network processing, a softirq storm. No memory corruption, that's good. It's a textbook softirq storm. It's *not* exploitable in a way that allows privilege escalation or remote control, it's just a DoS. The loop itself is the vulnerability, the misconfiguration.
But wait, could a *remote* packet trigger this if the network is misconfigured? Yes, in theory. If a remote packet hits a bridge that *already* has a loop, it would amplify the storm, but the root cause is the local configuration that allows the loop in the first place. So that's still a "local" DoS.
I'm seeing `__kasan_slab_free` in the stack, but that's just normal packet freeing as part of network processing. Nothing suspicious there. This trace is freeing the `nf_bridge_info` extension. So, nothing points to any kind of memory corruption.
The system is stuck in an infinite loop! `br_nf_dev_queue_xmit` is followed by `dev_queue_xmit`, then `veth_xmit`, then `netif_rx`, back to a softirq which does the same operation, over and over, because the peer device's backlog contains the incoming packet, because the device is a veth pair.
The loop is across NAPI polls and softirq processing. A single packet becomes two, then four, and so on as the packet is cloned for flooding. This quickly exhausts memory and/or fills the network queues. Even if packets are dropped due to full queues, the CPU stays busy with processing the drops and the successful transmissions. It's 100% busy in softirq. It will starve RCU if the softirq doesn't yield, because `__do_softirq` does limit how long a softirq can run. The limit is 2ms or 10 restarts, and it will eventually yield. After this, `ksoftirqd` will run, which should compete with other threads including the RCU kthread.
The stack trace shows `batadv_tt_purge` which disables bottom halves, calls spin_unlock_bh to release BH, enabling the bottom halves, and then calling `do_softirq`, which runs the softirq processing. If the network loop generates packets *very* fast, the CPU *will* spend a lot of time in softirq, because of how this `__local_bh_enable_ip` logic works! But, `batadv_tt_purge` is in a workqueue (`kworker/R-bat_e`). The key thing is if the network is overwhelmed, RCU gets starved. This is a known issue.
But is it a bug in `batman-adv` or `bridge`? No. This is generic, caused by the network loop. The loop is the known DoS, and an unprivileged user can't create that (needs `CAP_NET_ADMIN`), but in user namespaces, they *can*. So, they're responsible for the loop.
A user can set up a bridge, add veth pairs and loop the traffic. This causes the softirq storm on the host and leads to RCU stalls, and possibly kernel panic if `panic_on_rcu_stall` is set. This is a known DoS from user namespaces.
And no, an unprivileged user *cannot* trigger this without namespaces, because it requires setting up the networking.
Could `batman-adv` be *creating* the loop? Possible. Batman-adv is layer 2 and requires `CAP_NET_ADMIN` to configure. If it's over veths, it's possible. The syzbot setup is probably setting up a bridge, batman-adv, adding some interfaces, and sending packets to form the loop.
Here's the summary:
* **Exploitable:** False.
* **DenialOfService:** True.
* **Unprivileged:** False.
* **UserNamespace:** True.
* **VMGuestTrigger:** True.
*
|
| 17/2 |
2026/05/26 00:07 |
tool |
codesearch-definition-source |
0m
Args: map[ContextFile:net/batman-adv/translation-table.c IncludeLines:true Name:batadv_tt_purge]
Results: map[SourceCode:3499: static void batadv_tt_purge(struct work_struct *work)
3500: {
3501: struct delayed_work *delayed_work;
3502: struct batadv_priv_tt *priv_tt;
3503: struct batadv_priv *bat_priv;
3504:
3505: delayed_work = to_delayed_work(work);
3506: priv_tt = container_of(delayed_work, struct batadv_priv_tt, work);
3507: bat_priv = container_of(priv_tt, struct batadv_priv, tt);
3508:
3509: batadv_tt_local_purge(bat_priv, BATADV_TT_LOCAL_TIMEOUT);
3510: batadv_tt_global_purge(bat_priv);
3511: batadv_tt_req_purge(bat_priv);
3512: batadv_tt_roam_purge(bat_priv);
3513:
3514: queue_delayed_work(batadv_event_workqueue, &bat_priv->tt.work,
3515: msecs_to_jiffies(BATADV_TT_WORK_PERIOD));
3516: }
SourceFile:net/batman-adv/translation-table.c]
|
| 18/2 |
2026/05/26 00:07 |
llm |
expert |
0m
Model:
Tokens:
input: 27824
output: 49
thoughts: 15
Thoughts: Okay, let's dive into this. Here's my thought process on this prompt:
**Analyzing the Function `batadv_tt_global_purge`**
Alright, so the task at hand is to understand `batadv_tt_global_purge`. My immediate thought is, "Let's check `batadv_tt_global_purge`." I need to understand what this function does within the broader context of BATMAN-Adv. Knowing that, I'll probably be thinking about its purpose. Is this a cleanup routine? A garbage collection function? Is it related to table management, specifically the topology table? What are the implications of a "global purge"? Does it impact performance? Does it introduce any race conditions? I'll need to consider how often it's called, and what events trigger its execution, to understand its impact. Knowing this is a "purge", I'll likely also consider potential side effects and what happens if this operation fails, or is interrupted. I'll need to figure out what data is being purged, the specific conditions under which this occurs, and whether this function might be the cause of any observed issues or performance bottlenecks. I also need to understand the relationship between this function and other related routines in the code base.
|
| 19/2 |
2026/05/26 00:07 |
tool |
codesearch-definition-source |
0m
Args: map[ContextFile:net/batman-adv/translation-table.c IncludeLines:true Name:batadv_tt_global_purge]
Results: map[SourceCode:2215: static void batadv_tt_global_purge(struct batadv_priv *bat_priv)
2216: {
2217: struct batadv_hashtable *hash = bat_priv->tt.global_hash;
2218: struct hlist_head *head;
2219: struct hlist_node *node_tmp;
2220: spinlock_t *list_lock; /* protects write access to the hash lists */
2221: u32 i;
2222: char *msg = NULL;
2223: struct batadv_tt_common_entry *tt_common;
2224: struct batadv_tt_global_entry *tt_global;
2225:
2226: for (i = 0; i < hash->size; i++) {
2227: head = &hash->table[i];
2228: list_lock = &hash->list_locks[i];
2229:
2230: spin_lock_bh(list_lock);
2231: hlist_for_each_entry_safe(tt_common, node_tmp, head,
2232: hash_entry) {
2233: tt_global = container_of(tt_common,
2234: struct batadv_tt_global_entry,
2235: common);
2236:
2237: if (!batadv_tt_global_to_purge(tt_global, &msg))
2238: continue;
2239:
2240: batadv_dbg(BATADV_DBG_TT, bat_priv,
2241: "Deleting global tt entry %pM (vid: %d): %s\n",
2242: tt_global->common.addr,
2243: batadv_print_vid(tt_global->common.vid),
2244: msg);
2245:
2246: hlist_del_rcu(&tt_common->hash_entry);
2247:
2248: batadv_tt_global_entry_put(tt_global);
2249: }
2250: spin_unlock_bh(list_lock);
2251: }
2252: }
SourceFile:net/batman-adv/translation-table.c]
|
| 20/2 |
2026/05/26 00:07 |
llm |
expert |
0m
Model:
Tokens:
input: 28796
output: 28
thoughts: 508
Thoughts: **Analyzing a Potential RCU Stall in batadv_tt_global_purge**
Okay, so I'm looking at this `batadv_tt_global_purge` function, and something's not sitting right. It seems to iterate through a hash table, right? For each bucket, it grabs the `list_lock` using `spin_lock_bh`, goes through the list, and then *crucially* unlocks with `spin_unlock_bh`. Now, the problem jumps out: if this hash table gets large, or if the system's under a heavy softirq load, we're going to have some serious issues.
Think about it: `spin_unlock_bh` actually *runs* softirqs if any are pending. And if we have a network loop churning out packets, `local_softirq_pending()` will be true all the time. This means that *every* time we hit `spin_unlock_bh` (and that happens once per bucket, `hash->size` times), we potentially spend up to, say, 2 milliseconds processing softirqs. If our `hash->size` is 1024, that means we could be looking at 2 seconds of pure CPU time just processing softirqs, *without* yielding to the scheduler!
And that's the kicker, isn't it? The code isn't calling `cond_resched()` inside the loop! So, `batadv_tt_global_purge` is potentially running for a full two seconds without ever yielding. And if `batadv_tt_local_purge`, `batadv_tt_req_purge`, and `batadv_tt_roam_purge` do something similar, the total unyielding time could get even worse.
This perfectly explains why the CPU gets stuck and RCU is starved. We're running a task that's hogging the CPU and doesn't call `schedule()` or `cond_resched()`, but constantly processing softirqs because of that `spin_unlock_bh` call. It's a textbook pattern for RCU stalls: a spinlock loop without `cond_resched()`, coupled with a heavy softirq load. I've seen this before.
So, what's the fix? Well, the standard approach is usually to just add a `cond_resched()` call *after* the `spin_unlock_bh` calls. Let's see if we can find any prior commits in `net/batman-adv/translation-table.c` that do exactly that. Let's start searching for those `cond_resched()` additions.
|
| 21/2 |
2026/05/26 00:07 |
tool |
git-log |
0m
Args: map[PathPrefix:net/batman-adv/translation-table.c]
Results: map[Output:87b95082db32 batman-adv: remove network coding support
a608f11d3a3b batman-adv: Switch to crc32 header for crc32c
94433355027d batman-adv: Use consistent name for mesh interface
f4c9c2cc827d batman-adv: Fix incorrect offset in batadv_tt_tvlv_ogm_handler_v1()
6ecc4fd6c2f4 batman-adv: netlink: reduce duplicate code by returning interfaces
fca81aa3e653 batman-adv: Don't keep redundant TT change events
8587e0e3f562 batman-adv: Remove atomic usage for tt.local_changes
fff8f17c1a6f batman-adv: Do not let TT changes list grows indefinitely
8038806db64d batman-adv: Remove uninitialized data in full table TT response
f2f7358c3890 batman-adv: Do not send uninitialized TT changes
]
|
| 22/2 |
2026/05/26 00:07 |
llm |
expert |
0m
Model:
Tokens:
input: 30161
output: 49
thoughts: 47
Thoughts: **Checking for `cond_resched()` in Recent Code**
Okay, hold on a second. Something feels off. I was expecting to see a recent commit related to `cond_resched()`, but I'm not seeing one. That's unusual. Let me quickly verify that `batadv_tt_global_purge` actually incorporates `cond_resched()` in the latest iteration of the code. I need to make sure this recent change is being handled correctly, and this seems like the best starting point. Let me go take a look.
|
| 23/2 |
2026/05/26 00:07 |
tool |
codesearch-definition-source |
0m
Args: map[ContextFile:net/batman-adv/translation-table.c IncludeLines:true Name:batadv_tt_global_purge]
Results: map[SourceCode:2215: static void batadv_tt_global_purge(struct batadv_priv *bat_priv)
2216: {
2217: struct batadv_hashtable *hash = bat_priv->tt.global_hash;
2218: struct hlist_head *head;
2219: struct hlist_node *node_tmp;
2220: spinlock_t *list_lock; /* protects write access to the hash lists */
2221: u32 i;
2222: char *msg = NULL;
2223: struct batadv_tt_common_entry *tt_common;
2224: struct batadv_tt_global_entry *tt_global;
2225:
2226: for (i = 0; i < hash->size; i++) {
2227: head = &hash->table[i];
2228: list_lock = &hash->list_locks[i];
2229:
2230: spin_lock_bh(list_lock);
2231: hlist_for_each_entry_safe(tt_common, node_tmp, head,
2232: hash_entry) {
2233: tt_global = container_of(tt_common,
2234: struct batadv_tt_global_entry,
2235: common);
2236:
2237: if (!batadv_tt_global_to_purge(tt_global, &msg))
2238: continue;
2239:
2240: batadv_dbg(BATADV_DBG_TT, bat_priv,
2241: "Deleting global tt entry %pM (vid: %d): %s\n",
2242: tt_global->common.addr,
2243: batadv_print_vid(tt_global->common.vid),
2244: msg);
2245:
2246: hlist_del_rcu(&tt_common->hash_entry);
2247:
2248: batadv_tt_global_entry_put(tt_global);
2249: }
2250: spin_unlock_bh(list_lock);
2251: }
2252: }
SourceFile:net/batman-adv/translation-table.c]
|
| 24/2 |
2026/05/26 00:07 |
llm |
expert |
0m
Model:
Tokens:
input: 31018
output: 47
thoughts: 284
Thoughts: **My Analysis of the Batman-Adv RCU Stall Vulnerability**
Okay, so I'm looking at this code, and I see no `cond_resched()` calls in the relevant purge functions, which is already a red flag. The problem seems to be that functions like `batadv_tt_global_purge` iterate through a hash table and call `spin_unlock_bh`. This is a clear recipe for an RCU stall under heavy softirq load because `spin_unlock_bh` processes softirqs but doesn't yield to the scheduler, meaning a Denial of Service. This is a classic DoS scenario.
The next question is always, can this be triggered without user namespaces? Batman-adv configuration requires `CAP_NET_ADMIN`, and this is, unfortunately, accessible from user namespaces. So, technically, it's not unprivileged. But is this even exploitable? No, strictly speaking, it's just an RCU stall, but a DoS is still a problem.
Let me clarify my notes: DenialOfService: **True**. Unprivileged: **False**. UserNamespace: **True**. VMGuestTrigger: **True**. VmHostTrigger: **False**. NetworkTrigger: **False** (requires local setup). RemoteTrigger: **False**. PeripheralTrigger: **False**. FilesystemTrigger: **False**.
Now, I want to confirm that batman-adv configuration truly is privileged; let me see... It uses netlink or sysfs, generally requiring `GENL_ADMIN_PERM` or checking `netlink_capable(skb, CAP_NET_ADMIN)`. Let me go ahead and double check that in `net/batman-adv/netlink.c`.
|
| 25/2 |
2026/05/26 00:07 |
tool |
codesearch-definition-source |
0m
Args: map[ContextFile:net/batman-adv/netlink.c IncludeLines:false Name:batadv_netlink_family]
Results: map[SourceCode:struct genl_family batadv_netlink_family __ro_after_init = {
.hdrsize = 0,
.name = BATADV_NL_NAME,
.version = 1,
.maxattr = BATADV_ATTR_MAX,
.policy = batadv_netlink_policy,
.netnsok = true,
.pre_doit = batadv_pre_doit,
.post_doit = batadv_post_doit,
.module = THIS_MODULE,
.small_ops = batadv_netlink_ops,
.n_small_ops = ARRAY_SIZE(batadv_netlink_ops),
.resv_start_op = BATADV_CMD_SET_VLAN + 1,
.mcgrps = batadv_netlink_mcgrps,
.n_mcgrps = ARRAY_SIZE(batadv_netlink_mcgrps),
};
SourceFile:net/batman-adv/netlink.c]
|
| 26/2 |
2026/05/26 00:07 |
llm |
expert |
0m
Model:
Tokens:
input: 31974
output: 47
thoughts: 14
Thoughts: Okay, let's dive into this. Here's my thought process on checking `batadv_netlink_ops`, expressed as if it's coming directly from my own mind:
**Analyzing the `batadv_netlink_ops`**
Alright, time to get a good look at `batadv_netlink_ops`. My experience tells me that this is likely a critical structure within the B.A.T.M.A.N. advanced networking stack. I'm immediately thinking it's probably handling the Netlink interface operations. Specifically, I'm expecting to find function pointers defined here that allow userspace tools to interact with the B.A.T.M.A.N. configuration and control plane. I'll need to see if it's the standard implementation, or something that we may have done ourselves. I am hoping to get a better understanding of how the user-space daemon communicates with the kernel module, how messages are exchanged, and what kind of Netlink attributes are being used. I'll need to trace its usage in the broader context of the B.A.T.M.A.N. code. I'm keeping my eye out for any potential vulnerabilities or bottlenecks within this module's design. This is going to be good to see how our code handles these interactions.
|
| 27/2 |
2026/05/26 00:07 |
tool |
codesearch-definition-source |
0m
Args: map[ContextFile:net/batman-adv/netlink.c IncludeLines:false Name:batadv_netlink_ops]
Results: map[SourceCode:static const struct genl_small_ops batadv_netlink_ops[] = {
{
.cmd = BATADV_CMD_GET_MESH,
.validate = GENL_DONT_VALIDATE_STRICT | GENL_DONT_VALIDATE_DUMP,
/* can be retrieved by unprivileged users */
.doit = batadv_netlink_get_mesh,
.internal_flags = BATADV_FLAG_NEED_MESH,
},
{
.cmd = BATADV_CMD_TP_METER,
.validate = GENL_DONT_VALIDATE_STRICT | GENL_DONT_VALIDATE_DUMP,
.flags = GENL_UNS_ADMIN_PERM,
.doit = batadv_netlink_tp_meter_start,
.internal_flags = BATADV_FLAG_NEED_MESH,
},
{
.cmd = BATADV_CMD_TP_METER_CANCEL,
.validate = GENL_DONT_VALIDATE_STRICT | GENL_DONT_VALIDATE_DUMP,
.flags = GENL_UNS_ADMIN_PERM,
.doit = batadv_netlink_tp_meter_cancel,
.internal_flags = BATADV_FLAG_NEED_MESH,
},
{
.cmd = BATADV_CMD_GET_ROUTING_ALGOS,
.validate = GENL_DONT_VALIDATE_STRICT | GENL_DONT_VALIDATE_DUMP,
.flags = GENL_UNS_ADMIN_PERM,
.dumpit = batadv_algo_dump,
},
{
.cmd = BATADV_CMD_GET_HARDIF,
.validate = GENL_DONT_VALIDATE_STRICT | GENL_DONT_VALIDATE_DUMP,
/* can be retrieved by unprivileged users */
.dumpit = batadv_netlink_dump_hardif,
.doit = batadv_netlink_cmd_get_hardif,
.internal_flags = BATADV_FLAG_NEED_MESH |
BATADV_FLAG_NEED_HARDIF,
},
{
.cmd = BATADV_CMD_GET_TRANSTABLE_LOCAL,
.validate = GENL_DONT_VALIDATE_STRICT | GENL_DONT_VALIDATE_DUMP,
.flags = GENL_UNS_ADMIN_PERM,
.dumpit = batadv_tt_local_dump,
},
{
.cmd = BATADV_CMD_GET_TRANSTABLE_GLOBAL,
.validate = GENL_DONT_VALIDATE_STRICT | GENL_DONT_VALIDATE_DUMP,
.flags = GENL_UNS_ADMIN_PERM,
.dumpit = batadv_tt_global_dump,
},
{
.cmd = BATADV_CMD_GET_ORIGINATORS,
.validate = GENL_DONT_VALIDATE_STRICT | GENL_DONT_VALIDATE_DUMP,
.flags = GENL_UNS_ADMIN_PERM,
.dumpit = batadv_orig_dump,
},
{
.cmd = BATADV_CMD_GET_NEIGHBORS,
.validate = GENL_DONT_VALIDATE_STRICT | GENL_DONT_VALIDATE_DUMP,
.flags = GENL_UNS_ADMIN_PERM,
.dumpit = batadv_hardif_neigh_dump,
},
{
.cmd = BATADV_CMD_GET_GATEWAYS,
.validate = GENL_DONT_VALIDATE_STRICT | GENL_DONT_VALIDATE_DUMP,
.flags = GENL_UNS_ADMIN_PERM,
.dumpit = batadv_gw_dump,
},
{
.cmd = BATADV_CMD_GET_BLA_CLAIM,
.validate = GENL_DONT_VALIDATE_STRICT | GENL_DONT_VALIDATE_DUMP,
.flags = GENL_UNS_ADMIN_PERM,
.dumpit = batadv_bla_claim_dump,
},
{
.cmd = BATADV_CMD_GET_BLA_BACKBONE,
.validate = GENL_DONT_VALIDATE_STRICT | GENL_DONT_VALIDATE_DUMP,
.flags = GENL_UNS_ADMIN_PERM,
.dumpit = batadv_bla_backbone_dump,
},
{
.cmd = BATADV_CMD_GET_DAT_CACHE,
.validate = GENL_DONT_VALIDATE_STRICT | GENL_DONT_VALIDATE_DUMP,
.flags = GENL_UNS_ADMIN_PERM,
.dumpit = batadv_dat_cache_dump,
},
{
.cmd = BATADV_CMD_GET_MCAST_FLAGS,
.validate = GENL_DONT_VALIDATE_STRICT | GENL_DONT_VALIDATE_DUMP,
.flags = GENL_UNS_ADMIN_PERM,
.dumpit = batadv_mcast_flags_dump,
},
{
.cmd = BATADV_CMD_SET_MESH,
.validate = GENL_DONT_VALIDATE_STRICT | GENL_DONT_VALIDATE_DUMP,
.flags = GENL_UNS_ADMIN_PERM,
.doit = batadv_netlink_set_mesh,
.internal_flags = BATADV_FLAG_NEED_MESH,
},
{
.cmd = BATADV_CMD_SET_HARDIF,
.validate = GENL_DONT_VALIDATE_STRICT | GENL_DONT_VALIDATE_DUMP,
.flags = GENL_UNS_ADMIN_PERM,
.doit = batadv_netlink_set_hardif,
.internal_flags = BATADV_FLAG_NEED_MESH |
BATADV_FLAG_NEED_HARDIF,
},
{
.cmd = BATADV_CMD_GET_VLAN,
.validate = GENL_DONT_VALIDATE_STRICT | GENL_DONT_VALIDATE_DUMP,
/* can be retrieved by unprivileged users */
.doit = batadv_netlink_get_vlan,
.internal_flags = BATADV_FLAG_NEED_MESH |
BATADV_FLAG_NEED_VLAN,
},
{
.cmd = BATADV_CMD_SET_VLAN,
.validate = GENL_DONT_VALIDATE_STRICT | GENL_DONT_VALIDATE_DUMP,
.flags = GENL_UNS_ADMIN_PERM,
.doit = batadv_netlink_set_vlan,
.internal_flags = BATADV_FLAG_NEED_MESH |
BATADV_FLAG_NEED_VLAN,
},
};
SourceFile:net/batman-adv/netlink.c]
|
| 28/2 |
2026/05/26 00:07 |
llm |
expert |
0m
Model:
Tokens:
input: 34011
output: 40
thoughts: 2320
Thoughts: **Vulnerability Analysis: RCU Stall and Network Loop**
Okay, so `GENL_UNS_ADMIN_PERM` tells me that this requires `CAP_NET_ADMIN` within a user namespace. It's accessible from user namespaces but not unprivileged processes. My first thought is: can this be triggered any other way? The core issue appears to be a bridge loop that creates a softirq storm, ultimately leading to CPU starvation and RCU stalls. We've seen this before with network loops.
The exploitability is rated as False, but it's a Denial of Service, and it's triggerable from a user namespace within a VM guest. No host-level trigger. It's not a network or remote trigger *per se*, because the root cause is a misconfiguration (loop without STP).
Now, let's look at the kernel traces. The KASAN reports are intriguing, with those calls to `kasan_mem_to_shadow`, `kasan_byte_accessible`, and `__kasan_check_byte`. These are typically indicative of memory corruption, so I want to know what this is. From the first stack trace, it appears that this is happening during a stack unwind, and the unwind is driven by the RCU stall detector, which is dumping the stack of all CPUs. No, there's no memory corruption; this is just the CPU being interrupted by the NMI.
But now, there's a different stack trace. The first trace looked like a task interrupted by the timer interrupt. This task (`syz.3.109`) looks like it's trying to save its own stack trace *while* KASAN is running. This task was allocating an inode for debugfs. It was preempted by the timer interrupt which triggered `preempt_schedule_irq`. The task then blocks RCU.
Wait, the RCU stall message says: `Tasks blocked on level-0 rcu_node (CPUs 0-1): P6496/1:b..l`. Task 6496 is `syz.3.109`. It's blocked on an RCU node. So, the stack traces make sense. It was preempted in an RCU critical section! And the critical section involves a call to `lock_acquire`, and therefore `rcu_read_lock`. So, this is potentially more involved. It appears there is an RCU read-side critical section, and that this could be exploited.
|
| 29/2 |
2026/05/26 00:08 |
tool |
codesearch-definition-source |
0m
Args: map[ContextFile:kernel/locking/lockdep.c IncludeLines:true Name:lock_acquire]
Results: map[SourceCode:5821: /*
5822: * We are not always called with irqs disabled - do that here,
5823: * and also avoid lockdep recursion:
5824: */
5825: void lock_acquire(struct lockdep_map *lock, unsigned int subclass,
5826: int trylock, int read, int check,
5827: struct lockdep_map *nest_lock, unsigned long ip)
5828: {
5829: unsigned long flags;
5830:
5831: trace_lock_acquire(lock, subclass, trylock, read, check, nest_lock, ip);
5832:
5833: if (!debug_locks)
5834: return;
5835:
5836: /*
5837: * As KASAN instrumentation is disabled and lock_acquire() is usually
5838: * the first lockdep call when a task tries to acquire a lock, add
5839: * kasan_check_byte() here to check for use-after-free and other
5840: * memory errors.
5841: */
5842: kasan_check_byte(lock);
5843:
5844: if (unlikely(!lockdep_enabled())) {
5845: /* XXX allow trylock from NMI ?!? */
5846: if (lockdep_nmi() && !trylock) {
5847: struct held_lock hlock;
5848:
5849: hlock.acquire_ip = ip;
5850: hlock.instance = lock;
5851: hlock.nest_lock = nest_lock;
5852: hlock.irq_context = 2; // XXX
5853: hlock.trylock = trylock;
5854: hlock.read = read;
5855: hlock.check = check;
5856: hlock.hardirqs_off = true;
5857: hlock.references = 0;
5858:
5859: verify_lock_unused(lock, &hlock, subclass);
5860: }
5861: return;
5862: }
5863:
5864: raw_local_irq_save(flags);
5865: check_flags(flags);
5866:
5867: lockdep_recursion_inc();
5868: __lock_acquire(lock, subclass, trylock, read, check,
5869: irqs_disabled_flags(flags), nest_lock, ip, 0, 0, 0);
5870: lockdep_recursion_finish();
5871: raw_local_irq_restore(flags);
5872: }
SourceFile:kernel/locking/lockdep.c]
|
| 30/2 |
2026/05/26 00:08 |
llm |
expert |
0m
Model:
Tokens:
input: 37701
output: 49
thoughts: 249
Thoughts: **Investigating a KASAN Trigger in `unwind_next_frame`**
Okay, so I see a `lock_acquire` call that's triggering a `kasan_check_byte(lock)` call, which is interesting. The stack trace is what I'm looking at, as usual, to see how we got here. It's pointing me through `lock_acquire`, which, in turn, calls `kasan_check_byte`, as expected. But then I see something that jumps out immediately. This stack shows `unwind_next_frame` is calling `rcu_read_lock`? That doesn't seem right at all. Why would an unwinding function, of all things, need to acquire an RCU read lock? That strikes me as incredibly unusual, and a potential source of contention, or even a subtle bug. I need to dig into the source code to confirm this, so let's head straight to `arch/x86/kernel/unwind_orc.c:495` and see what's actually happening. Time to check what `unwind_next_frame` is doing with the RCU, and if this call is truly necessary.
|
| 31/2 |
2026/05/26 00:08 |
tool |
codesearch-definition-source |
0m
Args: map[ContextFile:arch/x86/kernel/unwind_orc.c IncludeLines:true Name:unwind_next_frame]
Results: map[SourceCode: 484: bool unwind_next_frame(struct unwind_state *state)
485: {
486: unsigned long ip_p, sp, tmp, orig_ip = state->ip, prev_sp = state->sp;
487: enum stack_type prev_type = state->stack_info.type;
488: struct orc_entry *orc;
489: bool indirect = false;
490:
491: if (unwind_done(state))
492: return false;
493:
494: /* Don't let modules unload while we're reading their ORC data. */
495: guard(rcu)();
496:
497: /* End-of-stack check for user tasks: */
498: if (state->regs && user_mode(state->regs))
499: goto the_end;
500:
501: /*
502: * Find the orc_entry associated with the text address.
503: *
504: * For a call frame (as opposed to a signal frame), state->ip points to
505: * the instruction after the call. That instruction's stack layout
506: * could be different from the call instruction's layout, for example
507: * if the call was to a noreturn function. So get the ORC data for the
508: * call instruction itself.
509: */
510: orc = orc_find(state->signal ? state->ip : state->ip - 1);
511: if (!orc) {
512: /*
513: * As a fallback, try to assume this code uses a frame pointer.
514: * This is just a guess, so the rest of the unwind is no longer
515: * considered reliable.
516: */
517: orc = &orc_fp_entry;
518: state->error = true;
519: } else {
520: if (orc->type == ORC_TYPE_UNDEFINED)
521: goto err;
522:
523: if (orc->type == ORC_TYPE_END_OF_STACK)
524: goto the_end;
525: }
526:
527: state->signal = orc->signal;
528:
529: /* Find the previous frame's stack: */
530: switch (orc->sp_reg) {
531: case ORC_REG_SP:
532: sp = state->sp + orc->sp_offset;
533: break;
534:
535: case ORC_REG_BP:
536: sp = state->bp + orc->sp_offset;
537: break;
538:
539: case ORC_REG_SP_INDIRECT:
540: sp = state->sp;
541: indirect = true;
542: break;
543:
544: case ORC_REG_BP_INDIRECT:
545: sp = state->bp + orc->sp_offset;
546: indirect = true;
547: break;
548:
549: case ORC_REG_R10:
550: if (!get_reg(state, offsetof(struct pt_regs, r10), &sp)) {
551: orc_warn_current("missing R10 value at %pB\n",
552: (void *)state->ip);
553: goto err;
554: }
555: break;
556:
557: case ORC_REG_R13:
558: if (!get_reg(state, offsetof(struct pt_regs, r13), &sp)) {
559: orc_warn_current("missing R13 value at %pB\n",
560: (void *)state->ip);
561: goto err;
562: }
563: break;
564:
565: case ORC_REG_DI:
566: if (!get_reg(state, offsetof(struct pt_regs, di), &sp)) {
567: orc_warn_current("missing RDI value at %pB\n",
568: (void *)state->ip);
569: goto err;
570: }
571: break;
572:
573: case ORC_REG_DX:
574: if (!get_reg(state, offsetof(struct pt_regs, dx), &sp)) {
575: orc_warn_current("missing DX value at %pB\n",
576: (void *)state->ip);
577: goto err;
578: }
579: break;
580:
581: default:
582: orc_warn("unknown SP base reg %d at %pB\n",
583: orc->sp_reg, (void *)state->ip);
584: goto err;
585: }
586:
587: if (indirect) {
588: if (!deref_stack_reg(state, sp, &sp))
589: goto err;
590:
591: if (orc->sp_reg == ORC_REG_SP_INDIRECT)
592: sp += orc->sp_offset;
593: }
594:
595: /* Find IP, SP and possibly regs: */
596: switch (orc->type) {
597: case ORC_TYPE_CALL:
598: ip_p = sp - sizeof(long);
599:
600: if (!deref_stack_reg(state, ip_p, &state->ip))
601: goto err;
602:
603: state->ip = unwind_recover_ret_addr(state, state->ip,
604: (unsigned long *)ip_p);
605: state->sp = sp;
606: state->regs = NULL;
607: state->prev_regs = NULL;
608: break;
609:
610: case ORC_TYPE_REGS:
611: if (!deref_stack_regs(state, sp, &state->ip, &state->sp)) {
612: orc_warn_current("can't access registers at %pB\n",
613: (void *)orig_ip);
614: goto err;
615: }
616: /*
617: * There is a small chance to interrupt at the entry of
618: * arch_rethook_trampoline() where the ORC info doesn't exist.
619: * That point is right after the RET to arch_rethook_trampoline()
620: * which was modified return address.
621: * At that point, the @addr_p of the unwind_recover_rethook()
622: * (this has to point the address of the stack entry storing
623: * the modified return address) must be "SP - (a stack entry)"
624: * because SP is incremented by the RET.
625: */
626: state->ip = unwind_recover_rethook(state, state->ip,
627: (unsigned long *)(state->sp - sizeof(long)));
628: state->regs = (struct pt_regs *)sp;
629: state->prev_regs = NULL;
630: state->full_regs = true;
631: break;
632:
633: case ORC_TYPE_REGS_PARTIAL:
634: if (!deref_stack_iret_regs(state, sp, &state->ip, &state->sp)) {
635: orc_warn_current("can't access iret registers at %pB\n",
636: (void *)orig_ip);
637: goto err;
638: }
639: /* See ORC_TYPE_REGS case comment. */
640: state->ip = unwind_recover_rethook(state, state->ip,
641: (unsigned long *)(state->sp - sizeof(long)));
642:
643: if (state->full_regs)
644: state->prev_regs = state->regs;
645: state->regs = (void *)sp - IRET_FRAME_OFFSET;
646: state->full_regs = false;
647: break;
648:
649: default:
650: orc_warn("unknown .orc_unwind entry type %d at %pB\n",
651: orc->type, (void *)orig_ip);
652: goto err;
653: }
654:
655: /* Find BP: */
656: switch (orc->bp_reg) {
657: case ORC_REG_UNDEFINED:
658: if (get_reg(state, offsetof(struct pt_regs, bp), &tmp))
659: state->bp = tmp;
660: break;
661:
662: case ORC_REG_PREV_SP:
663: if (!deref_stack_reg(state, sp + orc->bp_offset, &state->bp))
664: goto err;
665: break;
666:
667: case ORC_REG_BP:
668: if (!deref_stack_reg(state, state->bp + orc->bp_offset, &state->bp))
669: goto err;
670: break;
671:
672: default:
673: orc_warn("unknown BP base reg %d for ip %pB\n",
674: orc->bp_reg, (void *)orig_ip);
675: goto err;
676: }
677:
678: /* Prevent a recursive loop due to bad ORC data: */
679: if (state->stack_info.type == prev_type &&
680: on_stack(&state->stack_info, (void *)state->sp, sizeof(long)) &&
681: state->sp <= prev_sp) {
682: orc_warn_current("stack going in the wrong direction? at %pB\n",
683: (void *)orig_ip);
684: goto err;
685: }
686:
687: return true;
688:
689: err:
690: state->error = true;
691:
692: the_end:
693: state->stack_info.type = STACK_TYPE_UNKNOWN;
694: return false;
695: }
SourceFile:arch/x86/kernel/unwind_orc.c]
|
| 32/2 |
2026/05/26 00:08 |
llm |
expert |
0m
Model:
Tokens:
input: 41421
output: 66
thoughts: 874
Thoughts: **RCU Stall Analysis: A Softirq Storm in Disguise**
Okay, let's break this down. My initial observation was that `unwind_next_frame` was using `guard(rcu)()`, which essentially wraps `rcu_read_lock()` and `rcu_read_unlock()`. The stack trace confirms this β line 495 in `unwind_orc.c` indeed shows the `guard(rcu)()` call. This means the task, likely unwinding the stack for something like KASAN, had acquired an `rcu_read_lock`. Then, a timer interrupt preempted it, calling `preempt_schedule_irq`.
Now, the crucial point: `rcu_read_lock` *disables* preemption in non-preemptible kernels, but *allows* it in `PREEMPT(full)` kernels, as this system likely is. The catch, however, is that if a task is preempted *while* holding an RCU read-side lock, it ends up blocking the RCU grace period. The RCU stall detector kicked in, and saw that task `syz.3.109` was the culprit.
The question then was *why* it was blocking for so long. The answer, it turns out, is the softirq storm. The CPU was absolutely slammed with softirqs β specifically, the network loop, which was consuming all available processing time. This meant the preempted task couldn't resume and release the RCU read-side lock, thereby stalling the grace period. Bingo! The network loop was the source of the problem.
Let's summarize:
The network loop, triggered by a broadcast storm, consumed 100% of the CPU in `NET_RX_SOFTIRQ`, starving other tasks, and the RCU stall.
Creating a loop requires `CAP_NET_ADMIN`, which is accessible in user namespaces.
This is a local Denial of Service.
I'll formulate the response with these dimensions:
- Exploitable: False
- DenialOfService: True
- Unprivileged: False
- UserNamespace: True
- VMGuestTrigger: True
- VMHostTrigger: False
- NetworkTrigger: False
- RemoteTrigger: False
- PeripheralTrigger: False
- FilesystemTrigger: False
My final assessment is an RCU stall caused by a softirq storm. The softirq storm, in turn, is a direct result of a layer 2 network loopβan Ethernet broadcast storm, created through bridging interfaces (veth pairs, etc.) and flooded packets. This consumes all CPU time, leading to the RCU stall. This requires `CAP_NET_ADMIN` to configure, which is accessible to unprivileged users via user namespaces. It's a local DoS, not a memory corruption vulnerability or privilege escalation vector.
|
| 33/2 |
2026/05/26 00:08 |
tool |
set-results |
0m
Args: map[DenialOfService:true Exploitable:false FilesystemTrigger:false NetworkTrigger:false PeripheralTrigger:false RemoteTrigger:false Unprivileged:false UserNamespace:true VMGuestTrigger:true VMHostTrigger:false]
Results: map[DenialOfService:true Exploitable:false FilesystemTrigger:false NetworkTrigger:false PeripheralTrigger:false RemoteTrigger:false Unprivileged:false UserNamespace:true VMGuestTrigger:true VMHostTrigger:false]
|
| 34/2 |
2026/05/26 00:08 |
llm |
expert |
0m
Model:
Tokens:
input: 43049
output: 721
thoughts: 128
Thoughts: **Finalizing the Diagnosis**
Alright, the analysis is complete, and the pieces have fallen into place. It's time to craft the final response.
The evidence is undeniable. Those stack traces clearly reveal the culprit: a network loop caused by a bridge flooding packets with its own MAC address. This is textbook stuff. We're seeing the CPU get hammered processing `net_rx_action` within softirqs. That constant barrage of incoming packets is starving other tasks, and critically, the RCU grace period kthread, which ultimately leads to an RCU stall β a classic manifestation of a broadcast storm DoS.
From a practical perspective, this requires `CAP_NET_ADMIN` to configure the bridge and veth interfaces. That means it is accessible through user namespaces. However, the good news is that this isn't a memory corruption vulnerability. This makes exploitation significantly more challenging, which means we can rule out that concern.
|
| 35/1 |
2026/05/26 00:08 |
action |
format-explanation |
0m
Results: map[Explanation:**Analysis of the Bug Report**
**1. Nature of the Bug:**
The bug report indicates an RCU (Read-Copy-Update) stall. The kernel logs show:
* `rcu: INFO: rcu_preempt detected stalls on CPUs/tasks:`
* `rcu: rcu_preempt kthread starved for 3256 jiffies!`
* Repeated warnings: `bridge0: received packet on bridge_slave_0 with own
address as source address`
The stack traces reveal that the CPU is heavily occupied with processing network
packets in the softirq context (`net_rx_action` -> `process_backlog` ->
`br_handle_frame` -> `br_flood` -> `dev_queue_xmit`).
This is a classic Layer 2 network loop (broadcast storm). When interfaces (like
`veth` pairs) are bridged together in a loop without Spanning Tree Protocol
(STP) enabled or properly configured, a single broadcast or multicast packet
will be flooded endlessly across the loop.
Because the packet processing happens in the `NET_RX_SOFTIRQ` context, the
continuous stream of looping packets consumes 100% of the CPU. This softirq
storm starves other normal tasks on the CPU. In this specific crash, a task
(`syz.3.109`) was preempted by a timer interrupt while holding an
`rcu_read_lock()` (during KASAN stack unwinding). Because the CPU was
subsequently overwhelmed by the network softirq storm, the preempted task never
got a chance to resume and release the RCU lock, completely blocking the RCU
grace period and triggering the RCU stall detector.
**2. Security Impact:**
* **Exploitable:** No. This is a resource exhaustion issue (CPU starvation).
There is no memory corruption, use-after-free, or out-of-bounds access involved.
The KASAN frames in the stack trace are merely KASAN performing routine memory
checks during stack unwinding triggered by the RCU stall detector, not a bug
detection.
* **Denial of Service:** Yes. The broadcast storm consumes all available CPU
cycles on the affected cores, leading to RCU stalls, soft lockups, and
eventually a kernel panic (if `panic_on_rcu_stall` or `softlockup_panic` is
enabled).
* **Accessible From Unprivileged Processes:** No. Creating network bridges,
`veth` pairs, and altering their topology requires `CAP_NET_ADMIN` privileges.
* **Accessible From User Namespaces:** Yes. An unprivileged user can create a
new user namespace and a new network namespace. Within this isolated network
namespace, the user gains `CAP_NET_ADMIN` and can freely create bridges, `veth`
interfaces, and intentionally wire them into a loop to trigger the softirq storm
on the host CPU.
* **Network Trigger:** False. While it involves network packets, the root cause
is the malicious/misconfigured local network topology setup. A remote attacker
cannot trigger this unless the administrator has already misconfigured the
network to contain a loop.
**Conclusion:**
This is a local Denial-of-Service (DoS) vulnerability caused by a softirq
broadcast storm. It is not exploitable for privilege escalation or code
execution but can be reliably triggered by an unprivileged user leveraging user
and network namespaces to exhaust host CPU resources.]
|