hardpress

Prompt Injection and Agent Security: A Plain-English Guide

Nov 24, 2026

AI assistants follow instructions written in plain language. The trouble is that they can’t reliably tell your instructions from instructions an attacker has hidden in something the AI reads. That weakness is called prompt injection, and it is the main security problem for AI agents today.

A simple example

Developer Simon Willison, who coined the term, gives this scenario: you ask an assistant to summarise a web page, and the page secretly says to find your private data and send it to a stranger. There is a good chance the AI simply does it. Researchers have shown the same trick with text hidden in a YouTube transcript, which Tom’s Hardware tested with ChatGPT.

Why it is hard to fix

You may have heard it compared to SQL injection, a classic web attack that was eventually tamed. The UK’s National Cyber Security Centre says the comparison is dangerous. Databases can keep commands and data separate, but today’s language models have no such wall: everything is just text. The NCSC suggests thinking of an AI as an “inherently confusable deputy” and says the goal is to reduce the risk and the damage, not to expect a perfect cure.

The lethal trifecta

Willison’s memorable rule: danger spikes when one agent has all three of these at once.

1. Access to your private data      (email, files, code)
2. Exposure to untrusted content    (web pages, inbound email, documents)
3. A way to communicate outward     (send email, call web addresses)

All three together = an attacker can steal data with a planted message.
Remove any one leg and the risk drops sharply.

Willison also argues that security products which catch most attacks aren’t good enough, since an attacker only needs one to get through. Meta has proposed a related “Rule of Two”: an agent should combine at most two of untrusted input, access to sensitive systems, and the power to change things outside itself.

What you can do

As a user: connect only the tools you need, grant read-only access where possible, and be careful letting an assistant act on email or web pages from strangers. Check what an agent plans to do before approving important actions.
As a builder or manager: give agents the least access that works, require human approval for risky steps, keep logs, and design so that a tricked agent can’t cause much harm.

Where this fits

Prompt injection is one reason the agent habits in our agents post stress limits and approvals.

Further reading

Back to all posts