CVE-2026-137551: Frappe before 16.36.0 Jinja Sandbox Bypass via Module-Path Hooks
Frappe Framework before 15.121.2 and 16.x before 16.36.0 exposes functions imported into module-path-hooked modules as Jinja globals, making them callable from sandboxed templates. Authenticated users who can author rendered templates, such as Print Formats, can invoke these functions by name to achieve server-side code execution that bypasses the Jinja sandbox.
Affected Software
Event History
Frequently Asked Questions
Who is realistically exposed to this issue?
Frappe Framework deployments before 15.121.2 and 16.x before 16.36.0 are affected if authenticated users can author templates that are rendered by the application, such as Print Formats.
What access does an attacker need to exploit it?
An attacker needs an authenticated account with permission to create or modify rendered templates. No user interaction is required after the attacker can author a template.
What is the impact of successful exploitation?
The attacker can call functions exposed as Jinja globals from a sandboxed template, bypassing the Jinja sandbox and achieving server-side code execution. This can affect confidentiality, integrity, and availability.