fix(evidence): reject ambiguous network metadata names - #165
Draft
seonghobae wants to merge 9 commits into
Draft
Conversation
|
Important Review skippedDraft detected. Please check the settings in the CodeRabbit UI or the ⚙️ Run configurationConfiguration used: Organization UI Review profile: CHILL Plan: Pro Plus Run ID: You can disable this status message by setting the Use the checkbox below for a quick retry:
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
seonghobae
changed the base branch from
fix/evidence-error-contract
to
fix/provenance-locator-control-injection
August 16, 2026 09:09
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.
Buyer/protocol-integrity gap
NetworkEvidence::capturereused one generic metadata-name validator for both HTTP header fields and query fields. That boundary accepted HTTP separator characters in header field names even though RFC 9110 defines a field name astoken(1*tchar). It also allowed bidi, zero-width, soft-hyphen, and byte-order-mark characters in query field names, so redacted audit evidence could be visually reordered or hidden while preserving attacker-controlled field-name bytes.Query parameter names remain a separate syntax domain from HTTP field names: printable Unicode query names are preserved, but control and reviewed invisible formatting characters fail closed.
Live dependency and stack state
This Draft targets exact PR #162 head
aa66e9eef466ae39900352a342381f65ade2309e, transitively on #157. #162 owns the adjacent provenance-locator presentation hardening andEvidenceError::InvalidLocator; this branch owns HTTP field-name grammar plus query-name presentation integrity. Content-aware merge commit9cf10f985795dcbe5b31852895f786e2fc7ef5d2preserves both production contracts rather than allowing either sibling to drop the other'slib.rsand changelog semantics.Fresh ancestry is ahead 9 / behind 0 with merge base exactly
aa66e9eef466ae39900352a342381f65ade2309e. Keep Draft while #162/#157 remain active. No prerequisite check, review, mergeability, or approval evidence transfers.Test-first evidence and implementation
HTTP field-name grammar
1724ba47579155e46f400090011c4ed670fb9938failed only atcargo fmt --check, so that run was not accepted as semantic RED.1baf036651dab0f5f2160142d8845d19faf901a8reached the intended semantic boundary in CI run31855601735, Rust job94939662832:bad:namewas accepted asOk(NetworkEvidence)instead of failing closed. The companion regression preserving the complete RFC 9110tcharpunctuation set and an independent query name such asfilter:statuspassed. This is the valid RED.tcharpunctuation (!#$%&'*+-.^_|~`).Query-name presentation integrity
acef77fa3ac56bfc6dfa120ab764ee879a13c79badded hostile query names containing U+202E, U+200B, U+00AD, U+2066, and U+FEFF while preserving a printable Korean query name.31938663213passed repository contracts, canonical formatting, and workspace check, then failednetwork_evidence_rejects_invisible_query_field_namesbecause the U+202E field name was returned asOk(NetworkEvidence). The printable Unicode companion passed. This is the valid RED.e564d0e6f0338d8eaf6d83451d6b0998bef40515introduced one shared evidence-presentation validator for control and reviewed invisible Unicode formatting characters. Query metadata and provenance locators reuse it without conflating query syntax with HTTP token grammar.c3bfdda76813ec1fc8058d4cca5f95f5d2fe9479adds the truthful Unreleased query-presentation security record.Every captured metadata value remains unconditionally redacted. Hostile regressions reject malformed HTTP field names containing colon, comma, equals, parentheses, brackets, braces, slash, question mark, at-sign, quote, and backslash, plus invisible query-name presentation controls.
Exact-current proof
On unchanged exact head
c3bfdda76813ec1fc8058d4cca5f95f5d2fe9479against exact live baseaa66e9eef466ae39900352a342381f65ade2309e:31939233804: success;Rust contracts: repository contracts, canonical formatting, locked workspace/all-target checks, full tests, strict Clippy, and rustdoc success;Production coverage: exact owned production function/line/region/branch enforcement success;Security/SAST/central/model workflows not returned for this stacked Draft are not represented as passing. No predecessor-head, prerequisite-head, synthetic-merge, queued, pending, skipped, cancelled, absent, stale, status-only, or model-only evidence is promoted to current-head proof.
Scope boundary
This lane changes only credential-safe network-evidence admission. It performs no HTTP parsing, network I/O, browser execution, persistence, secret handling, workflow mutation, or release action. The scheduled actor does not merge or self-approve.