Detect CVE-2026-33646: Mise Arbitrary Code Execution via Tera Template Injection in .tool-versions in Google Chronicle
Detects exploitation of CVE-2026-33646, a critical trust bypass vulnerability in mise (formerly rtx) versions prior to 2026.3.10. Attackers can embed Tera template directives inside .tool-versions files to achieve arbitrary code execution when mise processes the file, bypassing trust checks. CVSS 9.6. PoC public.
MITRE ATT&CK
- Tactic
- Execution Persistence Defense Evasion
YARA-L Detection Query
rule mise_tera_template_code_execution {
meta:
author = "df00tech detection engineering"
description = "Detects CVE-2026-33646: Tera template injection in .tool-versions processed by mise"
severity = "CRITICAL"
priority = "HIGH"
events:
$file_write.metadata.event_type = "FILE_CREATION" or $file_write.metadata.event_type = "FILE_MODIFICATION"
$file_write.target.file.full_path = /\.tool-versions$/
$file_write.principal.hostname = $host
$file_write.metadata.event_timestamp.seconds = $t1
$proc_exec.metadata.event_type = "PROCESS_LAUNCH"
($proc_exec.target.process.file.full_path = /\/mise$/ or
$proc_exec.target.process.file.full_path = /\\mise\.exe$/)
$proc_exec.principal.hostname = $host
$proc_exec.metadata.event_timestamp.seconds = $t2
condition:
$file_write and $proc_exec and
$t2 >= $t1 and
($t2 - $t1) <= 300
} Chronicle YARA-L 2.0 rule detecting .tool-versions file writes followed within 5 minutes by mise process launch on the same host, indicating possible CVE-2026-33646 exploitation.
Data Sources
Required Tables
False Positives & Tuning
- Automated developer environment setup scripts that create .tool-versions and invoke mise
- Containerized build environments that generate .tool-versions as part of image builds
- Legitimate software delivery pipelines using mise for toolchain management
Other platforms for CVE-2026-33646
Testing Methodology
Validate this detection against 4 adversary techniques from Atomic Red Team. Each test below lists the behaviour to exercise and the telemetry you should expect to see. Executable commands and cleanup steps are available with Pro.
- Test 1Inject Tera system() call into .tool-versions and invoke mise install
Expected signal: File write event for .tool-versions, followed by mise process launch, followed by child process executing 'id' or shell writing to /tmp/mise-pwned.txt
- Test 2Malicious .tool-versions via Git Clone Simulation
Expected signal: Directory creation, .tool-versions file write by shell (not interactive mise), then mise process launch with install argument
- Test 3mise trust bypass via template in project-local .tool-versions
Expected signal: osascript child process spawned from mise with suspicious arguments, .tool-versions read by mise process
- Test 4Enumerate environment variables via Tera template injection
Expected signal: File write of .tool-versions, mise process launch, child write to /tmp/mise-env-leak.txt containing environment variable value
Unlock Pro Content
Get the full detection package for CVE-2026-33646 including response playbook, investigation guide, and atomic red team tests.