How to Detect and Respond to GreenBlood Ransomware with Wazuh

Summary
The article walks through using Sysmon, custom Wazuh rules, File Integrity Monitoring, YARA, and Active Response to detect GreenBlood’s Windows encryption and defense-disabling behaviors and remove files identified as malicious.
Key points
- The article describes GreenBlood encrypting Windows files with .tgbg or .gblood extensions and placing ransom notes in affected folders.
- Reported behaviors include deleting shadow copies, disabling recovery features, turning off Windows Firewall and Defender real-time protection, and running a cleanup script.
- Sysmon event collection and custom Wazuh rules 100201–100209 are configured to alert on these behaviors.
- The walkthrough configures File Integrity Monitoring for user Downloads folders and rules to trigger YARA scans when files are added or modified.
- A Wazuh Active Response script is shown to remove files matched by the YARA rules; the article identifies the script as a proof of concept that should be validated for the environment.
Article Details
- Defense Focus
- Detect GreenBlood ransomware activity on Windows endpoints and use YARA-based active response to identify and remove matching files.
- Detection Methods
- Collect Sysmon Operational event-channel logs and use custom Wazuh rules to alert on ransom-note creation, encrypted-file extensions, recovery-disabling commands, firewall and Defender changes, and cleanup-script activity.
- Use real-time file integrity monitoring on selected directories to detect newly added or modified files.
- Run a GreenBlood YARA signature against monitored files through Wazuh Active Response; log scan results and whether removal succeeded.
- Data Sources
- Sysmon Operational event logs, including process, command-line, and file-creation events.
- Wazuh File Integrity Monitoring (syscheck) events for file additions and modifications.
- YARA scan and Wazuh Active Response logs, including scan results and removal outcomes.
- Rule Types
- Custom Wazuh XML detection rules (including rules 100201–100209 and 100210–100215).
- YARA signature rule for GreenBlood ransomware.
- Custom Wazuh XML decoders for YARA Active Response logs.
- Platforms
- Windows endpoints
- Defensive Actions
- Install Sysmon on Windows endpoints and forward its Operational event logs to Wazuh.
- Configure real-time file integrity monitoring for Downloads or other selected directories.
- Deploy and reload the custom Wazuh detection rules.
- Configure YARA scanning and Active Response for files added to or modified in monitored directories.
- Review alerts for YARA matches, successful removals, and removal errors.
- Review and validate the article’s Active Response proof-of-concept script against local operational and security requirements before deployment.
Indicators of compromise
| Type | Indicator | Context |
|---|---|---|
| SHA512 | 12bba7161d07efcb1b14d30054901ac9ffe5202972437b0c47c88d71e45c717605294c9970f365c92e0b0f1250db678dc356dbf418dba27bdd5eeb68487a7199 | Analyzed GreenBlood sample hash; the article labels it SHA256, although the provided value is 128 hexadecimal characters. |
MITRE ATT&CK
T1059.003 · Windows Command ShellGreenBlood executes Windows command-shell instructions, including running cleanup_greenblood.bat.T1486 · Data Encrypted for ImpactGreenBlood encrypts files and appends the .tgbg or .gblood extension.T1490 · Inhibit System RecoveryGreenBlood deletes shadow copies and changes boot or recovery settings to inhibit system recovery.T1562.001 · Disable or Modify ToolsGreenBlood changes registry settings to disable Microsoft Defender real-time protection.T1562.004 · Disable or Modify System FirewallGreenBlood runs a netsh command to disable the Windows Defender Firewall.
Malware
Vendors
MicrosoftDisables Microsoft Defender real-time protection using the command reg add "HKLMSOFTWAREPoliciesMicrosoftWindows DefenderReal-Time Protection" /v DisableRealtimeMonitoring /t REG_DWORD /d 1 /f.WazuhThe blog demonstrates detection and response using Sysmon, custom Wazuh rules, and YARA-based Active Response to automatically identify and remove GreenBlood artifacts.
Products
Microsoft Defender Antimalware PlatformDisables Microsoft Defender real-time protection using the command reg add "HKLMSOFTWAREPoliciesMicrosoftWindows DefenderReal-Time Protection" /v DisableRealtimeMonitoring /t REG_DWORD /d 1 /f.WazuhThe blog demonstrates detection and response using Sysmon, custom Wazuh rules, and YARA-based Active Response to automatically identify and remove GreenBlood artifacts.Windows 11A Windows 11 endpoint with the Wazuh agent 4.14.3 installed and enrolled in the Wazuh server.
Tools
SysmonThe blog demonstrates detection and response using Sysmon, custom Wazuh rules, and YARA-based Active Response to automatically identify and remove GreenBlood artifacts.YARAThe blog demonstrates detection and response using Sysmon, custom Wazuh rules, and YARA-based Active Response to automatically identify and remove GreenBlood artifacts.
