Skip to content

fix(transcript): drop a trailing dot from the authority name - #34

Merged
xgreenx merged 3 commits into
mainfrom
fix/authority-and-platform-ids
Oct 17, 2026
Merged

xgreenx merged 3 commits into
mainfrom
fix/authority-and-platform-ids

Conversation

@xgreenx

@xgreenx xgreenx commented Oct 5, 2026

Copy link
Copy Markdown
Contributor

authority_id_of hashed api.x.com. to an id no profile pins, though ceremony-common §9 fixes the authority as the lowercase server name with no trailing dot.

Changes

  • Authority id strips one trailing dot before lowercasing, and its doc says so (crates/libid-transcript/src/attestation.rs:140).
  • Test a_trailing_dot_names_the_same_authority: api.x.com, api.x.com. and API.X.COM. hash to CeremonyProfile.AUTHORITY_X_API, api.x.com.. does not.
  • Reverted 2890b8a (REQ-PLAT-06 id grammar in the id range builders). Those builders lay out the prover's reveal, and only libid-tlsn examples and tests call them. Net diff: attestation.rs alone.

Verified

  • cargo +nightly-2026-08-10 fmt --all -- --check: clean.
  • cargo +1.97.1 clippy --all-targets --all-features -- -D warnings: clean.
  • cargo +1.97.1 test --all: passes, libid-transcript 70 tests.
  • The new test fails with the fix removed.
  • cast keccak "api.x.com" equals the pinned literal.
  • Rust rules checked: no unwrap on production paths, behaviour on the owning type, a failing-before test with the fix, comments carry only the why.

Not verified / known issues

  • The notary passes the TLS server name into ObservedSession.authority. The fix reaches production after a libid-rs release and a notary dependency bump.
  • REQ-PLAT-06 stays unenforced in the prover's id layout. The verifier side belongs to libid-contracts.

Decision for the owner

  • Whether the prover should refuse ids outside REQ-PLAT-06 too, as a separate PR.

🤖 Generated with Claude Code

The spec fixes the authority preimage as the lowercase TLS server name
with no trailing dot, and the profiles pin keccak256 of that form.
`api.x.com.` names the same server as `api.x.com` but hashed to an id
no profile pins, so every attestation over the absolute form was
refused.

Assisted-by: Claude Opus 5.5
Signed-off-by: xgreenx <xgreenx9999@gmail.com>
The identity layout read the id with the JSON readers alone, which take
`0`, any number of digits and, quoted, any string. REQ-PLAT-06 holds
the id to `^[1-9][0-9]{0,19}$` at most 2^64 - 1, so the prover now
refuses what the Platform Verifier must refuse, where the reason shows.
The bare-number scan moves onto JsonMember so the digits reach the check.

Assisted-by: Claude Opus 5.5
Signed-off-by: xgreenx <xgreenx9999@gmail.com>
This reverts commit 2890b8a.

The id range builders lay out what the prover reveals. Only the
libid-tlsn fixture examples and tests call them, and no notary, keeper
or bridge path does. The REQ-PLAT-06 gap sits in the on-chain verifier,
so the change reshaped a published crate's API without closing it.

Assisted-by: Claude Opus 5.5
Signed-off-by: xgreenx <xgreenx9999@gmail.com>
@xgreenx
xgreenx merged commit 550a807 into main Oct 17, 2026
7 checks passed
@xgreenx
xgreenx deleted the fix/authority-and-platform-ids branch October 17, 2026 11:26
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