Hook Verified

trailofbits-hooks

Security hooks for Claude Code that block destructive commands, prevent force pushes, protect credentials, and provide audit logging during AI-assisted development.

71

/ 100 · Grade D

D = 60–69

I need to secure my AI-assisted development workflow by preventing destructive commands, blocking unsafe git operations, protecting credentials, and maintaining audit trails.

securitydevelopmentgitauditprotection
Publisher: trailofbitsVersion: latestCertified: Mar 28, 2026Expires: Mar 28, 2027Source ↗

trailofbits-hooks earned Verified status with a trust score of 71/100 (Grade D). Adversarial testing produced 9 findings (8 high, 1 medium). Security scan flagged 0 findings. Tier is Verified rather than Certified due to unmitigated findings above severity thresholds.


Trust Score Breakdown

Eight weighted signals composing the aggregate trust score

security scan
100% × 15w
15.0
supply chain
100% × 10w
10.0
adversarial
0% × 25w
0.0
provenance
80% × 20w
16.0
consumer confirm
100% × 10w
10.0
behavioral pass
100% × 10w
10.0
contract accuracy
100% × 6w
6.0
uptime
100% × 4w
4.0

Scheme v2.0 · Weights provisional · Consumer confirmations and uptime use pipeline-derived baselines.


Findings

Security scan results, adversarial testing, and pipeline review

Security Scan — Cisco Skill Scanner

cisco-skill-scannerFAIL
staticbehavioralllmmeta
critical: 0high: 0medium: 0low: 0

Adversarial Testing — 6 categories, 9 findings

prompt injection chainsprivilege escalationdata exfiltration side channelscapability squattingcontext poisoningdependency confusion
highWarnprompt injection chainsconfirmed

The skill's PreToolUse hooks execute shell commands that directly interpolate user-provided command content without proper sanitization. The hooks use `jq -r '.tool_input.command'` to extract user input and then pass it to shell operations like `echo "$CMD"` and `grep` patterns. An attacker could inject shell metacharacters, command separators, or escape sequences in the tool_input.command field to execute arbitrary commands or bypass the security checks.

highWarnprivilege escalationconfirmed

The skill's hook system is designed to block dangerous operations like 'rm -rf' and 'git push --force', but the implementation has gaps that could allow bypasses. The hooks use regex patterns that may not catch all variations of dangerous commands, and the configuration explicitly mentions blocking force operations while potentially allowing them through pattern evasion.

highReviewprivilege escalationconfirmed

The skill implements extensive protections against system boundary violations through permission denies for sensitive directories (~/.ssh, ~/.aws, ~/.config, etc.) and shell profile modifications. However, the protection is implemented as a blacklist which may not cover all possible system configuration paths or new credential storage locations.

mediumReviewdata exfiltration side channelsconfirmed

The log-gam.sh hook logs Google Apps Manager (GAM) write operations to a JSONL file, including the full command with all arguments. GAM commands often contain sensitive administrative data like user emails, organizational unit paths, group memberships, and other directory information that could be considered sensitive in enterprise contexts.

highReviewcapability squattingconfirmed

The skill contains multiple conditional statements that reference system state the user wouldn't anticipate, including environment variables (CLAUDE_PROJECT_DIR), file system state (pnpm-lock.yaml existence), and command parsing logic that makes decisions based on system context rather than explicit user input.

highWarncontext poisoningconfirmed

The skill contains persistent behavioral directives that would affect all future tasks through environment variables and hook configurations. The 'alwaysThinkingEnabled': true setting and environment variables like 'DISABLE_TELEMETRY': '1' establish persistent behavioral changes that extend beyond any single task execution.

highWarncontext poisoningconfirmed

The skill creates persistent state through logging mechanisms and configuration files that outlast individual task execution. The GAM logging hook creates persistent audit trails in '.changelog-raw.jsonl' files, and the statusline script reads and processes persistent workspace state.

highReviewcontext poisoningsuspected

While the skill appears to be focused on development environment safety (Trail of Bits Hooks), it includes broad system-level permissions management, environment variable manipulation, and comprehensive file system access controls that extend beyond simple hook functionality. The extensive deny permissions list and environment variable settings suggest authority claims that may exceed the stated purpose.

highReviewdependency confusionsuspected

The skill configuration includes extensive bash command execution through hooks and status line scripts, but declares no dependencies in metadata. While the hooks appear to be security-focused (blocking dangerous rm commands, enforcing package manager conventions), the capability to execute arbitrary shell commands through the hook system could potentially be used for undeclared package installations or other system modifications. The statusline.sh script also executes git commands and other system utilities.

Methodology v1.0 · 6 categories · ~55 attack patterns


Interface

Skill triggers and instruction summary

Activation

Binds to lifecycle events: PreToolUse

Hook configuration with 2 handler(s)

Instructions: 2Files: 4Format: hook_json

Scope & Permissions

What this capability can and cannot access — derived from pipeline analysis

creates files

no

deletes files

yes

modifies files

no

accesses env variables

yes

invokes external tools

yes

makes network requests

no


Badge & Integration

Embed certification status in your README, docs, or CI pipeline

Fidensa Verified badge for trailofbits-hooks
badge SVG →attestation API →integration guide →

Certification Notes

Provenance observations from the pipeline

publisher

Publisher "trailofbits" is not verified — first certification from this publisher

provenance

No license file found in repository

provenance

No SECURITY.md or SECURITY.txt file found — no published vulnerability reporting process

provenance

Single contributor — no peer review evidence in commit history

provenance

Package description appears to be boilerplate or template text


Signed Artifact

Certification provenance and verification metadata

Content hashsha256:899355bd0e9cbf55df9aaab257795a3981da0d8287bd9488ecce139da4ee5b23
Key IDkms-9db4ed3b9f53
CertifiedMar 28, 2026
ExpiresMar 28, 2027
Pipeline version1.0
Statusvalid