Skip to content

Commit d252d81

Browse files
authored
simulators/ethereum/engine,pyspec: Update Trusted Setup (#915)
* simulators/ethereum/engine: Update geth branch, use mainnet trusted setup * simulators/ethereum: go.work.sum * simulators/ethereum/pyspec: Update geth branch * configs/cancun: Update geth to devnet-10 * simulators/ethereum/engine: Send different blobs depending on the sender
1 parent 0c04405 commit d252d81

File tree

11 files changed

+4343
-111
lines changed

11 files changed

+4343
-111
lines changed

configs/cancun.yaml

+1-1
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@
2323
dockerfile: git
2424
build_args:
2525
github: lightclient/go-ethereum
26-
tag: devnet-9
26+
tag: devnet-10
2727

2828
- client: nethermind
2929
nametag: cancun-git

simulators/ethereum/engine/devp2p/conn.go

+14-14
Original file line numberDiff line numberDiff line change
@@ -103,24 +103,24 @@ func (msg Transactions) Code() int { return 18 }
103103
func (msg Transactions) ReqID() uint64 { return 18 }
104104

105105
// GetBlockHeaders represents a block header query.
106-
type GetBlockHeaders eth.GetBlockHeadersPacket66
106+
type GetBlockHeaders eth.GetBlockHeadersPacket
107107

108108
func (msg GetBlockHeaders) Code() int { return 19 }
109109
func (msg GetBlockHeaders) ReqID() uint64 { return msg.RequestId }
110110

111-
type BlockHeaders eth.BlockHeadersPacket66
111+
type BlockHeaders eth.BlockHeadersPacket
112112

113113
func (msg BlockHeaders) Code() int { return 20 }
114114
func (msg BlockHeaders) ReqID() uint64 { return msg.RequestId }
115115

116116
// GetBlockBodies represents a GetBlockBodies request
117-
type GetBlockBodies eth.GetBlockBodiesPacket66
117+
type GetBlockBodies eth.GetBlockBodiesPacket
118118

119119
func (msg GetBlockBodies) Code() int { return 21 }
120120
func (msg GetBlockBodies) ReqID() uint64 { return msg.RequestId }
121121

122122
// BlockBodies is the network packet for block content distribution.
123-
type BlockBodies eth.BlockBodiesPacket66
123+
type BlockBodies eth.BlockBodiesPacket
124124

125125
func (msg BlockBodies) Code() int { return 22 }
126126
func (msg BlockBodies) ReqID() uint64 { return msg.RequestId }
@@ -132,7 +132,7 @@ func (msg NewBlock) Code() int { return 23 }
132132
func (msg NewBlock) ReqID() uint64 { return 0 }
133133

134134
// NewPooledTransactionHashes66 is the network packet for the tx hash propagation message.
135-
type NewPooledTransactionHashes66 eth.NewPooledTransactionHashesPacket66
135+
type NewPooledTransactionHashes66 eth.NewPooledTransactionHashesPacket67
136136

137137
func (msg NewPooledTransactionHashes66) Code() int { return 24 }
138138
func (msg NewPooledTransactionHashes66) ReqID() uint64 { return 0 }
@@ -143,7 +143,7 @@ type NewPooledTransactionHashes eth.NewPooledTransactionHashesPacket68
143143
func (msg NewPooledTransactionHashes) Code() int { return 24 }
144144
func (msg NewPooledTransactionHashes) ReqID() uint64 { return 0 }
145145

146-
type GetPooledTransactions eth.GetPooledTransactionsPacket66
146+
type GetPooledTransactions eth.GetPooledTransactionsPacket
147147

148148
func (msg GetPooledTransactions) Code() int { return 25 }
149149
func (msg GetPooledTransactions) ReqID() uint64 { return msg.RequestId }
@@ -200,25 +200,25 @@ func (c *Conn) Read() (Message, error) {
200200
case (Status{}).Code():
201201
msg = new(Status)
202202
case (GetBlockHeaders{}).Code():
203-
ethMsg := new(eth.GetBlockHeadersPacket66)
203+
ethMsg := new(eth.GetBlockHeadersPacket)
204204
if err := rlp.DecodeBytes(rawData, ethMsg); err != nil {
205205
return nil, errorf("could not rlp decode message: %v, %x", err, rawData)
206206
}
207207
return (*GetBlockHeaders)(ethMsg), nil
208208
case (BlockHeaders{}).Code():
209-
ethMsg := new(eth.BlockHeadersPacket66)
209+
ethMsg := new(eth.BlockHeadersPacket)
210210
if err := rlp.DecodeBytes(rawData, ethMsg); err != nil {
211211
return nil, errorf("could not rlp decode message: %v, %x", err, rawData)
212212
}
213213
return (*BlockHeaders)(ethMsg), nil
214214
case (GetBlockBodies{}).Code():
215-
ethMsg := new(eth.GetBlockBodiesPacket66)
215+
ethMsg := new(eth.GetBlockBodiesPacket)
216216
if err := rlp.DecodeBytes(rawData, ethMsg); err != nil {
217217
return nil, errorf("could not rlp decode message: %v, %x", err, rawData)
218218
}
219219
return (*GetBlockBodies)(ethMsg), nil
220220
case (BlockBodies{}).Code():
221-
ethMsg := new(eth.BlockBodiesPacket66)
221+
ethMsg := new(eth.BlockBodiesPacket)
222222
if err := rlp.DecodeBytes(rawData, ethMsg); err != nil {
223223
return nil, errorf("could not rlp decode message: %v, %x", err, rawData)
224224
}
@@ -237,7 +237,7 @@ func (c *Conn) Read() (Message, error) {
237237
}
238238
msg = new(NewPooledTransactionHashes66)
239239
case (GetPooledTransactions{}.Code()):
240-
ethMsg := new(eth.GetPooledTransactionsPacket66)
240+
ethMsg := new(eth.GetPooledTransactionsPacket)
241241
if err := rlp.DecodeBytes(rawData, ethMsg); err != nil {
242242
return nil, errorf("could not rlp decode message: %v, %x", err, rawData)
243243
}
@@ -422,8 +422,8 @@ func (c *Conn) readAndServe(timeout time.Duration) (Message, error) {
422422
return nil, errorf("could not get headers for inbound header request: %v", err)
423423
}
424424
resp := &BlockHeaders{
425-
RequestId: msg.ReqID(),
426-
BlockHeadersPacket: eth.BlockHeadersPacket(headers),
425+
RequestId: msg.ReqID(),
426+
BlockHeadersRequest: eth.BlockHeadersRequest(headers),
427427
}
428428
if _, err := c.Write(resp); err != nil {
429429
return nil, errorf("could not write to connection: %v", err)
@@ -455,7 +455,7 @@ func (c *Conn) headersRequest(request *GetBlockHeaders, reqID uint64) ([]*types.
455455
if !ok {
456456
return nil, fmt.Errorf("unexpected message received: %s", pretty.Sdump(msg))
457457
}
458-
headers := []*types.Header(resp.BlockHeadersPacket)
458+
headers := []*types.Header(resp.BlockHeadersRequest)
459459
return headers, nil
460460
}
461461

simulators/ethereum/engine/go.mod

+17-16
Original file line numberDiff line numberDiff line change
@@ -3,20 +3,20 @@ module github.com/ethereum/hive/simulators/ethereum/engine
33
go 1.20
44

55
require (
6-
github.com/crate-crypto/go-kzg-4844 v0.3.0
6+
github.com/crate-crypto/go-kzg-4844 v0.6.1-0.20231019121413-3621cc59f0c7
77
github.com/davecgh/go-spew v1.1.1
88
github.com/ethereum/go-ethereum v1.13.1
99
github.com/ethereum/hive v0.0.0-20230919110229-d58aec4a3eb5
10-
github.com/golang-jwt/jwt/v4 v4.4.3
10+
github.com/golang-jwt/jwt/v4 v4.5.0
1111
github.com/holiman/uint256 v1.2.3
1212
github.com/pkg/errors v0.9.1
13-
golang.org/x/exp v0.0.0-20230810033253-352e893a4cad
13+
golang.org/x/exp v0.0.0-20230905200255-921286631fa9
1414
)
1515

1616
require (
1717
github.com/DataDog/zstd v1.5.2 // indirect
1818
github.com/Microsoft/go-winio v0.6.1 // indirect
19-
github.com/VictoriaMetrics/fastcache v1.12.0 // indirect
19+
github.com/VictoriaMetrics/fastcache v1.12.1 // indirect
2020
github.com/apapsch/go-jsonmerge/v2 v2.0.0 // indirect
2121
github.com/beorn7/perks v1.0.1 // indirect
2222
github.com/bits-and-blooms/bitset v1.7.0 // indirect
@@ -25,15 +25,16 @@ require (
2525
github.com/cespare/xxhash/v2 v2.2.0 // indirect
2626
github.com/cockroachdb/errors v1.9.1 // indirect
2727
github.com/cockroachdb/logtags v0.0.0-20230118201751-21c54148d20b // indirect
28-
github.com/cockroachdb/pebble v0.0.0-20230906160148-46873a6a7a06 // indirect
28+
github.com/cockroachdb/pebble v0.0.0-20230928194634-aa077af62593 // indirect
2929
github.com/cockroachdb/redact v1.1.3 // indirect
30+
github.com/cockroachdb/tokenbucket v0.0.0-20230807174530-cc333fc44b06 // indirect
3031
github.com/consensys/bavard v0.1.13 // indirect
31-
github.com/consensys/gnark-crypto v0.11.0 // indirect
32+
github.com/consensys/gnark-crypto v0.12.1 // indirect
3233
github.com/cpuguy83/go-md2man/v2 v2.0.2 // indirect
3334
github.com/deckarep/golang-set/v2 v2.1.0 // indirect
3435
github.com/decred/dcrd/dcrec/secp256k1/v4 v4.1.0 // indirect
3536
github.com/deepmap/oapi-codegen v1.12.4 // indirect
36-
github.com/ethereum/c-kzg-4844 v0.3.1 // indirect
37+
github.com/ethereum/c-kzg-4844 v0.3.2-0.20231019020040-748283cced54 // indirect
3738
github.com/fjl/memsize v0.0.1 // indirect
3839
github.com/fsnotify/fsnotify v1.6.0 // indirect
3940
github.com/gballet/go-libpcsclite v0.0.0-20191108122812-4678299bea08 // indirect
@@ -42,7 +43,7 @@ require (
4243
github.com/go-stack/stack v1.8.1 // indirect
4344
github.com/gofrs/flock v0.8.1 // indirect
4445
github.com/gogo/protobuf v1.3.2 // indirect
45-
github.com/golang/protobuf v1.5.2 // indirect
46+
github.com/golang/protobuf v1.5.3 // indirect
4647
github.com/golang/snappy v0.0.5-0.20220116011046-fa5810519dcb // indirect
4748
github.com/google/uuid v1.3.0 // indirect
4849
github.com/gorilla/websocket v1.5.0 // indirect
@@ -59,7 +60,7 @@ require (
5960
github.com/kr/pretty v0.3.1 // indirect
6061
github.com/kr/text v0.2.0 // indirect
6162
github.com/mattn/go-colorable v0.1.13 // indirect
62-
github.com/mattn/go-isatty v0.0.16 // indirect
63+
github.com/mattn/go-isatty v0.0.17 // indirect
6364
github.com/mattn/go-runewidth v0.0.14 // indirect
6465
github.com/matttproud/golang_protobuf_extensions v1.0.4 // indirect
6566
github.com/mitchellh/mapstructure v1.5.0 // indirect
@@ -85,17 +86,17 @@ require (
8586
github.com/urfave/cli/v2 v2.25.7 // indirect
8687
github.com/xrash/smetrics v0.0.0-20201216005158-039620a65673 // indirect
8788
github.com/yusufpapurcu/wmi v1.2.2 // indirect
88-
golang.org/x/crypto v0.12.0 // indirect
89-
golang.org/x/mod v0.11.0 // indirect
90-
golang.org/x/net v0.10.0 // indirect
89+
golang.org/x/crypto v0.14.0 // indirect
90+
golang.org/x/mod v0.12.0 // indirect
91+
golang.org/x/net v0.17.0 // indirect
9192
golang.org/x/sync v0.3.0 // indirect
92-
golang.org/x/sys v0.11.0 // indirect
93-
golang.org/x/text v0.12.0 // indirect
93+
golang.org/x/sys v0.13.0 // indirect
94+
golang.org/x/text v0.13.0 // indirect
9495
golang.org/x/time v0.3.0 // indirect
95-
golang.org/x/tools v0.9.1 // indirect
96+
golang.org/x/tools v0.13.0 // indirect
9697
google.golang.org/protobuf v1.28.1 // indirect
9798
gopkg.in/natefinch/lumberjack.v2 v2.0.0 // indirect
9899
rsc.io/tmplfunc v0.0.3 // indirect
99100
)
100101

101-
replace github.com/ethereum/go-ethereum => github.com/lightclient/go-ethereum v1.10.10-0.20230926150549-ae44519d720c
102+
replace github.com/ethereum/go-ethereum => github.com/lightclient/go-ethereum v1.10.10-0.20231019143932-4d161dee0c4c

0 commit comments

Comments
 (0)