KASAN: stack-out-of-bounds Read in iov_iter_revert

7 views
Skip to first unread message

syzbot

unread,
Sep 12, 2021, 1:39:26 PM9/12/21
to syzkaller...@googlegroups.com
Hello,

syzbot found the following issue on:

HEAD commit: f96eb53cbd76 Linux 4.14.246
git tree: linux-4.14.y
console output: https://syzkaller.appspot.com/x/log.txt?x=16842853300000
kernel config: https://syzkaller.appspot.com/x/.config?x=678b722a9f6422ef
dashboard link: https://syzkaller.appspot.com/bug?extid=c9ab5b4d6a32fbfc2f13
compiler: gcc version 10.2.1 20210110 (Debian 10.2.1-6)
syz repro: https://syzkaller.appspot.com/x/repro.syz?x=174032dd300000
C reproducer: https://syzkaller.appspot.com/x/repro.c?x=1555197d300000

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

IPVS: ftp: loaded support on port[0] = 21
audit: type=1800 audit(1631468243.413:2): pid=7983 uid=0 auid=4294967295 ses=4294967295 op="collect_data" cause="failed(directio)" comm="syz-executor040" name="/" dev="fuse" ino=1 res=0
==================================================================
BUG: KASAN: stack-out-of-bounds in iov_iter_revert lib/iov_iter.c:917 [inline]
BUG: KASAN: stack-out-of-bounds in iov_iter_revert+0x800/0x900 lib/iov_iter.c:866
Read of size 8 at addr ffff8880a17dfd38 by task syz-executor040/7982

CPU: 0 PID: 7982 Comm: syz-executor040 Not tainted 4.14.246-syzkaller #0
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+0x1b2/0x281 lib/dump_stack.c:58
print_address_description.cold+0x54/0x1d3 mm/kasan/report.c:252
kasan_report_error.cold+0x8a/0x191 mm/kasan/report.c:351
kasan_report mm/kasan/report.c:409 [inline]
__asan_report_load8_noabort+0x68/0x70 mm/kasan/report.c:430
iov_iter_revert lib/iov_iter.c:917 [inline]
iov_iter_revert+0x800/0x900 lib/iov_iter.c:866
generic_file_read_iter+0x1183/0x21c0 mm/filemap.c:2257
fuse_file_read_iter+0x185/0x220 fs/fuse/file.c:943
call_read_iter include/linux/fs.h:1772 [inline]
new_sync_read fs/read_write.c:401 [inline]
__vfs_read+0x449/0x620 fs/read_write.c:413
vfs_read+0x139/0x340 fs/read_write.c:447
SYSC_read fs/read_write.c:574 [inline]
SyS_read+0xf2/0x210 fs/read_write.c:567
do_syscall_64+0x1d5/0x640 arch/x86/entry/common.c:292
entry_SYSCALL_64_after_hwframe+0x46/0xbb
RIP: 0033:0x445ea9
RSP: 002b:00007fec131c82f8 EFLAGS: 00000246 ORIG_RAX: 0000000000000000
RAX: ffffffffffffffda RBX: 00000000004d14f0 RCX: 0000000000445ea9
RDX: 000000002000a3a0 RSI: 0000000020008380 RDI: 0000000000000005
RBP: 00000000004a10dc R08: 0000000000000000 R09: 0000000000000000
R10: 0000000000000000 R11: 0000000000000246 R12: 0030656c69662f2e
R13: 000000000049d0d0 R14: 000000000049f0d8 R15: 00000000004d14f8

The buggy address belongs to the page:
page:ffffea000285f7c0 count:0 mapcount:0 mapping: (null) index:0x0
flags: 0xfff00000000000()
raw: 00fff00000000000 0000000000000000 0000000000000000 00000000ffffffff
raw: 0000000000000000 0000000100000001 0000000000000000 0000000000000000
page dumped because: kasan: bad access detected

Memory state around the buggy address:
ffff8880a17dfc00: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
ffff8880a17dfc80: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
>ffff8880a17dfd00: 00 00 00 00 f1 f1 f1 f1 00 00 f2 f2 00 00 00 00
^
ffff8880a17dfd80: 00 f2 f2 f2 f2 f2 00 00 00 00 00 f3 f3 f3 f3 f3
ffff8880a17dfe00: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
==================================================================


---
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
Reply all
Reply to author
Forward
0 new messages