Thread (3 messages) flat view 3 messages, 2 authors, 2020-07-27

WARNING in xfrm_policy_insert

From: syzbot <hidden>
Date: 2018-02-14 08:09:06
Also in: lkml

Hello,

syzbot hit the following crash on net-next commit
6c677750f22db3bb466a95f08b91a1cca8323146 (Tue Feb 13 10:29:05 2018 +0000)
mlxsw: spectrum: Use NL_SET_ERR_MSG_MOD

So far this crash happened 3 times on net-next, upstream.
C reproducer is attached.
syzkaller reproducer is attached.
Raw console output is attached.
compiler: gcc (GCC) 7.1.1 20170620
.config is attached.

IMPORTANT: if you fix the bug, please add the following tag to the commit:
Reported-by: syzbot+5cfc132a76d844973259@syzkaller.appspotmail.com
It will help syzbot understand when the bug is fixed. See footer for  
details.
If you forward the report, please keep this part and the footer.

WARNING: CPU: 0 PID: 9447 at net/xfrm/xfrm_policy.c:753  
xfrm_policy_insert+0x883/0x1140 net/xfrm/xfrm_policy.c:753
Kernel panic - not syncing: panic_on_warn set ...

CPU: 0 PID: 9447 Comm: syzkaller232283 Not tainted 4.16.0-rc1+ #225
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS  
Google 01/01/2011
Call Trace:
  __dump_stack lib/dump_stack.c:17 [inline]
  dump_stack+0x194/0x257 lib/dump_stack.c:53
  panic+0x1e4/0x41c kernel/panic.c:183
  __warn+0x1dc/0x200 kernel/panic.c:547
  report_bug+0x211/0x2d0 lib/bug.c:184
  fixup_bug.part.11+0x37/0x80 arch/x86/kernel/traps.c:178
  fixup_bug arch/x86/kernel/traps.c:247 [inline]
  do_error_trap+0x2d7/0x3e0 arch/x86/kernel/traps.c:296
  do_invalid_op+0x1b/0x20 arch/x86/kernel/traps.c:315
  invalid_op+0x22/0x40 arch/x86/entry/entry_64.S:988
RIP: 0010:xfrm_policy_insert+0x883/0x1140 net/xfrm/xfrm_policy.c:753
RSP: 0018:ffff8801cee97250 EFLAGS: 00010293
RAX: ffff8801c6b7a380 RBX: ffff8801c6a6d240 RCX: ffffffff84bc7033
RDX: 0000000000000000 RSI: 0000000000000000 RDI: ffff8801c6a6d460
RBP: ffff8801cee973e0 R08: 0000000000000000 R09: 0000000000000004
R10: ffff8801cee97108 R11: 0000000000000004 R12: dffffc0000000000
R13: 0000000000000000 R14: 000000000000007f R15: 0000000000000000
  xfrm_add_policy+0x3dc/0x8a0 net/xfrm/xfrm_user.c:1605
  xfrm_user_rcv_msg+0x41c/0x860 net/xfrm/xfrm_user.c:2595
  netlink_rcv_skb+0x14b/0x380 net/netlink/af_netlink.c:2442
  xfrm_netlink_rcv+0x6f/0x90 net/xfrm/xfrm_user.c:2603
  netlink_unicast_kernel net/netlink/af_netlink.c:1308 [inline]
  netlink_unicast+0x4c4/0x6b0 net/netlink/af_netlink.c:1334
  netlink_sendmsg+0xa4a/0xe60 net/netlink/af_netlink.c:1897
  sock_sendmsg_nosec net/socket.c:630 [inline]
  sock_sendmsg+0xca/0x110 net/socket.c:640
  ___sys_sendmsg+0x767/0x8b0 net/socket.c:2047
  __sys_sendmsg+0xe5/0x210 net/socket.c:2081
  SYSC_sendmsg net/socket.c:2092 [inline]
  SyS_sendmsg+0x2d/0x50 net/socket.c:2088
  do_syscall_64+0x282/0x940 arch/x86/entry/common.c:287
  entry_SYSCALL_64_after_hwframe+0x26/0x9b
RIP: 0033:0x446cf9
RSP: 002b:00007fb756bb7db8 EFLAGS: 00000293 ORIG_RAX: 000000000000002e
RAX: ffffffffffffffda RBX: 00000000006e168c RCX: 0000000000446cf9
RDX: 0000000000000000 RSI: 000000002014dfc8 RDI: 0000000000000009
RBP: 00000000006e1688 R08: 00007fb756bb8700 R09: 0000000000000000
R10: 00007fb756bb8700 R11: 0000000000000293 R12: 0000000000000000
R13: 00007ffe45c5ddaf R14: 00007fb756bb89c0 R15: 0000000000000008
Dumping ftrace buffer:
    (ftrace buffer empty)
Kernel Offset: disabled
Rebooting in 86400 seconds..


---
This bug is generated by a dumb bot. It may contain errors.
See https://goo.gl/tpsmEJ for details.
Direct all questions to syzkaller@googlegroups.com.

syzbot will keep track of this bug report.
If you forgot to add the Reported-by tag, once the fix for this bug is  
merged
into any tree, please reply to this email with:
#syz fix: exact-commit-title
If you want to test a patch for this bug, please reply with:
#syz test: git://repo/address.git branch
and provide the patch inline or as an attachment.
To mark this as a duplicate of another syzbot report, please reply with:
#syz dup: exact-subject-of-another-report
If it's a one-off invalid bug report, please reply with:
#syz invalid
Note: if the crash happens again, it will cause creation of a new bug  
report.
Note: all commands must start from beginning of the line in the email body.

Attachments

Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help