From mboxrd@z Thu Jan 1 00:00:00 1970 From: AL-KERNEL To: kernel-cve@kernelcve.org Subject: [CVE-2022-49347][LOW] ext4: fix bug_on in ext4_writepages Date: Mon, 12 Oct 2026 21:06:18 -0400 Message-ID: MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-AL-KERNEL-CVE: CVE-2022-49347 X-AL-KERNEL-Priority: LOW X-AL-KERNEL-Severity: LOW X-AL-KERNEL-Base-Severity: LOW X-AL-KERNEL-KPANIC: NO X-AL-KERNEL-ActionableScore: 2 X-AL-KERNEL-ActionableScore-Lower: unknown X-AL-KERNEL-Commit: 19918ec7717d87d5ab825884a46b26b21375d7ce List-Id: CVE: CVE-2022-49347 Priority: LOW AL-KERNEL base severity: LOW KPANIC flag: NO Patch: ext4: fix bug_on in ext4_writepages Commit: 19918ec7717d87d5ab825884a46b26b21375d7ce Upstream patch: https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/commit/?id=19918ec7717d87d5ab825884a46b26b21375d7ce Original CVE announcement: https://lore.kernel.org/linux-cve-announce/?q=CVE-2022-49347 Analysis date: Mon, 12 Oct 2026 21:06:18 -0400 ActionableScore: 2 ActionableScore lower bound: unknown Actionable bucket: Ordinary Moderate Manual review required: NO Summary: No one-sentence report phrase was found. ====================================================================== ABOUT THIS REPORT ====================================================================== The original Linux kernel CVE announcement for CVE-2022-49347 is available here: https://lore.kernel.org/linux-cve-announce/?q=CVE-2022-49347 The original announcement does not normally provide a security severity estimate, CVSS assessment, or enough information to determine whether the reported kernel bug represents a practically relevant security issue. This report was generated by AL-KERNEL, an AI-assisted Linux kernel vulnerability analysis system developed by Alexander Larkin. It combines an autonomous classifier with LLM-assisted technical analysis and a separate ActionableScore mechanism. The purpose of this report is to prioritize Linux kernel CVEs before manual review, identify cases that require prompt investigation, and support automatic closure of issues that are unlikely to have meaningful security impact. Published priority for this report: LOW Manual review required: NO A detailed explanation of the methodology and priority rules is included at the end of this message. ====================================================================== AL-KERNEL CLASSIFICATION RESULT ====================================================================== CVE-2022-49347 LOW https://www.kernelcve.org/list/?q=CVE-2022-49347 CHECK WITH IMPACT FROM ORIG NN LOW | AEGIS IMPACT MODERATE_KPANIC AEGIS_AS=2 LEGACY=LOW RESULT=DIFF TEMP_DISTANCE_MERGE_SKIP=AEGIS_NO_POSITIVE_SEVERITY_EVIDENCE (independent Legacy and Aegis differ; FINAL: LOW, Aegis: MODERATE_KPANIC) Maybe valid. Check manually. Hints by AL-KERNEL: The best (paranoid) CVSS is 'AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:N/A:H';CWE-617;CWE-703;*CWE-664;Other CVSS 'AV:L/AC:H/PR:L/UI:N/S:U/C:N/I:N/A:H';BEST CVSS score: '5.5';DESCR 'An inconsistent ext4 inline data conversion state can reach BUG_ON in ext4_writepages and cause a kernel crash. The condition can occur when delayed allocation conversion is still pending, another inline data conversion is attempted, and block mapping fails before the inline state is restored. For the CVSS the PR:L value is used because an unprivileged local user may trigger the relevant write and fallocate operations on a file the user controls. The base score uses AC:H because the trigger requires inline data, delayed allocation, a specific operation sequence, and an allocation or mapping failure. The issue is not network reachable. Impact is denial of service through a kernel BUG with no supported UAF, OOB access, information disclosure, or arbitrary write primitive.';NO MANUAL CHECK; ,and ActionableScore result is Ordinary Moderate (with actual score 2) MAYBE KASAN DISK INIT HARDWARE CVEOUTDATED DECREASED_TO_MODERATE_REGULAR_FROM_MODERATE7_BASED_ON_GUESSCVSS_AND_CIANNH DECREASED_TO_LOW_FROM_MODERATE_BASED_ON_ACTIONABLESCORELESSTHAN3 - - checked ====================================================================== ACTIONABLESCORE ANALYSIS ====================================================================== ActionableScore=2 PrimitiveClass=CLASS_C RealUAF=NO HostAdminRequired=UNKNOWN NamespaceScopedPrivilege=UNKNOWN ImportantCandidate=NO ManualReview=NO AutoDowngradeAllowed=YES RequiresHostUID0=UNKNOWN AuthorizationDecisionBypass=NO ProtectedResourceImpact=NONE B4PendingReview=NO B4PendingConfirmed=NO 1. ActionableScore * Raw conservative score: 2 * Conservative score: 2 * Raw paranoid score: 2 * Paranoid score: 2 * No floor or cap was applied. * Final recommended bucket: **Ordinary Moderate**:: 2. Signal breakdown Positive signals: * +1 Reliable kernel crash / strong DoS. The supplied trace demonstrates a reachable `BUG_ON()` in `ext4_writepages()`. * +1 Important filesystem/storage path. The defect affects ext4 inline-data conversion, delayed allocation, and writeback state. Negative signals: * No negative points applied. Host-admin privilege, rare configuration, and hard timing were not positively established and therefore were not used as penalties. Material non-awarded signals: * No UAF, stale post-lifetime access, OOB read, OOB write, arbitrary write, or repeated release operation is established. * No filesystem metadata corruption bonus was awarded. The inconsistent bitmap report is an observed prerequisite or surrounding condition, not a demonstrated consequence of this state-transition bug. * No local-unprivileged bonus was awarded because write and fallocate are ordinarily accessible on an owned file, but the complete trigger also needs inline-data state and a block-mapping failure whose below-host-admin controllability is unresolved. * No extra Availability point was awarded because it would double-count the demonstrated kernel crash. * No confidentiality, integrity, authorization-bypass, shared-backing, or COW signal is established. * B5-R does not apply because there is no confirmed retry-accumulated heap OOB write. * B3-PENDING does not apply because no write into shared or file-backed storage outside the authorized file is shown. * B4-PENDING does not apply because no authorization decision changes from DENY to ALLOW. 3. Reachability analysis The visible trigger sequence uses writes, fallocate, delayed-allocation writeback, and an ext4 ioctl path on an inline-data inode. An ordinary user can normally write and fallocate a file the user owns, but the supplied evidence does not prove that such a user can reliably create the required block-mapping failure or initial filesystem condition. Host-admin-equivalent privilege is therefore not positively required, but complete below-host-admin reachability is also not established. `HostAdminRequired` remains `UNKNOWN`. No capability namespace governs the demonstrated operations, and no complete namespace-scoped trigger is established. An ext4 filesystem with inline-data support must already exist and be mounted. No special hardware or network access is involved. This is an ordered state-transition sequence rather than a timing race, so no race penalty applies. 4. Primitive and severity interpretation The exact primitive is an inconsistent ext4 inode state during overlapping inline-data-to-extent conversion phases. Pending delayed-allocation conversion leaves inline data present while `EXT4_STATE_MAY_INLINE_DATA` is cleared. A second conversion and restoration path can set the flag again before writeback reaches `ext4_writepages()`, where the incompatible state triggers `BUG_ON()`. This is neither active structured UAF nor fixed stale storage. It is a logic and state-management defect classified as `CLASS_C`. There is no concrete repeated release or refcount mutation. The demonstrated consequence is kernel crash and local denial of service. Memory corruption, persistent filesystem corruption, information disclosure, privilege escalation, and cross-file modification are unsupported speculative consequences. The fix forces pending writeback to complete before another inline conversion proceeds. `ImportantCandidate=NO` because no independently useful corruption, ownership, lifetime, or authorization primitive survives after excluding the crash. `AutoDowngradeAllowed=YES` because the established behavior is a constrained assertion failure without unresolved exploitation leverage. 5. One-sentence report phrase An inconsistent ext4 inline-data conversion state can reach BUG_ON in ext4_writepages and crash the kernel, but the patch establishes no UAF, OOB access, authorization bypass, or non-crash corruption primitive. 6. Manual review recommendation NO MANUAL CHECK NEEDED The demonstrated issue is a Class C local assertion failure with DoS impact, and no Important-preserving primitive is established. 7. Call-site confidence Call-site confidence: high ====================================================================== UPSTREAM PATCH SUMMARY ====================================================================== Patch: ext4: fix bug_on in ext4_writepages Commit: 19918ec7717d87d5ab825884a46b26b21375d7ce Upstream URL: https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/commit/?id=19918ec7717d87d5ab825884a46b26b21375d7ce Commit description: we got issue as follows: EXT4-fs error (device loop0): ext4_mb_generate_buddy:1141: group 0, block bitmap and bg descriptor inconsistent: 25 vs 31513 free cls ------------[ cut here ]------------ kernel BUG at fs/ext4/inode.c:2708! invalid opcode: 0000 [#1] PREEMPT SMP KASAN PTI CPU: 2 PID: 2147 Comm: rep Not tainted 5.18.0-rc2-next-20220413+ #155 RIP: 0010:ext4_writepages+0x1977/0x1c10 RSP: 0018:ffff88811d3e7880 EFLAGS: 00010246 RAX: 0000000000000000 RBX: 0000000000000001 RCX: ffff88811c098000 RDX: 0000000000000000 RSI: ffff88811c098000 RDI: 0000000000000002 RBP: ffff888128140f50 R08: ffffffffb1ff6387 R09: 0000000000000000 R10: 0000000000000007 R11: ffffed10250281ea R12: 0000000000000001 R13: 00000000000000a4 R14: ffff88811d3e7bb8 R15: ffff888128141028 FS: 00007f443aed9740(0000) GS:ffff8883aef00000(0000) knlGS:0000000000000000 CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033 CR2: 0000000020007200 CR3: 000000011c2a4000 CR4: 00000000000006e0 DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000 DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400 Call Trace: do_writepages+0x130/0x3a0 filemap_fdatawrite_wbc+0x83/0xa0 filemap_flush+0xab/0xe0 ext4_alloc_da_blocks+0x51/0x120 __ext4_ioctl+0x1534/0x3210 __x64_sys_ioctl+0x12c/0x170 do_syscall_64+0x3b/0x90 It may happen as follows: 1. write inline_data inode vfs_write new_sync_write ext4_file_write_iter ext4_buffered_write_iter generic_perform_write ext4_da_write_begin ext4_da_write_inline_data_begin -> If inline data size too small will allocate block to write, then mapping will has dirty page ext4_da_convert_inline_data_to_extent ->clear EXT4_STATE_MAY_INLINE_DATA 2. fallocate do_vfs_ioctl ioctl_preallocate vfs_fallocate ext4_fallocate ext4_convert_inline_data ext4_convert_inline_data_nolock ext4_map_blocks -> fail will goto restore data ext4_restore_inline_data ext4_create_inline_data ext4_write_inline_data ext4_set_inode_state -> set inode EXT4_STATE_MAY_INLINE_DATA 3. writepages __ext4_ioctl ext4_alloc_da_blocks filemap_flush filemap_fdatawrite_wbc do_writepages ext4_writepages if (ext4_has_inline_data(inode)) BUG_ON(ext4_test_inode_state(inode, EXT4_STATE_MAY_INLINE_DATA)) The root cause of this issue is we destory inline data until call ext4_writepages under delay allocation mode. But there maybe already convert from inline to extent. To solve this issue, we call filemap_flush first.. Cc: stable@kernel.org Signed-off-by: Ye Bin Reviewed-by: Jan Kara Link: https://lore.kernel.org/r/20220516122634.1690462-1-yebin10@huawei.com Signed-off-by: Theodore Ts'o Signed-off-by: Greg Kroah-Hartman Changed files: fs/ext4/inode.c fs/ext4/inline.c Diff excerpt: Not included in this email. See the upstream URL for the full patch. Full patch: https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/commit/?id=19918ec7717d87d5ab825884a46b26b21375d7ce ====================================================================== DETAILED REPORT METHODOLOGY ====================================================================== The original Linux kernel CVE announcement for CVE-2022-49347 can be found here: https://lore.kernel.org/linux-cve-announce/?q=CVE-2022-49347 The original CVE announcement normally does not include a security-level estimate. In particular, it may not contain a CVSS assessment, an impact level, or enough information to determine whether the reported bug is a practically relevant security issue. One purpose of this parallel CVE list is to provide that missing technical and prioritization information. The original goal of the AL-KERNEL project was to prioritize Linux kernel CVE analysis automatically before manual review. The system can also help identify non-security issues that may be suitable for automatic closure. This report was generated by AL-KERNEL, an AI-assisted Linux kernel vulnerability analysis system developed by Alexander Larkin. The first analysis stage combines an autonomous classifier with additional LLM-based analysis. The autonomous classifier runs locally on a CPU and is based on a backpropagation neural network. Together, these mechanisms produce a technical vulnerability description, identify likely weakness types, estimate CVSS severity, and provide input for ActionableScore. Two CVSS estimates are retained because incomplete kernel vulnerability information often permits more than one defensible interpretation: Conservative CVSS vector: AV:L/AC:H/PR:L/UI:N/S:U/C:N/I:N/A:H The Best / paranoid CVSS vector: AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:N/A:H The Best / paranoid CVSS score: 5.5 The conservative vector represents a lower-impact interpretation. The Best/paranoid vector intentionally represents a plausible upper-bound interpretation and should not automatically be treated as demonstrated real-world impact. CVSS may also need to be adjusted for a particular Linux deployment, because actual reachability, privileges, enabled kernel configuration, hardware, namespaces, exposed device nodes, and other environmental conditions can differ significantly between systems. A separate ActionableScore mechanism evaluates practical remediation urgency. Its analysis may include reachability, attack prerequisites, subsystem exposure, memory-corruption characteristics, denial-of-service reliability, and possible confidentiality, integrity, or privilege-escalation impact. Conservative ActionableScore: unknown Paranoid ActionableScore: 2 The final base severity is taken directly from the second tab-separated field of the AL-KERNEL classification result. ActionableScore does not replace or independently override that final AL-KERNEL decision, and if ActionableScore adjusted impact level of ALKERNEL, then you would see self-readable flags above like INCREASED_TO_HIGH_BASED_ON_ACTIONABLESCOREHIGHEREQTHAN7. For an AL-KERNEL result of MODERATE, this report uses the following additional presentation split: ActionableScore below 5 -> MODERATE REGULAR ActionableScore 5 or more -> MODERATE 7.0 The distinction between MODERATE REGULAR and MODERATE 7.0 makes it possible to identify Moderate issues that should receive manual analysis and fixes before lower-priority MODERATE REGULAR issues. In many cases, MODERATE REGULAR fixes may wait for a later rebase or routine update. There is one override in which MODERATE REGULAR becomes MODERATE 7.0 even when the ActionableScore is below 5. When the AL-KERNEL result contains the KPANIC flag, a MODERATE result is always presented as MODERATE 7.0. The KPANIC flag selected with few regexps without usage of AI at all, so it helps to detect cases when Kernel Crash happens and similar (to filter False-Negative results from the LLM usage). KPANIC indicates that a reliable kernel crash, kernel panic, or similarly serious kernel availability impact was identified by the classification workflow. AL-KERNEL base severity for this report: LOW KPANIC detected for this report: NO Published priority for this report (same as in Subject): LOW These results are intended to support engineering triage. They are machine-generated estimates, and cases marked for manual review should be validated by a human security engineer before final disposition. For more info read docs linked from here: https://kernelcve.org/ (and you can submit you own patch there to generate such a report for non-existant CVE-id yet). Note that in many cases this AI tool selects higher severity, than real is (means you can expect Importants instead of Moderate 7.0 or Moderates 7.0 instead of regular Moderates). If you see such cases, please use reply email interface to add additional manual analyses info to this particular CVE. And please, please, let me know when you see Lows instead of Importants or Important instead of Low (because particular for such cases I need to tune this AI tool to make it better for this one and next similar). My contact email for such notifications is alexanjelausa@gmail.com (and both send reply to CVE record itself too and see "reply" button below for howto reply).