DiscV4 sending FindNode request #4892
Closed
ana-prdekalo
started this conversation in
Technical discussions
Replies: 1 comment 1 reply
-
oh, I believe your assessment is correct, nice find. the problematic line is this one: reth/crates/net/discv4/src/lib.rs Lines 1315 to 1316 in 2cddd0f which sends a ping, but this only proves the endpoint from our side but does not prove it for the target node.
exactly so we should indeed wait until the endpoint proof has been established (we sent a pong to a ping, that should follow after we received a pong) |
Beta Was this translation helpful? Give feedback.
1 reply
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Hi,
I was going through
discv4
code, and I noticed thatFindNode
is issued on a successfulPong
response on this line.In discv4 docs it is said that:
Again, from the docs, the sender is verified if:
My understanding is that if I'm running a node, in order for my
FindNode
request to be verified, I should've responded to thePing
request withPong
to the node I'm requestingNeighbours
from.So, if my understanding of the docs and the code is okay, in the current implementation, we are sending
FindNode
after we initiatePing
, but this doesn't mean that we're necessarily verified in "the eyes" of a node we're requesting Neighbors from. Am I correct?If my understanding is correct, why not assume that when we receive
Ping
from some node, ourPong
will be successfully sent&verified and tie requesting neighbors toPing
message rather than toPong
?Beta Was this translation helpful? Give feedback.
All reactions