8000 docs(cbio): publish plaintext vectors only, never masked bytes by shroominic · Pull Request #167 · shroominic/OpenGlucose · GitHub
[go: up one dir, main page]

Skip to content

docs(cbio): publish plaintext vectors only, never masked bytes - #167

Closed
shroominic wants to merge 1 commit into
docs/cbio-gs1-auth-materialfrom
docs/cbio-auth-material-redaction
Closed

shroominic wants to merge 1 commit into
docs/cbio-gs1-auth-materialfrom
docs/cbio-auth-material-redaction

Conversation

@shroominic
@shroominic shroominic commented Sep 18, 2026 •
Copy link
Copy Markdown
Owner

Fixes part of #164. Applies to #138, which is where the second copy of the material lives. Base is docs/cbio-gs1-auth-material.

What was wrong

The "Synthetic test vectors" table in docs/testing/cbio-gs1-auth-material.md printed two things this record promises not to print:

  • the authentication frame's plaintext hex, whose bytes 9..24 are the 16-byte link credential written out verbatim;
  • a masked column derived from the real stream key.

The same document says the material is "deliberately not reproduced as bare constants in this document beyond the test vectors above", so it contradicted itself, and it does so on a public branch.

What this changes

  • The authentication row keeps its layout and omits the credential field: 19 01 00 <6 reversed address octets> <16-byte material> C.
  • The masked column is gone. A masked byte string is a function of the key, so publishing one publishes key-derived material; the document now shows how to generate it at run time from injected material instead.
  • The remaining plaintext rows are unchanged: they are protocol structure, not credentials.
  • The limits section states that neither value appears in the document, in any other repository file, or in any test fixture.

Verification

The byte-class inventory used across this gate derives its needles from the pre-fix source and scans every branch tip, stripping whitespace so a multi-line byte list is matched as well as a hex string. It finds:

  • the link credential published in this document on docs/cbio-gs1-auth-material, origin/release/v0.4.0, and repro/162-aggregate-append, before this change;
  • no credential or masked-value needle on docs/cbio-auth-material-redaction, after it.

The only long values left in the redacted document are the artifact digests and one state-changing activation plaintext, neither of which carries key-derived bytes.

Decisions taken

  • Publish structure, never values. Frame layouts stay, because reading the record should not require decompiling anything; the credential field and the masked column become placeholders.
  • Do not restate the bytes even to explain the redaction. The reason is named, the value is not.
  • Leave the derivation procedure in place. The record still has to be usable by someone wiring the injected-material path, so the offsets, digests, and call sequence stay.

Not claimed

This does not clean the already-published copies of the material in the repository's git history, and it does not touch the byte-list constants on the other sensor branches. Purging or rotating those is a separate owner decision, requested in #173.

8000

The vector table printed the authentication frame's plaintext hex, whose
bytes 9..24 are the 16-byte link credential, and the masked column was
derived from the real stream key. Both contradict the record's own stated
policy and belong to the material tracked in #164.

Keep the plaintext layouts, omit the credential field, and generate masked
bytes at run time from injected material instead.
@shroominic
Copy link
Copy Markdown
Owner Author

Carried by the GS1 consolidation in PR #209 (branch feature/cbio-gs1, head 3eca4f4).

This PR is contained in the consolidated line; the merge that carries it is c85f827.

Closing as subsumed by the consolidation - not as won't fix. The per-defect evidence stays in this thread, and the carrying commit above is where the change now lives.

@shroominic shroominic closed this Sep 18, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant

0