Skip to content

fix(setup): don't count OpenVTC's own admin did:key as a persona in the context probe - #635

Merged
stormer78 merged 1 commit into
mainfrom
fix/632-probe-admin-did
Nov 25, 2026
Merged

stormer78 merged 1 commit into
mainfrom
fix/632-probe-admin-did

Conversation

@stormer78

Copy link
Copy Markdown
Contributor

Fixes #632. Refs #633 (documentation only; the binary build lives in the download pipeline, not here).

#632: first-time setup stops at "already in use"

context_probe::probe runs after setup has rotated the ephemeral setup DID into the long-term admin did:key, which the VTA records in the same context. Since #623 (list_dids_webvh → vta/dids/list), the probe counted every DID, so every fresh context read as "1 persona".

  • The probe now filters vta/dids/list to the persona methods webvh and scid:vh, the same set the rebuild plan already used. Both now share context_probe::PERSONA_DID_METHODS, so they can't drift apart.
  • I didn't use class: "persona": the VTA records a class only for did:webs (webvh summaries carry class: None), so it would hide every real webvh persona and read occupied contexts as empty.

Tests (mockvta_bootstrap_e2e, --include-ignored):

  • New probe_reads_a_fresh_context_as_empty_after_admin_rotation: rotates the admin into ctx1 against MockVta, asserts the admin did:key is listed in the context (the precondition), then asserts the probe returns Empty. Against the old probe it fails with Occupied { persona_dids: ["did:key:z6Mk…"] }.
  • persona_did_webvh_mint_round_trips now also asserts a minted did:webvh persona makes the probe return Occupied.

#633: Linux runtime libraries

The README's Prerequisites gain a "Linux runtime libraries" section: libpcsclite.so.1 (from openpgp-card) and libdbus-1.so.3 (from dbus-secret-service, linked dynamically, not vendored), with package names for Debian/Ubuntu, Fedora and Arch. Loading PC/SC at runtime, or shipping a no-token download, is a separate change.

Needs a backport to release/0.9: the bug ships in 0.9.0.

…he context probe

The probe listed every DID in the context, so the long-term admin did:key
setup rotates into it just before probing made every fresh context read as
holding one persona (#632, a regression from the move to vta/dids/list in
#623). Filter to the persona methods (webvh, scid:vh), shared with the
rebuild plan as context_probe::PERSONA_DID_METHODS. The class filter is not
usable: the VTA only records a class for did:webs.

Adds a MockVta regression test (fails on the old probe with the admin
did:key reported as a persona) and checks a minted did:webvh persona still
reads as occupied.

Also documents the Linux runtime libraries (libpcsclite1, libdbus-1-3) the
binary needs before it starts (#633).

Fixes #632
Refs #633

Signed-off-by: Glenn Gore <glenn.g@affinidi.com>
@stormer78
stormer78 requested a review from a team as a code owner November 25, 2026 17:16
@stormer78 stormer78 added the backport release/0.9 Cherry-pick onto release/0.9 once merged label Nov 25, 2026
@stormer78
stormer78 merged commit 4714c50 into main Nov 25, 2026
22 checks passed
@stormer78
stormer78 deleted the fix/632-probe-admin-did branch November 25, 2026 18:34
@github-actions

Copy link
Copy Markdown

Backport branch created but failed to create PR.
Request to create PR rejected with status 403.

(see action log for full response)

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.

bug(setup): first-time setup stops at "This Trust Context is already in use" because the probe counts OpenVTC's own new admin DID

1 participant