Skip to content

Handover Protocol#198

Merged
cygnusv merged 14 commits intonucypher:rocknrollfrom
cygnusv:gary
Jun 3, 2025
Merged

Handover Protocol#198
cygnusv merged 14 commits intonucypher:rocknrollfrom
cygnusv:gary

Conversation

@cygnusv
Copy link
Copy Markdown
Member

@cygnusv cygnusv commented Feb 18, 2025

Type of PR:

  • Bugfix
  • Feature
  • Documentation
  • Refactor
  • Other

Required reviews:

How many reviews does the PR author need?

  • 1
  • 2
  • 3

What this does:
This PR introduces the core cryptography for the handover process. In this process, an incoming and departing node interact in such a way that there's a secure and publicly verifiable handover of the private key share. The resulting aggregate transcript is equal to the original, except for the blinded share corresponding to the handover, which in turn contains the same private key share, encrypted now with the incoming validator key.

Issues fixed/closed:

  • Fixes #...

Why it's needed:

Explain how this PR fits in the greater context of the NuCypher Network.
E.g., if this PR address a nucypher/productdev issue, let reviewers know!

Notes for reviewers:

What should reviewers focus on?
Is there a particular commit/function/section of your PR that requires more attention from reviewers?

The test in ferveo/src/lib.rs shows a relatively high-level view of how the handover works, so I'd start from there, or at least focus on that. The core cryptographic components are added in the new ´HandoverTranscriptstruct in therefresh.rs` module.

cygnusv added 3 commits May 2, 2025 11:49
HandoverTranscript, a.k.a. "The Baton", represents the message an incoming node produces to initiate a handover with an outgoing node. After the handover, the incoming node replaces the outgoing node in an existing cohort, securely obtaining a new blinded key share, but under the incoming node's private key.
@cygnusv cygnusv changed the title [draft] Handover Protocol Handover Protocol May 22, 2025
@cygnusv cygnusv marked this pull request as ready for review May 22, 2025 16:07
Copy link
Copy Markdown
Member

@derekpierre derekpierre left a comment

Choose a reason for hiding this comment

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

🎸 - looks great!

#[test_case(4, 4; "N is a power of 2, t=N")]
#[test_case(30, 16; "N is not a power of 2, t is 1 + 50%")]
#[test_case(30, 30; "N is not a power of 2, t=N")]
fn test_dkg_simple_tdec_handover(shares_num: u32, security_threshold: u32) {
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Great test - read like a story! 🔥

@cygnusv cygnusv merged commit 969a118 into nucypher:rocknroll Jun 3, 2025
10 of 11 checks passed
@derekpierre derekpierre mentioned this pull request Aug 15, 2025
18 tasks
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.

3 participants