Sprint 002: Skill enforcement — bypass 감지 + 차단 #2
Reference in New Issue
Block a user
Delete Branch "feature/sprint-002"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Skill context + trace + guard + hooks + CLI. 13 new tests (22 total). F1 해결.
Sprint 002 전체 구현 — F1 (자매 skill bypass) 해결: Enforcement core: - src/enforcement/skill-context.ts — 스킬 컨텍스트 생성/읽기/삭제/만료 체크 - src/enforcement/skill-trace.ts — 도구 사용 추적 (JSONL append) - src/enforcement/guard.ts — pre-tool 가드 (context 유무 + 만료 + escape hatch) Hooks (실제 로직): - hooks/pre-tool.sh — Write/Edit/Bash 게이트 (context 없으면 exit 2) - hooks/post-tool.sh — 도구 사용 trace 자동 기록 CLI: - rails skill-context {create|show|clear} - rails skill-trace {show|blocked} Tests (13 신규, 22 total pass): - skill-context: CRUD + 만료 감지 - skill-trace: append + read + blocked count - guard: no-context 차단, valid 허용, expired 차단, RAILS_ENFORCE=off escape hatch 검증: tsc --noEmit ✓ | vitest 22/22 ✓ | build ✓ | rails --help ✓ Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>View command line instructions
Checkout
From your project repository, check out a new branch and test the changes.