OilRig, also called APT34, is an Iranian espionage group that hides command and control in DNS and in the victim's own Exchange server, and harvests credentials so thoroughly that it captures new passwords as users change them. Active since at least 2014, it targets government, energy, financial, chemical and telecommunications organisations in the Middle East and beyond, and it often enters through a trusted partner. This profile is for SOC analysts, Exchange and Active Directory administrators and threat intelligence teams in the Gulf, Israel and organisations with Middle Eastern operations or suppliers. It covers names and attribution as each source states it, targeting, the ATT&CK techniques mapped to the group, its credential and mailbox abuse in detail, notable campaigns and a detection and hardening plan. Regional context is in the Iran State Cyber Operations Guide, and general group background in the Threat Actor Groups Guide.
Key takeaways
- DNS and mail are its covert channels. BONDUPDATER and ISMAgent tunnel C2 through DNS, and PowerExchange and STEALHOOK use on-premises Exchange mailboxes to receive commands and send stolen data.
- It captures passwords at the source. Trend Micro documented a malicious password filter DLL registered with the LSA, which receives every new plaintext password, plus LaZagne, Mimikatz and a Credential Manager stealer.
- Partners are the way in. ATT&CK records supply chain attacks that abuse trust between organisations, spearphishing from compromised email accounts, LinkedIn lures and fake VPN, conference and job sites.
- Service accounts are disguises. Microsoft found an account named to look like an Exchange Health Manager mailbox, given Organization Management and ApplicationImpersonation, during the 2022 Albania intrusion that it linked with moderate confidence to the group.
- Patch fast and watch Tier 0. The group exploited CVE-2017-11882 within a week of its patch and CVE-2024-30088 in 2024; most of its later work needs domain controller and Exchange access.
Who they are (names and aliases)
MITRE ATT&CK tracks the group as OilRig (G0049), a suspected Iranian threat group targeting Middle Eastern and international victims since at least 2014, which works on behalf of the Iranian government based on infrastructure references to Iran, use of Iranian infrastructure and targeting aligned with nation-state interests. Mandiant made the same assessment for APT34 in December 2017 and said APT34 loosely aligns with public reporting on OilRig. Microsoft assessed with moderate confidence that the actors who gained initial access and stole data in the 2022 attack on the Albanian government are linked to EUROPIUM (now Hazel Sandstorm), which it notes has been publicly tied to Iran's Ministry of Intelligence and Security (MOIS).
| Name | Tracked by | Notes |
|---|---|---|
| OilRig | Palo Alto Networks Unit 42 (also Evasive Serpens), ATT&CK | ATT&CK primary name |
| APT34 | Mandiant / Google | "Loosely aligns" with OilRig per Mandiant |
| Hazel Sandstorm (earlier EUROPIUM) | Microsoft | Renamed in April 2023 |
| Crambus | Symantec | 2023 Middle East government intrusion |
| Earth Simnavaz | Trend Micro | 2024 Gulf energy activity |
| Helix Kitten, COBALT GYPSY, IRN2, ITG13, TA452 | Other vendors | Aliases listed in ATT&CK |
Related but distinct Iranian groups: the APT33 Threat Actor Profile Guide, the MuddyWater Threat Actor Profile and the Charming Kitten (APT35) Threat Actor Profile.
Targeting and motivation
- Sectors: financial, government, energy, chemical and telecommunications (ATT&CK and Mandiant). Trend Micro's 2024 reporting focuses on oil and gas and other infrastructure in the Gulf.
- Regions: mostly the Middle East. ESET's Outer Space (2021) and Juicy Mix (2022) campaigns, recorded in ATT&CK, targeted Israeli organisations; Symantec described an eight-month intrusion into a Middle Eastern government in 2023; Microsoft's Albania case extends the reach to Europe.
- Motivation: long-term espionage focused on reconnaissance that benefits Iranian national interests (Mandiant). In Albania the access and stolen mail preceded a destructive ransomware and wiper attack that Microsoft attributed with high confidence to Iranian government-sponsored actors, so access gained by this group can be handed on for disruption.
Tactics and techniques (MITRE ATT&CK)
All techniques below are mapped to G0049 in ATT&CK v20, which records about 76 technique uses for the group.
| Tactic | Technique | How it shows up |
|---|---|---|
| Resource development | T1583.001 Domains; T1586.002 Email Accounts | Fake VPN portals, conference sign-ups and job sites; phishing from compromised mailboxes |
| Initial access | T1566.001, T1566.002, T1566.003 Spearphishing via Service; T1195 Supply Chain Compromise | Macro documents, links, LinkedIn messages; attacks through compromised partner organisations |
| Initial access, persistence | T1133 External Remote Services; T1505.003 Web Shell | VPN, Citrix and OWA with stolen credentials; web shells on vulnerable web servers |
| Execution, privilege escalation | T1203 Exploitation for Client Execution; T1068 Exploitation for Privilege Escalation | CVE-2017-11882 in Office; Windows kernel CVE-2024-30088 for SYSTEM |
| Persistence | T1137.004 Outlook Home Page; T1053.005 Scheduled Task | Outlook Home Page abuse, including rollback of the CVE-2017-11774 fix; VBScript tasks |
| Credential access, persistence | T1556.002 Password Filter DLL | Malicious filter registered with the LSA captures plaintext passwords on change |
| Credential access | T1003.001 LSASS Memory; T1003.004 LSA Secrets; T1003.005 Cached Domain Credentials | Mimikatz, LaZagne |
| Credential access | T1555.003 Credentials from Web Browsers; T1555.004 Windows Credential Manager; T1056.001 Keylogging | LaZagne, VALUEVAULT, KEYPUNCH and LONGWATCH keyloggers |
| Discovery | T1069.002 Domain Groups; T1201 Password Policy Discovery | net group "domain admins" and "Exchange Trusted Subsystem"; net accounts /domain |
| Command and control | T1071.004 DNS; T1008 Fallback Channels | DNS tunnelling, including through requestbin.net; ISMAgent falls back to DNS when HTTP fails |
| Command and control | T1572 Protocol Tunneling; T1219 Remote Access Tools | Plink renamed \ProgramData\Adobe.exe forwarding RDP; ngrok |
| Exfiltration | T1048.003 Exfiltration Over Unencrypted Non-C2 Protocol | Data sent through Microsoft Exchange and FTP |
| Lateral movement | T1021.001 RDP; T1543.003 Windows Service | RDP enabled and tunnelled; services created from a compromised domain controller |
| Defence impairment, stealth | T1686.003 Windows Host Firewall; T1553.002 Code Signing | Firewall rules opened for remote access; malware signed with stolen certificates |
How they abuse identities and credentials
OilRig treats Active Directory and Exchange as its operating platform. The table follows the path from one user to persistent, mailbox-level control.
| Stage | What the sources describe | Control that breaks it |
|---|---|---|
| Borrow a trusted sender | Phishing from compromised partner and supplier mailboxes | DMARC enforcement, supplier compromise playbooks, banner and sandbox for external partner mail |
| Harvest stored secrets | LaZagne for browser, LSA and cached credentials; VALUEVAULT for Credential Manager | Block browser password saving on managed devices; Credential Guard; use an enterprise password manager |
| Capture new passwords | Password filter DLL in LSA Notification Packages, needs local admin (Trend Micro) | Allowlist approved filters; alert on changes to HKLM\SYSTEM\CurrentControlSet\Control\Lsa\Notification Packages; LSA protection |
| Own the domain | Mimikatz on a domain controller; services created from the DC | Tier 0 admin model, privileged access workstations, no interactive admin logons to member servers with DA rights |
| Live in Exchange | PowerExchange logs into mailboxes with hardcoded credentials, takes commands from mail with "@@" in the subject and hides them with an inbox rule named defaultexchangerules; STEALHOOK sends data out through Exchange with the subject "Update Service" | Audit inbox rule creation; alert on rules that move mail to Deleted Items; restrict EWS and remote PowerShell to named admin accounts |
| Disguise an account | "HealthMailbox55x2yq" added to Organization Management and granted ApplicationImpersonation (Microsoft, Albania) | Inventory Exchange system mailboxes; alert on any role group change and on ApplicationImpersonation assignments |
- Rotate after a password filter finding: if a malicious filter ran on a domain controller, assume every password changed since then is known, and force a domain-wide reset, including service accounts and the krbtgt account (twice).
- Exchange service identities: Exchange Trusted Subsystem and health mailboxes are high-value non-human identities. See the Microsoft Exchange Server Security Guide and the Service Account Security Guide.
Notable incidents
| Date | Activity | Source |
|---|---|---|
| November 2017 | CVE-2017-11882 exploited less than a week after the patch; POWRUNER and BONDUPDATER with DNS C2 against Middle East targets | Mandiant, 7 December 2017 |
| 2021 | Outer Space campaign against Israeli organisations with SampleCheck5000 and Solar | ATT&CK C0042 (citing ESET) |
| May 2021 to July 2022 | Access to the Albanian government through SharePoint CVE-2019-0604, mail theft, then a destructive attack on 15 July 2022; Microsoft links the access and exfiltration actors to EUROPIUM with moderate confidence | Microsoft, 8 September 2022 |
| 2022 | Juicy Mix campaign against Israeli organisations with the Mango backdoor | ATT&CK C0044 (citing ESET) |
| February to September 2023 | Eight-month intrusion into a Middle Eastern government; PowerExchange mail-based C2 | Symantec, 19 October 2023 |
| 2024 | Gulf energy and infrastructure targets; CVE-2024-30088, password filter DLL, STEALHOOK | Trend Micro, 11 October 2024 |
Detection and defence
Detection signals
| Signal | Where to look | Notes |
|---|---|---|
| Long, high-entropy subdomains or many unique subdomains under one domain | DNS resolver logs, protective DNS | BONDUPDATER-style DGA names; see the DNS Security Guide |
| New DLL listed in LSA Notification Packages; Event ID 4614 on domain controllers | Registry auditing, Security log | Password filter abuse |
| Inbox rules moving messages to Deleted Items; messages with "@@" in subject | Exchange admin audit log, message trace | PowerExchange behaviour |
| Mail with subject "Update Service" sent from servers or service accounts to external addresses | Message trace, DLP | STEALHOOK exfiltration |
| Role group changes, ApplicationImpersonation assignments, new HealthMailbox-style accounts | Exchange admin audit log, AD Event ID 4728 and 4732 | Disguised service account |
| fDenyTSConnections set to 0, firewall rules opened for RDP, RDP on ports such as 999, 12345 or 4455 | Sysmon 13, Windows Firewall logs, NetFlow | Plink tunnelling of RDP |
| plink.exe or putty binaries renamed and run from ProgramData; ngrok processes | EDR process telemetry | ATT&CK notes \ProgramData\Adobe.exe |
| Web server processes spawning PowerShell | EDR | Web shell activity |
Hardening plan
- Week 1: patch Office, Exchange, SharePoint and Windows kernel flaws listed above; confirm MFA on VPN, Citrix and OWA; block DNS from endpoints except to internal resolvers.
- Weeks 2 to 4: enable Exchange admin and mailbox audit logging, and alert on inbox rules, role group changes and ApplicationImpersonation; review all existing inbox rules that delete or move mail.
- Weeks 4 to 8: enable LSA protection and Credential Guard in audit mode, then enforce; baseline LSA Notification Packages on every DC and alert on change; disable browser password saving through policy.
- Quarter 1: implement a tiered admin model with privileged access workstations; restrict EWS and Exchange remote PowerShell to named admin accounts; apply protective DNS with DNS tunnelling detection.
- Response: if a password filter or DC compromise is found, plan a full credential reset with krbtgt rotated twice, remove rogue inbox rules and role assignments, and rebuild affected Exchange servers. Test the reset plan in a lab first, because resetting service accounts without a dependency map can cause outages.
Metrics
- Domain controllers with a baselined, alerting LSA Notification Packages value: 100%.
- Inbox rules that forward or delete mail reviewed: 100% each quarter.
- Endpoints able to send DNS directly to the internet: zero.
- Accounts holding Exchange Organization Management or ApplicationImpersonation: documented and reviewed monthly.
- Remote access services without MFA: zero.
Framework mapping
| Framework | Reference | Relevance |
|---|---|---|
| NIST SP 800-53 Rev. 5 | AC-2 Account Management, AC-6 Least Privilege | Disguised service accounts and Exchange role groups |
| NIST SP 800-53 Rev. 5 | IA-2 Identification and Authentication, CM-11 User-installed Software | MFA for remote access; controlling DLLs and tools |
| NIST SP 800-53 Rev. 5 | SC-20 Secure Name/Address Resolution Service, SI-4 System Monitoring, AU-12 Audit Record Generation | DNS tunnelling and Exchange auditing |
| NIST CSF 2.0 | PR.AA-01, DE.CM-03 | Identity and credential management, monitoring of personnel activity and technology use |
| MITRE D3FEND | D3-DNSTA DNS Traffic Analysis | Detecting DNS C2 |
Practitioner checklist
- Baseline LSA Notification Packages on all domain controllers and alert on change.
- Alert on inbox rules that move or delete mail and on Exchange role group or impersonation changes.
- Force endpoint DNS through internal resolvers with tunnelling detection.
- Require MFA on VPN, Citrix and OWA and review accounts that bypass it.
- Hunt for renamed Plink, ngrok and RDP on unusual ports.
- Disable browser password storage on managed devices and enable Credential Guard.
- Treat partner mailboxes as a threat path: verify unexpected attachments from suppliers.
- Keep a tested domain-wide credential reset plan, including krbtgt and service accounts.
Standards and references
- MITRE ATT&CK: OilRig (G0049)
- MITRE ATT&CK: Modify Authentication Process: Password Filter DLL
- MITRE ATT&CK: Application Layer Protocol: DNS
- Microsoft Threat Intelligence: Microsoft investigates Iranian attacks against the Albanian government
- Mandiant: New Targeted Attack in the Middle East by APT34
- Symantec: Crambus, new campaign targets Middle Eastern government
- Trend Micro: Earth Simnavaz (APT34) cyberattacks against the Middle East
Related NHI Mgmt Group resources: Iran State Cyber Operations Guide · Threat Actor Groups Guide · Microsoft Exchange Server Security Guide · DNS Security Guide · APT33 Threat Actor Profile Guide