# CVE-2023-52566: nilfs2: fix potential use after free in nilfs\_gccache\_submit\_read\_data()

> Archived entry. Full-text search covers entries since 2026-11-10; exact IDs work for all years.

- **Severity:** MEDIUM 5.5
- **CVSS:** 5.5 (v3.1, CNA) `CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:N/A:H`
- **CVSS metrics:** Attack vector: Local; Attack complexity: Low; Privileges required: Low; User interaction: None; Scope: Unchanged; Confidentiality impact: None; Integrity impact: None; Availability impact: High
- **Exploited in the wild:** Not in CISA KEV
- **Public exploit / PoC:** None known
- **Remote exploitation:** Not remotely exploitable (local or adjacent access needed)
- **EPSS:** 0.30% (percentile 15, 2026-11-28)
- **CWE:** CWE-416
- **Published:** 2024-03-02T21:59:38.167Z
- **Modified:** 2026-06-17T06:43:02.450Z

## Who should check

- Anyone running Linux \>= a3d93f709e893187d301aa5458b2248db9f22bd1, \< fb1084e63ee56958b0a56e17a50a4fd86445b9c1; \>= a3d93f709e893187d301aa5458b2248db9f22bd1, \< bb61224f6abc8e71bfdf06d7c984e23460875f5b; \>= a3d93f709e893187d301aa5458b2248db9f22bd1, \< 193b5a1c6c67c36b430989dc063fe7ea4e200a33; \>= a3d93f709e893187d301aa5458b2248db9f22bd1, \< 7130a87ca32396eb9bf48b71a2d42259ae44c6c7; \>= a3d93f709e893187d301aa5458b2248db9f22bd1, \< 3936e8714907cd55e37c7cc50e50229e4a9042e8; \>= a3d93f709e893187d301aa5458b2248db9f22bd1, \< 980663f1d189eedafd18d80053d9cf3e2ceb5c8c; \>= a3d93f709e893187d301aa5458b2248db9f22bd1, \< 28df4646ad8b433340772edc90ca709cdefc53e2; \>= a3d93f709e893187d301aa5458b2248db9f22bd1, \< 7ee29facd8a9c5a26079148e36bcf07141b3a6bc
- Anyone running Linux 2.6.30

## 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\]

## Affected and fixed versions

- Linux: \>= a3d93f709e893187d301aa5458b2248db9f22bd1, \< fb1084e63ee56958b0a56e17a50a4fd86445b9c1; \>= a3d93f709e893187d301aa5458b2248db9f22bd1, \< bb61224f6abc8e71bfdf06d7c984e23460875f5b; \>= a3d93f709e893187d301aa5458b2248db9f22bd1, \< 193b5a1c6c67c36b430989dc063fe7ea4e200a33; \>= a3d93f709e893187d301aa5458b2248db9f22bd1, \< 7130a87ca32396eb9bf48b71a2d42259ae44c6c7; \>= a3d93f709e893187d301aa5458b2248db9f22bd1, \< 3936e8714907cd55e37c7cc50e50229e4a9042e8; \>= a3d93f709e893187d301aa5458b2248db9f22bd1, \< 980663f1d189eedafd18d80053d9cf3e2ceb5c8c; \>= a3d93f709e893187d301aa5458b2248db9f22bd1, \< 28df4646ad8b433340772edc90ca709cdefc53e2; \>= a3d93f709e893187d301aa5458b2248db9f22bd1, \< 7ee29facd8a9c5a26079148e36bcf07141b3a6bc (cvelist)
- Linux: 2.6.30 (cvelist)

## Mitigation

- Upgrade Linux to 7ee29facd8a9c5a26079148e36bcf07141b3a6bc or later.

## Check your systems with an agent

Paste this into a coding agent:

```text
Check whether anything I run is affected by CVE-2023-52566. Work read-only: do not install, upgrade, delete or change anything.

Details: https://flawdb.com/CVE-2023-52566.md
Affected: Linux >= a3d93f709e893187d301aa5458b2248db9f22bd1, < fb1084e63ee56958b0a56e17a50a4fd86445b9c1; >= a3d93f709e893187d301aa5458b2248db9f22bd1, < bb61224f6abc8e71bfdf06d7c984e23460875f5b; >= a3d93f709e893187d301aa5458b2248db9f22bd1, < 193b5a1c6c67c36b430989dc063fe7ea4e200a33; >= a3d93f709e893187d301aa5…
Fixed in: Linux 193b5a1c6c67c36b430989dc063fe7ea4e200a33, Linux 7130a87ca32396eb9bf48b71a2d42259ae44c6c7, Linux 3936e8714907cd55e37c7cc50e50229e4a9042e8, Linux 980663f1d189eedafd18d80053d9cf3e2ceb5c8c, Linux 28df4646ad8b433340772edc90ca709cdefc53e2, Linux 7ee29facd8a9c5a26079148e36bcf07141b3a6bc

Steps:
1. Search this machine and project for Linux: dependency manifests and lockfiles, installed packages, container images and running services.
2. For each match, note the installed version and whether it is inside the affected range.
3. Report a table: location, installed version, affected (yes / no / unsure), evidence. If affected, say which fixed version or mitigation from the details link applies, but don't apply it.
```

## FAQ

### Is CVE-2023-52566 being exploited?

There is no confirmed exploitation: CVE-2023-52566 is not in the CISA Known Exploited Vulnerabilities catalog. No public exploit code is known. EPSS estimates a 0.30% chance of exploitation in the next 30 days (as of 2026-11-28).

### How serious is CVE-2023-52566?

Medium: CVSS 5.5 (v3.1, scored by CNA). Not remotely exploitable (local or adjacent access needed).

### Which versions are affected by CVE-2023-52566?

Linux \>= a3d93f709e893187d301aa5458b2248db9f22bd1, \< fb1084e63ee56958b0a56e17a50a4fd86445b9c1; \>= a3d93f709e893187d301aa5458b2248db9f22bd1, \< bb61224f6abc8e71bfdf06d7c984e23460875f5b; \>= a3d93f709e893187d301aa5458b2248db9f22bd1, \< 193b5a1c6c67c36b430989dc063fe7ea4e200a33; \>= a3d93f709e893187d301aa5458b2248db9f22bd1, \< 7130a87ca32396eb9bf48b71a2d42259ae44c6c7; \>= a3d93f709e893187d301aa5458b2248db9f22bd1, \< 3936e8714907cd55e37c7cc50e50229e4a9042e8; \>= a3d93f709e893187d301aa5458b2248db9f22bd1, \< 980663f1d189eedafd18d80053d9cf3e2ceb5c8c; \>= a3d93f709e893187d301aa5458b2248db9f22bd1, \< 28df4646ad8b433340772edc90ca709cdefc53e2; \>= a3d93f709e893187d301aa5458b2248db9f22bd1, \< 7ee29facd8a9c5a26079148e36bcf07141b3a6bc; Linux 2.6.30.

### Is there a fix for CVE-2023-52566?

Yes. Fixed in Linux 193b5a1c6c67c36b430989dc063fe7ea4e200a33, Linux 7130a87ca32396eb9bf48b71a2d42259ae44c6c7, Linux 3936e8714907cd55e37c7cc50e50229e4a9042e8, Linux 980663f1d189eedafd18d80053d9cf3e2ceb5c8c, Linux 28df4646ad8b433340772edc90ca709cdefc53e2, Linux 7ee29facd8a9c5a26079148e36bcf07141b3a6bc. Upgrade Linux to 7ee29facd8a9c5a26079148e36bcf07141b3a6bc or later.

### How do I check if I'm affected by CVE-2023-52566?

Find where you use the affected software (dependency lockfiles, installed packages, container images, servers) and compare the installed version with the affected range above. The agent prompt on this page does this read-only.

## References

- patch: <https://git.kernel.org/stable/c/fb1084e63ee56958b0a56e17a50a4fd86445b9c1>
- patch: <https://git.kernel.org/stable/c/bb61224f6abc8e71bfdf06d7c984e23460875f5b>
- patch: <https://git.kernel.org/stable/c/193b5a1c6c67c36b430989dc063fe7ea4e200a33>
- patch: <https://git.kernel.org/stable/c/7130a87ca32396eb9bf48b71a2d42259ae44c6c7>
- patch: <https://git.kernel.org/stable/c/3936e8714907cd55e37c7cc50e50229e4a9042e8>
- patch: <https://git.kernel.org/stable/c/980663f1d189eedafd18d80053d9cf3e2ceb5c8c>
- patch: <https://git.kernel.org/stable/c/28df4646ad8b433340772edc90ca709cdefc53e2>
- patch: <https://git.kernel.org/stable/c/7ee29facd8a9c5a26079148e36bcf07141b3a6bc>

## Attribution

- CVE Program: CVE® is a registered trademark of The MITRE Corporation. CVE records © 1999–2026 The MITRE Corporation. <https://www.cve.org/Legal/TermsOfUse>
- NVD: This product uses data from the NVD API but is not endorsed or certified by the NVD. <https://nvd.nist.gov/vuln/detail/CVE-2023-52566>

HTML: <https://flawdb.com/CVE-2023-52566> · JSON: <https://flawdb.com/api/v1/entries/CVE-2023-52566>
