Description
Insecure Temporary File vulnerability in Mix deps.partition in Elixir allows a local user to execute code as another user via a swapped partition config file. Partitioned dependency compilation passes the project configuration to each partition VM through a file in a fixed-name directory under the shared system temporary directory, and the partition trusts what it reads back. Another local user on the same host can exploit this during a mix deps.compile run that uses partitioned compilation.

Mix.Tasks.Deps.Partition.server/4 in lib/mix/lib/mix/tasks/deps.partition.ex creates the directory with File.mkdir_p/1, which accepts an existing directory without checking its owner, so a user who created it first can replace the file before client/0 reads it.

This issue affects mix: from 1.20.0-rc.4 before 1.20.5.
Published: 2026-10-30
Score: 5.4 Medium
EPSS: n/a
KEV: No
Impact: Local Privilege Escalation
Action: Patch
AI Analysis

Impact

In the Mix dependency compilation system, a hash of project configuration is written to a file in a temporary directory that is shared across all partitions. Because the directory creation step does not verify ownership, a local user can create or replace that file before the worker processes read it. This allows the attacker to insert arbitrary code that will be executed as the owner of the target user, effectively giving the attacker the ability to run code as that user. The flaw is a classic insecure temporary file vulnerability and is classified as CWE-377.

Affected Systems

The vulnerability affects the Elixir programming language, specifically Elixir’s Mix tool, from version 1.20.0‑rc.4 up to and including 1.20.4. It is relevant to any system that runs Elixir Mix tasks for dependency compilation on a multi‑user host.

Risk and Exploitability

The CVSS base score is 5.4, indicating moderate severity. No EPSS score is currently available, and the vulnerability is not listed in the CISA KEV catalog, suggesting that there have not been widely reported exploits yet. The likely attack vector requires the attacker to have a user account on the same host and to be able to run Mix commands, making it a local privilege escalation scenario.

Generated by OpenCVE AI on October 30, 2026 at 10:50 UTC.

Remediation

Vendor Workaround

On a multi-user host, set TMPDIR to a private per-user directory with mode 0700 before running Mix, so that System.tmp_dir/0 resolves to a location other users cannot pre-create or read. Alternatively, keep partitioned compilation disabled by leaving MIX_OS_DEPS_COMPILE_PARTITION_COUNT unset or at 1, which keeps the configuration inside the parent process.


OpenCVE Recommended Actions

  • Upgrade to Elixir 1.20.5 or newer to receive the official fix.
  • On multi‑user hosts, set the TMPDIR environment variable to a per‑user directory with permissions 0700 before invoking Mix so that temporary files cannot be tampered with by other users.
  • Disable partitioned compilation by leaving MIX_OS_DEPS_COMPILE_PARTITION_COUNT unset or setting it to 1, which keeps configuration inside the parent process and removes the vulnerable file.

Generated by OpenCVE AI on October 30, 2026 at 10:50 UTC.

Tracking

Sign in to view the affected projects.

Advisories

No advisories yet.

History

Fri, 30 Oct 2026 09:15:00 +0000

Type Values Removed Values Added
Description Insecure Temporary File vulnerability in Mix deps.partition in Elixir allows a local user to execute code as another user via a swapped partition config file. Partitioned dependency compilation passes the project configuration to each partition VM through a file in a fixed-name directory under the shared system temporary directory, and the partition trusts what it reads back. Another local user on the same host can exploit this during a mix deps.compile run that uses partitioned compilation. Mix.Tasks.Deps.Partition.server/4 in lib/mix/lib/mix/tasks/deps.partition.ex creates the directory with File.mkdir_p/1, which accepts an existing directory without checking its owner, so a user who created it first can replace the file before client/0 reads it. This issue affects mix: from 1.20.0-rc.4 before 1.20.5.
Title Insecure temporary file in mix deps.partition lets a local user execute code in another user's dependency build
First Time appeared Elixir-lang
Elixir-lang elixir
Weaknesses CWE-377
CPEs cpe:2.3:a:elixir-lang:elixir:*:*:*:*:*:*:*:*
Vendors & Products Elixir-lang
Elixir-lang elixir
References
Metrics cvssV4_0

{'score': 5.4, 'vector': 'CVSS:4.0/AV:L/AC:L/AT:P/PR:L/UI:P/VC:H/VI:H/VA:H/SC:N/SI:N/SA:N'}


Subscriptions

Elixir-lang Elixir
cve-icon MITRE

Status: PUBLISHED

Assigner: EEF

Published:

Updated: 2026-10-30T09:01:05.212Z

Reserved: 2026-10-14T21:45:01.541Z

Link: CVE-2026-97209

cve-icon Vulnrichment

No data.

cve-icon NVD

Status : Received

Published: 2026-10-30T09:17:15.640

Modified: 2026-10-30T09:17:15.640

Link: CVE-2026-97209

cve-icon Redhat

No data.

cve-icon OpenCVE Enrichment

Updated: 2026-10-30T11:15:11Z

Weaknesses