CVE-2026-40505
Description
MuPDF before 1.27 contains an ANSI injection vulnerability in mutool that allows attackers to inject arbitrary ANSI escape sequences through crafted PDF metadata fields. Attackers can embed malicious ANSI escape codes in PDF metadata that are passed unsanitized to terminal output when running mutool info, enabling them to manipulate terminal display for social engineering attacks such as presenting fake prompts or spoofed commands.
Predictions
Heuristic predictions, AS-IS, for prioritization only.
Mitigations
No mitigations published for this CVE yet.
The vendor-content worker queues fetches as references arrive (check back in a few minutes). Or โ if you've already worked around this in production โ publish your fix to the community-verified tier.
โ Propose a mitigation on Community โ Mitigations published via the community go through AI scoring + 2 human reviewers + 7-day silent objection window before landing here withsource_tier=community-verified.
OS impact
Debian Mixed 5 releases
| Version | Status | Fixed in |
|---|---|---|
| trixie | Affected | โ |
| sid | Fixed | 1.27.0+ds1-5 |
| forky | Fixed | 1.27.0+ds1-5 |
| bullseye | Affected | โ |
| bookworm | Affected | โ |
Application impact
| Vendor | Product | Versions | Fixed |
|---|---|---|---|
| artifex | mupdf | {"endExcluding":"1.27.0"} | 1.27.0 |
References
- https://cgit.ghostscript.com/cgi-bin/cgit.cgi/mupdf.git/commit/?id=0f17d789fe8c29b41e47663be82514aaca3a4dfb
- https://github.com/ArtifexSoftware/mupdf/commit/0f17d789fe8c29b41e47663be82514aaca3a4dfb
- https://github.com/ArtifexSoftware/mupdf/releases/tag/1.27.0
- https://www.vulncheck.com/advisories/mupdf-mutool-ansi-injection-via-metadata
- https://security-tracker.debian.org/tracker/CVE-2026-40505
CWEs
CWE-150
Community-verified mitigations for this CVE will appear above when contributors publish them.
Verify integrity in audit chain (admin only). AS-IS.