Received: by 2002:a05:6358:9144:b0:117:f937:c515 with SMTP id r4csp8836876rwr; Thu, 11 May 2023 06:55:18 -0700 (PDT) X-Google-Smtp-Source: ACHHUZ6RponJLBw4OeRQbaWYjw3OsMSWggWAu/DRP26Br1W46lvL6yI8vMH22CXb3WHasPZrT723 X-Received: by 2002:a05:6a20:12c4:b0:101:64b0:e69c with SMTP id v4-20020a056a2012c400b0010164b0e69cmr12208137pzg.29.1683813318036; Thu, 11 May 2023 06:55:18 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1683813318; cv=none; d=google.com; s=arc-20160816; b=UCOzWufe2Gb2+NaLo8FMwLUCDKpLBod6MbGqBubOsfhPo3KnbYP77Y+Nd+ER6qTRAJ oU/T0w3lPypvSpCjmk2NhZRWEjuPMlQxoBiWUHjN91tdVGjvBqMg+c2CgkFya432zKSY CBD8DsvBWmxMR1z0oyZb0Hv3hbkWCIoEq5hBt5g+tBqZJWBmsC9TECjwKUVRocjoJG5f wkuxGcySl+IeQopHAR+QMrtm3jH+AJMJ8CY9c/dSoiK8oGDTkZdRZi8vhu79ghBpKnBa G3Hgdwbj7TXYbfOvnqArljc59z8hkVRQvrLdUBmMn/mRq960oAKqH7thVjU6W1vjpYqf lEgw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:to:from:subject:message-id:in-reply-to:date :mime-version; bh=YEtKPqXPc8KwjQyplWNpVUtXydk8COJxQKJbi5Nsyvo=; b=wDgbi6ywlJ18DXKZB7tvXu26f3SVq99v3HkBI6ft0+D23zem/fhV0+v33QnHl9VnAG oO+bVV1FZc/n4bNDeLQsSa1eK0UigMNYuVEP1Ayb1HtlXZ65V1KO7+BANeyMX+9g8b8J LgqkxWExFwP00QYZdF+/63E5CvT8arpe31HWG6qiHgVa/RsEo9XYUD6nM3YDRa0H45EO zDlwMaF5TeSqgVWYL7cAi0yI8TG2tHAENvtBTzamc6DaquTlarB3hwunmC2+tX4cZn+Q pFZ0zLYqd6d6RCmalgbRdAN0okf2oityRjbe0zvoS3xzKdF8Yx9eXzNoTw84pSxKCNRi H1ig== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=appspotmail.com Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id y10-20020aa79aea000000b0063b78126397si7394982pfp.230.2023.05.11.06.55.06; Thu, 11 May 2023 06:55:18 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=appspotmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S237628AbjEKNhf (ORCPT + 99 others); Thu, 11 May 2023 09:37:35 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:51608 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S237981AbjEKNf7 (ORCPT ); Thu, 11 May 2023 09:35:59 -0400 Received: from mail-il1-f199.google.com (mail-il1-f199.google.com [209.85.166.199]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 051A611545 for ; Thu, 11 May 2023 06:35:00 -0700 (PDT) Received: by mail-il1-f199.google.com with SMTP id e9e14a558f8ab-33172d0eb28so123447565ab.2 for ; Thu, 11 May 2023 06:35:00 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1683812100; x=1686404100; h=to:from:subject:message-id:in-reply-to:date:mime-version :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=YEtKPqXPc8KwjQyplWNpVUtXydk8COJxQKJbi5Nsyvo=; b=QUMWPUEyuQemMdOY508svUcNf1S7tZJYXj6sRgOUDc9yOpcQ1ntx3HJUJtVXT7LKsU eGat0PtH0u8Y2DGXoi3vZDN2snMzzA0B445p3YFiZXwTpPEWyZKS3L9EPs+Lcl/39UOa vNPmE3A7o9plXf3I2oAYoczGm5BacFm/U/xECBGUBvwJj7gTH8yUAW6wgJ0i1fJa7sSJ q0+TpsFHtPsyZQADhiZfuw64r0jrNj3L2PGzabY7ckCo+Xh3OxeooMRyiKxLPRAawYiT EIoP95KzxBT/OWHRBQGKA4WymFkFgQ29rsTSiLIdRdiEPzsZB/W5+DBqOsy0nHMW156d OQRg== X-Gm-Message-State: AC+VfDwNOCXFnfIC5f8/wY9bYOHUXncsUzbAx1AC7JHM3bI5+/W3rUq1 IAoMVs68kAdNdZQHp/RL05sszqOFYaaoeeu6RovHfcKBoIa7 MIME-Version: 1.0 X-Received: by 2002:a92:c686:0:b0:317:9096:e80f with SMTP id o6-20020a92c686000000b003179096e80fmr11324593ilg.4.1683812100231; Thu, 11 May 2023 06:35:00 -0700 (PDT) Date: Thu, 11 May 2023 06:35:00 -0700 In-Reply-To: <000000000000602c0e05f55d793c@google.com> X-Google-Appengine-App-Id: s~syzkaller X-Google-Appengine-App-Id-Alias: syzkaller Message-ID: <0000000000001a583a05fb6b0e76@google.com> Subject: Re: [syzbot] [ntfs?] kernel BUG in ntfs_iget From: syzbot To: anton@tuxera.com, linux-fsdevel@vger.kernel.org, linux-kernel@vger.kernel.org, linux-ntfs-dev@lists.sourceforge.net, syzkaller-bugs@googlegroups.com Content-Type: text/plain; charset="UTF-8" X-Spam-Status: No, score=-1.7 required=5.0 tests=BAYES_00,FROM_LOCAL_HEX, HEADER_FROM_DIFFERENT_DOMAINS,RCVD_IN_DNSWL_NONE,RCVD_IN_MSPIKE_H2, SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=no autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org syzbot has found a reproducer for the following issue on: HEAD commit: d295b66a7b66 Merge tag 'fsnotify_for_v6.4-rc2' of git://gi.. git tree: upstream console+strace: https://syzkaller.appspot.com/x/log.txt?x=1438109e280000 kernel config: https://syzkaller.appspot.com/x/.config?x=38526bf24c8d961b dashboard link: https://syzkaller.appspot.com/bug?extid=d62e6bd2a2d05103d105 compiler: Debian clang version 15.0.7, GNU ld (GNU Binutils for Debian) 2.35.2 syz repro: https://syzkaller.appspot.com/x/repro.syz?x=16ba9dec280000 C reproducer: https://syzkaller.appspot.com/x/repro.c?x=12ef95fa280000 Downloadable assets: disk image: https://storage.googleapis.com/syzbot-assets/95f1878df2f4/disk-d295b66a.raw.xz vmlinux: https://storage.googleapis.com/syzbot-assets/6d18d65ddcb5/vmlinux-d295b66a.xz kernel image: https://storage.googleapis.com/syzbot-assets/6a59b1fdff8e/bzImage-d295b66a.xz mounted in repro: https://storage.googleapis.com/syzbot-assets/eee641006b52/mount_0.gz IMPORTANT: if you fix the issue, please add the following tag to the commit: Reported-by: syzbot+d62e6bd2a2d05103d105@syzkaller.appspotmail.com loop0: detected capacity change from 0 to 190 ntfs: (device loop0): is_boot_sector_ntfs(): Invalid boot sector checksum. ntfs: (device loop0): map_mft_record_page(): Mft record 0x1 is corrupt. Run chkdsk. ntfs: (device loop0): map_mft_record(): Failed with error code 5. ntfs: (device loop0): ntfs_read_locked_inode(): Failed with error code -5. Marking corrupt inode 0x1 as bad. Run chkdsk. ntfs: (device loop0): load_system_files(): Failed to load $MFTMirr. Mounting read-only. Run ntfsfix and/or chkdsk. ------------[ cut here ]------------ kernel BUG at fs/ntfs/malloc.h:31! invalid opcode: 0000 [#1] PREEMPT SMP KASAN CPU: 1 PID: 4993 Comm: syz-executor320 Not tainted 6.4.0-rc1-syzkaller-00025-gd295b66a7b66 #0 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 04/14/2023 RIP: 0010:__ntfs_malloc fs/ntfs/malloc.h:31 [inline] RIP: 0010:ntfs_malloc_nofs+0xfd/0x100 fs/ntfs/malloc.h:52 Code: 17 e8 d7 1e c7 fe 48 89 df be 42 0c 00 00 5b 41 5e 41 5f e9 a5 f2 10 ff e8 c0 1e c7 fe 31 c0 5b 41 5e 41 5f c3 e8 b3 1e c7 fe <0f> 0b 90 66 0f 1f 00 55 41 57 41 56 41 55 41 54 53 49 89 fe 49 bc RSP: 0018:ffffc90003a3f818 EFLAGS: 00010293 RAX: ffffffff82c4488d RBX: 0000000000000000 RCX: ffff88802476bb80 RDX: 0000000000000000 RSI: 0000000000000000 RDI: 0000000000000000 RBP: ffff888073a05118 R08: ffffffff82c447bd R09: ffffed100e9c5323 R10: 0000000000000000 R11: dffffc0000000001 R12: dffffc0000000000 R13: ffff888074e29be0 R14: ffff888073a05147 R15: dffffc0000000000 FS: 000055555752e300(0000) GS:ffff8880b9900000(0000) knlGS:0000000000000000 CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033 CR2: 00007f02336e6000 CR3: 000000007a170000 CR4: 00000000003506e0 DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000 DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400 Call Trace: ntfs_read_locked_inode+0x1fd5/0x49c0 fs/ntfs/inode.c:703 ntfs_iget+0x113/0x190 fs/ntfs/inode.c:177 load_and_init_upcase fs/ntfs/super.c:1663 [inline] load_system_files+0x151c/0x4840 fs/ntfs/super.c:1818 ntfs_fill_super+0x19b3/0x2bd0 fs/ntfs/super.c:2900 mount_bdev+0x274/0x3a0 fs/super.c:1380 legacy_get_tree+0xef/0x190 fs/fs_context.c:610 vfs_get_tree+0x8c/0x270 fs/super.c:1510 do_new_mount+0x28f/0xae0 fs/namespace.c:3039 do_mount fs/namespace.c:3382 [inline] __do_sys_mount fs/namespace.c:3591 [inline] __se_sys_mount+0x2d9/0x3c0 fs/namespace.c:3568 do_syscall_x64 arch/x86/entry/common.c:50 [inline] do_syscall_64+0x41/0xc0 arch/x86/entry/common.c:80 entry_SYSCALL_64_after_hwframe+0x63/0xcd RIP: 0033:0x7f023bb1cafa Code: 83 c4 08 5b 5d c3 66 2e 0f 1f 84 00 00 00 00 00 c3 66 2e 0f 1f 84 00 00 00 00 00 0f 1f 44 00 00 49 89 ca b8 a5 00 00 00 0f 05 <48> 3d 01 f0 ff ff 73 01 c3 48 c7 c1 c0 ff ff ff f7 d8 64 89 01 48 RSP: 002b:00007fffebbdb6c8 EFLAGS: 00000286 ORIG_RAX: 00000000000000a5 RAX: ffffffffffffffda RBX: 0000000000000003 RCX: 00007f023bb1cafa RDX: 000000002001f1c0 RSI: 000000002001f200 RDI: 00007fffebbdb6e0 RBP: 00007fffebbdb6e0 R08: 00007fffebbdb720 R09: 0000000000000987 R10: 0000000000000000 R11: 0000000000000286 R12: 0000000000000004 R13: 000055555752e2c0 R14: 0000000000000000 R15: 00007fffebbdb720 Modules linked in: ---[ end trace 0000000000000000 ]--- RIP: 0010:__ntfs_malloc fs/ntfs/malloc.h:31 [inline] RIP: 0010:ntfs_malloc_nofs+0xfd/0x100 fs/ntfs/malloc.h:52 Code: 17 e8 d7 1e c7 fe 48 89 df be 42 0c 00 00 5b 41 5e 41 5f e9 a5 f2 10 ff e8 c0 1e c7 fe 31 c0 5b 41 5e 41 5f c3 e8 b3 1e c7 fe <0f> 0b 90 66 0f 1f 00 55 41 57 41 56 41 55 41 54 53 49 89 fe 49 bc RSP: 0018:ffffc90003a3f818 EFLAGS: 00010293 RAX: ffffffff82c4488d RBX: 0000000000000000 RCX: ffff88802476bb80 RDX: 0000000000000000 RSI: 0000000000000000 RDI: 0000000000000000 RBP: ffff888073a05118 R08: ffffffff82c447bd R09: ffffed100e9c5323 R10: 0000000000000000 R11: dffffc0000000001 R12: dffffc0000000000 R13: ffff888074e29be0 R14: ffff888073a05147 R15: dffffc0000000000 FS: 000055555752e300(0000) GS:ffff8880b9900000(0000) knlGS:0000000000000000 CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033 CR2: 00007f02336e6000 CR3: 000000007a170000 CR4: 00000000003506e0 DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000 DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400 --- If you want syzbot to run the reproducer, reply with: #syz test: git://repo/address.git branch-or-commit-hash If you attach or paste a git patch, syzbot will apply it before testing.