Repository navigation
feat(OMN-20926): the content-capture producer stores detected secrets and emits references - #2672
Merged
Merged
Conversation
jonahgabriel
pushed a commit
to OmniNode-ai/onex_change_control
that referenced
this pull request
Oct 11, 2026
) * evidence(OMN-20926): author OCC companion for OmniNode-ai/omniclaude#2672 OCC companion by node_pr_lifecycle_fix_effect (OMN-13317 F1 / OMN-13990 / OMN-14285). Product PR head d3859a4cb2db6da5cbf9e41b556bdcf4f43eb78c. * evidence(OMN-20926): self-bind OCC#13623 + rebind contract_sha256 --------- Co-authored-by: omnimarket-bot <bot@omninode.ai>
jonahgabriel
enabled auto-merge (squash)
October 11, 2026 01:02
Contributor
✅ Hostile Reviewer — PASSEDBlocking findings (critical/error): 0 Findings
Gate semantics (pilot phase)
Powered by omniintelligence.review_pairing.cli_review — node-based adversarial review via HandlerLlmCliSubprocess (OMN-8524) |
… and emits references
Operator ruling 2026-10-10 (RULING row 2026-10-10T22:38:48Z,
lane=secret-refs-9f8a): when the content scrubber finds a secret in captured
content, the secret is stored in the secret store and the record carries a
reference in its place. Ciphertext never goes on the bus.
This is the omniclaude half; omnimarket owns the contract and both effects.
- capture_redaction.py (the producer's resolver) parses the contract's new
secret_reference block fail-closed, keeps references standing through every
scrub exactly as omnimarket's resolver does, and never cuts a reference at a
chunk boundary or the size cap. prepare_content_records takes a secret sink:
each detected secret is offered to it, a returned reference replaces only
the value (a label and a closing quote stay), and a span the sink does not
take crosses as the scrub marker. The record carries stored_refs
{stored, fallback, reason}: counts and a reason code only.
- hook_content_capture.py's sink is omnimarket's captured secret store effect,
imported only when a capture finds a secret. A store failure falls back to
the marker and journals a loud hook.health.error (reason code and count,
never a value); a machine with no store configured, or an omnimarket that
predates the effect, falls back quietly.
- The mirrored contract is re-derived from omnimarket, and the posture drift
check compares the secret_reference block too.
… a secret-shaped keyword The pre-push secret scanner reads a keyword argument named like a secret as a hardcoded value. The contract block keeps its name; only the resolved field on omniclaude's RedactionContract changes.
jonahgabriel
force-pushed
the
jonah/omn-20926-captured-secret-refs
branch
from
October 11, 2026 17:07
d3859a4 to
c99ab78
Compare
jonahgabriel
added a commit
that referenced
this pull request
Oct 11, 2026
…d of skipping off macOS (#2692) The two Darwin-only skipif tests added by omniclaude#2680 skipped on the Linux runner and sat outside the test-split skip baseline, so every full-width Tests (Split n/m) run failed the Skip Count Ratchet (OMN-18776): omniclaude #2664, #2672 and #2683. The baseline is shrink-only, so the tests change, not the baseline: the parse leg runs bash -n with /bin/bash 3.2 on macOS and the PATH bash elsewhere, and the positive control asserts macOS refuses the outage pre-image while any other bash accepts it, which is why the static scan exists. Onex-Lane: hook-bash32-9f8a Onex-Session: 087b253dbb0448959a08c95511d7ddb3
Re-derived src/omniclaude/hooks/contracts/capture_redaction.yaml with generate_event_registry.py --sync-capture-contract against omnimarket at a commit containing omnimarket#3747. The Registry Consistency check had failed on the mirror as drifted (keys secret_patterns, secret_reference, topics). Result: 7 insertions, 1 deletion in the mirror. After the sync: - generate_event_registry.py --check passed (77 event types) - check_registry_consistency.py passed - 86 capture tests passed, 2 skipped
… tests Merged origin/dev into the branch. Advanced the omnimarket git pin in pyproject.toml and uv.lock from a44caa7efd79 to f7ff837dfb88 so the registry drift check reads an omnimarket that carries omnimarket#3747. Added contracts/OMN-20926.yaml with four acceptance criteria bound to the focused secret-reference tests and the registry parity check. Added two tests for sub_keeping_references: a match starting inside a reference keeps the reference and the text after it; a zero-width pattern terminates and leaves references standing. The mirrored capture_redaction.yaml was re-derived with --sync-capture-contract and did not change. Focused tests: 78 passed before the two new tests, 16 passed in the secret refs file after.
… merge base The dod-omn20926-mirror-parity check ran the sync test module, which passes at the merge base, so repo-evidence refused it as an always-pass control. It now runs a test of the new secret_reference posture key: it fails when the generator does not compare that block and passes when it does.
…t fix landed The pin-test fix merged to dev with its own contracts/OMN-20926.yaml, which collides with this branch's contract of the same name. The merged contract keeps both requirements, evidence commands and dod entries; the pin-test criteria are renumbered AC5 and AC6 so the ids stay unique.
…th dev contracts/OMN-20926.yaml: the two evidence items dod-omn20926-ac1-pin-tests-fetch-by-sha and dod-omn20926-ac2-pin-ancestry-unshallow now match, field for field, the items already on dev, so repo-evidence / dod-verify treats them as carried from the merge base. Reason: the pin-test fix landed on dev in #2710, so those tests pass at the merge base and a rebound item failed the base control as always-pass. Acceptance ids renumbered: the pin criteria are AC1 and AC2 again as on dev; the capture criteria are AC3 to AC6. No code or test change.
jonahgabriel
added a commit
that referenced
this pull request
Oct 13, 2026
…dger check (#2715) * ci(OMN-20708): add claim_source input and work-ledger check reader The reusable workflow gains a claim_source input with values file (default) and work-ledger. With work-ledger, the job reads the check "branch-claim / work-ledger" posted on the pull request head by the GitHub App onexbot-occ-writer (omnimarket's node_branch_claim_check_effect, omnimarket#3547). It opens no database connection and checks out no ledger. The job waits up to 900 seconds (input lab_check_wait_seconds). This change is the earlier draft omniclaude#2608 rebased onto dev. The folded branch-claim-gate.yml no longer exists, so its wiring is now in ci.yml. The caller branch-claim-check.yml names claim_source: file explicitly and gains checks: read. It stays on file until a completed lab check is visible on an omniclaude pull request head; none was visible on omniclaude#2708, #2710, #2711 or #2672 on 2026-10-13. tests/scripts/test_branch_claim_check_workflow.py runs the reader's own Bash with a fake gh and real jq. It no longer skips when jq is missing; it fails. New named cases: ledger_absent_passes, work_ledger_source_runs_no_ledger_step, claimed_elsewhere_refused, branch_claim_check_workflow_is_wired. The test is a named step "Branch-claim check workflow reader (OMN-20708)" of the Branch Claim Gate job in ci.yml, and a check-only pre-commit hook branch-claim-check-workflow. The Branch Claim Gate path filter now names the caller, the test and .pre-commit-config.yaml. contracts/OMN-20708.yaml added with three acceptance criteria and their dod_evidence. 38 tests in the file pass. Not changed: scripts/branch_claim.py, the pre-push hook, required-checks.yaml, branch protection. * fix(OMN-20708): add paths and trust boundary comment The CI check "Tests (Split 2/2)" failed on head 822752b at tests/workflows/test_blocking_validation_workflows.py::test_filter_is_the_original_trigger[branch-claim-gate]. The PR widened the Branch Claim Gate path filter in ci.yml with three paths: tests/scripts/test_branch_claim_check_workflow.py, .github/workflows/branch-claim-check.yml, and .pre-commit-config.yaml. This commit adds those three paths to the test's FOLDED_JOBS entry for branch-claim-gate, in the filter's order. The Hostile Reviewer gate blocked on one finding agreed by two voters: that the lab check outcome is spoofable via the check-runs API. This commit adds a comment above the "Read the lab branch-claim check for this head" step in branch-claim-check-reusable.yml stating the trust boundary: GitHub sets a check run's app from the creating token, so only the named App's installation token can publish a run the step accepts; GITHUB_TOKEN publishes as github-actions. The comment also notes jq @uri escapes & = # in the check name. No behaviour change in the workflow. Focused tests: 71 passed in test_blocking_validation_workflows.py (branch-claim/folded selection), 38 passed in test_branch_claim_check_workflow.py.
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.
OMN-20926: the content-capture producer stores detected secrets and emits references
Operator ruling 2026-10-10 (RULING row 2026-10-10T22:38:48Z, lane=secret-refs-9f8a): a secret the content scrubber finds is stored in the secret store and the record carries
secret://onex/captured/<hex>in its place; consumers resolve through the store. Ciphertext never goes on the bus. Mechanism ticket OMN-20926 (parent OMN-20768).Companion of OmniNode-ai/omnimarket#3747, which owns the contract and both effects. This PR's mirrored contract is re-derived from that branch, so the registry drift check (which reads the omnimarket rev uv.lock pins) goes green once #3747 is released and the lock is bumped. Land #3747 first.
Changes
capture_redaction.py: parses thesecret_referenceblock fail-closed, keeps references standing through every scrub exactly as omnimarket's resolver does, and never cuts a reference at a chunk boundary or the size cap.prepare_content_recordstakes a secret sink: each detected secret is offered to it, a returned reference replaces only the value, and a span the sink does not take crosses as the existing marker. Records carrystored_refs{stored, fallback, reason}: counts and a reason code only.hook_content_capture.py: the sink is omnimarket's captured secret store effect, imported only when a capture finds a secret. A store failure (unreachable, login or write refused, misconfigured) falls back to the marker and journals ahook.health.errornaming the reason and count, never a value. A machine with no store configured, or an omnimarket that predates the effect, falls back quietly. Capture is never blocked.generate_event_registry.py: the posture drift check compares thesecret_referenceblock.Access needed (cloud owner)
Writer (create only) and reader (read only) identities for the captured folder; exact request on OMN-20926. Until they exist every detected secret falls back to the marker.
Verification
Evidence-Ticket: OMN-20926
Evidence-Source: OCC#13623