CVE-2026-71239: CWE-1336 Improper Neutralization of Special Elements Used in a Template Engine in DjangoCRM django-crm
DjangoCRM's massmail module renders user-controlled EmlMessage fields (subject, content) through Django's Template() constructor with no sanitization, in at least three locations: message_previews.py builds an f-string embedding message.subject/message.content directly into a Template() call; email_creators.py passes eml_message.subject directly as a template string to Template(); and helpers.py contains the same f-string interpolation pattern. An authenticated user with mass-mail message edit rights can inject Django template syntax ({{ }} / {% %}) that executes at render time, enabling disclosure of other users' data and password hashes via request context variables, CSRF token forgery, and inclusion of arbitrary registered templates.
AI Analysis
Technical Summary
DjangoCRM's massmail module in django-crm renders user-controlled EmlMessage fields (subject, content) via Django's Template() constructor without sanitization in at least three locations: message_previews.py, email_creators.py, and helpers.py. Authenticated users with mass-mail message edit permissions can inject Django template syntax ({{ }} / {% %}) that executes during template rendering. This improper neutralization of special elements (CWE-1336) enables attackers to disclose sensitive data such as other users' information and password hashes through request context variables, perform CSRF token forgery, and include arbitrary registered templates. The vulnerability has a CVSS 3.1 score of 8.8 (high severity) with network attack vector, low attack complexity, requiring privileges but no user interaction, and impacts confidentiality and integrity.
Potential Impact
An attacker with authenticated mass-mail message edit rights can exploit this vulnerability to execute arbitrary Django template code. This can lead to unauthorized disclosure of sensitive user data including password hashes, forgery of CSRF tokens, and inclusion of arbitrary templates, compromising confidentiality and integrity of the system. There is no indication of impact on availability. No known exploits in the wild have been reported.
Mitigation Recommendations
Patch status is not yet confirmed — check the vendor advisory for current remediation guidance. Until an official fix is available, restrict mass-mail message edit permissions to trusted users only to reduce risk. Avoid rendering user-controlled input directly with Django's Template() constructor without proper sanitization or escaping.
CVE-2026-71239: CWE-1336 Improper Neutralization of Special Elements Used in a Template Engine in DjangoCRM django-crm
Description
DjangoCRM's massmail module renders user-controlled EmlMessage fields (subject, content) through Django's Template() constructor with no sanitization, in at least three locations: message_previews.py builds an f-string embedding message.subject/message.content directly into a Template() call; email_creators.py passes eml_message.subject directly as a template string to Template(); and helpers.py contains the same f-string interpolation pattern. An authenticated user with mass-mail message edit rights can inject Django template syntax ({{ }} / {% %}) that executes at render time, enabling disclosure of other users' data and password hashes via request context variables, CSRF token forgery, and inclusion of arbitrary registered templates.
CVSS v3.1
Score 8.1high
Weaknesses
AI-Powered Analysis
Machine-generated threat intelligence
Technical Analysis
DjangoCRM's massmail module in django-crm renders user-controlled EmlMessage fields (subject, content) via Django's Template() constructor without sanitization in at least three locations: message_previews.py, email_creators.py, and helpers.py. Authenticated users with mass-mail message edit permissions can inject Django template syntax ({{ }} / {% %}) that executes during template rendering. This improper neutralization of special elements (CWE-1336) enables attackers to disclose sensitive data such as other users' information and password hashes through request context variables, perform CSRF token forgery, and include arbitrary registered templates. The vulnerability has a CVSS 3.1 score of 8.8 (high severity) with network attack vector, low attack complexity, requiring privileges but no user interaction, and impacts confidentiality and integrity.
Potential Impact
An attacker with authenticated mass-mail message edit rights can exploit this vulnerability to execute arbitrary Django template code. This can lead to unauthorized disclosure of sensitive user data including password hashes, forgery of CSRF tokens, and inclusion of arbitrary templates, compromising confidentiality and integrity of the system. There is no indication of impact on availability. No known exploits in the wild have been reported.
Mitigation Recommendations
Patch status is not yet confirmed — check the vendor advisory for current remediation guidance. Until an official fix is available, restrict mass-mail message edit permissions to trusted users only to reduce risk. Avoid rendering user-controlled input directly with Django's Template() constructor without proper sanitization or escaping.
Technical Details
- Data Version
- 5.2
- Assigner Short Name
- TuranSec
- Date Reserved
- 2026-08-05T10:53:53.175Z
- Cvss Version
- 3.1
- State
- PUBLISHED
- Remediation Level
- null
Threat ID: 6a731a81bf8831d539c95ca2
Added to database: 08/05/2026, 11:12:01 UTC
Last enriched: 08/05/2026, 11:26:46 UTC
Last updated: 08/06/2026, 02:06:53 UTC
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.
Actions
Updates to AI analysis require Pro Console access. Upgrade inside Console → Billing.
External Links
Need more coverage?
Upgrade to Pro Console for AI refresh and higher limits.
For incident response and remediation, OffSeq services can help resolve threats faster.
Latest Threats
Check if your credentials are on the dark web
Instant breach scanning across billions of leaked records. Free tier available.