Skip to main content
Live Webinar with SANS (June 25)— Agentic CTI Automation for Fun & ProfitRegister Free
Mallory
Malware

SesameOp

SesameOp is a backdoor malware family discovered by Microsoft Incident Response’s Detection and Response Team (DART) in July 2025 during response to a sophisticated intrusion. Microsoft assessed the operation as long-term persistence for espionage-type purposes. The malware abuses the OpenAI Assistants API as a covert command-and-control channel, embedding command exchange in legitimate-looking API traffic rather than using traditional attacker-controlled infrastructure. Multiple sources describe this as the first confirmed case of an LLM API being repurposed for covert C2.

The observed infection chain includes a heavily obfuscated .NET loader, Netapi64.dll, and a .NET backdoor component, OpenAIAgent.Netapi64. The loader was reported as obfuscated with Eazfuscator.NET and loaded into host executables via .NET AppDomainManager injection directed by a crafted .config file. Microsoft reported the broader intrusion also involved compromised Microsoft Visual Studio utilities, internal web shells, and malicious processes used to maintain access. SesameOp uses AppDomainManager injection for persistence and defense evasion, and was observed persisting inside otherwise legitimate host processes, including developer tools.

Functionally, OpenAIAgent.Netapi64 provides the main backdoor capability. It reads configuration from a .NET resource section containing an OpenAI API key, a dictionary key selector, and an optional proxy. It creates the mutex "OpenAI APIS," Base64-encodes the hostname, queries the OpenAI account for vector stores, and retrieves Assistants using pagination. The malware uses Assistant description fields such as SLEEP, Payload, and Result as task indicators. For payload execution, it retrieves a message by thread ID and message ID, then processes a payload consisting of a Base64-encoded AES key protected with a hardcoded RSA key pair and a second blob that is AES-decrypted and GZIP-decompressed. Commands are therefore compressed and protected with layered symmetric and asymmetric encryption. The malware executes attacker-provided code on the victim host, including via a Microsoft JScript VsaEngine call to Eval.JScriptEvaluate, and then compresses, encrypts, and posts execution results back through the OpenAI Assistants API as new messages. Its traffic blends into normal HTTPS communication with api.openai.com, making network-based detection more difficult.

Reported host artifacts include creation of C:\Windows\Temp\Netapi64.start, logging of exceptions to C:\Windows\Temp\Netapi64.Exception, enumeration of C:\Windows\Temp\ for a file ending in .Netapi64, and use of a mutex to ensure a single in-memory instance. Microsoft Defender Antivirus detections cited in the content are Trojan:MSIL/Sesameop.A for the loader and Backdoor:MSIL/Sesameop.A for the backdoor.

Microsoft and OpenAI jointly investigated the abuse and disabled the API key and associated account believed to be used by the actor. The content states this activity was a misuse of legitimate OpenAI API functionality, not exploitation of an OpenAI vulnerability or misconfiguration.

Share:
For your environment

Hunt this family in your stack

Mallory pivots from this family to the IOCs, detections, and named campaigns that touch your stack, and pages you when something new lands.

MITRE ATT&CK

Techniques & procedures

12 distinct techniques documented for this family, organized by ATT&CK tactic.

Execution

1 technique
T1574.014AppDomainManagerEvidence1

The loader uses .NET AppDomainManager injection to persist within otherwise legitimate host processes such as developer tools.

Persistence

1 technique
T1505.003Web ShellEvidence1

The malware establishes persistence through internal web shells and "strategically placed" malicious processes designed for long-term espionage operations.

Privilege Escalation

1 technique
T1055Process InjectionEvidence2

The attack chain observed by DART researchers involved a heavily obfuscated loader and a .NET-based backdoor deployed through .NET AppDomainManager injection into multiple Microsoft Visual Studio utilities.

Stealth

3 techniques
T1027Obfuscated Files or InformationEvidence1

The attack chain observed by DART researchers involved a heavily obfuscated loader and a .NET-based backdoor...

T1055Process InjectionEvidence2

The attack chain observed by DART researchers involved a heavily obfuscated loader and a .NET-based backdoor deployed through .NET AppDomainManager injection into multiple Microsoft Visual Studio utilities.

T1574.014AppDomainManagerEvidence1

The loader uses .NET AppDomainManager injection to persist within otherwise legitimate host processes such as developer tools.

Command and Control

7 techniques
T1001Data ObfuscationEvidence1

Once active, the backdoor fetches encrypted, compressed commands hidden in AI-assistant metadata from the OpenAI API, executes them locally, and returns results using the same legitimate HTTPS traffic.

T1071Application Layer ProtocolEvidence4

a component of the backdoor uses the OpenAI Assistants API as a storage or relay mechanism to fetch commands, which the malware then runs. | Microsoft security researchers have discovered a new backdoor malware that uses the OpenAI Assistants API as a covert command-and-control channel.

T1071.001Web ProtocolsEvidence1

The developer saw a single response. The kernel saw 64 execve events, multiple outbound HTTPS connections, and a process tree several levels deep.

T1090.002External ProxyEvidence1

In July 2025, Microsoft DART documented SesameOp (ATLAS AML.CS0042): malware that used the OpenAI Assistants API as an encrypted command-and-control channel.

T1102Web ServiceEvidence1

"SesameOp... uses OpenAI Assistants API for command-and-control"

T1105Ingress Tool TransferEvidence1

The SesameOp backdoor uses the OpenAI Assistants API as a storage and relay mechanism to fetch compressed and encrypted commands, which the malware decrypts and executes on infected systems.

T1573Encrypted ChannelEvidence1

Results from these commands are likewise compressed, encrypted and sent back via the same legitimate API channel

Exfiltration

1 technique
T1041Exfiltration Over C2 ChannelEvidence1

The information harvested in the attacks is encrypted using a combination of symmetric and asymmetric encryption and transmitted back through the same API channel.

What this page doesn’t show

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 matching

Match every observed IP, domain, and hash against your live telemetry.

Threat actor attribution

Named campaigns wielding this family, with evidence pinned to each claim.

Exploited vulnerabilities

CVEs this family uses for access and lateral movement.

Detection signatures

YARA, Sigma, Snort, and vendor rules, auto-deployed to your SIEM.

MITRE ATT&CK mapping12

Every documented technique, ranked by evidence weight.

Researcher chatter

Reddit, Mastodon, and CTI community discussion around this family.