general protection fault in open_xa_dir

13 views
Skip to first unread message

syzbot

unread,
Sep 21, 2020, 9:41:16 PM9/21/20
to syzkaller...@googlegroups.com
Hello,

syzbot found the following issue on:

HEAD commit: cbfa1702 Linux 4.14.198
git tree: linux-4.14.y
console output: https://syzkaller.appspot.com/x/log.txt?x=124269ab900000
kernel config: https://syzkaller.appspot.com/x/.config?x=3990958d85b55e59
dashboard link: https://syzkaller.appspot.com/bug?extid=c8034d963b9b582ac547
compiler: gcc (GCC) 10.1.0-syz 20200507
syz repro: https://syzkaller.appspot.com/x/repro.syz?x=1355d69b900000
C reproducer: https://syzkaller.appspot.com/x/repro.c?x=1540f809900000

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

REISERFS (device loop0): journal params: device loop0, size 8192, journal first block 18, max trans len 1024, max batch 900, max commit age 30, max trans age 30
REISERFS (device loop0): checking transaction log (loop0)
REISERFS (device loop0): Using tea hash to sort names
kasan: CONFIG_KASAN_INLINE enabled
kasan: GPF could be caused by NULL-ptr deref or user memory access
general protection fault: 0000 [#1] PREEMPT SMP KASAN
Modules linked in:
CPU: 1 PID: 6362 Comm: syz-executor923 Not tainted 4.14.198-syzkaller #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011
task: ffff888084600440 task.stack: ffff888092890000
RIP: 0010:d_really_is_negative include/linux/dcache.h:470 [inline]
RIP: 0010:open_xa_root fs/reiserfs/xattr.c:124 [inline]
RIP: 0010:open_xa_dir+0xdf/0x600 fs/reiserfs/xattr.c:152
RSP: 0018:ffff8880928977f8 EFLAGS: 00010202
RAX: ffff88809754ac80 RBX: ffff88807c811748 RCX: 000000000000000b
RDX: dffffc0000000000 RSI: 0000000000000002 RDI: ffff8880862baf48
RBP: ffff8880862bad80 R08: ffff88809754b300 R09: 0000000000000002
R10: 0000000000000000 R11: ffff888084600440 R12: 1ffff11012512f01
R13: 0000000000000000 R14: 0000000000000002 R15: 0000000000000058
FS: 0000000002144880(0000) GS:ffff8880aeb00000(0000) knlGS:0000000000000000
CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: 0000557769261970 CR3: 000000009fdea000 CR4: 00000000001406e0
DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000
DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400
Call Trace:
xattr_lookup+0x1f/0x350 fs/reiserfs/xattr.c:395
reiserfs_xattr_get+0x8b/0x840 fs/reiserfs/xattr.c:668
reiserfs_get_acl+0x48/0x520 fs/reiserfs/xattr_acl.c:209
get_acl fs/posix_acl.c:140 [inline]
get_acl+0x11f/0x210 fs/posix_acl.c:95
check_acl fs/namei.c:277 [inline]
acl_permission_check fs/namei.c:301 [inline]
generic_permission+0x31e/0x3c0 fs/namei.c:339
reiserfs_permission+0x53/0x70 fs/reiserfs/xattr.c:944
do_inode_permission fs/namei.c:384 [inline]
__inode_permission+0x1f1/0x2f0 fs/namei.c:426
inode_permission fs/namei.c:476 [inline]
lookup_one_len+0x25d/0x3a0 fs/namei.c:2535
reiserfs_lookup_privroot+0x92/0x270 fs/reiserfs/xattr.c:963
reiserfs_fill_super+0x1ad8/0x28b6 fs/reiserfs/super.c:2179
mount_bdev+0x2b3/0x360 fs/super.c:1134
mount_fs+0x92/0x2a0 fs/super.c:1237
vfs_kern_mount.part.0+0x5b/0x470 fs/namespace.c:1046
vfs_kern_mount fs/namespace.c:1036 [inline]
do_new_mount fs/namespace.c:2549 [inline]
do_mount+0xe53/0x2a00 fs/namespace.c:2879
SYSC_mount fs/namespace.c:3095 [inline]
SyS_mount+0xa8/0x120 fs/namespace.c:3072
do_syscall_64+0x1d5/0x640 arch/x86/entry/common.c:292
entry_SYSCALL_64_after_hwframe+0x46/0xbb
RIP: 0033:0x446f6a
RSP: 002b:00007ffd51f04728 EFLAGS: 00000297 ORIG_RAX: 00000000000000a5
RAX: ffffffffffffffda RBX: 00007ffd51f04780 RCX: 0000000000446f6a
RDX: 0000000020000000 RSI: 0000000020000100 RDI: 00007ffd51f04740
RBP: 00007ffd51f04740 R08: 00007ffd51f04780 R09: 00007ffd00000015
R10: 0000000000010000 R11: 0000000000000297 R12: 0000000000000007
R13: 0000000000000004 R14: 0000000000000003 R15: 0000000000000003
Code: f9 48 c1 e9 03 80 3c 11 00 0f 85 67 04 00 00 4c 8b ad c8 01 00 00 48 ba 00 00 00 00 00 fc ff df 4d 8d 7d 58 4c 89 f9 48 c1 e9 03 <80> 3c 11 00 0f 85 18 04 00 00 49 8b 6d 58 4c 89 44 24 08 48 89
RIP: d_really_is_negative include/linux/dcache.h:470 [inline] RSP: ffff8880928977f8
RIP: open_xa_root fs/reiserfs/xattr.c:124 [inline] RSP: ffff8880928977f8
RIP: open_xa_dir+0xdf/0x600 fs/reiserfs/xattr.c:152 RSP: ffff8880928977f8
---[ end trace 3b87c4858f8bb4bd ]---


---
This report 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 issue. See:
https://goo.gl/tpsmEJ#status for how to communicate with syzbot.
syzbot can test patches for this issue, for details see:
https://goo.gl/tpsmEJ#testing-patches

syzbot

unread,
Sep 30, 2020, 1:05:16 AM9/30/20
to syzkaller...@googlegroups.com
Hello,

syzbot found the following issue on:

HEAD commit: 10ad6cfd Linux 4.19.148
git tree: linux-4.19.y
console output: https://syzkaller.appspot.com/x/log.txt?x=11b92975900000
kernel config: https://syzkaller.appspot.com/x/.config?x=f12430879510f963
dashboard link: https://syzkaller.appspot.com/bug?extid=266c024c60219d7e5474
compiler: gcc (GCC) 10.1.0-syz 20200507
syz repro: https://syzkaller.appspot.com/x/repro.syz?x=17fe4923900000
C reproducer: https://syzkaller.appspot.com/x/repro.c?x=1118e46d900000

IMPORTANT: if you fix the issue, please add the following tag to the commit:
Reported-by: syzbot+266c02...@syzkaller.appspotmail.com

REISERFS (device loop0): journal params: device loop0, size 8192, journal first block 18, max trans len 1024, max batch 900, max commit age 30, max trans age 30
REISERFS (device loop0): checking transaction log (loop0)
REISERFS (device loop0): Using tea hash to sort names
kasan: CONFIG_KASAN_INLINE enabled
kasan: GPF could be caused by NULL-ptr deref or user memory access
general protection fault: 0000 [#1] PREEMPT SMP KASAN
CPU: 1 PID: 6492 Comm: syz-executor490 Not tainted 4.19.148-syzkaller #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011
RIP: 0010:d_really_is_negative include/linux/dcache.h:466 [inline]
RIP: 0010:open_xa_root fs/reiserfs/xattr.c:124 [inline]
RIP: 0010:open_xa_dir+0xf6/0x690 fs/reiserfs/xattr.c:152
Code: 48 c1 ea 03 80 3c 02 00 0f 85 d2 04 00 00 4c 8b ad 70 05 00 00 48 b8 00 00 00 00 00 fc ff df 4d 8d 75 58 4c 89 f2 48 c1 ea 03 <80> 3c 02 00 0f 85 be 04 00 00 49 8b 6d 58 4c 89 04 24 48 85 ed 0f
RSP: 0018:ffff8880852a76d0 EFLAGS: 00010202
RAX: dffffc0000000000 RBX: ffff88807fd8c740 RCX: ffffffff81edae4e
RDX: 000000000000000b RSI: ffffffff81ed86c6 RDI: ffff8880a386c570
RBP: ffff8880a386c000 R08: ffff88808499abc0 R09: 0000000000000000
R10: 0000000000000005 R11: 0000000000000002 R12: 1ffff11010a54edc
R13: 0000000000000000 R14: 0000000000000058 R15: ffff88808499a540
FS: 000000000220f880(0000) GS:ffff8880ae300000(0000) knlGS:0000000000000000
CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: 000055f3b067e970 CR3: 000000009f98a000 CR4: 00000000001406e0
DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000
DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400
Call Trace:
xattr_lookup+0x21/0x3e0 fs/reiserfs/xattr.c:395
reiserfs_xattr_get+0x9d/0x9a0 fs/reiserfs/xattr.c:668
reiserfs_get_acl+0x57/0x620 fs/reiserfs/xattr_acl.c:209
get_acl.part.0+0x132/0x260 fs/posix_acl.c:140
get_acl+0x41/0x60 fs/posix_acl.c:108
check_acl fs/namei.c:279 [inline]
acl_permission_check fs/namei.c:303 [inline]
generic_permission+0x448/0x510 fs/namei.c:341
reiserfs_permission+0x64/0x80 fs/reiserfs/xattr.c:944
do_inode_permission fs/namei.c:386 [inline]
inode_permission+0x34e/0x540 fs/namei.c:451
lookup_one_len_common+0x279/0x3a0 fs/namei.c:2488
lookup_one_len+0xe6/0x190 fs/namei.c:2539
reiserfs_lookup_privroot+0x92/0x280 fs/reiserfs/xattr.c:963
reiserfs_fill_super+0x21e8/0x2e60 fs/reiserfs/super.c:2179
mount_bdev+0x2fc/0x3b0 fs/super.c:1158
mount_fs+0xa3/0x318 fs/super.c:1261
vfs_kern_mount.part.0+0x68/0x470 fs/namespace.c:961
vfs_kern_mount fs/namespace.c:951 [inline]
do_new_mount fs/namespace.c:2469 [inline]
do_mount+0x51c/0x2f10 fs/namespace.c:2799
ksys_mount+0xcf/0x130 fs/namespace.c:3015
__do_sys_mount fs/namespace.c:3029 [inline]
__se_sys_mount fs/namespace.c:3026 [inline]
__x64_sys_mount+0xba/0x150 fs/namespace.c:3026
do_syscall_64+0xf9/0x670 arch/x86/entry/common.c:293
entry_SYSCALL_64_after_hwframe+0x49/0xbe
RIP: 0033:0x447dba
Code: b8 08 00 00 00 0f 05 48 3d 01 f0 ff ff 0f 83 7d a3 fb ff c3 66 2e 0f 1f 84 00 00 00 00 00 66 90 49 89 ca b8 a5 00 00 00 0f 05 <48> 3d 01 f0 ff ff 0f 83 5a a3 fb ff c3 66 0f 1f 84 00 00 00 00 00
RSP: 002b:00007fffbefcd288 EFLAGS: 00000297 ORIG_RAX: 00000000000000a5
RAX: ffffffffffffffda RBX: 00007fffbefcd2e0 RCX: 0000000000447dba
RDX: 0000000020000000 RSI: 0000000020000100 RDI: 00007fffbefcd2a0
RBP: 00007fffbefcd2a0 R08: 00007fffbefcd2e0 R09: 0000000000000000
R10: 0000000000010000 R11: 0000000000000297 R12: 0000000000000007
R13: 0000000000000004 R14: 0000000000000003 R15: 0000000000000003
Modules linked in:
---[ end trace 1c9cd68c905fdaa1 ]---
RIP: 0010:d_really_is_negative include/linux/dcache.h:466 [inline]
RIP: 0010:open_xa_root fs/reiserfs/xattr.c:124 [inline]
RIP: 0010:open_xa_dir+0xf6/0x690 fs/reiserfs/xattr.c:152
Code: 48 c1 ea 03 80 3c 02 00 0f 85 d2 04 00 00 4c 8b ad 70 05 00 00 48 b8 00 00 00 00 00 fc ff df 4d 8d 75 58 4c 89 f2 48 c1 ea 03 <80> 3c 02 00 0f 85 be 04 00 00 49 8b 6d 58 4c 89 04 24 48 85 ed 0f
RSP: 0018:ffff8880852a76d0 EFLAGS: 00010202
RAX: dffffc0000000000 RBX: ffff88807fd8c740 RCX: ffffffff81edae4e
RDX: 000000000000000b RSI: ffffffff81ed86c6 RDI: ffff8880a386c570
RBP: ffff8880a386c000 R08: ffff88808499abc0 R09: 0000000000000000
R10: 0000000000000005 R11: 0000000000000002 R12: 1ffff11010a54edc
R13: 0000000000000000 R14: 0000000000000058 R15: ffff88808499a540
FS: 000000000220f880(0000) GS:ffff8880ae300000(0000) knlGS:0000000000000000
CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: 000055f3b067e970 CR3: 000000009f98a000 CR4: 00000000001406e0
DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000
DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400


syzbot

unread,
Oct 22, 2020, 12:04:06 AM10/22/20
to syzkaller...@googlegroups.com
syzbot suspects this issue was fixed by commit:

commit e2b6b34324c44944051bc11477ecf2b3a45ec0f4
Author: Jan Kara <ja...@suse.cz>
Date: Wed Sep 30 15:08:20 2020 +0000

reiserfs: Fix oops during mount

bisection log: https://syzkaller.appspot.com/x/bisect.txt?x=11362ff0500000
start commit: cbfa1702 Linux 4.14.198
git tree: linux-4.14.y
If the result looks correct, please mark the issue as fixed by replying with:

#syz fix: reiserfs: Fix oops during mount

For information about bisection process see: https://goo.gl/tpsmEJ#bisection
Reply all
Reply to author
Forward
0 new messages