Phantom audio: Phantom: Arbitrary file write and decode-bomb DoS via unconfined MCP tool paths
Affects phantom-audioSource GCVE Database
Mentioned vulnerabilities
CVSS 7.7 High : upgrade to 1.3.1 soon.
Data as of 10 Jul 2026, 09:29 UTC
- Patch
- Available – fixed in 1.3.1
CVSS:3.1/AV:L/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:NWhat to do
Upgrade phantom-audio to 1.3.1.
Affected software
| Product | Affected | Fixed in |
|---|---|---|
| PyPIphantom-audio | Affected
| Fixed in
|
Check your own hosts for these packages with threat-finder (opens in a new tab), our free open-source scanner.
AI-suggested
A fix is available in Phantom version 1.3.1. Users should upgrade to 1.3.1 or later to ensure file writes are confined to PHANTOM_OUTPUT_DIR and decode operations have appropriate size and duration limits. As a workaround before upgrading, set PHANTOM_OUTPUT_DIR (and optionally PHANTOM_AUDIO_DIR) to dedicated directories prior to starting the server to limit exposure.
Description
### Impact In Phantom <= 1.3.0, when `PHANTOM_OUTPUT_DIR` was unset (the default), the MCP tools accepted arbitrary absolute output paths with no confinement. Anything able to send tool calls (e.g. an AI agent driving the MCP interface) could **write or overwrite arbitrary files** the process user can write — including shell startup files (`~/.zshrc`) or a Reaper `__startup.lua`, which is effectively local code execution on a developer workstation. Separately, the stem-separation and render paths decoded input audio with no size/duration cap (the analysis path was already guarded). A small, highly compressed FLAC/OGG could expand to multi-gigabyte PCM, causing memory-exhaustion DoS, and widened exposure to decoder bugs including libsndfile CVE-2026-37555. ### Patches Fixed in **1.3.1**: - File writes are always confined to `PHANTOM_OUTPUT_DIR` (default `~/.phantom/output`); symlinks resolved and re-verified on the final path. - Decode/duration/size guards mirrored onto the separation and render paths (plus ffmpeg `-max_alloc`/`-t`/`-fs`). - Atomic `O_CREAT|O_EXCL` output creation in reference matching and symlink-TOCTOU hardening on confined input reads. ### Workarounds Set `PHANTOM_OUTPUT_DIR` (and optionally `PHANTOM_AUDIO_DIR`) to dedicated directories before starting the server. ### Credit Found during an internal security audit.