D-Link DIR-1935 SetIPv6FirewallSettings IPv6FirewallRule Command Injection Remote Code Execution Vulnerability
The router's web management portal fails to validate a user-supplied string inside the IPv6FirewallRule element of SetIPv6FirewallSettings requests before passing it to a system call. A network-adjacent attacker who bypasses the existing authentication could run arbitrary code as root on the device.
This vulnerability allows network-adjacent attackers to execute arbitrary code on affected installations of D-Link DIR-1935 routers. Although authentication is required to exploit this vulnerability, the existing authentication mechanism can be bypassed.
The full write-up lives on its author's site
It belongs to its author, so we link to it rather than copy it. The other two tabs are our own rewrites, checked against it.
Not written yet. The AI write-up for this report has not been written yet. The Original tab links to the source.
How it worked
Root cause
Likely the web portal builds a shell command from the unvalidated IPv6FirewallRule subelement value instead of sanitising or escaping it.
Impact
A network-adjacent attacker could execute arbitrary code as root, though authentication is required and must first be bypassed.
What the attacker needed
Network-adjacent access to the router; authentication bypass required
The fix
D-Link issued an update to correct the vulnerability.
Explained by bugbounty.wiki with AI from the original and checked against quotes from it; it can still be wrong. Read the original before relying on a detail.
Not written yet. The AI write-up for this report has not been written yet. The Original tab links to the source.
This router runs a small web server so you can change its settings from a browser. One of the settings pages takes text from the request and hands it to the operating system as a command without checking it first, so crafted text can run extra commands. Because those commands run as root, the most powerful account on the device, the attacker effectively owns the router.
What is RCE?
Running the attacker's code on the target's servers: through command or code injection, unsafe deserialisation or template injection.