Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Upgrade Chainsafe deps #631

Merged
merged 10 commits into from
Sep 24, 2024
Merged

Upgrade Chainsafe deps #631

merged 10 commits into from
Sep 24, 2024

Conversation

ScottyPoi
Copy link
Collaborator

@ScottyPoi ScottyPoi commented Sep 24, 2024

Upgrades @ChainSafe dependencies:

  • @chainsafe/discv5
  • @chainsafe/ssz
  • @chainsafe/persistent-merkle-tree
  • @chainsafe/ssz

Replaces

  • @libp2p/interface
  • @libp2p/peer-id
  • @libp2p/peer-id-factory

With

  • @libp2p/crypto

--
Notable change in creation of ENR

Previously we would generate a PeerId, containing a Secp256k1 keyapir, and use that PeerId to create a SignableENR

Now, we use @libp2p/crypto to generate a secp256k1 PrivateKey, and use that PrivateKey to create the ENR. This PrivateKey can be serialized and stored in the DB to reboot nodes with the same ENR.

We no longer need the @libp2p/peer-id related dependencies, as we no longer need to generate the PeerId.

@ScottyPoi ScottyPoi merged commit 62d80b5 into master Sep 24, 2024
4 checks passed
@ScottyPoi ScottyPoi linked an issue Sep 24, 2024 that may be closed by this pull request
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.

Update discv5
2 participants