Repository navigation
fix(auth): attribute credential restrictions accurately (#15889) - #15959
Conversation
Use a private ephemeral HMAC key for allowlist diagnostic references so caller-supplied IDs cannot be matched to a public SHA-256 dictionary or correlated across processes. Preserve process-local correlation, sample bounds, restriction sources and the noauth sentinel. Refs #15889
|
Follow-up validation of the diagnostic-reference CodeQL finding: The traced value is an allowed connection ID from key policy, a combo pin, or quota scope; this helper does not store password verifiers. The real privacy gap was the publicly reproducible SHA-256 diagnostic fingerprint. References now use HMAC-SHA256 with a private random key generated once per process/module. Same-process correlation remains available; references change in a separate process. Sample bounds, restriction sources, counts and the TDD: two new privacy assertions failed before the change (public digest matching and cross-process correlation), while two controls passed. All four now pass. The expanded five-file suite passed 128/128 tests, including the original 14 issue scenarios and auth/chat/combo consumers, with no skips. An independent reviewer reproduced the four privacy tests and found no Standards/Spec blocker. This is diagnostic privacy hardening, not a claim that password storage was vulnerable. No CodeQL rule or alert was suppressed. The new scan still needs to confirm the alert status, and the original reporter's Docker acceptance remains outstanding; the PR stays a draft. Published in commit The dashboard gate still fails with 19 diagnostics outside its baseline in Fresh hosted checks for this commit remain to be evaluated. In particular, HMAC improves diagnostic privacy but does not by itself prove that CodeQL’s alert is resolved; the review thread is left open. No merge or deployment was performed. GitHub currently reports this PR as CONFLICTING / DIRTY against the release branch. Base-red #15306 remains a separate hold: this follow-up does not merge or rebase the red release tip into the PR. Conflict reconciliation and fresh hosted validation are still required before any merge. |
|
Fechando esta PR para esvaziar a fila aberta. A branch |
|
Reabrindo. O fechamento foi um engano; esta PR volta para a fila de merge. A branch continua no lugar. |
CI Coverage Report
Coverage artifact was not available for this run. |
Connection selection can reject a keyless combo through its pin/allowlist while reporting that an API key caused the denial. The selector now carries the actual restriction source into the 403 response and records bounded, hashed allowlist references plus the reason an anonymous fallback was refused.
The existing allowlist intersection, combo pin, quota enforcement, synthetic-credential eligibility and retryable pause response are preserved. Diagnostic formatting also accepts a legacy scalar allowlist without affecting account selection. Two helpers keep the existing file-size ceilings intact.
Refs #15889. This fixes the locally reproduced diagnostic defect. The reporter's original clean-Docker 403/503 sequence has not been reproduced; its underlying cause remains open, and this change does not restore retired providers.
Evidence
Base-red inherited: #15306. This PR is left as a draft because the broader regression evidence is partial; it is not a merge-ready claim. No merge or deployment is included.
Mutation coverage follow-up
Registered
tests/unit/credential-scope-diagnostics-15889.test.tsinstryker.conf.jsonso its auth-module checks participate in mutation testing. The strict coverage-drift gate failed with exactly this missing file before the update and passed after it. Normal commit hooks passed. This configuration-only follow-up does not change the original reproduction limitations or the draft status.