ethereum / devp2p

Ethereum peer-to-peer networking specifications
995 stars 277 forks source link

rlpx.md: spec is ambiguous wrt first msg after handshake #128

Closed gsalgado closed 4 years ago

gsalgado commented 4 years ago

The "p2p" capability is present on all connections. After the initial handshake, both sides of the connection must send a Hello message. Upon receiving the Hello message a session is active and any other message may be sent. Implementations must ignore any difference in protocol version for forward-compatibility reasons. When communicating with a peer of lower version, implementations should try to mimic that version.

At any time, a Disconnect message may be sent.

In practice, a maxed-out geth node will send a Disconnect msg before the Hello, which kind of makes more sense than sending a Hello just to follow it with a Disconnect, but then the spec should probably be updated to reflect that after the initial handshake either a Hello or a Disconnect can be sent

fjl commented 4 years ago

Please check #129