CVE-2025-66434: n/a
CVE-2025-66434 is a Server-Side Template Injection (SSTI) vulnerability in the get_dunning_letter_text method of Frappe ERPNext versions through 15. 89. 0. It allows an authenticated attacker with permissions to configure Dunning Type and its child table to inject malicious Jinja2 template expressions. The vulnerability arises because the function renders attacker-controlled templates using frappe. render_template() with a user-supplied context, and the sandboxed environment still exposes dangerous globals like frappe. db. sql. Exploitation can lead to server-side code execution within a restricted context and potential leakage of sensitive database information. No public exploits are known yet, and no CVSS score is assigned.
AI Analysis
Technical Summary
CVE-2025-66434 is a critical Server-Side Template Injection (SSTI) vulnerability found in the get_dunning_letter_text method of Frappe ERPNext up to version 15.89.0. The vulnerability stems from the rendering of user-supplied Jinja2 templates (body_text) via the frappe.render_template() function, which uses a user-controlled context object (doc). Although Frappe attempts to sandbox the Jinja2 environment using a custom SandboxedEnvironment, it inadvertently exposes dangerous global functions such as frappe.db.sql through get_safe_globals(). This exposure allows an authenticated attacker, who has permissions to configure the Dunning Type and its associated Dunning Letter Text child table, to inject arbitrary Jinja2 expressions. These expressions can execute server-side code within the template rendering process, potentially leading to unauthorized database queries and leakage of sensitive information. The vulnerability requires authentication and specific configuration access, limiting the attack surface to users with elevated privileges. No public exploits are currently known, and no official patches or CVSS scores have been published as of the vulnerability's disclosure date. The lack of a CVSS score necessitates a severity assessment based on the potential impact and exploitation complexity.
Potential Impact
For European organizations, this vulnerability poses a significant risk especially to those relying on Frappe ERPNext for enterprise resource planning and financial operations. Successful exploitation could lead to unauthorized disclosure of sensitive financial and customer data stored in the ERP system's database, undermining confidentiality. The ability to execute server-side code, even within a restricted context, could be leveraged to escalate privileges or pivot to other parts of the network, impacting integrity and availability. Organizations in sectors such as finance, manufacturing, and retail that heavily depend on ERPNext for critical business processes are particularly at risk. Data breaches resulting from this vulnerability could lead to regulatory penalties under GDPR due to exposure of personal data. Additionally, the requirement for authenticated access means insider threats or compromised credentials could facilitate exploitation, increasing the risk profile. The absence of known public exploits provides a window for mitigation but also indicates potential for targeted attacks once exploit code becomes available.
Mitigation Recommendations
To mitigate this vulnerability, European organizations should immediately restrict access to the Dunning Type configuration and its child tables to only the most trusted and necessary personnel, minimizing the number of users who can inject malicious templates. Implement strict role-based access controls (RBAC) and audit all changes to these configurations. Organizations should monitor logs for unusual template rendering activity or database queries originating from the ERP system. Until an official patch is released, consider disabling or limiting the use of custom dunning letter templates if feasible. Review and harden the Jinja2 sandbox environment by removing or restricting dangerous globals such as frappe.db.sql from the template execution context. Conduct thorough code reviews and penetration testing focused on template injection vectors. Additionally, enforce strong authentication mechanisms, including multi-factor authentication (MFA), to reduce the risk of credential compromise. Stay updated with vendor advisories and apply patches promptly once available.
Affected Countries
Germany, France, United Kingdom, Netherlands, Italy, Spain, Belgium, Sweden
CVE-2025-66434: n/a
Description
CVE-2025-66434 is a Server-Side Template Injection (SSTI) vulnerability in the get_dunning_letter_text method of Frappe ERPNext versions through 15. 89. 0. It allows an authenticated attacker with permissions to configure Dunning Type and its child table to inject malicious Jinja2 template expressions. The vulnerability arises because the function renders attacker-controlled templates using frappe. render_template() with a user-supplied context, and the sandboxed environment still exposes dangerous globals like frappe. db. sql. Exploitation can lead to server-side code execution within a restricted context and potential leakage of sensitive database information. No public exploits are known yet, and no CVSS score is assigned.
AI-Powered Analysis
Technical Analysis
CVE-2025-66434 is a critical Server-Side Template Injection (SSTI) vulnerability found in the get_dunning_letter_text method of Frappe ERPNext up to version 15.89.0. The vulnerability stems from the rendering of user-supplied Jinja2 templates (body_text) via the frappe.render_template() function, which uses a user-controlled context object (doc). Although Frappe attempts to sandbox the Jinja2 environment using a custom SandboxedEnvironment, it inadvertently exposes dangerous global functions such as frappe.db.sql through get_safe_globals(). This exposure allows an authenticated attacker, who has permissions to configure the Dunning Type and its associated Dunning Letter Text child table, to inject arbitrary Jinja2 expressions. These expressions can execute server-side code within the template rendering process, potentially leading to unauthorized database queries and leakage of sensitive information. The vulnerability requires authentication and specific configuration access, limiting the attack surface to users with elevated privileges. No public exploits are currently known, and no official patches or CVSS scores have been published as of the vulnerability's disclosure date. The lack of a CVSS score necessitates a severity assessment based on the potential impact and exploitation complexity.
Potential Impact
For European organizations, this vulnerability poses a significant risk especially to those relying on Frappe ERPNext for enterprise resource planning and financial operations. Successful exploitation could lead to unauthorized disclosure of sensitive financial and customer data stored in the ERP system's database, undermining confidentiality. The ability to execute server-side code, even within a restricted context, could be leveraged to escalate privileges or pivot to other parts of the network, impacting integrity and availability. Organizations in sectors such as finance, manufacturing, and retail that heavily depend on ERPNext for critical business processes are particularly at risk. Data breaches resulting from this vulnerability could lead to regulatory penalties under GDPR due to exposure of personal data. Additionally, the requirement for authenticated access means insider threats or compromised credentials could facilitate exploitation, increasing the risk profile. The absence of known public exploits provides a window for mitigation but also indicates potential for targeted attacks once exploit code becomes available.
Mitigation Recommendations
To mitigate this vulnerability, European organizations should immediately restrict access to the Dunning Type configuration and its child tables to only the most trusted and necessary personnel, minimizing the number of users who can inject malicious templates. Implement strict role-based access controls (RBAC) and audit all changes to these configurations. Organizations should monitor logs for unusual template rendering activity or database queries originating from the ERP system. Until an official patch is released, consider disabling or limiting the use of custom dunning letter templates if feasible. Review and harden the Jinja2 sandbox environment by removing or restricting dangerous globals such as frappe.db.sql from the template execution context. Conduct thorough code reviews and penetration testing focused on template injection vectors. Additionally, enforce strong authentication mechanisms, including multi-factor authentication (MFA), to reduce the risk of credential compromise. Stay updated with vendor advisories and apply patches promptly once available.
Affected Countries
For access to advanced analysis and higher rate limits, contact root@offseq.com
Technical Details
- Data Version
- 5.2
- Assigner Short Name
- mitre
- Date Reserved
- 2025-11-30T00:00:00.000Z
- Cvss Version
- null
- State
- PUBLISHED
Threat ID: 69403ea1d9bcdf3f3deea906
Added to database: 12/15/2025, 5:00:17 PM
Last enriched: 12/15/2025, 5:15:28 PM
Last updated: 12/15/2025, 8:36:41 PM
Views: 8
Community Reviews
0 reviewsCrowdsource mitigation strategies, share intel context, and vote on the most helpful responses. Sign in to add your voice and help keep defenders ahead.
Want to contribute mitigation steps or threat intel context? Sign in or create an account to join the community discussion.
Related Threats
CVE-2025-64725: CWE-286: Incorrect User Management in WeblateOrg weblate
LowCVE-2023-53868: Unrestricted Upload of File with Dangerous Type in Coppermine coppermine-gallery
HighCVE-2025-14148: CWE-522 Insufficiently Protected Credentials in IBM UCD - IBM DevOps Deploy
MediumCVE-2025-55703: n/a
LowCVE-2025-13489: CWE-319 Cleartext Transmission of Sensitive Information in IBM UCD - IBM DevOps Deploy
MediumActions
Updates to AI analysis require Pro Console access. Upgrade inside Console → Billing.
Need enhanced features?
Contact root@offseq.com for Pro access with improved analysis and higher rate limits.