CVE-2022-50367
fs: fix UAF/GPF bug in nilfs_mdt_destroy
Check your servers for CVE-2022-50367
The Vulnpocalypse collector sends the package list of each Linux server and of its container images once a day. Vulnpocalypse shows every server where CVE-2022-50367 affects the running kernel, with the command that installs the fix. The free plan covers one server and one domain and does not need a credit card.
Description
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)
Severity (CVSS)
CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H
- Attack vector
- local: the attacker needs local access, or a user has to open a prepared file
- Attack complexity
- low: an attack works without special conditions
- Privileges required
- low: the attacker needs an ordinary user account
- User interaction
- none: nobody has to click or open anything
- Scope
- unchanged: the damage stays inside the vulnerable component
- Impact
- confidentiality high, integrity high, availability high: what an attacker can read (confidentiality), change (integrity) or stop (availability)
CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H
- Attack vector
- local: the attacker needs local access, or a user has to open a prepared file
- Attack complexity
- low: an attack works without special conditions
- Privileges required
- low: the attacker needs an ordinary user account
- User interaction
- none: nobody has to click or open anything
- Scope
- unchanged: the damage stays inside the vulnerable component
- Impact
- confidentiality high, integrity high, availability high: what an attacker can read (confidentiality), change (integrity) or stop (availability)
Exploitation
EPSS 0.23%: the probability of exploitation activity in the next 30 days, from the EPSS model of FIRST. The score is higher than 15.4% of all scored CVEs. Scores of 1 Dec 2026.
The assessment of CISA (SSVC, 14 Jan 2026):
- Exploitation
- none: CISA did not find evidence of exploitation or a public proof of concept
- Automatable
- no: each attack takes manual steps
- Technical impact
- total: full control of the component or of its data
Weakness
- CWE-416 Use After Free
Affected products
As the CNA lists them.
| Product | Versions |
|---|---|
| Linux |
affected from 1da177e4c3f41524e886b7f1b8a0c1fc7321cac2, before d1ff475d7c83289d0a7faef346ea3bbf90818bad affected from 1da177e4c3f41524e886b7f1b8a0c1fc7321cac2, before c0aa76b0f17f59dd9c9d3463550a2986a1d592e4 affected from 1da177e4c3f41524e886b7f1b8a0c1fc7321cac2, before ec2aab115eb38ac4992ea2fcc2a02fbe7af5cf48 affected from 1da177e4c3f41524e886b7f1b8a0c1fc7321cac2, before 70e4f70d54e0225f91814e8610477d65f33cefe4 affected from 1da177e4c3f41524e886b7f1b8a0c1fc7321cac2, before 1e555c3ed1fce4b278aaebe18a64a934cece57d8 affected from 1da177e4c3f41524e886b7f1b8a0c1fc7321cac2, before 64b79e632869ad3ef6c098a4731d559381da1115 affected from 1da177e4c3f41524e886b7f1b8a0c1fc7321cac2, before 81de80330fa6907aec32eb54c5619059e6e36452 affected from 1da177e4c3f41524e886b7f1b8a0c1fc7321cac2, before 2a96b532098284ecf8e4849b8b9e5fc7a28bdee9 affected from 1da177e4c3f41524e886b7f1b8a0c1fc7321cac2, before 2e488f13755ffbb60f307e991b27024716a33b29
Other versions: unaffected
|
| Linux |
affected 2.6.12 unaffected before 2.6.12 unaffected from 4.9.331 up to and including 4.9.* unaffected from 4.14.296 up to and including 4.14.* unaffected from 4.19.262 up to and including 4.19.* unaffected from 5.4.218 up to and including 5.4.* unaffected from 5.10.148 up to and including 5.10.* unaffected from 5.15.73 up to and including 5.15.* unaffected from 5.19.15 up to and including 5.19.* unaffected from 6.0.1 up to and including 6.0.* unaffected 6.1 and later
Other versions: affected
|
Is my server affected?
This CVE is in the Linux kernel. Compare the running kernel with the fixed kernel version of your distribution, and reboot after a kernel update:
uname -r
# Debian, Ubuntu: does the changelog of the running kernel name the CVE?
zgrep -l CVE-2022-50367 /usr/share/doc/linux-image-$(uname -r)/changelog.Debian.gz
# RHEL, Rocky, Alma
rpm -q --changelog kernel | grep CVE-2022-50367
With Trivy, on the host and for a container image. When a package is affected, it prints the installed and the fixed version:
trivy rootfs --scanners vuln / | grep CVE-2022-50367
trivy image --scanners vuln IMAGE | grep CVE-2022-50367
Vulnpocalypse makes this comparison every day for the package lists of your servers and container images, including language packages (npm, PyPI, Go, Maven and others), and sends the command that installs the fix. Start free with one server and one domain or read how to install the collector.
References
Other references
- https://git.kernel.org/stable/c/d1ff475d7c83289d0a7faef346ea3bbf90818bad git.kernel.org
- https://git.kernel.org/stable/c/c0aa76b0f17f59dd9c9d3463550a2986a1d592e4 git.kernel.org
- https://git.kernel.org/stable/c/ec2aab115eb38ac4992ea2fcc2a02fbe7af5cf48 git.kernel.org
- https://git.kernel.org/stable/c/70e4f70d54e0225f91814e8610477d65f33cefe4 git.kernel.org
- https://git.kernel.org/stable/c/1e555c3ed1fce4b278aaebe18a64a934cece57d8 git.kernel.org
- https://git.kernel.org/stable/c/64b79e632869ad3ef6c098a4731d559381da1115 git.kernel.org
- https://git.kernel.org/stable/c/81de80330fa6907aec32eb54c5619059e6e36452 git.kernel.org
- https://git.kernel.org/stable/c/2a96b532098284ecf8e4849b8b9e5fc7a28bdee9 git.kernel.org
- https://git.kernel.org/stable/c/2e488f13755ffbb60f307e991b27024716a33b29 git.kernel.org
Source: the record CVE-2022-50367 of the CVE List (CVE Program), CVE Terms of Use; the CISA KEV catalog and the CISA ADP container; EPSS of FIRST; the CWE catalog of MITRE, CWE Terms of Use. The text of the record is shown as published. Data sources and licences.
Vulnpocalypse