Excessive agency and improper output handling
On This Lesson 4 topics
This lesson is planned. The outline below lists the topics it will cover. The full lesson has not been published yet.
In this lesson
limit what the model can do and what its output can do.
Planned topics
- Excessive agency: too many tools, too much permission, no approval for side effects. Apply the least privilege from MID-069.
- Improper output handling: model output used as HTML, SQL, shell, or a URL without validation.
- Render output as plain text or sanitized markdown; never execute it; validate structured output against a schema.
- Limit the effect of a successful attack, since you cannot rule it out.
Draft outline details
Demonstration
a tool set before and after: refund(any order) becomes request_refund(order of this user), which creates a pending request.
Check your understanding
Name one rule for model output in a web page.
Show answer
Escape or sanitize it; never render it as raw HTML.
Practice
Apply this lesson with the module's lab, exercises and quiz.
Marking a lesson complete is optional and you can undo it any time. Your progress stays in this browser.