CVE-2026-138287
Deferred Deferred - Pending Action

D-Link DSL-2640B OS Command Injection Vulnerability

Vulnerability report for CVE-2026-138287, including description, CVSS score, EPSS score, affected products, exploitability, helpful resources, and attack-flow context.

Publication date: 2026-11-29

Last updated on: 2026-11-29

Assigner: VulDB

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.

CVSS Scores

EPSS Scores

Probability:
Percentile:

Meta Information

Published
2026-11-29
Last Modified
2026-11-29
Generated
2026-11-29
AI Q&A
2026-11-29
EPSS Evaluated
N/A
NVD
EUVD

Affected Vendors & Products

Showing 1 associated CPE
Vendor Product Version / Range
D-Link DSL-2640B 3.0.6.0.41

Helpful Resources

Exploitability

CWE
CWE Icon
KEV
KEV Icon
CWE ID Description
CWE-78 The product constructs all or part of an OS command using externally-influenced input from an upstream component, but it does not neutralize or incorrectly neutralizes special elements that could modify the intended OS command when it is sent to a downstream component.
CWE-77 The product constructs all or part of a command using externally-influenced input from an upstream component, but it does not neutralize or incorrectly neutralizes special elements that could modify the intended command when it is sent to a downstream component.

Attack-Flow Graph

AI Quick Actions

Instant insights powered by AI
Executive Summary

This is a command injection vulnerability in D-Link DSL-2640B firmware version 3.0.6.0.41. The flaw exists in the pmapCfgName parameter of the /portmapcfg.cmd endpoint, which is passed unsanitized into a shell command without validation. Attackers can inject arbitrary commands that execute as root due to the web management interface running with root privileges.

Detection Guidance

Check if your D-Link DSL-2640B device is running firmware version 3.0.6.0.41. Send an HTTP GET request to /portmapcfg.cmd with a test parameter like pmapCfgName=test;id to see if arbitrary commands execute. If the device responds with command output, it is vulnerable.

Impact Analysis

Attackers can exploit this vulnerability remotely without authentication to gain full control over the device. This includes reading sensitive data, modifying configurations, or installing persistent malware. The impact extends to both LAN and WAN if remote management is enabled.

Compliance Impact

This vulnerability could lead to unauthorized access to sensitive data stored on the device, potentially violating GDPR and HIPAA requirements for data protection and confidentiality. Unauthorized command execution may expose personal or health information, leading to compliance breaches.

Mitigation Strategies

Disable remote management on the device to prevent WAN-side exploitation. Disable the web management interface if not needed. Isolate the device from critical network segments. Replace the device as it is end-of-life and no patches are available.

Chat Assistant

Ask questions about this CVE
Hi! I’m here to help you understand CVE-2026-138287. Ask me anything about the vulnerability, its impact, or mitigation strategies.
0/70

EPSS Chart

Security Radar

News mentioning this vulnerability
Loading related security news...