The User Deleted the Email — The Attacker Already Had the Attachment
The user recognised the message was suspicious.
They deleted it.
Problem solved?
Not necessarily.
The email timeline showed delivery. The attachment evidence identified the file. And the endpoint telemetry showed something more important:
the attachment had already reached the device before the email disappeared from the mailbox.
Agent Foskett reconstructed what happened before deletion became the final event everyone remembered.

Deletion Wasn't the Beginning
Removing a suspicious email can reduce future exposure, but it does not erase actions that already occurred. The investigation has to move backwards through the timeline.
The user did the right thing — but deletion didn't end the investigation
That was useful containment, but deletion answered only one question: is the message still sitting there now?
It did not answer the more important question: what happened while the message was still present?
If the attachment had already been saved, opened or triggered activity, the investigation had moved beyond email.
Start with the message, not the user's memory
EmailEvents to establish when the message arrived, who received it and the network message identifier used for further pivots.- 1
- 2
- 3
- 4
- 5
- 6
- 7
- 8
- 9
- 10
- 11
- 12
- 13
- 14
- 15
let Recipient = "user@contoso.com";
EmailEvents
| where Timestamp > ago(7d)
| where RecipientEmailAddress =~ Recipient
| project Timestamp,
NetworkMessageId,
SenderFromAddress,
SenderMailFromAddress,
Subject,
DeliveryAction,
DeliveryLocation,
ThreatTypes
| order by Timestamp descIdentify the attachment
EmailAttachmentInfo. This can establish the attachment name, file type and hash values available in email telemetry. Those values become the bridge from the message to the endpoint investigation.- 1
- 2
- 3
- 4
- 5
- 6
- 7
- 8
- 9
- 10
- 11
- 12
- 13
let MessageId = "NETWORK-MESSAGE-ID-HERE";
EmailAttachmentInfo
| where Timestamp > ago(7d)
| where NetworkMessageId == MessageId
| project Timestamp,
NetworkMessageId,
RecipientEmailAddress,
FileName,
FileType,
SHA256,
ThreatTypesDid the attachment reach an endpoint?
DeviceFileEvents. A matching file event can show whether the attachment appeared on a device and where it was written. This does not by itself prove execution, but it establishes that the investigation is no longer confined to the mailbox.- 1
- 2
- 3
- 4
- 5
- 6
- 7
- 8
- 9
- 10
- 11
- 12
- 13
- 14
- 15
let AttachmentSHA256 = "SHA256-HERE";
DeviceFileEvents
| where Timestamp > ago(7d)
| where SHA256 == AttachmentSHA256
| project Timestamp,
DeviceName,
ActionType,
FileName,
FolderPath,
SHA256,
InitiatingProcessFileName,
InitiatingProcessCommandLine
| order by Timestamp ascWas there execution or follow-on activity?
DeviceProcessEvents to search for the attachment name in process and initiating-process command lines, then inspect the surrounding process tree. Documents and archives may lead to child processes rather than becoming executable processes themselves.- 1
- 2
- 3
- 4
- 5
- 6
- 7
- 8
- 9
- 10
- 11
- 12
- 13
- 14
- 15
- 16
- 17
let AttachmentName = "Invoice.pdf";
DeviceProcessEvents
| where Timestamp > ago(7d)
| where FileName =~ AttachmentName
or ProcessCommandLine has AttachmentName
or InitiatingProcessCommandLine has AttachmentName
| project Timestamp,
DeviceName,
AccountName,
FileName,
ProcessCommandLine,
InitiatingProcessFileName,
InitiatingProcessCommandLine,
SHA256
| order by Timestamp ascBuild the timeline backwards from deletion
For example: the email arrives, the attachment is exposed to the user, the file appears on the endpoint, process or network activity follows, and only then is the email deleted.
Deleting the message does not delete the timeline.
What Agent Foskett checked
What the evidence can and cannot prove
Email and endpoint telemetry must be correlated carefully. Filename matches alone can be ambiguous; hashes, device context, timestamps, process ancestry and surrounding activity strengthen the conclusion.
The goal is to determine what actually happened and contain any activity that survived the email's deletion.
The lesson
That was the correct action once they recognised the risk.
But deletion was not evidence that nothing had happened before it.
Agent Foskett followed the message into the attachment telemetry, then followed the attachment onto the endpoint.
The mailbox told him the email was gone. The endpoint told him whether the risk had already moved somewhere else.
Related investigations
Final thought
When a suspicious email has already been opened or its attachment may have been accessed, the investigation must cross the boundary between email and endpoint telemetry.
Follow the evidence. Build the timeline.
The Logs Already Knew! 🔎

