kauditd_printk_skb: 5 callbacks suppressed audit: type=1400 audit(1556765138.921:36): avc: denied { map } for pid=8280 comm="syz-executor712" path="/root/syz-executor712434629" dev="sda1" ino=1426 scontext=unconfined_u:system_r:insmod_t:s0-s0:c0.c1023 tcontext=unconfined_u:object_r:user_home_t:s0 tclass=file permissive=1 ================================================================== BUG: KASAN: slab-out-of-bounds in memcpy include/linux/string.h:348 [inline] BUG: KASAN: slab-out-of-bounds in bacpy+0x23/0x30 include/net/bluetooth/bluetooth.h:236 Read of size 6 at addr ffff88809b4c76fb by task kworker/u5:0/1275 CPU: 1 PID: 1275 Comm: kworker/u5:0 Not tainted 4.19.37 #5 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011 Workqueue: hci0 hci_rx_work Call Trace: __dump_stack lib/dump_stack.c:77 [inline] dump_stack+0x172/0x1f0 lib/dump_stack.c:113 print_address_description.cold+0x7c/0x20d mm/kasan/report.c:256 kasan_report_error mm/kasan/report.c:354 [inline] kasan_report mm/kasan/report.c:412 [inline] kasan_report.cold+0x8c/0x2ba mm/kasan/report.c:396 check_memory_region_inline mm/kasan/kasan.c:260 [inline] check_memory_region+0x123/0x190 mm/kasan/kasan.c:267 memcpy+0x24/0x50 mm/kasan/kasan.c:302 memcpy include/linux/string.h:348 [inline] bacpy+0x23/0x30 include/net/bluetooth/bluetooth.h:236 hci_inquiry_result_with_rssi_evt net/bluetooth/hci_event.c:3939 [inline] hci_event_packet+0x5455/0xaa6b net/bluetooth/hci_event.c:5820 hci_rx_work+0x440/0xaa0 net/bluetooth/hci_core.c:4349 process_one_work+0x98e/0x1760 kernel/workqueue.c:2153 worker_thread+0x98/0xe40 kernel/workqueue.c:2296 kthread+0x357/0x430 kernel/kthread.c:246 ret_from_fork+0x3a/0x50 arch/x86/entry/entry_64.S:413 Allocated by task 8284: save_stack+0x45/0xd0 mm/kasan/kasan.c:448 set_track mm/kasan/kasan.c:460 [inline] kasan_kmalloc mm/kasan/kasan.c:553 [inline] kasan_kmalloc+0xce/0xf0 mm/kasan/kasan.c:531 __do_kmalloc_node mm/slab.c:3689 [inline] __kmalloc_node_track_caller+0x51/0x80 mm/slab.c:3703 __kmalloc_reserve.isra.0+0x40/0xf0 net/core/skbuff.c:137 __alloc_skb+0x10b/0x5f0 net/core/skbuff.c:205 alloc_skb include/linux/skbuff.h:995 [inline] bt_skb_alloc include/net/bluetooth/bluetooth.h:339 [inline] vhci_get_user drivers/bluetooth/hci_vhci.c:180 [inline] vhci_write+0xc4/0x470 drivers/bluetooth/hci_vhci.c:299 call_write_iter include/linux/fs.h:1811 [inline] new_sync_write fs/read_write.c:474 [inline] __vfs_write+0x58e/0x820 fs/read_write.c:487 vfs_write+0x20c/0x560 fs/read_write.c:549 ksys_write+0xea/0x1f0 fs/read_write.c:598 __do_sys_write fs/read_write.c:610 [inline] __se_sys_write fs/read_write.c:607 [inline] __x64_sys_write+0x73/0xb0 fs/read_write.c:607 do_syscall_64+0x103/0x610 arch/x86/entry/common.c:290 entry_SYSCALL_64_after_hwframe+0x49/0xbe Freed by task 3594: save_stack+0x45/0xd0 mm/kasan/kasan.c:448 set_track mm/kasan/kasan.c:460 [inline] __kasan_slab_free+0x102/0x150 mm/kasan/kasan.c:521 kasan_slab_free+0xe/0x10 mm/kasan/kasan.c:528 __cache_free mm/slab.c:3503 [inline] kfree+0xcf/0x230 mm/slab.c:3822 kernfs_fop_release+0x129/0x1a0 fs/kernfs/file.c:783 __fput+0x2df/0x8b0 fs/file_table.c:278 ____fput+0x16/0x20 fs/file_table.c:309 task_work_run+0x14a/0x1c0 kernel/task_work.c:113 tracehook_notify_resume include/linux/tracehook.h:193 [inline] exit_to_usermode_loop+0x273/0x2c0 arch/x86/entry/common.c:166 prepare_exit_to_usermode arch/x86/entry/common.c:197 [inline] syscall_return_slowpath arch/x86/entry/common.c:268 [inline] do_syscall_64+0x52d/0x610 arch/x86/entry/common.c:293 entry_SYSCALL_64_after_hwframe+0x49/0xbe The buggy address belongs to the object at ffff88809b4c7500 which belongs to the cache kmalloc-512 of size 512 The buggy address is located 507 bytes inside of 512-byte region [ffff88809b4c7500, ffff88809b4c7700) The buggy address belongs to the page: page:ffffea00026d31c0 count:1 mapcount:0 mapping:ffff88812c3f0940 index:0x0 flags: 0x1fffc0000000100(slab) raw: 01fffc0000000100 ffffea00022f2948 ffffea00026d3908 ffff88812c3f0940 raw: 0000000000000000 ffff88809b4c7000 0000000100000006 0000000000000000 page dumped because: kasan: bad access detected Memory state around the buggy address: ffff88809b4c7600: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ffff88809b4c7680: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 >ffff88809b4c7700: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc ^ ffff88809b4c7780: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ffff88809b4c7800: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ==================================================================