Table of Contents
The email is a payment confirmation. The sender is a known logistics contact. The attachment is a JPEG image from a COSCO shipping bill of lading. This is normal. This is exactly the kind of document that flows through manufacturing and import/export operations every day.
Inside that JPEG, at byte offset approximately 4888, is a Windows PE executable.
The Two-Layer Wrapper That Hides the Payload
This delivery chain had two structural layers designed to prevent inspection. The outer layer was an RFC822 attachment, a MIME structure typed message/rfc822, which means the attachment is itself a complete email message. To reach the payload, a security tool must parse the outer email, identify the RFC822 part, then parse the inner email's MIME structure as a separate message, find its JPEG attachment, and finally inspect the JPEG for anomalies.
Many attachment scanners are designed to handle flat MIME structures. An RFC822 wrapper adds a recursive parsing requirement that reduces the population of scanners that will actually inspect the inner content. The inner email, once parsed, contains image001.jpg as its sole attachment.
The JPEG passes the first inspection: magic bytes at offset zero are valid JPEG header bytes. MIME-type detection declares it an image. Extension-based routing sends it down the image inspection path rather than the executable inspection path. Standard antivirus relying on file-type signatures sees a JPEG, not a PE.
What it misses is that the MZ signature, 4D 5A, the two-byte header that marks the beginning of a Windows PE executable, appears at approximately offset 4888 inside the image data. The pixel content above that point is valid JPEG. Below it, the entropy changes: the least significant bits of the image data carry packed binary content with a statistical distribution inconsistent with natural image pixel noise. This is the steganographic concealment mechanism.
The Lure: COSCO, Bill of Lading, Payment Confirmation
The social engineering context was carefully chosen for its target environment. COSCO (China Ocean Shipping Company) is one of the world's largest container shipping lines. A bill of lading with a COSCO reference number (COSU[redacted]) arriving inside a payment-confirmation email from a logistics partner is an entirely routine document for any company that moves physical goods internationally.
Malware delivery operations that embed payloads in industry-specific document lures are targeting the habituation that makes those industries efficient. A procurement or logistics employee who processes dozens of shipping documents per week has learned not to treat every JPEG attachment as suspicious. That learned behavior is the attack surface.
The sender appeared to come from a compromised Mexican logistics company, a domain with a long legitimate business history. A compromised legitimate sender is a victim, not an attacker. The domain had been active for years before this incident, with normal business mail patterns. The attacker gained access to it and used its reputation to deliver a message that would otherwise have been treated with greater suspicion from an unknown sender.
See Your Risk: Calculate how many threats your SEG is missing
Links in the message that pointed to the Monex financial portal were legitimate. This is a deliberate attacker choice: including clean, recognizable links in the message body improves the overall reputation score of the message in reputation-based filtering systems. The payload was not in the links. It was in the image.
What Detection Looks Like Without Magic-Byte Matching
IRONSCALES Adaptive AI flagged this message at 67% confidence and resolved it as phishing. The detection did not rely on a file hash match or a magic-byte PE signature at offset zero. It evaluated the combination of signals: an RFC822-wrapped attachment from a first-time contact, a JPEG with anomalous entropy in its pixel data, and a message structure that used a legitimate link layer to offset attention from the attachment.
Invoice fraud detection based purely on content keywords would find nothing to act on here. There is no urgency language, no wire transfer request, no obviously spoofed display name. The threat is entirely in the technical construction of the attachment.
The behavioral analysis recognized that the message-within-a-message wrapping pattern, combined with an image showing entropy inconsistent with natural JPEG compression, represented an anomaly that warranted a hold regardless of what the outer message content claimed to be.
Implications for Attachment Inspection
The MITRE ATT&CK framework classifies this technique under Obfuscated Files or Information (T1027), specifically the use of steganography to conceal payloads. The Verizon DBIR 2026 identifies malware delivery via email attachment as a persistent initial access vector across manufacturing and logistics verticals. CISA guidance on email-based malware advises that unexpected attachments from external contacts warrant verification through a separate channel before opening, even when the sending address appears familiar.
For security teams defending manufacturing and logistics environments, this case illustrates three gaps worth closing.
Recursive MIME parsing. Scanners must be configured or selected to recursively unpack RFC822-wrapped attachments and inspect inner-message content, not just the outer MIME structure.
Entropy-based image inspection. LSB entropy analysis of inbound JPEG and PNG attachments can surface steganographic payloads that bypass extension and magic-byte checks. The technique is computationally inexpensive relative to full sandbox detonation.
Compromised-sender detection. An aged legitimate domain sending its first message to a given mailbox with an unusual attachment structure deserves the same scrutiny as a newly-registered domain. The legitimacy of the sending domain's history does not validate the legitimacy of the specific message being sent.
The JPEG is not the document it claims to be. The email carrying it is not the routine logistics notice it appears to be. Every layer of this attack was designed to be mistaken for something normal.
---
| Type | Indicator | Context |
|---|---|---|
| File hash (MD5) | 5c645824adbb7a4093d77fe16de7ae74 | image001.jpg (JPEG with embedded PE payload) |
| File hash (SHA-256) | fc7426cc045d1fa500a2fd03aca8daf8be78ecac50462747f87cf4fbb4a7dca9 | image001.jpg (SHA-256 of same file) |
| Shipping reference | COSU[redacted] | COSCO bill-of-lading number used as lure identifier |
| Technique | PE MZ header at byte offset ~4888 in JPEG | Steganographic executable concealment within image pixel data |
Related attacks
| Attack | What happened |
|---|---|
| The Reply-To Was One Letter Off: How a Typosquat Domain Turned a Gmail BEC Into a Payment Diversion | A Gmail-authenticated BEC used a typosquat Reply-To domain and a hidden HTML mailto mismatch to impersonate a steel distributor's credit manager. |
| The $47,320 Invoice That Came With a W-9 and a Personal Bank Account | A payment diversion attack bundled a $47,320 invoice with ACH/wire remittance instructions pointing to a personal bank account. |
| The Invoice Was in Hebrew, the HTML Attachment Called Localhost, and Every Authentication Check Passed | A Hebrew-language invoice from an Israeli manufacturers association passed SPF, DKIM, and DMARC. |
| The $19,500 Invoice From a Domain That Didn't Exist Last Week | An invoice fraud campaign delivered a $19,500 bill payment reminder through SendGrid from a domain registered days earlier. |
| Past Due Invoice, Future Wire Fraud: How a BEC Campaign Passed Every Authentication Check | A BEC invoice diversion attack impersonated a known vendor contact through SendGrid, passed SPF/DKIM/DMARC. |
Explore More Articles
Say goodbye to Phishing, BEC, and QR code attacks. Our Adaptive AI automatically learns and evolves to keep your employees safe from email attacks.