Indirect Prompt Injection: When an Email Hijacks Copilot

A hidden instruction buried in an email can quietly manipulate Microsoft 365 Copilot. Here's the mechanism, Microsoft's defenses, and the admin controls that actually work.
A Monday Morning in Round Rock
A controller at a mid-size manufacturer outside Round Rock starts her day the way a lot of finance people do now: she asks Copilot to summarize her inbox before she touches anything else. One of the forty-odd emails in there looks like a routine vendor invoice. Buried in the white text at the bottom, invisible to a human reader but perfectly legible to a language model, is a block of instructions telling the assistant to flag an "urgent payment update" and surface a new routing number as if it came from her own AP team. Copilot reads it. Copilot summarizes it. She never sees the hidden text at all, just the assistant's confident, helpful paraphrase.
That's indirect prompt injection, and it's a meaningfully different problem than the chatbot-on-a-website attacks everyone talks about. There's no malicious user typing commands into a chat box. The attacker never touches your system directly. They just mail you something, or drop a file into a shared folder, and wait for your own AI assistant to read it and follow instructions it was never supposed to take from that source.
What Indirect Prompt Injection Actually Is
Strip away the jargon and it's simple: Copilot, like any large language model, can't tell the difference between "the content I'm summarizing" and "the instructions I'm supposed to follow" unless something external forces that distinction. If an email, a PDF, or a shared SharePoint document contains text that reads like a command, the model may treat it as one. The attacker doesn't need access to your network. They need a document that ends up in the context window of a tool your employees already trust.
This matters because Microsoft 365 Copilot only works with data a user already has at least view permission to, per Microsoft's own documentation. That's good news and bad news. Good, because Copilot isn't breaking into anything new. Bad, because it means the attack surface is every file your staff can already open, including inboxes, OneDrive, and Teams channels where oversharing has quietly accumulated for years. Indirect prompt injection doesn't create new access. It weaponizes access that already exists.
What Microsoft Builds In On Its Side
Microsoft has published detail on how it defends against this, and it's worth understanding before you assume the platform handles it for you.
Spotlighting
Spotlighting is Microsoft's term for a set of techniques that help the model tell the difference between trusted instructions and untrusted content pulled from documents or email. It includes delimiting (wrapping external content in clear markers so the model knows it's data, not direction), datamarking (tagging content with metadata that signals its origin), and encoding (transforming content in ways that make embedded instructions harder to execute as commands). None of these are foolproof, but together they reduce how often hidden text gets treated as an order rather than a quote.
Prompt Shields
Prompt Shields is a classifier trained specifically to detect injection attempts, both the direct kind (a user typing a jailbreak) and the indirect kind (malicious instructions hidden inside documents or emails the model is asked to process). It runs as a filter before content reaches the model's reasoning step.
Deterministic blocking
For known exfiltration patterns, like instructions that try to get the model to echo data back out through a tracking pixel, a crafted hyperlink, or an auto-generated email, Microsoft applies deterministic blocking rather than relying purely on the classifier's judgment call. Full detail is in Microsoft's MSRC writeup on indirect prompt injection defenses, and it's a useful read if you want the vendor-side picture before you build your own.
The Controls You Actually Own as Tenant Admin
Here's the part most IT teams skip, because it requires touching Purview rather than reading a blog post and feeling reassured. These are the levers that are yours to pull.
Keep external mail out of Copilot grounding
Microsoft Purview DLP now supports a policy condition specifically for Copilot: "Email is received from > External users." Applied correctly, it keeps externally originated email out of Copilot's grounding data, meaning the assistant won't treat an inbound vendor email as trustworthy source material for its summaries. This is documented on Microsoft's DLP for Microsoft 365 Copilot page, and it's worth saying plainly: this capability is in preview as of this writing. Preview means test it in a pilot group before you roll it tenant-wide, and don't assume it behaves identically to generally available DLP rules.
Sensitivity labels that block processing
Files labeled confidential or higher can be configured so Copilot simply won't process them for grounding or summarization. If your finance, legal, or HR shares carry sensitivity labels already (and if they don't, that's a separate conversation worth having with your Microsoft 365 managed services provider), extend that labeling discipline to explicitly block AI processing of the most sensitive tiers.
Block sensitive information types in prompts
Purview lets you configure DLP to detect sensitive information types, Social Security numbers, bank account formats, credit card numbers, inside the text a user pastes into a Copilot prompt, and block it before the prompt is ever sent. This stops two problems at once: accidental data leakage through careless prompting, and injected content that tries to get a user to paste sensitive data into a follow-up query.
Treat every AI summary as untrusted input
This is a policy change, not a technical one, and it costs nothing to implement. Train your finance and AP staff that a Copilot summary is a convenience, not a verification. Any payment instruction, routing number change, or credential reset that surfaces through an AI summary gets verified through a separate channel, a phone call to a known number, before anyone acts on it. Credential abuse shows up in some form in 39% of breaches according to the Verizon 2026 DBIR, and injected instructions aimed at harvesting credentials or redirecting payments are exactly the kind of social engineering that stat reflects.
Check XPIADetected in the audit log
Microsoft Purview Audit logs CopilotInteraction records, and within the AccessedResources field there's a flag called XPIADetected that fires when the system identifies a cross-prompt injection attempt in content Copilot processed. Most tenants never look at this. If you have a SIEM or a continuous monitoring setup, this flag belongs in your alerting, not buried in a log nobody reads until after an incident. Details are in Microsoft's Copilot audit documentation.
It's worth being direct about something here: a lot of DLP policy documentation and vendor marketing around Microsoft 365 still describes DLP purely as pattern-blocking for data loss, full stop, with no mention of prompt injection at all. That's the state of most public guidance right now. The controls above exist, but you have to know to look for the Copilot-specific conditions rather than assuming standard DLP already covers this.
The Five-Minute Tabletop for Finance
You don't need a consultant and a conference room to test this. Gather your AP team for five minutes and walk through one scenario: a Copilot summary flags an "updated payment instruction" from a known vendor. Ask three questions out loud. Who verifies it, and how? What's the callback number, and is it stored somewhere other than the email that just arrived? What happens if the person who'd normally verify it is out that day? If anyone hesitates on the answer, you've found your gap, and it cost you less time than a coffee run.
Frequently Asked Questions
Does indirect prompt injection require malware on the victim's computer?
No. The entire attack lives inside a document or email that your AI assistant is asked to read and summarize. No malware, no malicious link click required for the injection itself to execute.
Is the external-sender DLP rule enough on its own?
No, and it's still in preview. Pair it with sensitivity labels, sensitive information type blocking in prompts, and staff training on treating AI output as unverified until confirmed through a separate channel.
Can Copilot see files a user shouldn't have access to?
No. Copilot only surfaces data the signed-in user already has at least view permission to, per Microsoft's own documentation. The risk isn't new access, it's existing oversharing being summarized and acted on faster than before.
Who should own monitoring the XPIADetected flag?
Whoever owns your security monitoring, ideally feeding Purview audit data into a SIEM so the flag triggers an alert rather than sitting in a log nobody reviews until after money has moved.
If you're rolling out Copilot across a Houston, Katy, or Sugar Land office and nobody's configured these controls yet, that's a gap worth closing before an attacker finds it for you. Request a free IT assessment and we'll walk through your Purview configuration, your Copilot governance, and where your finance team's verification process actually breaks down under pressure.
Need Help With Cloud Services?
LayerLogix provides expert cloud services solutions for businesses across Houston and nationwide.
Related Articles
Need Expert IT Support?
Let our team help your Houston business with enterprise-grade IT services and cybersecurity solutions.
