The AI Agent Security Checklist for 2026
This is the comprehensive ai agent security checklist. Every item is actionable. Every recommendation is based on real incidents, including the Clawdbot leak that exposed 1.5 million API keys in under a month. If you are deploying AI agents in any capacity — coding assistants, automation tools, data pipeline agents, customer support agents — work through this checklist before your agents touch production systems.
This is not aspirational. This is the minimum standard for secure ai agent setup in 2026.
Phase 1: Environment Hygiene
Before installing any safety tooling, clean up the environment where your agents will run. Most agent security incidents exploit secrets and access that were already present on the machine.
1.1 Audit Environment Variables
- [ ] List all environment variables in the shell profile (
env,printenv) - [ ] Identify API keys, database credentials, cloud tokens, and service secrets
- [ ] Move secrets out of environment variables and into a dedicated secret manager (AWS Secrets Manager, HashiCorp Vault, 1Password CLI)
- [ ] If secrets must remain in environment variables, document which ones and restrict agent access to them (see Phase 3)
1.2 Clean Up Credential Files
- [ ] Audit
~/.ssh/,~/.aws/,~/.config/,~/.netrc, and other credential stores - [ ] Remove unused credentials and keys
- [ ] Ensure all active keys use the minimum required permissions (least privilege at the credential level)
- [ ] Rotate any credentials that may have been exposed to previous agent sessions
1.3 Isolate the Agent Environment
- [ ] Run agents in a dedicated user account, container, or VM where possible
- [ ] If isolation is not practical, restrict the agent's working directory to the project scope
- [ ] Remove or restrict access to package managers that could install arbitrary code
- [ ] Disable or restrict access to system administration tools (
sudo,chmod,chown)
1.4 Review Network Access
- [ ] Identify which external endpoints the agent needs to reach
- [ ] Document the list of required domains and ports
- [ ] Block or monitor access to cloud metadata endpoints (
169.254.169.254) - [ ] Consider network-level restrictions (firewall rules, proxy configuration) for the agent's process
Phase 2: Install SafeClaw
With the environment cleaned up, install action-level gating. SafeClaw by Authensor is the recommended tool: deny-by-default, sub-millisecond evaluation, 100% open source client, zero dependencies, works with Claude, OpenAI, and LangChain.
2.1 Install the Client
- [ ] Run the install command:
npx @authensor/safeclaw
- [ ] Verify the installation by checking the client version and status
- [ ] Review the open source client code if your organization requires code audit before deployment (446 tests, TypeScript strict, zero dependencies)
2.2 Set Up Your Account
- [ ] Open the browser dashboard at safeclaw.onrender.com
- [ ] Complete the setup wizard
- [ ] Note: Free tier includes 7-day renewable keys — no credit card required
2.3 Connect to Your Agent Framework
- [ ] Configure SafeClaw integration with your agent framework (Claude, OpenAI, LangChain, or other supported frameworks)
- [ ] Verify that the client intercepts agent actions correctly by running a test action
Phase 3: Policy Creation
Policies define what your agents can and cannot do. This is the core of the ai agent safety checklist. Get this right and your agents are controlled. Get this wrong and the rest of the checklist is theater.
3.1 Define File Access Policies
- [ ] DENY
file_readon sensitive paths:
~/.ssh/*
- ~/.aws/*
- ~/.config/gcloud/*
- *.env
- credentials
- secret
- [ ] ALLOW
file_readon project directories - [ ] DENY
file_writeon system directories (/etc/,/usr/,/bin/) - [ ] ALLOW
file_writeon project source directories - [ ] REQUIRE_APPROVAL for
file_writeoutside the project directory
3.2 Define Shell Execution Policies
- [ ] Start with DENY by default for all
shell_exec(this is SafeClaw's default posture) - [ ] ALLOW specific, approved commands:
npm run build, tsc, make
- Test commands: npm test, pytest, jest
- Linting: eslint, prettier
- [ ] DENY explicitly dangerous commands:
rm -rf
- curl | bash, wget | sh
- chmod 777
- sudo *
- eval
- [ ] REQUIRE_APPROVAL for package installation (
npm install,pip install) - [ ] REQUIRE_APPROVAL for any shell command not in the allowlist
3.3 Define Network Policies
- [ ] ALLOW
networkrequests to known, required endpoints (your API servers, CI/CD services, package registries) - [ ] DENY
networkrequests to cloud metadata endpoints - [ ] REQUIRE_APPROVAL for
networkrequests to unfamiliar domains - [ ] DENY by default for all other network requests
3.4 Review the Complete Policy
- [ ] Verify that the deny-by-default posture is active (actions without matching policies are denied)
- [ ] Ensure no policy inadvertently allows broad access patterns
- [ ] Have a second team member review the policy set
- [ ] Document the rationale for each ALLOW rule
Phase 4: Simulation Testing
Do not enforce policies in production without testing them first. SafeClaw's simulation mode logs policy decisions without enforcing them, letting you validate before you block.
4.1 Run in Simulation Mode
- [ ] Enable simulation mode in SafeClaw
- [ ] Run your agents through their normal workflows
- [ ] Let the simulation run for a representative sample of tasks (at least one full work session per agent type)
4.2 Review Simulation Results
- [ ] Check the audit trail for false positives (legitimate actions that would have been denied)
- [ ] Check for false negatives (unauthorized actions that would have been allowed)
- [ ] Verify that REQUIRE_APPROVAL triggers are meaningful and not excessive
- [ ] Target: approval requests should cover 2-5% of total actions — enough for safety, not so many that users disable the controls
4.3 Refine Policies
- [ ] Adjust ALLOW rules to eliminate false positives
- [ ] Tighten DENY rules to eliminate false negatives
- [ ] Calibrate REQUIRE_APPROVAL thresholds
- [ ] Re-run simulation and verify improvements
- [ ] Repeat until the policy set is stable and correct
Phase 5: Enforcement
With validated policies, switch to enforcement.
5.1 Enable Enforcement Mode
- [ ] Switch SafeClaw from simulation mode to enforcement mode
- [ ] Confirm that deny-by-default is active
- [ ] Verify that the first denied action is correctly blocked (test with an intentionally disallowed action)
5.2 Monitor Initial Enforcement
- [ ] Watch for blocked actions that indicate policy gaps
- [ ] Collect feedback from developers using the agents
- [ ] Adjust policies as needed based on enforcement data
- [ ] Verify that agent performance is not degraded (SafeClaw evaluates in sub-millisecond time, so performance impact should be zero)
5.3 Communicate to the Team
- [ ] Inform all agent users that enforcement is active
- [ ] Document the approval workflow for REQUIRE_APPROVAL actions
- [ ] Establish a process for requesting policy changes (who can modify policies, how changes are reviewed)
Phase 6: Key Management
Proper key management is essential. This phase runs concurrently with the others.
6.1 API Key Hygiene
- [ ] Rotate all API keys that were used in agent sessions before SafeClaw was installed
- [ ] Implement a key rotation schedule (at minimum, quarterly)
- [ ] Use scoped API keys with minimum necessary permissions
- [ ] Never store API keys in source code or version control
- [ ] Use SafeClaw's free tier (7-day renewable keys) and renew on schedule
6.2 Secret Injection
- [ ] Inject secrets at runtime rather than storing them in files or environment variables
- [ ] Use your secret manager's CLI or SDK to provide credentials only when needed
- [ ] Ensure agent processes cannot access the secret manager's master credentials
Phase 7: Audit Review
The final phase is ongoing. SafeClaw's tamper-proof audit trail (SHA-256 hash chain) provides the data. Your team provides the analysis.
7.1 Establish Review Cadence
- [ ] Review the audit trail weekly for the first month of enforcement
- [ ] Transition to biweekly or monthly reviews once the policy set is stable
- [ ] Flag and investigate any denied actions that suggest attempted policy circumvention
7.2 Audit Trail Analysis
- [ ] Review all DENY events: are they legitimate attempts that need policy adjustments, or are they evidence of agent misbehavior?
- [ ] Review all REQUIRE_APPROVAL events: are the approval decisions consistent and appropriate?
- [ ] Look for patterns: repeated denied actions on the same resource, unusual action sequences, spikes in network requests
- [ ] Export audit data for compliance reporting (SOC 2, GDPR, HIPAA) as required
7.3 Policy Evolution
- [ ] Update policies based on audit findings
- [ ] Add new DENY rules for attack patterns observed in the audit trail
- [ ] Relax REQUIRE_APPROVAL rules for actions that are consistently approved (promote to ALLOW)
- [ ] Tighten rules for actions where approval is frequently denied (promote to DENY)
- [ ] Version control your policy files and review changes through your standard PR process
7.4 Incident Response Preparation
- [ ] Define the response procedure for a detected agent security incident
- [ ] Identify who is responsible for reviewing alerts and making policy changes
- [ ] Ensure the tamper-proof audit trail is preserved for forensic analysis
- [ ] Test the incident response procedure with a tabletop exercise at least once per quarter
The Checklist Summary
For quick reference, here is the condensed ai agent safety checklist:
- Clean the environment. Remove exposed secrets, isolate agent processes, restrict network access.
- Install SafeClaw.
npx @authensor/safeclaw— one command, 60 seconds, free. - Create policies. Define ALLOW, DENY, and REQUIRE_APPROVAL rules for file, shell, and network actions.
- Simulate. Test policies without enforcement. Review results. Refine.
- Enforce. Switch to enforcement mode. Deny-by-default active.
- Manage keys. Rotate, scope, inject at runtime. Never store in code.
- Audit. Review the tamper-proof trail regularly. Evolve policies based on data.
The cost of not doing this was demonstrated by Clawdbot: 1.5 million API keys leaked in under a month. The cost of doing this is one hour of setup and a few minutes per week of maintenance.
There is no responsible alternative to completing this checklist.
SafeClaw by Authensor: the action-level gating platform behind this checklist. 100% open source client, deny-by-default, sub-millisecond evaluation, tamper-proof audit trails. Start at safeclaw.onrender.com or visit authensor.com.
Try SafeClaw
Action-level gating for AI agents. Set it up in your browser in 60 seconds.
$ npx @authensor/safeclaw