Bug 2396114 (CVE-2022-50367) - CVE-2022-50367 kernel: fs: fix UAF/GPF bug in nilfs_mdt_destroy
Summary: CVE-2022-50367 kernel: fs: fix UAF/GPF bug in nilfs_mdt_destroy
Keywords:
Status: NEW
Alias: CVE-2022-50367
Product: Security Response
Classification: Other
Component: vulnerability
Version: unspecified
Hardware: All
OS: Linux
medium
medium
Target Milestone: ---
Assignee: Product Security DevOps Team
QA Contact:
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2025-09-17 15:02 UTC by OSIDB Bzimport
Modified: 2025-09-17 18:01 UTC (History)
0 users

Fixed In Version:
Clone Of:
Environment:
Last Closed:
Embargoed:


Attachments (Terms of Use)

Description OSIDB Bzimport 2025-09-17 15:02:12 UTC
In the Linux kernel, the following vulnerability has been resolved:

fs: fix UAF/GPF bug in nilfs_mdt_destroy

In alloc_inode, inode_init_always() could return -ENOMEM if
security_inode_alloc() fails, which causes inode->i_private
uninitialized. Then nilfs_is_metadata_file_inode() returns
true and nilfs_free_inode() wrongly calls nilfs_mdt_destroy(),
which frees the uninitialized inode->i_private
and leads to crashes(e.g., UAF/GPF).

Fix this by moving security_inode_alloc just prior to
this_cpu_inc(nr_inodes)


Note You need to log in before you can comment on or make changes to this bug.