Warning: Permanently added '10.128.0.67' (ECDSA) to the list of known hosts. executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program syzkaller login: [ 516.922410][ T9390] ================================================================== [ 516.931982][ T9390] BUG: KASAN: use-after-free in n_tty_receive_buf_common+0x270f/0x2b70 [ 516.932002][ T9390] Read of size 1 at addr ffff8880a9415001 by task syz-executor980/9390 [ 516.932006][ T9390] [ 516.932021][ T9390] CPU: 1 PID: 9390 Comm: syz-executor980 Not tainted 5.5.0-rc2-next-20191220-syzkaller #0 [ 516.932029][ T9390] Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011 [ 516.932059][ T9390] Call Trace: [ 516.932104][ T9390] dump_stack+0x197/0x210 [ 516.932119][ T9390] ? n_tty_receive_buf_common+0x270f/0x2b70 [ 516.932183][ T9390] print_address_description.constprop.0.cold+0xd4/0x30b [ 516.932204][ T9390] ? n_tty_receive_buf_common+0x270f/0x2b70 [ 517.001176][ T9390] ? n_tty_receive_buf_common+0x270f/0x2b70 [ 517.001193][ T9390] __kasan_report.cold+0x1b/0x41 [ 517.001208][ T9390] ? n_tty_receive_buf_common+0x270f/0x2b70 [ 517.001228][ T9390] kasan_report+0x12/0x20 [ 517.022864][ T9390] __asan_report_load1_noabort+0x14/0x20 [ 517.022879][ T9390] n_tty_receive_buf_common+0x270f/0x2b70 [ 517.022893][ T9390] ? __kasan_check_read+0x11/0x20 [ 517.022925][ T9390] n_tty_receive_buf2+0x34/0x40 [ 517.022943][ T9390] tty_ldisc_receive_buf+0xad/0x1c0 [ 517.023016][ T9390] ? add_wait_queue+0x112/0x170 [ 517.023030][ T9390] ? n_tty_receive_buf_common+0x2b70/0x2b70 [ 517.023058][ T9390] paste_selection+0x1ff/0x460 [ 517.023080][ T9390] ? vcs_remove_sysfs+0x60/0x60 [ 517.023114][ T9390] ? lock_downgrade+0x920/0x920 [ 517.023153][ T9390] ? wake_up_q+0x140/0x140 [ 517.081116][ T9390] tioclinux+0x133/0x480 [ 517.081134][ T9390] vt_ioctl+0x1a41/0x26d0 [ 517.081150][ T9390] ? complete_change_console+0x3a0/0x3a0 [ 517.081257][ T9390] ? tomoyo_execute_permission+0x4a0/0x4a0 [ 517.081330][ T9390] ? __sanitizer_cov_trace_switch+0x49/0x80 [ 517.081346][ T9390] ? tty_jobctrl_ioctl+0x50/0xd40 [ 517.081367][ T9390] ? complete_change_console+0x3a0/0x3a0 [ 517.118570][ T9390] tty_ioctl+0xa37/0x14f0 [ 517.118586][ T9390] ? tty_vhangup+0x30/0x30 [ 517.118603][ T9390] ? __sanitizer_cov_trace_const_cmp2+0x18/0x20 [ 517.118694][ T9390] ? do_vfs_ioctl+0x11b/0x1340 [ 517.118714][ T9390] ? ioctl_file_clone+0x180/0x180 [ 517.118731][ T9390] ? __sanitizer_cov_trace_const_cmp4+0x16/0x20 [ 517.118785][ T9390] ? debug_smp_processor_id+0x33/0x18a [ 517.118846][ T9390] ? rcu_lockdep_current_cpu_online+0xe3/0x130 [ 517.162459][ T9390] ? rcu_read_lock_sched_held+0x9c/0xd0 [ 517.162478][ T9390] ? tomoyo_file_ioctl+0x23/0x30 [ 517.162493][ T9390] ? __sanitizer_cov_trace_const_cmp4+0x16/0x20 [ 517.162598][ T9390] ? security_file_ioctl+0x8d/0xc0 [ 517.162616][ T9390] ? tty_vhangup+0x30/0x30 [ 517.188942][ T9390] ksys_ioctl+0x123/0x180 [ 517.188961][ T9390] __x64_sys_ioctl+0x73/0xb0 [ 517.189051][ T9390] do_syscall_64+0xfa/0x790 [ 517.189097][ T9390] entry_SYSCALL_64_after_hwframe+0x49/0xbe [ 517.189110][ T9390] RIP: 0033:0x441319 [ 517.189127][ T9390] Code: e8 ac e8 ff ff 48 83 c4 18 c3 0f 1f 80 00 00 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 0f 83 eb 08 fc ff c3 66 2e 0f 1f 84 00 00 00 00 [ 517.189135][ T9390] RSP: 002b:00007fff031b0b38 EFLAGS: 00000246 ORIG_RAX: 0000000000000010 [ 517.189150][ T9390] RAX: ffffffffffffffda RBX: 0000000000000000 RCX: 0000000000441319 [ 517.189159][ T9390] RDX: 00000000200001c0 RSI: 000000000000541c RDI: 0000000000000003 [ 517.189167][ T9390] RBP: 000000000007e2c3 R08: 000000000000000d R09: 00000000004002c8 [ 517.189174][ T9390] R10: 0000000000000000 R11: 0000000000000246 R12: 0000000000402090 [ 517.189182][ T9390] R13: 0000000000402120 R14: 0000000000000000 R15: 0000000000000000 [ 517.189201][ T9390] [ 517.189236][ T9390] Allocated by task 9388: [ 517.189251][ T9390] save_stack+0x23/0x90 [ 517.189263][ T9390] __kasan_kmalloc.constprop.0+0xcf/0xe0 [ 517.189274][ T9390] kasan_kmalloc+0x9/0x10 [ 517.189284][ T9390] __kmalloc+0x163/0x770 [ 517.189300][ T9390] set_selection_kernel+0x872/0x13b0 [ 517.189312][ T9390] set_selection_user+0x95/0xd9 [ 517.189324][ T9390] tioclinux+0x11c/0x480 [ 517.189336][ T9390] vt_ioctl+0x1a41/0x26d0 [ 517.189346][ T9390] tty_ioctl+0xa37/0x14f0 [ 517.189358][ T9390] ksys_ioctl+0x123/0x180 [ 517.189371][ T9390] __x64_sys_ioctl+0x73/0xb0 [ 517.189382][ T9390] do_syscall_64+0xfa/0x790 [ 517.189406][ T9390] entry_SYSCALL_64_after_hwframe+0x49/0xbe [ 517.355214][ T9390] [ 517.355223][ T9390] Freed by task 9389: [ 517.355240][ T9390] save_stack+0x23/0x90 [ 517.355252][ T9390] __kasan_slab_free+0x102/0x150 [ 517.355264][ T9390] kasan_slab_free+0xe/0x10 [ 517.355274][ T9390] kfree+0x10a/0x2c0 [ 517.355289][ T9390] set_selection_kernel+0x88f/0x13b0 [ 517.355303][ T9390] set_selection_user+0x95/0xd9 [ 517.355314][ T9390] tioclinux+0x11c/0x480 [ 517.355326][ T9390] vt_ioctl+0x1a41/0x26d0 [ 517.355336][ T9390] tty_ioctl+0xa37/0x14f0 [ 517.355348][ T9390] ksys_ioctl+0x123/0x180 [ 517.355366][ T9390] __x64_sys_ioctl+0x73/0xb0 [ 517.428306][ T9390] do_syscall_64+0xfa/0x790 [ 517.428321][ T9390] entry_SYSCALL_64_after_hwframe+0x49/0xbe [ 517.428325][ T9390] [ 517.428335][ T9390] The buggy address belongs to the object at ffff8880a9415000 [ 517.428335][ T9390] which belongs to the cache kmalloc-512 of size 512 [ 517.428347][ T9390] The buggy address is located 1 bytes inside of [ 517.428347][ T9390] 512-byte region [ffff8880a9415000, ffff8880a9415200) [ 517.428353][ T9390] The buggy address belongs to the page: [ 517.428367][ T9390] page:ffffea0002a50540 refcount:1 mapcount:0 mapping:ffff8880aa400a80 index:0xffff8880a9415800 [ 517.428388][ T9390] raw: 00fffe0000000200 ffffea0002a3fbc8 ffffea00026a8f48 ffff8880aa400a80 [ 517.428406][ T9390] raw: ffff8880a9415800 ffff8880a9415000 0000000100000003 0000000000000000 [ 517.428412][ T9390] page dumped because: kasan: bad access detected [ 517.428416][ T9390] [ 517.428421][ T9390] Memory state around the buggy address: [ 517.428433][ T9390] ffff8880a9414f00: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc [ 517.428442][ T9390] ffff8880a9414f80: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc [ 517.428452][ T9390] >ffff8880a9415000: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb [ 517.428456][ T9390] ^ [ 517.428465][ T9390] ffff8880a9415080: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb [ 517.428476][ T9390] ffff8880a9415100: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb [ 517.428481][ T9390] ================================================================== [ 517.428486][ T9390] Disabling lock debugging due to kernel taint [ 517.429077][ T9390] Kernel panic - not syncing: panic_on_warn set ... [ 517.429096][ T9390] CPU: 1 PID: 9390 Comm: syz-executor980 Tainted: G B 5.5.0-rc2-next-20191220-syzkaller #0 [ 517.429102][ T9390] Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011 [ 517.429106][ T9390] Call Trace: [ 517.429118][ T9390] dump_stack+0x197/0x210 [ 517.429201][ T9390] panic+0x2e3/0x75c [ 517.429216][ T9390] ? add_taint.cold+0x16/0x16 [ 517.429232][ T9390] ? n_tty_receive_buf_common+0x270f/0x2b70 [ 517.429245][ T9390] ? preempt_schedule+0x4b/0x60 [ 517.429259][ T9390] ? ___preempt_schedule+0x16/0x18 [ 517.429312][ T9390] ? trace_hardirqs_on+0x5e/0x240 [ 517.429335][ T9390] ? n_tty_receive_buf_common+0x270f/0x2b70 [ 517.429352][ T9390] end_report+0x47/0x4f [ 517.429368][ T9390] ? n_tty_receive_buf_common+0x270f/0x2b70 [ 517.429383][ T9390] __kasan_report.cold+0xe/0x41 [ 517.429401][ T9390] ? n_tty_receive_buf_common+0x270f/0x2b70 [ 517.429419][ T9390] kasan_report+0x12/0x20 [ 517.429435][ T9390] __asan_report_load1_noabort+0x14/0x20 [ 517.429452][ T9390] n_tty_receive_buf_common+0x270f/0x2b70 [ 517.429467][ T9390] ? __kasan_check_read+0x11/0x20 [ 517.429495][ T9390] n_tty_receive_buf2+0x34/0x40 [ 517.429512][ T9390] tty_ldisc_receive_buf+0xad/0x1c0 [ 517.429527][ T9390] ? add_wait_queue+0x112/0x170 [ 517.429543][ T9390] ? n_tty_receive_buf_common+0x2b70/0x2b70 [ 517.429559][ T9390] paste_selection+0x1ff/0x460 [ 517.429576][ T9390] ? vcs_remove_sysfs+0x60/0x60 [ 517.429593][ T9390] ? lock_downgrade+0x920/0x920 [ 517.429611][ T9390] ? wake_up_q+0x140/0x140 [ 517.429628][ T9390] tioclinux+0x133/0x480 [ 517.429643][ T9390] vt_ioctl+0x1a41/0x26d0 [ 517.429660][ T9390] ? complete_change_console+0x3a0/0x3a0 [ 517.429679][ T9390] ? tomoyo_execute_permission+0x4a0/0x4a0 [ 517.429698][ T9390] ? __sanitizer_cov_trace_switch+0x49/0x80 [ 517.429716][ T9390] ? tty_jobctrl_ioctl+0x50/0xd40 [ 517.429732][ T9390] ? complete_change_console+0x3a0/0x3a0 [ 517.429747][ T9390] tty_ioctl+0xa37/0x14f0 [ 517.429761][ T9390] ? tty_vhangup+0x30/0x30 [ 517.429782][ T9390] ? __sanitizer_cov_trace_const_cmp2+0x18/0x20 [ 517.429799][ T9390] ? do_vfs_ioctl+0x11b/0x1340 [ 517.429815][ T9390] ? ioctl_file_clone+0x180/0x180 [ 517.429835][ T9390] ? __sanitizer_cov_trace_const_cmp4+0x16/0x20 [ 517.429853][ T9390] ? debug_smp_processor_id+0x33/0x18a [ 517.429872][ T9390] ? rcu_lockdep_current_cpu_online+0xe3/0x130 [ 517.429888][ T9390] ? rcu_read_lock_sched_held+0x9c/0xd0 [ 517.429905][ T9390] ? tomoyo_file_ioctl+0x23/0x30 [ 517.429922][ T9390] ? __sanitizer_cov_trace_const_cmp4+0x16/0x20 [ 517.429939][ T9390] ? security_file_ioctl+0x8d/0xc0 [ 517.429953][ T9390] ? tty_vhangup+0x30/0x30 [ 517.429968][ T9390] ksys_ioctl+0x123/0x180 [ 517.429990][ T9390] __x64_sys_ioctl+0x73/0xb0 [ 517.430007][ T9390] do_syscall_64+0xfa/0x790 [ 517.430024][ T9390] entry_SYSCALL_64_after_hwframe+0x49/0xbe [ 517.430037][ T9390] RIP: 0033:0x441319 [ 517.430053][ T9390] Code: e8 ac e8 ff ff 48 83 c4 18 c3 0f 1f 80 00 00 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 0f 83 eb 08 fc ff c3 66 2e 0f 1f 84 00 00 00 00 [ 517.430065][ T9390] RSP: 002b:00007fff031b0b38 EFLAGS: 00000246 ORIG_RAX: 0000000000000010 [ 517.430086][ T9390] RAX: ffffffffffffffda RBX: 0000000000000000 RCX: 0000000000441319 [ 517.430098][ T9390] RDX: 00000000200001c0 RSI: 000000000000541c RDI: 0000000000000003 [ 517.430109][ T9390] RBP: 000000000007e2c3 R08: 000000000000000d R09: 00000000004002c8 [ 517.430121][ T9390] R10: 0000000000000000 R11: 0000000000000246 R12: 0000000000402090 [ 517.430132][ T9390] R13: 0000000000402120 R14: 0000000000000000 R15: 0000000000000000 [ 517.432595][ T9390] Kernel Offset: disabled [ 517.994874][ T9390] Rebooting in 86400 seconds..