CVE-2026-5212

8.8

D-Link · NAS devices (various models)

A stack-based buffer overflow in the Webdav_Upload_File function of the webdav_mgr.cgi script allows remote authenticated attackers to execute arbitrary code via the f_file parameter.

Executive summary

A critical stack-based buffer overflow vulnerability in multiple D-Link NAS devices allows authenticated attackers to achieve remote code execution, posing a significant risk to data integrity.

Vulnerability

The vulnerability exists within the Webdav_Upload_File function of the webdav_mgr.cgi binary, where improper handling of the f_file argument leads to a stack-based buffer overflow. This flaw requires the attacker to have low-level privileges (authenticated user) to trigger the overflow and potentially execute arbitrary code.

Business impact

Successful exploitation of this vulnerability allows an authenticated attacker to execute arbitrary code on the affected NAS device. This could lead to a total compromise of stored data, unauthorized access to sensitive files, or permanent denial of service by crashing the device. With a CVSS score of 8.8, this vulnerability represents a high-severity risk that demands prompt attention to prevent lateral movement or data theft within the network.

Remediation

Immediate Action: Check the official D-Link support portal for firmware updates addressing this vulnerability, and apply them immediately to all affected NAS units. If no patch is currently available for your specific model, restrict management interface access to trusted network segments only.

Proactive Monitoring: Review system logs for unusual POST requests directed at /cgi-bin/webdav_mgr.cgi, particularly those containing excessively long filename parameters. Monitor NAS devices for unexpected service interruptions or frequent crashes.

Compensating Controls: Implement a Web Application Firewall (WAF) or an Intrusion Prevention System (IPS) to inspect and block malicious multipart/form-data payloads targeting the webdav_mgr.cgi endpoint. Restrict access to the web management interface to authorized administrative IP addresses via firewall rules.

Exploitation status

Public Exploit Available: Yes, a proof-of-concept is documented in the research write-up referenced by the CVE record.

Analyst recommendation

Given the availability of a public proof-of-concept and the potential for remote code execution, this vulnerability poses a significant risk to your storage infrastructure. Administrators should prioritize identifying all vulnerable D-Link devices within their environment and apply vendor-supplied firmware updates as soon as they are released. Until updates are applied, minimize the attack surface by isolating vulnerable devices from public-facing networks.

More D-Link CVEs

Sources

Originally found and disclosed by Ziyue Xie (VulDB User), per the CVE Program record.