kernel BUG at security/keys/keyring.c:LINE!

8 views
Skip to first unread message

syzbot

unread,
Apr 10, 2019, 12:04:10 PM4/10/19
to syzkaller-a...@googlegroups.com
Hello,

syzbot found the following crash on:

HEAD commit: d33692e8 Merge 4.14.74 into android-4.14
git tree: android-4.14
console output: https://syzkaller.appspot.com/x/log.txt?x=167a2c91400000
kernel config: https://syzkaller.appspot.com/x/.config?x=decf36ad71cd0a75
dashboard link: https://syzkaller.appspot.com/bug?extid=5f472c8c84752c7e1c37
compiler: gcc (GCC) 8.0.1 20180413 (experimental)
syz repro: https://syzkaller.appspot.com/x/repro.syz?x=13869ae6400000
C reproducer: https://syzkaller.appspot.com/x/repro.c?x=1505126e400000

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

random: sshd: uninitialized urandom read (32 bytes read)
urandom_read: 1 callbacks suppressed
random: sshd: uninitialized urandom read (32 bytes read)
audit: type=1400 audit(1538731504.673:7): avc: denied { map } for
pid=1780 comm="syz-executor384" path="/root/syz-executor384052972"
dev="sda1" ino=16481 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 ]------------
kernel BUG at security/keys/keyring.c:1221!
invalid opcode: 0000 [#1] PREEMPT SMP KASAN NOPTI
Modules linked in:
CPU: 0 PID: 1780 Comm: syz-executor384 Not tainted 4.14.74+ #17
task: ffff8801cf415e00 task.stack: ffff8801cba88000
RIP: 0010:__key_link_begin+0x1f5/0x2b0 security/keys/keyring.c:1221
RSP: 0018:ffff8801cba8fc18 EFLAGS: 00010297
RAX: ffff8801cf415e00 RBX: ffff8801cc1c6000 RCX: 1ffff10039751f75
RDX: 0000000000000000 RSI: ffff8801cba8fd68 RDI: ffff8801cba8fd78
RBP: ffff8801cba8fd68 R08: 0000000000000001 R09: 0000000000000000
R10: 0000000000000000 R11: 0000000000000001 R12: 1ffff10039751f91
R13: ffff8801cba8fd68 R14: ffff8801cc3e58a0 R15: ffff8801cba8fce8
FS: 0000000000c1f880(0000) GS:ffff8801d7600000(0000) knlGS:0000000000000000
CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: 0000000020caaffb CR3: 00000001cf3dc002 CR4: 00000000001606b0
Call Trace:
construct_alloc_key security/keys/request_key.c:389 [inline]
construct_key_and_link security/keys/request_key.c:480 [inline]
request_key_and_link+0x50f/0xa20 security/keys/request_key.c:595
SYSC_request_key security/keys/keyctl.c:213 [inline]
SyS_request_key+0x20e/0x2c0 security/keys/keyctl.c:158
do_syscall_64+0x19b/0x4b0 arch/x86/entry/common.c:289
entry_SYSCALL_64_after_hwframe+0x42/0xb7
RIP: 0033:0x440169
RSP: 002b:00007ffdf9ce7e88 EFLAGS: 00000217 ORIG_RAX: 00000000000000f9
RAX: ffffffffffffffda RBX: 00000000004002c8 RCX: 0000000000440169
RDX: 00000000200001c0 RSI: 0000000020000180 RDI: 00000000200000c0
RBP: 00000000006ca018 R08: 00000000004002c8 R09: 00000000004002c8
R10: 00000000157535cf R11: 0000000000000217 R12: 00000000004019f0
R13: 0000000000401a80 R14: 0000000000000000 R15: 0000000000000000
Code: 94 ff 48 c7 c7 00 8e dd 8f e8 08 3f 83 ff eb ac e8 31 ef 94 ff 48 c7
c7 00 8e dd 8f e8 75 34 e9 00 e9 00 ff ff ff e8 1b ef 94 ff <0f> 0b e8 14
ef 94 ff 48 8d bb ce 00 00 00 48 b8 00 00 00 00 00
RIP: __key_link_begin+0x1f5/0x2b0 security/keys/keyring.c:1221 RSP:
ffff8801cba8fc18
---[ end trace aef62e2ed8133767 ]---


---
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,
Apr 14, 2019, 4:51:24 AM4/14/19
to syzkaller-a...@googlegroups.com
Hello,

syzbot found the following crash on:

HEAD commit: 7bebf33f Merge 4.9.131 into android-4.9
git tree: android-4.9
console output: https://syzkaller.appspot.com/x/log.txt?x=163db67e400000
kernel config: https://syzkaller.appspot.com/x/.config?x=79019780e5795c29
dashboard link: https://syzkaller.appspot.com/bug?extid=4abf3203c56cdefc5376
compiler: gcc (GCC) 8.0.1 20180413 (experimental)
syz repro: https://syzkaller.appspot.com/x/repro.syz?x=1379f2e6400000
C reproducer: https://syzkaller.appspot.com/x/repro.c?x=11fad285400000

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

random: crng init done
------------[ cut here ]------------
kernel BUG at security/keys/keyring.c:1107!
invalid opcode: 0000 [#1] PREEMPT SMP KASAN
Modules linked in:
CPU: 0 PID: 2039 Comm: syz-executor631 Not tainted 4.9.131+ #50
task: ffff8801d18e5f00 task.stack: ffff8801cf1e0000
RIP: 0010:[<ffffffff819c0d4c>] [<ffffffff819c0d4c>]
__key_link_begin+0x20c/0x2d0 security/keys/keyring.c:1107
RSP: 0018:ffff8801cf1e7be0 EFLAGS: 00010293
RAX: ffff8801d18e5f00 RBX: ffff8801d533e300 RCX: 1ffff10039e3cf71
RDX: 0000000000000000 RSI: ffffffff819c0d4c RDI: ffff8801cf1e7d68
RBP: ffff8801cf1e7c10 R08: ffffffff83c9ec20 R09: 0000000000000001
R10: 0000000000000000 R11: 0000000000000001 R12: ffff8801cf1e7d58
R13: ffffffff831c0c20 R14: ffff8801cf1e7d58 R15: ffff8801d533e300
FS: 0000000000a4c880(0000) GS:ffff8801db600000(0000) knlGS:0000000000000000
CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: 0000000020caaffb CR3: 00000001d1308000 CR4: 00000000001606b0
Stack:
ffff8801cf1e7cd8 ffff8801cf1e7df8 ffff8801d533e480 ffffffff831c0c20
ffff8801cf1e7d58 ffff8801d533e300 ffff8801cf1e7e20 ffffffff819ca295
0000000000000000 0000000000000000 ffff8801d18e67a8 ffff8801cf1e7cd8
Call Trace:
[<ffffffff819ca295>] construct_alloc_key security/keys/request_key.c:388
[inline]
[<ffffffff819ca295>] construct_key_and_link
security/keys/request_key.c:479 [inline]
[<ffffffff819ca295>] request_key_and_link+0x535/0xac0
security/keys/request_key.c:594
[<ffffffff819c1db3>] SYSC_request_key security/keys/keyctl.c:213 [inline]
[<ffffffff819c1db3>] SyS_request_key+0x233/0x2f0 security/keys/keyctl.c:158
[<ffffffff810056ef>] do_syscall_64+0x19f/0x550 arch/x86/entry/common.c:285
[<ffffffff828037d3>] entry_SYSCALL_64_after_swapgs+0x5d/0xdb
Code: 95 ff 48 c7 c7 00 f6 1b 83 e8 41 c2 83 ff eb ac e8 2a a8 95 ff 48 c7
c7 00 f6 1b 83 e8 be c8 e3 00 e9 f3 fe ff ff e8 14 a8 95 ff <0f> 0b e8 0d
a8 95 ff 48 8d bb ce 00 00 00 48 b8 00 00 00 00 00
RIP [<ffffffff819c0d4c>] __key_link_begin+0x20c/0x2d0
security/keys/keyring.c:1107
RSP <ffff8801cf1e7be0>
---[ end trace 5a915618df1445dd ]---
Reply all
Reply to author
Forward
0 new messages