INIT: Entering runlevel: 2 [info] Using makefile-style concurrent boot in runlevel 2. [....] Starting enhanced syslogd: rsyslogd[?25l[?1c7[ ok 8[?25h[?0c. [....] Starting periodic command scheduler: cron[?25l[?1c7[ ok 8[?25h[?0c. [....] Starting OpenBSD Secure Shell server: sshd[?25l[?1c7[ ok 8[?25h[?0c. Debian GNU/Linux 7 syzkaller ttyS0 Warning: Permanently added 'ci-upstream-kasan-gce-0,10.128.0.41' (ECDSA) to the list of known hosts. 2017/09/09 21:49:42 parsed 1 programs 2017/09/09 21:49:42 executed programs: 0 2017/09/09 21:49:47 executed programs: 845 syzkaller login: [ 35.987811] dev_remove_pack: ffff8801d8b7ad80 not found [ 36.016728] ================================================================== [ 36.024152] BUG: KASAN: use-after-free in __dev_remove_pack+0x305/0x3b0 [ 36.030879] Read of size 8 at addr ffff8801d8f916e8 by task syz-executor1/6065 [ 36.038205] [ 36.039808] CPU: 0 PID: 6065 Comm: syz-executor1 Not tainted 4.13.0+ #76 [ 36.046617] Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011 [ 36.055940] Call Trace: [ 36.058503] dump_stack+0x194/0x257 [ 36.062105] ? arch_local_irq_restore+0x53/0x53 [ 36.066746] ? show_regs_print_info+0x65/0x65 [ 36.071222] ? __dev_remove_pack+0x305/0x3b0 [ 36.075605] print_address_description+0x73/0x250 [ 36.080419] ? __dev_remove_pack+0x305/0x3b0 [ 36.084802] kasan_report+0x24e/0x340 [ 36.088582] __asan_report_load8_noabort+0x14/0x20 [ 36.093482] __dev_remove_pack+0x305/0x3b0 [ 36.097692] ? dev_get_by_name_rcu+0x270/0x270 [ 36.102247] ? refcount_sub_and_test+0x115/0x1b0 [ 36.106977] ? refcount_inc+0x50/0x50 [ 36.110758] __unregister_prot_hook+0x224/0x280 [ 36.115407] packet_release+0x8bb/0xd70 [ 36.119363] ? packet_set_ring+0x1b70/0x1b70 [ 36.123747] ? dentry_free+0xcd/0x130 [ 36.127522] ? rcu_read_lock_sched_held+0x108/0x120 [ 36.132511] ? kmem_cache_free+0x249/0x280 [ 36.136720] ? dentry_free+0xd2/0x130 [ 36.140498] ? locks_remove_file+0x3fa/0x5a0 [ 36.144881] ? fcntl_setlk+0x10d0/0x10d0 [ 36.148919] ? __fsnotify_parent+0xb4/0x3a0 [ 36.153217] ? fsnotify+0x1af0/0x1af0 [ 36.156997] sock_release+0x8d/0x1e0 [ 36.160688] ? sock_release+0x8d/0x1e0 [ 36.164547] ? sock_release+0x1e0/0x1e0 [ 36.168493] sock_close+0x16/0x20 [ 36.171921] __fput+0x333/0x7f0 [ 36.175181] ? fput+0x140/0x140 [ 36.178436] ? check_same_owner+0x320/0x320 [ 36.182730] ? _raw_spin_unlock_irq+0x27/0x70 [ 36.187208] ____fput+0x15/0x20 [ 36.190462] task_work_run+0x199/0x270 [ 36.194325] ? task_work_cancel+0x210/0x210 [ 36.198618] ? _raw_spin_unlock+0x22/0x30 [ 36.202742] ? switch_task_namespaces+0x87/0xc0 [ 36.207388] do_exit+0xa52/0x1b40 [ 36.210830] ? match_held_lock+0x941/0x9f0 [ 36.215039] ? mm_update_next_owner+0x930/0x930 [ 36.219689] ? lock_downgrade+0x990/0x990 [ 36.223819] ? lock_downgrade+0x990/0x990 [ 36.227947] ? release_sock+0x74/0x2a0 [ 36.231816] ? do_raw_spin_trylock+0x190/0x190 [ 36.236374] ? check_noncircular+0x20/0x20 [ 36.240580] ? __local_bh_enable_ip+0x9d/0x160 [ 36.245139] ? release_sock+0x1d4/0x2a0 [ 36.249086] ? trace_hardirqs_on+0xd/0x10 [ 36.253206] ? __local_bh_enable_ip+0x9d/0x160 [ 36.257760] ? _raw_spin_unlock_bh+0x30/0x40 [ 36.262141] ? release_sock+0x1d4/0x2a0 [ 36.266087] ? napi_skb_free_stolen_head+0x170/0x170 [ 36.271163] ? __release_sock+0x360/0x360 [ 36.275289] ? find_held_lock+0x39/0x1d0 [ 36.279336] ? lock_downgrade+0x990/0x990 [ 36.283458] ? recalc_sigpending_tsk+0x117/0x150 [ 36.288189] ? recalc_sigpending+0x103/0x160 [ 36.292569] ? recalc_sigpending_tsk+0x150/0x150 [ 36.297295] ? get_signal+0x397/0x17e0 [ 36.301170] do_group_exit+0x149/0x400 [ 36.305031] ? __lock_is_held+0xbc/0x140 [ 36.309065] ? SyS_exit+0x30/0x30 [ 36.312491] ? _raw_spin_unlock_irq+0x27/0x70 [ 36.316961] ? trace_hardirqs_on_caller+0x421/0x5c0 [ 36.321954] get_signal+0x7e8/0x17e0 [ 36.325676] ? ptrace_notify+0x130/0x130 [ 36.329709] ? __fget+0xbb/0x580 [ 36.333050] ? __lockdep_init_map+0xe4/0x650 [ 36.337435] ? lock_release+0xd70/0xd70 [ 36.341387] ? __lock_is_held+0xbc/0x140 [ 36.345443] do_signal+0x94/0x1ee0 [ 36.348962] ? iterate_fd+0x3f0/0x3f0 [ 36.352740] ? setup_sigcontext+0x7d0/0x7d0 [ 36.357042] ? __fdget+0x18/0x20 [ 36.360383] ? sockfd_lookup_light+0x104/0x150 [ 36.364945] ? __fget_light+0x29d/0x390 [ 36.368896] ? selinux_tun_dev_create+0xc0/0xc0 [ 36.373541] ? selinux_netlbl_socket_setsockopt+0x10c/0x460 [ 36.379227] ? selinux_netlbl_sock_rcv_skb+0x730/0x730 [ 36.384473] ? alloc_file+0x284/0x3a0 [ 36.388245] ? exit_to_usermode_loop+0x98/0x300 [ 36.392893] exit_to_usermode_loop+0x224/0x300 [ 36.397451] ? trace_event_raw_event_sys_exit+0x260/0x260 [ 36.402974] syscall_return_slowpath+0x42f/0x500 [ 36.407703] ? prepare_exit_to_usermode+0x2c0/0x2c0 [ 36.412692] ? entry_SYSCALL_64_fastpath+0x91/0xbe [ 36.417595] ? trace_hardirqs_on_caller+0x421/0x5c0 [ 36.422583] ? trace_hardirqs_on_thunk+0x1a/0x1c [ 36.427320] entry_SYSCALL_64_fastpath+0xbc/0xbe [ 36.432052] RIP: 0033:0x451e59 [ 36.435216] RSP: 002b:00007fdc0e127c08 EFLAGS: 00000216 ORIG_RAX: 0000000000000036 [ 36.442902] RAX: 0000000000000000 RBX: 0000000000718000 RCX: 0000000000451e59 [ 36.450146] RDX: 000000000000000d RSI: 0000000000000107 RDI: 0000000000000007 [ 36.457387] RBP: 0000000000005750 R08: 000000000000001c R09: 0000000000000000 [ 36.464630] R10: 00000000204fbfe4 R11: 0000000000000216 R12: 00000000004bb378 [ 36.471869] R13: 00000000ffffffff R14: 0000000000000007 R15: 0000000000000107 [ 36.479133] [ 36.480731] Allocated by task 6060: [ 36.484331] save_stack_trace+0x16/0x20 [ 36.488277] save_stack+0x43/0xd0 [ 36.491700] kasan_kmalloc+0xad/0xe0 [ 36.495387] kmem_cache_alloc_trace+0x136/0x750 [ 36.500028] fanout_add+0xa50/0x1190 [ 36.503714] packet_setsockopt+0xfdc/0x1e80 [ 36.508008] SyS_setsockopt+0x189/0x360 [ 36.511958] entry_SYSCALL_64_fastpath+0x1f/0xbe [ 36.516679] [ 36.518276] Freed by task 6060: [ 36.521527] save_stack_trace+0x16/0x20 [ 36.525473] save_stack+0x43/0xd0 [ 36.528895] kasan_slab_free+0x71/0xc0 [ 36.532754] kfree+0xca/0x250 [ 36.535830] packet_release+0xa8f/0xd70 [ 36.539772] sock_release+0x8d/0x1e0 [ 36.543457] sock_close+0x16/0x20 [ 36.546879] __fput+0x333/0x7f0 [ 36.550128] ____fput+0x15/0x20 [ 36.553380] task_work_run+0x199/0x270 [ 36.557241] do_exit+0xa52/0x1b40 [ 36.560666] do_group_exit+0x149/0x400 [ 36.564522] get_signal+0x7e8/0x17e0 [ 36.568206] do_signal+0x94/0x1ee0 [ 36.571721] exit_to_usermode_loop+0x224/0x300 [ 36.576272] syscall_return_slowpath+0x42f/0x500 [ 36.580996] entry_SYSCALL_64_fastpath+0xbc/0xbe [ 36.585725] [ 36.587326] The buggy address belongs to the object at ffff8801d8f90e40 [ 36.587326] which belongs to the cache kmalloc-4096 of size 4096 [ 36.600125] The buggy address is located 2216 bytes inside of [ 36.600125] 4096-byte region [ffff8801d8f90e40, ffff8801d8f91e40) [ 36.612141] The buggy address belongs to the page: [ 36.617040] page:ffffea000763e400 count:1 mapcount:0 mapping:ffff8801d8f90e40 index:0x0 compound_mapcount: 0 [ 36.626986] flags: 0x200000000008100(slab|head) [ 36.631630] raw: 0200000000008100 ffff8801d8f90e40 0000000000000000 0000000100000001 [ 36.639482] raw: ffffea000763e220 ffffea0007604020 ffff8801dac00dc0 0000000000000000 [ 36.647330] page dumped because: kasan: bad access detected [ 36.653010] [ 36.654614] Memory state around the buggy address: [ 36.659512] ffff8801d8f91580: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb [ 36.666843] ffff8801d8f91600: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb [ 36.674174] >ffff8801d8f91680: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb [ 36.681500] ^ [ 36.688224] ffff8801d8f91700: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb [ 36.695553] ffff8801d8f91780: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb [ 36.702881] ================================================================== [ 36.710210] Disabling lock debugging due to kernel taint [ 36.715705] Kernel panic - not syncing: panic_on_warn set ... [ 36.715705] [ 36.723033] CPU: 0 PID: 6065 Comm: syz-executor1 Tainted: G B 4.13.0+ #76 [ 36.731050] Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011 [ 36.740369] Call Trace: [ 36.742926] dump_stack+0x194/0x257 [ 36.746522] ? arch_local_irq_restore+0x53/0x53 [ 36.751160] ? trace_hardirqs_on_thunk+0x1a/0x1c [ 36.755887] ? __dev_remove_pack+0x2f0/0x3b0 [ 36.760283] panic+0x1e4/0x417 [ 36.763442] ? __warn+0x1d9/0x1d9 [ 36.766868] ? __dev_remove_pack+0x305/0x3b0 [ 36.771243] kasan_end_report+0x50/0x50 [ 36.775184] kasan_report+0x137/0x340 [ 36.778953] __asan_report_load8_noabort+0x14/0x20 [ 36.783846] __dev_remove_pack+0x305/0x3b0 [ 36.788053] ? dev_get_by_name_rcu+0x270/0x270 [ 36.792604] ? refcount_sub_and_test+0x115/0x1b0 [ 36.797325] ? refcount_inc+0x50/0x50 [ 36.801095] __unregister_prot_hook+0x224/0x280 [ 36.805730] packet_release+0x8bb/0xd70 [ 36.809673] ? packet_set_ring+0x1b70/0x1b70 [ 36.814048] ? dentry_free+0xcd/0x130 [ 36.817812] ? rcu_read_lock_sched_held+0x108/0x120 [ 36.822797] ? kmem_cache_free+0x249/0x280 [ 36.826996] ? dentry_free+0xd2/0x130 [ 36.830769] ? locks_remove_file+0x3fa/0x5a0 [ 36.835143] ? fcntl_setlk+0x10d0/0x10d0 [ 36.839172] ? __fsnotify_parent+0xb4/0x3a0 [ 36.843464] ? fsnotify+0x1af0/0x1af0 [ 36.847233] sock_release+0x8d/0x1e0 [ 36.850911] ? sock_release+0x8d/0x1e0 [ 36.854763] ? sock_release+0x1e0/0x1e0 [ 36.858699] sock_close+0x16/0x20 [ 36.862119] __fput+0x333/0x7f0 [ 36.865366] ? fput+0x140/0x140 [ 36.868612] ? check_same_owner+0x320/0x320 [ 36.872897] ? _raw_spin_unlock_irq+0x27/0x70 [ 36.877359] ____fput+0x15/0x20 [ 36.880607] task_work_run+0x199/0x270 [ 36.884461] ? task_work_cancel+0x210/0x210 [ 36.888747] ? _raw_spin_unlock+0x22/0x30 [ 36.892859] ? switch_task_namespaces+0x87/0xc0 [ 36.897497] do_exit+0xa52/0x1b40 [ 36.900923] ? match_held_lock+0x941/0x9f0 [ 36.905122] ? mm_update_next_owner+0x930/0x930 [ 36.909759] ? lock_downgrade+0x990/0x990 [ 36.913874] ? lock_downgrade+0x990/0x990 [ 36.917990] ? release_sock+0x74/0x2a0 [ 36.921850] ? do_raw_spin_trylock+0x190/0x190 [ 36.926399] ? check_noncircular+0x20/0x20 [ 36.930601] ? __local_bh_enable_ip+0x9d/0x160 [ 36.935151] ? release_sock+0x1d4/0x2a0 [ 36.939088] ? trace_hardirqs_on+0xd/0x10 [ 36.943200] ? __local_bh_enable_ip+0x9d/0x160 [ 36.947749] ? _raw_spin_unlock_bh+0x30/0x40 [ 36.952121] ? release_sock+0x1d4/0x2a0 [ 36.956059] ? napi_skb_free_stolen_head+0x170/0x170 [ 36.961126] ? __release_sock+0x360/0x360 [ 36.965239] ? find_held_lock+0x39/0x1d0 [ 36.969271] ? lock_downgrade+0x990/0x990 [ 36.973387] ? recalc_sigpending_tsk+0x117/0x150 [ 36.978108] ? recalc_sigpending+0x103/0x160 [ 36.982483] ? recalc_sigpending_tsk+0x150/0x150 [ 36.987202] ? get_signal+0x397/0x17e0