Skip to content

fix: resolve missing AES on delegate's witness after delegation - #1402

Closed
krillero wants to merge 1 commit into
WebOfTrust:v1.2.13from
krillero:fix-delegator-seal
Closed

fix: resolve missing AES on delegate's witness after delegation#1402
krillero wants to merge 1 commit into
WebOfTrust:v1.2.13from
krillero:fix-delegator-seal

Conversation

@krillero

Copy link
Copy Markdown

Witnesses accept delegated events (dip/drt) before the delegator has anchored them, to avoid a deadlock in the delegation flow. However, the authorizer event seal (AES) was never back-filled once the delegator's anchoring event arrived, leaving the witness permanently showing "Not anchored" for the delegated identifier.

Introduce a pending witness delegation escrow (pwde) that tracks delegated events accepted by a witness without an AES. A new processEscrowWitnessAnchors method, called from processEscrows, periodically checks whether the delegator's KEL now contains the anchoring seal and stores the AES when it does.

Fixes #1317

@krillero
krillero force-pushed the fix-delegator-seal branch from 5d84789 to cbf7e8a Compare April 22, 2026 11:37
Witnesses accept delegated events (dip/drt) before the delegator has
anchored them, to avoid a deadlock in the delegation flow. However,
the authorizer event seal (AES) was never back-filled once the
delegator's anchoring event arrived, leaving the witness permanently
showing "Not anchored" for the delegated identifier.

Introduce a pending witness delegation escrow (pwde) that tracks
delegated events accepted by a witness without an AES. A new
processEscrowWitnessAnchors method, called from processEscrows,
periodically checks whether the delegator's KEL now contains the
anchoring seal and stores the AES when it does.

Fixes WebOfTrust#1317
@krillero
krillero force-pushed the fix-delegator-seal branch from cbf7e8a to bea42cf Compare April 22, 2026 11:38
@lenkan

lenkan commented Apr 22, 2026

Copy link
Copy Markdown
Contributor

I also tried "repairing" a witness using this escrow. So, after completing the delegation ceremony on the broken version, where the witness then is missing the anchor event seal. I can switch to this branch, and then do

kli export --name delegate --alias delegate | curl -X PUT http://localhost:5643

The escrow will run on the witness, and the anchoring event seal is added.

@kentbull

kentbull commented Apr 24, 2026

Copy link
Copy Markdown
Contributor

After reading through this I like it and believe it is half of the solution. The half we have in the PR is the witness side where it can accept the delegator's witness approval.

What I believe the other half should be would be a seal propagation Doer and an escrow in the witness that would put the local delegate's dip event in a seal propagation escrow and after the delegate discovers the delegator's approving seal via a keystate query then the seal propagation doer would look up the current witness set for the delegate and push the seal to each witness, effectively doing kli export | http PUT witness_URL yet with only the CESR stream slice containing the delegator seal.

@edeykholt

Copy link
Copy Markdown

conclusion of 5/5 meeting was to accept this on 1.3 branch if Phil approves. (or a sidecar watcher on 1.3). Reasonable approach on 1.2, given there isn't a local watcher (GLEIF).

@kentbull
kentbull deleted the branch WebOfTrust:v1.2.13 July 10, 2026 18:07
@kentbull kentbull closed this Jul 10, 2026
@kentbull

Copy link
Copy Markdown
Contributor

@krillero please reopen this PR to v1.2.14, the new release branch.

@lenkan

lenkan commented Jul 14, 2026

Copy link
Copy Markdown
Contributor

I opened #1498

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.

5 participants