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-next-kasan-gce-1,10.128.0.2' (ECDSA) to the list of known hosts. 2017/09/10 06:48:30 parsed 1 programs 2017/09/10 06:48:30 executed programs: 0 syzkaller login: [ 48.476121] dev_remove_pack: ffff8801ce7d0940 not found [ 48.497571] ================================================================== [ 48.504991] BUG: KASAN: use-after-free in __dev_remove_pack+0x305/0x3b0 [ 48.511722] Read of size 8 at addr ffff8801bfde3368 by task syz-executor3/3005 [ 48.519053] [ 48.520661] CPU: 0 PID: 3005 Comm: syz-executor3 Not tainted 4.13.0-next-20170908+ #18 [ 48.528689] Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011 [ 48.538015] Call Trace: [ 48.540582] dump_stack+0x194/0x257 [ 48.544186] ? arch_local_irq_restore+0x53/0x53 [ 48.548830] ? show_regs_print_info+0x65/0x65 [ 48.553305] ? __dev_remove_pack+0x305/0x3b0 [ 48.557688] print_address_description+0x73/0x250 [ 48.562507] ? __dev_remove_pack+0x305/0x3b0 [ 48.566890] kasan_report+0x24e/0x340 [ 48.570668] __asan_report_load8_noabort+0x14/0x20 [ 48.575569] __dev_remove_pack+0x305/0x3b0 [ 48.579780] ? dev_get_by_name_rcu+0x270/0x270 [ 48.584342] ? refcount_sub_and_test+0x115/0x1b0 [ 48.589081] __unregister_prot_hook+0x211/0x280 [ 48.593728] packet_release+0x8bb/0xd70 [ 48.597681] ? packet_set_ring+0x1b70/0x1b70 [ 48.602064] ? dentry_free+0xcd/0x130 [ 48.605837] ? rcu_read_lock_sched_held+0x108/0x120 [ 48.610828] ? kmem_cache_free+0x249/0x280 [ 48.615036] ? dentry_free+0xd2/0x130 [ 48.618815] ? locks_remove_file+0x3fa/0x5a0 [ 48.623199] ? fcntl_setlk+0x10d0/0x10d0 [ 48.627237] ? __fsnotify_parent+0xb4/0x3a0 [ 48.631532] ? fsnotify+0x1af0/0x1af0 [ 48.635311] sock_release+0x8d/0x1e0 [ 48.639000] ? sock_release+0x8d/0x1e0 [ 48.642861] ? sock_release+0x1e0/0x1e0 [ 48.646809] sock_close+0x16/0x20 [ 48.650238] __fput+0x333/0x7f0 [ 48.653499] ? fput+0x140/0x140 [ 48.656768] ? check_same_owner+0x320/0x320 [ 48.661069] ? _raw_spin_unlock_irq+0x27/0x70 [ 48.665548] ____fput+0x15/0x20 [ 48.668802] task_work_run+0x199/0x270 [ 48.672668] ? task_work_cancel+0x210/0x210 [ 48.676963] ? _raw_spin_unlock+0x22/0x30 [ 48.681084] ? switch_task_namespaces+0x87/0xc0 [ 48.685744] do_exit+0xa52/0x1b40 [ 48.689172] ? plist_check_list+0xa0/0xa0 [ 48.693304] ? plist_del+0x47b/0x990 [ 48.696994] ? mm_update_next_owner+0x930/0x930 [ 48.701637] ? plist_add+0x760/0x760 [ 48.705351] ? check_same_owner+0x320/0x320 [ 48.709663] ? find_held_lock+0x39/0x1d0 [ 48.713707] ? check_noncircular+0x20/0x20 [ 48.717917] ? lock_downgrade+0x990/0x990 [ 48.722476] ? refill_pi_state_cache.part.6+0x2f0/0x2f0 [ 48.727835] ? find_held_lock+0x39/0x1d0 [ 48.731882] ? lock_downgrade+0x990/0x990 [ 48.736005] ? recalc_sigpending_tsk+0x117/0x150 [ 48.740736] ? recalc_sigpending+0x103/0x160 [ 48.745118] ? recalc_sigpending_tsk+0x150/0x150 [ 48.749844] ? get_signal+0x397/0x17e0 [ 48.753719] do_group_exit+0x149/0x400 [ 48.757580] ? __lock_is_held+0xbc/0x140 [ 48.761617] ? SyS_exit+0x30/0x30 [ 48.765044] ? _raw_spin_unlock_irq+0x27/0x70 [ 48.769610] ? trace_hardirqs_on_caller+0x421/0x5c0 [ 48.774609] get_signal+0x7e8/0x17e0 [ 48.778332] ? ptrace_notify+0x130/0x130 [ 48.782377] ? __schedule+0x8f0/0x2070 [ 48.786236] ? lock_release+0xd70/0xd70 [ 48.790192] ? exit_robust_list+0x240/0x240 [ 48.794516] do_signal+0x94/0x1ee0 [ 48.798036] ? iterate_fd+0x3f0/0x3f0 [ 48.801814] ? setup_sigcontext+0x7d0/0x7d0 [ 48.806118] ? schedule+0x108/0x440 [ 48.809719] ? mntput_no_expire+0x15e/0xa90 [ 48.814013] ? check_same_owner+0x320/0x320 [ 48.818309] ? __schedule+0x2070/0x2070 [ 48.822263] ? __fget_light+0x29d/0x390 [ 48.826216] ? selinux_tun_dev_create+0xc0/0xc0 [ 48.830861] ? putname+0xee/0x130 [ 48.834287] ? selinux_netlbl_socket_setsockopt+0x10c/0x460 [ 48.839971] ? selinux_netlbl_sock_rcv_skb+0x730/0x730 [ 48.845223] ? exit_to_usermode_loop+0x98/0x300 [ 48.849874] exit_to_usermode_loop+0x224/0x300 [ 48.854435] ? trace_event_raw_event_sys_exit+0x260/0x260 [ 48.859957] syscall_return_slowpath+0x42f/0x500 [ 48.864687] ? prepare_exit_to_usermode+0x2c0/0x2c0 [ 48.869678] ? entry_SYSCALL_64_fastpath+0x91/0xbe [ 48.874593] ? trace_hardirqs_on_caller+0x421/0x5c0 [ 48.879585] ? trace_hardirqs_on_thunk+0x1a/0x1c [ 48.884324] entry_SYSCALL_64_fastpath+0xbc/0xbe [ 48.889061] RIP: 0033:0x451e59 [ 48.892225] RSP: 002b:00007f4b4b5becf8 EFLAGS: 00000246 ORIG_RAX: 00000000000000ca [ 48.899912] RAX: fffffffffffffe00 RBX: 0000000000718028 RCX: 0000000000451e59 [ 48.907156] RDX: 0000000000000000 RSI: 0000000000000000 RDI: 0000000000718028 [ 48.914401] RBP: 0000000000718000 R08: 0000000000000000 R09: 0000000000000000 [ 48.921648] R10: 0000000000000000 R11: 0000000000000246 R12: 0000000000000000 [ 48.928892] R13: 00007ffd3a4bebaf R14: 00007f4b4b5bf9c0 R15: 0000000000000000 [ 48.936154] [ 48.937754] Allocated by task 3005: [ 48.941356] save_stack_trace+0x16/0x20 [ 48.945301] save_stack+0x43/0xd0 [ 48.948727] kasan_kmalloc+0xad/0xe0 [ 48.952411] kmem_cache_alloc_trace+0x136/0x750 [ 48.957070] fanout_add+0xa50/0x1190 [ 48.960757] packet_setsockopt+0xfdc/0x1e80 [ 48.965052] SyS_setsockopt+0x189/0x360 [ 48.969174] entry_SYSCALL_64_fastpath+0x1f/0xbe [ 48.973909] [ 48.975529] Freed by task 3005: [ 48.978790] save_stack_trace+0x16/0x20 [ 48.982746] save_stack+0x43/0xd0 [ 48.986169] kasan_slab_free+0x71/0xc0 [ 48.990036] kfree+0xca/0x250 [ 48.993115] packet_release+0xa8f/0xd70 [ 48.997061] sock_release+0x8d/0x1e0 [ 49.000749] sock_close+0x16/0x20 [ 49.004175] __fput+0x333/0x7f0 [ 49.007437] ____fput+0x15/0x20 [ 49.010689] task_work_run+0x199/0x270 [ 49.014545] do_exit+0xa52/0x1b40 [ 49.017968] do_group_exit+0x149/0x400 [ 49.021839] get_signal+0x7e8/0x17e0 [ 49.025526] do_signal+0x94/0x1ee0 [ 49.029040] exit_to_usermode_loop+0x224/0x300 [ 49.033606] syscall_return_slowpath+0x42f/0x500 [ 49.038333] entry_SYSCALL_64_fastpath+0xbc/0xbe [ 49.043057] [ 49.044657] The buggy address belongs to the object at ffff8801bfde2ac0 [ 49.044657] which belongs to the cache kmalloc-4096 of size 4096 [ 49.057460] The buggy address is located 2216 bytes inside of [ 49.057460] 4096-byte region [ffff8801bfde2ac0, ffff8801bfde3ac0) [ 49.069477] The buggy address belongs to the page: [ 49.074380] page:ffffea0006ff7880 count:1 mapcount:0 mapping:ffff8801bfde2ac0 index:0x0 compound_mapcount: 0 [ 49.084338] flags: 0x200000000008100(slab|head) [ 49.088993] raw: 0200000000008100 ffff8801bfde2ac0 0000000000000000 0000000100000001 [ 49.096847] raw: ffffea000739a4a0 ffffea0006ffeaa0 ffff8801dac00dc0 0000000000000000 [ 49.104699] page dumped because: kasan: bad access detected [ 49.110379] [ 49.111986] Memory state around the buggy address: [ 49.116895] ffff8801bfde3200: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb [ 49.124227] ffff8801bfde3280: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb [ 49.131566] >ffff8801bfde3300: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb [ 49.138906] ^ [ 49.145630] ffff8801bfde3380: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb [ 49.152962] ffff8801bfde3400: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb [ 49.160292] ================================================================== [ 49.167622] Disabling lock debugging due to kernel taint [ 49.173154] Kernel panic - not syncing: panic_on_warn set ... [ 49.173154] [ 49.180484] CPU: 0 PID: 3005 Comm: syz-executor3 Tainted: G B 4.13.0-next-20170908+ #18 [ 49.189727] Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011 [ 49.199065] Call Trace: [ 49.201623] dump_stack+0x194/0x257 [ 49.205534] ? arch_local_irq_restore+0x53/0x53 [ 49.210187] ? trace_hardirqs_on_thunk+0x1a/0x1c [ 49.214919] ? __dev_remove_pack+0x2f0/0x3b0 [ 49.219299] panic+0x1e4/0x417 [ 49.222475] ? __warn+0x1d9/0x1d9 [ 49.225901] ? __dev_remove_pack+0x305/0x3b0 [ 49.230276] kasan_end_report+0x50/0x50 [ 49.234218] kasan_report+0x137/0x340 [ 49.237996] __asan_report_load8_noabort+0x14/0x20 [ 49.242892] __dev_remove_pack+0x305/0x3b0 [ 49.247102] ? dev_get_by_name_rcu+0x270/0x270 [ 49.251653] ? refcount_sub_and_test+0x115/0x1b0 [ 49.256382] __unregister_prot_hook+0x211/0x280 [ 49.261019] packet_release+0x8bb/0xd70 [ 49.264963] ? packet_set_ring+0x1b70/0x1b70 [ 49.269340] ? dentry_free+0xcd/0x130 [ 49.273109] ? rcu_read_lock_sched_held+0x108/0x120 [ 49.278092] ? kmem_cache_free+0x249/0x280 [ 49.282295] ? dentry_free+0xd2/0x130 [ 49.286065] ? locks_remove_file+0x3fa/0x5a0 [ 49.290439] ? fcntl_setlk+0x10d0/0x10d0 [ 49.294469] ? __fsnotify_parent+0xb4/0x3a0 [ 49.298766] ? fsnotify+0x1af0/0x1af0 [ 49.302536] sock_release+0x8d/0x1e0 [ 49.306214] ? sock_release+0x8d/0x1e0 [ 49.310067] ? sock_release+0x1e0/0x1e0 [ 49.314007] sock_close+0x16/0x20 [ 49.317428] __fput+0x333/0x7f0 [ 49.320687] ? fput+0x140/0x140 [ 49.323943] ? check_same_owner+0x320/0x320 [ 49.328234] ? _raw_spin_unlock_irq+0x27/0x70 [ 49.332706] ____fput+0x15/0x20 [ 49.335952] task_work_run+0x199/0x270 [ 49.339808] ? task_work_cancel+0x210/0x210 [ 49.344096] ? _raw_spin_unlock+0x22/0x30 [ 49.348212] ? switch_task_namespaces+0x87/0xc0 [ 49.352850] do_exit+0xa52/0x1b40 [ 49.356276] ? plist_check_list+0xa0/0xa0 [ 49.360407] ? plist_del+0x47b/0x990 [ 49.364086] ? mm_update_next_owner+0x930/0x930 [ 49.368723] ? plist_add+0x760/0x760 [ 49.372409] ? check_same_owner+0x320/0x320 [ 49.376710] ? find_held_lock+0x39/0x1d0 [ 49.380740] ? check_noncircular+0x20/0x20 [ 49.384942] ? lock_downgrade+0x990/0x990 [ 49.389060] ? refill_pi_state_cache.part.6+0x2f0/0x2f0 [ 49.394409] ? find_held_lock+0x39/0x1d0 [ 49.398452] ? lock_downgrade+0x990/0x990 [ 49.402580] ? recalc_sigpending_tsk+0x117/0x150 [ 49.407305] ? recalc_sigpending+0x103/0x160 [ 49.411679] ? recalc_sigpending_tsk+0x150/0x150 [ 49.416399] ? get_signal+0x397/0x17e0 [ 49.420257] do_group_exit+0x149/0x400 [ 49.424116] ? __lock_is_held+0xbc/0x140 [ 49.428142] ? SyS_exit+0x30/0x30 [ 49.431564] ? _raw_spin_unlock_irq+0x27/0x70 [ 49.436025] ? trace_hardirqs_on_caller+0x421/0x5c0 [ 49.441008] get_signal+0x7e8/0x17e0 [ 49.444702] ? ptrace_notify+0x130/0x130 [ 49.448733] ? __schedule+0x8f0/0x2070 [ 49.452599] ? lock_release+0xd70/0xd70 [ 49.456546] ? exit_robust_list+0x240/0x240 [ 49.460841] do_signal+0x94/0x1ee0 [ 49.464353] ? iterate_fd+0x3f0/0x3f0 [ 49.468120] ? setup_sigcontext+0x7d0/0x7d0 [ 49.472410] ? schedule+0x108/0x440 [ 49.476002] ? mntput_no_expire+0x15e/0xa90