CVE-2026-137043 — TOTOLINK N350RT — CWE-639 · CWE-285
A security vulnerability has been detected in TOTOLINK N350RT 9.3.5u.6468_B20250827/9.3.5u.6466_B20250825. The affected element is the function setLanguageCfg of the file /cgi-bin/cstecgi.cgi. Such manipulation of the argument lang leads to authorization bypass. The attack can be executed remotely. The exploit has been disclosed publicly and may be used.
A security vulnerability has been detected in TOTOLINK N350RT 9.3.5u.6468_B20250827/9.3.5u.6466_B20250825. The affected element is the function setLanguageCfg of the file /cgi-bin/cstecgi.cgi. Such manipulation of the argument lang leads to authorization bypass. The attack can be executed remotely. The exploit has been disclosed publicly and may be used.
🎯 What is this vulnerability?
This vulnerability is a Critical Authorization Bypass (CWE-285) combined with Authorization Bypass Through User-Controlled Key (CWE-639) in the TOTOLINK N350RT router firmware.
Technical Flaw Analysis:
The core issue resides in the CGI script /cgi-bin/cstecgi.cgi, specifically within the function setLanguageCfg. In standard CGI implementations for embedded routers, configuration changes (even seemingly benign ones like language settings) should require valid session tokens (e.g., sessionid, token) or valid HTTP Basic/Digest authentication headers.
The vulnerability indicates that the lang argument manipulation allows an attacker to bypass these checks. This suggests one of two likely implementation flaws:
1. Missing Token Validation: The setLanguageCfg function does not verify the presence or validity of an authentication token before processing the request.
2. Broken Access Control Logic: The function may check for authentication after processing the input, or it may have a logic flaw where certain values of lang trigger a code path that skips the authorization check entirely (e.g., a default case that assumes local access).
Given the CVSS vector PR:N (No Privileges Required) and UI:N (No User Interaction), this is an unauthenticated remote exploit. The S:C (Scope: Changed) indicates that the vulnerable component (the CGI script) is able to impact resources outside its security scope, likely granting the attacker access to the router's administrative interface or underlying system.
⚡ Attack Chain
1. Discovery & Reconnaissance
- Fingerprinting: The attacker scans the target network (or internet) for devices responding on port 80/443.
- Version Identification: The attacker sends a request to
/or/login.htmland inspects the HTTP headers (e.g.,Server,X-Powered-By) or the HTML source code for version strings. The presence ofTOTOLINKand specific UI elements confirms the device. - Version Verification: The attacker checks the firmware version string (e.g., via
/cgi-bin/cstecgi.cgior a status page) to confirm it matches9.3.5u.6468_B20250827or9.3.5u.6466_B20250825. - Mechanism: The attacker sends an HTTP POST or GET request to
/cgi-bin/cstecgi.cgiwith theactionparameter set tosetLanguageCfg(or similar, depending on the CGI's dispatch logic) and manipulates thelangparameter.
Illustrative Payload: Note: The exact parameter name for the action is not explicitly stated in the CVE description, only the function name. The following is an illustrative example based on common TOTOLINK CGI patterns.*
2. Exploitation
# Illustrative PoC: Unauthenticated Authorization Bypass
# Target: TOTOLINK N350RT
# Endpoint: /cgi-bin/cstecgi.cgi
# Function: setLanguageCfg
# Parameter: lang
curl -X POST "http://<TARGET_IP>/cgi-bin/cstecgi.cgi" \
-d "action=setLanguageCfg&lang=en&token=INVALID_OR_EMPTY" \
-H "User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64)" \
-H "Content-Type: application/x-www-form-urlencoded"token or authentication headers. The response may be a 200 OK with a success message, or it may redirect to the admin panel with a valid session cookie, or it may directly execute the configuration change.sessionid cookie.
2. If a valid session is established, the attacker can now access other authenticated CGI endpoints (e.g., setAdminCfg, setNetworkCfg).
3. If no session is established, the attacker may exploit the same bypass to call other functions that do not require authentication, or use the bypass to reset the admin password.3. Post-Exploitation
🌍 Real World Impact
Practical Consequences:
🛡️ Remediation & Mitigation
1. Patching
9.3.5u.6468_B20250827, 9.3.5u.6466_B20250825.2. Workarounds
/cgi-bin/cstecgi.cgi with the setLanguageCfg action.Example ModSecurity Rule (Illustrative):
SecRule REQUEST_URI "@contains /cgi-bin/cstecgi.cgi" \
"id:100001,phase:1,deny,status:403,msg:'Blocked unauthenticated access to cstecgi.cgi',log"
SecRule REQUEST_BODY "@contains setLanguageCfg" \
"id:100002,phase:2,deny,status:403,msg:'Blocked setLanguageCfg without valid session',log"Note: This rule is a basic example. A more robust rule would check for the presence of a valid session cookie or authentication header before allowing the request.
3. Detection
/cgi-bin/cstecgi.cgi with the setLanguageCfg parameter from IPs that do not have valid session cookies or authentication headers./cgi-bin/cstecgi.cgi with lang parameter.
* Requests from external IPs to the router's management interface.
* Unexpected changes to the router's language setting or admin credentials.⚠️ Urgency
FOFA Query