WARNING: ODEBUG bug in rfcomm_dlc_free

10 views
Skip to first unread message

syzbot

unread,
Jul 27, 2019, 1:51:06 PM7/27/19
to syzkaller...@googlegroups.com
Hello,

syzbot found the following crash on:

HEAD commit: ff33472c Linux 4.14.134
git tree: linux-4.14.y
console output: https://syzkaller.appspot.com/x/log.txt?x=13e5cda2600000
kernel config: https://syzkaller.appspot.com/x/.config?x=7918dc8aa910a9fb
dashboard link: https://syzkaller.appspot.com/bug?extid=1be52530c1802cd1b2cb
compiler: gcc (GCC) 9.0.0 20181231 (experimental)
syz repro: https://syzkaller.appspot.com/x/repro.syz?x=1047035c600000
C reproducer: https://syzkaller.appspot.com/x/repro.c?x=159ee4b4600000

IMPORTANT: if you fix the bug, please add the following tag to the commit:
Reported-by: syzbot+1be525...@syzkaller.appspotmail.com

audit: type=1400 audit(1564246025.415:36): avc: denied { map } for
pid=7086 comm="syz-executor353" path="/root/syz-executor353119208"
dev="sda1" ino=16483 scontext=unconfined_u:system_r:insmod_t:s0-s0:c0.c1023
tcontext=unconfined_u:object_r:user_home_t:s0 tclass=file permissive=1
ODEBUG: free active (active state 0) object type: timer_list hint:
rfcomm_dlc_timeout+0x0/0x60 include/linux/list.h:64
------------[ cut here ]------------
WARNING: CPU: 0 PID: 7089 at lib/debugobjects.c:287
debug_print_object.cold+0xa7/0xdb lib/debugobjects.c:287
Kernel panic - not syncing: panic_on_warn set ...

CPU: 0 PID: 7089 Comm: syz-executor353 Not tainted 4.14.134 #30
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+0x138/0x19c lib/dump_stack.c:53
panic+0x1f2/0x426 kernel/panic.c:182
__warn.cold+0x2f/0x36 kernel/panic.c:546
report_bug+0x216/0x254 lib/bug.c:186
fixup_bug arch/x86/kernel/traps.c:177 [inline]
fixup_bug arch/x86/kernel/traps.c:172 [inline]
do_error_trap+0x1bb/0x310 arch/x86/kernel/traps.c:295
do_invalid_op+0x1b/0x20 arch/x86/kernel/traps.c:314
invalid_op+0x1b/0x40 arch/x86/entry/entry_64.S:960
RIP: 0010:debug_print_object.cold+0xa7/0xdb lib/debugobjects.c:287
RSP: 0018:ffff88809fbd7aa8 EFLAGS: 00010086
RAX: 000000000000005e RBX: 0000000000000003 RCX: 0000000000000000
RDX: 0000000000000000 RSI: ffffffff866d0e00 RDI: ffffed1013f7af4b
RBP: ffff88809fbd7ad0 R08: 000000000000005e R09: 0000000000000000
R10: 0000000000000000 R11: ffff8880837500c0 R12: ffffffff866cc000
R13: ffffffff8581ffe0 R14: 0000000000000000 R15: ffff88808d1da828
__debug_check_no_obj_freed lib/debugobjects.c:747 [inline]
debug_check_no_obj_freed+0x3f5/0x7b7 lib/debugobjects.c:776
kfree+0xbd/0x270 mm/slab.c:3814
rfcomm_dlc_free+0x20/0x30 net/bluetooth/rfcomm/core.c:328
rfcomm_dlc_put include/net/bluetooth/rfcomm.h:258 [inline]
__rfcomm_create_dev net/bluetooth/rfcomm/tty.c:417 [inline]
rfcomm_create_dev net/bluetooth/rfcomm/tty.c:486 [inline]
rfcomm_dev_ioctl+0x1590/0x18b0 net/bluetooth/rfcomm/tty.c:588
rfcomm_sock_ioctl+0x82/0xa0 net/bluetooth/rfcomm/sock.c:902
sock_do_ioctl+0x64/0xb0 net/socket.c:974
sock_ioctl+0x2a6/0x470 net/socket.c:1071
vfs_ioctl fs/ioctl.c:46 [inline]
file_ioctl fs/ioctl.c:500 [inline]
do_vfs_ioctl+0x7ae/0x1060 fs/ioctl.c:684
SYSC_ioctl fs/ioctl.c:701 [inline]
SyS_ioctl+0x8f/0xc0 fs/ioctl.c:692
do_syscall_64+0x1e8/0x640 arch/x86/entry/common.c:292
entry_SYSCALL_64_after_hwframe+0x42/0xb7
RIP: 0033:0x441229
RSP: 002b:00007ffebb453368 EFLAGS: 00000246 ORIG_RAX: 0000000000000010
RAX: ffffffffffffffda RBX: 0000000000000000 RCX: 0000000000441229
RDX: 0000000020000100 RSI: 00000000400452c8 RDI: 0000000000000004
RBP: 000000000000d0d1 R08: 00000000004002c8 R09: 00000000004002c8
R10: 00000000004002c8 R11: 0000000000000246 R12: 0000000000402050
R13: 00000000004020e0 R14: 0000000000000000 R15: 0000000000000000

======================================================


---
This bug is generated by a bot. It may contain errors.
See https://goo.gl/tpsmEJ for more information about syzbot.
syzbot engineers can be reached at syzk...@googlegroups.com.

syzbot will keep track of this bug report. See:
https://goo.gl/tpsmEJ#status for how to communicate with syzbot.
syzbot can test patches for this bug, for details see:
https://goo.gl/tpsmEJ#testing-patches

syzbot

unread,
Jul 27, 2019, 7:05:07 PM7/27/19
to syzkaller...@googlegroups.com
Hello,

syzbot found the following crash on:

HEAD commit: 7250956f Linux 4.19.61
git tree: linux-4.19.y
console output: https://syzkaller.appspot.com/x/log.txt?x=106ad564600000
kernel config: https://syzkaller.appspot.com/x/.config?x=13e37a4c57ecad7f
dashboard link: https://syzkaller.appspot.com/bug?extid=2b7e5402aa6271cb1b9d
compiler: gcc (GCC) 9.0.0 20181231 (experimental)
syz repro: https://syzkaller.appspot.com/x/repro.syz?x=1622aff4600000
C reproducer: https://syzkaller.appspot.com/x/repro.c?x=141e5e92600000

IMPORTANT: if you fix the bug, please add the following tag to the commit:
Reported-by: syzbot+2b7e54...@syzkaller.appspotmail.com

audit: type=1400 audit(1564264884.705:36): avc: denied { map } for
pid=7926 comm="syz-executor851" path="/root/syz-executor851514735"
dev="sda1" ino=16483 scontext=unconfined_u:system_r:insmod_t:s0-s0:c0.c1023
tcontext=unconfined_u:object_r:user_home_t:s0 tclass=file permissive=1
------------[ cut here ]------------
ODEBUG: free active (active state 0) object type: timer_list hint:
rfcomm_dlc_timeout+0x0/0x80 include/linux/list.h:64
WARNING: CPU: 1 PID: 7929 at lib/debugobjects.c:325
debug_print_object+0x168/0x250 lib/debugobjects.c:325
Kernel panic - not syncing: panic_on_warn set ...

CPU: 1 PID: 7929 Comm: syz-executor851 Not tainted 4.19.61 #35
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS
Google 01/01/2011
Call Trace:
__dump_stack lib/dump_stack.c:77 [inline]
dump_stack+0x172/0x1f0 lib/dump_stack.c:113
panic+0x263/0x507 kernel/panic.c:185
__warn.cold+0x20/0x4a kernel/panic.c:540
report_bug+0x263/0x2b0 lib/bug.c:186
fixup_bug arch/x86/kernel/traps.c:178 [inline]
fixup_bug arch/x86/kernel/traps.c:173 [inline]
do_error_trap+0x204/0x360 arch/x86/kernel/traps.c:296
do_invalid_op+0x1b/0x20 arch/x86/kernel/traps.c:316
invalid_op+0x14/0x20 arch/x86/entry/entry_64.S:1035
RIP: 0010:debug_print_object+0x168/0x250 lib/debugobjects.c:325
Code: dd e0 4d 82 87 48 89 fa 48 c1 ea 03 80 3c 02 00 0f 85 b5 00 00 00 48
8b 14 dd e0 4d 82 87 48 c7 c7 20 43 82 87 e8 c6 37 19 fe <0f> 0b 83 05 db
c9 17 06 01 48 83 c4 20 5b 41 5c 41 5d 41 5e 5d c3
RSP: 0018:ffff8880960878d8 EFLAGS: 00010086
RAX: 0000000000000000 RBX: 0000000000000003 RCX: 0000000000000000
RDX: 0000000000000000 RSI: ffffffff8155d376 RDI: ffffed1012c10f0d
RBP: ffff888096087918 R08: ffff8880951c4180 R09: ffffed1015d23ee3
R10: ffffed1015d23ee2 R11: ffff8880ae91f717 R12: 0000000000000001
R13: ffffffff887ac380 R14: ffffffff815b48d0 R15: ffff88808adcdd28
__debug_check_no_obj_freed lib/debugobjects.c:785 [inline]
debug_check_no_obj_freed+0x29f/0x464 lib/debugobjects.c:817
kfree+0xbd/0x220 mm/slab.c:3821
rfcomm_dlc_free+0x20/0x30 net/bluetooth/rfcomm/core.c:328
rfcomm_dlc_put include/net/bluetooth/rfcomm.h:258 [inline]
__rfcomm_create_dev net/bluetooth/rfcomm/tty.c:417 [inline]
rfcomm_create_dev net/bluetooth/rfcomm/tty.c:486 [inline]
rfcomm_dev_ioctl+0x181f/0x1b60 net/bluetooth/rfcomm/tty.c:588
rfcomm_sock_ioctl+0x90/0xb0 net/bluetooth/rfcomm/sock.c:902
sock_do_ioctl+0xd8/0x2f0 net/socket.c:950
sock_ioctl+0x325/0x610 net/socket.c:1074
vfs_ioctl fs/ioctl.c:46 [inline]
file_ioctl fs/ioctl.c:501 [inline]
do_vfs_ioctl+0xd5f/0x1380 fs/ioctl.c:688
ksys_ioctl+0xab/0xd0 fs/ioctl.c:705
__do_sys_ioctl fs/ioctl.c:712 [inline]
__se_sys_ioctl fs/ioctl.c:710 [inline]
__x64_sys_ioctl+0x73/0xb0 fs/ioctl.c:710
do_syscall_64+0xfd/0x620 arch/x86/entry/common.c:293
entry_SYSCALL_64_after_hwframe+0x49/0xbe
RIP: 0033:0x441229
Code: e8 fc ab 02 00 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 9b 09 fc ff c3 66 2e 0f 1f 84 00 00 00 00
RSP: 002b:00007ffc048c29c8 EFLAGS: 00000246 ORIG_RAX: 0000000000000010
RAX: ffffffffffffffda RBX: 0000000000000000 RCX: 0000000000441229
RDX: 0000000020000100 RSI: 00000000400452c8 RDI: 0000000000000004
RBP: 000000000000e3af R08: 00000000004002c8 R09: 00000000004002c8

syzbot

unread,
Apr 14, 2020, 7:03:03 AM4/14/20
to syzkaller...@googlegroups.com
syzbot suspects this bug was fixed by commit:

commit 78a4ad28608a530b5bd85da60307d61133e68040
Author: Qiujun Huang <hqja...@gmail.com>
Date: Sun Mar 8 09:45:27 2020 +0000

Bluetooth: RFCOMM: fix ODEBUG bug in rfcomm_dev_ioctl

bisection log: https://syzkaller.appspot.com/x/bisect.txt?x=12b8dc20100000
start commit: 35766839 Linux 4.19.103
git tree: linux-4.19.y
kernel config: https://syzkaller.appspot.com/x/.config?x=84f14e7b6cbc7d27
dashboard link: https://syzkaller.appspot.com/bug?extid=2b7e5402aa6271cb1b9d
syz repro: https://syzkaller.appspot.com/x/repro.syz?x=10ec107ee00000
C reproducer: https://syzkaller.appspot.com/x/repro.c?x=13d196b5e00000

If the result looks correct, please mark the bug fixed by replying with:

#syz fix: Bluetooth: RFCOMM: fix ODEBUG bug in rfcomm_dev_ioctl

For information about bisection process see: https://goo.gl/tpsmEJ#bisection

syzbot

unread,
Apr 15, 2020, 8:35:03 AM4/15/20
to syzkaller...@googlegroups.com
syzbot suspects this bug was fixed by commit:

commit 0da9c032adbb6f83cc7f548c5155d26c64f44d63
Author: Qiujun Huang <hqja...@gmail.com>
Date: Sun Mar 8 09:45:27 2020 +0000

Bluetooth: RFCOMM: fix ODEBUG bug in rfcomm_dev_ioctl

bisection log: https://syzkaller.appspot.com/x/bisect.txt?x=133a4a00100000
start commit: 98db2bf2 Linux 4.14.171
git tree: linux-4.14.y
kernel config: https://syzkaller.appspot.com/x/.config?x=9dc3f6f9d0ff3b98
dashboard link: https://syzkaller.appspot.com/bug?extid=1be52530c1802cd1b2cb
syz repro: https://syzkaller.appspot.com/x/repro.syz?x=174d8e5ee00000
C reproducer: https://syzkaller.appspot.com/x/repro.c?x=151c1b11e00000
Reply all
Reply to author
Forward
0 new messages