syzbot


KASAN: slab-use-after-free Read in dma_buf_fd

Status: upstream: reported on 2026/03/11 03:17
Subsystems: dri media
Labels: actionable prio:high
[Documentation on labels]
Reported-by: syzbot+7f4987d0afb97dd090cb@syzkaller.appspotmail.com
Fix commit: ead6680f354f dma-buf: fix UAF in dma_buf_fd() tracepoint
Patched on: [ci-qemu-gce-upstream-auto ci-qemu-upstream ci-qemu-upstream-386 ci-qemu2-arm32 ci-qemu2-arm64 ci-qemu2-arm64-compat ci-qemu2-arm64-mte ci-snapshot-upstream-root ci-upstream-bpf-kasan-gce ci-upstream-bpf-next-kasan-gce ci-upstream-gce-arm64 ci-upstream-gce-leak ci-upstream-kasan-badwrites-root ci-upstream-kasan-gce ci-upstream-kasan-gce-386 ci-upstream-kasan-gce-root ci-upstream-kasan-gce-selinux-root ci-upstream-kasan-gce-smack-root ci-upstream-kmsan-gce-386-root ci-upstream-kmsan-gce-root ci-upstream-linux-next-kasan-gce-root ci-upstream-net-kasan-gce ci-upstream-net-this-kasan-gce ci-upstream-rust-kasan-gce ci2-upstream-fs ci2-upstream-kcsan-gce ci2-upstream-usb], missing on: [ci-qemu-native-arm64-kvm ci-qemu2-riscv64]
First crash: 107d, last: 32d
✨ AI Jobs (2)
ID Workflow Result Correct Bug Created Started Finished Revision Error
07ba7a1c-770c-480b-8f0b-59801464f424 assessment-security DenialOfService: ✅ Exploitable: ✅ FilesystemTrigger: ❌ NetworkTrigger: ❌ PeripheralTrigger: ❌ RemoteTrigger: ❌ Unprivileged: ✅ UserNamespace: ✅ VMGuestTrigger: ✅ VMHostTrigger: ❌ KASAN: slab-use-after-free Read in dma_buf_fd 2026/05/23 20:40 2026/05/23 20:40 2026/05/23 21:33 c69befb30ac10e158cc9d1557b508ee3f0eca1de

			
		
05c08db1-4dfa-4983-a7d1-c462f404046e moderation Actionable: ✅ Confident: ✅ KASAN: slab-use-after-free Read in dma_buf_fd 2026/03/10 14:15 2026/03/10 14:15 2026/03/10 14:38 d16aa12f36812fd3c4bc5f61111b6678f99f6b6e+

			
		
Discussions (4)
Title Replies (including bot) Last reply
[PATCH] dma-buf: fix UAF in dma_buf_fd() tracepoint 3 (3) 2026/05/28 14:53
[syzbot] Monthly dri report (May 2026) 0 (1) 2026/05/02 12:32
[syzbot] Monthly dri report (Apr 2026) 0 (1) 2026/04/01 07:42
[syzbot] [media?] [dri?] KASAN: slab-use-after-free Read in dma_buf_fd 0 (1) 2026/03/11 03:17

Sample crash report:
==================================================================
BUG: KASAN: slab-use-after-free in __raw_spin_lock_irqsave include/linux/spinlock_api_smp.h:132 [inline]
BUG: KASAN: slab-use-after-free in _raw_spin_lock_irqsave+0x40/0x60 kernel/locking/spinlock.c:166
Read of size 1 at addr ffff88803ec9b868 by task syz.0.3510/15778

CPU: 1 UID: 0 PID: 15778 Comm: syz.0.3510 Tainted: G             L      syzkaller #0 PREEMPT_{RT,(full)} 
Tainted: [L]=SOFTLOCKUP
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 04/18/2026
Call Trace:
 <TASK>
 dump_stack_lvl+0xe8/0x150 lib/dump_stack.c:120
 print_address_description+0x55/0x1e0 mm/kasan/report.c:378
 print_report+0x58/0x70 mm/kasan/report.c:482
 kasan_report+0x117/0x150 mm/kasan/report.c:595
 __kasan_check_byte+0x2a/0x40 mm/kasan/common.c:574
 kasan_check_byte include/linux/kasan.h:402 [inline]
 lock_acquire+0x84/0x350 kernel/locking/lockdep.c:5842
 __raw_spin_lock_irqsave include/linux/spinlock_api_smp.h:132 [inline]
 _raw_spin_lock_irqsave+0x40/0x60 kernel/locking/spinlock.c:166
 rt_mutex_slowunlock+0xbf/0x8b0 kernel/locking/rtmutex.c:1426
 spin_unlock include/linux/spinlock_rt.h:109 [inline]
 class_spinlock_destructor include/linux/spinlock.h:587 [inline]
 dma_buf_fd+0x178/0x330 drivers/dma-buf/dma-buf.c:796
 udmabuf_create+0xf26/0xfe0 drivers/dma-buf/udmabuf.c:453
 udmabuf_ioctl_create drivers/dma-buf/udmabuf.c:484 [inline]
 udmabuf_ioctl+0x1f6/0x310 drivers/dma-buf/udmabuf.c:515
 vfs_ioctl fs/ioctl.c:51 [inline]
 __do_sys_ioctl fs/ioctl.c:597 [inline]
 __se_sys_ioctl+0xff/0x170 fs/ioctl.c:583
 do_syscall_x64 arch/x86/entry/syscall_64.c:63 [inline]
 do_syscall_64+0x15f/0xf80 arch/x86/entry/syscall_64.c:94
 entry_SYSCALL_64_after_hwframe+0x77/0x7f
RIP: 0033:0x7f1e3efbce59
Code: ff c3 66 2e 0f 1f 84 00 00 00 00 00 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 e8 ff ff ff f7 d8 64 89 01 48
RSP: 002b:00007f1e3d1d4028 EFLAGS: 00000246 ORIG_RAX: 0000000000000010
RAX: ffffffffffffffda RBX: 00007f1e3f236180 RCX: 00007f1e3efbce59
RDX: 00002000000000c0 RSI: 0000000040187542 RDI: 0000000000000008
RBP: 00007f1e3f052d6f R08: 0000000000000000 R09: 0000000000000000
R10: 0000000000000000 R11: 0000000000000246 R12: 0000000000000000
R13: 00007f1e3f236218 R14: 00007f1e3f236180 R15: 00007ffe8752d588
 </TASK>

Allocated by task 15778:
 kasan_save_stack mm/kasan/common.c:57 [inline]
 kasan_save_track+0x3e/0x80 mm/kasan/common.c:78
 poison_kmalloc_redzone mm/kasan/common.c:398 [inline]
 __kasan_kmalloc+0x93/0xb0 mm/kasan/common.c:415
 kasan_kmalloc include/linux/kasan.h:263 [inline]
 __do_kmalloc_node mm/slub.c:5295 [inline]
 __kmalloc_noprof+0x3e7/0x7b0 mm/slub.c:5307
 kmalloc_noprof include/linux/slab.h:954 [inline]
 kzalloc_noprof include/linux/slab.h:1188 [inline]
 dma_buf_export+0x3ba/0xad0 drivers/dma-buf/dma-buf.c:739
 export_udmabuf drivers/dma-buf/udmabuf.c:320 [inline]
 udmabuf_create+0xee5/0xfe0 drivers/dma-buf/udmabuf.c:442
 udmabuf_ioctl_create drivers/dma-buf/udmabuf.c:484 [inline]
 udmabuf_ioctl+0x1f6/0x310 drivers/dma-buf/udmabuf.c:515
 vfs_ioctl fs/ioctl.c:51 [inline]
 __do_sys_ioctl fs/ioctl.c:597 [inline]
 __se_sys_ioctl+0xff/0x170 fs/ioctl.c:583
 do_syscall_x64 arch/x86/entry/syscall_64.c:63 [inline]
 do_syscall_64+0x15f/0xf80 arch/x86/entry/syscall_64.c:94
 entry_SYSCALL_64_after_hwframe+0x77/0x7f

Freed by task 15780:
 kasan_save_stack mm/kasan/common.c:57 [inline]
 kasan_save_track+0x3e/0x80 mm/kasan/common.c:78
 kasan_save_free_info+0x46/0x50 mm/kasan/generic.c:584
 poison_slab_object mm/kasan/common.c:253 [inline]
 __kasan_slab_free+0x5c/0x80 mm/kasan/common.c:285
 kasan_slab_free include/linux/kasan.h:235 [inline]
 slab_free_hook mm/slub.c:2689 [inline]
 slab_free mm/slub.c:6250 [inline]
 kfree+0x1c5/0x6c0 mm/slub.c:6565
 __dentry_kill+0x211/0x690 fs/dcache.c:723
 finish_dput+0xc9/0x480 fs/dcache.c:927
 __fput+0x6a3/0xa70 fs/file_table.c:518
 task_work_run+0x1d9/0x270 kernel/task_work.c:233
 resume_user_mode_work include/linux/resume_user_mode.h:50 [inline]
 __exit_to_user_mode_loop kernel/entry/common.c:67 [inline]
 exit_to_user_mode_loop+0xf3/0x4d0 kernel/entry/common.c:98
 __exit_to_user_mode_prepare include/linux/irq-entry-common.h:207 [inline]
 syscall_exit_to_user_mode_prepare include/linux/irq-entry-common.h:238 [inline]
 syscall_exit_to_user_mode include/linux/entry-common.h:318 [inline]
 do_syscall_64+0x33e/0xf80 arch/x86/entry/syscall_64.c:100
 entry_SYSCALL_64_after_hwframe+0x77/0x7f

The buggy address belongs to the object at ffff88803ec9b800
 which belongs to the cache kmalloc-1k of size 1024
The buggy address is located 104 bytes inside of
 freed 1024-byte region [ffff88803ec9b800, ffff88803ec9bc00)

The buggy address belongs to the physical page:
page: refcount:0 mapcount:0 mapping:0000000000000000 index:0x0 pfn:0x3ec98
head: order:3 mapcount:0 entire_mapcount:0 nr_pages_mapped:0 pincount:0
flags: 0x80000000000040(head|node=0|zone=1)
page_type: f5(slab)
raw: 0080000000000040 ffff88801a010dc0 dead000000000100 dead000000000122
raw: 0000000000000000 0000000800100010 00000000f5000000 0000000000000000
head: 0080000000000040 ffff88801a010dc0 dead000000000100 dead000000000122
head: 0000000000000000 0000000800100010 00000000f5000000 0000000000000000
head: 0080000000000003 fffffffffffffe01 00000000ffffffff 00000000ffffffff
head: 0000000000000000 0000000000000000 00000000ffffffff 0000000000000008
page dumped because: kasan: bad access detected
page_owner tracks the page as allocated
page last allocated via order 3, migratetype Unmovable, gfp_mask 0xd2820(GFP_ATOMIC|__GFP_NOWARN|__GFP_NORETRY|__GFP_COMP|__GFP_NOMEMALLOC), pid 13, tgid 13 (kworker/u8:1), ts 128332619728, free_ts 127707099198
 set_page_owner include/linux/page_owner.h:32 [inline]
 post_alloc_hook+0x231/0x280 mm/page_alloc.c:1858
 prep_new_page mm/page_alloc.c:1866 [inline]
 get_page_from_freelist+0x27c8/0x2840 mm/page_alloc.c:3946
 __alloc_frozen_pages_noprof+0x18d/0x380 mm/page_alloc.c:5226
 alloc_slab_page mm/slub.c:3278 [inline]
 allocate_slab+0x77/0x660 mm/slub.c:3467
 new_slab mm/slub.c:3525 [inline]
 refill_objects+0x33c/0x3d0 mm/slub.c:7255
 refill_sheaf mm/slub.c:2816 [inline]
 __pcs_replace_empty_main+0x373/0x720 mm/slub.c:4651
 alloc_from_pcs mm/slub.c:4749 [inline]
 slab_alloc_node mm/slub.c:4883 [inline]
 __do_kmalloc_node mm/slub.c:5294 [inline]
 __kmalloc_noprof+0x530/0x7b0 mm/slub.c:5307
 kmalloc_noprof include/linux/slab.h:954 [inline]
 kzalloc_noprof include/linux/slab.h:1188 [inline]
 ieee802_11_parse_elems_full+0x159/0x2ab0 net/mac80211/parse.c:1051
 ieee802_11_parse_elems net/mac80211/ieee80211_i.h:2518 [inline]
 ieee80211_inform_bss+0x161/0x1160 net/mac80211/scan.c:79
 rdev_inform_bss net/wireless/rdev-ops.h:418 [inline]
 cfg80211_inform_single_bss_data+0xd2f/0x1b80 net/wireless/scan.c:2372
 cfg80211_inform_bss_data+0x266/0x3c40 net/wireless/scan.c:3226
 cfg80211_inform_bss_frame_data+0x3c7/0x730 net/wireless/scan.c:3317
 ieee80211_bss_info_update+0x794/0xa40 net/mac80211/scan.c:230
 ieee80211_rx_bss_info net/mac80211/ibss.c:1088 [inline]
 ieee80211_rx_mgmt_probe_beacon net/mac80211/ibss.c:1569 [inline]
 ieee80211_ibss_rx_queued_mgmt+0x1901/0x2cb0 net/mac80211/ibss.c:1596
 ieee80211_iface_process_skb net/mac80211/iface.c:1795 [inline]
 ieee80211_iface_work+0x845/0x1390 net/mac80211/iface.c:1849
 cfg80211_wiphy_work+0x2cf/0x460 net/wireless/core.c:513
page last free pid 5257 tgid 5257 stack trace:
 reset_page_owner include/linux/page_owner.h:25 [inline]
 __free_pages_prepare mm/page_alloc.c:1402 [inline]
 __free_frozen_pages+0xfa6/0x10f0 mm/page_alloc.c:2943
 __slab_free+0x252/0x2a0 mm/slub.c:5612
 qlink_free mm/kasan/quarantine.c:163 [inline]
 qlist_free_all+0x99/0x100 mm/kasan/quarantine.c:179
 kasan_quarantine_reduce+0x148/0x160 mm/kasan/quarantine.c:286
 __kasan_slab_alloc+0x22/0x80 mm/kasan/common.c:350
 kasan_slab_alloc include/linux/kasan.h:253 [inline]
 slab_post_alloc_hook mm/slub.c:4569 [inline]
 slab_alloc_node mm/slub.c:4898 [inline]
 kmem_cache_alloc_node_noprof+0x22a/0x6e0 mm/slub.c:4950
 __alloc_skb+0x1d0/0x7d0 net/core/skbuff.c:702
 alloc_skb include/linux/skbuff.h:1383 [inline]
 alloc_skb_with_frags+0xc8/0x760 net/core/skbuff.c:6734
 sock_alloc_send_pskb+0x884/0x9a0 net/core/sock.c:2998
 unix_dgram_sendmsg+0x460/0x18d0 net/unix/af_unix.c:2141
 sock_sendmsg_nosec net/socket.c:787 [inline]
 __sock_sendmsg net/socket.c:802 [inline]
 sock_write_iter+0x4a1/0x4f0 net/socket.c:1254
 do_iter_readv_writev+0x62b/0x8d0 fs/read_write.c:-1
 vfs_writev+0x345/0x9a0 fs/read_write.c:1059
 do_writev+0x15a/0x2e0 fs/read_write.c:1105
 do_syscall_x64 arch/x86/entry/syscall_64.c:63 [inline]
 do_syscall_64+0x15f/0xf80 arch/x86/entry/syscall_64.c:94
 entry_SYSCALL_64_after_hwframe+0x77/0x7f

Memory state around the buggy address:
 ffff88803ec9b700: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc
 ffff88803ec9b780: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc
>ffff88803ec9b800: fa fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb
                                                          ^
 ffff88803ec9b880: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb
 ffff88803ec9b900: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb
==================================================================

Crashes (21):
Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Assets (help?) Manager Title
2026/05/15 20:04 upstream 70eda68668d1 9cd3beaa .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-kasan-gce-smack-root KASAN: slab-use-after-free Read in dma_buf_fd
2026/04/29 16:44 upstream 57b8e2d666a3 804ea88f .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-kasan-gce KASAN: slab-use-after-free Read in dma_buf_fd
2026/04/18 12:40 upstream 8541d8f725c6 303e2802 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-kasan-gce-smack-root KASAN: slab-use-after-free Read in dma_buf_fd
2026/04/18 09:38 upstream 8541d8f725c6 303e2802 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-kasan-gce-smack-root KASAN: slab-use-after-free Read in dma_buf_fd
2026/04/16 10:31 upstream aec2f682d47c df15c5f3 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-kasan-gce-smack-root KASAN: slab-use-after-free Read in dma_buf_fd
2026/04/15 03:24 upstream 508fed679541 e2e976a8 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-kasan-gce-smack-root KASAN: slab-use-after-free Read in dma_buf_fd
2026/03/31 13:51 upstream d0c3bcd5b897 aeea1c72 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-kasan-gce-smack-root KASAN: slab-use-after-free Read in dma_buf_fd
2026/03/30 08:49 upstream 7aaa8047eafd 356bdfc9 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-kasan-gce-smack-root KASAN: slab-use-after-free Read in dma_buf_fd
2026/03/26 16:24 upstream 0138af2472df fca8d360 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-kasan-gce-smack-root KASAN: slab-use-after-free Read in dma_buf_fd
2026/03/26 02:05 upstream d2a43e7f89da c6143aac .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-kasan-gce-smack-root KASAN: slab-use-after-free Read in dma_buf_fd
2026/03/25 07:27 upstream bbeb83d3182a 35e4ff71 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-kasan-gce-smack-root KASAN: slab-use-after-free Read in dma_buf_fd
2026/03/23 16:30 upstream c369299895a5 5e3db351 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-kasan-gce-smack-root KASAN: slab-use-after-free Read in dma_buf_fd
2026/03/23 16:29 upstream c369299895a5 5e3db351 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-kasan-gce-smack-root KASAN: slab-use-after-free Read in dma_buf_fd
2026/03/06 11:54 upstream 5ee8dbf54602 31e9c887 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-kasan-gce-smack-root KASAN: slab-use-after-free Read in dma_buf_fd
2026/03/04 07:19 upstream 0031c06807cf 4180d919 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-kasan-gce KASAN: slab-use-after-free Read in dma_buf_fd
2026/05/13 15:46 upstream 1d5dcaa3bd65 fec2a7ee .config console log report [disk image (non-bootable)] [vmlinux] [kernel image] ci-snapshot-upstream-root KASAN: slab-use-after-free Read in dma_buf_fd
2026/03/19 15:57 upstream 8a30aeb0d1b4 bd6dcb30 .config console log report info [disk image (non-bootable)] [vmlinux] [kernel image] ci-qemu-upstream-386 KASAN: slab-use-after-free Read in dma_buf_fd
2026/05/18 07:16 linux-next e98d21c170b0 de5aae85 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root KASAN: slab-use-after-free Read in dma_buf_fd
2026/05/17 13:17 linux-next e98d21c170b0 de5aae85 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root KASAN: slab-use-after-free Read in dma_buf_fd
2026/04/23 00:05 linux-next 70c8a7ec6715 b10da5ec .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root KASAN: slab-use-after-free Read in dma_buf_fd
2026/04/13 20:35 linux-next 1c7cc4904160 9530ccf9 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root KASAN: slab-use-after-free Read in dma_buf_fd
* Struck through repros no longer work on HEAD.