CVE-2026-65974

ERPNext: Server-Side Template Injection leading to Remote Code Execution

Published Aug 17, 2026 CVSS 3.1 · 9.9 Critical EPSS 1.0% KEV · Not listed
Description
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.

Analysis

AI-generated

Technical impact

ERPNext is affected by a server‑side template injection flaw that allows malicious users to inject arbitrary template content. Because the rendering engine is exposed without restrictive safeguards, an attacker can execute code on the server. The vulnerability is only reachable by authenticated users who possess a limited set of permissions, but those permissions grant the ability to cross a permission boundary, thereby compromising the confidentiality, integrity, and availability of the application.

Affected Systems

The affected product is ERPNext, built on the frappe framework. All releases prior to 15.111.0 and 16.22.0 are vulnerable, regardless of the operating environment. Users running any of those legacy versions should review their installed version against the published patch releases.

Risk and Exploitability

With a CVSS score of 9.9 the issue is classified as critical. The EPSS score is not available, but the absence of a public exploit does not diminish the high risk inherent to remote code execution. The vulnerability is not currently listed in the CISA KEV catalog, yet the potential impact and the required attacker conditions—an authenticated user with certain permissions—make it a top priority for remediation. The attack vector is inferred to be a privilege‑escalation scenario that relies on the application’s template engine and user permissions rather than an external network exploit.

Remediation

No solution or workaround provided in the CVE record.

OpenCVE Recommended Actions

  • Upgrade ERPNext to version 15.111.0 or later, or to 16.22.0 or later, to apply the vendor‑supplied fix.
  • For systems that cannot be updated immediately, restrict access to the frappe.render_template function by configuring the application’s permission settings to allow it only for trusted roles.
  • Audit user roles and privileges to ensure that no user has unnecessary permissions that could be leveraged to trigger the template injection.
  • If a temporary workaround is required, disable the template rendering capability in any non‑production or isolated instances until an update is deployed.

Generated by OpenCVE AI on August 18, 2026 at 00:03 UTC.

Tracking

Sign in to view the affected projects.

Advisories

No advisories available
History
Type Values Removed Values Added
Metrics ssvc

{'options': {'Automatable': 'no', 'Exploitation': 'none', 'Technical Impact': 'total'}, 'version': '2.0.3'}

Type Values Removed Values Added
First Time appeared Frappe
Frappe erpnext
Vendors & Products Frappe
Frappe erpnext
Type Values Removed Values Added
Description 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.
Title ERPNext: Server-Side Template Injection leading to Remote Code Execution
Weaknesses CWE-1336
References
Metrics cvssV3_1

{'score': 9.9, 'vector': 'CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:C/C:H/I:H/A:H'}

Weaknesses
  • CWE-1336

    Improper Neutralization of Special Elements Used in a Template Engine

Sources

Status
PUBLISHED
Assigner
GitHub_M
Published
Updated
Aug 18, 2026, 2:17 PM
Reserved
Jul 23, 2026, 6:15 PM
Status
Deferred
Published
Aug 17, 2026, 9:16 PM
Modified
Oct 23, 2026, 4:10 PM