[Android 6.1] KASAN: use-after-free Read in unix_stream_read_actor

3 views
Skip to first unread message

syzbot

unread,
Nov 10, 2023, 8:48:24 PM11/10/23
to syzkaller-a...@googlegroups.com
Hello,

syzbot found the following issue on:

HEAD commit: 48c6c901fe0e ANDROID: fs/passthrough: Fix compatibility wi..
git tree: android14-6.1
console output: https://syzkaller.appspot.com/x/log.txt?x=15ad277b680000
kernel config: https://syzkaller.appspot.com/x/.config?x=e9500dd6486f6367
dashboard link: https://syzkaller.appspot.com/bug?extid=0d6bc5d3e48bd509f184
compiler: Debian clang version 15.0.6, GNU ld (GNU Binutils for Debian) 2.40
syz repro: https://syzkaller.appspot.com/x/repro.syz?x=13732ca7680000
C reproducer: https://syzkaller.appspot.com/x/repro.c?x=144c7338e80000

Downloadable assets:
disk image: https://storage.googleapis.com/syzbot-assets/07676d890c1b/disk-48c6c901.raw.xz
vmlinux: https://storage.googleapis.com/syzbot-assets/71410f5a36d8/vmlinux-48c6c901.xz
kernel image: https://storage.googleapis.com/syzbot-assets/6cbdb22eb078/bzImage-48c6c901.xz

IMPORTANT: if you fix the issue, please add the following tag to the commit:
Reported-by: syzbot+0d6bc5...@syzkaller.appspotmail.com

==================================================================
BUG: KASAN: use-after-free in unix_stream_read_actor+0xa3/0xb0 net/unix/af_unix.c:2920
Read of size 4 at addr ffff888109da2a44 by task syz-executor366/445

CPU: 1 PID: 445 Comm: syz-executor366 Not tainted 6.1.43-syzkaller-00006-g48c6c901fe0e #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 10/09/2023
Call Trace:
<TASK>
__dump_stack lib/dump_stack.c:88 [inline]
dump_stack_lvl+0x151/0x1b7 lib/dump_stack.c:106
print_address_description mm/kasan/report.c:316 [inline]
print_report+0x158/0x4e0 mm/kasan/report.c:427
kasan_report+0x13c/0x170 mm/kasan/report.c:531
__asan_report_load4_noabort+0x14/0x20 mm/kasan/report_generic.c:350
unix_stream_read_actor+0xa3/0xb0 net/unix/af_unix.c:2920
unix_stream_recv_urg+0x1b4/0x300 net/unix/af_unix.c:2647
unix_stream_read_generic+0x2140/0x2220 net/unix/af_unix.c:2726
unix_stream_recvmsg+0x222/0x2b0 net/unix/af_unix.c:2957
____sys_recvmsg+0x285/0x530
___sys_recvmsg net/socket.c:2743 [inline]
__sys_recvmsg+0x2e9/0x3d0 net/socket.c:2773
__do_sys_recvmsg net/socket.c:2783 [inline]
__se_sys_recvmsg net/socket.c:2780 [inline]
__x64_sys_recvmsg+0x7f/0x90 net/socket.c:2780
do_syscall_x64 arch/x86/entry/common.c:50 [inline]
do_syscall_64+0x3d/0xb0 arch/x86/entry/common.c:80
entry_SYSCALL_64_after_hwframe+0x63/0xcd
RIP: 0033:0x7f5e75189989
Code: 28 00 00 00 75 05 48 83 c4 28 c3 e8 61 1b 00 00 90 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 b0 ff ff ff f7 d8 64 89 01 48
RSP: 002b:00007f5e75100228 EFLAGS: 00000246 ORIG_RAX: 000000000000002f
RAX: ffffffffffffffda RBX: 0000000000000023 RCX: 00007f5e75189989
RDX: 0000000040010083 RSI: 0000000020000140 RDI: 0000000000000004
RBP: 00007f5e7520c408 R08: 00007f5e751006c0 R09: 00007f5e751006c0
R10: 0000000000000000 R11: 0000000000000246 R12: 00007f5e7520c400
R13: 00007f5e7520c40c R14: 00007ffe5b635d80 R15: 00007ffe5b635e68
</TASK>

Allocated by task 444:
kasan_save_stack mm/kasan/common.c:45 [inline]
kasan_set_track+0x4b/0x70 mm/kasan/common.c:52
kasan_save_alloc_info+0x1f/0x30 mm/kasan/generic.c:505
__kasan_slab_alloc+0x6c/0x80 mm/kasan/common.c:333
kasan_slab_alloc include/linux/kasan.h:202 [inline]
slab_post_alloc_hook+0x53/0x2c0 mm/slab.h:768
slab_alloc_node mm/slub.c:3418 [inline]
kmem_cache_alloc_node+0x18a/0x2d0 mm/slub.c:3463
__alloc_skb+0xcc/0x2e0 net/core/skbuff.c:497
alloc_skb include/linux/skbuff.h:1275 [inline]
alloc_skb_with_frags+0xa6/0x680 net/core/skbuff.c:6148
sock_alloc_send_pskb+0x915/0xa50 net/core/sock.c:2732
sock_alloc_send_skb include/net/sock.h:1908 [inline]
queue_oob+0x102/0x8e0 net/unix/af_unix.c:2114
unix_stream_sendmsg+0xe10/0x1070 net/unix/af_unix.c:2251
sock_sendmsg_nosec net/socket.c:716 [inline]
sock_sendmsg net/socket.c:736 [inline]
____sys_sendmsg+0x5dc/0x9d0 net/socket.c:2482
___sys_sendmsg net/socket.c:2536 [inline]
__sys_sendmsg+0x2a9/0x390 net/socket.c:2565
__do_sys_sendmsg net/socket.c:2574 [inline]
__se_sys_sendmsg net/socket.c:2572 [inline]
__x64_sys_sendmsg+0x7f/0x90 net/socket.c:2572
do_syscall_x64 arch/x86/entry/common.c:50 [inline]
do_syscall_64+0x3d/0xb0 arch/x86/entry/common.c:80
entry_SYSCALL_64_after_hwframe+0x63/0xcd

Freed by task 444:
kasan_save_stack mm/kasan/common.c:45 [inline]
kasan_set_track+0x4b/0x70 mm/kasan/common.c:52
kasan_save_free_info+0x2b/0x40 mm/kasan/generic.c:516
____kasan_slab_free+0x131/0x180 mm/kasan/common.c:241
__kasan_slab_free+0x11/0x20 mm/kasan/common.c:249
kasan_slab_free include/linux/kasan.h:178 [inline]
slab_free_hook mm/slub.c:1744 [inline]
slab_free_freelist_hook mm/slub.c:1770 [inline]
slab_free mm/slub.c:3681 [inline]
kmem_cache_free+0x291/0x510 mm/slub.c:3703
kfree_skbmem+0x104/0x170
__kfree_skb net/core/skbuff.c:869 [inline]
consume_skb+0xb4/0x250 net/core/skbuff.c:1033
queue_oob+0x52c/0x8e0 net/unix/af_unix.c:2145
unix_stream_sendmsg+0xe10/0x1070 net/unix/af_unix.c:2251
sock_sendmsg_nosec net/socket.c:716 [inline]
sock_sendmsg net/socket.c:736 [inline]
____sys_sendmsg+0x5dc/0x9d0 net/socket.c:2482
___sys_sendmsg net/socket.c:2536 [inline]
__sys_sendmsg+0x2a9/0x390 net/socket.c:2565
__do_sys_sendmsg net/socket.c:2574 [inline]
__se_sys_sendmsg net/socket.c:2572 [inline]
__x64_sys_sendmsg+0x7f/0x90 net/socket.c:2572
do_syscall_x64 arch/x86/entry/common.c:50 [inline]
do_syscall_64+0x3d/0xb0 arch/x86/entry/common.c:80
entry_SYSCALL_64_after_hwframe+0x63/0xcd

The buggy address belongs to the object at ffff888109da2a00
which belongs to the cache skbuff_head_cache of size 256
The buggy address is located 68 bytes inside of
256-byte region [ffff888109da2a00, ffff888109da2b00)

The buggy address belongs to the physical page:
page:ffffea0004276880 refcount:1 mapcount:0 mapping:0000000000000000 index:0x0 pfn:0x109da2
flags: 0x4000000000000200(slab|zone=1)
raw: 4000000000000200 0000000000000000 dead000000000122 ffff888100b91800
raw: 0000000000000000 00000000000c000c 00000001ffffffff 0000000000000000
page dumped because: kasan: bad access detected
page_owner tracks the page as allocated
page last allocated via order 0, migratetype Unmovable, gfp_mask 0x12cc0(GFP_KERNEL|__GFP_NOWARN|__GFP_NORETRY), pid 444, tgid 442 (syz-executor366), ts 38100870369, free_ts 37664742630
set_page_owner include/linux/page_owner.h:33 [inline]
post_alloc_hook+0x213/0x220 mm/page_alloc.c:2586
prep_new_page+0x1b/0x110 mm/page_alloc.c:2593
get_page_from_freelist+0x2878/0x2910 mm/page_alloc.c:4410
__alloc_pages+0x3a1/0x780 mm/page_alloc.c:5698
allocate_slab mm/slub.c:1959 [inline]
new_slab+0xce/0x4c0 mm/slub.c:2012
___slab_alloc+0x6f9/0xb80 mm/slub.c:3200
__slab_alloc+0x5d/0xa0 mm/slub.c:3299
slab_alloc_node mm/slub.c:3384 [inline]
kmem_cache_alloc_node+0x1c9/0x2d0 mm/slub.c:3463
__alloc_skb+0xcc/0x2e0 net/core/skbuff.c:497
alloc_skb include/linux/skbuff.h:1275 [inline]
alloc_skb_with_frags+0xa6/0x680 net/core/skbuff.c:6148
sock_alloc_send_pskb+0x915/0xa50 net/core/sock.c:2732
sock_alloc_send_skb include/net/sock.h:1908 [inline]
queue_oob+0x102/0x8e0 net/unix/af_unix.c:2114
unix_stream_sendmsg+0xe10/0x1070 net/unix/af_unix.c:2251
sock_sendmsg_nosec net/socket.c:716 [inline]
sock_sendmsg net/socket.c:736 [inline]
____sys_sendmsg+0x5dc/0x9d0 net/socket.c:2482
___sys_sendmsg net/socket.c:2536 [inline]
__sys_sendmsg+0x2a9/0x390 net/socket.c:2565
__do_sys_sendmsg net/socket.c:2574 [inline]
__se_sys_sendmsg net/socket.c:2572 [inline]
__x64_sys_sendmsg+0x7f/0x90 net/socket.c:2572
page last free stack trace:
reset_page_owner include/linux/page_owner.h:26 [inline]
free_pages_prepare mm/page_alloc.c:1494 [inline]
free_pcp_prepare mm/page_alloc.c:1568 [inline]
free_unref_page_prepare+0x83d/0x850 mm/page_alloc.c:3500
free_unref_page_list+0xf6/0x6c0 mm/page_alloc.c:3649
release_pages+0xf7f/0xfe0 mm/swap.c:1055
free_pages_and_swap_cache+0x8a/0xa0 mm/swap_state.c:314
tlb_batch_pages_flush mm/mmu_gather.c:59 [inline]
tlb_flush_mmu_free mm/mmu_gather.c:254 [inline]
tlb_flush_mmu mm/mmu_gather.c:261 [inline]
tlb_finish_mmu+0x1e0/0x3f0 mm/mmu_gather.c:361
exit_mmap+0x3e5/0x8a0 mm/mmap.c:3329
__mmput+0x95/0x310 kernel/fork.c:1272
mmput+0x56/0x170 kernel/fork.c:1295
exit_mm kernel/exit.c:566 [inline]
do_exit+0xb29/0x2b80 kernel/exit.c:862
do_group_exit+0x21a/0x2d0 kernel/exit.c:1025
get_signal+0x169d/0x1820 kernel/signal.c:2879
arch_do_signal_or_restart+0xb0/0x16f0 arch/x86/kernel/signal.c:869
exit_to_user_mode_loop+0x6b/0xa0 kernel/entry/common.c:168
exit_to_user_mode_prepare+0x5a/0xa0 kernel/entry/common.c:204
__syscall_exit_to_user_mode_work kernel/entry/common.c:286 [inline]
syscall_exit_to_user_mode+0x26/0x130 kernel/entry/common.c:297
do_syscall_64+0x49/0xb0 arch/x86/entry/common.c:86

Memory state around the buggy address:
ffff888109da2900: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
ffff888109da2980: 00 00 00 00 00 00 00 00 fc fc fc fc fc fc fc fc
>ffff888109da2a00: fa fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb
^
ffff888109da2a80: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb
ffff888109da2b00: fc fc fc fc fc fc fc fc 00 00 00 00 00 00 00 00
==================================================================


---
This report is generated by a bot. It may contain errors.
See https://goo.gl/tpsmEJ for more information about syzbot.
syzbot engineers can be reached at syzk...@googlegroups.com.

syzbot will keep track of this issue. See:
https://goo.gl/tpsmEJ#status for how to communicate with syzbot.

If the report is already addressed, let syzbot know by replying with:
#syz fix: exact-commit-title

If you want syzbot to run the reproducer, reply with:
#syz test: git://repo/address.git branch-or-commit-hash
If you attach or paste a git patch, syzbot will apply it before testing.

If you want to overwrite report's subsystems, reply with:
#syz set subsystems: new-subsystem
(See the list of subsystem names on the web dashboard)

If the report is a duplicate of another one, reply with:
#syz dup: exact-subject-of-another-report

If you want to undo deduplication, reply with:
#syz undup

syzbot

unread,
Nov 10, 2023, 10:43:21 PM11/10/23
to syzkaller-a...@googlegroups.com
Hello,

syzbot found the following issue on:

HEAD commit: 61cfd264993d Revert "ipv4/fib: send notify when delete sou..
git tree: android13-5.15-lts
console output: https://syzkaller.appspot.com/x/log.txt?x=12ba93e0e80000
kernel config: https://syzkaller.appspot.com/x/.config?x=86febd5cba631f80
dashboard link: https://syzkaller.appspot.com/bug?extid=0f45031d26c6e8a1d1e2
compiler: Debian clang version 15.0.6, GNU ld (GNU Binutils for Debian) 2.40
syz repro: https://syzkaller.appspot.com/x/repro.syz?x=11ac7338e80000
C reproducer: https://syzkaller.appspot.com/x/repro.c?x=17abf898e80000

Downloadable assets:
disk image: https://storage.googleapis.com/syzbot-assets/12c3173d49c9/disk-61cfd264.raw.xz
vmlinux: https://storage.googleapis.com/syzbot-assets/aaf0b50ce030/vmlinux-61cfd264.xz
kernel image: https://storage.googleapis.com/syzbot-assets/d32e9000a96b/bzImage-61cfd264.xz

IMPORTANT: if you fix the issue, please add the following tag to the commit:
Reported-by: syzbot+0f4503...@syzkaller.appspotmail.com

==================================================================
BUG: KASAN: use-after-free in unix_stream_read_actor+0xa3/0xb0 net/unix/af_unix.c:2809
Read of size 4 at addr ffff88811ed1ce04 by task syz-executor396/943

CPU: 0 PID: 943 Comm: syz-executor396 Not tainted 5.15.137-syzkaller-01792-g61cfd264993d #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 10/09/2023
Call Trace:
<TASK>
__dump_stack lib/dump_stack.c:88 [inline]
dump_stack_lvl+0x151/0x1b7 lib/dump_stack.c:106
print_address_description+0x87/0x3b0 mm/kasan/report.c:248
__kasan_report mm/kasan/report.c:427 [inline]
kasan_report+0x179/0x1c0 mm/kasan/report.c:444
__asan_report_load4_noabort+0x14/0x20 mm/kasan/report_generic.c:308
unix_stream_read_actor+0xa3/0xb0 net/unix/af_unix.c:2809
unix_stream_recv_urg+0x1b4/0x2f0 net/unix/af_unix.c:2535
unix_stream_read_generic+0x2147/0x2240 net/unix/af_unix.c:2615
unix_stream_recvmsg+0x22d/0x2c0 net/unix/af_unix.c:2847
____sys_recvmsg+0x286/0x530
___sys_recvmsg+0x1ec/0x690 net/socket.c:2690
__sys_recvmsg net/socket.c:2720 [inline]
__do_sys_recvmsg net/socket.c:2730 [inline]
__se_sys_recvmsg net/socket.c:2727 [inline]
__x64_sys_recvmsg+0x1dc/0x2b0 net/socket.c:2727
do_syscall_x64 arch/x86/entry/common.c:50 [inline]
do_syscall_64+0x3d/0xb0 arch/x86/entry/common.c:80
entry_SYSCALL_64_after_hwframe+0x61/0xcb
RIP: 0033:0x7f01363844e9
Code: 28 00 00 00 75 05 48 83 c4 28 c3 e8 51 18 00 00 90 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 b0 ff ff ff f7 d8 64 89 01 48
RSP: 002b:00007f0136303228 EFLAGS: 00000246 ORIG_RAX: 000000000000002f
RAX: ffffffffffffffda RBX: 0000000000000028 RCX: 00007f01363844e9
RDX: 0000000040010083 RSI: 0000000020000140 RDI: 0000000000000004
RBP: 00007f013640e348 R08: 00007f01363036c0 R09: 00007f01363036c0
R10: 0000000000000000 R11: 0000000000000246 R12: 00007f013640e340
R13: 00007f013640e34c R14: 00007ffca2664350 R15: 00007ffca2664438
</TASK>

Allocated by task 942:
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+0xb1/0xe0 mm/kasan/common.c:466
kasan_slab_alloc include/linux/kasan.h:217 [inline]
slab_post_alloc_hook+0x53/0x2c0 mm/slab.h:550
slab_alloc_node mm/slub.c:3240 [inline]
slab_alloc mm/slub.c:3248 [inline]
kmem_cache_alloc+0xf5/0x200 mm/slub.c:3253
kmem_cache_alloc_node include/linux/slab.h:474 [inline]
__alloc_skb+0xbe/0x550 net/core/skbuff.c:416
alloc_skb include/linux/skbuff.h:1183 [inline]
alloc_skb_with_frags+0xa6/0x680 net/core/skbuff.c:6156
sock_alloc_send_pskb+0x915/0xa50 net/core/sock.c:2518
sock_alloc_send_skb+0x32/0x40 net/core/sock.c:2535
queue_oob+0xfd/0x8c0 net/unix/af_unix.c:1980
unix_stream_sendmsg+0xe06/0x1060 net/unix/af_unix.c:2117
sock_sendmsg_nosec net/socket.c:704 [inline]
__sock_sendmsg net/socket.c:716 [inline]
____sys_sendmsg+0x59e/0x8f0 net/socket.c:2429
___sys_sendmsg+0x252/0x2e0 net/socket.c:2483
__sys_sendmsg net/socket.c:2512 [inline]
__do_sys_sendmsg net/socket.c:2521 [inline]
__se_sys_sendmsg+0x19a/0x260 net/socket.c:2519
__x64_sys_sendmsg+0x7b/0x90 net/socket.c:2519
do_syscall_x64 arch/x86/entry/common.c:50 [inline]
do_syscall_64+0x3d/0xb0 arch/x86/entry/common.c:80
entry_SYSCALL_64_after_hwframe+0x61/0xcb

Freed by task 942:
kasan_save_stack mm/kasan/common.c:38 [inline]
kasan_set_track+0x4b/0x70 mm/kasan/common.c:45
kasan_set_free_info+0x23/0x40 mm/kasan/generic.c:370
____kasan_slab_free+0x126/0x160 mm/kasan/common.c:365
__kasan_slab_free+0x11/0x20 mm/kasan/common.c:373
kasan_slab_free include/linux/kasan.h:193 [inline]
slab_free_hook mm/slub.c:1723 [inline]
slab_free_freelist_hook+0xbd/0x190 mm/slub.c:1749
slab_free mm/slub.c:3519 [inline]
kmem_cache_free+0x116/0x2e0 mm/slub.c:3535
kfree_skbmem+0x104/0x170
__kfree_skb net/core/skbuff.c:758 [inline]
consume_skb+0xb4/0x250 net/core/skbuff.c:930
queue_oob+0x522/0x8c0 net/unix/af_unix.c:2011
unix_stream_sendmsg+0xe06/0x1060 net/unix/af_unix.c:2117
sock_sendmsg_nosec net/socket.c:704 [inline]
__sock_sendmsg net/socket.c:716 [inline]
____sys_sendmsg+0x59e/0x8f0 net/socket.c:2429
___sys_sendmsg+0x252/0x2e0 net/socket.c:2483
__sys_sendmsg net/socket.c:2512 [inline]
__do_sys_sendmsg net/socket.c:2521 [inline]
__se_sys_sendmsg+0x19a/0x260 net/socket.c:2519
__x64_sys_sendmsg+0x7b/0x90 net/socket.c:2519
do_syscall_x64 arch/x86/entry/common.c:50 [inline]
do_syscall_64+0x3d/0xb0 arch/x86/entry/common.c:80
entry_SYSCALL_64_after_hwframe+0x61/0xcb

The buggy address belongs to the object at ffff88811ed1cdc0
which belongs to the cache skbuff_head_cache of size 248
The buggy address is located 68 bytes inside of
248-byte region [ffff88811ed1cdc0, ffff88811ed1ceb8)
The buggy address belongs to the page:
page:ffffea00047b4700 refcount:1 mapcount:0 mapping:0000000000000000 index:0x0 pfn:0x11ed1c
flags: 0x4000000000000200(slab|zone=1)
raw: 4000000000000200 0000000000000000 dead000000000122 ffff888100351b00
raw: 0000000000000000 00000000000c000c 00000001ffffffff 0000000000000000
page dumped because: kasan: bad access detected
page_owner tracks the page as allocated
page last allocated via order 0, migratetype Unmovable, gfp_mask 0x12cc0(GFP_KERNEL|__GFP_NOWARN|__GFP_NORETRY), pid 938, ts 42766038655, free_ts 42713201046
set_page_owner include/linux/page_owner.h:33 [inline]
post_alloc_hook+0x1a3/0x1b0 mm/page_alloc.c:2602
prep_new_page+0x1b/0x110 mm/page_alloc.c:2608
get_page_from_freelist+0x3550/0x35d0 mm/page_alloc.c:4482
__alloc_pages+0x206/0x5e0 mm/page_alloc.c:5773
allocate_slab mm/slub.c:1932 [inline]
new_slab+0x9a/0x4e0 mm/slub.c:1995
___slab_alloc+0x39e/0x830 mm/slub.c:3028
__slab_alloc+0x4a/0x90 mm/slub.c:3115
slab_alloc_node mm/slub.c:3206 [inline]
slab_alloc mm/slub.c:3248 [inline]
kmem_cache_alloc+0x134/0x200 mm/slub.c:3253
kmem_cache_alloc_node include/linux/slab.h:474 [inline]
__alloc_skb+0xbe/0x550 net/core/skbuff.c:416
alloc_skb include/linux/skbuff.h:1183 [inline]
alloc_skb_with_frags+0xa6/0x680 net/core/skbuff.c:6156
sock_alloc_send_pskb+0x915/0xa50 net/core/sock.c:2518
sock_alloc_send_skb+0x32/0x40 net/core/sock.c:2535
queue_oob+0xfd/0x8c0 net/unix/af_unix.c:1980
unix_stream_sendmsg+0xe06/0x1060 net/unix/af_unix.c:2117
sock_sendmsg_nosec net/socket.c:704 [inline]
__sock_sendmsg net/socket.c:716 [inline]
____sys_sendmsg+0x59e/0x8f0 net/socket.c:2429
___sys_sendmsg+0x252/0x2e0 net/socket.c:2483
page last free stack trace:
reset_page_owner include/linux/page_owner.h:26 [inline]
free_pages_prepare mm/page_alloc.c:1469 [inline]
free_pcp_prepare mm/page_alloc.c:1541 [inline]
free_unref_page_prepare+0x7c8/0x7d0 mm/page_alloc.c:3531
free_unref_page+0xe6/0x730 mm/page_alloc.c:3613
free_the_page mm/page_alloc.c:802 [inline]
__free_pages+0x61/0xf0 mm/page_alloc.c:5849
free_pages+0x7c/0x90 mm/page_alloc.c:5860
tlb_batch_list_free mm/mmu_gather.c:61 [inline]
tlb_finish_mmu+0x253/0x320 mm/mmu_gather.c:341
exit_mmap+0x3ef/0x6f0 mm/mmap.c:3211
__mmput+0x95/0x310 kernel/fork.c:1179
mmput+0x5b/0x170 kernel/fork.c:1202
exit_mm kernel/exit.c:551 [inline]
do_exit+0xbb4/0x2b60 kernel/exit.c:862
do_group_exit+0x141/0x310 kernel/exit.c:997
get_signal+0x7a3/0x1630 kernel/signal.c:2891
arch_do_signal_or_restart+0xbd/0x1680 arch/x86/kernel/signal.c:867
handle_signal_work kernel/entry/common.c:148 [inline]
exit_to_user_mode_loop+0xa0/0xe0 kernel/entry/common.c:172
exit_to_user_mode_prepare+0x5a/0xa0 kernel/entry/common.c:208
__syscall_exit_to_user_mode_work kernel/entry/common.c:290 [inline]
syscall_exit_to_user_mode+0x26/0x160 kernel/entry/common.c:301
do_syscall_64+0x49/0xb0 arch/x86/entry/common.c:86

Memory state around the buggy address:
ffff88811ed1cd00: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 fc
ffff88811ed1cd80: fc fc fc fc fc fc fc fc fa fb fb fb fb fb fb fb
>ffff88811ed1ce00: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb
^
ffff88811ed1ce80: fb fb fb fb fb fb fb fc fc fc fc fc fc fc fc fc
ffff88811ed1cf00: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc

syzbot

unread,
Nov 11, 2023, 11:12:04 PM11/11/23
to syzkaller-a...@googlegroups.com
syzbot has bisected this issue to:

commit 876c14ad014d0e39c57cbfde53e13d17cdb6d645
Author: Rao Shoaib <rao.s...@oracle.com>
Date: Wed Aug 11 22:06:52 2021 +0000

af_unix: fix holding spinlock in oob handling

bisection log: https://syzkaller.appspot.com/x/bisect.txt?x=15685fc4e80000
start commit: 48c6c901fe0e ANDROID: fs/passthrough: Fix compatibility wi..
git tree: android14-6.1
final oops: https://syzkaller.appspot.com/x/report.txt?x=17685fc4e80000
console output: https://syzkaller.appspot.com/x/log.txt?x=13685fc4e80000
Reported-by: syzbot+0d6bc5...@syzkaller.appspotmail.com
Fixes: 876c14ad014d ("af_unix: fix holding spinlock in oob handling")

For information about bisection process see: https://goo.gl/tpsmEJ#bisection

syzbot

unread,
Feb 18, 2024, 10:43:11 PMFeb 18
to syzkaller-a...@googlegroups.com
Auto-closing this bug as obsolete.
No recent activity, existing reproducers are no longer triggering the issue.

syzbot

unread,
Mar 2, 2024, 2:16:04 AMMar 2
to syzkaller-a...@googlegroups.com
syzbot suspects this issue was fixed by commit:

commit d179189eec426fe4801e4b91efa1889faed12700
Author: Eric Dumazet <edum...@google.com>
Date: Mon Nov 13 13:49:38 2023 +0000

af_unix: fix use-after-free in unix_stream_read_actor()

bisection log: https://syzkaller.appspot.com/x/bisect.txt?x=125b7412180000
start commit: 48c6c901fe0e ANDROID: fs/passthrough: Fix compatibility wi..
git tree: android14-6.1
If the result looks correct, please mark the issue as fixed by replying with:

#syz fix: af_unix: fix use-after-free in unix_stream_read_actor()
Reply all
Reply to author
Forward
0 new messages