bee6e88e6a00d3dae465fabe3c467e48b0b461c99f726505648048db9f563935AgentTesla: bee6e88e — .NET Native AOT-compiled infostealer, Albanian order-confirmation lure
Executive Summary
A .NET Native AOT-compiled x64 AgentTesla variant, delivered as Konfirmimi_i_porosise.exe (Albanian: "Order Confirmation"). Compiled 2024-09-07 with .NET 8.0.5+ and MSVC 14.41. The Native AOT build strips all CLR metadata, rendering the binary opaque to dnSpy/ILSpy while embedding the full BCL runtime (~2.2 MB). A high-entropy (~7.93) custom BINARY resource (DLI91QTATH07DUVDLZLMHANC68RAZ) likely carries the encrypted C2 configuration or secondary payload. Static-only analysis; CAPE skipped due to no Windows guest.
What It Is
| Attribute | Value |
|---|---|
| SHA-256 | bee6e88e6a00d3dae465fabe3c467e48b0b461c99f726505648048db9f563935 |
| Size | 2,232,928 bytes (2.2 MB) |
| Format | PE32+ executable (GUI) x86-64, 8 sections ^[file.txt] |
| Timestamp | 0x66DCDA26 — Sat Sep 7 22:56:38 2024 UTC ^[pefile.txt:50] |
| Linker | MSVC 14.41 (Visual Studio 2022 v143) ^[exiftool.json:18] |
| Runtime | .NET 8.0.5+ (8.0.524.21615\8.0.5+087e15321bb712ef6fe8b0ba6f8bd12facf92629) ^[strings.txt:3620] |
| Native AOT | Confirmed — PublishAot build; no COM_DESCRIPTOR directory ^[pefile.txt:298-299] |
| Version Info | Nonsense masquerade: getEnableUnsafeUTF7EncodingUnorderedNotLessThanSignaling ^[exiftool.json:36-42] |
| Original Filename | Konfirmimi_i_porosise.exe (Albanian "Order Confirmation") ^[metadata.json:4] |
| Signed | true per rabin2 ( Authenticode signature present) ^[rabin2-info.txt:29] |
| Family | AgentTesla — explicit strings AgentTesla, AgentTesla.dll, AgentTesla.exe ^[strings.txt:3591,3592,7428] |
How It Works
1. Delivery & Masquerade
The binary arrives as a fake order-confirmation executable targeting Albanian-speaking victims or Albanian-market businesses. The VS_VERSIONINFO resource is poisoned with a nonsense word-salad string (getEnableUnsafeUTF7EncodingUnorderedNotLessThanSignaling) across all fields — a variant of the version-info-masquerade pattern observed in crypter droppers. ^[exiftool.json:36-42] ^[concepts/version-info-masquerade.md]
2. Anti-Analysis via Native AOT
Unlike traditional AgentTesla samples (which are .NET Framework 4.x assemblies easily reversed in dnSpy), this variant is compiled with .NET Native AOT (<PublishAot>true</PublishAot>). The resulting PE has:
- No CLR header —
COM_DESCRIPTORRVA = 0x0, Size = 0x0 ^[pefile.txt:298-299] - No IL metadata — defeats dnSpy, ILSpy, de4dot, and most .NET-specific EDR heuristics
- Self-contained runtime — entire BCL (10,000+ strings) inlined, inflating file size to 2.2 MB ^[strings.txt]
- Export
DotNetRuntimeDebugHeader— standard Native AOT artefact ^[strings.txt:7429]
This is the first confirmed AgentTesla sample in this corpus using Native AOT; prior confirmed samples (accd2ccd, b017d189) were conventional .NET Framework assemblies delivered via AutoItSC loaders. ^[entities/agenttesla.md]
3. Embedded Resource
The .rsrc section (entropy 7.93, 297 KB) contains a single custom BINARY resource named DLI91QTATH07DUVDLZLMHANC68RAZ — a 25-character random alphanumeric identifier consistent with the unclassified-dotnet-native-aot-loader pattern of encrypted payload staging. ^[pefile.txt:679-701] The resource is not a standard Windows resource type (no icon, manifest, or version block duplication) and its extreme entropy suggests encrypted or compressed content. Given the AgentTesla family's typical behaviour, this likely houses the SMTP C2 credentials, target configuration, or a secondary decrypted module.
4. Capability Surface (Static)
The BCL string noise obscures malicious capability strings, but several survive and align with known AgentTesla TTPs:
| Capability | Evidence |
|---|---|
| SMTP exfiltration | SmtpAccess, SmtpPermission.SmtpPermissionAttribute ^[strings.txt:4283-4284] |
| Registry manipulation | Microsoft.Win32.Registry, RegOpenKeyExW, RegSetValueExW ^[strings.txt:3595] ^[pefile.txt:384-391] |
| Privilege escalation | OpenProcessToken, LookupPrivilegeValueW, AdjustTokenPrivileges ^[pefile.txt:388-390] |
| Process/token manipulation | System.Diagnostics.Process, CreateThread, VirtualAlloc, VirtualProtect ^[strings.txt:3603] ^[pefile.txt:515,522-523] |
| Cryptography | BCryptOpenAlgorithmProvider, BCryptGenerateSymmetricKey, BCryptDestroyKey, BCryptGenRandom ^[pefile.txt:401-405] |
| Anti-debug | IsDebuggerPresent, Sleep, GetTickCount64 ^[pefile.txt:456,555,429] |
| Startup installation | InstallStartup (method name in strings) ^[strings.txt:4538] |
| Hidden execution | HideConsole, ExecuteCommandHidden ^[strings.txt] |
| Administrator check | IsAdministrator ^[strings.txt:4538] |
Notably absent from static strings: hardcoded SMTP server, username, password, or Telegram bot token. These are either inside the encrypted BINARY resource or constructed at runtime from obfuscated fragments — consistent with the unclassified-dotnet-native-aot-loader pattern.
Decompiled Behavior
Ghidra import succeeded but decompilation was hampered by the AOT runtime's aggressive inlining and massive function count. Radare2 analysis (level 3) provided a clearer surface view:
- Entry point (
entry0@0x14006b460): Standard Native AOT CRT startup — calls__get_initial_wide_environment, initializes the runtime, then dispatches to the managedMainequivalent. ^[r2:entry0] - Early init (
fcn.14006b58c): Sets up thread-local storage, condition variables, and exception handling frames. Callsfcn.14006b7f0(runtime type loader init),fcn.14006cc1c(GC initialization), andfcn.14000b4f0(likely module cctor / static constructor runner). ^[r2:fcn.14006b58c] - No obvious reflective loader in the first ~50 functions from entry — the AOT compiler has flattened the usual
Assembly.Loadpattern into direct native calls. - Import table is minimal and legitimate-looking: ADVAPI32, bcrypt, KERNEL32, ole32, plus VCRuntime forwarders. No
wininet,winhttp, orws2_32imports — networking is handled entirely through the inlinedSystem.Net.Httpnative runtime, leaving no Winsock IAT footprint. ^[pefile.txt:376-559]
C2 Infrastructure
No statically recoverable C2. The binary contains SMTP capability evidence (SmtpAccess, SmtpPermission) but no server address, port, or credential material in cleartext. The 297 KB encrypted BINARY resource (DLI91QTATH07DUVDLZLMHANC68RAZ) is the most probable container for runtime C2 configuration. Without dynamic execution or successful resource decryption, the exfiltration endpoint remains unknown.
Historical AgentTesla variants in this corpus used:
- SMTP:
mail.myhydropowered.com(STARTTLS/SSL) ^[entities/agenttesla.md] - FTP and Telegram Bot API as fallback channels
- Hardcoded UUID mutex for single-instance gating
- IP geolocation checks against
api.ipify.organdip-api.com
This sample likely follows the same channel pattern but with configuration moved into the encrypted resource.
Interesting Tidbits
- First Native AOT AgentTesla in corpus — shifts the family's tradecraft from easily reversed .NET Framework assemblies to native-compiled, analyst-hostile binaries. This significantly raises the cost of static analysis for SOC teams relying on dnSpy/ILSpy workflows.
- Authenticode signed —
signed: trueper rabin2. The signature may be valid, invalid, or self-signed; without certificate chain verification, its trustworthiness is unconfirmed. If valid, it would bypass SmartScreen and some EDR reputation checks. ^[rabin2-info.txt:29] - Albanian targeting —
Konfirmimi_i_porosise.exesuggests targeting of Albanian-speaking businesses or individuals, possibly in Kosovo, Albania, or diaspora communities. This is a geographic expansion beyond the usual English/Spanish/German lures observed in prior AgentTesla samples. - Canary enabled, NX/PIC — standard modern compiler security features are present, suggesting the AOT toolchain defaults were not weakened. ^[rabin2-info.txt:6,23,27]
- No FLOSS/CAPA output — FLOSS failed with argument-parsing error; CAPA failed due to missing signatures. Both tools are less effective against Native AOT binaries. ^[floss.txt] ^[capa.txt]
How To Mess With It (Homelab Replication)
Reproducing the Native AOT build
- Install .NET 8 SDK on a Windows or cross-compile via
dotnet publish -r win-x64. - Create a minimal C# project with
<PublishAot>true</PublishAot>and<InvariantGlobalization>true</InvariantGlobalization>(reduces size). - Add a
Resource.resxwith aBINARYentry containing random high-entropy data to simulate the encrypted payload container. - Build:
dotnet publish -c Release -r win-x64 --self-contained - Observe: output PE will have no COM_DESCRIPTOR, export
DotNetRuntimeDebugHeader, and contain 5,000+ BCL strings.
What you learn
- How .NET Native AOT defeats conventional .NET malware analysis pipelines
- Why EDRs relying on CLR hooking or AMSI lose visibility on AOT binaries
- How to pivot to radare2/Ghidra native workflows for .NET malware
Deployable Signatures
YARA Rule
rule AgentTesla_NativeAOT_x64 {
meta:
description = "AgentTesla compiled with .NET Native AOT"
author = "PacketPursuit"
date = "2026-06-30"
hash = "bee6e88e6a00d3dae465fabe3c467e48b0b461c99f726505648048db9f563935"
strings:
$agent1 = "AgentTesla" ascii wide
$agent2 = "AgentTesla.dll" ascii wide
$agent3 = "AgentTesla.exe" ascii wide
$aot1 = "DotNetRuntimeDebugHeader" ascii wide
$aot2 = "System.Private.CoreLib" ascii wide
$aot3 = "CanonType" ascii wide
$aot4 = "UniversalCanonType" ascii wide
$ver = "getEnableUnsafeUTF7EncodingUnorderedNotLessThanSignaling" ascii wide
$smtp = "SmtpAccess" ascii wide
$startup = "InstallStartup" ascii wide
condition:
uint16(0) == 0x5A4D and
uint32(uint32(0x3C)) == 0x00004550 and
uint16(uint32(0x3C) + 0x18) == 0x20B and
filesize > 1MB and filesize < 5MB and
(2 of ($agent*) or 2 of ($aot*)) and
($smtp or $startup)
}
Behavioral Fingerprint
This binary is a 2.2 MB x64 PE with no CLR metadata, a high-entropy (~7.9) custom BINARY resource, and imports limited to ADVAPI32, bcrypt, KERNEL32, and ole32. Upon execution, it initializes a Native AOT runtime, allocates memory via VirtualAlloc, and performs registry queries (RegOpenKeyExW) within the first 30 seconds. Network activity, if any, originates from inlined System.Net.Http code with no Winsock IAT entries. SMTP exfiltration is the expected C2 channel based on BCL string evidence.
IOC List
| Indicator | Value | Notes |
|---|---|---|
| SHA-256 | bee6e88e6a00d3dae465fabe3c467e48b0b461c99f726505648048db9f563935 |
Primary sample |
| Filename | Konfirmimi_i_porosise.exe |
Albanian "Order Confirmation" |
| InternalName | getEnableUnsafeUTF7EncodingUnorderedNotLessThanSignaling.dll |
Nonsense masquerade |
| Compile Time | 2024-09-07 22:56:38 UTC | PE timestamp |
| .NET Version | 8.0.5+ (8.0.524.21615) |
From strings |
| Resource Name | DLI91QTATH07DUVDLZLMHANC68RAZ |
Custom BINARY resource |
| Resource Entropy | ~7.93 | High — likely encrypted |
| Export | DotNetRuntimeDebugHeader |
Native AOT marker |
Detection Signatures
| ATT&CK Technique | Evidence | Confidence |
|---|---|---|
| T1059.003 — Windows Command Shell | ShellExecutor, ExecuteCommandHidden strings |
Medium (static) |
| T1003 — OS Credential Dumping | Microsoft.Win32.Registry, browser-credential-theft BCL presence |
Medium (static) |
| T1115 — Clipboard Data | AgentTesla family TTP | Medium (inferred) |
| T1113 — Screen Capture | AgentTesla family TTP | Medium (inferred) |
| T1056.001 — Input Capture: Keylogging | AgentTesla family TTP | Medium (inferred) |
| T1041 — Exfiltration Over C2 Channel | SmtpAccess, SmtpPermission strings |
High (static) |
| T1027.002 — Obfuscated Files or Information: Native AOT | No CLR metadata, self-contained runtime | High (static) |
| T1497.001 — Virtualization/Sandbox Evasion: Anti-VM | IsDebuggerPresent, Sleep, GetTickCount64 |
Medium (static) |
| T1547.001 — Registry Run Keys / Startup Folder | InstallStartup string |
Medium (static) |
| T1134.002 — Access Token Manipulation: Create Process with Token | OpenProcessToken, AdjustTokenPrivileges |
High (static) |
References
- Artifact ID:
940b5a9c-8e1c-4795-ae6a-2b4be2e1cfa5(OpenCTI) ^[metadata.json] - Source: OpenCTI / MalwareBazaar
- Related wiki pages:
- agenttesla — family entity
- dotnet-native-aot-rat-compilation — technique deep-dive
- unclassified-dotnet-native-aot-loader — umbrella entity for AOT loaders
- version-info-masquerade — nonsense masquerade pattern
- social-engineering-filename-lure — procurement-themed delivery
- smtp-exfiltration — exfiltration channel
Provenance
Analysis derived from static corpus files in raw/analyses/bee6e88e.../:
file.txt— file(1) outputpefile.txt— pefile Python library full PE dumpstrings.txt— GNU strings (default 4-char min)exiftool.json— ExifTool metadatarabin2-info.txt— radare2 binary headerbinwalk.txt— embedded file scanfloss.txt— FLOSS decoded strings (failed — argument error)capa.txt— CAPA capability detection (failed — missing signatures)metadata.json— OpenCTI artifact metadatadynamic-analysis.md— CAPE status (skipped, no Windows guest)
Radare2 analysis performed at level 3 with 120 s timeout on pp-hermes (Lab1BU, <lan>). PyGhidra import succeeded but decompilation queries failed due to binary name suffix mismatch (-eff2c4). Native decompilation relied on radare2 pdc and pdg backends.