BUG: bad usercopy in do_syslog

8 views
Skip to first unread message

syzbot

unread,
Jan 5, 2018, 5:58:04 AM1/5/18
to syzkaller-upst...@googlegroups.com
Hello,

syzkaller hit the following crash on
37759fa6d0fa9e4d6036d19ac12f555bfc0aeafd
git://git.cmpxchg.org/linux-mmots.git/master
compiler: gcc (GCC) 7.1.1 20170620
.config is attached
Raw console output is attached.
Unfortunately, I don't have any reproducer for this bug yet.
CC: [ak...@linux-foundation.org alexande...@amd.com
ch...@chris-wilson.co.uk da...@davemloft.net gre...@linuxfoundation.org
keun-...@darkmatter.ae lab...@redhat.com linux-...@vger.kernel.org
linu...@kvack.org mch...@kernel.org mi...@kernel.org]

IMPORTANT: if you fix the bug, please add the following tag to the commit:
Reported-by: syzbot+c00a2d...@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.

------------[ cut here ]------------
kernel BUG at mm/usercopy.c:84!
invalid opcode: 0000 [#1] SMP KASAN
Dumping ftrace buffer:
(ftrace buffer empty)
Modules linked in:
CPU: 1 PID: 2995 Comm: rsyslogd Not tainted 4.15.0-rc4-mm1+ #49
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS
Google 01/01/2011
RIP: 0010:report_usercopy mm/usercopy.c:76 [inline]
RIP: 0010:__check_object_size+0x3a2/0x4f0 mm/usercopy.c:276
RSP: 0018:ffff8801cff57a80 EFLAGS: 00010286
RAX: 0000000000000063 RBX: ffffffff85929820 RCX: 0000000000000000
RDX: 0000000000000063 RSI: 1ffff10039feaf10 RDI: ffffed0039feaf44
RBP: ffff8801cff57b70 R08: 1ffff10039feaed2 R09: 0000000000000000
R10: 0000000000000000 R11: 0000000000000000 R12: ffffffff859297e0
R13: ffff8801dae14090 R14: 00000000000003f0 R15: ffffea00076b8500
FS: 00007f722df8f700(0000) GS:ffff8801db300000(0000) knlGS:0000000000000000
CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: 00000000024d3cd8 CR3: 00000001d0f97004 CR4: 00000000001626e0
DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000
DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400
Call Trace:
check_object_size include/linux/thread_info.h:112 [inline]
check_copy_size include/linux/thread_info.h:143 [inline]
copy_to_user include/linux/uaccess.h:154 [inline]
syslog_print kernel/printk/printk.c:1332 [inline]
do_syslog+0x867/0xb80 kernel/printk/printk.c:1455
kmsg_read+0x74/0xa0 fs/proc/kmsg.c:40
proc_reg_read+0xe8/0x160 fs/proc/inode.c:217
__vfs_read+0xef/0xa00 fs/read_write.c:411
vfs_read+0x11e/0x350 fs/read_write.c:447
SYSC_read fs/read_write.c:573 [inline]
SyS_read+0xef/0x220 fs/read_write.c:566
entry_SYSCALL_64_fastpath+0x1f/0x96
RIP: 0033:0x7f72309ef1fd
RSP: 002b:00007f722df8ee30 EFLAGS: 00000293 ORIG_RAX: 0000000000000000
RAX: ffffffffffffffda RBX: 0000000000000008 RCX: 00007f72309ef1fd
RDX: 0000000000000fff RSI: 00007f722f7c35a0 RDI: 0000000000000004
RBP: 0000000000000030 R08: 000000000220d260 R09: 0000000000000000
R10: 20303034313d6570 R11: 0000000000000293 R12: 00000000000001c8
R13: 0000000000000008 R14: 00007f722f7c35a4 R15: 00007f722f7c45a4
Code: 48 0f 44 da e8 80 76 c1 ff 48 8b 85 28 ff ff ff 4d 89 f1 4c 89 e9 4c
89 e2 48 89 de 48 c7 c7 60 98 92 85 49 89 c0 e8 86 2f ab ff <0f> 0b 48 c7
c0 20 96 92 85 eb 96 48 c7 c0 60 96 92 85 eb 8d 48
RIP: report_usercopy mm/usercopy.c:76 [inline] RSP: ffff8801cff57a80
RIP: __check_object_size+0x3a2/0x4f0 mm/usercopy.c:276 RSP: ffff8801cff57a80
---[ end trace 0c9a71f99d737cbb ]---
Kernel panic - not syncing: Fatal exception
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 syzk...@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
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.
To upstream this report, please reply with:
#syz upstream
config.txt
raw.log

Dmitry Vyukov

unread,
Jan 5, 2018, 4:51:20 PM1/5/18
to syzbot, 'Dmitry Vyukov' via syzkaller-upstream-moderation
#syz fix: crypto: pcrypt - fix freeing pcrypt instances
> --
> You received this message because you are subscribed to the Google Groups
> "syzkaller-upstream-moderation" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to syzkaller-upstream-m...@googlegroups.com.
> To post to this group, send email to
> syzkaller-upst...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/syzkaller-upstream-moderation/001a11351f4490ef0205620552ee%40google.com.
> For more options, visit https://groups.google.com/d/optout.
Reply all
Reply to author
Forward
0 new messages