Chapter 13
AI Security and Guardrails
Threat-model the AI system, not just the chatbot text box. Test every untrusted channel: user text, retrieved pages, tool output, files, OCR, hidden Unicode, images, and external APIs. Scope tool permissions with least privilege, logging, approvals, and reversibility. Turn…
Apply this chapter
- Threat-model the AI system, not just the chatbot text box.
- Test every untrusted channel: user text, retrieved pages, tool output, files, OCR, hidden Unicode, images, and external APIs.
- Scope tool permissions with least privilege, logging, approvals, and reversibility.
- Turn OWASP-style risks and guardrails into replayable release-blocking eval cases.
Continue the conversation
Apply this to your context.
Save your product context once, then open a focused conversation that combines it with this concept.
7 focused briefs
Concepts in this chapter
- 099AI Security Threat ModelsAI security starts by naming what the system can read, infer, decide, and do.
- 100OWASP Top 10 for LLM ApplicationsThe OWASP LLM Top 10 is useful when security risks need to become concrete eval cases, release gates, traces, and mitigations.
- 101Prompt Injection and Indirect Prompt InjectionPrompt injection is what happens when untrusted text tries to become instructions.
- 102Training Data Poisoning and BackdoorsBad data can teach a model behavior that only appears when the trigger is right.
- 103Model Provenance, Geopolitical, and Nation-State RiskWhere a model is built, hosted, governed, and tuned can matter for security, privacy, continuity, and bias.
- 104MCP Security and Tool PermissioningMCP makes AI systems more useful by connecting tools. It also makes permission boundaries more important.
- 105Guardrails for AI SystemsGuardrails are the code, policy, permissions, human review, and telemetry around a model that limit what bad outputs can do.