The Nas Nobody Patched From Unauthenticated Rce To Network Proxy Via Wd Mycloud
An unauthenticated command injection in the WD MyCloud web interface allowed a remote attacker to execute arbitrary commands as root. The author used this to obtain a reverse shell, then set up SSH and a SOCKS proxy to route traffic through the NAS.
Published on systemweakness.com
In this blog, I’ll walk through how an unauthenticated command injection in a WD MyCloud NAS gave me a reverse shell as root, how I bootstrapped a persistent SSH backdoor on a device that didn’t even have SSH running, and how I turned that NAS into a covert SOCKS proxy with a single SSH flag.
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 write-up has not been written yet. The Original tab links to the source.
How it worked
Impact
An unauthenticated attacker could gain root-level command execution on the NAS and use it as a covert proxy, potentially accessing stored data and hiding their network origin.
What the attacker needed
Network access to the NAS web interface; Unpatched WD MyCloud firmware
The fix
The vulnerability should be fixed by updating the firmware to a patched version and restricting management interface access to trusted networks.
How it was found
- Discover a WD MyCloud NAS on the network (port 443).
- Exploit the unauthenticated command injection via Metasploit.
- Obtain a reverse shell as root.
- Generate SSH host keys on the device.
- Configure and start the SSH daemon.
- Change the root password for SSH authentication.
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 write-up has not been written yet. The Original tab links to the source.
A command injection flaw lets an attacker sneak operating system commands into a web request, and because the web server runs with high privileges, those commands run as the all-powerful root user. The attacker then used that access to install a remote login service (SSH) and turn the device into a relay for other network traffic, hiding their origin.
What is RCE?
Running the attacker's code on the target's servers: through command or code injection, unsafe deserialisation or template injection.