3306 Commits
Author SHA1 Message Date
randRuFlo 1a6e95ff4b chore(release): 3.56.6 (Windows hooks via node -e, SessionStart risk scanner, trajectory feedback, cli-core 3.7.1 / shared 3.0.3 pins); witness regen from a full build
Co-Authored-By: RuFlo <ruv@ruv.net>
2026-10-11 12:06:55 -04:00
rUv 8137b3d2f6 Merge pull request #4061 from ruvnet/batch/rudycelekli-fixes
fix: reviewed batch from rudycelekli (cli-core 3.7.1, shared 3.0.3, ruflo-adr 0.5.5)
2026-10-11 09:03:12 -07:00
randRuFlo 66b42ec532 fix(security): linear-time encoded-powershell match (repeated-token case was quadratic) in both scanners; re-sign helpers
Refs #4052, #4053.

Co-Authored-By: RuFlo <ruv@ruv.net>
2026-10-11 10:52:06 -04:00
r b40e8053ce Merge main into dream/2026-10-11-security 2026-10-11 10:49:55 -04:00
rUv 47ad62e5af Merge pull request #4054 from ruvnet/fix/win-hooks-4045
fix(init): Windows hooks launch through node -e, not cmd /c (#4045)
2026-10-11 07:48:54 -07:00
randRuFlo b662966540 chore: bump cli-core 3.7.1, shared 3.0.3, ruflo-adr 0.5.5 for the reviewed rudycelekli batch
Co-Authored-By: RuFlo <ruv@ruv.net>
2026-10-11 10:46:01 -04:00
r 21622f6769 Merge branch 'pr-4026' into batch/rudycelekli-fixes
# Conflicts:
#	v3/@claude-flow/cli-core/src/output.ts
2026-10-11 10:45:32 -04:00
r 665808183b Merge branch 'pr-4037' into batch/rudycelekli-fixes 2026-10-11 10:45:19 -04:00
r 17ecf82cf9 Merge branch 'pr-4035' into batch/rudycelekli-fixes 2026-10-11 10:45:19 -04:00
r 6f36161c7e Merge branch 'pr-4030' into batch/rudycelekli-fixes 2026-10-11 10:45:19 -04:00
r e2384d4e6e Merge branch 'pr-4029' into batch/rudycelekli-fixes 2026-10-11 10:45:19 -04:00
r ffd66d59fc Merge branch 'pr-4028' into batch/rudycelekli-fixes 2026-10-11 10:45:19 -04:00
r 29b5574fd0 Merge branch 'pr-4025' into batch/rudycelekli-fixes 2026-10-11 10:45:19 -04:00
r 78cd445550 Merge branch 'pr-4024' into batch/rudycelekli-fixes 2026-10-11 10:45:19 -04:00
r 33af710814 Merge branch 'pr-4023' into batch/rudycelekli-fixes 2026-10-11 10:45:19 -04:00
r 096643f123 Merge branch 'pr-4033' into batch/rudycelekli-fixes 2026-10-11 10:45:19 -04:00
r 18ed76d3e0 Merge branch 'pr-4032' into batch/rudycelekli-fixes 2026-10-11 10:45:19 -04:00
r af5b6b92c6 Merge branch 'pr-4022' into batch/rudycelekli-fixes 2026-10-11 10:45:19 -04:00
r cc44e3248c Merge branch 'pr-4021' into batch/rudycelekli-fixes 2026-10-11 10:45:18 -04:00
r 2940c91fcd Merge branch 'pr-4020' into batch/rudycelekli-fixes 2026-10-11 10:45:18 -04:00
ClaudeandRuFlo 25f26f5e3e fix(security): address review — linear-time regex, drop snippet from automatic-boot stdout
Two findings from ruvnet's review on #4053:

1. The powershell/-EncodedCommand pattern (`\s+.*-e(...)`) backtracks
   quadratically on hostile input -- measured ~1.9s on 64,000 spaces with no
   match; a 1MB hook command would stall session-restore (an unconditional
   boot path) for minutes. Rewritten as a linear token-walk
   (`(?:\S+\s+)*?`), confirmed <5ms on a 1MB hostile input while still
   matching real EncodedCommand payloads. Fixed in both the CJS mirror and
   the shared TS original (settings-risk-scanner.ts), since the TS version
   is already live via init/--upgrade.

2. scanSessionStartSettingsForRisk()'s warnings included up to 120 chars of
   the matched hook-command snippet -- but session-restore's stdout is read
   back into the live Claude Code session as context, unlike init/--upgrade
   where a human reads the terminal directly. Printing attacker-controlled
   settings.json content into that context is a prompt-injection path even
   with control characters stripped. The automatic-boot path now prints
   only the scanner-generated location + reason, never the snippet;
   srFormatRiskFindingsAsWarnings (snippet included) is unchanged for
   init/--upgrade's human-facing output.

New tests: a 1MB ReDoS timing guard, a snippet-leak regression guard, and a
real-payload-still-detected check after the regex rewrite. 75/75 related
tests pass.

Co-Authored-By: RuFlo <ruv@ruv.net>
Claude-Session: https://claude.ai/code/session_01HW4yuGGcrCy4CcPgQ7Q2dx
2026-10-11 13:38:47 +00:00
rUv 9723fa33ea Merge branch 'main' into fix/circuit-breaker-completion-window-20261010 2026-10-11 06:31:52 -07:00
rUv 9ad0743e11 Merge branch 'main' into fix/circuit-breaker-stats-date-snapshots-20261010 2026-10-11 06:31:50 -07:00
rUv 37d78d6a17 Merge branch 'main' into fix/json-memory-expired-key-reuse-20261010 2026-10-11 06:31:48 -07:00
rUv f7f7a81471 Merge branch 'main' into fix/json-memory-substring-results-20261010 2026-10-11 06:31:46 -07:00
rUv 0c08382cc6 Merge branch 'main' into fix/rvf-record-owned-snapshots-20261010 2026-10-11 06:31:44 -07:00
rUv 9b83e11f33 Merge branch 'main' into fix/rvf-initialize-retry-indexes-20261010 2026-10-11 06:31:42 -07:00
rUv 3ab24929e3 Merge branch 'main' into fix/rvf-zero-limit-pagination-20261010 2026-10-11 06:31:39 -07:00
rUv 13a72e50ef Merge branch 'main' into fix/output-colored-header-widths-20261010 2026-10-11 06:31:38 -07:00
rUv fd35e71d8a Merge branch 'main' into fix/output-table-padding-width-20261010 2026-10-11 06:31:35 -07:00
rUv 19c59a2a40 Merge pull request #4051 from ruvnet/fix/3662-stepful-trajectory-feedback-indexing
fix(hooks): index trajectory-end feedback even when steps were recorded (#3662)
2026-10-11 06:31:35 -07:00
rUv 3450d0ce13 Merge branch 'main' into fix/output-empty-progress-20261010 2026-10-11 06:31:33 -07:00
rUv 715b80f0bd Merge branch 'main' into fix/json-memory-utf8-size-20261010 2026-10-11 06:31:31 -07:00
randRuFlo a606b3cfeb fix(init): Windows hooks launch through node -e, not cmd /c (#4045)
Under Git Bash MSYS rewrote the /c of the generated cmd /c IF EXIST hook, so cmd
started interactively, executed the hook's stdin JSON and created zero-byte files
from text after a >. The Windows hook is now a single node -e with no cmd, no
%VAR%, and none of < > | & $ or inner double quotes. It keeps the project-first
then user-profile fallback (#1943), user scope never reads the project, and the
helper runs as a child with inherited stdio so stdin and the exit status pass
through. pinToUserHelpers recognises the new form (exact match only) as well as
the old ones.

Co-Authored-By: RuFlo <ruv@ruv.net>
2026-10-11 09:31:30 -04:00
rUv b5ad35cb9c Merge branch 'main' into fix/json-memory-entry-envelope-20261010 2026-10-11 06:31:29 -07:00
rUv 342ad839bb Merge branch 'main' into fix/json-memory-transaction-snapshots-20261010 2026-10-11 06:31:28 -07:00
ClaudeandRuFlo d4b77a05ad dream(security): #4052 wire settings.json risk scanner into the automatic SessionStart hook (evaluated, ACCEPT-scoped)
Closes the gap #3835 itself disclosed: the settings-risk scanner
(CVE-2025-59536-class detection, #3043) ran at init/--upgrade and (pending
#3835) the explicit hooks_session-restore MCP/CLI handler, but never on the
one path that fires automatically on every real Claude Code session boot
-- hook-handler.cjs's session-restore command, wired via .claude/settings.json's
own SessionStart hooks array. Validated against a real 2026 attack campaign
("Mini Shai-Hulud" npm worm) and a real Claude Code CVE (CVE-2026-25725),
both of which use exactly this SessionStart-hook persistence mechanism.

Ports the existing TS scanner's logic (hook-handler.cjs has no build step)
into scanSessionStartSettingsForRisk(), wired into the 'session-restore'
command handler in both the root and package copies of hook-handler.cjs
(kept byte-identical per the existing parity test). An adversarial-critic
subagent review found and this session fixed one real issue pre-commit: a
non-SyntaxError JSON.parse failure would have aborted session-restore
itself rather than degrading gracefully, since this path runs
unconditionally on every boot (unlike the opt-in MCP-tool path #3835
hardened the same way).

Co-Authored-By: RuFlo <ruv@ruv.net>
Claude-Session: https://claude.ai/code/session_01HW4yuGGcrCy4CcPgQ7Q2dx
2026-10-11 06:26:45 +00:00
ClaudeandRuFlo 68dc046a2a fix(hooks): index trajectory-end feedback even when steps were recorded (#3662)
#2351 fixed trajectory-end feedback being dropped, but only for step-less
trajectories (`!hasSteps` gate). The common start -> step -> end path that
real agents use recorded SONA state via `processTrajectoryOutcome`, but the
non-empty `feedback` string was never promoted to the `pattern` namespace,
so it was unreachable through `hooks_intelligence_pattern-search`.

Remove the `!hasSteps` restriction so feedback is promoted whenever it is
non-empty, regardless of whether steps were recorded. `patternsExtracted`
and the `feedbackDistilled` response field already handled both cases
generically, so no other call sites change behavior.

Adds a regression test driving the full trajectory-start -> step -> end ->
pattern-search path, which fails on current main and passes with this fix.

Note: this addresses only the "indexed when steps are present" half of
#3662. The issue's other claim — that `hooks_route` never consults a
persisted SONA `getRoutingSuggestion()` pattern — is real (verified:
`getSuggestion`/`getRoutingSuggestion` have no callers outside
sona-optimizer.ts) but requires an architectural decision (precedence vs.
the AgentDB/semantic routing paths, the confidence threshold, and new
response fields distinguishing "persisted" from "eligible for inference")
that is out of scope for this fix.

Co-Authored-By: RuFlo <ruv@ruv.net>
Claude-Session: https://claude.ai/code/session_01QFyyphjiSXRE1TS2rRnEwU
2026-10-11 05:22:04 +00:00
randRuFlo 19fb5a71de chore(release): 3.56.5 (cli graph header sniff keeps SQLite locks, #4040/#4044); witness regen from a full build
Co-Authored-By: RuFlo <ruv@ruv.net>
2026-10-10 21:52:14 -04:00
rUv fe703f0734 Merge pull request #4046 from ruvnet/fix/integration-no-publishconfig-tag
fix(integration): drop publishConfig.tag (3.0.1 landed on v3alpha, not latest)
2026-10-10 18:25:27 -07:00
randRuFlo 7dc07480ff fix(integration): drop publishConfig.tag so a stable publish lands on latest
3.0.1 was published with tag v3alpha and latest stayed on 3.0.0.

Co-Authored-By: RuFlo <ruv@ruv.net>
2026-10-10 21:09:49 -04:00
r 5b53336c97 Merge remote-tracking branch 'origin/main' into fix/graph-header-sniff-4040 2026-10-10 21:09:17 -04:00
r 9715c50fb7 Merge main into release/3.56.4 2026-10-10 20:30:01 -04:00
rUv 21953adcb0 Merge pull request #4019 from rudycelekli/fix/mcp-inflight-resource-cache-20261010
fix(mcp): fence stale resource cache writes after invalidation
2026-10-10 17:11:22 -07:00
randRuFlo 41fe2242e5 fix(memory): read the RFE1 header in a bounded child so the sniff cannot drop live SQLite locks (#4040)
Co-Authored-By: RuFlo <ruv@ruv.net>
2026-10-10 18:59:36 -04:00
rUv ef13569934 Merge pull request #3999 from proffesor-for-testing/fix/security-scan-false-positives
fix(security): scan code patterns without the false positives seen on a real tree
2026-10-10 15:56:52 -07:00
randRuFlo 762400a3a4 chore(release): 3.56.4 version bumps, changelog, helpers re-signed
Co-Authored-By: RuFlo <ruv@ruv.net>
2026-10-10 18:56:17 -04:00
rUv ebea43a793 Merge pull request #3990 from ruvnet/sec/helper-cli-from-helper-root
fix(helpers): resolve the ruflo CLI from the helper root, not the project (replaces #3953)
2026-10-10 15:54:07 -07:00
rUv 7047b8b030 Merge pull request #3949 from ruvnet/fix/helper-module-root-and-session-path
fix(helpers): resolve modules from the helper root and keep session writes in the project
2026-10-10 15:54:03 -07:00
rUv 570392602a Merge pull request #3952 from ruvnet/fix/user-settings-pin-home-helpers
fix(init): pin user-level hook and statusline commands to $HOME helpers (security review in PR comments)

Co-Authored-By: RuFlo <ruv@ruv.net>
2026-10-10 11:54:50 -07:00