syzbot


UBSAN: shift-out-of-bounds in xfrm_selector_match
Status: auto-closed as invalid on 2022/03/13 00:17
Reported-by: syzbot+e4c1dd36fc6b98c50859@syzkaller.appspotmail.com
First crash: 352d, last: 196d

Sample crash report:
================================================================================
UBSAN: shift-out-of-bounds in ./include/net/xfrm.h:829:23
shift exponent -128 is negative
CPU: 0 PID: 31981 Comm: syz-executor.5 Not tainted 5.15.0-syzkaller #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011
Call Trace:
 <TASK>
 __dump_stack lib/dump_stack.c:88 [inline]
 dump_stack_lvl+0xcd/0x134 lib/dump_stack.c:106
 ubsan_epilogue+0xb/0x5a lib/ubsan.c:151
 __ubsan_handle_shift_out_of_bounds.cold+0xb1/0x181 lib/ubsan.c:330
 addr4_match include/net/xfrm.h:829 [inline]
 __xfrm4_selector_match net/xfrm/xfrm_policy.c:201 [inline]
 xfrm_selector_match.cold+0x18/0x3a net/xfrm/xfrm_policy.c:226
 xfrm_state_look_at+0x16d/0x440 net/xfrm/xfrm_state.c:1046
 xfrm_state_find+0x168e/0x4f00 net/xfrm/xfrm_state.c:1120
 xfrm_tmpl_resolve_one net/xfrm/xfrm_policy.c:2391 [inline]
 xfrm_tmpl_resolve+0x2f3/0xd40 net/xfrm/xfrm_policy.c:2436
 xfrm_resolve_and_create_bundle+0x123/0x25a0 net/xfrm/xfrm_policy.c:2724
 xfrm_lookup_with_ifid+0x22a/0x2220 net/xfrm/xfrm_policy.c:3058
 xfrm_lookup net/xfrm/xfrm_policy.c:3187 [inline]
 xfrm_lookup_route+0x36/0x1e0 net/xfrm/xfrm_policy.c:3198
 ip_route_output_flow+0x114/0x150 net/ipv4/route.c:2857
 udp_sendmsg+0x1958/0x2740 net/ipv4/udp.c:1219
 inet_sendmsg+0x99/0xe0 net/ipv4/af_inet.c:819
 sock_sendmsg_nosec net/socket.c:704 [inline]
 sock_sendmsg+0xcf/0x120 net/socket.c:724
 ____sys_sendmsg+0x331/0x810 net/socket.c:2409
 ___sys_sendmsg+0xf3/0x170 net/socket.c:2463
 __sys_sendmmsg+0x195/0x470 net/socket.c:2549
 __do_sys_sendmmsg net/socket.c:2578 [inline]
 __se_sys_sendmmsg net/socket.c:2575 [inline]
 __x64_sys_sendmmsg+0x99/0x100 net/socket.c:2575
 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:0x7f9f4bf3dae9
Code: ff ff c3 66 2e 0f 1f 84 00 00 00 00 00 0f 1f 40 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 73 01 c3 48 c7 c1 bc ff ff ff f7 d8 64 89 01 48
RSP: 002b:00007f9f49471188 EFLAGS: 00000246 ORIG_RAX: 0000000000000133
RAX: ffffffffffffffda RBX: 00007f9f4c0510e0 RCX: 00007f9f4bf3dae9
RDX: 000000000800001d RSI: 0000000020007fc0 RDI: 0000000000000006
RBP: 00007f9f4bf97f6d R08: 0000000000000000 R09: 0000000000000000
R10: 0000000000000000 R11: 0000000000000246 R12: 0000000000000000
R13: 00007fffa9f4777f R14: 00007f9f49471300 R15: 0000000000022000
 </TASK>
================================================================================

Crashes (4):
Manager Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Title
ci-upstream-net-this-kasan-gce 2021/11/13 00:16 net 5833291ab6de 83f5c9b5 .config log report info UBSAN: shift-out-of-bounds in xfrm_selector_match
ci-upstream-net-this-kasan-gce 2021/07/18 01:09 net 5b69874f74cc f115ae98 .config log report info UBSAN: shift-out-of-bounds in xfrm_selector_match
ci-upstream-net-this-kasan-gce 2021/06/10 18:02 net 13c62f5371e3 1ba81399 .config log report info UBSAN: shift-out-of-bounds in xfrm_selector_match
ci-upstream-net-kasan-gce 2021/10/17 15:43 net-next 4e6e167bc049 0c5d9412 .config log report info UBSAN: shift-out-of-bounds in xfrm_selector_match