---
id: CVE-2026-138287
title: A flaw has been found in D-Link DSL-2640B 3.0.6.0.41
summary: >-
  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
  injectio…
severity: critical
cvss: 10
cvssVector: 'CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:C/C:H/I:H/A:H'
cwe:
  - CWE-77
  - CWE-78
published: '2026-11-29'
updated: '2026-11-30'
sourceUpdated: '2026-11-30T21:17:27.843'
source: NVD
sourceUrl: 'https://nvd.nist.gov/vuln/detail/CVE-2026-138287'
references:
  - url: >-
      https://github.com/dujiaode/DSL2640B/tree/main/01-portmapcfg-pmapcfgname-cmd-injection
    label: cna@vuldb.com
  - url: 'https://vuldb.com/cve/CVE-2026-138287'
    label: cna@vuldb.com
  - url: 'https://vuldb.com/submit/1074577'
    label: cna@vuldb.com
  - url: 'https://vuldb.com/vuln/445112'
    label: cna@vuldb.com
  - url: 'https://vuldb.com/vuln/445112/cti'
    label: cna@vuldb.com
  - url: 'https://www.dlink.com/'
    label: cna@vuldb.com
tags:
  - nvd
  - cve.org
  - exploit-available
epss: 0.03032
epssPercentile: 0.87867
ingestedAt: '2026-11-29T19:05:50.761Z'
vendor: D-Link
product: DSL-2640B
affected:
  - DSL-2640B 3.0.6.0.41
exploitAvailable: true
ssvc:
  exploitation: poc
  automatable: 'yes'
  technicalImpact: total
  timestamp: '2026-11-30T20:11:18.322465Z'
---

## Overview

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.

## Remediation

Refer to the linked advisories for vendor-supplied fixes and affected version ranges.
