KASAN: use-after-free Read in l2cap_connect_cfm (2)

Status: auto-obsoleted due to no activity on 2026/11/14 20:45
Bug presence: origin:lts-only
[Documentation on labels]
Reported-by: syzbot+d68bdee064365af6ea43@syzkaller.appspotmail.com
First crash: 419d, last: 152d
Fix bisection: the issue occurs on the latest tested release (bisect log)
Crash: KASAN: use-after-free Read in l2cap_connect_cfm (log)
Repro: C syz .config
  
▶ ▼ Bug presence (2)
Date Name Commit Repro Result
2025/09/26 linux-5.15.y (ToT) 43bb85222e53 C [report] KASAN: use-after-free Read in l2cap_connect_cfm
2025/09/26 upstream (ToT) fec734e8d564 C Didn't crash
▶ ▼ Similar bugs (6)
Kernel Title Rank 🛈 Repro Cause bisect Fix bisect Count Last Reported Patched Status
linux-6.1 KASAN: wild-memory-access Read in l2cap_connect_cfm 19 7 172d 411d 0/3 auto-obsoleted due to no activity on 2026/09/06 15:11
linux-5.15 KASAN: use-after-free Read in l2cap_connect_cfm 19 3 551d 650d 0/3 auto-obsoleted due to no activity on 2025/08/23 07:27
linux-6.1 KASAN: use-after-free Read in l2cap_connect_cfm 19 6 538d 759d 0/3 auto-obsoleted due to no activity on 2025/09/05 21:35
upstream KASAN: slab-use-after-free Read in l2cap_connect_cfm bluetooth 19 syz inconclusive 36 621d 700d 0/29 closed as invalid on 2025/03/07 00:26
upstream KASAN: wild-memory-access Read in l2cap_connect_cfm prio:high bluetooth 19 syz, C error inconclusive 345 141d 610d 0/29 auto-obsoleted due to no activity on 2026/10/17 13:12
linux-6.6 KASAN: slab-use-after-free Read in l2cap_connect_cfm origin:upstream 19 syz, C error 23 152d 425d 0/2 auto-obsoleted due to no activity on 2026/09/26 01:45
▶ ▼ Last patch testing requests (5)
Created Duration User Patch Repo Result
2026/11/14 20:25 18m retest repro linux-5.15.y no crash job log log
2026/08/26 18:03 0m retest repro linux-5.15.y error job log
2026/06/15 05:23 25m retest repro linux-5.15.y report log
2026/04/01 03:17 1h11m retest repro linux-5.15.y report log
2026/01/20 20:18 15m retest repro linux-5.15.y report log
▶ ▼ Fix bisection attempts (7)
Created Duration User Patch Repo Result
2026/06/22 03:59 12h39m fix candidate upstream error job log
2026/04/24 10:12 16m fix candidate upstream error job log
2026/03/24 19:32 1m fix candidate upstream error job log
2026/02/22 19:16 1m fix candidate upstream error job log
2026/01/23 06:47 1m fix candidate upstream error job log
2025/11/16 20:38 12h05m fix candidate upstream error job log
2025/11/06 08:24 2h17m bisect fix linux-5.15.y OK (0) job log log

Sample crash report:
kobject_add_internal failed for hci3:201 with -EEXIST, don't try to register things with the same name in the same directory.
Bluetooth: hci3: failed to register connection device
==================================================================
BUG: KASAN: use-after-free in l2cap_conn_ready net/bluetooth/l2cap_core.c:1759 [inline]
BUG: KASAN: use-after-free in l2cap_connect_cfm+0x6ff/0x10f0 net/bluetooth/l2cap_core.c:8387
Read of size 8 at addr ffff888071ca9488 by task kworker/u5:5/4203

CPU: 1 PID: 4203 Comm: kworker/u5:5 Not tainted syzkaller #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 05/09/2026
Workqueue: hci3 hci_rx_work
Call Trace:
 <TASK>
 dump_stack_lvl+0x188/0x250 lib/dump_stack.c:106
 print_address_description+0x60/0x2d0 mm/kasan/report.c:248
 __kasan_report mm/kasan/report.c:434 [inline]
 kasan_report+0xdf/0x130 mm/kasan/report.c:451
 l2cap_conn_ready net/bluetooth/l2cap_core.c:1759 [inline]
 l2cap_connect_cfm+0x6ff/0x10f0 net/bluetooth/l2cap_core.c:8387
 hci_connect_cfm include/net/bluetooth/hci_core.h:1507 [inline]
 le_conn_complete_evt+0xd45/0x15c0 net/bluetooth/hci_event.c:5456
 hci_le_conn_complete_evt net/bluetooth/hci_event.c:5481 [inline]
 hci_le_meta_evt+0x285/0x3cb0 net/bluetooth/hci_event.c:6203
 hci_event_packet+0xe4b/0x1370 net/bluetooth/hci_event.c:6552
 hci_rx_work+0x255/0xa10 net/bluetooth/hci_core.c:5190
 process_one_work+0x85f/0x1010 kernel/workqueue.c:2310
 worker_thread+0xaa6/0x1290 kernel/workqueue.c:2457
 kthread+0x436/0x520 kernel/kthread.c:334
 ret_from_fork+0x1f/0x30 arch/x86/entry/entry_64.S:287
 </TASK>

Allocated by task 4203:
 kasan_save_stack mm/kasan/common.c:38 [inline]
 kasan_set_track mm/kasan/common.c:46 [inline]
 set_alloc_info mm/kasan/common.c:434 [inline]
 ____kasan_kmalloc mm/kasan/common.c:513 [inline]
 __kasan_kmalloc+0xb5/0xf0 mm/kasan/common.c:522
 kmalloc include/linux/slab.h:607 [inline]
 kzalloc include/linux/slab.h:738 [inline]
 l2cap_chan_create+0x4c/0x730 net/bluetooth/l2cap_core.c:469
 l2cap_sock_alloc+0x13a/0x200 net/bluetooth/l2cap_sock.c:1894
 l2cap_sock_new_connection_cb+0xe0/0x1d0 net/bluetooth/l2cap_sock.c:1482
 l2cap_connect_cfm+0x35d/0x10f0 net/bluetooth/l2cap_core.c:8370
 hci_connect_cfm include/net/bluetooth/hci_core.h:1507 [inline]
 le_conn_complete_evt+0xd45/0x15c0 net/bluetooth/hci_event.c:5456
 hci_le_conn_complete_evt net/bluetooth/hci_event.c:5481 [inline]
 hci_le_meta_evt+0x285/0x3cb0 net/bluetooth/hci_event.c:6203
 hci_event_packet+0xe4b/0x1370 net/bluetooth/hci_event.c:6552
 hci_rx_work+0x255/0xa10 net/bluetooth/hci_core.c:5190
 process_one_work+0x85f/0x1010 kernel/workqueue.c:2310
 worker_thread+0xaa6/0x1290 kernel/workqueue.c:2457
 kthread+0x436/0x520 kernel/kthread.c:334
 ret_from_fork+0x1f/0x30 arch/x86/entry/entry_64.S:287

Freed by task 15041:
 kasan_save_stack mm/kasan/common.c:38 [inline]
 kasan_set_track+0x4b/0x70 mm/kasan/common.c:46
 kasan_set_free_info+0x1f/0x40 mm/kasan/generic.c:360
 ____kasan_slab_free+0xd5/0x110 mm/kasan/common.c:366
 kasan_slab_free include/linux/kasan.h:230 [inline]
 slab_free_hook mm/slub.c:1710 [inline]
 slab_free_freelist_hook+0xea/0x170 mm/slub.c:1736
 slab_free mm/slub.c:3504 [inline]
 kfree+0xef/0x2a0 mm/slub.c:4564
 l2cap_sock_cleanup_listen+0xea/0x270 net/bluetooth/l2cap_sock.c:1462
 l2cap_sock_release+0x66/0x1e0 net/bluetooth/l2cap_sock.c:1420
 __sock_release net/socket.c:651 [inline]
 sock_close+0xd5/0x240 net/socket.c:1345
 __fput+0x234/0x930 fs/file_table.c:311
 task_work_run+0x125/0x1a0 kernel/task_work.c:188
 tracehook_notify_resume include/linux/tracehook.h:189 [inline]
 exit_to_user_mode_loop+0x10f/0x130 kernel/entry/common.c:181
 exit_to_user_mode_prepare+0xee/0x180 kernel/entry/common.c:214
 __syscall_exit_to_user_mode_work kernel/entry/common.c:296 [inline]
 syscall_exit_to_user_mode+0x16/0x40 kernel/entry/common.c:307
 do_syscall_64+0x58/0xa0 arch/x86/entry/common.c:86
 entry_SYSCALL_64_after_hwframe+0x66/0xd0

Last potentially related work creation:
 kasan_save_stack+0x35/0x60 mm/kasan/common.c:38
 kasan_record_aux_stack+0xb8/0x100 mm/kasan/generic.c:348
 __call_rcu kernel/rcu/tree.c:3011 [inline]
 call_rcu+0x189/0x950 kernel/rcu/tree.c:3091
 __vlan_del+0x77c/0x920 net/bridge/br_vlan.c:388
 __vlan_flush net/bridge/br_vlan.c:420 [inline]
 br_vlan_flush+0x23e/0x3b0 net/bridge/br_vlan.c:787
 br_dev_uninit+0x2a/0x70 net/bridge/br_device.c:170
 unregister_netdevice_many+0x1417/0x19f0 net/core/dev.c:11177
 default_device_exit_batch+0x364/0x3c0 net/core/dev.c:11693
 ops_exit_list net/core/net_namespace.c:177 [inline]
 cleanup_net+0x791/0xba0 net/core/net_namespace.c:635
 process_one_work+0x85f/0x1010 kernel/workqueue.c:2310
 worker_thread+0xaa6/0x1290 kernel/workqueue.c:2457
 kthread+0x436/0x520 kernel/kthread.c:334
 ret_from_fork+0x1f/0x30 arch/x86/entry/entry_64.S:287

The buggy address belongs to the object at ffff888071ca9000
 which belongs to the cache kmalloc-2k of size 2048
The buggy address is located 1160 bytes inside of
 2048-byte region [ffff888071ca9000, ffff888071ca9800)
The buggy address belongs to the page:
page:ffffea0001c72a00 refcount:1 mapcount:0 mapping:0000000000000000 index:0x0 pfn:0x71ca8
head:ffffea0001c72a00 order:3 compound_mapcount:0 compound_pincount:0
flags: 0xfff00000010200(slab|head|node=0|zone=1|lastcpupid=0x7ff)
raw: 00fff00000010200 0000000000000000 0000000100000001 ffff888016c42000
raw: 0000000000000000 0000000080080008 00000001ffffffff 0000000000000000
page dumped because: kasan: bad access detected
page_owner tracks the page as allocated
page last allocated via order 3, migratetype Unmovable, gfp_mask 0x1d20c0(__GFP_IO|__GFP_FS|__GFP_NOWARN|__GFP_NORETRY|__GFP_COMP|__GFP_NOMEMALLOC|__GFP_HARDWALL), pid 4942, ts 154116789247, free_ts 133359052040
 prep_new_page mm/page_alloc.c:2426 [inline]
 get_page_from_freelist+0x1bbd/0x1ca0 mm/page_alloc.c:4192
 __alloc_pages+0x1ee/0x480 mm/page_alloc.c:5501
 alloc_slab_page mm/slub.c:1780 [inline]
 allocate_slab mm/slub.c:1917 [inline]
 new_slab+0xc0/0x4b0 mm/slub.c:1980
 ___slab_alloc+0x80a/0xdd0 mm/slub.c:3013
 __slab_alloc mm/slub.c:3100 [inline]
 slab_alloc_node mm/slub.c:3191 [inline]
 slab_alloc mm/slub.c:3233 [inline]
 kmem_cache_alloc_trace+0x1a5/0x2a0 mm/slub.c:3250
 kmalloc include/linux/slab.h:607 [inline]
 kzalloc include/linux/slab.h:738 [inline]
 nbp_vlan_add+0x1d7/0x370 net/bridge/br_vlan.c:1271
 br_vlan_info+0xfd/0x460 net/bridge/br_netlink.c:657
 br_process_vlan_info+0x545/0x7f0 net/bridge/br_netlink.c:720
 br_afspec+0x1ec/0x4d0 net/bridge/br_netlink.c:788
 br_setlink+0x2da/0x8c0 net/bridge/br_netlink.c:1030
 rtnl_bridge_setlink+0x4ba/0x720 net/core/rtnetlink.c:5023
 rtnetlink_rcv_msg+0x844/0xf30 net/core/rtnetlink.c:5688
 netlink_rcv_skb+0x1f5/0x440 net/netlink/af_netlink.c:2507
 netlink_unicast_kernel net/netlink/af_netlink.c:1318 [inline]
 netlink_unicast+0x774/0x920 net/netlink/af_netlink.c:1344
 netlink_sendmsg+0x8ba/0xbe0 net/netlink/af_netlink.c:1918
 sock_sendmsg_nosec net/socket.c:706 [inline]
 __sock_sendmsg net/socket.c:718 [inline]
 ____sys_sendmsg+0x5b7/0x8f0 net/socket.c:2445
page last free stack trace:
 reset_page_owner include/linux/page_owner.h:24 [inline]
 free_pages_prepare mm/page_alloc.c:1340 [inline]
 free_pcp_prepare mm/page_alloc.c:1391 [inline]
 free_unref_page_prepare+0x637/0x6c0 mm/page_alloc.c:3317
 free_unref_page+0x8f/0x2a0 mm/page_alloc.c:3396
 __vunmap+0x8b9/0xa50 mm/vmalloc.c:2628
 kcov_put kernel/kcov.c:417 [inline]
 kcov_close+0x27/0x50 kernel/kcov.c:519
 __fput+0x234/0x930 fs/file_table.c:311
 task_work_run+0x125/0x1a0 kernel/task_work.c:188
 exit_task_work include/linux/task_work.h:33 [inline]
 do_exit+0x626/0x20c0 kernel/exit.c:884
 do_group_exit+0x12e/0x300 kernel/exit.c:998
 get_signal+0x6d6/0x12d0 kernel/signal.c:2900
 arch_do_signal_or_restart+0xe7/0x12c0 arch/x86/kernel/signal.c:867
 handle_signal_work kernel/entry/common.c:154 [inline]
 exit_to_user_mode_loop+0x9e/0x130 kernel/entry/common.c:178
 exit_to_user_mode_prepare+0xee/0x180 kernel/entry/common.c:214
 __syscall_exit_to_user_mode_work kernel/entry/common.c:296 [inline]
 syscall_exit_to_user_mode+0x16/0x40 kernel/entry/common.c:307
 do_syscall_64+0x58/0xa0 arch/x86/entry/common.c:86
 entry_SYSCALL_64_after_hwframe+0x66/0xd0

Memory state around the buggy address:
 ffff888071ca9380: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb
 ffff888071ca9400: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb
>ffff888071ca9480: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb
                      ^
 ffff888071ca9500: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb
 ffff888071ca9580: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb
==================================================================

Crashes (17):
Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Assets (help?) Manager Title
2026/06/17 23:26 linux-5.15.y dc027a595035 b62b3ded .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan KASAN: use-after-free Read in l2cap_connect_cfm
2026/05/22 23:29 linux-5.15.y 93741761e5e3 5f091fcc .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan KASAN: use-after-free Read in l2cap_connect_cfm
2026/05/19 12:27 linux-5.15.y 93741761e5e3 223544dc .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan KASAN: use-after-free Read in l2cap_connect_cfm
2026/05/16 14:49 linux-5.15.y 93741761e5e3 a15a64a6 .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan KASAN: use-after-free Read in l2cap_connect_cfm
2026/05/06 22:46 linux-5.15.y ef251c45f1cd 1dddfd3d .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan KASAN: use-after-free Read in l2cap_connect_cfm
2026/02/20 10:43 linux-5.15.y 3330a8d33e08 17d780d6 .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan KASAN: use-after-free Read in l2cap_connect_cfm
2026/02/19 11:49 linux-5.15.y e45d5d41c134 746545b8 .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan KASAN: use-after-free Read in l2cap_connect_cfm
2026/02/19 11:49 linux-5.15.y e45d5d41c134 746545b8 .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan KASAN: use-after-free Read in l2cap_connect_cfm
2026/02/19 08:52 linux-5.15.y e45d5d41c134 746545b8 .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan KASAN: use-after-free Read in l2cap_connect_cfm
2026/02/07 04:13 linux-5.15.y 7b232985052f f20fc9f9 .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan KASAN: use-after-free Read in l2cap_connect_cfm
2026/01/28 02:13 linux-5.15.y 9eec9a14ee10 3029c699 .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan KASAN: use-after-free Read in l2cap_connect_cfm
2026/01/26 19:14 linux-5.15.y 9eec9a14ee10 a4c52dd6 .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan KASAN: use-after-free Read in l2cap_connect_cfm
2026/01/23 16:11 linux-5.15.y 9eec9a14ee10 e2b1b6e6 .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan KASAN: use-after-free Read in l2cap_connect_cfm
2025/12/16 14:41 linux-5.15.y 68efe5a6c16a d6526ea3 .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan KASAN: use-after-free Read in l2cap_connect_cfm
2025/09/25 04:25 linux-5.15.y 43bb85222e53 0abd0691 .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan KASAN: use-after-free Read in l2cap_connect_cfm
2025/09/25 00:04 linux-5.15.y 43bb85222e53 0abd0691 .config console log report syz / log C [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan KASAN: use-after-free Read in l2cap_connect_cfm
2025/09/24 14:25 linux-5.15.y 43bb85222e53 0abd0691 .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan KASAN: use-after-free Read in l2cap_connect_cfm
* Struck through repros no longer work on HEAD.