T-SQL campaign brute-forces exposed MS SQL Servers on TCP 1433 to deploy Gh0st RAT and XMRig miner
FortiGuard Labs reported an active campaign against internet-facing Microsoft SQL Server instances on TCP port 1433. A Go scanner (dllhost.exe) embeds the Naabu port scanner. A .NET brute-forcer (dwm.exe, assembly CSQL.exe) then tries the sa and admin accounts against a dictionary of more than 2,700 passwords. After a successful login, T-SQL batches run remotely and install an XMRig Monero miner and a Gh0st RAT variant. No named group is confirmed. The Tencent QQ data theft and the checks for Chinese security processes suggest a financially motivated, Chinese-speaking operator. This summary is based on the article alone, and no vendor advisory was consulted.
Detalhes técnicos
- The Go binary is packed with UPX. It downloads 2018.sql, dwm.exe, go.bat, go.vbs, out.bat, user.txt, pass.txt and sqlcmd.exe, and it creates a scheduled task disguised as a Microsoft Edge update that runs every 30 minutes.
- It gets a target IP from the C2 server, expands it to a /16 subnet, and sends SYN probes to port 1433. Open hosts are logged to Result.txt.
- dwm.exe brute-forces logins with up to 500 threads. 2018.sql then enables xp_cmdshell and Ole Automation Procedures.
- The script drops down.exe, renamed Google.exe or payload.exe, in C:\Users\Public. It also registers a scheduled task named Microsoft_UPDATES.
- It writes a hex-encoded Secs.exe with ADODB.Stream and runs it via WScript.Shell.
- Secs.exe sends the victim's IP, country, OS build, CPU, RAM, username and hostname to the C2 server by HTTP POST. It pulls payloads from an FTP server with FtpGetFileW.
- MicrosoftEdgeUpdate.exe is an XMRig miner packed with Themida. It mines Monero (rx/0) via Kryptex and Nanopool.
- winlogon.exe is a Gh0st RAT variant packed with Themida. It provides keylogging, screen capture, file management, a remote shell and more than 30 commands. It persists through the HKLM Run key, a service and a scheduled task. It wipes event logs, checks 78 security processes and steals Tencent QQ data.
- At least one compromised server in the United States was observed. No total victim count was published.
Remediação
- Restrict TCP 1433 at the perimeter.
- Enforce strong sa passwords.
- Keep xp_cmdshell and Ole Automation Procedures disabled.
- Audit scheduled tasks for Microsoft_UPDATES and fake Edge update tasks.
- Monitor C:\Users\Public for Secs.exe and Google.exe.
Linha do tempo
-
T-SQL campaign brute-forces exposed MS SQL Servers on TCP 1433 to deploy Gh0st RAT and XMRig miner
ler a análise desta fonte ocultar
FortiGuard Labs reported an active campaign against internet-facing Microsoft SQL Server instances on TCP port 1433. A Go scanner (dllhost.exe) embeds the Naabu port scanner. A .NET brute-forcer (dwm.exe, assembly CSQL.exe) then tries the sa and admin accounts against a dictionary of more than 2,700 passwords. After a successful login, T-SQL batches run remotely and install an XMRig Monero miner and a Gh0st RAT variant. No named group is confirmed. The Tencent QQ data theft and the checks for Chinese security processes suggest a financially motivated, Chinese-speaking operator. This summary is based on the article alone, and no vendor advisory was consulted.
Technical Details
- The Go binary is packed with UPX. It downloads 2018.sql, dwm.exe, go.bat, go.vbs, out.bat, user.txt, pass.txt and sqlcmd.exe, and it creates a scheduled task disguised as a Microsoft Edge update that runs every 30 minutes.
- It gets a target IP from the C2 server, expands it to a /16 subnet, and sends SYN probes to port 1433. Open hosts are logged to Result.txt.
- dwm.exe brute-forces logins with up to 500 threads. 2018.sql then enables xp_cmdshell and Ole Automation Procedures.
- The script drops down.exe, renamed Google.exe or payload.exe, in C:\Users\Public. It also registers a scheduled task named Microsoft_UPDATES.
- It writes a hex-encoded Secs.exe with ADODB.Stream and runs it via WScript.Shell.
- Secs.exe sends the victim's IP, country, OS build, CPU, RAM, username and hostname to the C2 server by HTTP POST. It pulls payloads from an FTP server with FtpGetFileW.
- MicrosoftEdgeUpdate.exe is an XMRig miner packed with Themida. It mines Monero (rx/0) via Kryptex and Nanopool.
- winlogon.exe is a Gh0st RAT variant packed with Themida. It provides keylogging, screen capture, file management, a remote shell and more than 30 commands. It persists through the HKLM Run key, a service and a scheduled task. It wipes event logs, checks 78 security processes and steals Tencent QQ data.
- At least one compromised server in the United States was observed. No total victim count was published.
Remediation
- Restrict TCP 1433 at the perimeter.
- Enforce strong sa passwords.
- Keep xp_cmdshell and Ole Automation Procedures disabled.
- Audit scheduled tasks for Microsoft_UPDATES and fake Edge update tasks.
- Monitor C:\Users\Public for Secs.exe and Google.exe.