CVE-2026-65974: ERPNext: Server-Side Template Injection leading to Remote Code Execution
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.
Security readout for executives and security teams
Plain-English summary
A user with limited ERPNext access could cross a security boundary and run code on the server. Successful exploitation could expose or alter ERP data and disrupt operations. The flaw is critical because it is network-accessible, requires only low privileges, and needs no user interaction.
Executive priority
Treat this as an urgent upgrade for affected ERPNext systems, especially externally reachable or business-critical deployments. Low-privilege access can become server code execution, placing financial, operational, and customer data at risk. Investigate for compromise where vulnerable systems had untrusted authenticated users.
Technical view
ERPNext exposes frappe.render_template within Frappe safe execution without forcing restrict_globals. A limited authenticated user can exploit this server-side template injection weakness to escape intended permissions and achieve remote code execution. The issue is classified as CWE-1336 and has a CVSS 3.1 score of 9.9.
Likely exposure
Deployments are affected when running ERPNext versions below 15.111.0, or versions from 16.0.0 through 16.21.x. Exposure requires an authenticated account with limited privileges and network access to the vulnerable functionality. The supplied sources do not identify specific configurations that eliminate exposure.
Exploitation context
The supplied bundle states that this CVE is not in KEV, and no cited source confirms active exploitation. Exploitation requires low privileges but has low complexity, needs no victim interaction, and can compromise confidentiality, integrity, and availability across a security boundary.
Researcher notes
The boundary failure involves frappe.render_template being exposed without mandatory restrict_globals enforcement in Frappe safe execution. The referenced Frappe commit documents the corrective code change. The bundle provides no proof-of-concept status, exploitation telemetry, indicators of compromise, or named temporary vendor workaround.
Mitigation direction
Upgrade ERPNext 15.x to 15.111.0 or later, or 16.x to 16.22.0 or later.
Follow the Frappe security advisory and release guidance during remediation.
Remove unnecessary limited-user accounts until affected systems are upgraded.
Restrict ERPNext access to trusted networks where operationally feasible.
Monitor affected systems for unusual template-related or server-side activity.
Validation and detection
Inventory every ERPNext deployment and record its exact installed version.
Confirm each deployment is outside the documented affected version ranges.
Verify the upgraded application reports version 15.111.0, 16.22.0, or a later applicable release.
Review limited-user accounts and remove access that is no longer required.
Examine available application and host logs for unexplained code execution or template activity.
Generated from the cited source records. This long-tail analysis has not been individually reviewed by a named human.
Potential ATT&CK relevance
Conservative CVE-to-ATT&CK context
These mappings and lookup hints may be relevant to the vulnerability behavior, CWE, affected product, or exposure path. Glexia-inferred context is not an official MITRE, ATT&CK, CWE, or CVE Program mapping.
ATT&CK lookup starting points
Use these exact CWE pages and searches to review the Glexia ATT&CK library from this CVE's weakness and description context.
cwe · low confidence lookup
CWE-1336: Exact CWE lookup
Use the exact CWE identifier as the starting point before reviewing related ATT&CK behavior. Open the exact CWE lookup page first, then review the ATT&CK searches from that MITRE weakness context. This is a Glexia lookup hint, not an official ATT&CK mapping.
The CVE wording references code or command execution, so execution technique review may help defensive triage. This is a Glexia inferred lookup path, not an official MITRE, ATT&CK, or CVE Program mapping.
These fields come from the CVE record and ADP containers, not from Glexia's Take. They preserve time-varying source decisions such as CISA SSVC, KEV status, CVSS metrics, and provider references.
1CVSS vectors
3Timeline events
1ADP providers
5Source links
SSVC decision data
CISA-ADPCISA Coordinator
Timestamp
Version
2.0.3
Exploitation: noneAutomatable: noTechnical Impact: total
CVSS vector scores
1 official score
We collect every scored CVSS vector available in the official CNA and ADP containers. When more than one version is present, the table keeps the source vectors side by side instead of collapsing them into the highest score.
CWE links open Glexia weakness intelligence pages with official CWE context, developer remediation guidance, and related CVE mappings.
CWE-1336 · source CWE mapping
Improper Neutralization of Special Elements Used in a Template Engine
Improper Neutralization of Special Elements Used in a Template Engine represents a recurring weakness pattern that can create exploitable paths when design, validation, or implementation controls are missing.