Repository navigation
Release 0.12.0 - #366
Merged
Merged
Release 0.12.0#366
Conversation
…wire backend.apiKey (sable-q9to) (#173) * fix(config): harden RAFTER_API_KEY handling — 0600, redaction, wire backend.apiKey (sable-q9to) Three credential-handling gaps (both Node + Python; intended env/flag path was already fine): 1. Plaintext, world-readable. ConfigManager.save() wrote ~/.rafter/config.json with the default umask (typically 0644). Now writes 0600 (dir 0700) and chmods an existing looser file on the next write — it can hold a backend key. 2. Unredacted echo. `config show`/`get`, the `config set` confirmation, and the MCP get_config tool + rafter://config / rafter://policy resources serialized the full config verbatim, handing any stored key to the terminal / MCP client. Added redactConfigSecrets / maskSecretValue (mask values under keys matching api_?key|token|secret|password|credential → "abcd****"); applied at every render path. Pure — the stored config is never mutated. 3. Dead credential path. backend.apiKey existed in the schema but resolveKey never read it. Wired it as the LOWEST-precedence source: --api-key flag > RAFTER_API_KEY env > global config backend.apiKey. Read only from the global ~/.rafter/config.json (load(), never loadWithPolicy/.rafter.yml — verified it does not merge backend.*), so a hostile repo cannot inject a key that redirects scans to another account. Secure-design pass recorded on the bead: it's a bearer token, so 0600 + display redaction is the right boundary (encrypting a local config just moves a KEK next to the ciphertext); precedence mirrors gh/aws/npm. Tests (both suites): redaction helpers, 0600 on fresh + tightened-on-rewrite, and resolveKey precedence flag>env>config. Node 67 / Python 19 config tests pass; broader config+mcp+api suites green. CLI_SPEC.md documents the resolution order, redaction, perms, and the global-only trust boundary. Note: Node key is backend.apiKey, Python is backend.api_key (dataclass snake_case) — same value, per-language path; redaction regex covers both. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com> * test(mcp): fix stale config-manager mock after redaction exports (sable-q9to) The redaction work added redactConfigSecrets/isSecretConfigKey/maskSecretValue to config-manager, which server.ts now imports — but the vi.mock in mcp-server-integration.test.ts only stubbed ConfigManager, so those imports resolved to undefined and 4 get_config/resource tests threw. Spread the real module (keeping the pure redaction helpers real) and override only ConfigManager. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com> --------- Co-authored-by: Claude Opus 4.8 <noreply@anthropic.com>
Patch bump for the opt-in --deep skill-review engine (sable-7g7) and the RAFTER_API_KEY hardening (sable-q9to). node + python versions matched 0.8.8 -> 0.8.9; CHANGELOG [0.8.9] section added. Co-authored-by: Claude Opus 4.8 <noreply@anthropic.com>
The rafter-security-skill.md frontmatter version (Node + Python copies) was left at 0.8.7 through the 0.8.8 and 0.8.9 package bumps, failing the validate-release 'ClawHub skill version matches package version' gate on the main→prod PR (#176). More importantly, publish-clawhub uses this frontmatter version as the ClawHub release version — so deploying as-is would ship the skill at a stale 0.8.7 while npm/PyPI publish 0.8.9 (cross-registry skew). Bump both to match the package version. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
…n-0.8.9 fix(release): bump ClawHub skill resource versions to 0.8.9
…ands (sable-nf2i)
CommandInterceptor.evaluate() returned {allowed:true, requiresApproval:false}
for critical destructive commands (rm -rf /, fork bombs, dd to disk, mkfs, …)
whenever no commandPolicy was configured — which is the real-world default
(the user's ~/.rafter/config.json often omits agent.commandPolicy). The pretool
hook only denies on (!allowed && !requiresApproval) || requiresApproval, so
allowed=true+approval=false sailed straight through: a security CLI that did not
block `rm -rf /` by default.
Fix: add an UNCONDITIONAL critical-destructive hard-block at the very top of
evaluate(), before any policy is loaded, in both implementations. Critical
commands now always return allowed=false, requiresApproval=false — independent
of whether a policy exists or which mode is set (allow-all and custom deny-lists
can no longer opt out of catastrophic commands). With no policy configured,
high-risk commands now fall back to requiring approval instead of allow-all.
- node/src/core/risk-rules.ts: add matchedCriticalPattern() helper
- python/rafter_cli/core/risk_rules.py: add match_critical_pattern() helper
- both interceptors: hard-block keyed on assessCommandRisk()=="critical",
surfacing the matched built-in pattern; exact node/python parity verified
(16/16 commands identical under the same config)
Updated the policy-mode tests that encoded the old (insecure) contract
(allow-all / custom deny-list / approve-dangerous permitting critical commands)
to assert the hard-block. Repairs the 13 red command-interceptor.test.ts cases,
the hook-integration "blocks rm -rf / even in a git repo" case, and the two
error-handling-gauntlet interceptor cases.
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
…block fix(security): unconditional hard-block for critical destructive commands (sable-nf2i)
…son)
Claude Code appends `--hook-json <data>` to the hook command at invocation; both
CLIs rejected it as an unknown option and exited non-zero, breaking the hook.
Hook input comes from stdin, so the extra flag (and its value) is unused and
safe to discard.
- Node: `.allowUnknownOption()` + `.allowExcessArguments()` on BOTH the pretool
and posttool Commander subcommands (the `<data>` value lands as an excess arg,
so allowUnknownOption alone isn't enough).
- Python: `context_settings={allow_extra_args, ignore_unknown_options}` on the
pretool/posttool `@hook_app.command(...)` decorators. (Setting it on the
hook_app *group* — the prior approach — does NOT reach subcommand parsing, so
`--hook-json` was still rejected; verified the group-only fix fails.)
Declared options like `--format` are still parsed normally. Adds Node + Python
regression tests covering: --hook-json tolerated on pretool & posttool, --format
still honored (not swallowed), and unchanged no-flag behavior. CLI_SPEC.md
documents the tolerance.
Supersedes the original #180 branch (which had no merge-base with main and
bundled an unrelated docs/vitest-upgrade history); re-applied cleanly on main.
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
…-json) fix(hook): tolerate --hook-json flag from Claude Code harness
…te|Edit|MultiEdit rafter agent init --with-claude-code (and agent enable claude-code.hooks) registered the `rafter hook posttool` redaction hook with a catch-all `.*` matcher, so it fired after EVERY Claude Code tool call — including Read and MCP tools, which never produce secrets to redact — adding latency to every operation. Narrow the matcher to the tools whose output is worth scanning: shell output (Bash) and file writes (Write/Edit/MultiEdit). Changed in both install paths per language (init/legacy + component spec), keeping Node and Python identical. PreToolUse matchers are unchanged. Scope is Claude Code only. Codex (.* PostToolUse) and Gemini (.* AfterTool) have the same broad-matcher latency issue and are tracked separately in sable-4alt for platform-correct narrow matchers. Docs (SKILL.md, PLATFORM_PARITY_AUDIT.md, CHANGELOG) and test expectations updated; a PostToolUse-matcher assertion added to the Python install test to mirror the Node coverage. Closes sable-h0ah Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
…posttool-matcher fix(claude-code): narrow PostToolUse hook matcher from .* to Bash|Write|Edit|MultiEdit (sable-h0ah)
…ening) (#184) Triage + remediation of the Rafter scan on main (bead sable-qsig). The large majority of the 780 findings are context-blind SAST false positives for a local CLI (fs/path ops on the user's own filesystem, an XXE rule firing on code that parses no XML, status-string compares flagged as timing attacks, git-diff parsing flagged as URL validation) and intentional demo/fixture secrets. Those are documented and suppressed in a new repo-root .rafter.yml — each entry traced input->sink first, honored by both the local engines and remote `rafter run`. Real fixes applied: - Node dependency CVE bumps via pnpm workspace overrides + direct deps, re-locked: axios 1.13.6->1.18.1, hono 4.12.8->4.12.27, tar ->7.5.17, js-yaml ->4.3.0, fast-uri, path-to-regexp, form-data, follow-redirects, ip-address, qs, brace-expansion all bumped past their fixed versions (~50 CVEs). tsc build clean; affected suites pass. - Python direct-dep floors bumped in pyproject (requests ^2.33.0, urllib3 >=2.7.0, python-dotenv ^1.2.2). Transitive CVEs (via mcp) need `poetry lock` on a box with poetry -> tracked in sable-i7ll. - skill_remote.extract_npm_tarball: skip non-file/dir members (symlink/hardlink/ device) as defense-in-depth on top of the existing zip-slip guard. Local secrets rescan after: 0 active, 488 suppressed (all triaged fixtures). Refs sable-qsig. Follow-ups: sable-i7ll (python poetry lock), sable-ufd9 (backend FP rules behind GH #178/#182). Co-authored-by: Claude Opus 4.8 <noreply@anthropic.com>
Patch release bundling the unreleased changes on main since 0.8.9: - Claude Code PostToolUse matcher narrowed .* -> Bash|Write|Edit|MultiEdit (#183) - Hooks tolerate harness-appended flags, e.g. --hook-json (#180) - Dependency CVE re-lock (axios, hono, tar, js-yaml, +transitives) and remote-skill tarball extraction hardening (#184) Bumps node/package.json + python/pyproject.toml to 0.8.10 (parity), the rafter-security skill resource version (node + python), and finalizes the CHANGELOG 0.8.10 section. Refs sable-ehb1 Co-authored-by: Claude Opus 4.8 <noreply@anthropic.com>
….yml can't suppress them The v0.8.10 publish (run 28332931747) failed at github-action.test.ts "CLI detects secrets in fixture file" (exit 0, expected 1), which gated publish-node — leaving npm at 0.8.9 while PyPI shipped 0.8.10, breaking dual-implementation version parity on the registries. Root cause: PR #184 added a repo-root .rafter.yml that declassifies **/fixtures/** and .github/fixtures/** as triaged false positives for the dogfooding security gate. Six checks scan .github/fixtures expecting detection, but policy discovery walks cwd -> git root, finds .rafter.yml, and suppresses the finding: - node/tests/github-action.test.ts "CLI detects secrets in fixture file" - publish.yaml smoke-test-node / smoke-test-python detection steps - test-action.yml detect-secrets / pip-install / published-v1 jobs (dormant — the path filter didn't fire on #184's root-file change) Fix: keep .rafter.yml exactly as the #184 backend-verified security review set it. Instead, make the detection checks hermetic — copy the fixture to a temp dir outside the repo (smoke/unit tests) or a neutral /tmp path the policy globs don't match (action jobs) so no .rafter.yml is discovered. These checks verify the detection ENGINE and must be decoupled from the repo's own self-scan policy. Verified locally: isolation restores exit 1 for node file/dir scans and the python file scan; github-action.test.ts 81/81. Version stays 0.8.10: twine --skip-existing no-ops the existing PyPI upload, npm publishes 0.8.10 fresh, and create-release cuts the v0.8.10 tag. Bead: sable-nfjq Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
…ture-detection fix(ci): make fixture-detection checks hermetic (unblock v0.8.10 npm publish)
Adds `dop_v1_[a-f0-9]{64}` (severity critical) to the built-in regex scanner in both Node and Python, with tests in each suite. Closes #26.
Co-authored-by: Minh_Nguyen <Minh-Nguyen-2k7@users.noreply.github.com>
Add OpenCode as an MCP-based platform adapter in both the Node and Python implementations, mirroring the existing Cursor/Windsurf/Hermes pattern. OpenCode supports local/stdio MCP servers and reads AGENTS.md natively. Its config schema differs from Cursor/Windsurf: the block is `mcp` (not `mcpServers`), each local server carries `type: "local"`, and command + args are a single `command` array. Registered at ~/.config/opencode/opencode.json with a seeded `$schema` pointer. Verified against https://opencode.ai/docs/mcp-servers/. - Node: installOpenCodeMcp() + --with-opencode flag + auto-detection (~/.config/opencode), dry-run plan, interactive prompt, warnings, next-steps, help hints, and the openCodeMcp() component-registry spec. Wired into status.ts (mcpAgents + detectAgents) and verify.ts (checkOpenCode). - Python: full parity in agent.py and agent_components.py. - recipes/opencode.md, README (platform table, badge, prose lists), and CLI_SPEC.md (--with flag, verify checks table). - Tests: node/tests/agent-init-opencode.test.ts plus mirrored TestInstallOpenCodeMcp / TestOpenCodeDetection in Python; registry ID lists updated (also backfilled the missing hermes.mcp entry). OpenClaw (a separate product) is untouched. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
…JSON
Rafter security review flagged a low-severity parity/robustness gap: when an
existing ~/.config/opencode/opencode.json is valid JSON but the top level is
not an object (an array, string, or number), the Node init path would assign
properties onto it and silently mangle the user's file. Python's init already
guarded this with isinstance(loaded, dict).
- Node installOpenCodeMcp: only accept a parsed object (else warn + replace),
mirroring the Python guard.
- Node/Python component openCodeMcp/_opencode_mcp: coerce a non-object read
result to {} in install(), and guard is_installed()/uninstall() so a
non-dict top-level can't raise.
- Regression tests for array/string top-level configs in both suites.
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Add optional multi-provider support to `rafter run` / `rafter scan` in both the Node and Python implementations. The scan POST body additively gains two OPTIONAL fields — `provider` (gitlab|gitea|bitbucket) and `repo_url` (canonical https clone URL) — sent ONLY for non-github remotes. GitHub requests are byte-identical to today (no provider, no repo_url). - git utils: infer provider from the remote host and normalize both `git@host:owner/repo(.git)` and `https://host/owner/repo(.git)` into a canonical `https://<host>/<owner>/<repo>` repo_url. Host map: github.com→github; gitlab.com / *.gitlab.com→gitlab; bitbucket.org→bitbucket; codeberg.org / *.gitea.io→gitea; anything else→github (backward-compat default). parseRemote/parse_remote return value is left intact for existing callers; detectRepo/detect_repo additively surface provider + repo_url. - backend run + scan command: add optional `--provider` / `--repo-url` flags that override inferred values. Body builder omits both fields whenever the resolved provider is github (or an unknown host that defaulted to github). github_token handling unchanged. - CLI_SPEC.md: document the two flags, the two additive body fields, the host→provider inference table, and the backward-compat rule. - Tests (Node + Python): provider inference per host and both URL forms; github remote produces a body with NO provider/repo_url (byte-identical shape); gitlab/bitbucket/gitea remotes produce the correct provider + normalized repo_url; --provider/--repo-url overrides win. No version bump. No lockfile or .rafter.yml changes. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
…g (ob-y5ep) (#191) The audit logger wrote command lines through `scanner.redact()`, which only masked substrings matching a known secret *pattern*. A command run as `RAFTER_API_KEY=<value> rafter ...` logged the value in plaintext: the key's shape matches no built-in pattern, so `redact()` left it untouched — leaking real API keys into `~/.rafter/audit.jsonl` despite `redact_secrets: true`. Add env-assignment redaction to the shared redaction path (`PatternEngine.redactText` / `redact_text`), so every `scanner.redact(command)` call site benefits (both `logCommandIntercepted` and `logPolicyOverride`). Any `NAME=VALUE` token whose NAME looks secret-bearing (`/(?:^|_)(KEY|TOKEN|SECRET|SECRETS|PASSWORD|PASSWD|PWD|API[_-]?KEY|ACCESS[_-]?KEY|CREDENTIALS?|AUTH)$/i`, which includes RAFTER_API_KEY) has its VALUE masked with the codebase's existing char-mask. This is additive to the existing pattern-based redaction — it catches values that match no pattern but sit behind a secret-named env var. Benign assignments like `FOO=bar` and `NODE_ENV=production` are left untouched. Both implementations updated in lockstep (identical regex, ordering, and mask). Tests added in both suites: a `RAFTER_API_KEY=<val> rafter scan .` command must not leak the raw value into the log, and benign assignments must be preserved. Co-authored-by: Claude Opus 4.8 <noreply@anthropic.com>
…ow-up to #190) (#194) Follow-up polish on @Minh-Nguyen-2k7's Mailchimp pattern (#190): asserts a bare 32-char hex with no -us datacenter suffix does NOT match, in both Node and Python, and removes trailing whitespace on the Python test. Test-only; pattern unchanged. Verified: node secret-patterns 58 passed, python test_regex_scanner 16 passed. Co-authored-by: Minh-Nguyen-2k7 <Minh-Nguyen-2k7@users.noreply.github.com> Co-authored-by: Claude Opus 4.8 <noreply@anthropic.com>
…#195) The rafter skill prompts were all-escalation with no scoping ("DO NOT stop at local", "an un-evaluated 'done' is not done", "default: run rafter run") and never said WHAT counts as security-relevant or when the gate does NOT apply. Agents writing research/experimental code with zero security surface (training scripts, data analysis, plotting, model eval, notebooks, pure computation over trusted local data) kept getting the gate in the way. Fix (prompting only — no executable code changes): add a "When this applies (and when it doesn't)" framing driven by the security SURFACE of the diff, not the task's label. - ENGAGE fully (unchanged, not weakened): auth, credentials/secrets/ tokens/sessions, user/untrusted input, SQL, shell/exec, file paths + uploads, deserialization, crypto, network-facing endpoints, data deletion, dependency/manifest changes. - BACK OFF: research/experimental/local-only/throwaway code with NONE of that surface — a quick surface check suffices, and with genuinely no surface it is fine to proceed without the full rafter-code-review + rafter run. - Key rule landed in every edited skill: judge by the actual security surface of the diff, not by whether the work is called "research." Research code that touches secrets/shell/network/untrusted input still fully engages. Also surface-conditioned the overly-broad `description:` front-matter (that string drives auto-invocation). Files: node/resources/skills/{rafter,rafter-code-review, rafter-secure-design}/SKILL.md and their byte-identical python mirrors under python/rafter_cli/resources/skills/. rafter-skill-review is left unchanged on purpose: vetting third-party executable context before install is always a genuine security surface, so a back-off there would weaken a real gate. This REDUCES false engagement on no-surface code without removing or softening protection for any genuine security surface. Refs: sable-hjd3 AI-assisted (per repo AI Policy): authored with Claude Opus 4.8. Co-authored-by: Claude Opus 4.8 <noreply@anthropic.com>
…el (sable-m9n6) (#196) `rafter agent init` injects RAFTER_INSTRUCTION_BLOCK into agents' instruction files (CLAUDE.md, and ~/.codex/AGENTS.md — a GLOBAL Codex instructions file). The block was a blanket gate ("A security-relevant task is not complete until reviewed... Stop and invoke before continuing") with no scoping. Because Codex reads ~/.codex/AGENTS.md as global instructions, every Codex session was ordered to treat its task as rafter-gated — agents went to read rafter's SKILL.md instead of doing the requested (often no-surface, research) work. Instruction-level hijacking. This applies the same surface-based scoping that PR #195 gave the skill prompts, to the injected block itself, so block and skills tell the same story: - Engage the gate when the change touches a real security surface (auth, secrets/ tokens, untrusted input, SQL/query, shell/exec, file paths, deserialization, crypto, network endpoints/SSRF, data deletion, dependencies). - Back off when NONE of those are present — research/experimental/local-only/ throwaway code (training scripts, analysis, plotting, model eval, notebooks, pure computation over trusted local data): a quick surface check is enough. - Decisive rule: judge by the diff's actual surface, not the "research" label — research code that reads a secret, shells out, hits the network, parses untrusted input, or bumps a dependency still gets the full gate. Guardrail: this reduces false engagement on no-surface code without removing or softening protection for any listed surface — the routing bullets were expanded (crypto, network/SSRF, data deletion, dependencies) so coverage strengthens, not weakens. node and python RAFTER_INSTRUCTION_BLOCK remain byte-identical. Also (sable-h0ah): narrow the Codex .codex/hooks.json PostToolUse matcher from `.*` to `Bash|apply_patch` so posttool stops firing on every Read/MCP call (log noise + latency), matching Codex's own PreToolUse surface and the claude-code posttool scoping. Applied in init.ts, components.ts, and the python mirror; the one test asserting the old value is updated. AI-assisted (Claude Opus 4.8) per repo AI Policy. Co-authored-by: Claude Opus 4.8 <noreply@anthropic.com>
… PostToolUse matcher (#197) The Python dry-run preview still printed 'PostToolUse: .*' after #196 narrowed the actual Codex PostToolUse matcher to Bash|apply_patch (Node's equivalent plan string was updated; Python's was missed). Cosmetic parity fix — the installed matcher was already correct; only the printed plan was stale. Co-authored-by: Claude Opus 4.8 <noreply@anthropic.com>
… stale poetry.lock (#198) Adds an explicit cryptography constraint to pin the in-major fix for GHSA-537c-gmf6-5ccf (held to 46.x to avoid the unrelated 49.x jump). While regenerating, found poetry.lock was STALE and violated its own pyproject constraints — the previously-declared Python security bumps were never locked, so the vulnerable versions were still what actually installed: python-dotenv ^1.2.2 -> lock had 1.0.1 (now 1.2.2) requests ^2.33.0 -> lock had 2.32.4 (now 2.34.2) urllib3 >=2.7.0,<3 -> lock had 2.6.3 (now 2.7.0) cryptography (new pin) -> lock had 46.0.5 (now 46.0.7) lock-version 2.1 preserved (regenerated with Poetry 2.4.1). `poetry check --lock` passes. Python suite: 1495 passed against the new locked deps. Co-authored-by: Claude Opus 4.8 <noreply@anthropic.com>
#195 added the surface-scoping section and grew the rafter router SKILL.md from 118 -> 142 lines, blowing BOTH line budgets (node <120, python <130). With no CI, those two tests have been red on main since it merged. - Condense SKILL.md 142 -> 128 lines: the 11-bullet engage list becomes a compact inline list (every surface kept) and the tier section is tightened. No content dropped — the scoping rule stays in the router, since it decides whether the skill is entered at all and can't be pushed into a sub-doc. - Align the node budget 120 -> 130 to match python's. The limits had drifted: python was bumped 120 -> 130 for the scanner-scope section; node never was. Tests: node brief.test.ts 28 passed; python test_brief.py 35 passed. node/python SKILL.md byte-identical. Co-authored-by: Claude Opus 4.8 <noreply@anthropic.com>
…as a command (sable-4v6e) (#200) The pretool hook hard-denied `gh pr create --body "…git push --force…"` and `git commit -m "don't git push --force"` because it matched risk/policy patterns against the RAW command line — quoted DATA (a PR body, a commit message) was treated as if it were the command. Two compounding defects: 1. Naive matching over the whole line (command-interceptor `matchesPattern` and risk-rules `assessCommandRisk`) saw inside quoted arguments. 2. A `policy.blockedPatterns` hit hard-coded riskLevel:"critical" — a hard deny that ignored the assessed risk — and the default deny-list held loose literals (the substring "rm -rf /" also denied `rm -rf /tmp/build`, which is only HIGH). Fix — an argument-aware sanitizer (`sanitizeCommandForMatching`, new in both risk-rules.ts and risk_rules.py) that all risk/policy matching now runs against: - Tokenize respecting single/double quotes, escapes, `$(…)`/backticks, redirects; split on chain operators (`;` `&&` `||` `|` `&`), kept in place so pipeline rules (`curl … | bash`) still match. - Redact only spans that are DATA: operands of text commands (echo/printf/grep/…), values of prose flags (`-m`/`--message`/`--body`/`--title`/…), and quoted multi-word prose arguments to ordinary commands. - Preserve and RECURSIVELY sanitize spans that are CODE: a shell's `-c` argument (bash/sh/zsh/…), `$(…)`/backticks outside single quotes, eval-style flags (`-c`/`-e`/`--eval`/`-exec`) and execs (eval/exec/ssh/xargs); prefix wrappers (sudo/env/timeout/nice/…) delegate to the command they wrap. The executable token is unquoted so quoting the command name (`"rm" -rf /`, `watch "rm -rf /"`) can't break the anchors. Recursion depth-capped at 8; fails safe (stays flagged). So `bash -c "rm -rf /"` still hard-blocks (its quoted arg IS a command), while `echo "rm -rf /"` is DATA and allowed. Defect 2: a deny-list match now reports the ASSESSED risk (still allowed:false), and DEFAULT_BLOCKED_PATTERNS is exactly the unconditional CRITICAL_PATTERNS set — so `git push --force` stays HIGH / approval-gated as intended, not silently coerced to a critical hard-deny. Node and Python mirrored (0 divergences across a 50-case differential corpus). Tests both directions in both suites; the old "quoting breaks rm -rf" known-gap tests now assert it's caught. Security: reviewed with the rafter agent (adversarial, ~20k differential-fuzz cases). It confirmed no catastrophic command moved from denied to silently allowed, no Node/Python divergence, and no DoS. It surfaced the exec-name quoting bypass (`"rm" -rf /`) — fixed here with tests — and two pre-existing, out-of-scope pattern-coverage gaps filed as sable-urvj (long-form `rm --recursive --force`) and sable-2t0w (Node audit-logger snake_case config). AI-assisted (Claude Opus 4.8) per the repo AI Policy. Co-authored-by: Claude Opus 4.8 <noreply@anthropic.com>
…s something (sable-p8lb) (#351)
…te it is local-only (sable-ce13) (#352)
… -delete on / or ~ are no longer low (sable-e7ju) (#353)
The six bead-named battery and corpus files sat at the root. Move them under fixtures/ next to vulnerable-repo and install-0.11.2, and point the node tests, python tests and the CI battery-floor script at the new path.
drafts/ held Show HN, bounty and research-pitch drafts. They are internal material, now kept privately.
.beads/ is already in .gitignore but its backup JSONL had been committed. Untrack it; the local store is unchanged.
chore: tidy repo root
release: v0.12.0
PR #357 adds an observed-output reference whose examples use the same fake AWS key as README.md. Add it to the existing documentation-examples ignore so the repo's own secret scan stays clean once it lands.
…typer 0.29 compat)
__main__.py patches the Click tree typer builds, which leans on typer internals; 0.29 changed one silently. Cap at the range the suite has been run against (0.27 and 0.29) so the next minor can't break installs unseen.
fix(python): typer 0.29 compatibility; cap typer below 0.30
macOS (APFS) refuses file names that are not valid UTF-8, so the fixture write threw before rafter ran and the macOS cross-platform jobs failed on every outside PR. On such a filesystem the case cannot arise; skip only that write and keep the rest of the test.
test(gates): fix macOS EILSEQ in the Unicode file-name test
…341) * fix: standardize backend error formatting Use shared formatters for backend run, get, and usage errors in Node.js and Python. Add regression tests and document stderr formatting. Co-authored-by: Claude <noreply@anthropic.com> * fix: address backend error-formatting review feedback --------- Co-authored-by: Claude <noreply@anthropic.com>
* docs(#36): add an initial JSON output reference Document observed Node and Python JSON and JSONL output with examples, field descriptions, runtime differences, and stability boundaries. Link the reference from the canonical CLI specification. Defer Sites responses and unobserved backend variants explicitly. Related to #36 Co-Authored-By: Codex <noreply@openai.com> * docs(#36): address JSON reference review Remove internal capture markers and obsolete progress prose, clarify canonical authority, and align severity and engine-field descriptions with observed output. Co-Authored-By: Codex <noreply@openai.com> * docs(#36): clarify the current severity field reference Distinguish the corrected canonical spec from earlier generic examples without changing captured payloads. Co-Authored-By: Codex <noreply@openai.com> --------- Co-authored-by: Codex <noreply@openai.com>
…Node does (sable-2xvl) (#365)
Rome-1
force-pushed
the
prod-release-0.12.0
branch
from
November 15, 2026 02:55
c4fe6c6 to
b842a1e
Compare
Raftersecurity
approved these changes
Nov 16, 2026
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.
Release 0.12.0. Merging publishes @rafter-security/cli and rafter-cli 0.12.0 to npm and PyPI, so Rome merges. Opened as a draft because the publish is on hold: Rome wants to wait for 0.12.1, so that #358 (Datadog pattern) and anything else queued go out together.
This tree is main (2f1b061 plus the CHANGELOG fold), not a cherry-pick branch like 0.11.5–0.11.7. Prod had diverged from main through those cherry-picked releases, so a direct main→prod PR conflicts in 110 files. The branch is main with a
-s oursmerge of prod on top: its tree is byte-identical to main, and it merges into prod with no conflicts. I checked that prod holds nothing main lacks: each fix cherry-picked to prod is on main, the 0.11.x release commits carry main content plus version bumps, and the only files main deletes are the.beads/backup/anddrafts/removals from #359.Contents: see CHANGELOG [0.12.0]. Headlines:
rafter gates, multi-pathsecrets,-aafter a subcommand,--out, local-only usage counters,agent updateand the pretool auto-refresh of installed skills, plus #341 (error formatting) and #357 (JSON output reference) from outside contributors.Release prep done on main:
[Unreleased]entries were folded into [0.12.0].check-version-unpublished.sh 0.12.0passes on npm and PyPI. Package versions match (0.12.0).If this ships as 0.12.1 instead: bump both versions, rename the CHANGELOG heading (or add a [0.12.1] section), and rebuild this branch from main the same way.