Skip to content

Debug capture leaks registered secrets and sentinels retain credential history #102388

Description

@steipete

Bug type

Behavior bug (incorrect output/state without crash)

Beta release blocker

No

Summary

Debug proxy WebSocket capture persists registered credential values verbatim, while process-local secret sentinels retain every resolved credential in unbounded maps.

Steps to reproduce

  1. Enable debug proxy capture.
  2. Register a resolved secret value and capture a WebSocket event containing it in the URL, payload, error text, or metadata.
  3. Inspect the capture row and payload blob; the literal value is present.
  4. Mint sentinels for successive credential rotations and inspect the process lifetime behavior; no entry is released.

Expected behavior

Every persisted debug-capture field should exact-redact registered values before storage, and sentinels should remain process-local without retaining one plaintext registry entry per historical credential.

Actual behavior

captureWsEvent stores the raw URL, frame payload, error text, and metadata. src/secrets/sentinel.ts keeps forward and reverse plaintext maps until process exit.

OpenClaw version

Current main at 1017ea5bc8048dfee9aff0d6a4be4d7e80f342bf; sentinel behavior shipped in v2026.7.1-beta.3.

Operating system

Ubuntu 24.04 (Blacksmith Testbox)

Install method

Source checkout

Model

N/A

Provider / routing chain

N/A

Logs

Synthetic capture proof recorded one WebSocket event and found the registered test secret in persisted capture data. No real credential values are included here.

Impact and severity

  • Affected: operators using debug proxy capture and long-lived gateways that rotate provider credentials.
  • Severity: high data-risk hardening gap; capture databases or blobs can contain credentials.
  • Frequency: deterministic for a captured frame containing a registered credential; registry growth occurs once per unique value and label.
  • Consequence: credentials can outlive their network request in diagnostic storage and process memory.

Additional information

Follow-up to #102008 and #102009. The Mattermost authentication frame is one concrete WebSocket caller, but the persistence boundary is shared by all capture callers.

Metadata

Metadata

Assignees

Labels

P0Emergency: data loss, security bypass, crash loop, or unusable core runtime.bugSomething isn't workingclawsweeper:needs-security-reviewClawSweeper marked this issue as needing security-sensitive review.clawsweeper:no-new-fix-prClawSweeper does not recommend queueing a new automated fix PR for this issue.clawsweeper:source-reproClawSweeper found a high-confidence source-level issue reproduction.impact:auth-providerAuth, provider routing, model choice, or SecretRef resolution may break.impact:securitySecurity boundary, credential, authz, sandbox, or sensitive-data risk.issue-rating: 🦞 diamond lobsterVery strong issue quality with high-confidence source-level or clear reproduction.maintainerMaintainer-authored PRmaturity:stableIssue affects a taxonomy feature currently scored M4/M5.

Type

No type

Fields

Priority

None yet

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions