Executive Summary
This analysis covers a sophisticated cyber espionage campaign conducted by the MuddyWater threat actor (also known as TEMP.Zagros, Mango Sandstorm, TA450) targeting government entities, critical infrastructure, and private sector organizations across the Middle East and globally. Campaign Scope:- 140+ confirmed targets across 8+ countries
- 4 distinct attack phases documented in Episodes 1-4
- Primary vectors: ProxyShell exploitation (CVE-2021-34473, CVE-2021-34523, CVE-2021-31207)
- Persistence mechanism: BellaCiao custom backdoor
- Attribution confidence: High (based on TTPs, tooling, and target selection)
Key Findings
1. Target Profile and Victim Selection
Primary Targets:- Government foreign ministries and diplomatic missions
- Law enforcement and intelligence agencies
- Critical infrastructure operators
- Telecommunications providers
- Healthcare facilities
- Financial institutions
- Middle East (Primary): UAE, Saudi Arabia, Kuwait, Turkey, Jordan, Iran
- Central Asia: Afghanistan, Pakistan
- Caucasus: Georgia, Armenia, Azerbaijan
- Europe (Secondary): Israel, Germany, France, Austria, UK
- Global (Tertiary): India, South Korea, Australia
- Government entities with foreign policy responsibilities
- Organizations with access to sensitive intelligence
- Critical infrastructure with national security implications
- Regional adversaries and geopolitical competitors
2. Attack Methodology
Phase 1: Reconnaissance
Tools and Techniques:- Subdomain enumeration:
subfinder,amass,dnsenum - Network scanning:
nmap,nbtscan - Service detection:
whatweb,wpscan - OSINT collection:
whois, DNS enumeration
- Systematic enumeration of entire government domains
- Focus on Microsoft Exchange (ports 443, 25, 587)
- SMB/RDP service discovery (ports 445, 139, 3389)
- Database service enumeration (ports 1433, 3306)
Phase 2: Initial Access
Primary Attack Vector: ProxyShell Vulnerabilities Chained:- CVE-2021-34473: Pre-auth path confusion vulnerability
- CVE-2021-34523: Elevation of privilege on Exchange PowerShell backend
- CVE-2021-31207: Post-auth arbitrary file write vulnerability
- Webshell upload to
/owa/auth/or/aspnet_client/ - HTTP 200 response from webshell path
- Ability to execute arbitrary commands
- SQL injection against web applications
- SMB relay attacks (attempted via
enum4linux,smbclient) - RDP brute forcing (using
ncrack,crowbar,medusa) - FTP service exploitation
Phase 3: Persistence and Lateral Movement
BellaCiao Backdoor Deployment Configuration Profile:- Windows service installation with legitimate-sounding name
- Hidden attribute on executables
- PowerShell-based webserver for remote management
- Plink for SSH tunneling (RDP forwarding)
Phase 4: Collection and Exfiltration
Credential Harvesting:- SAM database dumping:
samdump2 SAM SYSTEM - LSASS memory dumping via
comsvcs.dll - Network share password reuse
- Active Directory credential extraction
- Log file exfiltration from compromised hosts
- Network topology mapping
- Email metadata collection (legacyDN enumeration)
- File server enumeration
3. Infrastructure Analysis
Compromised Infrastructure:ameen-alkhalij.nu- WordPress server (likely victim turned C2)88.80.145.122- SSH tunnel/proxy endpoint103.57.251.31:3512- SOCKS5 proxy
twittsupport.com- BellaCiao primary C2msn-center.uk- BellaCiao backup C2
- Use of Cloudflare for reconnaissance traffic
- SSH tunneling through compromised infrastructure
- SOCKS proxies for pivoting
- Multiple backup C2 domains
- Legitimate-looking service names for persistence
4. Toolset Analysis
Open Source Tools:- Reconnaissance: subfinder, amass, nmap, dnsenum, nbtscan
- Web Scanning: ffuf, wpscan, whatweb
- Exploitation: metasploit, sqlmap, various ProxyShell exploits
- Post-Exploitation: enum4linux, smbclient, wmic, rpcclient
- Credential Attacks: medusa, ncrack, crowbar
- Tunneling: SSH, plink
- BellaCiao: Custom backdoor with service persistence
- ProxyShell Exploits: Multiple Python-based exploit scripts
- Webshells: Custom ASPX webshells with randomized names
- Operating System: Linux (Kali/Parrot OS)
- Primary Shell: zsh
- Languages: Python, PowerShell, Go (for BellaCiao)
- Version Control: Git for tool management
Attack Timeline
Early 2022: Initial Campaign
Q1-Q2 2022: ProxyShell Mass Exploitation- Mass scanning of Middle Eastern IP ranges
- Automated ProxyShell exploitation against Exchange servers
- Initial webshell deployment across 100+ organizations
- Focus on government email servers
- Turkey: 41 organizations compromised
- Saudi Arabia: 29 organizations compromised
- Kuwait: 21 organizations compromised
- Iran: 18 organizations compromised
Late 2022: Persistence Establishment
Q3-Q4 2022: BellaCiao Deployment- October 26, 2022: Ransomware testing (Episode 4 logs)
- Service-based persistence mechanisms deployed
- C2 infrastructure established (twittsupport.com, msn-center.uk)
- SSH tunneling infrastructure created
- Turkish Foreign Ministry (212.175.168.58)
- Dubai Police infrastructure (BellaCiao configuration found)
- Multiple Exchange servers maintained for lateral movement
2023-2024: Sustained Operations
Continuous Activity:- Ongoing reconnaissance of government domains
- Credential harvesting and reuse
- Lateral movement within compromised networks
- Establishment of multiple access vectors per organization
- Additional countries targeted (Pakistan, Georgia, Armenia)
- Critical infrastructure focus (telecommunications, utilities)
- Healthcare sector targeting
January 2025: Current Operations
Recent Activity (Jan 8-9, 2025):- WordPress exploitation attempts on
ameen-alkhalij.nu - 100+ XML-RPC brute force attempts in 4-minute window
- Continuous setup-config.php scanning from Cloudflare IPs
- Evidence of active C2 infrastructure
Impact Assessment
Confirmed Compromises
Critical Impact (Government):- Turkish Foreign Ministry: Full network compromise, credential harvesting, lateral movement documented
- Dubai Police: BellaCiao backdoor configured specifically for this target
- Afghan Government: Multiple ministries (MOF, MOD, MOI, MFA, AOP) under active reconnaissance
- UAE Government: Emaratech, RTA, Dubai Chamber, DNRD under attack
- Telecommunications: Turkish Telecom, Jazz Pakistan, Roshan Afghanistan
- Healthcare: Multiple Saudi hospitals, Kuwaiti medical facilities
- Financial: Insurance and investment firms in Saudi Arabia, Kuwait
- Manufacturing and industrial companies
- IT service providers
- Media organizations
Data at Risk
Sensitive Information:- Diplomatic communications (Foreign Ministry compromise)
- Intelligence and law enforcement data (Police infrastructure)
- PII of government employees and citizens
- Financial records and transactions
- Healthcare patient data
- Critical infrastructure operational data
- 140+ organizations with confirmed exploitation attempts
- 30+ confirmed shells deployed successfully
- 1,369+ reconnaissance commands executed
- 49 failed attempts documented (indicates detection)
Geopolitical Context
Attribution Assessment: Based on target selection, TTPs, and operational patterns, this activity is attributed with high confidence to MuddyWater (aka TEMP.Zagros, Mango Sandstorm, TA450), an Iranian state-sponsored APT group. Supporting Evidence:- Focus on Middle Eastern governments and adversaries
- BellaCiao backdoor (known MuddyWater tool)
- ProxyShell exploitation timeline matches known campaigns
- Target selection aligns with Iranian strategic interests
- Use of Persian language in some file paths and commands
- Intelligence collection on regional adversaries
- Monitoring of diplomatic activities
- Pre-positioning for future operations
- Intellectual property theft
- Critical infrastructure mapping
Recommendations for Defenders
Immediate Actions (0-24 hours)
1. Hunt for BellaCiao Indicators
Service Detection:2. Webshell Detection
Exchange Server Paths:webclient.aspx,OutlookOU.aspx,errorFE.aspx- Random 5-10 character names ending in
.aspx - Files modified after ProxyShell patches were released
3. Network Isolation
Block C2 Domains:Short-Term Actions (1-7 days)
4. ProxyShell Vulnerability Assessment
Check Exchange Version:- CVE-2021-34473 (May 2021 or later)
- CVE-2021-34523 (May 2021 or later)
- CVE-2021-31207 (May 2021 or later)
- Exchange Server 2019 CU10 or later
- Exchange Server 2016 CU21 or later
- Exchange Server 2013 CU23 or later
5. Credential Reset
High-Priority Accounts:- Administrator and domain admin accounts
- Exchange admin accounts
- Service accounts with network access
- VPN and remote access accounts
6. Log Analysis
Review Exchange Logs:- Review firewall logs for connections to C2 domains
- Analyze DNS logs for subdomain enumeration patterns
- Check proxy logs for reconnaissance activity
7. Endpoint Detection
Deploy EDR/AV Signatures: YARA Rule for BellaCiao:Medium-Term Actions (1-4 weeks)
8. Architecture Review
Network Segmentation:- Isolate Exchange servers from internal network
- Implement jump hosts for administrative access
- Segment critical systems by function and sensitivity
- Implement MFA for all administrative accounts
- Restrict WMI and PowerShell remoting
- Disable SMBv1 and legacy protocols
- Apply least privilege principles
- Deploy network traffic analysis tools
- Implement file integrity monitoring on Exchange servers
- Enable PowerShell script block logging
- Configure Sysmon for advanced logging
9. Threat Hunting
Hunt for Lateral Movement:10. Incident Response Plan
If Compromise Confirmed:-
Containment:
- Isolate affected systems from network
- Block C2 domains at firewall/DNS
- Disable compromised accounts
- Change all administrative passwords
-
Eradication:
- Remove webshells from Exchange servers
- Delete BellaCiao service and files
- Rebuild compromised systems from known-good images
- Apply all security patches
-
Recovery:
- Restore from clean backups if available
- Verify system integrity before reconnecting to network
- Monitor closely for signs of re-compromise
-
Lessons Learned:
- Document timeline of compromise
- Identify gaps in detection and prevention
- Update incident response procedures
- Conduct tabletop exercises
Long-Term Actions (1-3 months)
11. Security Program Enhancements
Vulnerability Management:- Establish patch management SLAs (critical patches within 7 days)
- Implement vulnerability scanning on regular schedule
- Prioritize internet-facing systems for patching
- Subscribe to vendor security advisories
- Deploy SIEM with correlation rules for APT activity
- Implement network traffic analysis (NTA)
- Enable cloud-based threat intelligence feeds
- Establish SOC with 24/7 monitoring capability
- Implement privileged access management (PAM) solution
- Deploy jump hosts for all administrative access
- Enforce MFA for all remote access
- Review and reduce administrative privileges
- Implement offline/air-gapped backups
- Test backup restoration regularly
- Ensure backups cover all critical systems
- Document and practice recovery procedures
12. Threat Intelligence Integration
Subscribe to Feeds:- Government CERT advisories (local country)
- Commercial threat intelligence platforms
- Information sharing communities (ISACs)
- Open source intelligence (OSINT) sources
- Automate IOC ingestion into SIEM/EDR
- Correlate IOCs with internal telemetry
- Share IOCs with trusted partners
- Participate in threat intelligence sharing
13. Security Awareness Training
Topics to Cover:- Phishing and social engineering awareness
- Secure password practices
- Recognizing suspicious activity
- Incident reporting procedures
- Insider threat indicators
- Executive leadership (strategic briefing)
- IT administrators (technical deep dive)
- All employees (general awareness)
- Security team (threat hunting techniques)
Detection Rules
Sigma Rules
BellaCiao Service Detection
WMI Lateral Movement
ProxyShell Webshell Access
YARA Rules
ProxyShell Webshell
Conclusion
The MuddyWater campaign represents a significant and ongoing threat to government entities and critical infrastructure across the Middle East. The threat actor demonstrates:- Sophistication: Use of zero-day exploits (ProxyShell), custom malware (BellaCiao), and advanced operational security
- Persistence: Sustained operations over 3+ years with evolving tactics
- Scale: 140+ targeted organizations across 8+ countries
- Impact: Confirmed compromise of foreign ministry, law enforcement, and critical infrastructure
- Immediate patching of ProxyShell vulnerabilities
- Hunt for BellaCiao backdoor indicators
- Enhanced monitoring of Exchange servers and lateral movement
- Credential hygiene and privilege reduction
- Network segmentation and access controls