# CVE-2025-38328: jffs2: check jffs2\_prealloc\_raw\_node\_refs() result in few other places

> 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, NVD) `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-26)
- **CWE:** CWE-476
- **Published:** 2025-07-10T08:15:02.296Z
- **Modified:** 2026-06-17T09:16:38.050Z

## Who should check

- Anyone running Linux \>= 2f785402f39b96a077b6e62bf26164bfb8e0c980, \< 7e860296d7808de1db175c1eda29f94a2955dcc4; \>= 2f785402f39b96a077b6e62bf26164bfb8e0c980, \< d96e6451a8d0fe62492d4cc942d695772293c05a; \>= 2f785402f39b96a077b6e62bf26164bfb8e0c980, \< f41c625328777f9ad572901ba0b0065bb9c9c1da; \>= 2f785402f39b96a077b6e62bf26164bfb8e0c980, \< 38d767fb4a7766ec2058f97787e4c6e8d10343d6; \>= 2f785402f39b96a077b6e62bf26164bfb8e0c980, \< cd42ddddd70abc7127c12b96c8c85dbd080ea56f; \>= 2f785402f39b96a077b6e62bf26164bfb8e0c980, \< d1b81776f337a9b997f797c70ac0a26d838a2168; \>= 2f785402f39b96a077b6e62bf26164bfb8e0c980, \< 042fa922c84b5080401bcd8897d4ac4919d15075; \>= 2f785402f39b96a077b6e62bf26164bfb8e0c980, \< 2b6d96503255a3ed676cd70f8368870c6d6a25c6
- Anyone running Linux 2.6.18

## Description

In the Linux kernel, the following vulnerability has been resolved:

jffs2: check jffs2\_prealloc\_raw\_node\_refs() result in few other places

Fuzzing hit another invalid pointer dereference due to the lack of
checking whether jffs2\_prealloc\_raw\_node\_refs() completed successfully.
Subsequent logic implies that the node refs have been allocated.

Handle that. The code is ready for propagating the error upwards.

KASAN: null-ptr-deref in range \[0x0000000000000008-0x000000000000000f\]
CPU: 1 PID: 5835 Comm: syz-executor145 Not tainted 5.10.234-syzkaller \#0
Hardware name: QEMU Standard PC (i440FX + PIIX, 1996), BIOS 1.12.0-1 04/01/2014
RIP: 0010:jffs2\_link\_node\_ref+0xac/0x690 fs/jffs2/nodelist.c:600
Call Trace:
 jffs2\_mark\_erased\_block fs/jffs2/erase.c:460 \[inline\]
 jffs2\_erase\_pending\_blocks+0x688/0x1860 fs/jffs2/erase.c:118
 jffs2\_garbage\_collect\_pass+0x638/0x1a00 fs/jffs2/gc.c:253
 jffs2\_reserve\_space+0x3f4/0xad0 fs/jffs2/nodemgmt.c:167
 jffs2\_write\_inode\_range+0x246/0xb50 fs/jffs2/write.c:362
 jffs2\_write\_end+0x712/0x1110 fs/jffs2/file.c:302
 generic\_perform\_write+0x2c2/0x500 mm/filemap.c:3347
 \_\_generic\_file\_write\_iter+0x252/0x610 mm/filemap.c:3465
 generic\_file\_write\_iter+0xdb/0x230 mm/filemap.c:3497
 call\_write\_iter include/linux/fs.h:2039 \[inline\]
 do\_iter\_readv\_writev+0x46d/0x750 fs/read\_write.c:740
 do\_iter\_write+0x18c/0x710 fs/read\_write.c:866
 vfs\_writev+0x1db/0x6a0 fs/read\_write.c:939
 do\_pwritev fs/read\_write.c:1036 \[inline\]
 \_\_do\_sys\_pwritev fs/read\_write.c:1083 \[inline\]
 \_\_se\_sys\_pwritev fs/read\_write.c:1078 \[inline\]
 \_\_x64\_sys\_pwritev+0x235/0x310 fs/read\_write.c:1078
 do\_syscall\_64+0x30/0x40 arch/x86/entry/common.c:46
 entry\_SYSCALL\_64\_after\_hwframe+0x67/0xd1

Found by Linux Verification Center (linuxtesting.org) with Syzkaller.

## Affected and fixed versions

- Linux: \>= 2f785402f39b96a077b6e62bf26164bfb8e0c980, \< 7e860296d7808de1db175c1eda29f94a2955dcc4; \>= 2f785402f39b96a077b6e62bf26164bfb8e0c980, \< d96e6451a8d0fe62492d4cc942d695772293c05a; \>= 2f785402f39b96a077b6e62bf26164bfb8e0c980, \< f41c625328777f9ad572901ba0b0065bb9c9c1da; \>= 2f785402f39b96a077b6e62bf26164bfb8e0c980, \< 38d767fb4a7766ec2058f97787e4c6e8d10343d6; \>= 2f785402f39b96a077b6e62bf26164bfb8e0c980, \< cd42ddddd70abc7127c12b96c8c85dbd080ea56f; \>= 2f785402f39b96a077b6e62bf26164bfb8e0c980, \< d1b81776f337a9b997f797c70ac0a26d838a2168; \>= 2f785402f39b96a077b6e62bf26164bfb8e0c980, \< 042fa922c84b5080401bcd8897d4ac4919d15075; \>= 2f785402f39b96a077b6e62bf26164bfb8e0c980, \< 2b6d96503255a3ed676cd70f8368870c6d6a25c6 (cvelist)
- Linux: 2.6.18 (cvelist)

## Mitigation

- Upgrade Linux to 2b6d96503255a3ed676cd70f8368870c6d6a25c6 or later.

## Check your systems with an agent

Paste this into a coding agent:

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

Details: https://flawdb.com/CVE-2025-38328.md
Affected: Linux >= 2f785402f39b96a077b6e62bf26164bfb8e0c980, < 7e860296d7808de1db175c1eda29f94a2955dcc4; >= 2f785402f39b96a077b6e62bf26164bfb8e0c980, < d96e6451a8d0fe62492d4cc942d695772293c05a; >= 2f785402f39b96a077b6e62bf26164bfb8e0c980, < f41c625328777f9ad572901ba0b0065bb9c9c1da; >= 2f785402f39b96a077b6e62…
Fixed in: Linux 7e860296d7808de1db175c1eda29f94a2955dcc4, Linux 38d767fb4a7766ec2058f97787e4c6e8d10343d6, Linux 042fa922c84b5080401bcd8897d4ac4919d15075, Linux 2b6d96503255a3ed676cd70f8368870c6d6a25c6

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-2025-38328 being exploited?

There is no confirmed exploitation: CVE-2025-38328 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-26).

### How serious is CVE-2025-38328?

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

### Which versions are affected by CVE-2025-38328?

Linux \>= 2f785402f39b96a077b6e62bf26164bfb8e0c980, \< 7e860296d7808de1db175c1eda29f94a2955dcc4; \>= 2f785402f39b96a077b6e62bf26164bfb8e0c980, \< d96e6451a8d0fe62492d4cc942d695772293c05a; \>= 2f785402f39b96a077b6e62bf26164bfb8e0c980, \< f41c625328777f9ad572901ba0b0065bb9c9c1da; \>= 2f785402f39b96a077b6e62bf26164bfb8e0c980, \< 38d767fb4a7766ec2058f97787e4c6e8d10343d6; \>= 2f785402f39b96a077b6e62bf26164bfb8e0c980, \< cd42ddddd70abc7127c12b96c8c85dbd080ea56f; \>= 2f785402f39b96a077b6e62bf26164bfb8e0c980, \< d1b81776f337a9b997f797c70ac0a26d838a2168; \>= 2f785402f39b96a077b6e62bf26164bfb8e0c980, \< 042fa922c84b5080401bcd8897d4ac4919d15075; \>= 2f785402f39b96a077b6e62bf26164bfb8e0c980, \< 2b6d96503255a3ed676cd70f8368870c6d6a25c6; Linux 2.6.18.

### Is there a fix for CVE-2025-38328?

Yes. Fixed in Linux 7e860296d7808de1db175c1eda29f94a2955dcc4, Linux 38d767fb4a7766ec2058f97787e4c6e8d10343d6, Linux 042fa922c84b5080401bcd8897d4ac4919d15075, Linux 2b6d96503255a3ed676cd70f8368870c6d6a25c6. Upgrade Linux to 2b6d96503255a3ed676cd70f8368870c6d6a25c6 or later.

### How do I check if I'm affected by CVE-2025-38328?

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/7e860296d7808de1db175c1eda29f94a2955dcc4>
- patch: <https://git.kernel.org/stable/c/d96e6451a8d0fe62492d4cc942d695772293c05a>
- patch: <https://git.kernel.org/stable/c/f41c625328777f9ad572901ba0b0065bb9c9c1da>
- patch: <https://git.kernel.org/stable/c/38d767fb4a7766ec2058f97787e4c6e8d10343d6>
- patch: <https://git.kernel.org/stable/c/cd42ddddd70abc7127c12b96c8c85dbd080ea56f>
- patch: <https://git.kernel.org/stable/c/d1b81776f337a9b997f797c70ac0a26d838a2168>
- patch: <https://git.kernel.org/stable/c/042fa922c84b5080401bcd8897d4ac4919d15075>
- patch: <https://git.kernel.org/stable/c/2b6d96503255a3ed676cd70f8368870c6d6a25c6>
- other: <https://lists.debian.org/debian-lts-announce/2025/10/msg00008.html>
- other: <https://lists.debian.org/debian-lts-announce/2025/10/msg00007.html>

## 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-2025-38328>

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