Home › Vulnerabilities › D-Link
D-Link DSL-2640B Hit by Three Remote OS Command Injection Flaws, Two Rated Critical
NVD published three vulnerabilities affecting D-Link DSL-2640B firmware 3.0.6.0.41, all described as OS command injection flaws that can be triggered remotely. Two are rated CRITICAL (CVSS 9.3) and one HIGH (CVSS 8.6), and the records say public exploits exist and may be used.
What to look into
- 3 vulnerabilities in D-Link DSL-2640B: 2 critical, 1 high (CVSS up to 9.3).
- None of them is known to be exploited yet.
- Start with CVE-2026-138288 (9.3 critical): D-Link DSL-2640B 3.0.6.0.41 cgiWanCfg ifname OS command injection (CVE-2026-138288). An attacker without an account can exploit this over the network, without any user action.
- 2 of 3 can be attacked over the network without logging in, 2 of them without anyone clicking anything.
- Kinds of flaws: Improper Neutralization of Special Elements used in a Command ('Command Injection') (×3); Improper Neutralization of Special Elements used in an OS Command ('OS Command Injection') (×3).
Key points
- Three OS command injection flaws in D-Link DSL-2640B version 3.0.6.0.41, all reportedly remotely exploitable.
- CVE-2026-138288 and CVE-2026-138287 are rated CRITICAL (CVSS 9.3); CVE-2026-138289 is rated HIGH (CVSS 8.6).
- Each flaw sits in a different web management function: WAN configuration, port mapping, and DMZ host settings.
- Public exploits are stated to exist, but the records do not report active exploitation.
- No fixed version or workaround is given in the sources.
What the batch covers
NVD published three related records on 2026-11-29 for the D-Link DSL-2640B, all tied to version 3.0.6.0.41. Each describes the same class of weakness: user-supplied input passed to an operating system command without adequate handling, which the records call OS command injection. Each is said to be exploitable remotely.
The most severe entries
CVE-2026-138288 is rated CRITICAL (CVSS 9.3). According to the record, the flaw is in the function cgiWanCfg of the file /wancfg.cmd, where manipulating the ifname argument leads to command injection.
CVE-2026-138287 is also CRITICAL (CVSS 9.3). Its record places the issue in the function cgiPortMapQrySwitch of portmapcfg.cmd, under a component labelled Endpoint, where manipulating the pmapCfgName argument causes command injection.
CVE-2026-138289 is rated HIGH (CVSS 8.6). It affects SecCfgMngr::setDmzHost in the DMZ Host Handler component, where manipulating the address argument results in command injection.
Exploitation status
All three records state that exploit code has been disclosed or published and may be used. The sources do not say that any of these flaws has been observed in attacks in the wild.
What is not stated
The records do not name a fixed firmware version, a vendor patch, a workaround, or a detection method. Administrators should check D-Link's support channels for an update rather than assume one exists for this build.
What to do
- Check D-Link's security advisories for a firmware update that addresses these CVEs, since the records give no fixed version.
- Restrict access to the device's web management interface and do not expose it to untrusted networks while no fix is confirmed.
- Review WAN, port mapping and DMZ host configurations for unexpected changes.
The 3 vulnerabilities
- CVE-2026-138288 9.3 D-Link DSL-2640B 3.0.6.0.41 cgiWanCfg ifname OS command injection (CVE-2026-138288)
- CVE-2026-138287 9.3 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.…
- CVE-2026-138289 8.6 D-Link DSL-2640B Command Injection Vulnerability CVE-2026-138289
Frequently asked questions
How many D-Link DSL-2640B vulnerabilities were published on November 29, 2026?
3 vulnerabilities: 2 critical, 1 high, with CVSS scores up to 9.3.
Are any of them being exploited?
None of them is in CISA's Known Exploited Vulnerabilities catalog yet.
Which one should be fixed first?
CVE-2026-138288 (CVSS 9.3): D-Link DSL-2640B 3.0.6.0.41 cgiWanCfg ifname OS command injection (CVE-2026-138288).