Malicious actors have been using a Trojan dubbed “Chikdos” to infect MySQL servers and abuse them to conduct distributed denial-of-service (DDoS) attacks.
The Chikdos malware, first documented by Poland’s CERT, has been around since 2013. The threat is designed to hijack both Linux and Windows machines and use them to launch DDoS attacks.
According to Symantec, the latest versions of the threat are not much different compared to the early variants analyzed by CERT Poland. In the attacks observed recently by the security firm, the attackers have been targeting MySQL servers, most likely because they are widespread and they have large bandwidth that can be very useful for DDoS attacks.
The attacks against MySQL servers start with a malicious user-defined function (UDF) that acts as a downloader (Downloader.Chikdos) for the actual malware, detected by Symantec as Trojan.Chikdos.A.
UDFs are stored in the file system and they’re designed to extend the functionality of a MySQL server. These functions are usually installed by malicious actors on MySQL servers via SQL injection attacks. In this case, experts say it’s unclear if the attackers have used automated scanning or a worm to compromise the servers and install the UDF.
Once executed, the UDF downloads the malware from hardcoded URLs (compromised websites) onto the infected server. In some cases, the downloader also adds a new user account to the system.
In the campaign analyzed by Symantec, a quarter of the compromised MySQL servers are in India, followed by China, Brazil, the Netherlands, the U.S., South Korea, Mexico, Canada and Italy. The attacks observed by the security firm were aimed at an IP address in China and a hosting provider in the United States.
“To protect against these types of attacks, SQL servers should not be run with administrator privileges where possible. Applications that use the SQL server should be patched regularly and follow good programming practices to mitigate SQL injection vulnerabilities. Check for the presence of new user accounts and ensure that remote access services are configured securely,” Symantec recommends.