一键导入
security-permissions
Risk-graded permission audit - wraps native /fewer-permission-prompts with allow/ask/deny tiers
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
菜单
Risk-graded permission audit - wraps native /fewer-permission-prompts with allow/ask/deny tiers
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
基于 SOC 职业分类
Flow: Auto - Full Issue Lifecycle in One Shot - Complete end-to-end workflow: start worktree → analyze issue → ELI5 plan + necessity gate → implement ...
Run quality checks (lint + test + typecheck + security) without committing
Flow: Finish - Quality Gates, Commit, Push, and Create PR - Run quality checks, commit changes, push the branch, and create a pull request.
Flow Commands - Streamlined worktree-based development workflow. No locks, no Redis - just git.
Flow: Merge PR and Clean Up - Merge the current branch's PR, then clean up the worktree and branch.
Diagnose flow workflow setup and environment
| name | security-permissions |
| description | Risk-graded permission audit - wraps native /fewer-permission-prompts with allow/ask/deny tiers |
Generated from a Claude Code command. Where the procedure references these Claude-only surfaces, adapt as follows:
~/.codex/config.toml, or fall back to the referenced repo scripts and CLI entry points.scripts/<name> are bundled under scripts/ in this skill directory (byte-identical copies from the claude-power-pack checkout); some expect sibling repo resources, so prefer a full checkout when one is available.A risk-graded wrapper around Claude Code's native /fewer-permission-prompts.
The native skill does a binary read-only / skip split and emits an allowlist only.
This command adds scripts/classify-tool-risk.py to sort every observed tool call
into risk tiers, then proposes a full allow / ask / deny policy.
Use the native
/fewer-permission-promptsfor the quick read-only allowlist. Use this when you also want the mutation and danger tiers surfaced and guarded (it never editspermissions.ask/permissions.denyunless you asked for the graded policy, which this command does by design).
git fetch) +
the safe, reversible subset of local writes (git add, git commit,
mkdir, git worktree add) + read-only MCP tools seen >= 3 times.git push --force, git reset --hard, rm -rf..env, *.pem, *.key,
id_rsa*.Run the graded classifier over recent transcripts:
python3 scripts/classify-tool-risk.py --limit 50
(Run from the CPP checkout. It scans ~/.claude/projects/**/*.jsonl across all
projects, not just the current one.)
Present the tiers as a table (tier, count, examples, verdict). Note that the READONLY-AUTO tier is already covered by Claude Code and needs no rule - do not propose those (see the native skill's auto-allow list).
Propose the policy from the tiers:
allow: READONLY-ADDABLE + the SAFE subset of WRITE-LOCAL. Exclude anything
with a data-loss mode - git checkout, git rm, git branch -D,
git worktree remove, git reset classify as DESTRUCTIVE, not allow.
CODE-EXEC / DUAL-USE-NET / SCRIPT-EXEC are never allowlisted (arbitrary
execution or ambiguous network I/O).ask: the DESTRUCTIVE tier (force push, reset --hard, rm -rf) so it
prompts even under auto-accept.deny: secret files (.env, **/.env, *.pem, *.key, id_rsa*).Merge into the project .claude/settings.json (NOT settings.local.json,
NOT ~/.claude/settings.json): preserve existing keys and entries,
de-duplicate, never remove or reorder. Precedence is deny > ask > allow, so
a secret deny overrides a broad Edit(**) allow.
Report: what was added to each tier, what was already covered by Claude
Code's auto-allow (so no rule was needed), and what was excluded and why
(e.g. dropped python3/uv/make - arbitrary code execution; dropped
curl/gh api - dual-use network).
To auto-allow file edits "only within the git commit list": Claude Code permissions are path-glob based, not git-aware, so this cannot be expressed directly. Two implementations:
Edit(**) / Write(**) for the repo tree plus a
deny list for sensitive gitignored files (.env, keys).PreToolUse hook that runs git check-ignore on the edit
target and blocks ignored paths. This literally scopes edits to tracked files.
Offered, not applied by default./fewer-permission-prompts (a built-in
Claude Code skill, not a CPP skill - which is why its graded extension lives
in CPP).scripts/classify-tool-risk.py (the canonical risk taxonomy).
Re-run anytime for a fresh view.#482 permission-census hook
(scripts/hook-permission-census.sh) captures prompts as they happen and
vendors the same taxonomy inline. This command is the retroactive side
(mine all transcripts, propose a policy in one pass). scripts/tool-risk-drift.py
guards the two taxonomies' safety-critical sets in sync.ask/deny guards are more protective in
~/.claude/settings.json (global, every project); the allowlist is
project-scoped by design. Offer to promote the guards to global.