HanifNet
- Type
- Backdoor
- Capabilities
- PersistencePost exploitationReconnaissance
- Platforms
- Windows
HanifNet is a custom unsigned .NET backdoor used by the Iranian state-aligned threat actor commonly tracked as Lemon Sandstorm, also known as Parisite, Pioneer Kitten, Fox Kitten, Rubidium, and UNC757. It was deployed during a long-running intrusion against Middle Eastern critical infrastructure as part of a broader malware ecosystem that also included HXLibrary, NeoExpressRAT, Havoc, and multiple web shells.
HanifNet is designed to maintain persistent remote access by contacting command-and-control infrastructure, retrieving tasking, and executing commands on compromised systems. Reported functionality includes remote command execution through PowerShell, file operations, and system discovery, making it suitable for post-compromise control and operator-driven espionage activity. In the observed campaign, it was launched via masqueraded scheduled tasks to blend with legitimate administrative activity and support long-term access.
The malware was used after the adversary had already obtained access to the victim environment through stolen VPN credentials and subsequent internal compromise. Its deployment formed part of a sustained, multi-phase operation focused on persistence, credential access, lateral movement, and strategic prepositioning inside critical infrastructure networks. The broader campaign targeted Middle Eastern energy and infrastructure organizations and showed strong interest in restricted and operational-technology-adjacent environments, although no confirmed disruptive OT impact was established. HanifNet is best characterized as a bespoke backdoor supporting long-dwell espionage and infrastructure prepositioning by an Iranian threat actor.
Associated threat actors
1 distinct threat actor Mallory has associated with this family across public reporting. Open in Mallory to see the full evidence chain and overlapping campaigns.
Once inside, they installed multiple web shells on public-facing web servers and deployed three backdoors—Havoc, HanifNet, and HXLibrary—to maintain long-term access. | Scheduled task runs ‘masf.exe’ with ‘ml’ as sole command line argument. FortiGuard tracks this malware as HanifNet.
Techniques & procedures
8 distinct techniques documented for this family, organized by ATT&CK tactic.
Initial Access
2 techniques
Initial Access
beginning with VPN credential theft and progressively deepening access
“beginning with VPN credential theft”
Execution
4 techniques
Execution
“Persistence was maintained through web shells and scheduled tasks …” / command lines show “schtasks /create …” and “Register-ScheduledTask …”
Table 11. Scheduled tasks created by the adversary throughout the reported intrusion... The heavy use of scheduled tasks to execute malware aligns with previous Lemon Sandstorm activity. | These backdoors were run using scheduled tasks.
HanifNet, HXLibrary, and NeoExpressRAT, enabling command execution, file operations, and system discovery.
The adversary heavily used PowerShell to execute malicious commands on the compromised systems.
Persistence
5 techniques
Persistence
“Persistence was maintained through web shells and scheduled tasks …” / command lines show “schtasks /create …” and “Register-ScheduledTask …”
Table 11. Scheduled tasks created by the adversary throughout the reported intrusion... The heavy use of scheduled tasks to execute malware aligns with previous Lemon Sandstorm activity. | These backdoors were run using scheduled tasks.
beginning with VPN credential theft and progressively deepening access
“beginning with VPN credential theft”
“Persistence was maintained through web shells…” and “IIS-based malware designed to blend seamlessly into legitimate network traffic.”
Privilege Escalation
3 techniques
Privilege Escalation
“Persistence was maintained through web shells and scheduled tasks …” / command lines show “schtasks /create …” and “Register-ScheduledTask …”
Table 11. Scheduled tasks created by the adversary throughout the reported intrusion... The heavy use of scheduled tasks to execute malware aligns with previous Lemon Sandstorm activity. | These backdoors were run using scheduled tasks.
beginning with VPN credential theft and progressively deepening access
Stealth
1 technique
Stealth
beginning with VPN credential theft and progressively deepening access
Discovery
1 technique
Discovery
enabling command execution, file operations, and system discovery
Observables
8 indicators attributed across vendor reports, sandbox runs, and researcher write-ups. Values are masked here and available in full in Mallory.
Recent activity
7 sources tracked across advisories, community write-ups, and news. New activity surfaces here as Mallory finds it.