# CVE-2026-123974: pytorch/serve: Local privilege escalation through insecure temporary path

Status: published. Published: 2026-11-06. Updated: 2026-11-06.

In all versions of PyTorch's TorchServe, a predictable extraction directory in /tmp lets a local user swap the model handler and run code as the TorchServe service account leading to local privilege escalation.

## Remediation

- fix: The project is archived and currently no permanent solution is scheduled for release. See workaround section. (source: CNA: Akrites)
- workaround: Three independent fixes:


  *  Set TEMP (or pass -Djava.io.tmpdir) to a directory the service account owns and that is not world-writable.
  *  Harden the systemd unit with PrivateTmp=yes, so /tmp is namespaced per service.
  *  At the code level, extract into a directory owned by the service account and refuse to reuse a pre-existing extraction root that the service does not own, instead of forceMkdir-ing into whatever is already there. (source: CNA: Akrites)

## Affected products and versions

- PyTorch / TorchServe: ≥ 0; < * (affected, semver). Source: CNA: Akrites

## Severity and prioritization

- CVSS 3.1: 7.8 (high); CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H; source: CNA: Akrites

- CISA KEV: No listing in collected sources

- EPSS: Not available

- SSVC: exploitation poc; automatable no; technical impact total; source ADP: CISA-ADP

- Weaknesses: CWE-379

## Exploit evidence

No exploit evidence in collected sources. This is not proof of no exploitation.

## References

- https://christbowel.com/blog/torchserve-lpe/ (CNA: Akrites)

- https://github.com/Christbowel/torchserve-lpe (CNA: Akrites)

## Provenance

- CNA: Akrites: https://www.cve.org/CVERecord?id=CVE-2026-123974; retrieved 2026-11-06; source updated 2026-11-06

Revision: bb28d4c23745fc6cf1eb9073a05d61c3f88efbc52e1266ca31f935b9ba128d15

Canonical: https://y2.dev/cve/CVE-2026-123974

## Agent and API access

Public CVE pages, Markdown, and JSON are free to read without an account or API key.

- Public catalog: https://y2.dev/cve/index.json. Follow nextCursor with the same search, filters, sort, and limit (1–100). A null cursor marks the end.

- WebMCP: search_cve_disclosures, get_cve_disclosure, get_cve_page_markdown, get_y2_cve_access. Available in compatible browsers.

- Cyber API: https://api.y2.dev/api/v2/cyber/cves and https://api.y2.dev/api/v2/cyber/cves/{cveId}.

- Y2 Pro or Elite: create a workspace API key with the intel:cyber scope and send Authorization: Bearer <Y2_API_KEY>. Setup: https://y2.dev/docs/api/create-key.

- x402: Pay per request without an account or API key. Omit Authorization, read the HTTP 402 PAYMENT-REQUIRED challenge, validate its current requirements, and retry with PAYMENT-SIGNATURE through an authorized payment client. These browser tools never make payments. Guide: https://y2.dev/docs/api/x402.

- OpenAPI: https://y2.dev/api/openapi.yaml. Agent access metadata: https://y2.dev/cve/agent.json.

Collected public records only. Check source status for coverage and freshness.