core/forkid: implement the forkid EIP, announce via ENR (#19738)

* eth: chain config (genesis + fork) ENR entry

* core/forkid, eth: protocol independent fork ID, update to CRC32 spec

* core/forkid, eth: make forkid a struct, next uint64, enr struct, RLP

* core/forkid: change forkhash rlp encoding from int to [4]byte

* eth: fixup eth entry a bit and update it every block

* eth: fix lint

* eth: fix crash in ethclient tests
This commit is contained in:
Péter Szilágyi
2019-07-08 18:53:47 +03:00
committed by GitHub
parent cc0f0e27a6
commit 983f92368b
11 changed files with 571 additions and 96 deletions

View File

@ -70,7 +70,7 @@ func TestGetSetIPv6(t *testing.T) {
assert.Equal(t, ip, ip2)
}
// TestGetSetDiscPort tests encoding/decoding and setting/getting of the DiscPort key.
// TestGetSetUDP tests encoding/decoding and setting/getting of the UDP key.
func TestGetSetUDP(t *testing.T) {
port := UDP(30309)
var r Record