Skip to main content

Docutils CVE-2026-144963

| EUVDEUVD-2026-144250 HIGH
Improper Neutralization of Special Elements in Output Used by a Downstream Component ('Injection') (CWE-74)
2026-12-04 VulnCheck GHSA-c3cf-rq9c-2hg9
8.2
CVSS 4.0 · Vendor: VulnCheck
View

Attack ChainAIDerived

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

  1. Access
    Submit crafted reStructuredText to rST-to-LaTeX converter
  2. Exploit
    Inject TeX macro via percent-encoded image URI
  3. Execution
    LaTeX compiler executes injected \input on local file
  4. Impact
    Local file contents embedded in compiled output

Vulnerability Assessment

Weakness
CWE
OWASP Top 10:2025
A05:2025 - Injection
ASVS 5.0
V1 - Encoding and Sanitization Input neutralization, injection prevention
Exploitation Conditions

Exploitation requires a target workflow that passes attacker-controlled reStructuredText through the docutils latex2e (LaTeX) writer AND then compiles the resulting TeX with a LaTeX engine; the injected \input macro discloses local files readable by that compiler into the output the attacker can observe. Critically, per the description this bypasses the raw_enabled and file_insertion_enabled settings being disabled, so those hardening options do NOT mitigate it. Limiting factors: the deployment must both convert untrusted rST to LaTeX and compile it (pure HTML rendering is unaffected), the attacker must be able to retrieve the compiled output to read disclosed content, and the AC:H/AT:P metrics reflect the non-trivial URI crafting required. The only complete fix stated in the evidence is updating to docutils 0.23.1.

Impact

This is a genuine but conditional issue rather than a drop-everything emergency. The CVSS 4.0 vector (AV:N/AC:H/AT:P/PR:N/UI:N) describes a network-reachable, unauthenticated flaw, but with high attack complexity (AC:H) and a present attack requirement (AT:P), meaning exploitation is not trivially universal - it depends on specific crafting and a vulnerable processing workflow. Impact is confidentiality-only (VC:H, VI:N, VA:N, no scope change): local file disclosure into compiled output, not code execution or integrity/availability loss. The vuln.today priority is 'this_week' and the vendor patch is available. There is no CISA KEV listing and no EPSS score was supplied, so there is no signal of active or widespread exploitation; no public exploit code was identified in the input either. The references are patch/advisory material (VulnCheck advisory, the fixing commit, and source lines), not working exploit code. Net: a real, patchable confidentiality vulnerability worth remediating promptly for anyone compiling untrusted reStructuredText to LaTeX/PDF, but its AC:H/AT:P profile and confidentiality-only impact place it below network RCE-class emergencies. Note the signals are consistent (no KEV, no EPSS, this_week priority, confidentiality-only) - no major conflicts, though the absence of EPSS/POC data means exploitation likelihood cannot be quantified.

Exploit ScenarioDerived

A service that renders user-submitted reStructuredText to PDF via the docutils LaTeX writer accepts attacker content containing a percent-encoded image URI. The attacker closes the \includegraphics argument and injects an \input macro so that at TeX compile time the contents of a local file (e.g. a secret or config file readable by the compiler) are embedded into the generated output, which the attacker then retrieves. No public exploit code was identified, but the technique is documented in the VulnCheck advisory and the fixing commit.

This Week Schedule remediation this week. Why: HIGH severity (CVSS 7.0-8.9).
Patch available

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

Alert me

AnalysisAIv1 – Dec 04, 2026

TeX macro injection in the Docutils LaTeX writer lets attackers who supply reStructuredText smuggle an \input macro into compiled output via percent-encoded image URIs, closing the includegraphics argument to break out of the intended URI context. Versions before 0.23.1 are affected, and the technique embeds local files readable by the LaTeX compiler into the produced document - notably even when raw_enabled and file_insertion_enabled are turned off, so those hardening settings do not mitigate it. Exploitation is conditional: the workflow must convert untrusted rST to LaTeX and then compile it, and the attacker must be able to retrieve the compiled output, which is why the assessed severity reflects high attack complexity; no public exploit code or active exploitation is confirmed in the available data, and a vendor fix exists in 0.23.1.

RemediationAI

Upgrade to Docutils 0.23.1, the only complete fix stated in the evidence (PyPI: https://pypi.org/project/docutils/0.23.1/; patch commit: https://github.com/docutils/docutils/commit/d5a9b02bc34e5137fcb333dc1e26835f14c02587); the vendor patch causes image URIs containing a backslash, '^^' or unbalanced braces to raise an error instead of emitting LaTeX, so documents relying on such URIs may now fail to render and will need corrected image paths. Do not rely on disabling raw_enabled or file_insertion_enabled as a workaround - the evidence states the injection works even with those settings off. Where upgrading is not immediately possible, the actionable compensating control is to stop passing untrusted reStructuredText through the latex2e writer and compiling the result: render untrusted input to HTML only, or run LaTeX conversion only on trusted, vetted sources, since the flaw is unreachable without both steps. Note the trade-off that this removes LaTeX/PDF generation for untrusted content; additionally, restricting which files the LaTeX compiler can read (e.g. a confined build environment) limits the impact of any successful \input but does not fix the injection itself.

Affected VersionsENISA

Docutils 0 <0.23.1

Affected Packages

euvd docutils fix: 0.23.1

Source: OSV (Open Source Vulnerabilities)

Affects your stack

Affects 1 package in euvd

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

Technical ContextAI · show details

Docutils is a Python library for processing reStructuredText into formats such as HTML and LaTeX. The latex2e writer builds LaTeX source from image directives, placing the image URI inside an \includegraphics argument; the pre-0.23.1 code did not validate the URI for characters that can terminate or alter that argument. The root cause class is CWE-74 (improper neutralization of special elements in output used by a downstream component), i.e. injection into the generated TeX. Percent-encoded URI sequences are decoded before being written into the LaTeX output, allowing a crafted URI to escape the includegraphics argument and introduce an \input macro that pulls a local file into the compiled document. The upstream fix in commit d5a9b02 adds checks in docutils/writers/latex2e/__init__.py::visit_image that reject image URIs containing a backslash, the '^^' sequence, or unbalanced braces, emitting an error instead of generating the LaTeX; the commit also adjusts system-message backref handling for the zero-backref case. Tests added in test_writers/test_latex2e.py cover brace, backslash and double-caret URIs. The assessed vector (AV:N/AC:H/PR:N/UI:N, confidentiality-only impact) indicates remote, unauthenticated triggering but with high complexity tied to the crafted URI work; the trigger mechanism is specifically the image-URI path described above, not a generic parsing flaw in all writers.

Know when Docutils 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 (VulnCheck) PRIMARY 8.2 HIGH
CVSS:4.0/AV:N/AC:H/AT:P/PR:N/UI:N/VC:H/VI:N/VA:N/SC:N/SI:N/SA:N
vuln.today AI 5.9 MEDIUM

Unauthenticated remote rST supply (PR:N) but requires a convert-then-compile LaTeX workflow plus crafted percent-encoded URI (AC:H); impact is local file disclosure only, so C:H, I:N, A:N.

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

Primary rating from Vendor (VulnCheck).

CVSS VectorVendor: VulnCheck

Attack Vector
Network
Attack Complexity
High
Attack Requirements
Present
Privileges Required
None
User Interaction
None
Vulnerable system: Confidentiality
High
Vulnerable system: Integrity
None
Vulnerable system: Availability
None
Subsequent system: Confidentiality
None
Subsequent system: Integrity
None
Subsequent system: Availability
None

DescriptionCVE.org

Docutils before 0.23.1 contains a TeX injection vulnerability in the LaTeX writer that allows attackers supplying reStructuredText to inject TeX macros via percent-encoded image URIs. Attackers can close the includegraphics argument and inject an input macro, embedding local files into compiled output even with raw_enabled and file_insertion_enabled disabled.

Executive ViewAI

Why It Matters

CVE-2026-144963 is a high-severity TeX macro injection flaw in Docutils versions before 0.23.1. It affects organizations that convert untrusted reStructuredText into LaTeX and then compile it, allowing an attacker to embed local files into the compiled document that the attacker can later retrieve. Leadership should care because this can lead to unauthorized disclosure of sensitive files, but exploitation requires a specific workflow and high attack complexity, and no active exploitation has been confirmed.

Business Impact: High
Compensating Controls

Apply vendor patch.

Threat Intelligence Overview

Prevalence
High
core reStructuredText library, dependency of Sphinx across the Python ecosystem
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 HIGH
CISA KEV No
Public POC No
EPSS N/A
Patch available Yes
Active threat No
Deciding rule
HIGH severity (CVSS 7.0-8.9)
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
Scheduled
Exploitation
None
System Exposure· derived
Open
Automatable
No
Human Impact
High
Technical Impact
Partial

Priority Score

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

Attack Technique

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.

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