Claude Code Permissions Hook — Development skill for Claude Code
A PreToolUse hook for Claude Code for more granular permission controls.
How to install Claude Code Permissions Hook
This entry records only its repository, not the path inside it, so there is no
exact command to give. Open kornysietsma/claude-code-permissions-hook and copy the folder into
~/.claude/skills/, or the file into ~/.claude/agents/.
What Claude Code Permissions Hook does
A PreToolUse hook for Claude Code for more granular permission controls.
Alternatives in Development
- Internet Court Skill — The trust layer for agent-to-agent commerce — natural-language mandates, ERC-7710 delegated permissions, x402 4.9k ★
- Ccundo — Integrates seamlessly with Claude Code to provide granular undo functionality by reading directly from Claude 1.4k ★
- WP Abilities API — WordPress capabilities and permissions API 902 ★
README
Command Permissions Hook for Claude Code
A PreToolUse hook for Claude Code that provides granular control over which tools Claude can use, with support for allow/deny rules, pattern matching, and security exclusions.
NOTE: This is a workaround for current (December 2025) limitations in Claude Code permissions - [setting Bash permissions](https://docs.claude.com/en/docs/claude-code/iam#tool-specific-permission-rules) doesn't work consistently. Built following Anthropic's [hook guidelines](https://docs.claude.com/en/docs/claude-code/iam#additional-permission-control-with-hooks).
This may be short-lived as Anthropic improves permissions. Use it if it helps, but you'll need basic Rust knowledge.
Features
- All configuration is via a single
.tomlfile - see example.toml for an example - Allow/deny rules with regex pattern matching for tool inputs
- Exclude patterns for handling edge cases (e.g., block
..in allowed paths) - Audit logging of tool use decisions to JSON file
Documentation
- Configuration Guide - How to write rules for each supported tool
- Tool Input Schemas - Reference for Claude Code tool input formats
Installation
Requires Rust. Install via [rustup](https://rustup.rs/) if you want to use this project. Rust is fun!
cargo build --release
Binary: `target/release/claude-code-permissions-hook`
Configuration
Create a TOML configuration file (see `example.toml`):
[audit]
audit_file = "/tmp/claude-tool-use.json"
# Audit level: off, matched (default), all
# - off: no auditing
# - matched: audit only tool use that hits a rule (allow/deny)
# - all: audit everything including passthrough
audit_level = "matched"
# Allow rules - checked after deny rules
[[allow]]
tool = "Read"
file_path_regex = "^/Users/korny/Dropbox/prj/.*"
file_path_exclude_regex = "\\.\\." # Block path traversal
[[allow]]
tool = "Bash"
command_regex = "^c
Related Skills
Generate Permissions
Generate VAMS Permission Template
Dsh Plugin Product Subagents
Role-based Codex / Claude Code / ACP subagent providers for the DeepSeek Harness — continuable children, durab
Architecture Claude Permission Bypass Removal Planning
Plan and review removal of Claude --dangerously-skip-permissions from autonomous automation paths without losi
Analyze Permissions
Analyze permission patterns and optionally add them to settings.json
Analyze Consented Permissions
Analyze permission grant patterns across sessions and suggest auto-allow configurations
Pursue
Hand Kimi an objective to pursue AUTONOMOUSLY across multiple turns (experimental goal mode), bounded by a har
Related Agents
Permissions Manager
Manage tool permission rules. Use when user says 'allow', 'deny', or 'ask' for a command, wants to modify perm
AI Controls Author
AI system spec, eval suite, tool permission matrix, HITL workflow (taxonomy 4.15). Used by ai-controls-team.
Function Analyzer
Performs ultra-granular per-function deep analysis for security audit context building. Use when analyzing den