Attack ChainAIDerived
Hypothetical attack flow derived from CVE metadata – not a confirmed exploit chain
-
ReconAuthenticate as limited ERPNext user
-
DeliveryReach template-rendering feature
-
ExploitInject malicious Jinja/SSTI payload
-
Installrender_template runs without restrict_globals
-
C2Escape safe_exec sandbox
-
ExecuteExecute OS commands as server user
-
ImpactFull host compromise
Vulnerability Assessment
| Weakness |
CWE
ASVS 5.0
V1 - Encoding and Sanitization Template injection prevention
|
| Exploitation Conditions | Requires an authenticated ERPNext account (PR:L) with the ability to supply or trigger rendering of Jinja template content through a Frappe feature that routes into safe_exec's render_safe_globals - for example custom print formats, email/notification templates, web templates/pages, or server scripts that call render_template. The limiting factor is that a fully anonymous, unauthenticated outsider cannot exploit this directly: an attacker must first hold at least a low-privilege ('limited') user role and reach a template-authoring or template-execution surface. No special non-default configuration is needed beyond having such users, and no victim interaction is required; any ERPNext instance before 15.111.0 / 16.22.0 that grants semi-trusted users template-editing capability is exposed. |
| Impact | The signals are largely aligned toward high priority: the CVSS 3.1 vector (AV:N/AC:L/PR:L/UI:N/S:C/C:H/I:H/A:H = 9.9) describes a network-reachable, low-complexity attack needing only limited privileges and no user interaction, with a scope change reflecting sandbox escape to full host compromise. SSTI leading to RCE is a well-understood, reliable exploitation class, so the modest PR:L barrier (any authenticated ERPNext user who can reach a template-rendering feature) is the main gating factor rather than a strong mitigant. No EPSS score is provided and the CVE is not in CISA KEV, and no POC is referenced, so there is no evidence of active or automated exploitation yet - but the patch commit is public, which materially lowers the effort to reconstruct a working exploit. Because ERPNext instances are frequently multi-tenant or exposed to semi-trusted internal users, any operator running a version prior to 15.111.0 or 16.22.0 should treat this as urgent and patch promptly rather than waiting for in-the-wild reports. |
| Exploit ScenarioDerived | A low-privileged ERPNext user with access to a feature that renders Jinja (such as a custom print format, notification template, or web template) injects a template payload like {{ ...os.popen('id')... }} that, once rendered by the unrestricted render_template inside safe_exec, executes attacker-controlled OS commands on the server. Because the vector is network-based with low complexity and no user interaction, the attacker only needs a valid limited account; no public POC is referenced, but the SSTI-to-RCE pattern is straightforward to weaponize from the public fix diff. |
Get an e-mail when this CVE is exploited, patched or re-scored. Free account.
Alert meAnalysisAIv1 – Aug 17, 2026
Server-side template injection in ERPNext (Frappe framework) lets low-privileged authenticated users escape the Frappe safe-execution sandbox and achieve remote code execution on the server. The root cause is that frappe.render_template was exposed inside the safe_exec globals without forcing restrict_globals, so a user who can supply template content crosses a permission boundary into unrestricted Jinja evaluation. Rated CVSS 9.9 with a scope change; no public exploit code or CISA KEV listing is identified at time of analysis, but the fix commit is public, narrowing the reversing effort required.
RemediationAI
Vendor-released patch: upgrade ERPNext to 15.111.0 (for 15.x deployments) or 16.22.0 (for 16.x deployments), which pull in the corrected Frappe render_template handling; ensure the bundled Frappe framework is updated alongside ERPNext so commit 529d190a is present. Follow the advisory at https://github.com/frappe/erpnext/security/advisories/GHSA-w996-r7v3-87wr. If you cannot patch immediately, reduce exposure by tightening who holds authenticated accounts and by restricting or disabling features that let non-admin users author or submit Jinja templates (for example custom print formats, notification/email templates, web page and web template records, and server-script or report contexts that call render_template); auditing and locking down these template-editing permissions is the most direct compensating control, with the trade-off that legitimate users who rely on custom print formats or notifications will lose self-service template editing until patched. Also place the ERP behind network access controls so only trusted users can reach the application, accepting that this does not protect against a malicious or compromised internal account.
Affected VersionsENISA
Affected Packages
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
ERPNext is built on the Frappe web framework, which offers a 'safe execution' sandbox (frappe/utils/safe_exec.py) for running user- or app-supplied Python and Jinja templates with a restricted global namespace. Jinja rendering in Frappe is normally hardened by a restrict_globals flag that strips dangerous callables from the template context. The vulnerability (CWE-1336, Server-Side Template Injection / improper neutralization of special elements in a template engine) arises because render_safe_globals() bound the raw frappe.render_template into the sandbox rather than a wrapper enforcing restrict_globals=True. The public fix (frappe commit 529d190a) introduces a safe_render_template shim that pops any caller-supplied restrict_globals and hard-codes restrict_globals=True, changes render_template's signature to make restrict_globals keyword-only (preventing positional bypass), and only re-exposes the unrestricted render_template inside the higher-trust exec_safe_globals path.
Know when Erpnext 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
AV:N/AC:L/PR:L/UI:N/S:C/C:H/I:H/A:H
Network-reachable SSTI needing only a low-privilege account (PR:L, AV:N, AC:L, no UI); sandbox escape to host justifies scope change and full C/I/A impact.
Primary rating from Vendor (GitHub_M).
CVSS VectorVendor: GitHub_M
Lifecycle Timeline
2DescriptionCVE.org
ERPNext is a free and open source Enterprise Resource Planning tool. Prior to 15.111.0 and 16.22.0, limited authenticated users can cross a permission boundary in Frappe safe execution because frappe.render_template is exposed without forcing restrict_globals, allowing server-side template injection and remote code execution. This issue is fixed in versions 15.111.0 and 16.22.0.
Executive ViewAI
ERPNext deployments face a critical remote code execution vulnerability allowing any authenticated user to execute arbitrary server code by injecting malicious Jinja templates; no public exploit code has been identified, but the vulnerability enables full system compromise. With no vendor patch currently available, organizations must immediately limit user access to template functions and implement compensating controls to prevent data breach and operational disruption.
Restrict template-rendering functionality to essential personnel via role-based access control; deploy WAF rules to block Jinja template syntax ({% %}, {{ }}, {
#}) in user inputs; establish real-time monitoring and alerting for suspicious template-related API calls and error patterns; segregate ERPNext from other production systems to limit lateral movement in case of compromise; require multi-factor authentication for accounts with template permissions; disable frappe.render_template in safe_exec contexts if not operationally critical; maintain tested daily incremental backups; conduct weekly access reviews of users with template-rendering permissions.
Threat Intelligence Overview
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.
What every action level means
SSVC AssessmentENISA
Priority Score
Attack Technique
Remote Code Execution represents the critical moment when an attacker successfully runs arbitrary code on a target system without physical access.
Stored cross-site scripting leading to code execution in Frappe Framework 15.89.0 (and the ERPNext application built on
An exploitable SQL injection vulnerability exists in the authenticated part of ERPNext v10.1.6. Rated high severity (CVS
An exploitable SQL injection vulnerability exists in the authenticated part of ERPNext v10.1.6. Rated high severity (CVS
An exploitable SQL injection vulnerability exists in the authenticated part of ERPNext v10.1.6. Rated high severity (CVS
An exploitable SQL injection vulnerability exists in the authenticated part of ERPNext v10.1.6. Rated high severity (CVS
Authenticated SQL injection in Frappe ERPNext through 15.89.0 allows low-privilege users to extract arbitrary database c
SQL injection in Frappe ERPNext through 15.89.0 lets an authenticated attacker with a valid session and access to the Pa
Authenticated attackers with permission to create or modify Print Format documents in Frappe ERPNext through 15.89.0 can
Authenticated server-side template injection in Frappe ERPNext through 15.89.0 lets a user who can create or modify an A
Authenticated server-side template injection in Frappe ERPNext through 15.89.0 allows users with privileges to configure
An SQL injection vulnerability exists in the frappe.desk.reportview.get functionality of ERPNext 11.1.38. Rated high sev
Frappe Framework ERPNext 13.4.0 contains a sandbox escape vulnerability in RestrictedPython that allows authenticated us
EUVD-2026-60451
NVD
CVE.org
EPSS
Vulnrichment
GitHub
Exploit-DB