Skip to content

feat(node): guardian signed delegate signatures broadcast#4744

Merged
evan-gray merged 8 commits intowormhole-foundation:mainfrom
wormholelabs-xyz:delegate-observation-batches
Apr 14, 2026
Merged

feat(node): guardian signed delegate signatures broadcast#4744
evan-gray merged 8 commits intowormhole-foundation:mainfrom
wormholelabs-xyz:delegate-observation-batches

Conversation

@evan-gray
Copy link
Copy Markdown
Contributor

@evan-gray evan-gray commented Apr 9, 2026

This returns the gossip message time restriction pre #4743 in favor of a canonical guardian only approach. This allows any guardian to collect a quorum of delegated guardian set signatures for a message and broadcast them in a single message.

The goal is that this should maintain the same safeguards and security of the original delegated guardian set messages but provide the same security / DoS prevention as observation requests.

Tested with https://api.wormholescan.io/api/v1/observations/delegate/50/00000000000000000000000062deeafee06c7442a21c93ededc79a0cb5791c83/1750

This required a change in Wormholescan to store the full data from the gossip message, so some earlier messages may not contain all the relevant fields. I expect that if a prior message was needed for some reason, it could either be re-observed or the data could be backfilled.

Reviewers: the most critical code is in p2p.go 👀


Summary

  • Add broadcast-delegate-signatures admin command that fetches delegate observations from the wormholescan API for a given VAA ID and rebroadcasts them on the delegated_attestation p2p topic
  • Introduces a new DelegateSignaturesBroadcast gossip message type that carries observation data once with a compact array of per-guardian (addr, sent_timestamp, signature) tuples
  • The CLI client fetches from wormholescan, groups by hash, verifies each delegate signature by reconstructing the original DelegateObservation bytes, and sends only verified signatures to the guardian node
  • The admin server is a thin passthrough that forwards the pre-built broadcast to p2p for signing and publication
  • Receiving guardians verify both the broadcast envelope (canonical guardian signature) and each inner delegate signature, then feed them into the existing delegate observation processor pipeline

@evan-gray evan-gray force-pushed the delegate-observation-batches branch 5 times, most recently from 547444a to 33e112f Compare April 10, 2026 01:45
@evan-gray evan-gray marked this pull request as ready for review April 10, 2026 01:46
@evan-gray evan-gray force-pushed the delegate-observation-batches branch 2 times, most recently from c93a95e to 5ea4844 Compare April 10, 2026 02:00
@johnsaigle johnsaigle self-requested a review April 10, 2026 11:00
@johnsaigle
Copy link
Copy Markdown
Contributor

@claude

@github-actions
Copy link
Copy Markdown

Claude Code is working…

I'll analyze this and get back to you.

View job run

@evan-gray evan-gray force-pushed the delegate-observation-batches branch from 5ea4844 to 5aa5fae Compare April 10, 2026 12:54
Copy link
Copy Markdown
Contributor

@johnsaigle johnsaigle left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Given that we're doing checks against the current Guardian Set on one level, and the delegated/canonical sets on another level, do we need to worry about the boundary cases like:

  • Changing a Guardian Set?
  • Changing the Delegated Guardian Set for a chain?

Comment thread node/cmd/guardiand/adminclient.go Outdated
Comment thread node/cmd/guardiand/adminclient.go
Comment thread node/cmd/guardiand/adminclient.go
Comment thread node/pkg/p2p/p2p.go Outdated
Comment thread proto/gossip/v1/gossip.proto Outdated
Comment thread node/cmd/guardiand/adminclient.go Outdated
Comment thread node/pkg/p2p/p2p.go
Comment thread node/pkg/p2p/p2p.go
Comment thread node/pkg/p2p/p2p.go
@evan-gray evan-gray changed the title Delegate observation batches feat(node): guardian signed delegate signatures broadcast Apr 10, 2026
Comment thread node/pkg/p2p/p2p.go
Comment thread node/cmd/guardiand/adminclient.go Outdated
@evan-gray evan-gray force-pushed the delegate-observation-batches branch 3 times, most recently from 16347df to 966587a Compare April 11, 2026 22:48
Copy link
Copy Markdown
Contributor

@johnsaigle johnsaigle left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think we should update the test coverage to make sure we're handling the non-VAA-hash-related fields correctly.

Otherwise, the rest of the comments are improvements but IMO they do not need to block the PR.

Comment thread node/cmd/guardiand/adminclient.go Outdated
Comment thread node/cmd/guardiand/adminclient.go Outdated
Comment thread node/cmd/guardiand/adminclient.go
Comment thread node/cmd/guardiand/adminclient.go Outdated
Comment thread node/cmd/guardiand/adminclient.go Outdated
Comment thread node/cmd/guardiand/adminclient.go Outdated
Comment thread node/cmd/guardiand/adminclient_delegate_test.go
Comment thread node/cmd/guardiand/adminclient_delegate_test.go
Comment thread node/cmd/guardiand/adminclient_delegate_test.go Outdated
mdulin2
mdulin2 previously approved these changes Apr 13, 2026
Copy link
Copy Markdown
Contributor

@mdulin2 mdulin2 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks pretty good to me! The checks on the single signature appear to all be done on the batch case as well.

Comment thread node/pkg/p2p/p2p.go
Comment thread node/pkg/p2p/p2p.go
Comment thread node/pkg/p2p/p2p.go
@evan-gray evan-gray force-pushed the delegate-observation-batches branch from 9be839d to 937d18f Compare April 13, 2026 22:01
Copy link
Copy Markdown
Contributor

@johnsaigle johnsaigle left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

A few small notes for test coverage and logging in case we hit size limits on the p2p layer.
Otherwise looks good and I'm happy to approve once these are resolved.

Comment thread node/cmd/guardiand/adminclient_delegate_test.go
Comment thread node/cmd/guardiand/adminclient_delegate_test.go Outdated
Comment thread node/cmd/guardiand/adminclient_delegate_test.go
Comment thread node/cmd/guardiand/adminclient.go
Comment thread node/pkg/p2p/p2p.go
Comment thread node/cmd/guardiand/adminclient.go Outdated
Copy link
Copy Markdown
Collaborator

@djb15 djb15 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Approving changes to gossip.proto

@evan-gray evan-gray merged commit 777903c into wormhole-foundation:main Apr 14, 2026
38 checks passed
@evan-gray evan-gray deleted the delegate-observation-batches branch April 14, 2026 19:30
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