Chock.sh Build your plugin

Policies

Block Risky Characters in File and Branch Names

Block Risky Characters in File and Branch Names: what it does, its label on each agent, what it misses, and examples.

Catalog policy refname-filename-metachar, version 0.1.5, labelled blocks on Claude Code.

What it does

Refuses names a shell, CI step or git can misread. Paths a change adds or renames into (commit, agent writes), and branches and tags pushed (pre-push), with command substitution, an IFS expansion, a backtick, ; & | < >, a double quote, a backslash, a control or bidi character, a base64-decode shape, a leading dash or trailing space or dot in a segment, or a '..' segment; a ref also with a full commit id's shape. A guard refuses git and file commands creating such names. No waiver. Friction, not a boundary.

On each agent

AgentLabelWhat it does there
Claude CodeBlocksRefuses a matched shell command before it runs. Blocks on an agent's file writes and at turn end
CursorBlocksRefuses a matched shell command before it runs. Blocks on an agent's file writes and at turn end
CodexBlocksRefuses a matched shell command before it runs. Blocks on an agent's file writes and at turn end. If the hook errors, the action goes through (not witnessed; the vendor's row is only partly live-run)
GitHub CopilotBlocksRefuses a matched shell command before it runs. Blocks at turn end only. It does not check a file write when it happens. If the hook errors, the action goes through (not witnessed; the vendor's row is only partly live-run)
DevinBlocksRefuses a matched shell command before it runs. Blocks at turn end only. It does not check a file write when it happens. If the hook errors, the action goes through (vendor docs only, not witnessed)
GrokNot gradedNot graded yet for Grok
gooseNot gradedNot graded yet for goose
AntigravityNot gradedNot graded yet for Antigravity
OpenHandsNot gradedNot graded yet for OpenHands
Kimi CodeNot gradedNot graded yet for Kimi Code
Factory DroidNot gradedNot graded yet for Factory Droid

What it misses

This policy does not state what it misses.

Examples from its eval suite

Refused: A change adds a file whose name carries command substitution that decodes and runs a payload.

Allowed: A change adds ordinary source files.

More

Built from engine 5a4b6287a46e and catalog 1e60d211c1bb.