T-SQL Being Abused to Deliver Malware on Compromised MS SQL Servers
Fortinet, Thursday, November 12th, 2026
FortiGuard Labs details a campaign that brute-forces exposed Microsoft SQL Servers and uses T-SQL to install a Monero miner and Gh0st RAT.
In early October 2026, FortiGuard Labs found an active campaign targeting Internet-facing Microsoft SQL Server instances, in which a UPX-packed Go payload named dllhost.exe embeds the open-source Naabu scanner, retrieves target IP ranges from its server and scans them for open TCP port 1433.
It downloads supporting files including credential lists and sqlcmd.exe, and persists through a scheduled task that imitates a Microsoft Edge update and runs every 30 minutes.
A .NET tool named dwm.exe then brute-forces logins on discovered servers and runs malicious T-SQL commands from 2018.sql to download further malware.
Fortinet rates the severity as high, with impact including an XMR miner and remote control of the server.