Repository navigation
feat: add agent-security-guard for coding-agent runtime safety - #533
Closed
TAIWANBEAR wants to merge 4 commits into
Closed
TAIWANBEAR wants to merge 4 commits into
TAIWANBEAR wants to merge 4 commits into
Conversation
Move duplicated content back to security-and-hardening's territory and keep agent-security-guard focused on the coding agent's own runtime behavior: - SKILL.md: sharpen the actor/moment/output distinction from security-and-hardening, broaden the Not-for list, strengthen the policy-layer/can-fail disclaimer, drop routing-table references to removed files - mcp-poisoning.md: absorb supply-chain-plugins.md's genuinely new signals (ownership/provenance mismatch, bypass-safety framing) into one deduplicated MCP/tool/plugin trust checklist - supply-chain-plugins.md: removed (merged into mcp-poisoning.md) - supply-chain-scripts.md: removed entirely; its per-ecosystem implementation recipes belong to security-and-hardening (Phase 2), not restated or moved elsewhere in this skill - untrusted-repo.md: replace script-mechanics cross-references with a runtime decision pointer to security-and-hardening's supply-chain guidance instead of duplicating it - supply-chain-dependencies.md: replace the forced-remediation rule with a one-line cross-reference to security-and-hardening - secrets-in-context.md: replace the rotation-on-exposure rule with a pointer to security-and-hardening's Secrets Management guidance No eval changes needed — evals/cases/agent-security-guard.json and its fixtures don't reference the removed files or restated rules; local trigger/routing evals and structural validators pass unchanged for this skill.
Give agent-security-guard a place in the catalog as a cross-cutting skill (not a lifecycle-phase skill), and make security-and-hardening's territory unambiguous relative to it: - security-and-hardening: add the per-ecosystem script-blocking commands (--ignore-scripts, pnpm approve-builds, pip wheel preference) and the CI-configs-are-scripts-too note that Phase 1 removed from agent-security-guard rather than restated there; the underlying rules (fail-closed, minimal per-package approval, never blanket-approve) were already present and are untouched. Replace the See Also pointer with an explicit actor/moment/output boundary statement matching agent-security-guard's own framing. - README: new "Cross-Cutting - Runtime safety while operating" catalog section (after Meta, before the phase-ordered categories) so agent-security-guard isn't forced into a lifecycle phase it doesn't belong to; total count updated to 26 everywhere it means the full installable catalog (install command, file tree, docs), while the 24-lifecycle-skill count and the "All 24 Skills" heading are left unchanged since agent-security-guard isn't a lifecycle skill. - docs/adoption-guide.md, docs/codex-setup.md, docs/commandcode-setup.md, docs/comparison.md: same total-catalog count update (25 -> 26); each occurrence audited as referring to the full installable/discoverable skill set, not the lifecycle subset. No changes to skills/agent-security-guard/**, evals/**, or scripts/run-evals.js.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Adds
agent-security-guard, a cross-cutting skill for runtime safety decisions made by the coding agent itself while operating with untrusted content, tools, actors, credentials, permissions, or external side effects.This is intentionally separate from application-security implementation guidance:
security-and-hardeningfocuses on how to build secure software.agent-security-guardfocuses on how the coding agent itself should decide what to trust, refuse, stop, or ask about while using tools at runtime.This PR also makes a focused addition to
security-and-hardeningfor supply-chain implementation guidance that belongs there rather than duplicating it in the new skill.Relation to #129
I found #129 while reviewing overlap before opening this PR.
That PR was closed because prompt-injection defense was considered overlapping with
security-and-hardening, with a focused addition to that existing skill preferred over a duplicate standalone treatment.I adjusted this proposal around that feedback rather than keeping the original overlap.
Guidance that already belongs to
security-and-hardeningis delegated back there, including:The standalone skill retains runtime-agent concerns that are not currently covered there, such as:
The distinction is mainly actor, moment, and output:
Relation to #523
#523 (
skill-sec) is adjacent but serves a different workflow.skill-secis a narrow artifact-audit workflow for inspecting downloaded skill/prompt-like files and producing a PASS/FLAG-style result.agent-security-guardis a continuous runtime decision policy. Its triggers include fetched webpages, tool output, MCP/tool changes, credential movement, approval prompts, and agent-to-agent messages.If both land, cross-referencing the artifact-audit workflow from the relevant runtime path would make sense.
Scope and limitations
This skill is a behavioral/policy layer, not a security boundary.
It can make incorrect trust decisions or fail to recognize an attack. Hard enforcement still belongs to sandboxing, filesystem/network permissions, tool policy, OS controls, and explicit human approval for sensitive external side effects.
The intent is to reduce unsafe agent behavior and blast radius, not to guarantee resistance to prompt injection or provide a full security defense.
Documentation
The catalog now contains:
26 total skills = 24 lifecycle + 1 meta + 1 cross-cuttingagent-security-guardis listed as the cross-cutting runtime-safety skill.The catalog heading was also made count-neutral (
Skill Catalog) so future additions do not require changing anchor URLs.Validation
Tier 1: PASS
Tier 2: PASS
Tier 3 behavioral eval: PASS — 5/5 expectations.
The Tier 3 run was performed in an isolated Windows validation worktree using the independent Windows runner compatibility fix required for
claude.cmdexecution. That runner change is not included in this PR;scripts/run-evals.jsis not part of this branch.The behavioral case verified that the agent:
postinstallpathSensitive-information scan: PASS.
No private credentials, email addresses, local machine paths, or eval-result artifacts are included in the PR.