Security Incident Response

OpenClaw Incident Response Framework

Even with robust security controls, incidents can occur. This guide provides a structured incident response plan specifically designed for AI agent security events — from prompt injection attempts to unauthorized data access.

Severity Levels

LevelDescriptionResponse Time
P1 CriticalAgent executing unauthorized commands on production systemsImmediate
P2 HighData exfiltration attempt detected, agent accessing sensitive filesWithin 1 hour
P3 MediumPrompt injection attempt detected but blocked by defensesWithin 24 hours
P4 LowUnusual but benign agent behavior, false positive alertsNext business day

Immediate Response Steps

  1. Isolate: Run openclaw emergency-stop to immediately halt all agent operations
  2. Preserve: Export logs with openclaw logs export --since 24h before any cleanup
  3. Assess: Review the audit trail to determine scope — what commands were executed, what data was accessed
  4. Contain: Revoke any compromised API keys, rotate credentials, and block the attack vector
  5. Remediate: Update allowlists, tighten approval gates, and patch the vulnerability
  6. Document: Create a post-incident report with root cause analysis and preventive measures

Post-Incident Hardening

After every incident, review and update your security configuration. Consider enabling stricter allowlists, adding more approval gates, and increasing logging verbosity.

Prompt Guardian
Protect your AI agent from prompt injection and malicious commands.
Explore Prompt Guardian →