carlos / platform Public

review: round 1 findings and scoped-check brief, race-helpers

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
claude agent, operated by paul@keymail.dev pushed by paul@keymail.dev 003329bdf52ac89dccadc637cd26e2a1540cd1a3 parent d944ac5
2 files changed, +47 −0
  • docs/superpowers/reviews/CHECK-BRIEF-race-helpers-R1-fix.md +20 −0
  • docs/superpowers/reviews/FINDINGS-race-helpers-R1.md +27 −0
diff --git a/docs/superpowers/reviews/CHECK-BRIEF-race-helpers-R1-fix.md b/docs/superpowers/reviews/CHECK-BRIEF-race-helpers-R1-fix.md
new file mode 100644
index 000000000..4bdfa11de
--- /dev/null
+++ b/docs/superpowers/reviews/CHECK-BRIEF-race-helpers-R1-fix.md
@@ -0,0 +1,20 @@
+# Scoped check: race-helpers, after round 1 (not a review round)
+
+Repo carlos/platform, branch `race-helpers` (tip in the prompt). Round 1
+(`docs/superpowers/reviews/FINDINGS-race-helpers-R1.md`) found one P1: the
+gitleaks census allowance suppressed real hex credentials. The fix is
+commit d944ac57. Scope: `git show d944ac57` and `.gitleaks.toml` only.
+
+Check:
+1. The P1: resolved, partly, not. Each digest allowlist now matches the
+ whole line (`regexTarget = "line"`): census tests a complete five-field
+ entry; always-awake-consumers.json a .go path and a 64-hex digest; one
+ chunk-boundary pattern for plan9_b8_census_test.go. Can a real
+ credential still pass any of these (including the chunk-boundary
+ pattern, which checks only the last line of a chunk)?
+2. Every other allowlist entry: exact, anchored values only?
+3. Does the file still fail closed if gitleaks' config fails to parse?
+
+Answer each: OK, or a finding with file:line, failure scenario and fix,
+marked P1 or P2. End with exactly one line: CHECK PASSED, or CHECK FAILED
+with the P1s. Do not edit files, spawn reviewers or run full suites.
diff --git a/docs/superpowers/reviews/FINDINGS-race-helpers-R1.md b/docs/superpowers/reviews/FINDINGS-race-helpers-R1.md
new file mode 100644
index 000000000..d254ab5db
--- /dev/null
+++ b/docs/superpowers/reviews/FINDINGS-race-helpers-R1.md
@@ -0,0 +1,27 @@
+Reviewed `origin/main...f8014804fbe1dd7e450c6bddb4b9b8032b840dc3`, round 1. The difference from the brief’s named commit, `302b9886`, is only the brief itself.
+
+- **P1 — The census allowance also suppresses real hexadecimal credentials.**
+ [.gitleaks.toml:32](/home/paulca/amadan.net/carlos/platform-race-helpers/.gitleaks.toml:32) allows every `generic-api-key` finding consisting of 10–64 lowercase hexadecimal characters anywhere in matching census files or `implementation/always-awake-consumers.json`. It does not check whether the value occupies a source-digest field.
+
+ **Failure scenario:** someone copies a real hexadecimal API key into a census test—for example, an `api_key = "…"` assignment. Both allowance conditions match, so the new security step silently accepts it.
+
+ **Evidence:** the pinned v8.30.1 executable detected a synthetic 64-character hexadecimal API key through stdin and returned exit 1. The configured path and value expressions both match that value in an existing census-file path. Inspection of v8.30.1’s `checkFindingAllowed` confirms that this conjunction suppresses the finding. This conclusion combines the detector check with source inspection; I did not plant a file in the worktree.
+
+ **Fix:** retain the path restriction, but match the actual census-entry or JSON digest-field structure using `regexTarget`, or enumerate exact approved digests. Verify that a synthetic hexadecimal credential elsewhere in the same files still fails.
+
+ **Fault family:** secret-scanning exceptions must distinguish approved source digests from credentials.
+
+No additional P2 or P3 findings.
+
+The remaining checks found:
+
+- **No production Go changes:** all 78 changed Go files are tests. The other changes concern CI, configuration and documentation.
+- **Race gate:** discovery and shards receive `-race`; nonzero job statuses propagate to failure. Normal mode retains its existing commands. The bcrypt timing exclusion and reduced simulation seeds are consistent with the tests and documented scope.
+- **Excluded packages:** the README explicitly records activator’s unfinished cleanup work and lease’s dependency race. Cached litestream sources confirm that v0.5.14 closes databases before stopping monitors, while v0.5.18 reverses that order.
+- **Log capture:** the shared buffers synchronize reads, writes and resets. Review across all three packages found no additional assertion regression from the migration.
+- **Test fixes:** the rootfs cgroup-reader installation, separate claimstop context, wakecheck callback cleanup and concurrent bootstrap pipe drain address their stated failures.
+- **Ratchet:** only lowered—one sleep allowance removed and one function-length allowance reduced from 332 to 330.
+
+Shell syntax checks and `git diff --check` passed. The cached, pinned gitleaks executable rejected synthetic hexadecimal and GitHub-shaped credentials. Full suites were not run. The read-only sandbox prevented Go build-directory creation, so the complete Make targets were not executed. No files were changed or reviewers spawned.
+
+NOT READY
\ No newline at end of file