KASAN: slab-out-of-bounds Read in sk_skb_adjust_room

Status: upstream: reported C repro on 2026/10/05 01:06
Reported-by: syzbot+4cd99872eba48e59d844@syzkaller.appspotmail.com
First crash: 2d02h, last: 2d01h
▶ ▼ Similar bugs (3)
Kernel Title Rank 🛈 Repro Cause bisect Fix bisect Count Last Reported Patched Status
linux-5.15 KASAN: slab-out-of-bounds Read in sk_skb_adjust_room 17 syz, C 6 1d19h 2d06h 0/3 upstream: reported C repro on 2026/10/04 20:39
linux-6.1 KASAN: slab-out-of-bounds Read in sk_skb_adjust_room 17 syz, C 10 1d07h 2d10h 0/3 upstream: reported C repro on 2026/10/04 16:38
android-6-1 KASAN: use-after-free Read in sk_skb_adjust_room 19 syz, C 12 1d14h 2d01h 0/2 upstream: reported C repro on 2026/10/05 01:18

Sample crash report:
==================================================================
BUG: KASAN: slab-out-of-bounds in tls_get_ctx include/net/tls.h:507 [inline]
BUG: KASAN: slab-out-of-bounds in tls_sw_has_ctx_rx include/net/tls.h:615 [inline]
BUG: KASAN: slab-out-of-bounds in ____sk_skb_adjust_room net/core/filter.c:3646 [inline]
BUG: KASAN: slab-out-of-bounds in sk_skb_adjust_room+0x389/0x5c0 net/core/filter.c:3623
Read of size 8 at addr ffff8881257894e8 by task syz-executor309/303

CPU: 0 PID: 303 Comm: syz-executor309 Not tainted syzkaller #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 09/16/2026
Call Trace:
 <TASK>
 __dump_stack+0x21/0x30 lib/dump_stack.c:88
 dump_stack_lvl+0x110/0x170 lib/dump_stack.c:106
 print_address_description+0x7f/0x2c0 mm/kasan/report.c:248
 __kasan_report mm/kasan/report.c:427 [inline]
 kasan_report+0x10f/0x150 mm/kasan/report.c:444
 __asan_report_load8_noabort+0x14/0x20 mm/kasan/report_generic.c:309
 tls_get_ctx include/net/tls.h:507 [inline]
 tls_sw_has_ctx_rx include/net/tls.h:615 [inline]
 ____sk_skb_adjust_room net/core/filter.c:3646 [inline]
 sk_skb_adjust_room+0x389/0x5c0 net/core/filter.c:3623
 bpf_prog_e15ab8bd9cea3c06+0x19/0x708
 bpf_dispatcher_nop_func include/linux/bpf.h:786 [inline]
 __bpf_prog_run include/linux/filter.h:628 [inline]
 bpf_prog_run include/linux/filter.h:635 [inline]
 bpf_prog_run_pin_on_cpu include/linux/filter.h:652 [inline]
 sk_psock_verdict_recv+0x245/0x7f0 net/core/skmsg.c:1233
 unix_read_sock+0x108/0x2d0 net/unix/af_unix.c:2439
 unix_stream_read_sock+0x61/0x90 net/unix/af_unix.c:2615
 sk_psock_verdict_data_ready+0x167/0x1d0 net/core/skmsg.c:1256
 unix_stream_sendmsg+0x7d1/0xc90 net/unix/af_unix.c:2117
 sock_sendmsg_nosec net/socket.c:704 [inline]
 __sock_sendmsg net/socket.c:716 [inline]
 __sys_sendto+0x46d/0x620 net/socket.c:2063
 __do_sys_sendto net/socket.c:2075 [inline]
 __se_sys_sendto net/socket.c:2071 [inline]
 __x64_sys_sendto+0xe5/0x100 net/socket.c:2071
 x64_sys_call+0x178/0x9a0 arch/x86/include/generated/asm/syscalls_64.h:45
 do_syscall_x64 arch/x86/entry/common.c:50 [inline]
 do_syscall_64+0x4c/0xa0 arch/x86/entry/common.c:80
 entry_SYSCALL_64_after_hwframe+0x66/0xd0
RIP: 0033:0x7f8021caee79
Code: c0 79 93 eb d5 48 8d 7c 1d 00 eb 99 0f 1f 44 00 00 48 89 f8 48 89 f7 48 89 d6 48 89 ca 4d 89 c2 4d 89 c8 4c 8b 4c 24 08 0f 05 <48> 3d 01 f0 ff ff 73 01 c3 48 c7 c1 d8 ff ff ff f7 d8 64 89 01 48
RSP: 002b:00007ffccbfdd368 EFLAGS: 00000246 ORIG_RAX: 000000000000002c
RAX: ffffffffffffffda RBX: 00007ffccbfdd4a8 RCX: 00007f8021caee79
RDX: 0000000000000001 RSI: 0000200000000800 RDI: 0000000000000004
RBP: 0000000000000001 R08: 0000000000000000 R09: 0000000000000000
R10: 0000000000000000 R11: 0000000000000246 R12: 00007ffccbfdd498
R13: 0000000000000002 R14: 00007f8021d3fca0 R15: 0000000000000002
 </TASK>

Allocated by task 303:
 kasan_save_stack mm/kasan/common.c:38 [inline]
 kasan_set_track mm/kasan/common.c:45 [inline]
 set_alloc_info mm/kasan/common.c:433 [inline]
 __kasan_slab_alloc+0xb7/0xe0 mm/kasan/common.c:466
 kasan_slab_alloc include/linux/kasan.h:217 [inline]
 slab_post_alloc_hook+0x4f/0x2b0 mm/slab.h:550
 slab_alloc_node mm/slub.c:3245 [inline]
 slab_alloc mm/slub.c:3255 [inline]
 kmem_cache_alloc+0xf7/0x260 mm/slub.c:3260
 sk_prot_alloc+0x5f/0x320 net/core/sock.c:1861
 sk_alloc+0x38/0x430 net/core/sock.c:1927
 unix_create1+0xb4/0x610 net/unix/af_unix.c:-1
 unix_create+0x149/0x200 net/unix/af_unix.c:933
 __sock_create+0x38d/0x7a0 net/socket.c:1486
 sock_create net/socket.c:1542 [inline]
 __sys_socketpair+0x1a1/0x590 net/socket.c:1642
 __do_sys_socketpair net/socket.c:1695 [inline]
 __se_sys_socketpair net/socket.c:1692 [inline]
 __x64_sys_socketpair+0x9b/0xb0 net/socket.c:1692
 x64_sys_call+0x36/0x9a0 arch/x86/include/generated/asm/syscalls_64.h:54
 do_syscall_x64 arch/x86/entry/common.c:50 [inline]
 do_syscall_64+0x4c/0xa0 arch/x86/entry/common.c:80
 entry_SYSCALL_64_after_hwframe+0x66/0xd0

The buggy address belongs to the object at ffff888125788fc0
 which belongs to the cache UNIX-STREAM of size 1216
The buggy address is located 104 bytes to the right of
 1216-byte region [ffff888125788fc0, ffff888125789480)
The buggy address belongs to the page:
page:ffffea000495e200 refcount:1 mapcount:0 mapping:0000000000000000 index:0x0 pfn:0x125788
head:ffffea000495e200 order:2 compound_mapcount:0 compound_pincount:0
flags: 0x4000000000010200(slab|head|zone=1)
raw: 4000000000010200 0000000000000000 dead000000000122 ffff8881003e7080
raw: 0000000000000000 00000000800c000c 00000001ffffffff 0000000000000000
page dumped because: kasan: bad access detected
page_owner tracks the page as allocated
page last allocated via order 2, migratetype Unmovable, gfp_mask 0xd20c0(__GFP_IO|__GFP_FS|__GFP_NOWARN|__GFP_NORETRY|__GFP_COMP|__GFP_NOMEMALLOC), pid 303, ts 25723889203, free_ts 25709206982
 set_page_owner include/linux/page_owner.h:33 [inline]
 post_alloc_hook+0x192/0x1b0 mm/page_alloc.c:2607
 prep_new_page+0x1c/0x110 mm/page_alloc.c:2613
 get_page_from_freelist+0x2c3a/0x2cd0 mm/page_alloc.c:4487
 __alloc_pages+0x1a2/0x460 mm/page_alloc.c:5824
 alloc_slab_page mm/slub.c:-1 [inline]
 allocate_slab mm/slub.c:1937 [inline]
 new_slab+0xa0/0x4d0 mm/slub.c:2000
 ___slab_alloc+0x3ac/0x840 mm/slub.c:3033
 __slab_alloc+0x49/0x90 mm/slub.c:3120
 slab_alloc_node mm/slub.c:3211 [inline]
 slab_alloc mm/slub.c:3255 [inline]
 kmem_cache_alloc+0x138/0x260 mm/slub.c:3260
 sk_prot_alloc+0x5f/0x320 net/core/sock.c:1861
 sk_alloc+0x38/0x430 net/core/sock.c:1927
 unix_create1+0xb4/0x610 net/unix/af_unix.c:-1
 unix_create+0x149/0x200 net/unix/af_unix.c:933
 __sock_create+0x38d/0x7a0 net/socket.c:1486
 sock_create net/socket.c:1542 [inline]
 __sys_socketpair+0x1a1/0x590 net/socket.c:1642
 __do_sys_socketpair net/socket.c:1695 [inline]
 __se_sys_socketpair net/socket.c:1692 [inline]
 __x64_sys_socketpair+0x9b/0xb0 net/socket.c:1692
 x64_sys_call+0x36/0x9a0 arch/x86/include/generated/asm/syscalls_64.h:54
page last free stack trace:
 reset_page_owner include/linux/page_owner.h:26 [inline]
 free_pages_prepare mm/page_alloc.c:1474 [inline]
 free_pcp_prepare mm/page_alloc.c:1546 [inline]
 free_unref_page_prepare+0x5fa/0x600 mm/page_alloc.c:3536
 free_unref_page+0xae/0x540 mm/page_alloc.c:3618
 free_the_page mm/page_alloc.c:805 [inline]
 __free_pages+0x6c/0x100 mm/page_alloc.c:5900
 free_pages+0x82/0x90 mm/page_alloc.c:5911
 __stack_depot_save+0x453/0x480 lib/stackdepot.c:358
 kasan_save_stack mm/kasan/common.c:39 [inline]
 kasan_set_track mm/kasan/common.c:45 [inline]
 set_alloc_info mm/kasan/common.c:433 [inline]
 ____kasan_kmalloc mm/kasan/common.c:512 [inline]
 __kasan_kmalloc+0xe6/0x100 mm/kasan/common.c:521
 kasan_kmalloc include/linux/kasan.h:227 [inline]
 __kmalloc_track_caller+0x13c/0x2c0 mm/slub.c:4959
 kmemdup+0x26/0x60 mm/util.c:132
 sidtab_sid2str_get+0x137/0x2c0 security/selinux/ss/sidtab.c:615
 sidtab_entry_to_string security/selinux/ss/services.c:1293 [inline]
 security_sid_to_context_core+0x2ac/0x480 security/selinux/ss/services.c:1386
 security_sid_to_context+0x33/0x40 security/selinux/ss/services.c:1409
 avc_audit_post_callback+0x135/0x830 security/selinux/avc.c:724
 common_lsm_audit+0x12b9/0x1670 security/lsm_audit.c:469
 slow_avc_audit+0x1c4/0x240 security/selinux/avc.c:802
 avc_audit security/selinux/include/avc.h:135 [inline]
 avc_has_perm+0x1fb/0x250 security/selinux/avc.c:1190
 file_map_prot_check+0x199/0x270 security/selinux/hooks.c:3867

Memory state around the buggy address:
 ffff888125789380: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
 ffff888125789400: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
>ffff888125789480: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc
                                                          ^
 ffff888125789500: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc
 ffff888125789580: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc
========================================

Crashes (4):
Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Assets (help?) Manager Title
2026/10/05 01:23 android13-5.15-lts f5eaed2bbe33 57bbd979 .config strace log report syz / log C [disk image] [vmlinux] [kernel image] ci2-android-5-15 KASAN: slab-out-of-bounds Read in sk_skb_adjust_room
2026/10/05 01:03 android13-5.15-lts f5eaed2bbe33 57bbd979 .config strace log report syz / log C [disk image] [vmlinux] [kernel image] ci2-android-5-15 KASAN: slab-out-of-bounds Read in sk_skb_adjust_room
2026/10/05 00:44 android13-5.15-lts f5eaed2bbe33 57bbd979 .config console log report info [disk image] [vmlinux] [kernel image] ci2-android-5-15 KASAN: slab-out-of-bounds Read in sk_skb_adjust_room
2026/10/05 00:44 android13-5.15-lts f5eaed2bbe33 57bbd979 .config console log report info [disk image] [vmlinux] [kernel image] ci2-android-5-15 KASAN: slab-out-of-bounds Read in sk_skb_adjust_room
* Struck through repros no longer work on HEAD.