Skip to main content
Mallory
Malware1 associated actor1 associated CVE

Samurai backdoor

Tracked since Jan 17, 2026 · Updated 7 months ago
Trending this weekNot trendingOutside this week’s top 100
Mention activity · 30 daysNo mention activity in the last 30 days.
Vulns1Associated
Actors1Associated
ATT&CK0Techniques
IOCs8Tracked

Samurai is a modular passive C# backdoor associated with the ToddyCat APT, an espionage-focused cluster active since at least December 2020. It was used in attacks against high-profile entities in Europe and Asia, including government, military, defense-related organizations, and initially compromised Microsoft Exchange servers in Taiwan and Vietnam. ToddyCat first deployed it after compromising Exchange via an unknown exploit and later in broader ProxyLogon-related activity.

Samurai typically operates on ports 80 and 443 and uses the .NET HTTPListener class to process specially crafted HTTP POST requests. It allows arbitrary attacker-supplied C# source code to be compiled and executed at runtime. Reported Samurai-uploaded modules support remote command execution, file enumeration, file exfiltration, and proxying/forwarding TCP traffic. The malware has been used to communicate with internal IPs over ports including 135, 445, 389, 80, and 443 for lateral movement, and in some cases was used to deploy the Ninja post-exploitation tool.

Its configuration is base64-encoded and DES-encrypted with a hardcoded key 90 EE 0C E1 6C 0D C9 0C, and is customized per victim. Configuration can include URI prefixes such as /owa/auth/sslauth/ and victim-domain-specific URL prefixes. On successful execution, Samurai returns HTTP 200 responses containing AES-encrypted, base64-encoded output.

The documented installation chain used a dropper (debug.exe), a C++ DLL loader (iiswmi.dll), and a C# .NET loader (websvc.dll). The dropper decrypted an external payload file, debug.xml, using Wincrypt with CALG_3DES_112 and a static embedded key. Persistence was established by creating a service such as WebUpdate and configuring svchost.exe to load a malicious ServiceDll via registry keys under HKLM\System\ControlSet\Services\WebUpdate\Parameters. The final Samurai payload was stored as a compressed, encrypted, base64-encoded blob in registry keys under HKLM\SOFTWARE\Classes\Interface{6FD0637B-85C6-D3A9-CCE9-65A3F73ADED9}, with some variants using {AFDB6869-CAFA-25D2-C0E0-09B80690F21D}.

Is this in your environment?See whether this family's indicators match your telemetry and which of your assets are exposed to the CVEs associated with it.
Check your exposure
Associated CVEs

Associated vulnerabilities

1 CVE Mallory has correlated with this family across public research and vendor advisories. Each card links to the full Mallory page for that vulnerability.

CVE-2021-26855via securelistExploited in the wildProxyLogon SSRF in Microsoft Exchange Server"From February 26 until early March, we observed a quick escalation and the attacker abusing the ProxyLogon vulnerability to compromise multiple organizations across Europe and Asia."View vulnerability →Source ↗
Threat actors

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.

View more details →
ToddyCat

"The first wave of attacks exclusively targeted Microsoft Exchange Servers, which were compromised with Samurai, a sophisticated passive backdoor that usually works on ports 80 and 443. The malware allows arbitrary C# code execution..."

via securelistsecurelist.com
Indicators of compromise

Observables

8 indicators attributed across vendor reports, sandbox runs, and researcher write-ups. Values are masked here and available in full in Mallory.

View all in app →
Indicator values are available in Mallory. Pivot on every hash, domain, URL, and IP, or pipe them straight into your SIEM.View all in Mallory
Mallory platform

The version that knows your environment.

This page is what’s public. Mallory adds the parts that aren’t: which of your assets match these IOCs, which detections are missing, which campaigns to expect next, and what to do in the next 30 minutes.
IOC matching8Match every observed IP, domain, and hash against your live telemetry.
Associated threat actors1Groups linked to this family, with evidence pinned to each claim.
Associated vulnerabilities1CVEs linked to this family, with the reporting behind each link.
Detection signaturesYARA, Sigma, Snort, and vendor rules, auto-deployed to your SIEM.
MITRE ATT&CK mappingEvery documented technique, ranked by evidence weight.
Researcher chatterReddit, Mastodon, and CTI community discussion around this family.