Skip to content

About Preparams Selection Logic During Reshare Phase #136

Closed

Description

@treeforest

Hello,

I noticed that during the reshare phase, new nodes always use the preparams at index 1. However, after the first reshare, in the second reshare, they might end up using the same preparams again.

Currently, the code snippet is:

preParams := p.ecdsaPreParams[0]
if isNewPeer {
	preParams = p.ecdsaPreParams[1]
	participantPeerIDs = newPeerIDs
} else {
	participantPeerIDs = oldKeyInfo.ParticipantPeerIDs
}

Would it be better to select preparams based on version % 2 and (version + 1) % 2 instead, to alternate the preparams and avoid reuse?

Looking forward to your thoughts. Thanks!

Activity

  1. anhthii commented on Jan 26, 2026

    @anhthii
    Contributor

    @vietddude can help

  2. self-assigned this
    on Jan 26, 2026
  3. anhthii commented on Jan 27, 2026

    @anhthii
    Contributor

    Thank you for reporting @treeforest , fixed in #139

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions