Files
buzz/desktop/src-tauri
Logan Johnson a3a0745d0c fix(desktop): verify saved owner link before agent duplicate or repair
Add existing agent admitted an existing record on pubkey/persona/community
and then reported a healthy duplicate or repaired a missing key without ever
checking the saved NIP-OA attestation. A legacy record with a missing,
foreign, or invalid saved owner link could pass Add while launch
preparation later refuses it as unowned.

Under the existing commit locks, commit_verified now validates the saved
record's attestation for the exact current owner and agent via the same
runtime_configurations::verify_owner predicate launch preparation applies,
before both the healthy-duplicate return and the key-repair write. Absent,
foreign, and invalid links are refused with a redacted error and zero
writes; no silent re-attestation or owner migration is introduced.

Regression coverage at the real commit seam crosses healthy and missing
saved keys with absent, foreign, and structurally-valid-but-unverifiable
attestations, asserting refusal preserves raw store bytes and key state;
positive valid-duplicate and explicit-repair controls are retained.

Signed-off-by: Logan Johnson <loganj@squareup.com>
2026-09-08 18:00:08 -04:00
..