VSFTPD — Backdoor Command Execution Vulnerability Exploitat
The vsftpd 2.3.4 package distributed for a few days in 2011 contained a backdoor: a username ending in a smiley emoticon caused the daemon to open a root shell on TCP port 6200. An attacker could then connect to that port and run commands as root.
Published on medium.com
Over the past few years, individuals and organizations have been rapidly embracing digital transformation. However, this shift has brought with it a critical issue that many remain unaware of or choose to ignore, security of their data and information.
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
Root cause
The distributed source of vsftpd 2.3.4 had been replaced with a malicious version that checks the username for a smiley sequence and then spawns a root shell listener.
Impact
An attacker who can reach the FTP port could trigger the backdoor and obtain a root shell on the host, giving full control of the machine.
What the attacker needed
Vsftpd 2.3.4 from the infected 2011 window; network access to the FTP port; network access to port 6200
The fix
The report says to upgrade vsftpd to a newer version and verify checksums and signatures of downloaded binaries; it also offers a temporary iptables rule dropping traffic to port 6200.
How it was found
- Set up attacker and victim virtual machines on a host-only network and note their IP addresses.
- Scan the victim with nmap to find the FTP service on port 21 and confirm port 6200 is closed.
- Run the nmap vuln script against port 21 to flag the backdoor.
- Connect to the FTP service and send a username ending in a smiley emoticon with any password.
- Rescan port 6200 to see it is now open, then connect to it to obtain a root shell.
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.
Someone had tampered with the download of a file-transfer program called vsftpd, so the copy people installed secretly included extra code. If a login name ended with a smiley face, that code started a hidden door on another network port, and anyone who connected to that port got full control of the machine. This was not a normal coding mistake but a supply-chain attack on the download site.
What is RCE?
Running the attacker's code on the target's servers: through command or code injection, unsafe deserialisation or template injection.