# CVE-2024-39301: net/9p: fix uninit-value in p9\_client\_rpc()

> 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.31% (percentile 16, 2026-11-26)
- **CWE:** CWE-665
- **Published:** 2024-06-25T14:22:41.566Z
- **Modified:** 2026-06-17T07:41:40.387Z

## Who should check

- Anyone running Linux \>= 348b59012e5c6402741d067cf6eeeb6271999d06, \< 72c5d8e416ecc46af370a1340b3db5ff0b0cc867; \>= 348b59012e5c6402741d067cf6eeeb6271999d06, \< 2101901dd58c6da4924bc5efb217a1d83436290b; \>= 348b59012e5c6402741d067cf6eeeb6271999d06, \< 124947855564572713d705a13be7d0c9dae16a17; \>= 348b59012e5c6402741d067cf6eeeb6271999d06, \< 89969ffbeb948ffc159d19252e7469490103011b; \>= 348b59012e5c6402741d067cf6eeeb6271999d06, \< ca71f204711ad24113e8b344dc5bb8b0385f5672; \>= 348b59012e5c6402741d067cf6eeeb6271999d06, \< 6c1791130b781c843572fb6391c4a4c5d857ab17; \>= 348b59012e5c6402741d067cf6eeeb6271999d06, \< fe5c604053c36c62af24eee8a76407d026ea5163; \>= 348b59012e5c6402741d067cf6eeeb6271999d06, \< 25460d6f39024cc3b8241b14c7ccf0d6f11a736a
- Anyone running Linux 3.2

## Description

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

net/9p: fix uninit-value in p9\_client\_rpc()

Syzbot with the help of KMSAN reported the following error:

BUG: KMSAN: uninit-value in trace\_9p\_client\_res include/trace/events/9p.h:146 \[inline\]
BUG: KMSAN: uninit-value in p9\_client\_rpc+0x1314/0x1340 net/9p/client.c:754
 trace\_9p\_client\_res include/trace/events/9p.h:146 \[inline\]
 p9\_client\_rpc+0x1314/0x1340 net/9p/client.c:754
 p9\_client\_create+0x1551/0x1ff0 net/9p/client.c:1031
 v9fs\_session\_init+0x1b9/0x28e0 fs/9p/v9fs.c:410
 v9fs\_mount+0xe2/0x12b0 fs/9p/vfs\_super.c:122
 legacy\_get\_tree+0x114/0x290 fs/fs\_context.c:662
 vfs\_get\_tree+0xa7/0x570 fs/super.c:1797
 do\_new\_mount+0x71f/0x15e0 fs/namespace.c:3352
 path\_mount+0x742/0x1f20 fs/namespace.c:3679
 do\_mount fs/namespace.c:3692 \[inline\]
 \_\_do\_sys\_mount fs/namespace.c:3898 \[inline\]
 \_\_se\_sys\_mount+0x725/0x810 fs/namespace.c:3875
 \_\_x64\_sys\_mount+0xe4/0x150 fs/namespace.c:3875
 do\_syscall\_64+0xd5/0x1f0
 entry\_SYSCALL\_64\_after\_hwframe+0x6d/0x75

Uninit was created at:
 \_\_alloc\_pages+0x9d6/0xe70 mm/page\_alloc.c:4598
 \_\_alloc\_pages\_node include/linux/gfp.h:238 \[inline\]
 alloc\_pages\_node include/linux/gfp.h:261 \[inline\]
 alloc\_slab\_page mm/slub.c:2175 \[inline\]
 allocate\_slab mm/slub.c:2338 \[inline\]
 new\_slab+0x2de/0x1400 mm/slub.c:2391
 \_\_\_slab\_alloc+0x1184/0x33d0 mm/slub.c:3525
 \_\_slab\_alloc mm/slub.c:3610 \[inline\]
 \_\_slab\_alloc\_node mm/slub.c:3663 \[inline\]
 slab\_alloc\_node mm/slub.c:3835 \[inline\]
 kmem\_cache\_alloc+0x6d3/0xbe0 mm/slub.c:3852
 p9\_tag\_alloc net/9p/client.c:278 \[inline\]
 p9\_client\_prepare\_req+0x20a/0x1770 net/9p/client.c:641
 p9\_client\_rpc+0x27e/0x1340 net/9p/client.c:688
 p9\_client\_create+0x1551/0x1ff0 net/9p/client.c:1031
 v9fs\_session\_init+0x1b9/0x28e0 fs/9p/v9fs.c:410
 v9fs\_mount+0xe2/0x12b0 fs/9p/vfs\_super.c:122
 legacy\_get\_tree+0x114/0x290 fs/fs\_context.c:662
 vfs\_get\_tree+0xa7/0x570 fs/super.c:1797
 do\_new\_mount+0x71f/0x15e0 fs/namespace.c:3352
 path\_mount+0x742/0x1f20 fs/namespace.c:3679
 do\_mount fs/namespace.c:3692 \[inline\]
 \_\_do\_sys\_mount fs/namespace.c:3898 \[inline\]
 \_\_se\_sys\_mount+0x725/0x810 fs/namespace.c:3875
 \_\_x64\_sys\_mount+0xe4/0x150 fs/namespace.c:3875
 do\_syscall\_64+0xd5/0x1f0
 entry\_SYSCALL\_64\_after\_hwframe+0x6d/0x75

If p9\_check\_errors() fails early in p9\_client\_rpc(), req-\>rc.tag
will not be properly initialized. However, trace\_9p\_client\_res()
ends up trying to print it out anyway before p9\_client\_rpc()
finishes.

Fix this issue by assigning default values to p9\_fcall fields
such as 'tag' and (just in case KMSAN unearths something new) 'id'
during the tag allocation stage.

## Affected and fixed versions

- Linux: \>= 348b59012e5c6402741d067cf6eeeb6271999d06, \< 72c5d8e416ecc46af370a1340b3db5ff0b0cc867; \>= 348b59012e5c6402741d067cf6eeeb6271999d06, \< 2101901dd58c6da4924bc5efb217a1d83436290b; \>= 348b59012e5c6402741d067cf6eeeb6271999d06, \< 124947855564572713d705a13be7d0c9dae16a17; \>= 348b59012e5c6402741d067cf6eeeb6271999d06, \< 89969ffbeb948ffc159d19252e7469490103011b; \>= 348b59012e5c6402741d067cf6eeeb6271999d06, \< ca71f204711ad24113e8b344dc5bb8b0385f5672; \>= 348b59012e5c6402741d067cf6eeeb6271999d06, \< 6c1791130b781c843572fb6391c4a4c5d857ab17; \>= 348b59012e5c6402741d067cf6eeeb6271999d06, \< fe5c604053c36c62af24eee8a76407d026ea5163; \>= 348b59012e5c6402741d067cf6eeeb6271999d06, \< 25460d6f39024cc3b8241b14c7ccf0d6f11a736a (cvelist)
- Linux: 3.2 (cvelist)

## Mitigation

- Upgrade Linux to 25460d6f39024cc3b8241b14c7ccf0d6f11a736a or later.

## Check your systems with an agent

Paste this into a coding agent:

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

Details: https://flawdb.com/CVE-2024-39301.md
Affected: Linux >= 348b59012e5c6402741d067cf6eeeb6271999d06, < 72c5d8e416ecc46af370a1340b3db5ff0b0cc867; >= 348b59012e5c6402741d067cf6eeeb6271999d06, < 2101901dd58c6da4924bc5efb217a1d83436290b; >= 348b59012e5c6402741d067cf6eeeb6271999d06, < 124947855564572713d705a13be7d0c9dae16a17; >= 348b59012e5c6402741d067…
Fixed in: Linux 72c5d8e416ecc46af370a1340b3db5ff0b0cc867, Linux 2101901dd58c6da4924bc5efb217a1d83436290b, Linux 124947855564572713d705a13be7d0c9dae16a17, Linux 89969ffbeb948ffc159d19252e7469490103011b, Linux 6c1791130b781c843572fb6391c4a4c5d857ab17, Linux 25460d6f39024cc3b8241b14c7ccf0d6f11a736a

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-2024-39301 being exploited?

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

### How serious is CVE-2024-39301?

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

### Which versions are affected by CVE-2024-39301?

Linux \>= 348b59012e5c6402741d067cf6eeeb6271999d06, \< 72c5d8e416ecc46af370a1340b3db5ff0b0cc867; \>= 348b59012e5c6402741d067cf6eeeb6271999d06, \< 2101901dd58c6da4924bc5efb217a1d83436290b; \>= 348b59012e5c6402741d067cf6eeeb6271999d06, \< 124947855564572713d705a13be7d0c9dae16a17; \>= 348b59012e5c6402741d067cf6eeeb6271999d06, \< 89969ffbeb948ffc159d19252e7469490103011b; \>= 348b59012e5c6402741d067cf6eeeb6271999d06, \< ca71f204711ad24113e8b344dc5bb8b0385f5672; \>= 348b59012e5c6402741d067cf6eeeb6271999d06, \< 6c1791130b781c843572fb6391c4a4c5d857ab17; \>= 348b59012e5c6402741d067cf6eeeb6271999d06, \< fe5c604053c36c62af24eee8a76407d026ea5163; \>= 348b59012e5c6402741d067cf6eeeb6271999d06, \< 25460d6f39024cc3b8241b14c7ccf0d6f11a736a; Linux 3.2.

### Is there a fix for CVE-2024-39301?

Yes. Fixed in Linux 72c5d8e416ecc46af370a1340b3db5ff0b0cc867, Linux 2101901dd58c6da4924bc5efb217a1d83436290b, Linux 124947855564572713d705a13be7d0c9dae16a17, Linux 89969ffbeb948ffc159d19252e7469490103011b, Linux 6c1791130b781c843572fb6391c4a4c5d857ab17, Linux 25460d6f39024cc3b8241b14c7ccf0d6f11a736a. Upgrade Linux to 25460d6f39024cc3b8241b14c7ccf0d6f11a736a or later.

### How do I check if I'm affected by CVE-2024-39301?

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/72c5d8e416ecc46af370a1340b3db5ff0b0cc867>
- patch: <https://git.kernel.org/stable/c/2101901dd58c6da4924bc5efb217a1d83436290b>
- patch: <https://git.kernel.org/stable/c/124947855564572713d705a13be7d0c9dae16a17>
- patch: <https://git.kernel.org/stable/c/89969ffbeb948ffc159d19252e7469490103011b>
- patch: <https://git.kernel.org/stable/c/ca71f204711ad24113e8b344dc5bb8b0385f5672>
- patch: <https://git.kernel.org/stable/c/6c1791130b781c843572fb6391c4a4c5d857ab17>
- patch: <https://git.kernel.org/stable/c/fe5c604053c36c62af24eee8a76407d026ea5163>
- patch: <https://git.kernel.org/stable/c/25460d6f39024cc3b8241b14c7ccf0d6f11a736a>

## 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-2024-39301>

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