Threat Feed

CVE-2026-138287: D-Link DSL-2640B · Remote code execution

Exploitation: None known · CVSS 10.0 Critical · Unauthenticated · Published 2026-11-29

Description

A flaw has been found in D-Link DSL-2640B 3.0.6.0.41. The impacted element is the function cgiPortMapQrySwitch of the file portmapcfg.cmd of the component Endpoint. This manipulation of the argument pmapCfgName causes os command injection. The attack can be initiated remotely. The exploit has been published and may be used.

Enclave's analysis

D-Link DSL-2640B firmware 3.0.6.0.41 has a command injection in portmapcfg.cmd: the pmapCfgName parameter gets dropped straight into a root shell command. The CVE record calls it unauthenticated and network-reachable, but the actual proof-of-concept shows it needs valid admin credentials (default admin:admin or a hardcoded vendor account), and the web UI is LAN-only unless remote management is turned on. A working PoC exists, demonstrated against an emulated image rather than live hardware. The device is end-of-life with no patch coming, so restrict LAN access, kill default creds, or retire it.

Fix

No fixed version in the CVE record yet. Follow the vendor advisory.

Affected versions

ProductVulnerableFixed in
DSL-2640B3.0.6.0.41Not listed
D-Link DSL-2640Bfirmware 3.0.6.0.41Not listed
D-Link DSL-2740R / DSL-2780B / DSL-526B (same /bin/cfm CGI framework)Unconfirmed — PoC author's own untested extrapolation, not in the CNA's affected listNot listed

Seen in 2 sources