random: sshd: uninitialized urandom read (32 bytes read, 109 bits of entropy available) ================================================================== BUG: KASAN: slab-out-of-bounds in strnlen+0xc1/0xd0 lib/string.c:498 Read of size 1 at addr ffff8800b4166210 by task syzkaller458348/3325 CPU: 0 PID: 3325 Comm: syzkaller458348 Not tainted 4.4.113-ge70c132 #27 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011 0000000000000000 eae1dbf084bcf86b ffff8801d024f580 ffffffff81d0278d ffffea0002d05980 ffff8800b4166210 0000000000000000 ffff8800b4166210 ffff8801d024f850 ffff8801d024f5b8 ffffffff814fd053 ffff8800b4166210 Call Trace: [] __dump_stack lib/dump_stack.c:15 [inline] [] dump_stack+0xc1/0x124 lib/dump_stack.c:51 [] print_address_description+0x73/0x260 mm/kasan/report.c:252 [] kasan_report_error mm/kasan/report.c:351 [inline] [] kasan_report+0x285/0x370 mm/kasan/report.c:408 [] __asan_report_load1_noabort+0x14/0x20 mm/kasan/report.c:426 [] strnlen+0xc1/0xd0 lib/string.c:498 [] string.isra.4+0x4c/0x240 lib/vsprintf.c:518 [] vsnprintf+0x766/0x15f0 lib/vsprintf.c:1907 [] __request_module+0x14f/0x810 kernel/kmod.c:146 [] xt_request_find_target+0x8b/0xb0 net/netfilter/x_tables.c:255 [] check_compat_entry_size_and_hooks net/ipv4/netfilter/ip_tables.c:1490 [inline] [] translate_compat_table+0x568/0x1760 net/ipv4/netfilter/ip_tables.c:1582 [] ? 0xffffffff810002b8 [] compat_do_replace.isra.15+0x1f1/0x410 net/ipv4/netfilter/ip_tables.c:1690 [] compat_do_ipt_set_ctl+0x106/0x150 net/ipv4/netfilter/ip_tables.c:1721 [] compat_nf_sockopt net/netfilter/nf_sockopt.c:143 [inline] [] compat_nf_setsockopt+0x88/0x130 net/netfilter/nf_sockopt.c:155 [] compat_ip_setsockopt+0x9d/0xf0 net/ipv4/ip_sockglue.c:1255 [] inet_csk_compat_setsockopt+0x95/0x120 net/ipv4/inet_connection_sock.c:914 [] compat_tcp_setsockopt+0x3d/0x70 net/ipv4/tcp.c:2643 [] compat_sock_common_setsockopt+0xb2/0x140 net/core/sock.c:2670 [] C_SYSC_setsockopt net/compat.c:384 [inline] [] compat_SyS_setsockopt+0x149/0x290 net/compat.c:367 [] do_syscall_32_irqs_on arch/x86/entry/common.c:390 [inline] [] do_fast_syscall_32+0x314/0x890 arch/x86/entry/common.c:457 [] sysenter_flags_fixed+0xd/0x17 Allocated by task 3325: [] save_stack_trace+0x26/0x50 arch/x86/kernel/stacktrace.c:63 [] save_stack+0x43/0xd0 mm/kasan/kasan.c:512 [] set_track mm/kasan/kasan.c:524 [inline] [] kasan_kmalloc+0xad/0xe0 mm/kasan/kasan.c:616 [] __kmalloc+0x124/0x320 mm/slub.c:3613 [] kmalloc include/linux/slab.h:481 [inline] [] xt_alloc_table_info+0x71/0x100 net/netfilter/x_tables.c:911 [] compat_do_replace.isra.15+0x16b/0x410 net/ipv4/netfilter/ip_tables.c:1679 [] compat_do_ipt_set_ctl+0x106/0x150 net/ipv4/netfilter/ip_tables.c:1721 [] compat_nf_sockopt net/netfilter/nf_sockopt.c:143 [inline] [] compat_nf_setsockopt+0x88/0x130 net/netfilter/nf_sockopt.c:155 [] compat_ip_setsockopt+0x9d/0xf0 net/ipv4/ip_sockglue.c:1255 [] inet_csk_compat_setsockopt+0x95/0x120 net/ipv4/inet_connection_sock.c:914 [] compat_tcp_setsockopt+0x3d/0x70 net/ipv4/tcp.c:2643 [] compat_sock_common_setsockopt+0xb2/0x140 net/core/sock.c:2670 [] C_SYSC_setsockopt net/compat.c:384 [inline] [] compat_SyS_setsockopt+0x149/0x290 net/compat.c:367 [] do_syscall_32_irqs_on arch/x86/entry/common.c:390 [inline] [] do_fast_syscall_32+0x314/0x890 arch/x86/entry/common.c:457 [] sysenter_flags_fixed+0xd/0x17 Freed by task 1888: [] save_stack_trace+0x26/0x50 arch/x86/kernel/stacktrace.c:63 [] save_stack+0x43/0xd0 mm/kasan/kasan.c:512 [] set_track mm/kasan/kasan.c:524 [inline] [] kasan_slab_free+0x72/0xc0 mm/kasan/kasan.c:589 [] slab_free_hook mm/slub.c:1383 [inline] [] slab_free_freelist_hook mm/slub.c:1405 [inline] [] slab_free mm/slub.c:2859 [inline] [] kfree+0xfc/0x300 mm/slub.c:3749 [] free_bprm+0x19d/0x200 fs/exec.c:1246 [] do_execveat_common.isra.33+0x1711/0x1e60 fs/exec.c:1644 [] do_execve fs/exec.c:1679 [inline] [] SYSC_execve fs/exec.c:1760 [inline] [] SyS_execve+0x42/0x50 fs/exec.c:1755 [] return_from_execve+0x0/0x23 The buggy address belongs to the object at ffff8800b4166140 which belongs to the cache kmalloc-256 of size 256 The buggy address is located 208 bytes inside of 256-byte region [ffff8800b4166140, ffff8800b4166240) The buggy address belongs to the page: PANIC: double fault, error_code: 0x0 CPU: 0 PID: 3325 Comm: syzkaller458348 Not tainted 4.4.113-ge70c132 #27 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011 task: ffff8800b4f7c740 task.stack: ffff8801d0248000 RIP: 0010:[] [] dump_page_badflags+0x12/0x250 mm/debug.c:84 RSP: 0018:ffff880100000000 EFLAGS: 00010046 RAX: ffff8800b4f7c740 RBX: ffffea0002d05980 RCX: ffffffff8148f8d0 RDX: 0000000000000000 RSI: ffffffff838a8de0 RDI: ffffea0002d05980 RBP: ffff880100000020 R08: 0000000000000001 R09: 0000000000000000 R10: 0000000000000002 R11: fffffbfff0ad7e26 R12: 0000000000000000 R13: ffffffff838a8de0 R14: 0000000000000000 R15: 0000000000000000 FS: 0000000000000000(0000) GS:ffff8801db200000(0063) knlGS:00000000098bb840 CS: 0010 DS: 002b ES: 002b CR0: 0000000080050033 CR2: ffff8800fffffff8 CR3: 00000001d445e000 CR4: 0000000000160670 DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000 DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400 Stack: Call Trace: Code: 00 e9 50 fd ff ff e8 6e df 06 00 e9 1d fd ff ff 66 0f 1f 84 00 00 00 00 00 55 48 89 e5 41 57 41 56 41 55 49 89 f5 41 54 49 89 d4 <53> 48 89 fb 48 83 ec 08 e8 b1 04 ed ff 48 8d 7b 10 48 b8 00 00