Prompt Injection Attacks: Techniques, Examples and Layered Defenses

· Original article ↗

Summary

This guide explains how direct and indirect prompt injection exploits LLM context, with examples of data leakage and tool abuse. It outlines layered defenses for input handling, permissions, output, and continuous testing.

Key points

  • The article says OWASP ranks prompt injection first in its 2026 Top 10 for LLM Applications and MITRE ATLAS maps it to AML.T0051.
  • LLMs process system instructions and supplied content in the same context, allowing text treated as data to influence model behavior.
  • Delivery surfaces include documents, email, webpages, tool outputs, repositories, images, and clipboard content; payloads may use hidden Unicode, encoding, or multilingual text.
  • Cited demonstrations describe indirect injections that exposed private information through rendered links or images, and a Semantic Kernel example that ran code on its host.
  • The article describes tool-call chains, persistent instructions in memory or rules files, and self-replicating email as ways an injection can extend beyond one response.
  • It characterizes most prompt injections observed on public webpages as low impact so far, while warning that access to email, terminals, or payment tools raises the potential consequences.
  • Recommended controls include limiting context and tool permissions, normalizing and screening inputs, validating tool parameters, sanitizing outputs, and testing defenses with adaptive multi-turn attacks.

Article Details

Topic
Prompt injection techniques, impacts, and layered defenses for LLM applications and agents

Indicators of compromise

TypeIndicatorContext
URLhxxps[:]//aiexecutiveorder[.]com?secret=confettiExfiltration link in a demonstrated Slack AI prompt injection; the payload instructed the model to substitute a private API key.
URLhxxps[:]//asssistant-security[.]com/updatesAttacker-server URL used to fetch subsequent instructions in a demonstrated prompt-injection remote-control attack.

MITRE ATT&CK

CVE

People

Threat Actors

Malware

Vendors

Products

Countries

Related Articles