Skip to content

fix: admit the synthetic browser status redaction fixture - #1646

Merged
vincentkoc merged 1 commit into
mainfrom
review/browser-status-fixture-20260921
Sep 22, 2026
Merged

vincentkoc merged 1 commit into
mainfrom
review/browser-status-fixture-20260921

Conversation

@vincentkoc

@vincentkoc vincentkoc commented Sep 22, 2026 •

Copy link
Copy Markdown
Member

What Problem This Solves

Fixes: ClawSweeper refuses browser-stack reviews because an existing mocked status-response redaction test contains a synthetic credentialed loopback URL.

User Impact

Maintainers can review changes that include this exact existing fixture. All native secret scanning, verification, source-provenance, and mutation gates remain enabled. This does not itself approve or merge any browser PR.

Why This Change Was Made

The fixture originates in OpenClaw PR 81002, commit b6a94d4ef94cce827fe7514356dd9a4418d88c32 (2026-05-12). It tests removal of URL userinfo from a mocked status response and is not an operational credential. Its full source line is unchanged in the reviewed stack.

The existing host-owned exact-attribution table is the owner of this qualification. One row binds URI detector 17, the observed PLAIN decoder, both native value digests, the complete source-line digest, the original test path, regular-file mode, and committed base/head references. No classifier algorithm or scanner flag changes. HTML and other unobserved decoder variants remain unqualified.

Production delta: +3 lines. Regression delta: +62 lines.

OpenClaw Bay Impact

None. There is no dashboard, telemetry, queue, review-publication, or public-action contract change.

Documentation Impact

Reviewed README.md Safety Model and docs/proof/agent-input-scan-context/README.md. Their exact-attribution and fail-closed contracts remain accurate; this adds one qualification under that existing contract. The bounded proof receipt is retained below. No new active runbook or broader scanner capability is introduced.

Real Behavior Proof

Claim: the production classifier classifies only this reviewed synthetic fixture after native scanning, while preserving its exact source boundary.

Surface and scenario: native TruffleHog filesystem scan of the complete committed status-route test blobs from base cdc60c8caf7ff072bc7d8aa813e92959dc814862, engine head 8dde9d30ac4d182006779f1cdad1de4183afc2e0, and Chromium head 3c64630a372624357d09149fe72d2f0a3e969dd4; unchanged native output passed to classifyReviewedFixtureScan from baseline and candidate.

Command and environment: Linux x64, Node 26.7.0, checksum-verified native TruffleHog 3.97.4. The harness extracts full blobs with git show <revision>:extensions/browser/src/browser/routes/basic.existing-session.test.ts, checks the unique full-line witness, and runs:

trufflehog filesystem <private-three-blob-directory> \
  --fail --fail-on-scan-errors --no-update --json --no-color

Verification remains enabled. The native scanner inherits no authentication or proxy variables; the harness confirms that the synthetic loopback port has no listener before scanning. Raw scanner values and verification messages are not persisted.

Observed: exit 183; three unverified PLAIN URI findings. Baseline at 3350906aa794aa08894b90b568cad6c28d03e572 refuses literal_not_reviewed; the candidate classifies all three with exact source attribution. The complete sanitized receipt follows.

Limits: controlled native classifier proof, not the whole hosted prompt/schema/diff admission and not live browser/provider proof. It does not clear the hosted refusal by itself. After trusted qualification lands, the browser stack still requires fresh full-input hosted reviews of its exact then-current heads and bodies. Native detector coverage is unchanged.

Sanitized native proof receipt
{
  "policyBase": "3350906aa794aa08894b90b568cad6c28d03e572",
  "scanner": "3.97.4",
  "source": "extensions/browser/src/browser/routes/basic.existing-session.test.ts",
  "revisions": [
    [
      "cdc60c8caf7ff072bc7d8aa813e92959dc814862",
      "base"
    ],
    [
      "8dde9d30ac4d182006779f1cdad1de4183afc2e0",
      "head"
    ],
    [
      "3c64630a372624357d09149fe72d2f0a3e969dd4",
      "head"
    ]
  ],
  "scannerExit": 183,
  "signal": null,
  "findingCount": 3,
  "metadata": [
    {
      "detector": "URI",
      "decoder": "PLAIN",
      "verified": false,
      "verificationErrorPresent": true
    },
    {
      "detector": "URI",
      "decoder": "PLAIN",
      "verified": false,
      "verificationErrorPresent": true
    },
    {
      "detector": "URI",
      "decoder": "PLAIN",
      "verified": false,
      "verificationErrorPresent": true
    }
  ],
  "before": {
    "kind": "refused",
    "reason": "findings",
    "diagnostic": {
      "kind": "unclassified_finding",
      "reason": "literal_not_reviewed",
      "findingCount": 3,
      "findingIndex": 0,
      "detectorType": 17,
      "decoder": "PLAIN",
      "verified": false,
      "scannerLine": 611,
      "material": {
        "kind": "blob",
        "id": "334bcce34e872bdd782d7c6109713d7523edaa82",
        "referenceCount": 1,
        "references": [
          {
            "revision": "8dde9d30ac4d182006779f1cdad1de4183afc2e0",
            "pathSha256": "394ac8b3338f1dd8486090938dc0363c664772f11217d447f789573e35cca120",
            "mode": "100644",
            "role": "head"
          }
        ]
      }
    }
  },
  "after": {
    "kind": "classified",
    "notices": [
      {
        "fixtureSha256": "1d71159c56ca84a71d1b34c10e8d645f3ced3c75a5ac818104338ff58bb95993",
        "source": "extensions/browser/src/browser/routes/basic.existing-session.test.ts",
        "detector": "URI",
        "findings": [
          {
            "blob": "334bcce34e872bdd782d7c6109713d7523edaa82",
            "scannerLine": 611,
            "literalLine": 611,
            "decoder": "PLAIN",
            "role": "head",
            "occurrences": 1
          },
          {
            "blob": "5ad290b284601c41da903d9e4a8cebb1cd578026",
            "scannerLine": 579,
            "literalLine": 579,
            "decoder": "PLAIN",
            "role": "base",
            "occurrences": 1
          },
          {
            "blob": "86cbb565bc9f171b329dd961e4adc40f8153b0a2",
            "scannerLine": 611,
            "literalLine": 611,
            "decoder": "PLAIN",
            "role": "head",
            "occurrences": 1
          }
        ]
      }
    ]
  },
  "limits": "Controlled native scan of the exact three status-redaction fixture blobs only; not full hosted input scan or review clearance. No raw scanner values or verification details persisted."
}

Evidence

  • Baseline/candidate regression: exact fixture qualification fails before the added row and passes afterward. Negative cases reject full-line drift, duplicate occurrence, wrong or mixed source, uncommitted role, verified findings, unknown decoder, and changed/unknown native values.
  • Fresh mandatory pnpm run check completed all static/docs/format/build/lint phases and reached its terminal full-coverage report: 6,503 passed, 0 failed, 19 skipped; changed-coverage cases 13/13 passed. Coverage: 87.47% lines, 78.04% branches, 90.78% functions. The command used child-only SHELL=/bin/bash and the repository-supported CLAWSWEEPER_TEST_CONCURRENCY=4 under the shared host build lock, with unchanged assertions and deadlines. The original native process handle could not be recovered across worker resumption, so raw shell exit status is unavailable; terminal test/coverage evidence and absence of lifecycle errors are retained rather than inventing an exit code.
  • Fresh native precommit review exited 0 in 65.5 seconds with no actionable finding. It confirmed the exact fixture/source/decoder/committed-role boundaries and passed the new boundary test against the source classifier. This review used an explicitly selected source-only snapshot; dependencies/build output were absent, so full validation comes from the actual-checkout suite above.
  • Fresh committed-branch native review exited 0 in 46.07 seconds with no actionable finding. It reviewed the original complete repository at 88a63355b892ba4b27fccaecbd3ab0c9e40fbae1 against actual parent 3350906aa794aa08894b90b568cad6c28d03e572, verified the same exact patch, and passed the new regression against source. Dependencies/build output were deliberately not installed in that read-only review checkout; full-suite evidence remains the actual-checkout run above.
  • Current-head/body ClawSweeper readiness and applicable hosted CI remain required before merge; neither native review bypasses those gates.

CodeQL alert disposition

Alert 126 was independently reviewed and dismissed as a false positive on 2026-09-22. The new test's synthetic URI at lines 3514–3515 reaches unchanged exactFixture line 1052, which hashes the complete source-line witness for deterministic content attribution, not password storage or authentication. That helper has been unchanged since 10c64167c30da64c0b0c78a2b3872bf7435cb0e3 (2026-09-06), is local to the test module, and is excluded from production builds. This regression uses the actual production policy and does not consume the generated helper policy.

The disposition is specific to alert 126, applies to that alert across branches, and is reversible. The existing dispositions of alerts 123/124 remain unchanged. Fixture bytes, SHA-256 content-identity semantics, CodeQL rules/workflows, native scanning, and all production gates are unchanged. A fresh ClawSweeper review of this updated body remains required.

@vincentkoc vincentkoc self-assigned this Sep 22, 2026
@clawsweeper

clawsweeper Bot commented Sep 22, 2026 •

Copy link
Copy Markdown
Contributor

🦞👀
ClawSweeper picked this up.

Pull request received. I will update this pull request when review starts.

ClawSweeper review complete

ClawSweeper finished reviewing this revision. The review result is being finalized.

View the workflow run.

@clawsweeper clawsweeper Bot added P2 Normal priority bug or improvement with limited blast radius. proof: sufficient Contributor real behavior proof is sufficient. rating: 🐚 platinum hermit Good normal PR readiness with ordinary maintainer review expected. status: 👀 ready for maintainer look ClawSweeper has no concrete contributor-facing blocker left for this PR. labels Sep 22, 2026
@clawsweeper

clawsweeper Bot commented Sep 22, 2026 •

Copy link
Copy Markdown
Contributor

Codex review: needs maintainer review before merge. Reviewed September 22, 2026, 12:28 AM ET / 04:28 UTC (Revision 2).

ClawSweeper review

What this changes

Adds exact secret-scan qualification for an existing synthetic browser status-redaction fixture, with regression coverage for rejected variants.

Merge readiness

✅ Ready for maintainer review

Keep open: this remains a useful, narrowly scoped fix absent from current main. The recorded native proof supports the qualification, and no actionable correctness or security defect was found.

Priority: P2
Reviewed head: 88a63355b892ba4b27fccaecbd3ab0c9e40fbae1

Review scores

Measure Result What it means
Overall readiness 🐚 platinum hermit (4/6) A focused policy addition with relevant native before/after evidence and meaningful rejection coverage.
Proof confidence 🐚 platinum hermit (4/6) Sufficient (terminal): The captured Linux native-scan receipt exercises the changed production classifier with three complete upstream blobs and shows baseline refusal becoming exact classification. Regressions cover forbidden variants; full hosted admission remains a separate, unchanged gate.
Patch quality 🐚 platinum hermit (4/6) No actionable review findings were identified.

Verification

Check Result Evidence
Real behavior Verified Sufficient (terminal): The captured Linux native-scan receipt exercises the changed production classifier with three complete upstream blobs and shows baseline refusal becoming exact classification. Regressions cover forbidden variants; full hosted admission remains a separate, unchanged gate.
Evidence reviewed 7 items Introduced change and merge scope: The pinned introduced delta adds three production lines and 62 test lines. The verified test merge has the pinned main and PR head as its two parents and changes only these same two files.
Exact rejection boundaries: The existing classifier requires matching native metadata, both value digests, complete source-line witnesses, regular-file mode, and every committed source reference. Verified findings and unmatched material still refuse admission; scanner arguments and completion checks are unchanged.
Upstream fixture identity: The policy explicitly depends on this upstream test fixture. GitHub source shows a mocked status-redaction test asserting removal of URL credentials. Independently hashing the retrieved complete blob produced 334bcce34e872bdd782d7c6109713d7523edaa82; line 611 hashes to the exact policy witness 5b94a943db86311a9fad2e77bc395ce0a94cde5c73a04cf17943ab5b29928110.
Findings None None.
Security None None.

How this fits together

ClawSweeper scans review inputs before allowing model inspection. Its host-owned fixture policy distinguishes reviewed synthetic test data from findings that must block admission.

flowchart TD
  A[Committed source and review inputs] --> B[Native secret scan]
  B --> C[Exact fixture classification]
  D[Host-owned fixture policy] --> C
  C --> E{All findings qualify?}
  E -->|Yes| F[Continue admission checks]
  E -->|No| G[Refuse review]
Loading

Before merge

None.

Agent review details

Security

None.

Review metrics

Metric Value Why it matters
Production and test growth Production +3 lines; tests +62 lines; 0 deletions The production growth is justified by one exact qualification using the existing classifier.

Technical review

Best possible solution:

Retain the exact host-owned qualification while requiring subsequent browser reviews to pass their own complete-input admission.

Do we have a high-confidence way to reproduce the issue?

Yes: current main lacks the exact attribution, and the recorded native scan demonstrates the resulting refusal. This read-only review verified the source mechanism without executing the scanner.

Is this the best way to solve the issue?

Yes: adding one exact attribution uses the established policy mechanism and preserves rejection of unqualified findings without introducing a parallel bypass.

AGENTS.md: found and applied where relevant.

Codex review notes: model internal, reasoning medium; reviewed against 0ecd31af54ad.

Labels

Label justifications:

  • P2: Repairs a bounded false refusal affecting reviews containing one established synthetic fixture.
  • rating: 🐚 platinum hermit: Overall readiness is 🐚 platinum hermit; proof is 🐚 platinum hermit and patch quality is 🐚 platinum hermit.
  • status: 👀 ready for maintainer look: ClawSweeper has no concrete contributor-facing blocker left for this PR. Sufficient (terminal): The captured Linux native-scan receipt exercises the changed production classifier with three complete upstream blobs and shows baseline refusal becoming exact classification. Regressions cover forbidden variants; full hosted admission remains a separate, unchanged gate.
  • proof: sufficient: Contributor real behavior proof is sufficient. The captured Linux native-scan receipt exercises the changed production classifier with three complete upstream blobs and shows baseline refusal becoming exact classification. Regressions cover forbidden variants; full hosted admission remains a separate, unchanged gate.

Evidence

What I checked:

  • Introduced change and merge scope: The pinned introduced delta adds three production lines and 62 test lines. The verified test merge has the pinned main and PR head as its two parents and changes only these same two files. (src/agent-input-scan-fixtures.ts:252, 88a63355b892)
  • Exact rejection boundaries: The existing classifier requires matching native metadata, both value digests, complete source-line witnesses, regular-file mode, and every committed source reference. Verified findings and unmatched material still refuse admission; scanner arguments and completion checks are unchanged. (src/agent-input-scan-fixtures.ts:900, 88a63355b892)
  • Upstream fixture identity: The policy explicitly depends on this upstream test fixture. GitHub source shows a mocked status-redaction test asserting removal of URL credentials. Independently hashing the retrieved complete blob produced 334bcce34e872bdd782d7c6109713d7523edaa82; line 611 hashes to the exact policy witness 5b94a943db86311a9fad2e77bc395ce0a94cde5c73a04cf17943ab5b29928110. (extensions/browser/src/browser/routes/basic.existing-session.test.ts:611, 8dde9d30ac4d)
  • Recorded native behavior proof: The supplied PR body at source revision f29f0ee693161b4f05756da935c1c073aac4368f91ff3f2d44fe088fc1e50225 contains the complete sanitized receipt: native TruffleHog 3.97.4 on Linux scanned three complete committed blobs, returned three unverified PLAIN findings, and unchanged output changed from baseline literal_not_reviewed refusal to candidate classification. Its stated limit correctly excludes full hosted admission. Focused negative regressions supplement this native evidence. (88a63355b892)
  • Current-main necessity: The fetched main fixture policy contains neither this source path nor its value digest. The latest release tag v0.3.0 predates this classifier file. No merged replacement was established. (src/agent-input-scan-fixtures.ts, 0ecd31af54ad)
  • Existing policy and review continuity: AGENTS.md was read fully; no nested AGENTS.md or maintainer-notes directory was found. README documents the same exact-attribution mechanism. The previous completed review covers this unchanged head and retains no findings; the updated body explains the CodeQL disposition and records no Bay contract impact. The alert API returned 404, so its administrative dismissal was not independently verified; source inspection confirms the cited hashing helper produces test content identities. (README.md:665, 88a63355b892)

Likely related people:

  • steipete: Suggested for follow-up; no historical authorship or introduction is verified. (role: unverified routing candidate; confidence: low)
  • vincentkoc: Suggested for follow-up; no historical authorship or introduction is verified. (role: unverified routing candidate; confidence: low)

Rating scale

Score Internal tier Crab rank Meaning
6/6 S 🦀 challenger crab Exceptional readiness
5/6 A 🦞 diamond lobster Very strong readiness
4/6 B 🐚 platinum hermit Good normal PR; ordinary maintainer review
3/6 C 🦐 gold shrimp Useful, but confidence is limited
2/6 D 🦪 silver shellfish Proof or implementation needs work
1/6 F 🧂 unranked krab Not merge-ready
N/A NA 🌊 off-meta tidepool Rating does not apply

Overall follows the weaker of proof and patch quality.
Shiny media proof means a screenshot, video, or linked artifact directly shows the changed behavior. Runtime, network, CSP, and security claims still need visible diagnostics.

Workflow

  • ClawSweeper keeps one durable marker-backed review comment per issue or PR.
  • Re-runs edit this comment so the latest verdict, findings, and automation markers stay together instead of adding duplicate bot comments.
  • A fresh review can be triggered by eligible @clawsweeper re-review comments, exact-item GitHub events, scheduled/background review runs, or manual workflow dispatch.
  • PR/issue authors and users with repository write access can comment @clawsweeper re-review or @clawsweeper re-run on an open PR or issue to request a fresh review only.
  • Maintainers can also comment @clawsweeper review to request a fresh review only.
  • Fresh-review commands do not start repair, autofix, rebase, CI repair, or automerge.
  • Maintainer-only repair and merge flows require explicit commands such as @clawsweeper autofix, @clawsweeper automerge, @clawsweeper fix ci, or @clawsweeper address review.
  • Maintainers can comment @clawsweeper explain to ask for more context, or @clawsweeper stop to stop active automation.

History

Review history (1 earlier review cycle)
  • reviewed 2026-09-22T04:11:08.502Z sha 88a6335 :: needs maintainer review before merge. :: none

@vincentkoc

Copy link
Copy Markdown
Member Author

@clawsweeper re-review

@clawsweeper

clawsweeper Bot commented Sep 22, 2026

Copy link
Copy Markdown
Contributor

🦞🧹
ClawSweeper re-review requested.

I asked ClawSweeper to review this item again.
Action: item re-review queued (workflow sweep.yml, event exact_review_queue).
Result: when the review finishes, ClawSweeper will create the durable review comment if needed or update the existing comment in place.

@clawsweeper

clawsweeper Bot commented Sep 22, 2026 •

Copy link
Copy Markdown
Contributor

🦞👀
Exact review queued.

Re-review progress:

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

P2 Normal priority bug or improvement with limited blast radius. proof: sufficient Contributor real behavior proof is sufficient. rating: 🐚 platinum hermit Good normal PR readiness with ordinary maintainer review expected. status: 👀 ready for maintainer look ClawSweeper has no concrete contributor-facing blocker left for this PR.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant