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

feat: update utp-rs dependency #1652

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open

Conversation

morph-dev
Copy link
Collaborator

@morph-dev morph-dev commented Jan 28, 2025

What was wrong?

It's possible for wrong Enr to be passed to utp library if it was changed recently.
See #1596 for more details.

How was it fixed?

The utp-rs library is updated (see ethereum/utp#136) so only peer id (NodeId) is required when receiving the utp packet, while entire peer (Enr) is passed when calling accept_with_cid.

The biggest change is in crates/portalnet/src/discovery.rs, where we now call find_enr only if Enr is unknown when we have to send them packet (which should rarely happen), instead of every time we receive packet.

Worth highlighting that due to the nature of #1596, we can't easily verify that this actually fixes it until it's deployed to the servers. I did some manual testing and I'm confident that this should fix it (but I plan to verify once this is merged and deployed).

To-Do

@morph-dev morph-dev self-assigned this Jan 28, 2025
@morph-dev morph-dev marked this pull request as ready for review January 28, 2025 21:25
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.

1 participant