Security best practices
Practical boundaries for agent identity, tool access, and sensitive data.
Limit authority
- Use Kubernetes namespaces and RBAC to scope who can create Agents, Tools, and Runs.
- Configure Agent allowedTools and server-side tool authorization; a prompt-level instruction alone cannot grant or deny permission.
- Place explicit approval gates ahead of expensive, destructive, or externally visible actions.
Protect data and credentials
- Keep model API keys and object-store credentials in a secret manager or Kubernetes Secrets, not repository files.
- Enforce tenant separation where data is fetched and tools run; do not rely on model behavior to filter cross-tenant information.
- Treat tool results and retrieved documents as untrusted input; test against prompt injection and data exfiltration.
Treat retrieved text as data
MCP responses, documents, URLs, and model output can contain instructions that try to redirect the agent. Do not pass these through as trusted policy. Validate tool parameters, target tenant, and requested side effects in application code; separate system instructions from retrieved content and redact secrets before passing data to a model. Test with malicious-looking retrievals as well as legitimate inputs.
Review checklist
- Review the chart-generated Roles and service accounts for least privilege; avoid granting a Run access to unrelated namespaces.
- Bind each tool call to an authenticated tenant and user; verify authorization again at the external service.
- Use per-workload credentials with rotation and audit access to model prompts, traces, and artifacts.
- Apply outbound network policies and allow only approved model, MCP, Temporal, and storage destinations.
- Require human approval for high-impact writes, and make retryable operations idempotent.
- Test tenant-crossing attempts, prompt injection, oversized tool results, and interrupted workflows before onboarding customers.
Verify the deployment
A policy documented here is a deployment requirement, not proof that every listed control is automatically enforced by the platform. Review installed RBAC, credentials, network policies, and connector permissions before handling sensitive workloads.