syzbot


BUG: unable to handle kernel NULL pointer dereference in __tcp_transmit_skb

Status: auto-obsoleted due to no activity on 2023/04/22 09:49
Subsystems: net
[Documentation on labels]
Reported-by: syzbot+090d23ddbd5cd185c2e0@syzkaller.appspotmail.com
First crash: 986d, last: 886d
Cause bisection: introduced by (bisect log) :
commit f2f2325ec79970807012dfc9e716cdbb02d9b574
Author: Eric Dumazet <edumazet@google.com>
Date: Fri Feb 4 20:15:46 2022 +0000

  ip6mr: ip6mr_sk_done() can exit early in common cases

Crash: KASAN: use-after-free Read in ip6mr_sk_done (log)
Repro: C syz .config
  
Fix bisection the fix commit could be any of (bisect log):
  36c2e31ad25b net: geneve: add missing netlink policy and size for IFLA_GENEVE_INNER_PROTO_INHERIT
  8e4372e61785 Merge branch 'add-mtu-change-with-stmmac-interface-running'
  
Discussions (1)
Title Replies (including bot) Last reply
[syzbot] BUG: unable to handle kernel NULL pointer dereference in __tcp_transmit_skb 2 (4) 2022/03/24 08:11
Last patch testing requests (6)
Created Duration User Patch Repo Result
2023/04/22 09:40 25m retest repro net-next OK log
2023/04/22 09:26 22m retest repro net-next OK log
2023/01/11 22:32 19m retest repro net-next-old report log
2022/10/03 21:30 16m retest repro net-next-old report log
2022/07/05 14:20 17m gautammenghani201@gmail.com upstream report log
2022/07/05 08:21 15m gautammenghani201@gmail.com https://git.kernel.org/pub/scm/linux/kernel/git/netdev/net-next.git master report log
Fix bisection attempts (3)
Created Duration User Patch Repo Result
2022/07/26 04:23 21m bisect fix net-next-old OK (2) job log
2022/06/25 20:56 26m bisect fix net-next-old OK (0) job log log
2022/05/09 10:44 19m bisect fix net-next-old OK (0) job log log

Sample crash report:
BUG: kernel NULL pointer dereference, address: 0000000000000000
#PF: supervisor instruction fetch in kernel mode
#PF: error_code(0x0010) - not-present page
PGD 13fd5067 P4D 13fd5067 PUD 77ebc067 PMD 0 
Oops: 0010 [#1] PREEMPT SMP KASAN
CPU: 1 PID: 7423 Comm: syz-executor720 Not tainted 5.17.0-rc8-syzkaller-02803-g36c2e31ad25b #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011
RIP: 0010:0x0
Code: Unable to access opcode bytes at RIP 0xffffffffffffffd6.
RSP: 0018:ffffc900001d0a60 EFLAGS: 00010246
RAX: dffffc0000000000 RBX: ffff88801e00cd10 RCX: 0000000000000100
RDX: 1ffff11003c019a3 RSI: ffff8880155c5c80 RDI: ffff888014bac800
RBP: ffff888014bac800 R08: 0000000000000000 R09: 0000000000000000
R10: ffffffff87bccdc7 R11: 0000000000000000 R12: ffff8880155c5c80
R13: 0000000000000000 R14: ffff888014bacf60 R15: ffff88807527012c
FS:  000055555733b3c0(0000) GS:ffff8880b9d00000(0000) knlGS:0000000000000000
CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: ffffffffffffffd6 CR3: 00000000757b0000 CR4: 00000000003506e0
DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000
DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400
Call Trace:
 <IRQ>
 __tcp_transmit_skb+0x1098/0x38b0 net/ipv4/tcp_output.c:1371
 tcp_transmit_skb net/ipv4/tcp_output.c:1420 [inline]
 tcp_xmit_probe_skb+0x28c/0x320 net/ipv4/tcp_output.c:4006
 tcp_write_wakeup+0x1bd/0x610 net/ipv4/tcp_output.c:4059
 tcp_send_probe0+0x44/0x560 net/ipv4/tcp_output.c:4074
 tcp_probe_timer net/ipv4/tcp_timer.c:398 [inline]
 tcp_write_timer_handler+0x9ed/0xbc0 net/ipv4/tcp_timer.c:626
 tcp_write_timer+0xa2/0x2b0 net/ipv4/tcp_timer.c:642
 call_timer_fn+0x1a5/0x6b0 kernel/time/timer.c:1421
 expire_timers kernel/time/timer.c:1466 [inline]
 __run_timers.part.0+0x67c/0xa30 kernel/time/timer.c:1734
 __run_timers kernel/time/timer.c:1715 [inline]
 run_timer_softirq+0xb3/0x1d0 kernel/time/timer.c:1747
 __do_softirq+0x29b/0x9c2 kernel/softirq.c:558
 invoke_softirq kernel/softirq.c:432 [inline]
 __irq_exit_rcu+0x123/0x180 kernel/softirq.c:637
 irq_exit_rcu+0x5/0x20 kernel/softirq.c:649
 sysvec_apic_timer_interrupt+0x93/0xc0 arch/x86/kernel/apic/apic.c:1097
 </IRQ>
 <TASK>
 asm_sysvec_apic_timer_interrupt+0x12/0x20 arch/x86/include/asm/idtentry.h:638
RIP: 0010:lock_acquire+0x1ef/0x510 kernel/locking/lockdep.c:5607
Code: e4 a4 7e 83 f8 01 0f 85 b4 02 00 00 9c 58 f6 c4 02 0f 85 9f 02 00 00 48 83 7c 24 08 00 74 01 fb 48 b8 00 00 00 00 00 fc ff df <48> 01 c3 48 c7 03 00 00 00 00 48 c7 43 08 00 00 00 00 48 8b 84 24
RSP: 0018:ffffc90002eaf888 EFLAGS: 00000206
RAX: dffffc0000000000 RBX: 1ffff920005d5f13 RCX: 5ad5b746ce328923
RDX: 1ffff1100e5374eb RSI: 0000000000000000 RDI: 0000000000000000
RBP: 0000000000000000 R08: 0000000000000000 R09: ffffffff8fe0c947
R10: fffffbfff1fc1928 R11: 0000000000000001 R12: 0000000000000002
R13: 0000000000000000 R14: ffffffff8bb84ca0 R15: 0000000000000000
 rcu_lock_acquire include/linux/rcupdate.h:268 [inline]
 rcu_read_lock include/linux/rcupdate.h:694 [inline]
 fib_lookup.constprop.0+0x8f/0x460 include/net/ip_fib.h:377
 ip_route_output_key_hash_rcu+0xf54/0x2c80 net/ipv4/route.c:2737
 ip_route_output_key_hash+0x183/0x2f0 net/ipv4/route.c:2627
 __ip_route_output_key include/net/route.h:127 [inline]
 ip_route_output_flow+0x23/0x150 net/ipv4/route.c:2857
 ip_route_newports include/net/route.h:343 [inline]
 tcp_v4_connect+0x12a5/0x1d00 net/ipv4/tcp_ipv4.c:283
 __inet_stream_connect+0x8cf/0xed0 net/ipv4/af_inet.c:660
 inet_stream_connect+0x53/0xa0 net/ipv4/af_inet.c:724
 smc_connect+0x230/0x450 net/smc/af_smc.c:1522
 __sys_connect_file+0x155/0x1a0 net/socket.c:1900
 __sys_connect+0x161/0x190 net/socket.c:1917
 __do_sys_connect net/socket.c:1927 [inline]
 __se_sys_connect net/socket.c:1924 [inline]
 __x64_sys_connect+0x6f/0xb0 net/socket.c:1924
 do_syscall_x64 arch/x86/entry/common.c:50 [inline]
 do_syscall_64+0x35/0xb0 arch/x86/entry/common.c:80
 entry_SYSCALL_64_after_hwframe+0x44/0xae
RIP: 0033:0x7f23b4ec0889
Code: 28 00 00 00 75 05 48 83 c4 28 c3 e8 e1 14 00 00 90 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 73 01 c3 48 c7 c1 c0 ff ff ff f7 d8 64 89 01 48
RSP: 002b:00007ffce8f74658 EFLAGS: 00000246 ORIG_RAX: 000000000000002a
RAX: ffffffffffffffda RBX: 00007ffce8f746b0 RCX: 00007f23b4ec0889
RDX: 0000000000000010 RSI: 00000000200001c0 RDI: 0000000000000003
RBP: 0000000000000000 R08: 000000000000cf1c R09: 000000000000cf1c
R10: 0000000000000004 R11: 0000000000000246 R12: 00007ffce8f746a0
R13: 000000000000cf1c R14: 00007ffce8f7469c R15: 431bde82d7b634db
 </TASK>
Modules linked in:
CR2: 0000000000000000
---[ end trace 0000000000000000 ]---
RIP: 0010:0x0
Code: Unable to access opcode bytes at RIP 0xffffffffffffffd6.
RSP: 0018:ffffc900001d0a60 EFLAGS: 00010246
RAX: dffffc0000000000 RBX: ffff88801e00cd10 RCX: 0000000000000100
RDX: 1ffff11003c019a3 RSI: ffff8880155c5c80 RDI: ffff888014bac800
RBP: ffff888014bac800 R08: 0000000000000000 R09: 0000000000000000
R10: ffffffff87bccdc7 R11: 0000000000000000 R12: ffff8880155c5c80
R13: 0000000000000000 R14: ffff888014bacf60 R15: ffff88807527012c
FS:  000055555733b3c0(0000) GS:ffff8880b9d00000(0000) knlGS:0000000000000000
CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: ffffffffffffffd6 CR3: 00000000757b0000 CR4: 00000000003506e0
DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000
DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400
----------------
Code disassembly (best guess):
   0:	e4 a4                	in     $0xa4,%al
   2:	7e 83                	jle    0xffffff87
   4:	f8                   	clc
   5:	01 0f                	add    %ecx,(%rdi)
   7:	85 b4 02 00 00 9c 58 	test   %esi,0x589c0000(%rdx,%rax,1)
   e:	f6 c4 02             	test   $0x2,%ah
  11:	0f 85 9f 02 00 00    	jne    0x2b6
  17:	48 83 7c 24 08 00    	cmpq   $0x0,0x8(%rsp)
  1d:	74 01                	je     0x20
  1f:	fb                   	sti
  20:	48 b8 00 00 00 00 00 	movabs $0xdffffc0000000000,%rax
  27:	fc ff df
* 2a:	48 01 c3             	add    %rax,%rbx <-- trapping instruction
  2d:	48 c7 03 00 00 00 00 	movq   $0x0,(%rbx)
  34:	48 c7 43 08 00 00 00 	movq   $0x0,0x8(%rbx)
  3b:	00
  3c:	48                   	rex.W
  3d:	8b                   	.byte 0x8b
  3e:	84                   	.byte 0x84
  3f:	24                   	.byte 0x24

Crashes (7):
Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Assets (help?) Manager Title
2022/03/24 00:13 net-next-old 36c2e31ad25b 5ff41e94 .config console log report syz C ci-upstream-net-kasan-gce BUG: unable to handle kernel NULL pointer dereference in __tcp_transmit_skb
2022/05/17 06:01 upstream 42226c989789 744a39e2 .config console log report info ci-upstream-kasan-gce-selinux-root BUG: unable to handle kernel NULL pointer dereference in __tcp_transmit_skb
2022/05/23 18:18 net-old 8c3b8dc5cc9b 4c7657cb .config console log report info ci-upstream-net-this-kasan-gce BUG: unable to handle kernel NULL pointer dereference in __tcp_transmit_skb
2022/05/10 06:04 net-old edae34a3ed92 8b277b8e .config console log report info ci-upstream-net-this-kasan-gce BUG: unable to handle kernel NULL pointer dereference in __tcp_transmit_skb
2022/03/23 23:41 net-next-old 36c2e31ad25b 5ff41e94 .config console log report info ci-upstream-net-kasan-gce BUG: unable to handle kernel NULL pointer dereference in __tcp_transmit_skb
2022/03/17 14:21 net-next-old d96657dc9238 dfa9a8ed .config console log report info ci-upstream-net-kasan-gce BUG: unable to handle kernel NULL pointer dereference in __tcp_transmit_skb
2022/04/01 06:14 linux-next e5071887cd22 68fc921a .config console log report info ci-upstream-linux-next-kasan-gce-root BUG: unable to handle kernel NULL pointer dereference in __tcp_transmit_skb
* Struck through repros no longer work on HEAD.