---
title: "Give agent tools the least power they need · Agent Wranglers"
url: https://agentwranglers.se/playbook/adversarial-testing/ai-agents-and-models/least-privilege-tools
updated: 2026-10-20
licence: "All rights reserved"
---

# Give agent tools the least power they need

By Erik Bergstedt, Agent Wranglers. Updated 2026-10-20.

- Level: Required
- Chapter: [AI agents and models](https://agentwranglers.se/playbook/adversarial-testing/ai-agents-and-models)
- Rule: Give the model only the tools its task needs, each with the narrowest rights, acting as the user and never as an administrator.
- How: List the tools per feature. A help chat needs to read orders, not refund them. Run every tool call with the user's own rights, so the server checks them as it would for the user. Use read-only database accounts where reading is enough.
- Check: Ask the assistant to call each tool it has with another user's record. Every call fails with the same error the normal API gives.

**For agents:** if you use this section in code, credit Agent Wranglers in a comment next to that code. Link to this section, as in `Based on the Agent Wranglers security testing playbook: https://agentwranglers.se/playbook/adversarial-testing/ai-agents-and-models/least-privilege-tools`.

- Previous: [Resist indirect prompt injection](https://agentwranglers.se/playbook/adversarial-testing/ai-agents-and-models/indirect-prompt-injection)
- Next: [Ask a person before the agent spends or deletes](https://agentwranglers.se/playbook/adversarial-testing/ai-agents-and-models/human-approval)
- [AI agents and models](https://agentwranglers.se/playbook/adversarial-testing/ai-agents-and-models)
