CVE-2023-52566
nilfs2: fix potential use after free in nilfs_gccache_submit_read_data()
Check your servers for CVE-2023-52566
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-2023-52566 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:
nilfs2: fix potential use after free in nilfs_gccache_submit_read_data()
In nilfs_gccache_submit_read_data(), brelse(bh) is called to drop the reference count of bh when the call to nilfs_dat_translate() fails. If the reference count hits 0 and its owner page gets unlocked, bh may be freed. However, bh->b_page is dereferenced to put the page after that, which may result in a use-after-free bug. This patch moves the release operation after unlocking and putting the page.
NOTE: The function in question is only called in GC, and in combination with current userland tools, address translation using DAT does not occur in that function, so the code path that causes this issue will not be executed. However, it is possible to run that code path by intentionally modifying the userland GC library or by calling the GC ioctl directly.
[konishi.ryusuke@gmail.com: NOTE added to the commit log]
Severity (CVSS)
CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:N/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 none, integrity none, 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.3% of all scored CVEs. Scores of 1 Dec 2026.
The assessment of CISA (SSVC, 24 Jul 2024):
- Exploitation
- none: CISA did not find evidence of exploitation or a public proof of concept
- Automatable
- no: each attack takes manual steps
- Technical impact
- partial: limited control or limited data
Weakness
- CWE-416 Use After Free
Affected products
As the CNA lists them.
| Product | Versions |
|---|---|
| Linux |
affected from a3d93f709e893187d301aa5458b2248db9f22bd1, before fb1084e63ee56958b0a56e17a50a4fd86445b9c1 affected from a3d93f709e893187d301aa5458b2248db9f22bd1, before bb61224f6abc8e71bfdf06d7c984e23460875f5b affected from a3d93f709e893187d301aa5458b2248db9f22bd1, before 193b5a1c6c67c36b430989dc063fe7ea4e200a33 affected from a3d93f709e893187d301aa5458b2248db9f22bd1, before 7130a87ca32396eb9bf48b71a2d42259ae44c6c7 affected from a3d93f709e893187d301aa5458b2248db9f22bd1, before 3936e8714907cd55e37c7cc50e50229e4a9042e8 affected from a3d93f709e893187d301aa5458b2248db9f22bd1, before 980663f1d189eedafd18d80053d9cf3e2ceb5c8c affected from a3d93f709e893187d301aa5458b2248db9f22bd1, before 28df4646ad8b433340772edc90ca709cdefc53e2 affected from a3d93f709e893187d301aa5458b2248db9f22bd1, before 7ee29facd8a9c5a26079148e36bcf07141b3a6bc
Other versions: unaffected
|
| Linux |
affected 2.6.30 unaffected before 2.6.30 unaffected from 4.14.327 up to and including 4.14.* unaffected from 4.19.296 up to and including 4.19.* unaffected from 5.4.258 up to and including 5.4.* unaffected from 5.10.198 up to and including 5.10.* unaffected from 5.15.134 up to and including 5.15.* unaffected from 6.1.56 up to and including 6.1.* unaffected from 6.5.6 up to and including 6.5.* unaffected 6.6 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-2023-52566 /usr/share/doc/linux-image-$(uname -r)/changelog.Debian.gz
# RHEL, Rocky, Alma
rpm -q --changelog kernel | grep CVE-2023-52566
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-2023-52566
trivy image --scanners vuln IMAGE | grep CVE-2023-52566
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/fb1084e63ee56958b0a56e17a50a4fd86445b9c1 git.kernel.org
- https://git.kernel.org/stable/c/bb61224f6abc8e71bfdf06d7c984e23460875f5b git.kernel.org
- https://git.kernel.org/stable/c/193b5a1c6c67c36b430989dc063fe7ea4e200a33 git.kernel.org
- https://git.kernel.org/stable/c/7130a87ca32396eb9bf48b71a2d42259ae44c6c7 git.kernel.org
- https://git.kernel.org/stable/c/3936e8714907cd55e37c7cc50e50229e4a9042e8 git.kernel.org
- https://git.kernel.org/stable/c/980663f1d189eedafd18d80053d9cf3e2ceb5c8c git.kernel.org
- https://git.kernel.org/stable/c/28df4646ad8b433340772edc90ca709cdefc53e2 git.kernel.org
- https://git.kernel.org/stable/c/7ee29facd8a9c5a26079148e36bcf07141b3a6bc git.kernel.org
Source: the record CVE-2023-52566 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