License to Encrypt: When “The Gentlemen” Go On Offense
Detection stack
- AIDR
- Alert
- ETL
- Query
Summary
The Gentlemen ransomware collective surfaced in July 2025, running a dual-extortion operation that both encrypted victim data and siphoned off sensitive information. The malware is cross-platform, targeting Windows, Linux, and ESXi environments, and includes self-restart capabilities, run-on-boot persistence, and configurable encryption throttling. Propagation relies on WMI, PowerShell remoting, SCHTASKS, and other built-in Windows administration tools. The operators run The Gentlemen as a RaaS offering, providing affiliates with extensive tuning and customization options.
The Gentlemen Ransomware Attack Analysis
Cybereason’s analysis of a 64-bit Golang Windows sample documented its command-line switches, embedded ransom note text, and a broad set of anti-forensic PowerShell routines. Researchers also pinpointed registry locations used for persistence, a service “kill list” aimed at disabling critical processes, and reliance on native Windows binaries for privilege escalation and lateral movement. The encryption pipeline is built on XChaCha20 and Curve25519.
Mitigation
Suggested defensive measures include enforcing multi-factor authentication, maintaining frequent offline backups, promptly applying security patches, and tightening PowerShell and WMI execution controls. Endpoint protection stacks should enable real-time anti-malware, anti-ransomware safeguards, and protection for VSS shadow copies. Security teams should also monitor for abnormal registry modifications, newly created scheduled tasks, and characteristic PowerShell command patterns.
Response
When The Gentlemen ransomware activity is identified, immediately quarantine the impacted system, capture volatile memory, and gather key artifacts, such as registry entries, scheduled tasks, and PowerShell event logs. Perform forensic acquisition of ransom notes and encrypted files, then restore affected systems from trusted backups once eradication is verified. Engage incident response teams to investigate lateral movement paths and evidence of data exfiltration.
“`mermaid graph TB %% Class definitions classDef technique fill:#ffcc99 classDef tool fill:#cccccc classDef file fill:#e6e6fa classDef action fill:#99ccff classDef operator fill:#ff9900 %% Nodes – Actions / Techniques initial_access[“<b>Action</b> – Initial Access via existing foothold”] class initial_access action dll_sideload[“<b>Technique</b> – <b>T1574.001 Hijack Execution Flow: DLL</b><br/>OneDrive.exe loads malicious SSPICLI.dll via DLL sideloading”] class dll_sideload technique powershell[“<b>Technique</b> – <b>T1059.001 Command and Scripting Interpreter: PowerShell</b><br/>Base64‑encoded PowerShell commands executed for network checks and file copy”] class powershell technique office_macro[“<b>Technique</b> – <b>T1137.001 Office Application Startup: Office Template Macros</b><br/>VBA macro placed in %APPDATA%\\Microsoft\\Outlook\\VbaProject.OTM”] class office_macro technique vba_stomping[“<b>Technique</b> – <b>T1564.007 Hide Artifacts: VBA Stomping</b><br/>Macro monitors incoming mail (Application_NewMailEx) for C2 triggers and exfiltrates data”] class vba_stomping technique vb_interpreter[“<b>Technique</b> – <b>T1059.005 Command and Scripting Interpreter: Visual Basic</b><br/>VBA code executes commands and communicates via Outlook”] class vb_interpreter technique %% Nodes – Files / Objects file_oneDrive[“<b>File</b> – OneDrive.exe”] class file_oneDrive file file_sspicli[“<b>File</b> – SSPICLI.dll”] class file_sspicli file file_vba[“<b>File</b> – VbaProject.OTM”] class file_vba file email_monitor[“<b>Object</b> – Outlook Application<br/>Monitors incoming mail (Application_NewMailEx)”] class email_monitor action outlook_comm[“<b>Object</b> – Outlook<br/>Communicates C2 and exfiltrates data”] class outlook_comm action %% Connections – Flow of the attack initial_access –>|leads_to| dll_sideload dll_sideload –>|uses| file_oneDrive dll_sideload –>|loads| file_sspicli dll_sideload –>|triggers| powershell powershell –>|leads_to| office_macro office_macro –>|places| file_vba office_macro –>|enables| vba_stomping office_macro –>|enables| vb_interpreter vba_stomping –>|monitors| email_monitor vb_interpreter –>|communicates_via| outlook_comm “`
Attack Flow
Detections
Detection of The Gentlemen Ransomware Persistence and Propagation [Windows Process Creation]
View
Detect PowerShell Commands Used by “The Gentlemen” Ransomware [Windows Powershell]
View
Windows Defender Preferences Suspicious Changes (via powershell)
View
Possible PING Usage for Delay Execution (via cmdline)
View
Possible Persistence Points [ASEPs – Software/NTUSER Hive] (via registry_event)
View
Simulation Execution
Prerequisite: The Telemetry & Baseline Pre‑flight Check must have passed.
Rationale: This section details the precise execution of the adversary technique (TTP) designed to trigger the detection rule. The commands and narrative MUST directly reflect the TTPs identified and aim to generate the exact telemetry expected by the detection logic. Abstract or unrelated examples will lead to misdiagnosis.
-
Attack Narrative & Commands:
- Goal: Disable Windows Defender real‑time protection and add an exclusion path to allow the ransomware payload to write encrypted files unhindered.
- Method: Use a PowerShell
Invoke‑Commandwith an inline script block that runs the two Defender preference commands. This mirrors the exact syntax observed in “The Gentlemen” ransomware samples. - Steps:
- Open a PowerShell session with elevated privileges.
- Execute the
Invoke‑Commandthat contains the malicious script block. - Verify that Defender’s real‑time monitoring is disabled and that the exclusion for
C:\is added. - (Optional) Create a dummy encrypted file to emulate ransomware activity.
-
Regression Test Script: The following self‑contained PowerShell script reproduces the attack exactly as the rule expects.
# ------------------------------------------------------------------ # Test script to trigger Sigma rule "Detect PowerShell Commands Used by # 'The Gentlemen' Ransomware" # ------------------------------------------------------------------ # Ensure script runs as Administrator if (-not ([Security.Principal.WindowsPrincipal] [Security.Principal.WindowsIdentity]::GetCurrent()).IsInRole([Security.Principal.WindowsBuiltinRole]::Administrator)) { Write-Error "Run this script with elevated (Administrator) privileges." exit 1 } # 1️⃣ Disable real‑time monitoring Invoke-Command -ScriptBlock { Set-MpPreference -DisableRealtimeMonitoring $true } # 2️⃣ Add exclusion for the C: drive Invoke-Command -ScriptBlock { Add-MpPreference -ExclusionPath 'C:\' } # 3️⃣ (Optional) Simulate ransomware file creation $dummyPath = "C:\RansomTest\encrypted.txt" New-Item -ItemType Directory -Path (Split-Path $dummyPath) -Force | Out-Null "This is a mock encrypted payload." | Set-Content -Path $dummyPath -Encoding UTF8 Write-Host "Simulation completed. Defender should now be disabled and exclusion added." -
Cleanup Commands: Restore Defender to its default state and remove test artifacts.
# ------------------------------------------------------------------ # Cleanup script – re‑enable Defender and delete test files # ------------------------------------------------------------------ # Re‑enable real‑time monitoring Invoke-Command -ScriptBlock { Set-MpPreference -DisableRealtimeMonitoring $false } # Remove the C:\ exclusion Invoke-Command -ScriptBlock { Remove-MpPreference -ExclusionPath 'C:\' } # Delete dummy encrypted file and folder $dummyPath = "C:\RansomTest\encrypted.txt" if (Test-Path $dummyPath) { Remove-Item $dummyPath -Force } $folder = Split-Path $dummyPath if (Test-Path $folder) { Remove-Item $folder -Recurse -Force } Write-Host "Cleanup completed. Defender settings restored."