Compare commits

...

9 Commits

Author SHA1 Message Date
JihoonSong
75da91417b Consider Gloas when calling ForkchoiceUpdated (#15753) 2025-10-23 13:29:27 -07:00
terence tsao
263055a315 Save full payload by default 2025-10-23 13:28:48 -07:00
JihoonSong
7ccdff0ee6 Add serialization for Gloas block (#15747) 2025-10-23 13:28:48 -07:00
terence tsao
2f492d81ee implement eip-7928 as a gloas fork without eip-7732 2025-10-23 13:28:01 -07:00
terence
46bc81b4c8 Add metric to track data columns recovered from execution layer (#15924) 2025-10-23 15:50:25 +00:00
kasey
9c4774b82e default new blob storage layouts to by-epoch (#15904)
* default new blob storage layouts to by-epoch

also, do not log migration message until we see a directory that needs to be migrated

Co-authored-by: Manu NALEPA <enalepa@offchainlabs.com>

* manu feedback

---------

Co-authored-by: Kasey Kirkham <kasey@users.noreply.github.com>
Co-authored-by: Manu NALEPA <enalepa@offchainlabs.com>
2025-10-22 20:09:18 +00:00
terence
7dd4f5948c Update consensus spec tests to v1.6.0-beta.1 with new hashes and URL template (#15918) 2025-10-22 18:22:19 +00:00
Radosław Kapka
2f090c52d9 Allow custom headers in validator client HTTP requests (#15884)
* Allow custom headers in validator client HTTP requests

* changelog <3

* improve flag description

* Bastin's review

* James' review

* add godoc for NodeConnectionOption
2025-10-22 13:47:35 +00:00
Manu NALEPA
3ecb5d0b67 Remove Reading static P2P private key from a file. log if Fulu is enabled. (#15913) 2025-10-22 11:52:31 +00:00
91 changed files with 9516 additions and 1844 deletions

View File

@@ -253,16 +253,16 @@ filegroup(
url = "https://github.com/ethereum/EIPs/archive/5480440fe51742ed23342b68cf106cefd427e39d.tar.gz",
)
consensus_spec_version = "v1.6.0-beta.0"
consensus_spec_version = "v1.6.0-beta.1"
load("@prysm//tools:download_spectests.bzl", "consensus_spec_tests")
consensus_spec_tests(
name = "consensus_spec_tests",
flavors = {
"general": "sha256-rT3jQp2+ZaDiO66gIQggetzqr+kGeexaLqEhbx4HDMY=",
"minimal": "sha256-wowwwyvd0KJLsE+oDOtPkrhZyJndJpJ0lbXYsLH6XBw=",
"mainnet": "sha256-4ZLrLNeO7NihZ4TuWH5V5fUhvW9Y3mAPBQDCqrfShps=",
"general": "sha256-oEj0MTViJHjZo32nABK36gfvSXpbwkBk/jt6Mj7pWFI=",
"minimal": "sha256-cS4NPv6IRBoCSmWomQ8OEo8IsVNW9YawUFqoRZQBUj4=",
"mainnet": "sha256-BYuLndMPAh4p13IRJgNfVakrCVL69KRrNw2tdc3ETbE=",
},
version = consensus_spec_version,
)
@@ -278,7 +278,7 @@ filegroup(
visibility = ["//visibility:public"],
)
""",
integrity = "sha256-sBe3Rx8zGq9IrvfgIhZQpYidGjy3mE1SiCb6/+pjLdY=",
integrity = "sha256-yrq3tdwPS8Ri+ueeLAHssIT3ssMrX7zvHiJ8Xf9GVYs=",
strip_prefix = "consensus-specs-" + consensus_spec_version[1:],
url = "https://github.com/ethereum/consensus-specs/archive/refs/tags/%s.tar.gz" % consensus_spec_version,
)

View File

@@ -6,6 +6,7 @@ go_library(
"client.go",
"errors.go",
"options.go",
"transport.go",
],
importpath = "github.com/OffchainLabs/prysm/v6/api/client",
visibility = ["//visibility:public"],
@@ -14,7 +15,13 @@ go_library(
go_test(
name = "go_default_test",
srcs = ["client_test.go"],
srcs = [
"client_test.go",
"transport_test.go",
],
embed = [":go_default_library"],
deps = ["//testing/require:go_default_library"],
deps = [
"//testing/assert:go_default_library",
"//testing/require:go_default_library",
],
)

25
api/client/transport.go Normal file
View File

@@ -0,0 +1,25 @@
package client
import "net/http"
// CustomHeadersTransport adds custom headers to each request
type CustomHeadersTransport struct {
base http.RoundTripper
headers map[string][]string
}
func NewCustomHeadersTransport(base http.RoundTripper, headers map[string][]string) *CustomHeadersTransport {
return &CustomHeadersTransport{
base: base,
headers: headers,
}
}
func (t *CustomHeadersTransport) RoundTrip(req *http.Request) (*http.Response, error) {
for header, values := range t.headers {
for _, value := range values {
req.Header.Add(header, value)
}
}
return t.base.RoundTrip(req)
}

View File

@@ -0,0 +1,25 @@
package client
import (
"net/http"
"net/http/httptest"
"testing"
"github.com/OffchainLabs/prysm/v6/testing/assert"
"github.com/OffchainLabs/prysm/v6/testing/require"
)
type noopTransport struct{}
func (*noopTransport) RoundTrip(*http.Request) (*http.Response, error) {
return nil, nil
}
func TestRoundTrip(t *testing.T) {
tr := &CustomHeadersTransport{base: &noopTransport{}, headers: map[string][]string{"key1": []string{"value1", "value2"}, "key2": []string{"value3"}}}
req := httptest.NewRequest("GET", "http://foo", nil)
_, err := tr.RoundTrip(req)
require.NoError(t, err)
assert.DeepEqual(t, []string{"value1", "value2"}, req.Header.Values("key1"))
assert.DeepEqual(t, []string{"value3"}, req.Header.Values("key2"))
}

View File

@@ -192,6 +192,46 @@ func NewGenesisBlockForState(ctx context.Context, st state.BeaconState) (interfa
Block: electraGenesisBlock(root),
Signature: params.BeaconConfig().EmptySignature[:],
})
case *ethpb.BeaconStateGloas:
return blocks.NewSignedBeaconBlock(&ethpb.SignedBeaconBlockGloas{
Block: &ethpb.BeaconBlockGloas{
ParentRoot: params.BeaconConfig().ZeroHash[:],
StateRoot: root[:],
Body: &ethpb.BeaconBlockBodyGloas{
RandaoReveal: make([]byte, 96),
Eth1Data: &ethpb.Eth1Data{
DepositRoot: make([]byte, 32),
BlockHash: make([]byte, 32),
},
Graffiti: make([]byte, 32),
SyncAggregate: &ethpb.SyncAggregate{
SyncCommitteeBits: make([]byte, fieldparams.SyncCommitteeLength/8),
SyncCommitteeSignature: make([]byte, fieldparams.BLSSignatureLength),
},
ExecutionPayload: &enginev1.ExecutionPayloadGloas{
ParentHash: make([]byte, 32),
FeeRecipient: make([]byte, 20),
StateRoot: make([]byte, 32),
ReceiptsRoot: make([]byte, 32),
LogsBloom: make([]byte, 256),
PrevRandao: make([]byte, 32),
ExtraData: make([]byte, 0),
BaseFeePerGas: make([]byte, 32),
BlockHash: make([]byte, 32),
Transactions: make([][]byte, 0),
Withdrawals: make([]*enginev1.Withdrawal, 0),
},
BlsToExecutionChanges: make([]*ethpb.SignedBLSToExecutionChange, 0),
BlobKzgCommitments: make([][]byte, 0),
ExecutionRequests: &enginev1.ExecutionRequests{
Withdrawals: make([]*enginev1.WithdrawalRequest, 0),
Deposits: make([]*enginev1.DepositRequest, 0),
Consolidations: make([]*enginev1.ConsolidationRequest, 0),
},
},
},
Signature: params.BeaconConfig().EmptySignature[:],
})
default:
return nil, ErrUnrecognizedState
}

View File

@@ -0,0 +1,19 @@
load("@prysm//tools/go:def.bzl", "go_library")
go_library(
name = "go_default_library",
srcs = ["upgrade.go"],
importpath = "github.com/OffchainLabs/prysm/v6/beacon-chain/core/gloas",
visibility = ["//visibility:public"],
deps = [
"//beacon-chain/core/helpers:go_default_library",
"//beacon-chain/core/time:go_default_library",
"//beacon-chain/state:go_default_library",
"//beacon-chain/state/state-native:go_default_library",
"//config/params:go_default_library",
"//proto/engine/v1:go_default_library",
"//proto/prysm/v1alpha1:go_default_library",
"//time/slots:go_default_library",
"@com_github_pkg_errors//:go_default_library",
],
)

View File

@@ -0,0 +1,189 @@
package gloas
import (
"context"
"github.com/OffchainLabs/prysm/v6/beacon-chain/core/helpers"
"github.com/OffchainLabs/prysm/v6/beacon-chain/core/time"
"github.com/OffchainLabs/prysm/v6/beacon-chain/state"
state_native "github.com/OffchainLabs/prysm/v6/beacon-chain/state/state-native"
"github.com/OffchainLabs/prysm/v6/config/params"
enginev1 "github.com/OffchainLabs/prysm/v6/proto/engine/v1"
ethpb "github.com/OffchainLabs/prysm/v6/proto/prysm/v1alpha1"
"github.com/OffchainLabs/prysm/v6/time/slots"
"github.com/pkg/errors"
)
// UpgradeToGloas updates inputs a generic state to return the version Gloas state.
// This implements the upgrade_to_eip7928 function from the specification.
func UpgradeToGloas(ctx context.Context, beaconState state.BeaconState) (state.BeaconState, error) {
epoch := time.CurrentEpoch(beaconState)
currentSyncCommittee, err := beaconState.CurrentSyncCommittee()
if err != nil {
return nil, err
}
nextSyncCommittee, err := beaconState.NextSyncCommittee()
if err != nil {
return nil, err
}
prevEpochParticipation, err := beaconState.PreviousEpochParticipation()
if err != nil {
return nil, err
}
currentEpochParticipation, err := beaconState.CurrentEpochParticipation()
if err != nil {
return nil, err
}
inactivityScores, err := beaconState.InactivityScores()
if err != nil {
return nil, err
}
payloadHeader, err := beaconState.LatestExecutionPayloadHeader()
if err != nil {
return nil, err
}
txRoot, err := payloadHeader.TransactionsRoot()
if err != nil {
return nil, err
}
wdRoot, err := payloadHeader.WithdrawalsRoot()
if err != nil {
return nil, err
}
wi, err := beaconState.NextWithdrawalIndex()
if err != nil {
return nil, err
}
vi, err := beaconState.NextWithdrawalValidatorIndex()
if err != nil {
return nil, err
}
summaries, err := beaconState.HistoricalSummaries()
if err != nil {
return nil, err
}
excessBlobGas, err := payloadHeader.ExcessBlobGas()
if err != nil {
return nil, err
}
blobGasUsed, err := payloadHeader.BlobGasUsed()
if err != nil {
return nil, err
}
depositRequestsStartIndex, err := beaconState.DepositRequestsStartIndex()
if err != nil {
return nil, err
}
depositBalanceToConsume, err := beaconState.DepositBalanceToConsume()
if err != nil {
return nil, err
}
exitBalanceToConsume, err := beaconState.ExitBalanceToConsume()
if err != nil {
return nil, err
}
earliestExitEpoch, err := beaconState.EarliestExitEpoch()
if err != nil {
return nil, err
}
consolidationBalanceToConsume, err := beaconState.ConsolidationBalanceToConsume()
if err != nil {
return nil, err
}
earliestConsolidationEpoch, err := beaconState.EarliestConsolidationEpoch()
if err != nil {
return nil, err
}
pendingDeposits, err := beaconState.PendingDeposits()
if err != nil {
return nil, err
}
pendingPartialWithdrawals, err := beaconState.PendingPartialWithdrawals()
if err != nil {
return nil, err
}
pendingConsolidations, err := beaconState.PendingConsolidations()
if err != nil {
return nil, err
}
proposerLookahead, err := helpers.InitializeProposerLookahead(ctx, beaconState, slots.ToEpoch(beaconState.Slot()))
if err != nil {
return nil, err
}
// Create the new Gloas execution payload header with block_access_list_root
// as specified in the EIP7928 upgrade function
latestExecutionPayloadHeader := &enginev1.ExecutionPayloadHeaderGloas{
ParentHash: payloadHeader.ParentHash(),
FeeRecipient: payloadHeader.FeeRecipient(),
StateRoot: payloadHeader.StateRoot(),
ReceiptsRoot: payloadHeader.ReceiptsRoot(),
LogsBloom: payloadHeader.LogsBloom(),
PrevRandao: payloadHeader.PrevRandao(),
BlockNumber: payloadHeader.BlockNumber(),
GasLimit: payloadHeader.GasLimit(),
GasUsed: payloadHeader.GasUsed(),
Timestamp: payloadHeader.Timestamp(),
ExtraData: payloadHeader.ExtraData(),
BaseFeePerGas: payloadHeader.BaseFeePerGas(),
BlockHash: payloadHeader.BlockHash(),
TransactionsRoot: txRoot,
WithdrawalsRoot: wdRoot,
BlobGasUsed: blobGasUsed,
ExcessBlobGas: excessBlobGas,
BlockAccessListRoot: make([]byte, 32), // New in EIP7928 - empty Root()
}
s := &ethpb.BeaconStateGloas{
GenesisTime: uint64(beaconState.GenesisTime().Unix()),
GenesisValidatorsRoot: beaconState.GenesisValidatorsRoot(),
Slot: beaconState.Slot(),
Fork: &ethpb.Fork{
PreviousVersion: beaconState.Fork().CurrentVersion,
CurrentVersion: params.BeaconConfig().GloasForkVersion, // Modified in EIP7928
Epoch: epoch,
},
LatestBlockHeader: beaconState.LatestBlockHeader(),
BlockRoots: beaconState.BlockRoots(),
StateRoots: beaconState.StateRoots(),
HistoricalRoots: beaconState.HistoricalRoots(),
Eth1Data: beaconState.Eth1Data(),
Eth1DataVotes: beaconState.Eth1DataVotes(),
Eth1DepositIndex: beaconState.Eth1DepositIndex(),
Validators: beaconState.Validators(),
Balances: beaconState.Balances(),
RandaoMixes: beaconState.RandaoMixes(),
Slashings: beaconState.Slashings(),
PreviousEpochParticipation: prevEpochParticipation,
CurrentEpochParticipation: currentEpochParticipation,
JustificationBits: beaconState.JustificationBits(),
PreviousJustifiedCheckpoint: beaconState.PreviousJustifiedCheckpoint(),
CurrentJustifiedCheckpoint: beaconState.CurrentJustifiedCheckpoint(),
FinalizedCheckpoint: beaconState.FinalizedCheckpoint(),
InactivityScores: inactivityScores,
CurrentSyncCommittee: currentSyncCommittee,
NextSyncCommittee: nextSyncCommittee,
LatestExecutionPayloadHeader: latestExecutionPayloadHeader,
NextWithdrawalIndex: wi,
NextWithdrawalValidatorIndex: vi,
HistoricalSummaries: summaries,
DepositRequestsStartIndex: depositRequestsStartIndex,
DepositBalanceToConsume: depositBalanceToConsume,
ExitBalanceToConsume: exitBalanceToConsume,
EarliestExitEpoch: earliestExitEpoch,
ConsolidationBalanceToConsume: consolidationBalanceToConsume,
EarliestConsolidationEpoch: earliestConsolidationEpoch,
PendingDeposits: pendingDeposits,
PendingPartialWithdrawals: pendingPartialWithdrawals,
PendingConsolidations: pendingConsolidations,
ProposerLookahead: proposerLookahead,
}
post, err := state_native.InitializeFromProtoUnsafeGloas(s)
if err != nil {
return nil, errors.Wrap(err, "failed to initialize post gloas beaconState")
}
return post, nil
}

View File

@@ -108,6 +108,12 @@ func CanUpgradeToFulu(slot primitives.Slot) bool {
return epochStart && fuluEpoch
}
func CanUpgradeToGloas(slot primitives.Slot) bool {
epochStart := slots.IsEpochStart(slot)
gloasEpoch := slots.ToEpoch(slot) == params.BeaconConfig().GloasForkEpoch
return epochStart && gloasEpoch
}
// CanProcessEpoch checks the eligibility to process epoch.
// The epoch can be processed at the end of the last slot of every epoch.
//

View File

@@ -24,6 +24,7 @@ go_library(
"//beacon-chain/core/epoch/precompute:go_default_library",
"//beacon-chain/core/execution:go_default_library",
"//beacon-chain/core/fulu:go_default_library",
"//beacon-chain/core/gloas:go_default_library",
"//beacon-chain/core/helpers:go_default_library",
"//beacon-chain/core/time:go_default_library",
"//beacon-chain/core/transition/interop:go_default_library",

View File

@@ -17,6 +17,7 @@ import (
"github.com/OffchainLabs/prysm/v6/beacon-chain/core/epoch/precompute"
"github.com/OffchainLabs/prysm/v6/beacon-chain/core/execution"
"github.com/OffchainLabs/prysm/v6/beacon-chain/core/fulu"
"github.com/OffchainLabs/prysm/v6/beacon-chain/core/gloas"
"github.com/OffchainLabs/prysm/v6/beacon-chain/core/time"
"github.com/OffchainLabs/prysm/v6/beacon-chain/state"
"github.com/OffchainLabs/prysm/v6/config/features"
@@ -389,6 +390,15 @@ func UpgradeState(ctx context.Context, state state.BeaconState) (state.BeaconSta
upgraded = true
}
if time.CanUpgradeToGloas(slot) {
state, err = gloas.UpgradeToGloas(ctx, state)
if err != nil {
tracing.AnnotateError(span, err)
return nil, err
}
upgraded = true
}
if upgraded {
log.WithField("version", version.String(state.Version())).Info("Upgraded state to")
}

View File

@@ -212,7 +212,8 @@ func filterNoop(_ string) bool {
return true
}
func isRootDir(p string) bool {
// IsBlockRootDir returns true if the path segment looks like a block root directory.
func IsBlockRootDir(p string) bool {
dir := filepath.Base(p)
return len(dir) == rootStringLen && strings.HasPrefix(dir, "0x")
}

View File

@@ -188,7 +188,7 @@ func TestListDir(t *testing.T) {
name: "root filter",
dirPath: ".",
expected: []string{childlessBlob.name, blobWithSsz.name, blobWithSszAndTmp.name},
filter: isRootDir,
filter: IsBlockRootDir,
},
{
name: "ssz filter",

View File

@@ -19,12 +19,14 @@ import (
const (
// Full root in directory will be 66 chars, eg:
// >>> len('0x0002fb4db510b8618b04dc82d023793739c26346a8b02eb73482e24b0fec0555') == 66
rootStringLen = 66
sszExt = "ssz"
partExt = "part"
periodicEpochBaseDir = "by-epoch"
rootStringLen = 66
sszExt = "ssz"
partExt = "part"
)
// PeriodicEpochBaseDir is the name of the base directory for the by-epoch layout.
const PeriodicEpochBaseDir = "by-epoch"
const (
LayoutNameFlat = "flat"
LayoutNameByEpoch = "by-epoch"
@@ -130,11 +132,11 @@ func migrateLayout(fs afero.Fs, from, to fsLayout, cache *blobStorageSummaryCach
if iter.atEOF() {
return errLayoutNotDetected
}
log.WithField("fromLayout", from.name()).WithField("toLayout", to.name()).Info("Migrating blob filesystem layout. This one-time operation can take extra time (up to a few minutes for systems with extended blob storage and a cold disk cache).")
lastMoved := ""
parentDirs := make(map[string]bool) // this map should have < 65k keys by design
moved := 0
dc := newDirCleaner()
migrationLogged := false
for ident, err := iter.next(); !errors.Is(err, io.EOF); ident, err = iter.next() {
if err != nil {
if errors.Is(err, errIdentFailure) {
@@ -146,6 +148,11 @@ func migrateLayout(fs afero.Fs, from, to fsLayout, cache *blobStorageSummaryCach
}
return errors.Wrapf(errMigrationFailure, "failed to iterate previous layout structure while migrating blobs, err=%s", err.Error())
}
if !migrationLogged {
log.WithField("fromLayout", from.name()).WithField("toLayout", to.name()).
Info("Migrating blob filesystem layout. This one-time operation can take extra time (up to a few minutes for systems with extended blob storage and a cold disk cache).")
migrationLogged = true
}
src := from.dir(ident)
target := to.dir(ident)
if src != lastMoved {

View File

@@ -34,7 +34,7 @@ func (l *periodicEpochLayout) name() string {
func (l *periodicEpochLayout) blockParentDirs(ident blobIdent) []string {
return []string{
periodicEpochBaseDir,
PeriodicEpochBaseDir,
l.periodDir(ident.epoch),
l.epochDir(ident.epoch),
}
@@ -50,28 +50,28 @@ func (l *periodicEpochLayout) notify(ident blobIdent) error {
// If before == 0, it won't be used as a filter and all idents will be returned.
func (l *periodicEpochLayout) iterateIdents(before primitives.Epoch) (*identIterator, error) {
_, err := l.fs.Stat(periodicEpochBaseDir)
_, err := l.fs.Stat(PeriodicEpochBaseDir)
if err != nil {
if os.IsNotExist(err) {
return &identIterator{eof: true}, nil // The directory is non-existent, which is fine; stop iteration.
}
return nil, errors.Wrapf(err, "error reading path %s", periodicEpochBaseDir)
return nil, errors.Wrapf(err, "error reading path %s", PeriodicEpochBaseDir)
}
// iterate root, which should have directories named by "period"
entries, err := listDir(l.fs, periodicEpochBaseDir)
entries, err := listDir(l.fs, PeriodicEpochBaseDir)
if err != nil {
return nil, errors.Wrapf(err, "failed to list %s", periodicEpochBaseDir)
return nil, errors.Wrapf(err, "failed to list %s", PeriodicEpochBaseDir)
}
return &identIterator{
fs: l.fs,
path: periodicEpochBaseDir,
path: PeriodicEpochBaseDir,
// Please see comments on the `layers` field in `identIterator`` if the role of the layers is unclear.
layers: []layoutLayer{
{populateIdent: populateNoop, filter: isBeforePeriod(before)},
{populateIdent: populateEpoch, filter: isBeforeEpoch(before)},
{populateIdent: populateRoot, filter: isRootDir}, // extract root from path
{populateIdent: populateIndex, filter: isSszFile}, // extract index from filename
{populateIdent: populateRoot, filter: IsBlockRootDir}, // extract root from path
{populateIdent: populateIndex, filter: isSszFile}, // extract index from filename
},
entries: entries,
}, nil
@@ -98,7 +98,7 @@ func (l *periodicEpochLayout) epochDir(epoch primitives.Epoch) string {
}
func (l *periodicEpochLayout) periodDir(epoch primitives.Epoch) string {
return filepath.Join(periodicEpochBaseDir, fmt.Sprintf("%d", periodForEpoch(epoch)))
return filepath.Join(PeriodicEpochBaseDir, fmt.Sprintf("%d", periodForEpoch(epoch)))
}
func (l *periodicEpochLayout) sszPath(n blobIdent) string {

View File

@@ -30,7 +30,7 @@ func (l *flatLayout) iterateIdents(before primitives.Epoch) (*identIterator, err
if os.IsNotExist(err) {
return &identIterator{eof: true}, nil // The directory is non-existent, which is fine; stop iteration.
}
return nil, errors.Wrapf(err, "error reading path %s", periodicEpochBaseDir)
return nil, errors.Wrap(err, "error reading blob base dir")
}
entries, err := listDir(l.fs, ".")
if err != nil {
@@ -199,10 +199,10 @@ func (l *flatSlotReader) isSSZAndBefore(fname string) bool {
// the epoch can be determined.
func isFlatCachedAndBefore(cache *blobStorageSummaryCache, before primitives.Epoch) func(string) bool {
if before == 0 {
return isRootDir
return IsBlockRootDir
}
return func(p string) bool {
if !isRootDir(p) {
if !IsBlockRootDir(p) {
return false
}
root, err := rootFromPath(p)

View File

@@ -58,6 +58,11 @@ var (
GetPayloadMethodV5,
GetBlobsV2,
}
gloasEngineEndpoints = []string{
NewPayloadMethodV5,
GetPayloadMethodV6,
}
)
const (
@@ -68,6 +73,8 @@ const (
NewPayloadMethodV3 = "engine_newPayloadV3"
// NewPayloadMethodV4 is the engine_newPayloadVX method added at Electra.
NewPayloadMethodV4 = "engine_newPayloadV4"
// NewPayloadMethodV5 is the engine_newPayloadVX method added at Gloas.
NewPayloadMethodV5 = "engine_newPayloadV5"
// ForkchoiceUpdatedMethod v1 request string for JSON-RPC.
ForkchoiceUpdatedMethod = "engine_forkchoiceUpdatedV1"
// ForkchoiceUpdatedMethodV2 v2 request string for JSON-RPC.
@@ -84,6 +91,8 @@ const (
GetPayloadMethodV4 = "engine_getPayloadV4"
// GetPayloadMethodV5 is the get payload method added for fulu
GetPayloadMethodV5 = "engine_getPayloadV5"
// GetPayloadMethodV6 is the get payload method added for gloas
GetPayloadMethodV6 = "engine_getPayloadV6"
// BlockByHashMethod request string for JSON-RPC.
BlockByHashMethod = "eth_getBlockByHash"
// BlockByNumberMethod request string for JSON-RPC.
@@ -178,6 +187,18 @@ func (s *Service) NewPayload(ctx context.Context, payload interfaces.ExecutionDa
return nil, handleRPCError(err)
}
}
case *pb.ExecutionPayloadGloas:
if executionRequests == nil {
return nil, errors.New("execution requests are required for gloas execution payload")
}
flattenedRequests, err := pb.EncodeExecutionRequests(executionRequests)
if err != nil {
return nil, errors.Wrap(err, "failed to encode execution requests")
}
err = s.rpcClient.CallContext(ctx, result, NewPayloadMethodV5, payloadPb, versionedHashes, parentBlockRoot, flattenedRequests)
if err != nil {
return nil, handleRPCError(err)
}
default:
return nil, errors.New("unknown execution data type")
}
@@ -239,7 +260,7 @@ func (s *Service) ForkchoiceUpdated(
if err != nil {
return nil, nil, handleRPCError(err)
}
case version.Deneb, version.Electra, version.Fulu:
case version.Deneb, version.Electra, version.Fulu, version.Gloas:
a, err := attrs.PbV3()
if err != nil {
return nil, nil, err
@@ -273,6 +294,9 @@ func (s *Service) ForkchoiceUpdated(
func getPayloadMethodAndMessage(slot primitives.Slot) (string, proto.Message) {
epoch := slots.ToEpoch(slot)
if epoch >= params.BeaconConfig().GloasForkEpoch {
return GetPayloadMethodV6, &pb.ExecutionBundleGloas{}
}
if epoch >= params.BeaconConfig().FuluForkEpoch {
return GetPayloadMethodV5, &pb.ExecutionBundleFulu{}
}
@@ -325,6 +349,10 @@ func (s *Service) ExchangeCapabilities(ctx context.Context) ([]string, error) {
supportedEngineEndpoints = append(supportedEngineEndpoints, fuluEngineEndpoints...)
}
if params.GloasEnabled() {
supportedEngineEndpoints = append(supportedEngineEndpoints, gloasEngineEndpoints...)
}
elSupportedEndpointsSlice := make([]string, len(supportedEngineEndpoints))
if err := s.rpcClient.CallContext(ctx, &elSupportedEndpointsSlice, ExchangeCapabilities, supportedEngineEndpoints); err != nil {
return nil, handleRPCError(err)

View File

@@ -32,6 +32,9 @@ var gossipTopicMappings = map[string]func() proto.Message{
func GossipTopicMappings(topic string, epoch primitives.Epoch) proto.Message {
switch topic {
case BlockSubnetTopicFormat:
if epoch >= params.BeaconConfig().GloasForkEpoch {
return &ethpb.SignedBeaconBlockGloas{}
}
if epoch >= params.BeaconConfig().FuluForkEpoch {
return &ethpb.SignedBeaconBlockFulu{}
}
@@ -144,4 +147,7 @@ func init() {
// Specially handle Fulu objects.
GossipTypeMapping[reflect.TypeOf(&ethpb.SignedBeaconBlockFulu{})] = BlockSubnetTopicFormat
// Specially handle Gloas objects.
GossipTypeMapping[reflect.TypeOf(&ethpb.SignedBeaconBlockGloas{})] = BlockSubnetTopicFormat
}

View File

@@ -85,6 +85,11 @@ func InitializeDataMaps() {
&ethpb.SignedBeaconBlockFulu{Block: &ethpb.BeaconBlockElectra{Body: &ethpb.BeaconBlockBodyElectra{ExecutionPayload: &enginev1.ExecutionPayloadDeneb{}}}},
)
},
bytesutil.ToBytes4(params.BeaconConfig().GloasForkVersion): func() (interfaces.ReadOnlySignedBeaconBlock, error) {
return blocks.NewSignedBeaconBlock(
&ethpb.SignedBeaconBlockGloas{Block: &ethpb.BeaconBlockGloas{Body: &ethpb.BeaconBlockBodyGloas{ExecutionPayload: &enginev1.ExecutionPayloadGloas{}}}},
)
},
}
// Reset our metadata map.
@@ -110,6 +115,9 @@ func InitializeDataMaps() {
bytesutil.ToBytes4(params.BeaconConfig().FuluForkVersion): func() (metadata.Metadata, error) {
return wrapper.WrappedMetadataV2(&ethpb.MetaDataV2{}), nil
},
bytesutil.ToBytes4(params.BeaconConfig().GloasForkVersion): func() (metadata.Metadata, error) {
return wrapper.WrappedMetadataV2(&ethpb.MetaDataV2{}), nil
},
}
// Reset our attestation map.
@@ -135,6 +143,9 @@ func InitializeDataMaps() {
bytesutil.ToBytes4(params.BeaconConfig().FuluForkVersion): func() (ethpb.Att, error) {
return &ethpb.SingleAttestation{}, nil
},
bytesutil.ToBytes4(params.BeaconConfig().GloasForkVersion): func() (ethpb.Att, error) {
return &ethpb.SingleAttestation{}, nil
},
}
// Reset our aggregate attestation map.
@@ -160,6 +171,9 @@ func InitializeDataMaps() {
bytesutil.ToBytes4(params.BeaconConfig().FuluForkVersion): func() (ethpb.SignedAggregateAttAndProof, error) {
return &ethpb.SignedAggregateAttestationAndProofElectra{}, nil
},
bytesutil.ToBytes4(params.BeaconConfig().GloasForkVersion): func() (ethpb.SignedAggregateAttAndProof, error) {
return &ethpb.SignedAggregateAttestationAndProofElectra{}, nil
},
}
// Reset our aggregate attestation map.
@@ -185,6 +199,9 @@ func InitializeDataMaps() {
bytesutil.ToBytes4(params.BeaconConfig().FuluForkVersion): func() (ethpb.AttSlashing, error) {
return &ethpb.AttesterSlashingElectra{}, nil
},
bytesutil.ToBytes4(params.BeaconConfig().GloasForkVersion): func() (ethpb.AttSlashing, error) {
return &ethpb.AttesterSlashingElectra{}, nil
},
}
// Reset our light client optimistic update map.
@@ -204,6 +221,12 @@ func InitializeDataMaps() {
bytesutil.ToBytes4(params.BeaconConfig().ElectraForkVersion): func() (interfaces.LightClientOptimisticUpdate, error) {
return lightclientConsensusTypes.NewEmptyOptimisticUpdateDeneb(), nil
},
bytesutil.ToBytes4(params.BeaconConfig().FuluForkVersion): func() (interfaces.LightClientOptimisticUpdate, error) {
return lightclientConsensusTypes.NewEmptyOptimisticUpdateDeneb(), nil
},
bytesutil.ToBytes4(params.BeaconConfig().GloasForkVersion): func() (interfaces.LightClientOptimisticUpdate, error) {
return lightclientConsensusTypes.NewEmptyOptimisticUpdateDeneb(), nil
},
}
// Reset our light client finality update map.
@@ -223,5 +246,11 @@ func InitializeDataMaps() {
bytesutil.ToBytes4(params.BeaconConfig().ElectraForkVersion): func() (interfaces.LightClientFinalityUpdate, error) {
return lightclientConsensusTypes.NewEmptyFinalityUpdateElectra(), nil
},
bytesutil.ToBytes4(params.BeaconConfig().FuluForkVersion): func() (interfaces.LightClientFinalityUpdate, error) {
return lightclientConsensusTypes.NewEmptyFinalityUpdateElectra(), nil
},
bytesutil.ToBytes4(params.BeaconConfig().GloasForkVersion): func() (interfaces.LightClientFinalityUpdate, error) {
return lightclientConsensusTypes.NewEmptyFinalityUpdateElectra(), nil
},
}
}

View File

@@ -68,7 +68,10 @@ func privKey(cfg *Config) (*ecdsa.PrivateKey, error) {
}
if defaultKeysExist {
log.WithField("filePath", defaultKeyPath).Info("Reading static P2P private key from a file. To generate a new random private key at every start, please remove this file.")
if !params.FuluEnabled() {
log.WithField("filePath", defaultKeyPath).Info("Reading static P2P private key from a file. To generate a new random private key at every start, please remove this file.")
}
return privKeyFromFile(defaultKeyPath)
}

View File

@@ -57,6 +57,12 @@ func (vs *Server) constructGenericBeaconBlock(
return nil, fmt.Errorf("expected *BlobsBundleV2, got %T", blobsBundler)
}
return vs.constructFuluBlock(blockProto, isBlinded, bidStr, bundle), nil
case version.Gloas:
bundle, ok := blobsBundler.(*enginev1.BlobsBundleV2)
if blobsBundler != nil && !ok {
return nil, fmt.Errorf("expected *BlobsBundleV2, got %T", blobsBundler)
}
return vs.constructGloasBlock(blockProto, isBlinded, bidStr, bundle), nil
default:
return nil, fmt.Errorf("unknown block version: %d", sBlk.Version())
}
@@ -120,3 +126,12 @@ func (vs *Server) constructFuluBlock(blockProto proto.Message, isBlinded bool, p
}
return &ethpb.GenericBeaconBlock{Block: &ethpb.GenericBeaconBlock_Fulu{Fulu: fuluContents}, IsBlinded: false, PayloadValue: payloadValue}
}
func (vs *Server) constructGloasBlock(blockProto proto.Message, isBlinded bool, payloadValue string, bundle *enginev1.BlobsBundleV2) *ethpb.GenericBeaconBlock {
gloasContents := &ethpb.BeaconBlockContentsGloas{Block: blockProto.(*ethpb.BeaconBlockGloas)}
if bundle != nil {
gloasContents.KzgProofs = bundle.Proofs
gloasContents.Blobs = bundle.Blobs
}
return &ethpb.GenericBeaconBlock{Block: &ethpb.GenericBeaconBlock_Gloas{Gloas: gloasContents}, IsBlinded: false, PayloadValue: payloadValue}
}

View File

@@ -300,7 +300,7 @@ func (vs *Server) ProposeBeaconBlock(ctx context.Context, req *ethpb.GenericSign
return nil, status.Errorf(codes.Internal, "Could not hash tree root: %v", err)
}
// For post-Fulu blinded blocks, submit to relay and return early
// For post-Fulu blinded blocks (including Gloas), submit to relay and return early
if block.IsBlinded() && slots.ToEpoch(block.Block().Slot()) >= params.BeaconConfig().FuluForkEpoch {
err := vs.BlockBuilder.SubmitBlindedBlockPostFulu(ctx, block)
if err != nil {
@@ -370,7 +370,7 @@ func (vs *Server) broadcastAndReceiveSidecars(
}
// handleBlindedBlock processes blinded beacon blocks (pre-Fulu only).
// Post-Fulu blinded blocks are handled directly in ProposeBeaconBlock.
// Post-Fulu blinded blocks (including Gloas) are handled directly in ProposeBeaconBlock.
func (vs *Server) handleBlindedBlock(ctx context.Context, block interfaces.SignedBeaconBlock) (interfaces.SignedBeaconBlock, []*ethpb.BlobSidecar, error) {
if block.Version() < version.Bellatrix {
return nil, nil, errors.New("pre-Bellatrix blinded block")
@@ -640,6 +640,9 @@ func blobsAndProofs(req *ethpb.GenericSignedBeaconBlock) ([][]byte, [][]byte, er
case req.GetFulu() != nil:
dbBlockContents := req.GetFulu()
return dbBlockContents.Blobs, dbBlockContents.KzgProofs, nil
case req.GetGloas() != nil:
dbBlockContents := req.GetGloas()
return dbBlockContents.Blobs, dbBlockContents.KzgProofs, nil
default:
return nil, nil, errors.Errorf("unknown request type provided: %T", req)
}

View File

@@ -473,6 +473,11 @@ func isVersionCompatible(bidVersion, headBlockVersion int) bool {
return true
}
// Allow Electra bids for Gloas blocks - they have compatible payload formats
if bidVersion == version.Electra && headBlockVersion == version.Gloas {
return true
}
// For all other cases, require exact version match
return false
}

View File

@@ -16,6 +16,11 @@ func getEmptyBlock(slot primitives.Slot) (interfaces.SignedBeaconBlock, error) {
var err error
epoch := slots.ToEpoch(slot)
switch {
case epoch >= params.BeaconConfig().GloasForkEpoch:
sBlk, err = blocks.NewSignedBeaconBlock(&ethpb.SignedBeaconBlockGloas{Block: &ethpb.BeaconBlockGloas{Body: &ethpb.BeaconBlockBodyGloas{}}})
if err != nil {
return nil, status.Errorf(codes.Internal, "Could not initialize block for proposal: %v", err)
}
case epoch >= params.BeaconConfig().FuluForkEpoch:
sBlk, err = blocks.NewSignedBeaconBlock(&ethpb.SignedBeaconBlockFulu{Block: &ethpb.BeaconBlockElectra{Body: &ethpb.BeaconBlockBodyElectra{}}})
if err != nil {

View File

@@ -136,7 +136,7 @@ func (vs *Server) getLocalPayloadFromEngine(
}
var attr payloadattribute.Attributer
switch st.Version() {
case version.Deneb, version.Electra, version.Fulu:
case version.Deneb, version.Electra, version.Fulu, version.Gloas:
withdrawals, _, err := st.ExpectedWithdrawals()
if err != nil {
return nil, err

View File

@@ -52,6 +52,7 @@ type BeaconState struct {
latestExecutionPayloadHeader *enginev1.ExecutionPayloadHeader
latestExecutionPayloadHeaderCapella *enginev1.ExecutionPayloadHeaderCapella
latestExecutionPayloadHeaderDeneb *enginev1.ExecutionPayloadHeaderDeneb
latestExecutionPayloadHeaderGloas *enginev1.ExecutionPayloadHeaderGloas
// Capella fields
nextWithdrawalIndex uint64

View File

@@ -17,6 +17,10 @@ func (b *BeaconState) LatestExecutionPayloadHeader() (interfaces.ExecutionData,
b.lock.RLock()
defer b.lock.RUnlock()
if b.version >= version.Gloas {
return blocks.WrappedExecutionPayloadHeaderGloas(b.latestExecutionPayloadHeaderGloas.Copy())
}
if b.version >= version.Deneb {
return blocks.WrappedExecutionPayloadHeaderDeneb(b.latestExecutionPayloadHeaderDeneb.Copy())
}

View File

@@ -43,6 +43,8 @@ func ComputeFieldRootsWithHasher(ctx context.Context, state *BeaconState) ([][]b
fieldRoots = make([][]byte, params.BeaconConfig().BeaconStateElectraFieldCount)
case version.Fulu:
fieldRoots = make([][]byte, params.BeaconConfig().BeaconStateFuluFieldCount)
case version.Gloas:
fieldRoots = make([][]byte, params.BeaconConfig().BeaconStateGloasFieldCount)
default:
return nil, fmt.Errorf("unknown state version %s", version.String(state.version))
}
@@ -245,7 +247,7 @@ func ComputeFieldRootsWithHasher(ctx context.Context, state *BeaconState) ([][]b
fieldRoots[types.LatestExecutionPayloadHeaderCapella.RealPosition()] = executionPayloadRoot[:]
}
if state.version >= version.Deneb {
if state.version >= version.Deneb && state.version < version.Gloas {
// Execution payload root.
executionPayloadRoot, err := state.latestExecutionPayloadHeaderDeneb.HashTreeRoot()
if err != nil {
@@ -254,6 +256,15 @@ func ComputeFieldRootsWithHasher(ctx context.Context, state *BeaconState) ([][]b
fieldRoots[types.LatestExecutionPayloadHeaderDeneb.RealPosition()] = executionPayloadRoot[:]
}
if state.version >= version.Gloas {
// Execution payload root.
executionPayloadRoot, err := state.latestExecutionPayloadHeaderGloas.HashTreeRoot()
if err != nil {
return nil, err
}
fieldRoots[types.LatestExecutionPayloadHeaderGloas.RealPosition()] = executionPayloadRoot[:]
}
if state.version >= version.Capella {
// Next withdrawal index root.
nextWithdrawalIndexRoot := make([]byte, 32)

View File

@@ -55,6 +55,17 @@ func (b *BeaconState) SetLatestExecutionPayloadHeader(val interfaces.ExecutionDa
b.latestExecutionPayloadHeaderDeneb = latest
b.markFieldAsDirty(types.LatestExecutionPayloadHeaderDeneb)
return nil
case *enginev1.ExecutionPayloadGloas:
if !(b.version >= version.Gloas) {
return fmt.Errorf("wrong state version (%s) for gloas execution payload", version.String(b.version))
}
latest, err := consensusblocks.PayloadToHeaderGloas(val)
if err != nil {
return errors.Wrap(err, "could not convert payload to header")
}
b.latestExecutionPayloadHeaderGloas = latest
b.markFieldAsDirty(types.LatestExecutionPayloadHeaderGloas)
return nil
case *enginev1.ExecutionPayloadHeader:
if b.version != version.Bellatrix {
return fmt.Errorf("wrong state version (%s) for bellatrix execution payload header", version.String(b.version))
@@ -76,6 +87,13 @@ func (b *BeaconState) SetLatestExecutionPayloadHeader(val interfaces.ExecutionDa
b.latestExecutionPayloadHeaderDeneb = header
b.markFieldAsDirty(types.LatestExecutionPayloadHeaderDeneb)
return nil
case *enginev1.ExecutionPayloadHeaderGloas:
if !(b.version >= version.Gloas) {
return fmt.Errorf("wrong state version (%s) for gloas execution payload header", version.String(b.version))
}
b.latestExecutionPayloadHeaderGloas = header
b.markFieldAsDirty(types.LatestExecutionPayloadHeaderGloas)
return nil
default:
return errors.New("value must be an execution payload header")
}

View File

@@ -112,6 +112,24 @@ var (
electraFields,
types.ProposerLookahead,
)
gloasFields = append(
altairFields,
types.LatestExecutionPayloadHeaderGloas,
types.NextWithdrawalIndex,
types.NextWithdrawalValidatorIndex,
types.HistoricalSummaries,
types.DepositRequestsStartIndex,
types.DepositBalanceToConsume,
types.ExitBalanceToConsume,
types.EarliestExitEpoch,
types.ConsolidationBalanceToConsume,
types.EarliestConsolidationEpoch,
types.PendingDeposits,
types.PendingPartialWithdrawals,
types.PendingConsolidations,
types.ProposerLookahead,
)
)
const (
@@ -122,6 +140,7 @@ const (
denebSharedFieldRefCount = 7
electraSharedFieldRefCount = 10
fuluSharedFieldRefCount = 11
gloasSharedFieldRefCount = 11
)
// InitializeFromProtoPhase0 the beacon state from a protobuf representation.
@@ -159,6 +178,11 @@ func InitializeFromProtoFulu(st *ethpb.BeaconStateFulu) (state.BeaconState, erro
return InitializeFromProtoUnsafeFulu(proto.Clone(st).(*ethpb.BeaconStateFulu))
}
// InitializeFromProtoGloas the beacon state from a protobuf representation.
func InitializeFromProtoGloas(st *ethpb.BeaconStateGloas) (state.BeaconState, error) {
return InitializeFromProtoUnsafeGloas(proto.Clone(st).(*ethpb.BeaconStateGloas))
}
// InitializeFromProtoUnsafePhase0 directly uses the beacon state protobuf fields
// and sets them as fields of the BeaconState type.
func InitializeFromProtoUnsafePhase0(st *ethpb.BeaconState) (state.BeaconState, error) {
@@ -736,6 +760,105 @@ func InitializeFromProtoUnsafeFulu(st *ethpb.BeaconStateFulu) (state.BeaconState
return b, nil
}
// InitializeFromProtoUnsafeGloas directly uses the beacon state protobuf fields
// and sets them as fields of the BeaconState type.
func InitializeFromProtoUnsafeGloas(st *ethpb.BeaconStateGloas) (state.BeaconState, error) {
if st == nil {
return nil, errors.New("received nil state")
}
hRoots := customtypes.HistoricalRoots(make([][32]byte, len(st.HistoricalRoots)))
for i, r := range st.HistoricalRoots {
hRoots[i] = bytesutil.ToBytes32(r)
}
proposerLookahead := make([]primitives.ValidatorIndex, len(st.ProposerLookahead))
for i, v := range st.ProposerLookahead {
proposerLookahead[i] = primitives.ValidatorIndex(v)
}
fieldCount := params.BeaconConfig().BeaconStateFuluFieldCount
b := &BeaconState{
version: version.Gloas,
genesisTime: st.GenesisTime,
genesisValidatorsRoot: bytesutil.ToBytes32(st.GenesisValidatorsRoot),
slot: st.Slot,
fork: st.Fork,
latestBlockHeader: st.LatestBlockHeader,
historicalRoots: hRoots,
eth1Data: st.Eth1Data,
eth1DataVotes: st.Eth1DataVotes,
eth1DepositIndex: st.Eth1DepositIndex,
slashings: st.Slashings,
previousEpochParticipation: st.PreviousEpochParticipation,
currentEpochParticipation: st.CurrentEpochParticipation,
justificationBits: st.JustificationBits,
previousJustifiedCheckpoint: st.PreviousJustifiedCheckpoint,
currentJustifiedCheckpoint: st.CurrentJustifiedCheckpoint,
finalizedCheckpoint: st.FinalizedCheckpoint,
currentSyncCommittee: st.CurrentSyncCommittee,
nextSyncCommittee: st.NextSyncCommittee,
latestExecutionPayloadHeaderGloas: st.LatestExecutionPayloadHeader,
nextWithdrawalIndex: st.NextWithdrawalIndex,
nextWithdrawalValidatorIndex: st.NextWithdrawalValidatorIndex,
historicalSummaries: st.HistoricalSummaries,
depositRequestsStartIndex: st.DepositRequestsStartIndex,
depositBalanceToConsume: st.DepositBalanceToConsume,
exitBalanceToConsume: st.ExitBalanceToConsume,
earliestExitEpoch: st.EarliestExitEpoch,
consolidationBalanceToConsume: st.ConsolidationBalanceToConsume,
earliestConsolidationEpoch: st.EarliestConsolidationEpoch,
pendingDeposits: st.PendingDeposits,
pendingPartialWithdrawals: st.PendingPartialWithdrawals,
pendingConsolidations: st.PendingConsolidations,
proposerLookahead: proposerLookahead,
id: types.Enumerator.Inc(),
dirtyFields: make(map[types.FieldIndex]bool, fieldCount),
dirtyIndices: make(map[types.FieldIndex][]uint64, fieldCount),
stateFieldLeaves: make(map[types.FieldIndex]*fieldtrie.FieldTrie, fieldCount),
rebuildTrie: make(map[types.FieldIndex]bool, fieldCount),
valMapHandler: stateutil.NewValMapHandler(st.Validators),
}
b.blockRootsMultiValue = NewMultiValueBlockRoots(st.BlockRoots)
b.stateRootsMultiValue = NewMultiValueStateRoots(st.StateRoots)
b.randaoMixesMultiValue = NewMultiValueRandaoMixes(st.RandaoMixes)
b.balancesMultiValue = NewMultiValueBalances(st.Balances)
b.validatorsMultiValue = NewMultiValueValidators(st.Validators)
b.inactivityScoresMultiValue = NewMultiValueInactivityScores(st.InactivityScores)
b.sharedFieldReferences = make(map[types.FieldIndex]*stateutil.Reference, gloasSharedFieldRefCount)
for _, f := range gloasFields {
b.dirtyFields[f] = true
b.rebuildTrie[f] = true
b.dirtyIndices[f] = []uint64{}
trie, err := fieldtrie.NewFieldTrie(f, types.BasicArray, nil, 0)
if err != nil {
return nil, err
}
b.stateFieldLeaves[f] = trie
}
// Initialize field reference tracking for shared data.
b.sharedFieldReferences[types.HistoricalRoots] = stateutil.NewRef(1)
b.sharedFieldReferences[types.Eth1DataVotes] = stateutil.NewRef(1)
b.sharedFieldReferences[types.Slashings] = stateutil.NewRef(1)
b.sharedFieldReferences[types.PreviousEpochParticipationBits] = stateutil.NewRef(1)
b.sharedFieldReferences[types.CurrentEpochParticipationBits] = stateutil.NewRef(1)
b.sharedFieldReferences[types.LatestExecutionPayloadHeaderGloas] = stateutil.NewRef(1) // New in Gloas.
b.sharedFieldReferences[types.HistoricalSummaries] = stateutil.NewRef(1)
b.sharedFieldReferences[types.PendingDeposits] = stateutil.NewRef(1)
b.sharedFieldReferences[types.PendingPartialWithdrawals] = stateutil.NewRef(1)
b.sharedFieldReferences[types.PendingConsolidations] = stateutil.NewRef(1)
b.sharedFieldReferences[types.ProposerLookahead] = stateutil.NewRef(1)
state.Count.Inc()
// Finalizer runs when dst is being destroyed in garbage collection.
runtime.SetFinalizer(b, finalizerCleanup)
return b, nil
}
// Copy returns a deep copy of the beacon state.
func (b *BeaconState) Copy() state.BeaconState {
b.lock.RLock()
@@ -757,6 +880,8 @@ func (b *BeaconState) Copy() state.BeaconState {
fieldCount = params.BeaconConfig().BeaconStateElectraFieldCount
case version.Fulu:
fieldCount = params.BeaconConfig().BeaconStateFuluFieldCount
case version.Gloas:
fieldCount = params.BeaconConfig().BeaconStateFuluFieldCount
}
dst := &BeaconState{
@@ -811,6 +936,7 @@ func (b *BeaconState) Copy() state.BeaconState {
latestExecutionPayloadHeader: b.latestExecutionPayloadHeader.Copy(),
latestExecutionPayloadHeaderCapella: b.latestExecutionPayloadHeaderCapella.Copy(),
latestExecutionPayloadHeaderDeneb: b.latestExecutionPayloadHeaderDeneb.Copy(),
latestExecutionPayloadHeaderGloas: b.latestExecutionPayloadHeaderGloas.Copy(),
id: types.Enumerator.Inc(),
@@ -847,6 +973,8 @@ func (b *BeaconState) Copy() state.BeaconState {
dst.sharedFieldReferences = make(map[types.FieldIndex]*stateutil.Reference, electraSharedFieldRefCount)
case version.Fulu:
dst.sharedFieldReferences = make(map[types.FieldIndex]*stateutil.Reference, fuluSharedFieldRefCount)
case version.Gloas:
dst.sharedFieldReferences = make(map[types.FieldIndex]*stateutil.Reference, gloasSharedFieldRefCount)
}
for field, ref := range b.sharedFieldReferences {
@@ -942,6 +1070,8 @@ func (b *BeaconState) initializeMerkleLayers(ctx context.Context) error {
b.dirtyFields = make(map[types.FieldIndex]bool, params.BeaconConfig().BeaconStateElectraFieldCount)
case version.Fulu:
b.dirtyFields = make(map[types.FieldIndex]bool, params.BeaconConfig().BeaconStateFuluFieldCount)
case version.Gloas:
b.dirtyFields = make(map[types.FieldIndex]bool, params.BeaconConfig().BeaconStateFuluFieldCount)
default:
return fmt.Errorf("unknown state version (%s) when computing dirty fields in merklization", version.String(b.version))
}
@@ -1154,6 +1284,8 @@ func (b *BeaconState) rootSelector(ctx context.Context, field types.FieldIndex)
return b.latestExecutionPayloadHeaderCapella.HashTreeRoot()
case types.LatestExecutionPayloadHeaderDeneb:
return b.latestExecutionPayloadHeaderDeneb.HashTreeRoot()
case types.LatestExecutionPayloadHeaderGloas:
return b.latestExecutionPayloadHeaderGloas.HashTreeRoot()
case types.NextWithdrawalIndex:
return ssz.Uint64Root(b.nextWithdrawalIndex), nil
case types.NextWithdrawalValidatorIndex:

View File

@@ -88,6 +88,8 @@ func (f FieldIndex) String() string {
return "latestExecutionPayloadHeaderCapella"
case LatestExecutionPayloadHeaderDeneb:
return "latestExecutionPayloadHeaderDeneb"
case LatestExecutionPayloadHeaderGloas:
return "latestExecutionPayloadHeaderGloas"
case NextWithdrawalIndex:
return "nextWithdrawalIndex"
case NextWithdrawalValidatorIndex:
@@ -171,7 +173,7 @@ func (f FieldIndex) RealPosition() int {
return 22
case NextSyncCommittee:
return 23
case LatestExecutionPayloadHeader, LatestExecutionPayloadHeaderCapella, LatestExecutionPayloadHeaderDeneb:
case LatestExecutionPayloadHeader, LatestExecutionPayloadHeaderCapella, LatestExecutionPayloadHeaderDeneb, LatestExecutionPayloadHeaderGloas:
return 24
case NextWithdrawalIndex:
return 25
@@ -251,6 +253,7 @@ const (
LatestExecutionPayloadHeader
LatestExecutionPayloadHeaderCapella
LatestExecutionPayloadHeaderDeneb
LatestExecutionPayloadHeaderGloas
NextWithdrawalIndex
NextWithdrawalValidatorIndex
HistoricalSummaries

View File

@@ -192,6 +192,13 @@ var (
},
)
dataColumnsRecoveredFromELTotal = promauto.NewCounter(
prometheus.CounterOpts{
Name: "data_columns_recovered_from_el_total",
Help: "Count the number of times data columns have been recovered from the execution layer.",
},
)
// Data column sidecar validation, beacon metrics specs
dataColumnSidecarVerificationRequestsCounter = promauto.NewCounter(prometheus.CounterOpts{
Name: "beacon_data_column_sidecar_processing_requests_total",

View File

@@ -224,6 +224,8 @@ func (s *Service) processDataColumnSidecarsFromExecution(ctx context.Context, so
}
if len(unseenIndices) > 0 {
dataColumnsRecoveredFromELTotal.Inc()
log.WithFields(logrus.Fields{
"root": fmt.Sprintf("%#x", source.Root()),
"slot": source.Slot(),

View File

@@ -0,0 +1,2 @@
### Changed
- Use the `by-epoch' blob storage layout by default and log a warning to users who continue to use the flat layout, encouraging them to switch.

View File

@@ -0,0 +1,2 @@
### Fixed
- Remove `Reading static P2P private key from a file.` log if Fulu is enabled.

View File

@@ -0,0 +1,3 @@
### Added
- Allow custom headers in validator client HTTP requests.

View File

@@ -0,0 +1,3 @@
### Added
- Metric to track data columns recovered from execution layer

View File

@@ -0,0 +1,3 @@
### Changed
- Updated consensus spec tests to v1.6.0-beta.1 with new hashes and URL template

View File

@@ -12,6 +12,7 @@ go_library(
"//config/params:go_default_library",
"//consensus-types/primitives:go_default_library",
"@com_github_pkg_errors//:go_default_library",
"@com_github_sirupsen_logrus//:go_default_library",
"@com_github_urfave_cli_v2//:go_default_library",
],
)
@@ -19,8 +20,10 @@ go_library(
go_test(
name = "go_default_test",
srcs = ["options_test.go"],
data = glob(["testdata/**"]),
embed = [":go_default_library"],
deps = [
"//beacon-chain/db/filesystem:go_default_library",
"//cmd:go_default_library",
"//config/params:go_default_library",
"//consensus-types/primitives:go_default_library",

View File

@@ -1,6 +1,8 @@
package storage
import (
"fmt"
"os"
"path"
"strings"
@@ -10,6 +12,7 @@ import (
"github.com/OffchainLabs/prysm/v6/config/params"
"github.com/OffchainLabs/prysm/v6/consensus-types/primitives"
"github.com/pkg/errors"
log "github.com/sirupsen/logrus"
"github.com/urfave/cli/v2"
)
@@ -25,9 +28,9 @@ var (
Aliases: []string{"extend-blob-retention-epoch"},
}
BlobStorageLayout = &cli.StringFlag{
Name: "blob-storage-layout",
Usage: layoutFlagUsage(),
Value: filesystem.LayoutNameFlat,
Name: "blob-storage-layout",
Usage: layoutFlagUsage(),
DefaultText: fmt.Sprintf("\"%s\", unless a different existing layout is detected", filesystem.LayoutNameByEpoch),
}
DataColumnStoragePathFlag = &cli.PathFlag{
Name: "data-column-path",
@@ -35,6 +38,14 @@ var (
}
)
// Flags is the list of CLI flags for configuring blob storage.
var Flags = []cli.Flag{
BlobStoragePathFlag,
BlobRetentionEpochFlag,
BlobStorageLayout,
DataColumnStoragePathFlag,
}
func layoutOptions() string {
return "available options are: " + strings.Join(filesystem.LayoutNames, ", ") + "."
}
@@ -62,10 +73,20 @@ func BeaconNodeOptions(c *cli.Context) ([]node.Option, error) {
return nil, errors.Wrap(err, "blob retention epoch")
}
blobPath := blobStoragePath(c)
layout, err := detectLayout(blobPath, c)
if err != nil {
return nil, errors.Wrap(err, "detecting blob storage layout")
}
if layout == filesystem.LayoutNameFlat {
log.Warnf("Existing '%s' blob storage layout detected. Consider setting the flag --%s=%s for faster startup and more reliable pruning. Setting this flag will automatically migrate your existing blob storage to the newer layout on the next restart.",
filesystem.LayoutNameFlat, BlobStorageLayout.Name, filesystem.LayoutNameByEpoch)
}
blobStorageOptions := node.WithBlobStorageOptions(
filesystem.WithBlobRetentionEpochs(blobRetentionEpoch),
filesystem.WithBasePath(blobStoragePath(c)),
filesystem.WithLayout(c.String(BlobStorageLayout.Name)), // This is validated in the Action func for BlobStorageLayout.
filesystem.WithBasePath(blobPath),
filesystem.WithLayout(layout), // This is validated in the Action func for BlobStorageLayout.
)
dataColumnRetentionEpoch, err := dataColumnRetentionEpoch(c)
@@ -82,6 +103,53 @@ func BeaconNodeOptions(c *cli.Context) ([]node.Option, error) {
return opts, nil
}
// stringFlagGetter makes testing detectLayout easier
// because we don't need to mess with FlagSets and cli types.
type stringFlagGetter interface {
String(name string) string
}
// detectLayout determines which layout to use based on explicit user flags or by probing the
// blob directory to determine the previously used layout.
// - explicit: If the user has specified a layout flag, that layout is returned.
// - flat: If directories that look like flat layout's block root paths are present.
// - by-epoch: default if neither of the above is true.
func detectLayout(dir string, c stringFlagGetter) (string, error) {
explicit := c.String(BlobStorageLayout.Name)
if explicit != "" {
return explicit, nil
}
dir = path.Clean(dir)
// nosec: this path is provided by the node operator via flag
base, err := os.Open(dir) // #nosec G304
if err != nil {
// 'blobs' directory does not exist yet, so default to by-epoch.
return filesystem.LayoutNameByEpoch, nil
}
defer func() {
if err := base.Close(); err != nil {
log.WithError(err).Errorf("Could not close blob storage directory")
}
}()
// When we go looking for existing by-root directories, we only need to find one directory
// but one of those directories could be the `by-epoch` layout's top-level directory,
// and it seems possible that on some platforms we could get extra system directories that I don't
// know how to anticipate (looking at you, Windows), so I picked 16 as a small number with a generous
// amount of wiggle room to be confident that we'll likely see a by-root director if one exists.
entries, err := base.Readdirnames(16)
if err != nil {
return "", errors.Wrap(err, "reading blob storage directory")
}
for _, entry := range entries {
if filesystem.IsBlockRootDir(entry) {
return filesystem.LayoutNameFlat, nil
}
}
return filesystem.LayoutNameByEpoch, nil
}
func blobStoragePath(c *cli.Context) string {
blobsPath := c.Path(BlobStoragePathFlag.Name)
if blobsPath == "" {

View File

@@ -3,8 +3,14 @@ package storage
import (
"flag"
"fmt"
"os"
"path"
"path/filepath"
"strings"
"syscall"
"testing"
"github.com/OffchainLabs/prysm/v6/beacon-chain/db/filesystem"
"github.com/OffchainLabs/prysm/v6/cmd"
"github.com/OffchainLabs/prysm/v6/config/params"
"github.com/OffchainLabs/prysm/v6/consensus-types/primitives"
@@ -109,3 +115,105 @@ func TestDataColumnStoragePath_FlagSpecified(t *testing.T) {
assert.Equal(t, "/blah/blah", storagePath)
}
type mockStringFlagGetter struct {
v string
}
func (m mockStringFlagGetter) String(name string) string {
return m.v
}
func TestDetectLayout(t *testing.T) {
fakeRoot := "0xabcdef1234567890abcdef1234567890abcdef1234567890abcdef1234567890"
require.Equal(t, true, filesystem.IsBlockRootDir(fakeRoot))
withFlatRoot := func(t *testing.T, dir string) {
require.NoError(t, os.MkdirAll(path.Join(dir, fakeRoot), 0o755))
}
withByEpoch := func(t *testing.T, dir string) {
require.NoError(t, os.MkdirAll(path.Join(dir, filesystem.PeriodicEpochBaseDir), 0o755))
}
cases := []struct {
name string
expected string
expectedErr error
setup func(t *testing.T, dir string)
getter mockStringFlagGetter
}{
{
name: "no blobs dir",
expected: filesystem.LayoutNameByEpoch,
},
{
name: "blobs dir without root dirs",
expected: filesystem.LayoutNameByEpoch,
// empty subdirectory under blobs which doesn't match the block root pattern
setup: func(t *testing.T, dir string) {
require.NoError(t, os.MkdirAll(path.Join(dir, "some-dir"), 0o755))
},
},
{
name: "blobs dir with root dir",
setup: withFlatRoot,
expected: filesystem.LayoutNameFlat,
},
{
name: "blobs dir with root dir overridden by flag",
setup: withFlatRoot,
expected: filesystem.LayoutNameByEpoch,
getter: mockStringFlagGetter{v: filesystem.LayoutNameByEpoch},
},
{
name: "only has by-epoch dir",
setup: withByEpoch,
expected: filesystem.LayoutNameByEpoch,
},
{
name: "contains by-epoch dir and root dirs",
setup: func(t *testing.T, dir string) {
withFlatRoot(t, dir)
withByEpoch(t, dir)
},
expected: filesystem.LayoutNameFlat,
},
{
name: "unreadable dir",
// It isn't detectLayout's job to detect any errors reading the directory,
// so it ignores errors from the os.Open call. But we can also get errors
// from readdirnames, but this is hard to simulate in a test. So in the test
// write a file in place of the dir, which will succeed in the Open call, but
// fail when read as a directory. This is why the expected error is syscall.ENOTDIR
// (syscall error code from using readdirnames syscall on an ordinary file).
setup: func(t *testing.T, dir string) {
parent := filepath.Dir(dir)
require.NoError(t, os.MkdirAll(parent, 0o755))
require.NoError(t, os.WriteFile(dir, []byte{}, 0o755))
},
expectedErr: syscall.ENOTDIR,
},
}
for _, tc := range cases {
t.Run(tc.name, func(t *testing.T) {
dir := strings.Replace(t.Name(), " ", "_", -1)
dir = path.Join(os.TempDir(), dir)
if tc.setup != nil {
tc.setup(t, dir)
}
if tc.expectedErr != nil {
t.Log("hi")
}
layout, err := detectLayout(dir, tc.getter)
if tc.expectedErr != nil {
require.ErrorIs(t, err, tc.expectedErr)
return
}
require.NoError(t, err)
require.Equal(t, tc.expected, layout)
assert.Equal(t, tc.expectedErr, err)
assert.Equal(t, tc.expected, layout)
})
}
}

View File

@@ -45,6 +45,13 @@ var (
Usage: "Beacon node REST API provider endpoint.",
Value: "http://127.0.0.1:3500",
}
// BeaconRESTApiHeaders defines a list of headers to send with all HTTP requests to the beacon node.
BeaconRESTApiHeaders = &cli.StringFlag{
Name: "beacon-rest-api-headers",
Usage: `Comma-separated list of key value pairs to pass as headers for all HTTP calls to the beacon node.
To provide multiple values for the same key, specify the same key for each value.
Example: --grpc-headers=key1=value1,key1=value2,key2=value3`,
}
// CertFlag defines a flag for the node's TLS certificate.
CertFlag = &cli.StringFlag{
Name: "tls-cert",

View File

@@ -51,6 +51,7 @@ func startNode(ctx *cli.Context) error {
var appFlags = []cli.Flag{
flags.BeaconRPCProviderFlag,
flags.BeaconRESTApiProviderFlag,
flags.BeaconRESTApiHeaders,
flags.CertFlag,
flags.GraffitiFlag,
flags.DisablePenaltyRewardLogFlag,

View File

@@ -93,6 +93,7 @@ var appHelpFlagGroups = []flagGroup{
Flags: []cli.Flag{
flags.CertFlag,
flags.BeaconRPCProviderFlag,
flags.BeaconRESTApiHeaders,
flags.EnableRPCFlag,
flags.RPCHost,
flags.RPCPort,

View File

@@ -128,6 +128,7 @@ var (
SaveFullExecutionPayloads = &cli.BoolFlag{
Name: "save-full-execution-payloads",
Usage: "Saves beacon blocks with full execution payloads instead of execution payload headers in the database.",
Value: true,
}
EnableBeaconRESTApi = &cli.BoolFlag{
Name: "enable-beacon-rest-api",

View File

@@ -156,6 +156,7 @@ type BeaconChainConfig struct {
BeaconStateDenebFieldCount int // BeaconStateDenebFieldCount defines how many fields are in beacon state post upgrade to Deneb.
BeaconStateElectraFieldCount int // BeaconStateElectraFieldCount defines how many fields are in beacon state post upgrade to Electra.
BeaconStateFuluFieldCount int // BeaconStateFuluFieldCount defines how many fields are in beacon state post upgrade to Fulu.
BeaconStateGloasFieldCount int // BeaconStateGloasFieldCount defines how many fields are in beacon state post upgrade to Gloas.
// Slasher constants.
WeakSubjectivityPeriod primitives.Epoch // WeakSubjectivityPeriod defines the time period expressed in number of epochs were proof of stake network should validate block headers and attestations for slashable events.
@@ -178,6 +179,8 @@ type BeaconChainConfig struct {
ElectraForkEpoch primitives.Epoch `yaml:"ELECTRA_FORK_EPOCH" spec:"true"` // ElectraForkEpoch is used to represent the assigned fork epoch for electra.
FuluForkVersion []byte `yaml:"FULU_FORK_VERSION" spec:"true"` // FuluForkVersion is used to represent the fork version for fulu.
FuluForkEpoch primitives.Epoch `yaml:"FULU_FORK_EPOCH" spec:"true"` // FuluForkEpoch is used to represent the assigned fork epoch for fulu.
GloasForkVersion []byte `yaml:"GLOAS_FORK_VERSION" spec:"true"` // GloasForkVersion is used to represent the fork version for gloas.
GloasForkEpoch primitives.Epoch `yaml:"GLOAS_FORK_EPOCH" spec:"true"` // GloasForkEpoch is used to represent the assigned fork epoch for gloas.
ForkVersionSchedule map[[fieldparams.VersionLength]byte]primitives.Epoch // Schedule of fork epochs by version.
ForkVersionNames map[[fieldparams.VersionLength]byte]string // Human-readable names of fork versions.
@@ -332,6 +335,7 @@ func (b *BeaconChainConfig) VersionToForkEpochMap() map[int]primitives.Epoch {
version.Deneb: b.DenebForkEpoch,
version.Electra: b.ElectraForkEpoch,
version.Fulu: b.FuluForkEpoch,
version.Gloas: b.GloasForkEpoch,
}
}
@@ -595,6 +599,7 @@ func initForkSchedule(b *BeaconChainConfig) *NetworkSchedule {
{Epoch: b.DenebForkEpoch, isFork: true, ForkVersion: to4(b.DenebForkVersion), MaxBlobsPerBlock: uint64(b.DeprecatedMaxBlobsPerBlock), VersionEnum: version.Deneb},
{Epoch: b.ElectraForkEpoch, isFork: true, ForkVersion: to4(b.ElectraForkVersion), MaxBlobsPerBlock: uint64(b.DeprecatedMaxBlobsPerBlockElectra), VersionEnum: version.Electra},
{Epoch: b.FuluForkEpoch, isFork: true, ForkVersion: to4(b.FuluForkVersion), VersionEnum: version.Fulu},
{Epoch: b.GloasForkEpoch, isFork: true, ForkVersion: to4(b.GloasForkVersion), VersionEnum: version.Gloas},
})
}
@@ -619,6 +624,7 @@ func configForkSchedule(b *BeaconChainConfig) map[[fieldparams.VersionLength]byt
fvs[bytesutil.ToBytes4(b.DenebForkVersion)] = b.DenebForkEpoch
fvs[bytesutil.ToBytes4(b.ElectraForkVersion)] = b.ElectraForkEpoch
fvs[bytesutil.ToBytes4(b.FuluForkVersion)] = b.FuluForkEpoch
fvs[bytesutil.ToBytes4(b.GloasForkVersion)] = b.GloasForkEpoch
return fvs
}
@@ -642,6 +648,7 @@ func ConfigForkVersions(b *BeaconChainConfig) map[[fieldparams.VersionLength]byt
bytesutil.ToBytes4(b.DenebForkVersion): version.Deneb,
bytesutil.ToBytes4(b.ElectraForkVersion): version.Electra,
bytesutil.ToBytes4(b.FuluForkVersion): version.Fulu,
bytesutil.ToBytes4(b.GloasForkVersion): version.Gloas,
}
}
@@ -720,6 +727,12 @@ func FuluEnabled() bool {
return BeaconConfig().FuluForkEpoch < math.MaxUint64
}
// GloasEnabled centralizes the check to determine if code paths that are specific to Gloas should be allowed to execute.
// This will make it easier to find call sites that do this kind of check and remove them post-gloas.
func GloasEnabled() bool {
return BeaconConfig().GloasForkEpoch < math.MaxUint64
}
// WithinDAPeriod checks if the block epoch is within the data availability retention period.
func WithinDAPeriod(block, current primitives.Epoch) bool {
if block >= BeaconConfig().FuluForkEpoch {

View File

@@ -13,6 +13,7 @@ func InteropConfig() *BeaconChainConfig {
c.DenebForkVersion = []byte{4, 0, 0, 235}
c.ElectraForkVersion = []byte{5, 0, 0, 235}
c.FuluForkVersion = []byte{6, 0, 0, 235}
c.GloasForkVersion = []byte{7, 0, 0, 235}
c.InitializeForkSchedule()
return c

View File

@@ -31,6 +31,8 @@ const (
mainnetElectraForkEpoch = 364032 // May 7, 2025, 10:05:11 UTC
// Fulu Fork Epoch for mainnet config
mainnetFuluForkEpoch = math.MaxUint64 // Far future / to be defined
// Gloas Fork Epoch for mainnet config
mainnetGloasForkEpoch = math.MaxUint64 // Far future / to be defined
)
var mainnetNetworkConfig = &NetworkConfig{
@@ -197,6 +199,7 @@ var mainnetBeaconConfig = &BeaconChainConfig{
BeaconStateDenebFieldCount: 28,
BeaconStateElectraFieldCount: 37,
BeaconStateFuluFieldCount: 38,
BeaconStateGloasFieldCount: 38,
// Slasher related values.
WeakSubjectivityPeriod: 54000,
@@ -221,6 +224,8 @@ var mainnetBeaconConfig = &BeaconChainConfig{
ElectraForkEpoch: mainnetElectraForkEpoch,
FuluForkVersion: []byte{6, 0, 0, 0},
FuluForkEpoch: mainnetFuluForkEpoch,
GloasForkVersion: []byte{7, 0, 0, 0},
GloasForkEpoch: mainnetGloasForkEpoch,
// New values introduced in Altair hard fork 1.
// Participation flag indices.
@@ -361,6 +366,7 @@ func FillTestVersions(c *BeaconChainConfig, b byte) {
c.DenebForkVersion = make([]byte, fieldparams.VersionLength)
c.ElectraForkVersion = make([]byte, fieldparams.VersionLength)
c.FuluForkVersion = make([]byte, fieldparams.VersionLength)
c.GloasForkVersion = make([]byte, fieldparams.VersionLength)
c.GenesisForkVersion[fieldparams.VersionLength-1] = b
c.AltairForkVersion[fieldparams.VersionLength-1] = b
@@ -369,6 +375,7 @@ func FillTestVersions(c *BeaconChainConfig, b byte) {
c.DenebForkVersion[fieldparams.VersionLength-1] = b
c.ElectraForkVersion[fieldparams.VersionLength-1] = b
c.FuluForkVersion[fieldparams.VersionLength-1] = b
c.GloasForkVersion[fieldparams.VersionLength-1] = b
c.GenesisForkVersion[0] = 0
c.AltairForkVersion[0] = 1
@@ -377,4 +384,5 @@ func FillTestVersions(c *BeaconChainConfig, b byte) {
c.DenebForkVersion[0] = 4
c.ElectraForkVersion[0] = 5
c.FuluForkVersion[0] = 6
c.GloasForkVersion[0] = 7
}

View File

@@ -97,6 +97,8 @@ func MinimalSpecConfig() *BeaconChainConfig {
minimalConfig.ElectraForkEpoch = math.MaxUint64
minimalConfig.FuluForkVersion = []byte{6, 0, 0, 1}
minimalConfig.FuluForkEpoch = math.MaxUint64
minimalConfig.GloasForkVersion = []byte{7, 0, 0, 1}
minimalConfig.GloasForkEpoch = math.MaxUint64
minimalConfig.SyncCommitteeSize = 32
minimalConfig.InactivityScoreBias = 4

View File

@@ -9,6 +9,7 @@ const (
DenebE2EForkEpoch = 12
ElectraE2EForkEpoch = 14
FuluE2EForkEpoch = math.MaxUint64
GloasE2EForkEpoch = math.MaxUint64
)
// E2ETestConfig retrieves the configurations made specifically for E2E testing.
@@ -46,6 +47,7 @@ func E2ETestConfig() *BeaconChainConfig {
e2eConfig.DenebForkEpoch = DenebE2EForkEpoch
e2eConfig.ElectraForkEpoch = ElectraE2EForkEpoch
e2eConfig.FuluForkEpoch = FuluE2EForkEpoch
e2eConfig.GloasForkEpoch = GloasE2EForkEpoch
// Terminal Total Difficulty.
e2eConfig.TerminalTotalDifficulty = "480"
@@ -59,6 +61,7 @@ func E2ETestConfig() *BeaconChainConfig {
e2eConfig.DenebForkVersion = []byte{4, 0, 0, 253}
e2eConfig.ElectraForkVersion = []byte{5, 0, 0, 253}
e2eConfig.FuluForkVersion = []byte{6, 0, 0, 253}
e2eConfig.GloasForkVersion = []byte{7, 0, 0, 253}
e2eConfig.BlobSchedule = []BlobScheduleEntry{
{Epoch: 12, MaxBlobsPerBlock: 6},
@@ -97,6 +100,7 @@ func E2EMainnetTestConfig() *BeaconChainConfig {
e2eConfig.DenebForkEpoch = DenebE2EForkEpoch
e2eConfig.ElectraForkEpoch = ElectraE2EForkEpoch
e2eConfig.FuluForkEpoch = FuluE2EForkEpoch
e2eConfig.GloasForkEpoch = GloasE2EForkEpoch
// Terminal Total Difficulty.
e2eConfig.TerminalTotalDifficulty = "480"
@@ -110,6 +114,7 @@ func E2EMainnetTestConfig() *BeaconChainConfig {
e2eConfig.DenebForkVersion = []byte{4, 0, 0, 254}
e2eConfig.ElectraForkVersion = []byte{5, 0, 0, 254}
e2eConfig.FuluForkVersion = []byte{6, 0, 0, 254}
e2eConfig.GloasForkVersion = []byte{7, 0, 0, 254}
// Deneb changes.
e2eConfig.MinPerEpochChurnLimit = 2

View File

@@ -1,5 +1,7 @@
package params
import "math"
// UseHoleskyNetworkConfig uses the Holesky beacon chain specific network config.
func UseHoleskyNetworkConfig() {
cfg := BeaconNetworkConfig().Copy()
@@ -41,6 +43,8 @@ func HoleskyConfig() *BeaconChainConfig {
cfg.ElectraForkVersion = []byte{0x06, 0x1, 0x70, 0x0}
cfg.FuluForkEpoch = 165120 // 2025-10-01 08:48:00 UTC
cfg.FuluForkVersion = []byte{0x07, 0x1, 0x70, 0x0}
cfg.GloasForkEpoch = math.MaxUint64
cfg.GloasForkVersion = []byte{0x08, 0x1, 0x70, 0x0} // TODO: Define holesky fork version for gloas. This is a placeholder value.
cfg.TerminalTotalDifficulty = "0"
cfg.DepositContractAddress = "0x4242424242424242424242424242424242424242"
cfg.EjectionBalance = 28000000000

View File

@@ -1,5 +1,7 @@
package params
import "math"
// UseHoodiNetworkConfig uses the Hoodi beacon chain specific network config.
func UseHoodiNetworkConfig() {
cfg := BeaconNetworkConfig().Copy()
@@ -47,6 +49,8 @@ func HoodiConfig() *BeaconChainConfig {
cfg.ElectraForkVersion = []byte{0x60, 0x00, 0x09, 0x10}
cfg.FuluForkEpoch = 50688 // 2025-10-28 18:53:12 UTC
cfg.FuluForkVersion = []byte{0x70, 0x00, 0x09, 0x10}
cfg.GloasForkEpoch = math.MaxUint64
cfg.GloasForkVersion = []byte{0x80, 0x00, 0x09, 0x10}
cfg.TerminalTotalDifficulty = "0"
cfg.DepositContractAddress = "0x00000000219ab540356cBB839Cbe05303d7705Fa"
cfg.BlobSchedule = []BlobScheduleEntry{

View File

@@ -1,6 +1,8 @@
package params
import (
"math"
eth1Params "github.com/ethereum/go-ethereum/params"
)
@@ -46,6 +48,8 @@ func SepoliaConfig() *BeaconChainConfig {
cfg.ElectraForkVersion = []byte{0x90, 0x00, 0x00, 0x74}
cfg.FuluForkEpoch = 272640 // 2025-10-14 07:36:00 UTC
cfg.FuluForkVersion = []byte{0x90, 0x00, 0x00, 0x75}
cfg.GloasForkEpoch = math.MaxUint64
cfg.GloasForkVersion = []byte{0x90, 0x00, 0x00, 0x76} // TODO: Define sepolia fork version for gloas. This is a placeholder value.
cfg.TerminalTotalDifficulty = "17000000000000000"
cfg.DepositContractAddress = "0x7f02C3E3c98b133055B8B348B2Ac625669Ed295D"
cfg.DefaultBuilderGasLimit = uint64(60000000)

View File

@@ -37,6 +37,10 @@ func NewWrappedExecutionData(v proto.Message) (interfaces.ExecutionData, error)
return WrappedExecutionPayloadDeneb(pbStruct)
case *enginev1.ExecutionPayloadDenebWithValueAndBlobsBundle:
return WrappedExecutionPayloadDeneb(pbStruct.Payload)
case *enginev1.ExecutionPayloadGloas:
return WrappedExecutionPayloadGloas(pbStruct)
case *enginev1.ExecutionPayloadHeaderGloas:
return WrappedExecutionPayloadHeaderGloas(pbStruct)
case *enginev1.ExecutionBundleElectra:
// note: no payload changes in electra so using deneb
return WrappedExecutionPayloadDeneb(pbStruct.Payload)
@@ -48,6 +52,8 @@ func NewWrappedExecutionData(v proto.Message) (interfaces.ExecutionData, error)
return WrappedExecutionPayloadHeaderCapella(pbStruct)
case *enginev1.ExecutionPayloadHeaderDeneb:
return WrappedExecutionPayloadHeaderDeneb(pbStruct)
case *enginev1.ExecutionBundleGloas:
return WrappedExecutionPayloadGloas(pbStruct.Payload)
default:
return nil, errors.Wrapf(ErrUnsupportedVersion, "type %T", pbStruct)
}
@@ -792,6 +798,59 @@ func PayloadToHeaderDeneb(payload interfaces.ExecutionData) (*enginev1.Execution
}, nil
}
// PayloadToHeaderGloas converts `payload` into execution payload header format.
func PayloadToHeaderGloas(payload interfaces.ExecutionData) (*enginev1.ExecutionPayloadHeaderGloas, error) {
txs, err := payload.Transactions()
if err != nil {
return nil, err
}
txRoot, err := ssz.TransactionsRoot(txs)
if err != nil {
return nil, err
}
withdrawals, err := payload.Withdrawals()
if err != nil {
return nil, err
}
withdrawalsRoot, err := ssz.WithdrawalSliceRoot(withdrawals, fieldparams.MaxWithdrawalsPerPayload)
if err != nil {
return nil, err
}
blobGasUsed, err := payload.BlobGasUsed()
if err != nil {
return nil, err
}
excessBlobGas, err := payload.ExcessBlobGas()
if err != nil {
return nil, err
}
// For Gloas, we need to compute the BlockAccessListRoot
// This will need to be implemented once we have access to the BlockAccessList field
var blockAccessListRoot [32]byte
return &enginev1.ExecutionPayloadHeaderGloas{
ParentHash: bytesutil.SafeCopyBytes(payload.ParentHash()),
FeeRecipient: bytesutil.SafeCopyBytes(payload.FeeRecipient()),
StateRoot: bytesutil.SafeCopyBytes(payload.StateRoot()),
ReceiptsRoot: bytesutil.SafeCopyBytes(payload.ReceiptsRoot()),
LogsBloom: bytesutil.SafeCopyBytes(payload.LogsBloom()),
PrevRandao: bytesutil.SafeCopyBytes(payload.PrevRandao()),
BlockNumber: payload.BlockNumber(),
GasLimit: payload.GasLimit(),
GasUsed: payload.GasUsed(),
Timestamp: payload.Timestamp(),
ExtraData: bytesutil.SafeCopyBytes(payload.ExtraData()),
BaseFeePerGas: bytesutil.SafeCopyBytes(payload.BaseFeePerGas()),
BlockHash: bytesutil.SafeCopyBytes(payload.BlockHash()),
TransactionsRoot: txRoot[:],
WithdrawalsRoot: withdrawalsRoot[:],
BlobGasUsed: blobGasUsed,
ExcessBlobGas: excessBlobGas,
BlockAccessListRoot: blockAccessListRoot[:],
}, nil
}
var (
PayloadToHeaderElectra = PayloadToHeaderDeneb
PayloadToHeaderFulu = PayloadToHeaderDeneb
@@ -1170,3 +1229,317 @@ func (e executionPayloadDeneb) ExcessBlobGas() (uint64, error) {
func (e executionPayloadDeneb) IsBlinded() bool {
return false
}
// executionPayloadGloas is a convenience wrapper around a beacon block body's execution payload data structure
// This wrapper allows us to conform to a common interface so that beacon
// blocks for future forks can also be applied across Prysm without issues.
type executionPayloadGloas struct {
p *enginev1.ExecutionPayloadGloas
}
var _ interfaces.ExecutionData = &executionPayloadGloas{}
// WrappedExecutionPayloadGloas is a constructor which wraps a protobuf execution payload into an interface.
func WrappedExecutionPayloadGloas(p *enginev1.ExecutionPayloadGloas) (interfaces.ExecutionData, error) {
w := executionPayloadGloas{p: p}
if w.IsNil() {
return nil, consensus_types.ErrNilObjectWrapped
}
return w, nil
}
// IsNil checks if the underlying data is nil.
func (e executionPayloadGloas) IsNil() bool {
return e.p == nil
}
// MarshalSSZ --
func (e executionPayloadGloas) MarshalSSZ() ([]byte, error) {
return e.p.MarshalSSZ()
}
// MarshalSSZTo --
func (e executionPayloadGloas) MarshalSSZTo(dst []byte) ([]byte, error) {
return e.p.MarshalSSZTo(dst)
}
// SizeSSZ --
func (e executionPayloadGloas) SizeSSZ() int {
return e.p.SizeSSZ()
}
// UnmarshalSSZ --
func (e executionPayloadGloas) UnmarshalSSZ(buf []byte) error {
return e.p.UnmarshalSSZ(buf)
}
// HashTreeRoot --
func (e executionPayloadGloas) HashTreeRoot() ([32]byte, error) {
return e.p.HashTreeRoot()
}
// HashTreeRootWith --
func (e executionPayloadGloas) HashTreeRootWith(hh *fastssz.Hasher) error {
return e.p.HashTreeRootWith(hh)
}
// Proto --
func (e executionPayloadGloas) Proto() proto.Message {
return e.p
}
// ParentHash --
func (e executionPayloadGloas) ParentHash() []byte {
return e.p.ParentHash
}
// FeeRecipient --
func (e executionPayloadGloas) FeeRecipient() []byte {
return e.p.FeeRecipient
}
// StateRoot --
func (e executionPayloadGloas) StateRoot() []byte {
return e.p.StateRoot
}
// ReceiptsRoot --
func (e executionPayloadGloas) ReceiptsRoot() []byte {
return e.p.ReceiptsRoot
}
// LogsBloom --
func (e executionPayloadGloas) LogsBloom() []byte {
return e.p.LogsBloom
}
// PrevRandao --
func (e executionPayloadGloas) PrevRandao() []byte {
return e.p.PrevRandao
}
// BlockNumber --
func (e executionPayloadGloas) BlockNumber() uint64 {
return e.p.BlockNumber
}
// GasLimit --
func (e executionPayloadGloas) GasLimit() uint64 {
return e.p.GasLimit
}
// GasUsed --
func (e executionPayloadGloas) GasUsed() uint64 {
return e.p.GasUsed
}
// Timestamp --
func (e executionPayloadGloas) Timestamp() uint64 {
return e.p.Timestamp
}
// ExtraData --
func (e executionPayloadGloas) ExtraData() []byte {
return e.p.ExtraData
}
// BaseFeePerGas --
func (e executionPayloadGloas) BaseFeePerGas() []byte {
return e.p.BaseFeePerGas
}
// BlockHash --
func (e executionPayloadGloas) BlockHash() []byte {
return e.p.BlockHash
}
// Transactions --
func (e executionPayloadGloas) Transactions() ([][]byte, error) {
return e.p.Transactions, nil
}
// TransactionsRoot --
func (e executionPayloadGloas) TransactionsRoot() ([]byte, error) {
return nil, consensus_types.ErrUnsupportedField
}
// Withdrawals --
func (e executionPayloadGloas) Withdrawals() ([]*enginev1.Withdrawal, error) {
return e.p.Withdrawals, nil
}
// WithdrawalsRoot --
func (e executionPayloadGloas) WithdrawalsRoot() ([]byte, error) {
return nil, consensus_types.ErrUnsupportedField
}
func (e executionPayloadGloas) BlobGasUsed() (uint64, error) {
return e.p.BlobGasUsed, nil
}
func (e executionPayloadGloas) ExcessBlobGas() (uint64, error) {
return e.p.ExcessBlobGas, nil
}
// IsBlinded returns true if the underlying data is blinded.
func (e executionPayloadGloas) IsBlinded() bool {
return false
}
// executionPayloadHeaderGloas is a convenience wrapper around a blinded beacon block body's execution header data structure.
// This wrapper allows us to conform to a common interface so that beacon
// blocks for future forks can also be applied across Prysm without issues.
type executionPayloadHeaderGloas struct {
p *enginev1.ExecutionPayloadHeaderGloas
}
var _ interfaces.ExecutionData = &executionPayloadHeaderGloas{}
// WrappedExecutionPayloadHeaderGloas is a constructor which wraps a protobuf execution header into an interface.
func WrappedExecutionPayloadHeaderGloas(p *enginev1.ExecutionPayloadHeaderGloas) (interfaces.ExecutionData, error) {
w := executionPayloadHeaderGloas{p: p}
if w.IsNil() {
return nil, consensus_types.ErrNilObjectWrapped
}
return w, nil
}
// IsNil checks if the underlying data is nil.
func (e executionPayloadHeaderGloas) IsNil() bool {
return e.p == nil
}
// MarshalSSZ --
func (e executionPayloadHeaderGloas) MarshalSSZ() ([]byte, error) {
return e.p.MarshalSSZ()
}
// MarshalSSZTo --
func (e executionPayloadHeaderGloas) MarshalSSZTo(dst []byte) ([]byte, error) {
return e.p.MarshalSSZTo(dst)
}
// SizeSSZ --
func (e executionPayloadHeaderGloas) SizeSSZ() int {
return e.p.SizeSSZ()
}
// UnmarshalSSZ --
func (e executionPayloadHeaderGloas) UnmarshalSSZ(buf []byte) error {
return e.p.UnmarshalSSZ(buf)
}
// HashTreeRoot --
func (e executionPayloadHeaderGloas) HashTreeRoot() ([32]byte, error) {
return e.p.HashTreeRoot()
}
// HashTreeRootWith --
func (e executionPayloadHeaderGloas) HashTreeRootWith(hh *fastssz.Hasher) error {
return e.p.HashTreeRootWith(hh)
}
// Proto --
func (e executionPayloadHeaderGloas) Proto() proto.Message {
return e.p
}
// ParentHash --
func (e executionPayloadHeaderGloas) ParentHash() []byte {
return e.p.ParentHash
}
// FeeRecipient --
func (e executionPayloadHeaderGloas) FeeRecipient() []byte {
return e.p.FeeRecipient
}
// StateRoot --
func (e executionPayloadHeaderGloas) StateRoot() []byte {
return e.p.StateRoot
}
// ReceiptsRoot --
func (e executionPayloadHeaderGloas) ReceiptsRoot() []byte {
return e.p.ReceiptsRoot
}
// LogsBloom --
func (e executionPayloadHeaderGloas) LogsBloom() []byte {
return e.p.LogsBloom
}
// PrevRandao --
func (e executionPayloadHeaderGloas) PrevRandao() []byte {
return e.p.PrevRandao
}
// BlockNumber --
func (e executionPayloadHeaderGloas) BlockNumber() uint64 {
return e.p.BlockNumber
}
// GasLimit --
func (e executionPayloadHeaderGloas) GasLimit() uint64 {
return e.p.GasLimit
}
// GasUsed --
func (e executionPayloadHeaderGloas) GasUsed() uint64 {
return e.p.GasUsed
}
// Timestamp --
func (e executionPayloadHeaderGloas) Timestamp() uint64 {
return e.p.Timestamp
}
// ExtraData --
func (e executionPayloadHeaderGloas) ExtraData() []byte {
return e.p.ExtraData
}
// BaseFeePerGas --
func (e executionPayloadHeaderGloas) BaseFeePerGas() []byte {
return e.p.BaseFeePerGas
}
// BlockHash --
func (e executionPayloadHeaderGloas) BlockHash() []byte {
return e.p.BlockHash
}
// Transactions --
func (executionPayloadHeaderGloas) Transactions() ([][]byte, error) {
return nil, consensus_types.ErrUnsupportedField
}
// TransactionsRoot --
func (e executionPayloadHeaderGloas) TransactionsRoot() ([]byte, error) {
return e.p.TransactionsRoot, nil
}
// Withdrawals --
func (e executionPayloadHeaderGloas) Withdrawals() ([]*enginev1.Withdrawal, error) {
return nil, consensus_types.ErrUnsupportedField
}
// WithdrawalsRoot --
func (e executionPayloadHeaderGloas) WithdrawalsRoot() ([]byte, error) {
return e.p.WithdrawalsRoot, nil
}
// BlobGasUsed --
func (e executionPayloadHeaderGloas) BlobGasUsed() (uint64, error) {
return e.p.BlobGasUsed, nil
}
// ExcessBlobGas --
func (e executionPayloadHeaderGloas) ExcessBlobGas() (uint64, error) {
return e.p.ExcessBlobGas, nil
}
// IsBlinded returns true if the underlying data is blinded.
func (e executionPayloadHeaderGloas) IsBlinded() bool {
return true
}

View File

@@ -82,6 +82,10 @@ func NewSignedBeaconBlock(i interface{}) (interfaces.SignedBeaconBlock, error) {
return initBlindedSignedBlockFromProtoFulu(b)
case *eth.GenericSignedBeaconBlock_BlindedFulu:
return initBlindedSignedBlockFromProtoFulu(b.BlindedFulu)
case *eth.GenericSignedBeaconBlock_Gloas:
return initSignedBlockFromProtoGloas(b.Gloas.Block)
case *eth.SignedBeaconBlockGloas:
return initSignedBlockFromProtoGloas(b)
default:
return nil, errors.Wrapf(ErrUnsupportedSignedBeaconBlock, "unable to create block from type %T", i)
}
@@ -138,6 +142,10 @@ func NewBeaconBlock(i interface{}) (interfaces.ReadOnlyBeaconBlock, error) {
return initBlindedBlockFromProtoFulu(b)
case *eth.GenericBeaconBlock_BlindedFulu:
return initBlindedBlockFromProtoFulu(b.BlindedFulu)
case *eth.GenericBeaconBlock_Gloas:
return initBlockFromProtoGloas(b.Gloas.Block)
case *eth.BeaconBlockGloas:
return initBlockFromProtoGloas(b)
default:
return nil, errors.Wrapf(errUnsupportedBeaconBlock, "unable to create block from type %T", i)
}
@@ -260,6 +268,19 @@ func BuildSignedBeaconBlock(blk interfaces.ReadOnlyBeaconBlock, signature []byte
return nil, errIncorrectBlockVersion
}
return NewSignedBeaconBlock(&eth.SignedBeaconBlockFulu{Block: pb, Signature: signature})
case version.Gloas:
if blk.IsBlinded() {
pb, ok := pb.(*eth.BlindedBeaconBlockFulu)
if !ok {
return nil, errIncorrectBlockVersion
}
return NewSignedBeaconBlock(&eth.SignedBlindedBeaconBlockFulu{Message: pb, Signature: signature})
}
pb, ok := pb.(*eth.BeaconBlockGloas)
if !ok {
return nil, errIncorrectBlockVersion
}
return NewSignedBeaconBlock(&eth.SignedBeaconBlockGloas{Block: pb, Signature: signature})
default:
return nil, errUnsupportedBeaconBlock
}
@@ -273,6 +294,8 @@ func getWrappedPayload(payload interface{}) (wrappedPayload interfaces.Execution
wrappedPayload, wrapErr = WrappedExecutionPayloadCapella(p)
case *enginev1.ExecutionPayloadDeneb:
wrappedPayload, wrapErr = WrappedExecutionPayloadDeneb(p)
case *enginev1.ExecutionPayloadGloas:
wrappedPayload, wrapErr = WrappedExecutionPayloadGloas(p)
default:
wrappedPayload, wrapErr = nil, fmt.Errorf("%T is not a type of execution payload", p)
}
@@ -629,6 +652,90 @@ func BuildSignedBeaconBlockFromExecutionPayload(blk interfaces.ReadOnlySignedBea
},
Signature: sig[:],
}
case version.Gloas:
p, ok := payload.(*enginev1.ExecutionPayloadGloas)
if !ok {
return nil, fmt.Errorf("payload has wrong type (expected %T, got %T)", &enginev1.ExecutionPayloadGloas{}, payload)
}
blsToExecutionChanges, err := b.Body().BLSToExecutionChanges()
if err != nil {
return nil, err
}
commitments, err := b.Body().BlobKzgCommitments()
if err != nil {
return nil, err
}
var atts []*eth.AttestationElectra
if b.Body().Attestations() != nil {
atts = make([]*eth.AttestationElectra, len(b.Body().Attestations()))
for i, att := range b.Body().Attestations() {
a, ok := att.(*eth.AttestationElectra)
if !ok {
return nil, fmt.Errorf("attestation has wrong type (expected %T, got %T)", &eth.AttestationElectra{}, att)
}
atts[i] = a
}
}
var attSlashings []*eth.AttesterSlashingElectra
if b.Body().AttesterSlashings() != nil {
attSlashings = make([]*eth.AttesterSlashingElectra, len(b.Body().AttesterSlashings()))
for i, slashing := range b.Body().AttesterSlashings() {
s, ok := slashing.(*eth.AttesterSlashingElectra)
if !ok {
return nil, fmt.Errorf("attester slashing has wrong type (expected %T, got %T)", &eth.AttesterSlashingElectra{}, slashing)
}
attSlashings[i] = s
}
}
er, err := b.Body().ExecutionRequests()
if err != nil {
return nil, err
}
fullBlock = &eth.SignedBeaconBlockGloas{
Block: &eth.BeaconBlockGloas{
Slot: b.Slot(),
ProposerIndex: b.ProposerIndex(),
ParentRoot: parentRoot[:],
StateRoot: stateRoot[:],
Body: &eth.BeaconBlockBodyGloas{
RandaoReveal: randaoReveal[:],
Eth1Data: b.Body().Eth1Data(),
Graffiti: graffiti[:],
ProposerSlashings: b.Body().ProposerSlashings(),
AttesterSlashings: attSlashings,
Attestations: atts,
Deposits: b.Body().Deposits(),
VoluntaryExits: b.Body().VoluntaryExits(),
SyncAggregate: syncAgg,
ExecutionPayload: &enginev1.ExecutionPayloadGloas{
ParentHash: p.ParentHash,
FeeRecipient: p.FeeRecipient,
StateRoot: p.StateRoot,
ReceiptsRoot: p.ReceiptsRoot,
LogsBloom: p.LogsBloom,
PrevRandao: p.PrevRandao,
BlockNumber: p.BlockNumber,
GasLimit: p.GasLimit,
GasUsed: p.GasUsed,
Timestamp: p.Timestamp,
ExtraData: p.ExtraData,
BaseFeePerGas: p.BaseFeePerGas,
BlockHash: p.BlockHash,
Transactions: p.Transactions,
Withdrawals: p.Withdrawals,
BlobGasUsed: p.BlobGasUsed,
ExcessBlobGas: p.ExcessBlobGas,
BlockAccessList: p.BlockAccessList,
},
BlsToExecutionChanges: blsToExecutionChanges,
BlobKzgCommitments: commitments,
ExecutionRequests: er,
},
},
Signature: sig[:],
}
default:
return nil, errors.New("Block not of known type")
}

View File

@@ -80,6 +80,8 @@ func (b *SignedBeaconBlock) Copy() (interfaces.SignedBeaconBlock, error) {
return initBlindedSignedBlockFromProtoFulu(pb.(*eth.SignedBlindedBeaconBlockFulu).Copy())
}
return initSignedBlockFromProtoFulu(pb.(*eth.SignedBeaconBlockFulu).Copy())
case version.Gloas:
return initSignedBlockFromProtoGloas(pb.(*eth.SignedBeaconBlockGloas).Copy())
default:
return nil, errIncorrectBlockVersion
}
@@ -157,6 +159,14 @@ func (b *SignedBeaconBlock) PbGenericBlock() (*eth.GenericSignedBeaconBlock, err
return &eth.GenericSignedBeaconBlock{
Block: &eth.GenericSignedBeaconBlock_Fulu{Fulu: bc},
}, nil
case version.Gloas:
bc, ok := pb.(*eth.SignedBeaconBlockContentsGloas)
if !ok {
return nil, fmt.Errorf("PbGenericBlock() only supports block content type but got %T", pb)
}
return &eth.GenericSignedBeaconBlock{
Block: &eth.GenericSignedBeaconBlock_Gloas{Gloas: bc},
}, nil
default:
return nil, errIncorrectBlockVersion
}
@@ -336,6 +346,57 @@ func (b *SignedBeaconBlock) ToBlinded() (interfaces.ReadOnlySignedBeaconBlock, e
},
Signature: b.signature[:],
})
case *enginev1.ExecutionPayloadGloas:
header, err := PayloadToHeaderGloas(payload)
if err != nil {
return nil, errors.Wrap(err, "payload to header gloas")
}
// Convert ExecutionPayloadHeaderGloas to ExecutionPayloadHeaderDeneb for compatibility
// TODO: Create proper Gloas blinded block types
denebHeader := &enginev1.ExecutionPayloadHeaderDeneb{
ParentHash: header.ParentHash,
FeeRecipient: header.FeeRecipient,
StateRoot: header.StateRoot,
ReceiptsRoot: header.ReceiptsRoot,
LogsBloom: header.LogsBloom,
PrevRandao: header.PrevRandao,
BlockNumber: header.BlockNumber,
GasLimit: header.GasLimit,
GasUsed: header.GasUsed,
Timestamp: header.Timestamp,
ExtraData: header.ExtraData,
BaseFeePerGas: header.BaseFeePerGas,
BlockHash: header.BlockHash,
TransactionsRoot: header.TransactionsRoot,
WithdrawalsRoot: header.WithdrawalsRoot,
BlobGasUsed: header.BlobGasUsed,
ExcessBlobGas: header.ExcessBlobGas,
}
return initBlindedSignedBlockFromProtoFulu(
&eth.SignedBlindedBeaconBlockFulu{
Message: &eth.BlindedBeaconBlockFulu{
Slot: b.block.slot,
ProposerIndex: b.block.proposerIndex,
ParentRoot: b.block.parentRoot[:],
StateRoot: b.block.stateRoot[:],
Body: &eth.BlindedBeaconBlockBodyElectra{
RandaoReveal: b.block.body.randaoReveal[:],
Eth1Data: b.block.body.eth1Data,
Graffiti: b.block.body.graffiti[:],
ProposerSlashings: b.block.body.proposerSlashings,
AttesterSlashings: b.block.body.attesterSlashingsElectra,
Attestations: b.block.body.attestationsElectra,
Deposits: b.block.body.deposits,
VoluntaryExits: b.block.body.voluntaryExits,
SyncAggregate: b.block.body.syncAggregate,
ExecutionPayloadHeader: denebHeader,
BlsToExecutionChanges: b.block.body.blsToExecutionChanges,
BlobKzgCommitments: b.block.body.blobKzgCommitments,
ExecutionRequests: b.block.body.executionRequests,
},
},
Signature: b.signature[:],
})
default:
return nil, fmt.Errorf("%T is not an execution payload header", p)
}
@@ -437,6 +498,11 @@ func (b *SignedBeaconBlock) MarshalSSZ() ([]byte, error) {
return pb.(*eth.SignedBlindedBeaconBlockFulu).MarshalSSZ()
}
return pb.(*eth.SignedBeaconBlockFulu).MarshalSSZ()
case version.Gloas:
if b.IsBlinded() {
return pb.(*eth.SignedBlindedBeaconBlockFulu).MarshalSSZ()
}
return pb.(*eth.SignedBeaconBlockGloas).MarshalSSZ()
default:
return []byte{}, errIncorrectBlockVersion
}
@@ -479,6 +545,11 @@ func (b *SignedBeaconBlock) MarshalSSZTo(dst []byte) ([]byte, error) {
return pb.(*eth.SignedBlindedBeaconBlockFulu).MarshalSSZTo(dst)
}
return pb.(*eth.SignedBeaconBlockFulu).MarshalSSZTo(dst)
case version.Gloas:
if b.IsBlinded() {
return pb.(*eth.SignedBlindedBeaconBlockFulu).MarshalSSZTo(dst)
}
return pb.(*eth.SignedBeaconBlockGloas).MarshalSSZTo(dst)
default:
return []byte{}, errIncorrectBlockVersion
}
@@ -526,6 +597,11 @@ func (b *SignedBeaconBlock) SizeSSZ() int {
return pb.(*eth.SignedBlindedBeaconBlockFulu).SizeSSZ()
}
return pb.(*eth.SignedBeaconBlockFulu).SizeSSZ()
case version.Gloas:
if b.IsBlinded() {
return pb.(*eth.SignedBlindedBeaconBlockFulu).SizeSSZ()
}
return pb.(*eth.SignedBeaconBlockGloas).SizeSSZ()
default:
panic(incorrectBlockVersion)
}
@@ -666,6 +742,28 @@ func (b *SignedBeaconBlock) UnmarshalSSZ(buf []byte) error {
return err
}
}
case version.Gloas:
if b.IsBlinded() {
pb := &eth.SignedBlindedBeaconBlockFulu{}
if err := pb.UnmarshalSSZ(buf); err != nil {
return err
}
var err error
newBlock, err = initBlindedSignedBlockFromProtoFulu(pb)
if err != nil {
return err
}
} else {
pb := &eth.SignedBeaconBlockGloas{}
if err := pb.UnmarshalSSZ(buf); err != nil {
return err
}
var err error
newBlock, err = initSignedBlockFromProtoGloas(pb)
if err != nil {
return err
}
}
default:
return errIncorrectBlockVersion
}
@@ -749,6 +847,11 @@ func (b *BeaconBlock) HashTreeRoot() ([field_params.RootLength]byte, error) {
return pb.(*eth.BlindedBeaconBlockFulu).HashTreeRoot()
}
return pb.(*eth.BeaconBlockElectra).HashTreeRoot()
case version.Gloas:
if b.IsBlinded() {
return pb.(*eth.BlindedBeaconBlockFulu).HashTreeRoot()
}
return pb.(*eth.BeaconBlockGloas).HashTreeRoot()
default:
return [field_params.RootLength]byte{}, errIncorrectBlockVersion
}
@@ -790,6 +893,11 @@ func (b *BeaconBlock) HashTreeRootWith(h *ssz.Hasher) error {
return pb.(*eth.BlindedBeaconBlockFulu).HashTreeRootWith(h)
}
return pb.(*eth.BeaconBlockElectra).HashTreeRootWith(h)
case version.Gloas:
if b.IsBlinded() {
return pb.(*eth.BlindedBeaconBlockFulu).HashTreeRootWith(h)
}
return pb.(*eth.BeaconBlockGloas).HashTreeRootWith(h)
default:
return errIncorrectBlockVersion
}
@@ -832,6 +940,11 @@ func (b *BeaconBlock) MarshalSSZ() ([]byte, error) {
return pb.(*eth.BlindedBeaconBlockFulu).MarshalSSZ()
}
return pb.(*eth.BeaconBlockElectra).MarshalSSZ()
case version.Gloas:
if b.IsBlinded() {
return pb.(*eth.BlindedBeaconBlockFulu).MarshalSSZ()
}
return pb.(*eth.BeaconBlockGloas).MarshalSSZ()
default:
return []byte{}, errIncorrectBlockVersion
}
@@ -874,6 +987,11 @@ func (b *BeaconBlock) MarshalSSZTo(dst []byte) ([]byte, error) {
return pb.(*eth.BlindedBeaconBlockFulu).MarshalSSZTo(dst)
}
return pb.(*eth.BeaconBlockElectra).MarshalSSZTo(dst)
case version.Gloas:
if b.IsBlinded() {
return pb.(*eth.BlindedBeaconBlockFulu).MarshalSSZTo(dst)
}
return pb.(*eth.BeaconBlockGloas).MarshalSSZTo(dst)
default:
return []byte{}, errIncorrectBlockVersion
}
@@ -921,6 +1039,11 @@ func (b *BeaconBlock) SizeSSZ() int {
return pb.(*eth.BlindedBeaconBlockFulu).SizeSSZ()
}
return pb.(*eth.BeaconBlockElectra).SizeSSZ()
case version.Gloas:
if b.IsBlinded() {
return pb.(*eth.BlindedBeaconBlockFulu).SizeSSZ()
}
return pb.(*eth.BeaconBlockGloas).SizeSSZ()
default:
panic(incorrectBodyVersion)
}
@@ -1061,6 +1184,28 @@ func (b *BeaconBlock) UnmarshalSSZ(buf []byte) error {
return err
}
}
case version.Gloas:
if b.IsBlinded() {
pb := &eth.BlindedBeaconBlockFulu{}
if err := pb.UnmarshalSSZ(buf); err != nil {
return err
}
var err error
newBlock, err = initBlindedBlockFromProtoFulu(pb)
if err != nil {
return err
}
} else {
pb := &eth.BeaconBlockGloas{}
if err := pb.UnmarshalSSZ(buf); err != nil {
return err
}
var err error
newBlock, err = initBlockFromProtoGloas(pb)
if err != nil {
return err
}
}
default:
return errIncorrectBlockVersion
}
@@ -1104,6 +1249,11 @@ func (b *BeaconBlock) AsSignRequestObject() (validatorpb.SignRequestObject, erro
return &validatorpb.SignRequest_BlindedBlockFulu{BlindedBlockFulu: pb.(*eth.BlindedBeaconBlockFulu)}, nil
}
return &validatorpb.SignRequest_BlockFulu{BlockFulu: pb.(*eth.BeaconBlockElectra)}, nil
case version.Gloas:
if b.IsBlinded() {
return &validatorpb.SignRequest_BlindedBlockFulu{BlindedBlockFulu: pb.(*eth.BlindedBeaconBlockFulu)}, nil
}
return &validatorpb.SignRequest_BlockGloas{BlockGloas: pb.(*eth.BeaconBlockGloas)}, nil
default:
return nil, errIncorrectBlockVersion
}
@@ -1280,6 +1430,11 @@ func (b *BeaconBlockBody) HashTreeRoot() ([field_params.RootLength]byte, error)
return pb.(*eth.BlindedBeaconBlockBodyElectra).HashTreeRoot()
}
return pb.(*eth.BeaconBlockBodyElectra).HashTreeRoot()
case version.Gloas:
if b.IsBlinded() {
return pb.(*eth.BlindedBeaconBlockBodyElectra).HashTreeRoot()
}
return pb.(*eth.BeaconBlockBodyGloas).HashTreeRoot()
default:
return [field_params.RootLength]byte{}, errIncorrectBodyVersion
}

View File

@@ -44,6 +44,8 @@ func ComputeBlockBodyFieldRoots(ctx context.Context, blockBody *BeaconBlockBody)
fieldRoots = make([][]byte, 13)
case version.Fulu:
fieldRoots = make([][]byte, 13)
case version.Gloas:
fieldRoots = make([][]byte, 13)
default:
return nil, fmt.Errorf("unknown block body version %s", version.String(blockBody.version))
}

View File

@@ -185,6 +185,33 @@ func (b *SignedBeaconBlock) Proto() (proto.Message, error) { // nolint:gocognit
Block: block,
Signature: b.signature[:],
}, nil
case version.Gloas:
if b.IsBlinded() {
var block *eth.BlindedBeaconBlockFulu
if blockMessage != nil {
var ok bool
block, ok = blockMessage.(*eth.BlindedBeaconBlockFulu)
if !ok {
return nil, errIncorrectBlockVersion
}
}
return &eth.SignedBlindedBeaconBlockFulu{
Message: block,
Signature: b.signature[:],
}, nil
}
var block *eth.BeaconBlockGloas
if blockMessage != nil {
var ok bool
block, ok = blockMessage.(*eth.BeaconBlockGloas)
if !ok {
return nil, errIncorrectBlockVersion
}
}
return &eth.SignedBeaconBlockGloas{
Block: block,
Signature: b.signature[:],
}, nil
default:
return nil, errors.New("unsupported signed beacon block version")
}
@@ -399,6 +426,39 @@ func (b *BeaconBlock) Proto() (proto.Message, error) { // nolint:gocognit
StateRoot: b.stateRoot[:],
Body: body,
}, nil
case version.Gloas:
if b.IsBlinded() {
var body *eth.BlindedBeaconBlockBodyElectra
if bodyMessage != nil {
var ok bool
body, ok = bodyMessage.(*eth.BlindedBeaconBlockBodyElectra)
if !ok {
return nil, errIncorrectBodyVersion
}
}
return &eth.BlindedBeaconBlockFulu{
Slot: b.slot,
ProposerIndex: b.proposerIndex,
ParentRoot: b.parentRoot[:],
StateRoot: b.stateRoot[:],
Body: body,
}, nil
}
var body *eth.BeaconBlockBodyGloas
if bodyMessage != nil {
var ok bool
body, ok = bodyMessage.(*eth.BeaconBlockBodyGloas)
if !ok {
return nil, errIncorrectBodyVersion
}
}
return &eth.BeaconBlockGloas{
Slot: b.slot,
ProposerIndex: b.proposerIndex,
ParentRoot: b.parentRoot[:],
StateRoot: b.stateRoot[:],
Body: body,
}, nil
default:
return nil, fmt.Errorf("unsupported beacon block version: %s", version.String(b.version))
}
@@ -668,6 +728,78 @@ func (b *BeaconBlockBody) Proto() (proto.Message, error) {
BlobKzgCommitments: b.blobKzgCommitments,
ExecutionRequests: b.executionRequests,
}, nil
case version.Gloas:
if b.IsBlinded() {
var ph *enginev1.ExecutionPayloadHeaderGloas
var ok bool
if b.executionPayloadHeader != nil {
ph, ok = b.executionPayloadHeader.Proto().(*enginev1.ExecutionPayloadHeaderGloas)
if !ok {
return nil, errPayloadHeaderWrongType
}
}
// Use Electra body for now until Gloas-specific blinded body is created
denebHeader := &enginev1.ExecutionPayloadHeaderDeneb{}
if ph != nil {
denebHeader = &enginev1.ExecutionPayloadHeaderDeneb{
ParentHash: ph.ParentHash,
FeeRecipient: ph.FeeRecipient,
StateRoot: ph.StateRoot,
ReceiptsRoot: ph.ReceiptsRoot,
LogsBloom: ph.LogsBloom,
PrevRandao: ph.PrevRandao,
BlockNumber: ph.BlockNumber,
GasLimit: ph.GasLimit,
GasUsed: ph.GasUsed,
Timestamp: ph.Timestamp,
ExtraData: ph.ExtraData,
BaseFeePerGas: ph.BaseFeePerGas,
BlockHash: ph.BlockHash,
TransactionsRoot: ph.TransactionsRoot,
WithdrawalsRoot: ph.WithdrawalsRoot,
BlobGasUsed: ph.BlobGasUsed,
ExcessBlobGas: ph.ExcessBlobGas,
}
}
return &eth.BlindedBeaconBlockBodyElectra{
RandaoReveal: b.randaoReveal[:],
Eth1Data: b.eth1Data,
Graffiti: b.graffiti[:],
ProposerSlashings: b.proposerSlashings,
AttesterSlashings: b.attesterSlashingsElectra,
Attestations: b.attestationsElectra,
Deposits: b.deposits,
VoluntaryExits: b.voluntaryExits,
SyncAggregate: b.syncAggregate,
ExecutionPayloadHeader: denebHeader,
BlsToExecutionChanges: b.blsToExecutionChanges,
BlobKzgCommitments: b.blobKzgCommitments,
ExecutionRequests: b.executionRequests,
}, nil
}
var p *enginev1.ExecutionPayloadGloas
var ok bool
if b.executionPayload != nil {
p, ok = b.executionPayload.Proto().(*enginev1.ExecutionPayloadGloas)
if !ok {
return nil, errPayloadWrongType
}
}
return &eth.BeaconBlockBodyGloas{
RandaoReveal: b.randaoReveal[:],
Eth1Data: b.eth1Data,
Graffiti: b.graffiti[:],
ProposerSlashings: b.proposerSlashings,
AttesterSlashings: b.attesterSlashingsElectra,
Attestations: b.attestationsElectra,
Deposits: b.deposits,
VoluntaryExits: b.voluntaryExits,
SyncAggregate: b.syncAggregate,
ExecutionPayload: p,
BlsToExecutionChanges: b.blsToExecutionChanges,
BlobKzgCommitments: b.blobKzgCommitments,
ExecutionRequests: b.executionRequests,
}, nil
default:
return nil, errors.New("unsupported beacon block body version")
}
@@ -1477,3 +1609,77 @@ func initBlindedBlockBodyFromProtoFulu(pb *eth.BlindedBeaconBlockBodyElectra) (*
}
return b, nil
}
// ----------------------------------------------------------------------------
// Gloas
// ----------------------------------------------------------------------------
func initSignedBlockFromProtoGloas(pb *eth.SignedBeaconBlockGloas) (*SignedBeaconBlock, error) {
if pb == nil {
return nil, errNilBlock
}
block, err := initBlockFromProtoGloas(pb.Block)
if err != nil {
return nil, err
}
b := &SignedBeaconBlock{
version: version.Gloas,
block: block,
signature: bytesutil.ToBytes96(pb.Signature),
}
return b, nil
}
func initBlockFromProtoGloas(pb *eth.BeaconBlockGloas) (*BeaconBlock, error) {
if pb == nil {
return nil, errNilBlock
}
body, err := initBlockBodyFromProtoGloas(pb.Body)
if err != nil {
return nil, err
}
b := &BeaconBlock{
version: version.Gloas,
slot: pb.Slot,
proposerIndex: pb.ProposerIndex,
parentRoot: bytesutil.ToBytes32(pb.ParentRoot),
stateRoot: bytesutil.ToBytes32(pb.StateRoot),
body: body,
}
return b, nil
}
func initBlockBodyFromProtoGloas(pb *eth.BeaconBlockBodyGloas) (*BeaconBlockBody, error) {
if pb == nil {
return nil, errNilBlockBody
}
p, err := WrappedExecutionPayloadGloas(pb.ExecutionPayload)
// We allow the payload to be nil
if err != nil && !errors.Is(err, consensus_types.ErrNilObjectWrapped) {
return nil, err
}
er := pb.ExecutionRequests
if er == nil {
er = &enginev1.ExecutionRequests{}
}
b := &BeaconBlockBody{
version: version.Gloas,
randaoReveal: bytesutil.ToBytes96(pb.RandaoReveal),
eth1Data: pb.Eth1Data,
graffiti: bytesutil.ToBytes32(pb.Graffiti),
proposerSlashings: pb.ProposerSlashings,
attesterSlashingsElectra: pb.AttesterSlashings,
attestationsElectra: pb.Attestations,
deposits: pb.Deposits,
voluntaryExits: pb.VoluntaryExits,
syncAggregate: pb.SyncAggregate,
executionPayload: p,
blsToExecutionChanges: pb.BlsToExecutionChanges,
blobKzgCommitments: pb.BlobKzgCommitments,
executionRequests: er,
}
return b, nil
}

View File

@@ -36,6 +36,9 @@ func NewSignedBeaconBlockFromGeneric(gb *eth.GenericSignedBeaconBlock) (interfac
case *eth.GenericSignedBeaconBlock_Fulu:
return blocks.NewSignedBeaconBlock(bb.Fulu.Block)
// Generic Signed Beacon Block Deneb can't be used here as it is not a block, but block content with blobs
case *eth.GenericSignedBeaconBlock_Gloas:
return blocks.NewSignedBeaconBlock(bb.Gloas.Block)
// Generic Signed Beacon Block Gloas can't be used here as it is not a block, but block content with blobs
default:
return nil, errors.Wrapf(blocks.ErrUnsupportedSignedBeaconBlock, "unable to create block from type %T", gb)
}

View File

@@ -87,6 +87,8 @@ func FromForkVersion(cv [fieldparams.VersionLength]byte) (*VersionedUnmarshaler,
fork = version.Electra
case bytesutil.ToBytes4(cfg.FuluForkVersion):
fork = version.Fulu
case bytesutil.ToBytes4(cfg.GloasForkVersion):
fork = version.Gloas
default:
return nil, errors.Wrapf(ErrForkNotFound, "version=%#x", cv)
}
@@ -172,6 +174,16 @@ func (cf *VersionedUnmarshaler) UnmarshalBeaconState(marshaled []byte) (s state.
if err != nil {
return nil, errors.Wrapf(err, "failed to init state trie from state, detected fork=%s", forkName)
}
case version.Gloas:
st := &ethpb.BeaconStateGloas{}
err = st.UnmarshalSSZ(marshaled)
if err != nil {
return nil, errors.Wrapf(err, "failed to unmarshal state, detected fork=%s", forkName)
}
s, err = state_native.InitializeFromProtoUnsafeGloas(st)
if err != nil {
return nil, errors.Wrapf(err, "failed to init state trie from state, detected fork=%s", forkName)
}
default:
return nil, fmt.Errorf("unable to initialize BeaconState for fork version=%s", forkName)
}
@@ -224,6 +236,8 @@ func (cf *VersionedUnmarshaler) UnmarshalBeaconBlock(marshaled []byte) (interfac
blk = &ethpb.SignedBeaconBlockElectra{}
case version.Fulu:
blk = &ethpb.SignedBeaconBlockFulu{}
case version.Gloas:
blk = &ethpb.SignedBeaconBlockGloas{}
default:
forkName := version.String(cf.Fork)
return nil, fmt.Errorf("unable to initialize ReadOnlyBeaconBlock for fork version=%s at slot=%d", forkName, slot)

View File

@@ -43,6 +43,8 @@ ssz_gen_marshal(
"ExecutionPayloadDeneb",
"ExecutionPayloadDenebAndBlobsBundle",
"ExecutionPayloadDenebAndBlobsBundleV2",
"ExecutionPayloadGloas",
"ExecutionPayloadHeaderGloas",
"BlindedBlobsBundle",
"BlobsBundle",
"BlobsBundleV2",
@@ -81,6 +83,7 @@ go_library(
"execution_engine.go",
"fulu.go",
"json_marshal_unmarshal.go",
"gloas.go",
":ssz_generated_files", # keep
],
embed = [
@@ -116,6 +119,7 @@ ssz_proto_files(
"electra.proto",
"execution_engine.proto",
"fulu.proto",
"gloas.proto",
],
config = select({
"//conditions:default": "mainnet",

View File

@@ -1791,6 +1791,864 @@ func (e *ExecutionPayloadDeneb) HashTreeRootWith(hh *ssz.Hasher) (err error) {
return
}
// MarshalSSZ ssz marshals the ExecutionPayloadGloas object
func (e *ExecutionPayloadGloas) MarshalSSZ() ([]byte, error) {
return ssz.MarshalSSZ(e)
}
// MarshalSSZTo ssz marshals the ExecutionPayloadGloas object to a target array
func (e *ExecutionPayloadGloas) MarshalSSZTo(buf []byte) (dst []byte, err error) {
dst = buf
offset := int(532)
// Field (0) 'ParentHash'
if size := len(e.ParentHash); size != 32 {
err = ssz.ErrBytesLengthFn("--.ParentHash", size, 32)
return
}
dst = append(dst, e.ParentHash...)
// Field (1) 'FeeRecipient'
if size := len(e.FeeRecipient); size != 20 {
err = ssz.ErrBytesLengthFn("--.FeeRecipient", size, 20)
return
}
dst = append(dst, e.FeeRecipient...)
// Field (2) 'StateRoot'
if size := len(e.StateRoot); size != 32 {
err = ssz.ErrBytesLengthFn("--.StateRoot", size, 32)
return
}
dst = append(dst, e.StateRoot...)
// Field (3) 'ReceiptsRoot'
if size := len(e.ReceiptsRoot); size != 32 {
err = ssz.ErrBytesLengthFn("--.ReceiptsRoot", size, 32)
return
}
dst = append(dst, e.ReceiptsRoot...)
// Field (4) 'LogsBloom'
if size := len(e.LogsBloom); size != 256 {
err = ssz.ErrBytesLengthFn("--.LogsBloom", size, 256)
return
}
dst = append(dst, e.LogsBloom...)
// Field (5) 'PrevRandao'
if size := len(e.PrevRandao); size != 32 {
err = ssz.ErrBytesLengthFn("--.PrevRandao", size, 32)
return
}
dst = append(dst, e.PrevRandao...)
// Field (6) 'BlockNumber'
dst = ssz.MarshalUint64(dst, e.BlockNumber)
// Field (7) 'GasLimit'
dst = ssz.MarshalUint64(dst, e.GasLimit)
// Field (8) 'GasUsed'
dst = ssz.MarshalUint64(dst, e.GasUsed)
// Field (9) 'Timestamp'
dst = ssz.MarshalUint64(dst, e.Timestamp)
// Offset (10) 'ExtraData'
dst = ssz.WriteOffset(dst, offset)
offset += len(e.ExtraData)
// Field (11) 'BaseFeePerGas'
if size := len(e.BaseFeePerGas); size != 32 {
err = ssz.ErrBytesLengthFn("--.BaseFeePerGas", size, 32)
return
}
dst = append(dst, e.BaseFeePerGas...)
// Field (12) 'BlockHash'
if size := len(e.BlockHash); size != 32 {
err = ssz.ErrBytesLengthFn("--.BlockHash", size, 32)
return
}
dst = append(dst, e.BlockHash...)
// Offset (13) 'Transactions'
dst = ssz.WriteOffset(dst, offset)
for ii := 0; ii < len(e.Transactions); ii++ {
offset += 4
offset += len(e.Transactions[ii])
}
// Offset (14) 'Withdrawals'
dst = ssz.WriteOffset(dst, offset)
offset += len(e.Withdrawals) * 44
// Field (15) 'BlobGasUsed'
dst = ssz.MarshalUint64(dst, e.BlobGasUsed)
// Field (16) 'ExcessBlobGas'
dst = ssz.MarshalUint64(dst, e.ExcessBlobGas)
// Offset (17) 'BlockAccessList'
dst = ssz.WriteOffset(dst, offset)
offset += len(e.BlockAccessList)
// Field (10) 'ExtraData'
if size := len(e.ExtraData); size > 32 {
err = ssz.ErrBytesLengthFn("--.ExtraData", size, 32)
return
}
dst = append(dst, e.ExtraData...)
// Field (13) 'Transactions'
if size := len(e.Transactions); size > 1048576 {
err = ssz.ErrListTooBigFn("--.Transactions", size, 1048576)
return
}
{
offset = 4 * len(e.Transactions)
for ii := 0; ii < len(e.Transactions); ii++ {
dst = ssz.WriteOffset(dst, offset)
offset += len(e.Transactions[ii])
}
}
for ii := 0; ii < len(e.Transactions); ii++ {
if size := len(e.Transactions[ii]); size > 1073741824 {
err = ssz.ErrBytesLengthFn("--.Transactions[ii]", size, 1073741824)
return
}
dst = append(dst, e.Transactions[ii]...)
}
// Field (14) 'Withdrawals'
if size := len(e.Withdrawals); size > 16 {
err = ssz.ErrListTooBigFn("--.Withdrawals", size, 16)
return
}
for ii := 0; ii < len(e.Withdrawals); ii++ {
if dst, err = e.Withdrawals[ii].MarshalSSZTo(dst); err != nil {
return
}
}
// Field (17) 'BlockAccessList'
if size := len(e.BlockAccessList); size > 1073741824 {
err = ssz.ErrBytesLengthFn("--.BlockAccessList", size, 1073741824)
return
}
dst = append(dst, e.BlockAccessList...)
return
}
// UnmarshalSSZ ssz unmarshals the ExecutionPayloadGloas object
func (e *ExecutionPayloadGloas) UnmarshalSSZ(buf []byte) error {
var err error
size := uint64(len(buf))
if size < 532 {
return ssz.ErrSize
}
tail := buf
var o10, o13, o14, o17 uint64
// Field (0) 'ParentHash'
if cap(e.ParentHash) == 0 {
e.ParentHash = make([]byte, 0, len(buf[0:32]))
}
e.ParentHash = append(e.ParentHash, buf[0:32]...)
// Field (1) 'FeeRecipient'
if cap(e.FeeRecipient) == 0 {
e.FeeRecipient = make([]byte, 0, len(buf[32:52]))
}
e.FeeRecipient = append(e.FeeRecipient, buf[32:52]...)
// Field (2) 'StateRoot'
if cap(e.StateRoot) == 0 {
e.StateRoot = make([]byte, 0, len(buf[52:84]))
}
e.StateRoot = append(e.StateRoot, buf[52:84]...)
// Field (3) 'ReceiptsRoot'
if cap(e.ReceiptsRoot) == 0 {
e.ReceiptsRoot = make([]byte, 0, len(buf[84:116]))
}
e.ReceiptsRoot = append(e.ReceiptsRoot, buf[84:116]...)
// Field (4) 'LogsBloom'
if cap(e.LogsBloom) == 0 {
e.LogsBloom = make([]byte, 0, len(buf[116:372]))
}
e.LogsBloom = append(e.LogsBloom, buf[116:372]...)
// Field (5) 'PrevRandao'
if cap(e.PrevRandao) == 0 {
e.PrevRandao = make([]byte, 0, len(buf[372:404]))
}
e.PrevRandao = append(e.PrevRandao, buf[372:404]...)
// Field (6) 'BlockNumber'
e.BlockNumber = ssz.UnmarshallUint64(buf[404:412])
// Field (7) 'GasLimit'
e.GasLimit = ssz.UnmarshallUint64(buf[412:420])
// Field (8) 'GasUsed'
e.GasUsed = ssz.UnmarshallUint64(buf[420:428])
// Field (9) 'Timestamp'
e.Timestamp = ssz.UnmarshallUint64(buf[428:436])
// Offset (10) 'ExtraData'
if o10 = ssz.ReadOffset(buf[436:440]); o10 > size {
return ssz.ErrOffset
}
if o10 != 532 {
return ssz.ErrInvalidVariableOffset
}
// Field (11) 'BaseFeePerGas'
if cap(e.BaseFeePerGas) == 0 {
e.BaseFeePerGas = make([]byte, 0, len(buf[440:472]))
}
e.BaseFeePerGas = append(e.BaseFeePerGas, buf[440:472]...)
// Field (12) 'BlockHash'
if cap(e.BlockHash) == 0 {
e.BlockHash = make([]byte, 0, len(buf[472:504]))
}
e.BlockHash = append(e.BlockHash, buf[472:504]...)
// Offset (13) 'Transactions'
if o13 = ssz.ReadOffset(buf[504:508]); o13 > size || o10 > o13 {
return ssz.ErrOffset
}
// Offset (14) 'Withdrawals'
if o14 = ssz.ReadOffset(buf[508:512]); o14 > size || o13 > o14 {
return ssz.ErrOffset
}
// Field (15) 'BlobGasUsed'
e.BlobGasUsed = ssz.UnmarshallUint64(buf[512:520])
// Field (16) 'ExcessBlobGas'
e.ExcessBlobGas = ssz.UnmarshallUint64(buf[520:528])
// Offset (17) 'BlockAccessList'
if o17 = ssz.ReadOffset(buf[528:532]); o17 > size || o14 > o17 {
return ssz.ErrOffset
}
// Field (10) 'ExtraData'
{
buf = tail[o10:o13]
if len(buf) > 32 {
return ssz.ErrBytesLength
}
if cap(e.ExtraData) == 0 {
e.ExtraData = make([]byte, 0, len(buf))
}
e.ExtraData = append(e.ExtraData, buf...)
}
// Field (13) 'Transactions'
{
buf = tail[o13:o14]
num, err := ssz.DecodeDynamicLength(buf, 1048576)
if err != nil {
return err
}
e.Transactions = make([][]byte, num)
err = ssz.UnmarshalDynamic(buf, num, func(indx int, buf []byte) (err error) {
if len(buf) > 1073741824 {
return ssz.ErrBytesLength
}
if cap(e.Transactions[indx]) == 0 {
e.Transactions[indx] = make([]byte, 0, len(buf))
}
e.Transactions[indx] = append(e.Transactions[indx], buf...)
return nil
})
if err != nil {
return err
}
}
// Field (14) 'Withdrawals'
{
buf = tail[o14:o17]
num, err := ssz.DivideInt2(len(buf), 44, 16)
if err != nil {
return err
}
e.Withdrawals = make([]*Withdrawal, num)
for ii := 0; ii < num; ii++ {
if e.Withdrawals[ii] == nil {
e.Withdrawals[ii] = new(Withdrawal)
}
if err = e.Withdrawals[ii].UnmarshalSSZ(buf[ii*44 : (ii+1)*44]); err != nil {
return err
}
}
}
// Field (17) 'BlockAccessList'
{
buf = tail[o17:]
if len(buf) > 1073741824 {
return ssz.ErrBytesLength
}
if cap(e.BlockAccessList) == 0 {
e.BlockAccessList = make([]byte, 0, len(buf))
}
e.BlockAccessList = append(e.BlockAccessList, buf...)
}
return err
}
// SizeSSZ returns the ssz encoded size in bytes for the ExecutionPayloadGloas object
func (e *ExecutionPayloadGloas) SizeSSZ() (size int) {
size = 532
// Field (10) 'ExtraData'
size += len(e.ExtraData)
// Field (13) 'Transactions'
for ii := 0; ii < len(e.Transactions); ii++ {
size += 4
size += len(e.Transactions[ii])
}
// Field (14) 'Withdrawals'
size += len(e.Withdrawals) * 44
// Field (17) 'BlockAccessList'
size += len(e.BlockAccessList)
return
}
// HashTreeRoot ssz hashes the ExecutionPayloadGloas object
func (e *ExecutionPayloadGloas) HashTreeRoot() ([32]byte, error) {
return ssz.HashWithDefaultHasher(e)
}
// HashTreeRootWith ssz hashes the ExecutionPayloadGloas object with a hasher
func (e *ExecutionPayloadGloas) HashTreeRootWith(hh *ssz.Hasher) (err error) {
indx := hh.Index()
// Field (0) 'ParentHash'
if size := len(e.ParentHash); size != 32 {
err = ssz.ErrBytesLengthFn("--.ParentHash", size, 32)
return
}
hh.PutBytes(e.ParentHash)
// Field (1) 'FeeRecipient'
if size := len(e.FeeRecipient); size != 20 {
err = ssz.ErrBytesLengthFn("--.FeeRecipient", size, 20)
return
}
hh.PutBytes(e.FeeRecipient)
// Field (2) 'StateRoot'
if size := len(e.StateRoot); size != 32 {
err = ssz.ErrBytesLengthFn("--.StateRoot", size, 32)
return
}
hh.PutBytes(e.StateRoot)
// Field (3) 'ReceiptsRoot'
if size := len(e.ReceiptsRoot); size != 32 {
err = ssz.ErrBytesLengthFn("--.ReceiptsRoot", size, 32)
return
}
hh.PutBytes(e.ReceiptsRoot)
// Field (4) 'LogsBloom'
if size := len(e.LogsBloom); size != 256 {
err = ssz.ErrBytesLengthFn("--.LogsBloom", size, 256)
return
}
hh.PutBytes(e.LogsBloom)
// Field (5) 'PrevRandao'
if size := len(e.PrevRandao); size != 32 {
err = ssz.ErrBytesLengthFn("--.PrevRandao", size, 32)
return
}
hh.PutBytes(e.PrevRandao)
// Field (6) 'BlockNumber'
hh.PutUint64(e.BlockNumber)
// Field (7) 'GasLimit'
hh.PutUint64(e.GasLimit)
// Field (8) 'GasUsed'
hh.PutUint64(e.GasUsed)
// Field (9) 'Timestamp'
hh.PutUint64(e.Timestamp)
// Field (10) 'ExtraData'
{
elemIndx := hh.Index()
byteLen := uint64(len(e.ExtraData))
if byteLen > 32 {
err = ssz.ErrIncorrectListSize
return
}
hh.PutBytes(e.ExtraData)
hh.MerkleizeWithMixin(elemIndx, byteLen, (32+31)/32)
}
// Field (11) 'BaseFeePerGas'
if size := len(e.BaseFeePerGas); size != 32 {
err = ssz.ErrBytesLengthFn("--.BaseFeePerGas", size, 32)
return
}
hh.PutBytes(e.BaseFeePerGas)
// Field (12) 'BlockHash'
if size := len(e.BlockHash); size != 32 {
err = ssz.ErrBytesLengthFn("--.BlockHash", size, 32)
return
}
hh.PutBytes(e.BlockHash)
// Field (13) 'Transactions'
{
subIndx := hh.Index()
num := uint64(len(e.Transactions))
if num > 1048576 {
err = ssz.ErrIncorrectListSize
return
}
for _, elem := range e.Transactions {
{
elemIndx := hh.Index()
byteLen := uint64(len(elem))
if byteLen > 1073741824 {
err = ssz.ErrIncorrectListSize
return
}
hh.AppendBytes32(elem)
hh.MerkleizeWithMixin(elemIndx, byteLen, (1073741824+31)/32)
}
}
hh.MerkleizeWithMixin(subIndx, num, 1048576)
}
// Field (14) 'Withdrawals'
{
subIndx := hh.Index()
num := uint64(len(e.Withdrawals))
if num > 16 {
err = ssz.ErrIncorrectListSize
return
}
for _, elem := range e.Withdrawals {
if err = elem.HashTreeRootWith(hh); err != nil {
return
}
}
hh.MerkleizeWithMixin(subIndx, num, 16)
}
// Field (15) 'BlobGasUsed'
hh.PutUint64(e.BlobGasUsed)
// Field (16) 'ExcessBlobGas'
hh.PutUint64(e.ExcessBlobGas)
// Field (17) 'BlockAccessList'
{
elemIndx := hh.Index()
byteLen := uint64(len(e.BlockAccessList))
if byteLen > 1073741824 {
err = ssz.ErrIncorrectListSize
return
}
hh.PutBytes(e.BlockAccessList)
hh.MerkleizeWithMixin(elemIndx, byteLen, (1073741824+31)/32)
}
hh.Merkleize(indx)
return
}
// MarshalSSZ ssz marshals the ExecutionPayloadHeaderGloas object
func (e *ExecutionPayloadHeaderGloas) MarshalSSZ() ([]byte, error) {
return ssz.MarshalSSZ(e)
}
// MarshalSSZTo ssz marshals the ExecutionPayloadHeaderGloas object to a target array
func (e *ExecutionPayloadHeaderGloas) MarshalSSZTo(buf []byte) (dst []byte, err error) {
dst = buf
offset := int(616)
// Field (0) 'ParentHash'
if size := len(e.ParentHash); size != 32 {
err = ssz.ErrBytesLengthFn("--.ParentHash", size, 32)
return
}
dst = append(dst, e.ParentHash...)
// Field (1) 'FeeRecipient'
if size := len(e.FeeRecipient); size != 20 {
err = ssz.ErrBytesLengthFn("--.FeeRecipient", size, 20)
return
}
dst = append(dst, e.FeeRecipient...)
// Field (2) 'StateRoot'
if size := len(e.StateRoot); size != 32 {
err = ssz.ErrBytesLengthFn("--.StateRoot", size, 32)
return
}
dst = append(dst, e.StateRoot...)
// Field (3) 'ReceiptsRoot'
if size := len(e.ReceiptsRoot); size != 32 {
err = ssz.ErrBytesLengthFn("--.ReceiptsRoot", size, 32)
return
}
dst = append(dst, e.ReceiptsRoot...)
// Field (4) 'LogsBloom'
if size := len(e.LogsBloom); size != 256 {
err = ssz.ErrBytesLengthFn("--.LogsBloom", size, 256)
return
}
dst = append(dst, e.LogsBloom...)
// Field (5) 'PrevRandao'
if size := len(e.PrevRandao); size != 32 {
err = ssz.ErrBytesLengthFn("--.PrevRandao", size, 32)
return
}
dst = append(dst, e.PrevRandao...)
// Field (6) 'BlockNumber'
dst = ssz.MarshalUint64(dst, e.BlockNumber)
// Field (7) 'GasLimit'
dst = ssz.MarshalUint64(dst, e.GasLimit)
// Field (8) 'GasUsed'
dst = ssz.MarshalUint64(dst, e.GasUsed)
// Field (9) 'Timestamp'
dst = ssz.MarshalUint64(dst, e.Timestamp)
// Offset (10) 'ExtraData'
dst = ssz.WriteOffset(dst, offset)
offset += len(e.ExtraData)
// Field (11) 'BaseFeePerGas'
if size := len(e.BaseFeePerGas); size != 32 {
err = ssz.ErrBytesLengthFn("--.BaseFeePerGas", size, 32)
return
}
dst = append(dst, e.BaseFeePerGas...)
// Field (12) 'BlockHash'
if size := len(e.BlockHash); size != 32 {
err = ssz.ErrBytesLengthFn("--.BlockHash", size, 32)
return
}
dst = append(dst, e.BlockHash...)
// Field (13) 'TransactionsRoot'
if size := len(e.TransactionsRoot); size != 32 {
err = ssz.ErrBytesLengthFn("--.TransactionsRoot", size, 32)
return
}
dst = append(dst, e.TransactionsRoot...)
// Field (14) 'WithdrawalsRoot'
if size := len(e.WithdrawalsRoot); size != 32 {
err = ssz.ErrBytesLengthFn("--.WithdrawalsRoot", size, 32)
return
}
dst = append(dst, e.WithdrawalsRoot...)
// Field (15) 'BlobGasUsed'
dst = ssz.MarshalUint64(dst, e.BlobGasUsed)
// Field (16) 'ExcessBlobGas'
dst = ssz.MarshalUint64(dst, e.ExcessBlobGas)
// Field (17) 'BlockAccessListRoot'
if size := len(e.BlockAccessListRoot); size != 32 {
err = ssz.ErrBytesLengthFn("--.BlockAccessListRoot", size, 32)
return
}
dst = append(dst, e.BlockAccessListRoot...)
// Field (10) 'ExtraData'
if size := len(e.ExtraData); size > 32 {
err = ssz.ErrBytesLengthFn("--.ExtraData", size, 32)
return
}
dst = append(dst, e.ExtraData...)
return
}
// UnmarshalSSZ ssz unmarshals the ExecutionPayloadHeaderGloas object
func (e *ExecutionPayloadHeaderGloas) UnmarshalSSZ(buf []byte) error {
var err error
size := uint64(len(buf))
if size < 616 {
return ssz.ErrSize
}
tail := buf
var o10 uint64
// Field (0) 'ParentHash'
if cap(e.ParentHash) == 0 {
e.ParentHash = make([]byte, 0, len(buf[0:32]))
}
e.ParentHash = append(e.ParentHash, buf[0:32]...)
// Field (1) 'FeeRecipient'
if cap(e.FeeRecipient) == 0 {
e.FeeRecipient = make([]byte, 0, len(buf[32:52]))
}
e.FeeRecipient = append(e.FeeRecipient, buf[32:52]...)
// Field (2) 'StateRoot'
if cap(e.StateRoot) == 0 {
e.StateRoot = make([]byte, 0, len(buf[52:84]))
}
e.StateRoot = append(e.StateRoot, buf[52:84]...)
// Field (3) 'ReceiptsRoot'
if cap(e.ReceiptsRoot) == 0 {
e.ReceiptsRoot = make([]byte, 0, len(buf[84:116]))
}
e.ReceiptsRoot = append(e.ReceiptsRoot, buf[84:116]...)
// Field (4) 'LogsBloom'
if cap(e.LogsBloom) == 0 {
e.LogsBloom = make([]byte, 0, len(buf[116:372]))
}
e.LogsBloom = append(e.LogsBloom, buf[116:372]...)
// Field (5) 'PrevRandao'
if cap(e.PrevRandao) == 0 {
e.PrevRandao = make([]byte, 0, len(buf[372:404]))
}
e.PrevRandao = append(e.PrevRandao, buf[372:404]...)
// Field (6) 'BlockNumber'
e.BlockNumber = ssz.UnmarshallUint64(buf[404:412])
// Field (7) 'GasLimit'
e.GasLimit = ssz.UnmarshallUint64(buf[412:420])
// Field (8) 'GasUsed'
e.GasUsed = ssz.UnmarshallUint64(buf[420:428])
// Field (9) 'Timestamp'
e.Timestamp = ssz.UnmarshallUint64(buf[428:436])
// Offset (10) 'ExtraData'
if o10 = ssz.ReadOffset(buf[436:440]); o10 > size {
return ssz.ErrOffset
}
if o10 != 616 {
return ssz.ErrInvalidVariableOffset
}
// Field (11) 'BaseFeePerGas'
if cap(e.BaseFeePerGas) == 0 {
e.BaseFeePerGas = make([]byte, 0, len(buf[440:472]))
}
e.BaseFeePerGas = append(e.BaseFeePerGas, buf[440:472]...)
// Field (12) 'BlockHash'
if cap(e.BlockHash) == 0 {
e.BlockHash = make([]byte, 0, len(buf[472:504]))
}
e.BlockHash = append(e.BlockHash, buf[472:504]...)
// Field (13) 'TransactionsRoot'
if cap(e.TransactionsRoot) == 0 {
e.TransactionsRoot = make([]byte, 0, len(buf[504:536]))
}
e.TransactionsRoot = append(e.TransactionsRoot, buf[504:536]...)
// Field (14) 'WithdrawalsRoot'
if cap(e.WithdrawalsRoot) == 0 {
e.WithdrawalsRoot = make([]byte, 0, len(buf[536:568]))
}
e.WithdrawalsRoot = append(e.WithdrawalsRoot, buf[536:568]...)
// Field (15) 'BlobGasUsed'
e.BlobGasUsed = ssz.UnmarshallUint64(buf[568:576])
// Field (16) 'ExcessBlobGas'
e.ExcessBlobGas = ssz.UnmarshallUint64(buf[576:584])
// Field (17) 'BlockAccessListRoot'
if cap(e.BlockAccessListRoot) == 0 {
e.BlockAccessListRoot = make([]byte, 0, len(buf[584:616]))
}
e.BlockAccessListRoot = append(e.BlockAccessListRoot, buf[584:616]...)
// Field (10) 'ExtraData'
{
buf = tail[o10:]
if len(buf) > 32 {
return ssz.ErrBytesLength
}
if cap(e.ExtraData) == 0 {
e.ExtraData = make([]byte, 0, len(buf))
}
e.ExtraData = append(e.ExtraData, buf...)
}
return err
}
// SizeSSZ returns the ssz encoded size in bytes for the ExecutionPayloadHeaderGloas object
func (e *ExecutionPayloadHeaderGloas) SizeSSZ() (size int) {
size = 616
// Field (10) 'ExtraData'
size += len(e.ExtraData)
return
}
// HashTreeRoot ssz hashes the ExecutionPayloadHeaderGloas object
func (e *ExecutionPayloadHeaderGloas) HashTreeRoot() ([32]byte, error) {
return ssz.HashWithDefaultHasher(e)
}
// HashTreeRootWith ssz hashes the ExecutionPayloadHeaderGloas object with a hasher
func (e *ExecutionPayloadHeaderGloas) HashTreeRootWith(hh *ssz.Hasher) (err error) {
indx := hh.Index()
// Field (0) 'ParentHash'
if size := len(e.ParentHash); size != 32 {
err = ssz.ErrBytesLengthFn("--.ParentHash", size, 32)
return
}
hh.PutBytes(e.ParentHash)
// Field (1) 'FeeRecipient'
if size := len(e.FeeRecipient); size != 20 {
err = ssz.ErrBytesLengthFn("--.FeeRecipient", size, 20)
return
}
hh.PutBytes(e.FeeRecipient)
// Field (2) 'StateRoot'
if size := len(e.StateRoot); size != 32 {
err = ssz.ErrBytesLengthFn("--.StateRoot", size, 32)
return
}
hh.PutBytes(e.StateRoot)
// Field (3) 'ReceiptsRoot'
if size := len(e.ReceiptsRoot); size != 32 {
err = ssz.ErrBytesLengthFn("--.ReceiptsRoot", size, 32)
return
}
hh.PutBytes(e.ReceiptsRoot)
// Field (4) 'LogsBloom'
if size := len(e.LogsBloom); size != 256 {
err = ssz.ErrBytesLengthFn("--.LogsBloom", size, 256)
return
}
hh.PutBytes(e.LogsBloom)
// Field (5) 'PrevRandao'
if size := len(e.PrevRandao); size != 32 {
err = ssz.ErrBytesLengthFn("--.PrevRandao", size, 32)
return
}
hh.PutBytes(e.PrevRandao)
// Field (6) 'BlockNumber'
hh.PutUint64(e.BlockNumber)
// Field (7) 'GasLimit'
hh.PutUint64(e.GasLimit)
// Field (8) 'GasUsed'
hh.PutUint64(e.GasUsed)
// Field (9) 'Timestamp'
hh.PutUint64(e.Timestamp)
// Field (10) 'ExtraData'
{
elemIndx := hh.Index()
byteLen := uint64(len(e.ExtraData))
if byteLen > 32 {
err = ssz.ErrIncorrectListSize
return
}
hh.PutBytes(e.ExtraData)
hh.MerkleizeWithMixin(elemIndx, byteLen, (32+31)/32)
}
// Field (11) 'BaseFeePerGas'
if size := len(e.BaseFeePerGas); size != 32 {
err = ssz.ErrBytesLengthFn("--.BaseFeePerGas", size, 32)
return
}
hh.PutBytes(e.BaseFeePerGas)
// Field (12) 'BlockHash'
if size := len(e.BlockHash); size != 32 {
err = ssz.ErrBytesLengthFn("--.BlockHash", size, 32)
return
}
hh.PutBytes(e.BlockHash)
// Field (13) 'TransactionsRoot'
if size := len(e.TransactionsRoot); size != 32 {
err = ssz.ErrBytesLengthFn("--.TransactionsRoot", size, 32)
return
}
hh.PutBytes(e.TransactionsRoot)
// Field (14) 'WithdrawalsRoot'
if size := len(e.WithdrawalsRoot); size != 32 {
err = ssz.ErrBytesLengthFn("--.WithdrawalsRoot", size, 32)
return
}
hh.PutBytes(e.WithdrawalsRoot)
// Field (15) 'BlobGasUsed'
hh.PutUint64(e.BlobGasUsed)
// Field (16) 'ExcessBlobGas'
hh.PutUint64(e.ExcessBlobGas)
// Field (17) 'BlockAccessListRoot'
if size := len(e.BlockAccessListRoot); size != 32 {
err = ssz.ErrBytesLengthFn("--.BlockAccessListRoot", size, 32)
return
}
hh.PutBytes(e.BlockAccessListRoot)
hh.Merkleize(indx)
return
}
// MarshalSSZ ssz marshals the ExecutionPayloadDenebAndBlobsBundle object
func (e *ExecutionPayloadDenebAndBlobsBundle) MarshalSSZ() ([]byte, error) {
return ssz.MarshalSSZ(e)

View File

@@ -1,6 +1,8 @@
package enginev1
import "github.com/OffchainLabs/prysm/v6/encoding/bytesutil"
import (
"github.com/OffchainLabs/prysm/v6/encoding/bytesutil"
)
type copier[T any] interface {
Copy() T
@@ -214,3 +216,57 @@ func (payload *ExecutionPayloadHeader) Copy() *ExecutionPayloadHeader {
TransactionsRoot: bytesutil.SafeCopyBytes(payload.TransactionsRoot),
}
}
// Copy -- Gloas
func (payload *ExecutionPayloadGloas) Copy() *ExecutionPayloadGloas {
if payload == nil {
return nil
}
return &ExecutionPayloadGloas{
ParentHash: bytesutil.SafeCopyBytes(payload.ParentHash),
FeeRecipient: bytesutil.SafeCopyBytes(payload.FeeRecipient),
StateRoot: bytesutil.SafeCopyBytes(payload.StateRoot),
ReceiptsRoot: bytesutil.SafeCopyBytes(payload.ReceiptsRoot),
LogsBloom: bytesutil.SafeCopyBytes(payload.LogsBloom),
PrevRandao: bytesutil.SafeCopyBytes(payload.PrevRandao),
BlockNumber: payload.BlockNumber,
GasLimit: payload.GasLimit,
GasUsed: payload.GasUsed,
Timestamp: payload.Timestamp,
ExtraData: bytesutil.SafeCopyBytes(payload.ExtraData),
BaseFeePerGas: bytesutil.SafeCopyBytes(payload.BaseFeePerGas),
BlockHash: bytesutil.SafeCopyBytes(payload.BlockHash),
Transactions: bytesutil.SafeCopy2dBytes(payload.Transactions),
Withdrawals: copySlice(payload.Withdrawals),
BlobGasUsed: payload.BlobGasUsed,
ExcessBlobGas: payload.ExcessBlobGas,
BlockAccessList: bytesutil.SafeCopyBytes(payload.BlockAccessList),
}
}
// Copy -- Gloas
func (payload *ExecutionPayloadHeaderGloas) Copy() *ExecutionPayloadHeaderGloas {
if payload == nil {
return nil
}
return &ExecutionPayloadHeaderGloas{
ParentHash: bytesutil.SafeCopyBytes(payload.ParentHash),
FeeRecipient: bytesutil.SafeCopyBytes(payload.FeeRecipient),
StateRoot: bytesutil.SafeCopyBytes(payload.StateRoot),
ReceiptsRoot: bytesutil.SafeCopyBytes(payload.ReceiptsRoot),
LogsBloom: bytesutil.SafeCopyBytes(payload.LogsBloom),
PrevRandao: bytesutil.SafeCopyBytes(payload.PrevRandao),
BlockNumber: payload.BlockNumber,
GasLimit: payload.GasLimit,
GasUsed: payload.GasUsed,
Timestamp: payload.Timestamp,
ExtraData: bytesutil.SafeCopyBytes(payload.ExtraData),
BaseFeePerGas: bytesutil.SafeCopyBytes(payload.BaseFeePerGas),
BlockHash: bytesutil.SafeCopyBytes(payload.BlockHash),
TransactionsRoot: bytesutil.SafeCopyBytes(payload.TransactionsRoot),
WithdrawalsRoot: bytesutil.SafeCopyBytes(payload.WithdrawalsRoot),
BlobGasUsed: payload.BlobGasUsed,
ExcessBlobGas: payload.ExcessBlobGas,
BlockAccessListRoot: bytesutil.SafeCopyBytes(payload.BlockAccessListRoot),
}
}

File diff suppressed because it is too large Load Diff

View File

@@ -92,6 +92,53 @@ message ExecutionPayloadDeneb {
uint64 excess_blob_gas = 17;
}
message ExecutionPayloadGloas {
bytes parent_hash = 1 [ (ethereum.eth.ext.ssz_size) = "32" ];
bytes fee_recipient = 2 [ (ethereum.eth.ext.ssz_size) = "20" ];
bytes state_root = 3 [ (ethereum.eth.ext.ssz_size) = "32" ];
bytes receipts_root = 4 [ (ethereum.eth.ext.ssz_size) = "32" ];
bytes logs_bloom = 5 [ (ethereum.eth.ext.ssz_size) = "logs_bloom.size" ];
bytes prev_randao = 6 [ (ethereum.eth.ext.ssz_size) = "32" ];
uint64 block_number = 7;
uint64 gas_limit = 8;
uint64 gas_used = 9;
uint64 timestamp = 10;
bytes extra_data = 11 [ (ethereum.eth.ext.ssz_max) = "extra_data.size" ];
bytes base_fee_per_gas = 12 [ (ethereum.eth.ext.ssz_size) = "32" ];
bytes block_hash = 13 [ (ethereum.eth.ext.ssz_size) = "32" ];
repeated bytes transactions = 14 [
(ethereum.eth.ext.ssz_size) = "?,?",
(ethereum.eth.ext.ssz_max) = "1048576,1073741824"
];
// MAX_WITHDRAWALS_PER_PAYLOAD
repeated Withdrawal withdrawals = 15
[ (ethereum.eth.ext.ssz_max) = "withdrawal.size" ];
uint64 blob_gas_used = 16;
uint64 excess_blob_gas = 17;
bytes block_access_list = 18 [ (ethereum.eth.ext.ssz_max) = "1073741824" ];
}
message ExecutionPayloadHeaderGloas {
bytes parent_hash = 1 [ (ethereum.eth.ext.ssz_size) = "32" ];
bytes fee_recipient = 2 [ (ethereum.eth.ext.ssz_size) = "20" ];
bytes state_root = 3 [ (ethereum.eth.ext.ssz_size) = "32" ];
bytes receipts_root = 4 [ (ethereum.eth.ext.ssz_size) = "32" ];
bytes logs_bloom = 5 [ (ethereum.eth.ext.ssz_size) = "logs_bloom.size" ];
bytes prev_randao = 6 [ (ethereum.eth.ext.ssz_size) = "32" ];
uint64 block_number = 7;
uint64 gas_limit = 8;
uint64 gas_used = 9;
uint64 timestamp = 10;
bytes extra_data = 11 [ (ethereum.eth.ext.ssz_max) = "extra_data.size" ];
bytes base_fee_per_gas = 12 [ (ethereum.eth.ext.ssz_size) = "32" ];
bytes block_hash = 13 [ (ethereum.eth.ext.ssz_size) = "32" ];
bytes transactions_root = 14 [ (ethereum.eth.ext.ssz_size) = "32" ];
bytes withdrawals_root = 15 [ (ethereum.eth.ext.ssz_size) = "32" ];
uint64 blob_gas_used = 16;
uint64 excess_blob_gas = 17;
bytes block_access_list_root = 18 [ (ethereum.eth.ext.ssz_size) = "32" ];
}
message ExecutionPayloadCapellaWithValue {
ExecutionPayloadCapella payload = 1;
bytes value = 2;

43
proto/engine/v1/gloas.go Normal file
View File

@@ -0,0 +1,43 @@
package enginev1
import (
"github.com/pkg/errors"
)
func (ebe *ExecutionBundleGloas) GetDecodedExecutionRequests(limits ExecutionRequestLimits) (*ExecutionRequests, error) {
requests := &ExecutionRequests{}
var prevTypeNum *uint8
for i := range ebe.ExecutionRequests {
requestType, requestListInSSZBytes, err := decodeExecutionRequest(ebe.ExecutionRequests[i])
if err != nil {
return nil, err
}
if prevTypeNum != nil && *prevTypeNum >= requestType {
return nil, errors.New("invalid execution request type order or duplicate requests, requests should be in sorted order and unique")
}
prevTypeNum = &requestType
switch requestType {
case DepositRequestType:
drs, err := unmarshalDeposits(requestListInSSZBytes, limits.Deposits)
if err != nil {
return nil, err
}
requests.Deposits = drs
case WithdrawalRequestType:
wrs, err := unmarshalWithdrawals(requestListInSSZBytes, limits.Withdrawals)
if err != nil {
return nil, err
}
requests.Withdrawals = wrs
case ConsolidationRequestType:
crs, err := unmarshalConsolidations(requestListInSSZBytes, limits.Consolidations)
if err != nil {
return nil, err
}
requests.Consolidations = crs
default:
return nil, errors.Errorf("unsupported request type %d", requestType)
}
}
return requests, nil
}

191
proto/engine/v1/gloas.pb.go generated Executable file
View File

@@ -0,0 +1,191 @@
// Code generated by protoc-gen-go. DO NOT EDIT.
// versions:
// protoc-gen-go v1.36.3
// protoc v3.21.7
// source: proto/engine/v1/gloas.proto
package enginev1
import (
reflect "reflect"
sync "sync"
protoreflect "google.golang.org/protobuf/reflect/protoreflect"
protoimpl "google.golang.org/protobuf/runtime/protoimpl"
)
const (
// Verify that this generated code is sufficiently up-to-date.
_ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion)
// Verify that runtime/protoimpl is sufficiently up-to-date.
_ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20)
)
type ExecutionBundleGloas struct {
state protoimpl.MessageState `protogen:"open.v1"`
Payload *ExecutionPayloadGloas `protobuf:"bytes,1,opt,name=payload,proto3" json:"payload,omitempty"`
Value []byte `protobuf:"bytes,2,opt,name=value,proto3" json:"value,omitempty"`
BlobsBundle *BlobsBundleV2 `protobuf:"bytes,3,opt,name=blobs_bundle,json=blobsBundle,proto3" json:"blobs_bundle,omitempty"`
ShouldOverrideBuilder bool `protobuf:"varint,4,opt,name=should_override_builder,json=shouldOverrideBuilder,proto3" json:"should_override_builder,omitempty"`
ExecutionRequests [][]byte `protobuf:"bytes,5,rep,name=execution_requests,json=executionRequests,proto3" json:"execution_requests,omitempty"`
unknownFields protoimpl.UnknownFields
sizeCache protoimpl.SizeCache
}
func (x *ExecutionBundleGloas) Reset() {
*x = ExecutionBundleGloas{}
mi := &file_proto_engine_v1_gloas_proto_msgTypes[0]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
func (x *ExecutionBundleGloas) String() string {
return protoimpl.X.MessageStringOf(x)
}
func (*ExecutionBundleGloas) ProtoMessage() {}
func (x *ExecutionBundleGloas) ProtoReflect() protoreflect.Message {
mi := &file_proto_engine_v1_gloas_proto_msgTypes[0]
if x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
ms.StoreMessageInfo(mi)
}
return ms
}
return mi.MessageOf(x)
}
// Deprecated: Use ExecutionBundleGloas.ProtoReflect.Descriptor instead.
func (*ExecutionBundleGloas) Descriptor() ([]byte, []int) {
return file_proto_engine_v1_gloas_proto_rawDescGZIP(), []int{0}
}
func (x *ExecutionBundleGloas) GetPayload() *ExecutionPayloadGloas {
if x != nil {
return x.Payload
}
return nil
}
func (x *ExecutionBundleGloas) GetValue() []byte {
if x != nil {
return x.Value
}
return nil
}
func (x *ExecutionBundleGloas) GetBlobsBundle() *BlobsBundleV2 {
if x != nil {
return x.BlobsBundle
}
return nil
}
func (x *ExecutionBundleGloas) GetShouldOverrideBuilder() bool {
if x != nil {
return x.ShouldOverrideBuilder
}
return false
}
func (x *ExecutionBundleGloas) GetExecutionRequests() [][]byte {
if x != nil {
return x.ExecutionRequests
}
return nil
}
var File_proto_engine_v1_gloas_proto protoreflect.FileDescriptor
var file_proto_engine_v1_gloas_proto_rawDesc = []byte{
0x0a, 0x1b, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2f, 0x65, 0x6e, 0x67, 0x69, 0x6e, 0x65, 0x2f, 0x76,
0x31, 0x2f, 0x67, 0x6c, 0x6f, 0x61, 0x73, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x12, 0x12, 0x65,
0x74, 0x68, 0x65, 0x72, 0x65, 0x75, 0x6d, 0x2e, 0x65, 0x6e, 0x67, 0x69, 0x6e, 0x65, 0x2e, 0x76,
0x31, 0x1a, 0x26, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2f, 0x65, 0x6e, 0x67, 0x69, 0x6e, 0x65, 0x2f,
0x76, 0x31, 0x2f, 0x65, 0x78, 0x65, 0x63, 0x75, 0x74, 0x69, 0x6f, 0x6e, 0x5f, 0x65, 0x6e, 0x67,
0x69, 0x6e, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22, 0x9e, 0x02, 0x0a, 0x14, 0x45, 0x78,
0x65, 0x63, 0x75, 0x74, 0x69, 0x6f, 0x6e, 0x42, 0x75, 0x6e, 0x64, 0x6c, 0x65, 0x47, 0x6c, 0x6f,
0x61, 0x73, 0x12, 0x43, 0x0a, 0x07, 0x70, 0x61, 0x79, 0x6c, 0x6f, 0x61, 0x64, 0x18, 0x01, 0x20,
0x01, 0x28, 0x0b, 0x32, 0x29, 0x2e, 0x65, 0x74, 0x68, 0x65, 0x72, 0x65, 0x75, 0x6d, 0x2e, 0x65,
0x6e, 0x67, 0x69, 0x6e, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x45, 0x78, 0x65, 0x63, 0x75, 0x74, 0x69,
0x6f, 0x6e, 0x50, 0x61, 0x79, 0x6c, 0x6f, 0x61, 0x64, 0x47, 0x6c, 0x6f, 0x61, 0x73, 0x52, 0x07,
0x70, 0x61, 0x79, 0x6c, 0x6f, 0x61, 0x64, 0x12, 0x14, 0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65,
0x18, 0x02, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x12, 0x44, 0x0a,
0x0c, 0x62, 0x6c, 0x6f, 0x62, 0x73, 0x5f, 0x62, 0x75, 0x6e, 0x64, 0x6c, 0x65, 0x18, 0x03, 0x20,
0x01, 0x28, 0x0b, 0x32, 0x21, 0x2e, 0x65, 0x74, 0x68, 0x65, 0x72, 0x65, 0x75, 0x6d, 0x2e, 0x65,
0x6e, 0x67, 0x69, 0x6e, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x42, 0x6c, 0x6f, 0x62, 0x73, 0x42, 0x75,
0x6e, 0x64, 0x6c, 0x65, 0x56, 0x32, 0x52, 0x0b, 0x62, 0x6c, 0x6f, 0x62, 0x73, 0x42, 0x75, 0x6e,
0x64, 0x6c, 0x65, 0x12, 0x36, 0x0a, 0x17, 0x73, 0x68, 0x6f, 0x75, 0x6c, 0x64, 0x5f, 0x6f, 0x76,
0x65, 0x72, 0x72, 0x69, 0x64, 0x65, 0x5f, 0x62, 0x75, 0x69, 0x6c, 0x64, 0x65, 0x72, 0x18, 0x04,
0x20, 0x01, 0x28, 0x08, 0x52, 0x15, 0x73, 0x68, 0x6f, 0x75, 0x6c, 0x64, 0x4f, 0x76, 0x65, 0x72,
0x72, 0x69, 0x64, 0x65, 0x42, 0x75, 0x69, 0x6c, 0x64, 0x65, 0x72, 0x12, 0x2d, 0x0a, 0x12, 0x65,
0x78, 0x65, 0x63, 0x75, 0x74, 0x69, 0x6f, 0x6e, 0x5f, 0x72, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74,
0x73, 0x18, 0x05, 0x20, 0x03, 0x28, 0x0c, 0x52, 0x11, 0x65, 0x78, 0x65, 0x63, 0x75, 0x74, 0x69,
0x6f, 0x6e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x73, 0x42, 0x8c, 0x01, 0x0a, 0x16, 0x6f,
0x72, 0x67, 0x2e, 0x65, 0x74, 0x68, 0x65, 0x72, 0x65, 0x75, 0x6d, 0x2e, 0x65, 0x6e, 0x67, 0x69,
0x6e, 0x65, 0x2e, 0x76, 0x31, 0x42, 0x0a, 0x47, 0x6c, 0x6f, 0x61, 0x73, 0x50, 0x72, 0x6f, 0x74,
0x6f, 0x50, 0x01, 0x5a, 0x3a, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f,
0x70, 0x72, 0x79, 0x73, 0x6d, 0x61, 0x74, 0x69, 0x63, 0x6c, 0x61, 0x62, 0x73, 0x2f, 0x70, 0x72,
0x79, 0x73, 0x6d, 0x2f, 0x76, 0x35, 0x2f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2f, 0x65, 0x6e, 0x67,
0x69, 0x6e, 0x65, 0x2f, 0x76, 0x31, 0x3b, 0x65, 0x6e, 0x67, 0x69, 0x6e, 0x65, 0x76, 0x31, 0xaa,
0x02, 0x12, 0x45, 0x74, 0x68, 0x65, 0x72, 0x65, 0x75, 0x6d, 0x2e, 0x45, 0x6e, 0x67, 0x69, 0x6e,
0x65, 0x2e, 0x56, 0x31, 0xca, 0x02, 0x12, 0x45, 0x74, 0x68, 0x65, 0x72, 0x65, 0x75, 0x6d, 0x5c,
0x45, 0x6e, 0x67, 0x69, 0x6e, 0x65, 0x5c, 0x76, 0x31, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f,
0x33,
}
var (
file_proto_engine_v1_gloas_proto_rawDescOnce sync.Once
file_proto_engine_v1_gloas_proto_rawDescData = file_proto_engine_v1_gloas_proto_rawDesc
)
func file_proto_engine_v1_gloas_proto_rawDescGZIP() []byte {
file_proto_engine_v1_gloas_proto_rawDescOnce.Do(func() {
file_proto_engine_v1_gloas_proto_rawDescData = protoimpl.X.CompressGZIP(file_proto_engine_v1_gloas_proto_rawDescData)
})
return file_proto_engine_v1_gloas_proto_rawDescData
}
var file_proto_engine_v1_gloas_proto_msgTypes = make([]protoimpl.MessageInfo, 1)
var file_proto_engine_v1_gloas_proto_goTypes = []any{
(*ExecutionBundleGloas)(nil), // 0: ethereum.engine.v1.ExecutionBundleGloas
(*ExecutionPayloadGloas)(nil), // 1: ethereum.engine.v1.ExecutionPayloadGloas
(*BlobsBundleV2)(nil), // 2: ethereum.engine.v1.BlobsBundleV2
}
var file_proto_engine_v1_gloas_proto_depIdxs = []int32{
1, // 0: ethereum.engine.v1.ExecutionBundleGloas.payload:type_name -> ethereum.engine.v1.ExecutionPayloadGloas
2, // 1: ethereum.engine.v1.ExecutionBundleGloas.blobs_bundle:type_name -> ethereum.engine.v1.BlobsBundleV2
2, // [2:2] is the sub-list for method output_type
2, // [2:2] is the sub-list for method input_type
2, // [2:2] is the sub-list for extension type_name
2, // [2:2] is the sub-list for extension extendee
0, // [0:2] is the sub-list for field type_name
}
func init() { file_proto_engine_v1_gloas_proto_init() }
func file_proto_engine_v1_gloas_proto_init() {
if File_proto_engine_v1_gloas_proto != nil {
return
}
file_proto_engine_v1_execution_engine_proto_init()
type x struct{}
out := protoimpl.TypeBuilder{
File: protoimpl.DescBuilder{
GoPackagePath: reflect.TypeOf(x{}).PkgPath(),
RawDescriptor: file_proto_engine_v1_gloas_proto_rawDesc,
NumEnums: 0,
NumMessages: 1,
NumExtensions: 0,
NumServices: 0,
},
GoTypes: file_proto_engine_v1_gloas_proto_goTypes,
DependencyIndexes: file_proto_engine_v1_gloas_proto_depIdxs,
MessageInfos: file_proto_engine_v1_gloas_proto_msgTypes,
}.Build()
File_proto_engine_v1_gloas_proto = out.File
file_proto_engine_v1_gloas_proto_rawDesc = nil
file_proto_engine_v1_gloas_proto_goTypes = nil
file_proto_engine_v1_gloas_proto_depIdxs = nil
}

View File

@@ -0,0 +1,20 @@
syntax = "proto3";
package ethereum.engine.v1;
import "proto/engine/v1/execution_engine.proto";
option csharp_namespace = "Ethereum.Engine.V1";
option go_package = "github.com/prysmaticlabs/prysm/v5/proto/engine/v1;enginev1";
option java_multiple_files = true;
option java_outer_classname = "GloasProto";
option java_package = "org.ethereum.engine.v1";
option php_namespace = "Ethereum\\Engine\\v1";
message ExecutionBundleGloas {
ExecutionPayloadGloas payload = 1;
bytes value = 2;
BlobsBundleV2 blobs_bundle = 3;
bool should_override_builder = 4;
repeated bytes execution_requests = 5;
}

View File

@@ -313,6 +313,14 @@ type GetPayloadV5ResponseJson struct {
ExecutionRequests []hexutil.Bytes `json:"executionRequests"`
}
type GetPayloadV6ResponseJson struct {
ExecutionPayload *ExecutionPayloadGloasJSON `json:"executionPayload"`
BlockValue string `json:"blockValue"`
BlobsBundle *BlobBundleV2JSON `json:"blobsBundle"`
ShouldOverrideBuilder bool `json:"shouldOverrideBuilder"`
ExecutionRequests []hexutil.Bytes `json:"executionRequests"`
}
// ExecutionPayloadBody represents the engine API ExecutionPayloadV1 or ExecutionPayloadV2 type.
type ExecutionPayloadBody struct {
Transactions []hexutil.Bytes `json:"transactions"`
@@ -342,6 +350,27 @@ type ExecutionPayloadDenebJSON struct {
Withdrawals []*Withdrawal `json:"withdrawals"`
}
type ExecutionPayloadGloasJSON struct {
ParentHash *common.Hash `json:"parentHash"`
FeeRecipient *common.Address `json:"feeRecipient"`
StateRoot *common.Hash `json:"stateRoot"`
ReceiptsRoot *common.Hash `json:"receiptsRoot"`
LogsBloom *hexutil.Bytes `json:"logsBloom"`
PrevRandao *common.Hash `json:"prevRandao"`
BlockNumber *hexutil.Uint64 `json:"blockNumber"`
GasLimit *hexutil.Uint64 `json:"gasLimit"`
GasUsed *hexutil.Uint64 `json:"gasUsed"`
Timestamp *hexutil.Uint64 `json:"timestamp"`
ExtraData hexutil.Bytes `json:"extraData"`
BaseFeePerGas string `json:"baseFeePerGas"`
BlobGasUsed *hexutil.Uint64 `json:"blobGasUsed"`
ExcessBlobGas *hexutil.Uint64 `json:"excessBlobGas"`
BlockHash *common.Hash `json:"blockHash"`
Transactions []hexutil.Bytes `json:"transactions"`
Withdrawals []*Withdrawal `json:"withdrawals"`
BlockAccessList *hexutil.Bytes `json:"blockAccessList"`
}
// WithdrawalRequestV1 represents an execution engine WithdrawalRequestV1 value
// https://github.com/ethereum/execution-apis/blob/main/src/engine/prague.md#withdrawalrequestv1
type WithdrawalRequestV1 struct {
@@ -912,6 +941,54 @@ func (e *ExecutionPayloadDeneb) MarshalJSON() ([]byte, error) {
})
}
func (e *ExecutionPayloadGloas) MarshalJSON() ([]byte, error) {
transactions := make([]hexutil.Bytes, len(e.Transactions))
for i, tx := range e.Transactions {
transactions[i] = tx
}
baseFee := new(big.Int).SetBytes(bytesutil.ReverseByteOrder(e.BaseFeePerGas))
baseFeeHex := hexutil.EncodeBig(baseFee)
pHash := common.BytesToHash(e.ParentHash)
sRoot := common.BytesToHash(e.StateRoot)
recRoot := common.BytesToHash(e.ReceiptsRoot)
prevRan := common.BytesToHash(e.PrevRandao)
bHash := common.BytesToHash(e.BlockHash)
blockNum := hexutil.Uint64(e.BlockNumber)
gasLimit := hexutil.Uint64(e.GasLimit)
gasUsed := hexutil.Uint64(e.GasUsed)
timeStamp := hexutil.Uint64(e.Timestamp)
recipient := common.BytesToAddress(e.FeeRecipient)
logsBloom := hexutil.Bytes(e.LogsBloom)
withdrawals := e.Withdrawals
if withdrawals == nil {
withdrawals = make([]*Withdrawal, 0)
}
blobGasUsed := hexutil.Uint64(e.BlobGasUsed)
excessBlobGas := hexutil.Uint64(e.ExcessBlobGas)
blockAccessList := hexutil.Bytes(e.BlockAccessList)
return json.Marshal(ExecutionPayloadGloasJSON{
ParentHash: &pHash,
FeeRecipient: &recipient,
StateRoot: &sRoot,
ReceiptsRoot: &recRoot,
LogsBloom: &logsBloom,
PrevRandao: &prevRan,
BlockNumber: &blockNum,
GasLimit: &gasLimit,
GasUsed: &gasUsed,
Timestamp: &timeStamp,
ExtraData: e.ExtraData,
BaseFeePerGas: baseFeeHex,
BlobGasUsed: &blobGasUsed,
ExcessBlobGas: &excessBlobGas,
BlockHash: &bHash,
Transactions: transactions,
Withdrawals: withdrawals,
BlockAccessList: &blockAccessList,
})
}
func JsonDepositRequestsToProto(j []DepositRequestV1) ([]*DepositRequest, error) {
reqs := make([]*DepositRequest, len(j))
@@ -1409,6 +1486,141 @@ func (e *ExecutionBundleFulu) UnmarshalJSON(enc []byte) error {
return nil
}
func (e *ExecutionBundleGloas) UnmarshalJSON(enc []byte) error {
dec := GetPayloadV6ResponseJson{}
if err := json.Unmarshal(enc, &dec); err != nil {
return err
}
if dec.ExecutionPayload == nil || dec.ExecutionPayload.ParentHash == nil {
return errors.New("missing required field 'parentHash' for ExecutionPayload")
}
if dec.ExecutionPayload.FeeRecipient == nil {
return errors.New("missing required field 'feeRecipient' for ExecutionPayload")
}
if dec.ExecutionPayload.StateRoot == nil {
return errors.New("missing required field 'stateRoot' for ExecutionPayload")
}
if dec.ExecutionPayload.ReceiptsRoot == nil {
return errors.New("missing required field 'receiptsRoot' for ExecutableDataV1")
}
if dec.ExecutionPayload.LogsBloom == nil {
return errors.New("missing required field 'logsBloom' for ExecutionPayload")
}
if dec.ExecutionPayload.PrevRandao == nil {
return errors.New("missing required field 'prevRandao' for ExecutionPayload")
}
if dec.ExecutionPayload.ExtraData == nil {
return errors.New("missing required field 'extraData' for ExecutionPayload")
}
if dec.ExecutionPayload.BlockHash == nil {
return errors.New("missing required field 'blockHash' for ExecutionPayload")
}
if dec.ExecutionPayload.Transactions == nil {
return errors.New("missing required field 'transactions' for ExecutionPayload")
}
if dec.ExecutionPayload.BlockNumber == nil {
return errors.New("missing required field 'blockNumber' for ExecutionPayload")
}
if dec.ExecutionPayload.Timestamp == nil {
return errors.New("missing required field 'timestamp' for ExecutionPayload")
}
if dec.ExecutionPayload.GasUsed == nil {
return errors.New("missing required field 'gasUsed' for ExecutionPayload")
}
if dec.ExecutionPayload.GasLimit == nil {
return errors.New("missing required field 'gasLimit' for ExecutionPayload")
}
if dec.ExecutionPayload.BlobGasUsed == nil {
return errors.New("missing required field 'blobGasUsed' for ExecutionPayload")
}
if dec.ExecutionPayload.ExcessBlobGas == nil {
return errors.New("missing required field 'excessBlobGas' for ExecutionPayload")
}
if dec.ExecutionPayload.BlockAccessList == nil {
return errors.New("missing required field 'blockAccessList' for ExecutionPayload")
}
*e = ExecutionBundleGloas{Payload: &ExecutionPayloadGloas{}}
e.Payload.ParentHash = dec.ExecutionPayload.ParentHash.Bytes()
e.Payload.FeeRecipient = dec.ExecutionPayload.FeeRecipient.Bytes()
e.Payload.StateRoot = dec.ExecutionPayload.StateRoot.Bytes()
e.Payload.ReceiptsRoot = dec.ExecutionPayload.ReceiptsRoot.Bytes()
e.Payload.LogsBloom = *dec.ExecutionPayload.LogsBloom
e.Payload.PrevRandao = dec.ExecutionPayload.PrevRandao.Bytes()
e.Payload.BlockNumber = uint64(*dec.ExecutionPayload.BlockNumber)
e.Payload.GasLimit = uint64(*dec.ExecutionPayload.GasLimit)
e.Payload.GasUsed = uint64(*dec.ExecutionPayload.GasUsed)
e.Payload.Timestamp = uint64(*dec.ExecutionPayload.Timestamp)
e.Payload.ExtraData = dec.ExecutionPayload.ExtraData
baseFee, err := hexutil.DecodeBig(dec.ExecutionPayload.BaseFeePerGas)
if err != nil {
return err
}
e.Payload.BaseFeePerGas = bytesutil.PadTo(bytesutil.ReverseByteOrder(baseFee.Bytes()), fieldparams.RootLength)
e.Payload.ExcessBlobGas = uint64(*dec.ExecutionPayload.ExcessBlobGas)
e.Payload.BlobGasUsed = uint64(*dec.ExecutionPayload.BlobGasUsed)
e.Payload.BlockHash = dec.ExecutionPayload.BlockHash.Bytes()
txs := make([][]byte, len(dec.ExecutionPayload.Transactions))
for i, tx := range dec.ExecutionPayload.Transactions {
txs[i] = tx
}
e.Payload.Transactions = txs
if dec.ExecutionPayload.Withdrawals == nil {
dec.ExecutionPayload.Withdrawals = make([]*Withdrawal, 0)
}
e.Payload.Withdrawals = dec.ExecutionPayload.Withdrawals
e.Payload.BlockAccessList = *dec.ExecutionPayload.BlockAccessList
v, err := hexutil.DecodeBig(dec.BlockValue)
if err != nil {
return err
}
e.Value = bytesutil.PadTo(bytesutil.ReverseByteOrder(v.Bytes()), fieldparams.RootLength)
if dec.BlobsBundle != nil {
e.BlobsBundle = &BlobsBundleV2{}
commitments := make([][]byte, len(dec.BlobsBundle.Commitments))
for i, kzg := range dec.BlobsBundle.Commitments {
k := kzg
commitments[i] = bytesutil.PadTo(k[:], fieldparams.BLSPubkeyLength)
}
e.BlobsBundle.KzgCommitments = commitments
proofs := make([][]byte, len(dec.BlobsBundle.Proofs))
for i, proof := range dec.BlobsBundle.Proofs {
p := proof
proofs[i] = bytesutil.PadTo(p[:], fieldparams.BLSPubkeyLength)
}
e.BlobsBundle.Proofs = proofs
blobs := make([][]byte, len(dec.BlobsBundle.Blobs))
for i, blob := range dec.BlobsBundle.Blobs {
b := make([]byte, fieldparams.BlobLength)
copy(b, blob)
blobs[i] = b
}
e.BlobsBundle.Blobs = blobs
}
e.ShouldOverrideBuilder = dec.ShouldOverrideBuilder
reqs := make([][]byte, len(dec.ExecutionRequests))
for i, r := range dec.ExecutionRequests {
b := make([]byte, len(r))
copy(b, r)
reqs[i] = b
}
e.ExecutionRequests = reqs
return nil
}
// RecastHexutilByteSlice converts a []hexutil.Bytes to a [][]byte
func RecastHexutilByteSlice(h []hexutil.Bytes) [][]byte {
r := make([][]byte, len(h))

View File

@@ -194,6 +194,15 @@ ssz_fulu_objs = [
"SignedBlindedBeaconBlockFulu",
]
ssz_gloas_objs = [
"BeaconBlockBodyGloas",
"BeaconBlockContentsGloas",
"BeaconBlockGloas",
"BeaconStateGloas",
"SignedBeaconBlockContentsGloas",
"SignedBeaconBlockGloas",
]
ssz_gen_marshal(
name = "ssz_generated_phase0",
out = "phase0.ssz.go",
@@ -284,6 +293,19 @@ ssz_gen_marshal(
objs = ssz_fulu_objs,
)
ssz_gen_marshal(
name = "ssz_generated_gloas",
out = "gloas.ssz.go",
exclude_objs = ssz_phase0_objs + ssz_altair_objs + ssz_bellatrix_objs + ssz_capella_objs + ssz_deneb_objs + ssz_electra_objs + ssz_fulu_objs,
go_proto = ":go_proto",
includes = [
"//consensus-types/primitives:go_default_library",
"//math:go_default_library",
"//proto/engine/v1:go_default_library",
],
objs = ssz_gloas_objs,
)
ssz_gen_marshal(
name = "ssz_generated_non_core",
out = "non-core.ssz.go",
@@ -352,6 +374,7 @@ go_library(
":ssz_generated_deneb", # keep
":ssz_generated_electra", # keep
":ssz_generated_fulu", # keep
":ssz_generated_gloas", # keep
":ssz_generated_non_core", # keep
":ssz_generated_phase0", # keep
],

View File

@@ -695,3 +695,54 @@ func (sigBlock *SignedBeaconBlockFulu) Copy() *SignedBeaconBlockFulu {
Signature: bytesutil.SafeCopyBytes(sigBlock.Signature),
}
}
// ----------------------------------------------------------------------------
// Gloas
// ----------------------------------------------------------------------------
// Copy --
func (sigBlock *SignedBeaconBlockGloas) Copy() *SignedBeaconBlockGloas {
if sigBlock == nil {
return nil
}
return &SignedBeaconBlockGloas{
Block: sigBlock.Block.Copy(),
Signature: bytesutil.SafeCopyBytes(sigBlock.Signature),
}
}
// Copy --
func (block *BeaconBlockGloas) Copy() *BeaconBlockGloas {
if block == nil {
return nil
}
return &BeaconBlockGloas{
Slot: block.Slot,
ProposerIndex: block.ProposerIndex,
ParentRoot: bytesutil.SafeCopyBytes(block.ParentRoot),
StateRoot: bytesutil.SafeCopyBytes(block.StateRoot),
Body: block.Body.Copy(),
}
}
// Copy --
func (body *BeaconBlockBodyGloas) Copy() *BeaconBlockBodyGloas {
if body == nil {
return nil
}
return &BeaconBlockBodyGloas{
RandaoReveal: bytesutil.SafeCopyBytes(body.RandaoReveal),
Eth1Data: body.Eth1Data.Copy(),
Graffiti: bytesutil.SafeCopyBytes(body.Graffiti),
ProposerSlashings: CopySlice(body.ProposerSlashings),
AttesterSlashings: CopySlice(body.AttesterSlashings),
Attestations: CopySlice(body.Attestations),
Deposits: CopySlice(body.Deposits),
VoluntaryExits: CopySlice(body.VoluntaryExits),
SyncAggregate: body.SyncAggregate.Copy(),
ExecutionPayload: body.ExecutionPayload.Copy(),
BlsToExecutionChanges: CopySlice(body.BlsToExecutionChanges),
BlobKzgCommitments: CopyBlobKZGs(body.BlobKzgCommitments),
ExecutionRequests: CopyExecutionRequests(body.ExecutionRequests),
}
}

File diff suppressed because it is too large Load Diff

View File

@@ -72,6 +72,8 @@ message GenericSignedBeaconBlock {
// Representing a signed, post-Fulu fork blinded beacon block.
SignedBlindedBeaconBlockFulu blinded_fulu = 12;
// Representing a signed, post-Gloas fork beacon block content.
SignedBeaconBlockContentsGloas gloas = 13;
}
bool is_blinded = 100;
reserved 101; // Deprecated fields
@@ -116,6 +118,8 @@ message GenericBeaconBlock {
// Representing a post-Fulu fork blinded beacon block.
BlindedBeaconBlockFulu blinded_fulu = 12;
// Representing a post-Gloas fork beacon block content.
BeaconBlockContentsGloas gloas = 13;
}
bool is_blinded = 100;
string payload_value = 101;
@@ -1107,3 +1111,95 @@ message BlindedBeaconBlockFulu {
// The blinded beacon block body.
BlindedBeaconBlockBodyElectra body = 5;
}
// Gloas structures
message BeaconBlockBodyGloas {
// The validators RANDAO reveal 96 byte value.
bytes randao_reveal = 1 [ (ethereum.eth.ext.ssz_size) = "96" ];
// A reference to the Ethereum 1.x chain.
Eth1Data eth1_data = 2;
// 32 byte field of arbitrary data. This field may contain any data and
// is not used for anything other than a fun message.
bytes graffiti = 3 [ (ethereum.eth.ext.ssz_size) = "32" ];
// Block operations
// Refer to spec constants at
// https://github.com/ethereum/consensus-specs/blob/master/specs/core/0_beacon-chain.md#max-operations-per-block
// At most MAX_PROPOSER_SLASHINGS.
repeated ProposerSlashing proposer_slashings = 4
[ (ethereum.eth.ext.ssz_max) = "16" ];
// At most MAX_ATTESTER_SLASHINGS_ELECTRA.
repeated AttesterSlashingElectra attester_slashings = 5
[ (ethereum.eth.ext.ssz_max) = "1" ];
// At most MAX_ATTESTATIONS_ELECTRA.
repeated AttestationElectra attestations = 6
[ (ethereum.eth.ext.ssz_max) = "8" ];
// At most MAX_DEPOSITS.
repeated Deposit deposits = 7 [ (ethereum.eth.ext.ssz_max) = "16" ];
// At most MAX_VOLUNTARY_EXITS.
repeated SignedVoluntaryExit voluntary_exits = 8
[ (ethereum.eth.ext.ssz_max) = "16" ];
// Sync aggregate object for the beacon chain to track sync committee votes.
SyncAggregate sync_aggregate = 9;
// Execution payload from the execution chain. New in Gloas network
// upgrade.
ethereum.engine.v1.ExecutionPayloadGloas execution_payload = 10;
// At most MAX_BLS_TO_EXECUTION_CHANGES. New in Capella network upgrade.
repeated SignedBLSToExecutionChange bls_to_execution_changes = 11
[ (ethereum.eth.ext.ssz_max) = "16" ];
// Blob KZG commitments.
repeated bytes blob_kzg_commitments = 12 [
(ethereum.eth.ext.ssz_size) = "?,48",
(ethereum.eth.ext.ssz_max) = "max_blob_commitments.size"
];
ethereum.engine.v1.ExecutionRequests execution_requests = 13;
}
message BeaconBlockGloas {
// Beacon chain slot that this block represents.
uint64 slot = 1 [
(ethereum.eth.ext.cast_type) =
"github.com/OffchainLabs/prysm/v6/consensus-types/primitives.Slot"
];
// Validator index of the validator that proposed the block header.
uint64 proposer_index = 2 [ (ethereum.eth.ext.cast_type) =
"github.com/OffchainLabs/prysm/v6/"
"consensus-types/primitives.ValidatorIndex" ];
// 32 byte root of the parent block.
bytes parent_root = 3 [ (ethereum.eth.ext.ssz_size) = "32" ];
// 32 byte root of the resulting state after processing this block.
bytes state_root = 4 [ (ethereum.eth.ext.ssz_size) = "32" ];
// The beacon block body.
BeaconBlockBodyGloas body = 5;
}
message SignedBeaconBlockGloas {
// The unsigned beacon block itself.
BeaconBlockGloas block = 1;
// 96 byte BLS signature from the validator that produced this block.
bytes signature = 2 [ (ethereum.eth.ext.ssz_size) = "96" ];
}
message SignedBeaconBlockContentsGloas {
SignedBeaconBlockGloas block = 1;
repeated bytes kzg_proofs = 2 [
(ethereum.eth.ext.ssz_size) = "?,48",
(ethereum.eth.ext.ssz_max) = "max_cell_proofs_length.size"
];
repeated bytes blobs = 3 [
(ethereum.eth.ext.ssz_size) = "?,blob.size",
(ethereum.eth.ext.ssz_max) = "max_blob_commitments.size"
];
}
message BeaconBlockContentsGloas {
BeaconBlockGloas block = 1;
repeated bytes kzg_proofs = 2 [
(ethereum.eth.ext.ssz_size) = "?,48",
(ethereum.eth.ext.ssz_max) = "max_cell_proofs_length.size"
];
repeated bytes blobs = 3 [
(ethereum.eth.ext.ssz_size) = "?,blob.size",
(ethereum.eth.ext.ssz_max) = "max_blob_commitments.size"
];
}

View File

@@ -2409,6 +2409,346 @@ func (x *BeaconStateFulu) GetProposerLookahead() []uint64 {
return nil
}
type BeaconStateGloas struct {
state protoimpl.MessageState `protogen:"open.v1"`
GenesisTime uint64 `protobuf:"varint,1001,opt,name=genesis_time,json=genesisTime,proto3" json:"genesis_time,omitempty"`
GenesisValidatorsRoot []byte `protobuf:"bytes,1002,opt,name=genesis_validators_root,json=genesisValidatorsRoot,proto3" json:"genesis_validators_root,omitempty" ssz-size:"32"`
Slot github_com_OffchainLabs_prysm_v6_consensus_types_primitives.Slot `protobuf:"varint,1003,opt,name=slot,proto3" json:"slot,omitempty" cast-type:"github.com/OffchainLabs/prysm/v6/consensus-types/primitives.Slot"`
Fork *Fork `protobuf:"bytes,1004,opt,name=fork,proto3" json:"fork,omitempty"`
LatestBlockHeader *BeaconBlockHeader `protobuf:"bytes,2001,opt,name=latest_block_header,json=latestBlockHeader,proto3" json:"latest_block_header,omitempty"`
BlockRoots [][]byte `protobuf:"bytes,2002,rep,name=block_roots,json=blockRoots,proto3" json:"block_roots,omitempty" ssz-size:"8192,32"`
StateRoots [][]byte `protobuf:"bytes,2003,rep,name=state_roots,json=stateRoots,proto3" json:"state_roots,omitempty" ssz-size:"8192,32"`
HistoricalRoots [][]byte `protobuf:"bytes,2004,rep,name=historical_roots,json=historicalRoots,proto3" json:"historical_roots,omitempty" ssz-max:"16777216" ssz-size:"?,32"`
Eth1Data *Eth1Data `protobuf:"bytes,3001,opt,name=eth1_data,json=eth1Data,proto3" json:"eth1_data,omitempty"`
Eth1DataVotes []*Eth1Data `protobuf:"bytes,3002,rep,name=eth1_data_votes,json=eth1DataVotes,proto3" json:"eth1_data_votes,omitempty" ssz-max:"2048"`
Eth1DepositIndex uint64 `protobuf:"varint,3003,opt,name=eth1_deposit_index,json=eth1DepositIndex,proto3" json:"eth1_deposit_index,omitempty"`
Validators []*Validator `protobuf:"bytes,4001,rep,name=validators,proto3" json:"validators,omitempty" ssz-max:"1099511627776"`
Balances []uint64 `protobuf:"varint,4002,rep,packed,name=balances,proto3" json:"balances,omitempty" ssz-max:"1099511627776"`
RandaoMixes [][]byte `protobuf:"bytes,5001,rep,name=randao_mixes,json=randaoMixes,proto3" json:"randao_mixes,omitempty" ssz-size:"65536,32"`
Slashings []uint64 `protobuf:"varint,6001,rep,packed,name=slashings,proto3" json:"slashings,omitempty" ssz-size:"8192"`
PreviousEpochParticipation []byte `protobuf:"bytes,7001,opt,name=previous_epoch_participation,json=previousEpochParticipation,proto3" json:"previous_epoch_participation,omitempty" ssz-max:"1099511627776"`
CurrentEpochParticipation []byte `protobuf:"bytes,7002,opt,name=current_epoch_participation,json=currentEpochParticipation,proto3" json:"current_epoch_participation,omitempty" ssz-max:"1099511627776"`
JustificationBits github_com_prysmaticlabs_go_bitfield.Bitvector4 `protobuf:"bytes,8001,opt,name=justification_bits,json=justificationBits,proto3" json:"justification_bits,omitempty" cast-type:"github.com/prysmaticlabs/go-bitfield.Bitvector4" ssz-size:"1"`
PreviousJustifiedCheckpoint *Checkpoint `protobuf:"bytes,8002,opt,name=previous_justified_checkpoint,json=previousJustifiedCheckpoint,proto3" json:"previous_justified_checkpoint,omitempty"`
CurrentJustifiedCheckpoint *Checkpoint `protobuf:"bytes,8003,opt,name=current_justified_checkpoint,json=currentJustifiedCheckpoint,proto3" json:"current_justified_checkpoint,omitempty"`
FinalizedCheckpoint *Checkpoint `protobuf:"bytes,8004,opt,name=finalized_checkpoint,json=finalizedCheckpoint,proto3" json:"finalized_checkpoint,omitempty"`
InactivityScores []uint64 `protobuf:"varint,9001,rep,packed,name=inactivity_scores,json=inactivityScores,proto3" json:"inactivity_scores,omitempty" ssz-max:"1099511627776"`
CurrentSyncCommittee *SyncCommittee `protobuf:"bytes,9002,opt,name=current_sync_committee,json=currentSyncCommittee,proto3" json:"current_sync_committee,omitempty"`
NextSyncCommittee *SyncCommittee `protobuf:"bytes,9003,opt,name=next_sync_committee,json=nextSyncCommittee,proto3" json:"next_sync_committee,omitempty"`
LatestExecutionPayloadHeader *v1.ExecutionPayloadHeaderGloas `protobuf:"bytes,10001,opt,name=latest_execution_payload_header,json=latestExecutionPayloadHeader,proto3" json:"latest_execution_payload_header,omitempty"`
NextWithdrawalIndex uint64 `protobuf:"varint,11001,opt,name=next_withdrawal_index,json=nextWithdrawalIndex,proto3" json:"next_withdrawal_index,omitempty"`
NextWithdrawalValidatorIndex github_com_OffchainLabs_prysm_v6_consensus_types_primitives.ValidatorIndex `protobuf:"varint,11002,opt,name=next_withdrawal_validator_index,json=nextWithdrawalValidatorIndex,proto3" json:"next_withdrawal_validator_index,omitempty" cast-type:"github.com/OffchainLabs/prysm/v6/consensus-types/primitives.ValidatorIndex"`
HistoricalSummaries []*HistoricalSummary `protobuf:"bytes,11003,rep,name=historical_summaries,json=historicalSummaries,proto3" json:"historical_summaries,omitempty" ssz-max:"16777216"`
DepositRequestsStartIndex uint64 `protobuf:"varint,12001,opt,name=deposit_requests_start_index,json=depositRequestsStartIndex,proto3" json:"deposit_requests_start_index,omitempty"`
DepositBalanceToConsume github_com_OffchainLabs_prysm_v6_consensus_types_primitives.Gwei `protobuf:"varint,12002,opt,name=deposit_balance_to_consume,json=depositBalanceToConsume,proto3" json:"deposit_balance_to_consume,omitempty" cast-type:"github.com/OffchainLabs/prysm/v6/consensus-types/primitives.Gwei"`
ExitBalanceToConsume github_com_OffchainLabs_prysm_v6_consensus_types_primitives.Gwei `protobuf:"varint,12003,opt,name=exit_balance_to_consume,json=exitBalanceToConsume,proto3" json:"exit_balance_to_consume,omitempty" cast-type:"github.com/OffchainLabs/prysm/v6/consensus-types/primitives.Gwei"`
EarliestExitEpoch github_com_OffchainLabs_prysm_v6_consensus_types_primitives.Epoch `protobuf:"varint,12004,opt,name=earliest_exit_epoch,json=earliestExitEpoch,proto3" json:"earliest_exit_epoch,omitempty" cast-type:"github.com/OffchainLabs/prysm/v6/consensus-types/primitives.Epoch"`
ConsolidationBalanceToConsume github_com_OffchainLabs_prysm_v6_consensus_types_primitives.Gwei `protobuf:"varint,12005,opt,name=consolidation_balance_to_consume,json=consolidationBalanceToConsume,proto3" json:"consolidation_balance_to_consume,omitempty" cast-type:"github.com/OffchainLabs/prysm/v6/consensus-types/primitives.Gwei"`
EarliestConsolidationEpoch github_com_OffchainLabs_prysm_v6_consensus_types_primitives.Epoch `protobuf:"varint,12006,opt,name=earliest_consolidation_epoch,json=earliestConsolidationEpoch,proto3" json:"earliest_consolidation_epoch,omitempty" cast-type:"github.com/OffchainLabs/prysm/v6/consensus-types/primitives.Epoch"`
PendingDeposits []*PendingDeposit `protobuf:"bytes,12007,rep,name=pending_deposits,json=pendingDeposits,proto3" json:"pending_deposits,omitempty" ssz-max:"134217728"`
PendingPartialWithdrawals []*PendingPartialWithdrawal `protobuf:"bytes,12008,rep,name=pending_partial_withdrawals,json=pendingPartialWithdrawals,proto3" json:"pending_partial_withdrawals,omitempty" ssz-max:"134217728"`
PendingConsolidations []*PendingConsolidation `protobuf:"bytes,12009,rep,name=pending_consolidations,json=pendingConsolidations,proto3" json:"pending_consolidations,omitempty" ssz-max:"262144"`
ProposerLookahead []uint64 `protobuf:"varint,13001,rep,packed,name=proposer_lookahead,json=proposerLookahead,proto3" json:"proposer_lookahead,omitempty" ssz-size:"64"`
unknownFields protoimpl.UnknownFields
sizeCache protoimpl.SizeCache
}
func (x *BeaconStateGloas) Reset() {
*x = BeaconStateGloas{}
mi := &file_proto_prysm_v1alpha1_beacon_state_proto_msgTypes[16]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
func (x *BeaconStateGloas) String() string {
return protoimpl.X.MessageStringOf(x)
}
func (*BeaconStateGloas) ProtoMessage() {}
func (x *BeaconStateGloas) ProtoReflect() protoreflect.Message {
mi := &file_proto_prysm_v1alpha1_beacon_state_proto_msgTypes[16]
if x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
ms.StoreMessageInfo(mi)
}
return ms
}
return mi.MessageOf(x)
}
// Deprecated: Use BeaconStateGloas.ProtoReflect.Descriptor instead.
func (*BeaconStateGloas) Descriptor() ([]byte, []int) {
return file_proto_prysm_v1alpha1_beacon_state_proto_rawDescGZIP(), []int{16}
}
func (x *BeaconStateGloas) GetGenesisTime() uint64 {
if x != nil {
return x.GenesisTime
}
return 0
}
func (x *BeaconStateGloas) GetGenesisValidatorsRoot() []byte {
if x != nil {
return x.GenesisValidatorsRoot
}
return nil
}
func (x *BeaconStateGloas) GetSlot() github_com_OffchainLabs_prysm_v6_consensus_types_primitives.Slot {
if x != nil {
return x.Slot
}
return github_com_OffchainLabs_prysm_v6_consensus_types_primitives.Slot(0)
}
func (x *BeaconStateGloas) GetFork() *Fork {
if x != nil {
return x.Fork
}
return nil
}
func (x *BeaconStateGloas) GetLatestBlockHeader() *BeaconBlockHeader {
if x != nil {
return x.LatestBlockHeader
}
return nil
}
func (x *BeaconStateGloas) GetBlockRoots() [][]byte {
if x != nil {
return x.BlockRoots
}
return nil
}
func (x *BeaconStateGloas) GetStateRoots() [][]byte {
if x != nil {
return x.StateRoots
}
return nil
}
func (x *BeaconStateGloas) GetHistoricalRoots() [][]byte {
if x != nil {
return x.HistoricalRoots
}
return nil
}
func (x *BeaconStateGloas) GetEth1Data() *Eth1Data {
if x != nil {
return x.Eth1Data
}
return nil
}
func (x *BeaconStateGloas) GetEth1DataVotes() []*Eth1Data {
if x != nil {
return x.Eth1DataVotes
}
return nil
}
func (x *BeaconStateGloas) GetEth1DepositIndex() uint64 {
if x != nil {
return x.Eth1DepositIndex
}
return 0
}
func (x *BeaconStateGloas) GetValidators() []*Validator {
if x != nil {
return x.Validators
}
return nil
}
func (x *BeaconStateGloas) GetBalances() []uint64 {
if x != nil {
return x.Balances
}
return nil
}
func (x *BeaconStateGloas) GetRandaoMixes() [][]byte {
if x != nil {
return x.RandaoMixes
}
return nil
}
func (x *BeaconStateGloas) GetSlashings() []uint64 {
if x != nil {
return x.Slashings
}
return nil
}
func (x *BeaconStateGloas) GetPreviousEpochParticipation() []byte {
if x != nil {
return x.PreviousEpochParticipation
}
return nil
}
func (x *BeaconStateGloas) GetCurrentEpochParticipation() []byte {
if x != nil {
return x.CurrentEpochParticipation
}
return nil
}
func (x *BeaconStateGloas) GetJustificationBits() github_com_prysmaticlabs_go_bitfield.Bitvector4 {
if x != nil {
return x.JustificationBits
}
return github_com_prysmaticlabs_go_bitfield.Bitvector4(nil)
}
func (x *BeaconStateGloas) GetPreviousJustifiedCheckpoint() *Checkpoint {
if x != nil {
return x.PreviousJustifiedCheckpoint
}
return nil
}
func (x *BeaconStateGloas) GetCurrentJustifiedCheckpoint() *Checkpoint {
if x != nil {
return x.CurrentJustifiedCheckpoint
}
return nil
}
func (x *BeaconStateGloas) GetFinalizedCheckpoint() *Checkpoint {
if x != nil {
return x.FinalizedCheckpoint
}
return nil
}
func (x *BeaconStateGloas) GetInactivityScores() []uint64 {
if x != nil {
return x.InactivityScores
}
return nil
}
func (x *BeaconStateGloas) GetCurrentSyncCommittee() *SyncCommittee {
if x != nil {
return x.CurrentSyncCommittee
}
return nil
}
func (x *BeaconStateGloas) GetNextSyncCommittee() *SyncCommittee {
if x != nil {
return x.NextSyncCommittee
}
return nil
}
func (x *BeaconStateGloas) GetLatestExecutionPayloadHeader() *v1.ExecutionPayloadHeaderGloas {
if x != nil {
return x.LatestExecutionPayloadHeader
}
return nil
}
func (x *BeaconStateGloas) GetNextWithdrawalIndex() uint64 {
if x != nil {
return x.NextWithdrawalIndex
}
return 0
}
func (x *BeaconStateGloas) GetNextWithdrawalValidatorIndex() github_com_OffchainLabs_prysm_v6_consensus_types_primitives.ValidatorIndex {
if x != nil {
return x.NextWithdrawalValidatorIndex
}
return github_com_OffchainLabs_prysm_v6_consensus_types_primitives.ValidatorIndex(0)
}
func (x *BeaconStateGloas) GetHistoricalSummaries() []*HistoricalSummary {
if x != nil {
return x.HistoricalSummaries
}
return nil
}
func (x *BeaconStateGloas) GetDepositRequestsStartIndex() uint64 {
if x != nil {
return x.DepositRequestsStartIndex
}
return 0
}
func (x *BeaconStateGloas) GetDepositBalanceToConsume() github_com_OffchainLabs_prysm_v6_consensus_types_primitives.Gwei {
if x != nil {
return x.DepositBalanceToConsume
}
return github_com_OffchainLabs_prysm_v6_consensus_types_primitives.Gwei(0)
}
func (x *BeaconStateGloas) GetExitBalanceToConsume() github_com_OffchainLabs_prysm_v6_consensus_types_primitives.Gwei {
if x != nil {
return x.ExitBalanceToConsume
}
return github_com_OffchainLabs_prysm_v6_consensus_types_primitives.Gwei(0)
}
func (x *BeaconStateGloas) GetEarliestExitEpoch() github_com_OffchainLabs_prysm_v6_consensus_types_primitives.Epoch {
if x != nil {
return x.EarliestExitEpoch
}
return github_com_OffchainLabs_prysm_v6_consensus_types_primitives.Epoch(0)
}
func (x *BeaconStateGloas) GetConsolidationBalanceToConsume() github_com_OffchainLabs_prysm_v6_consensus_types_primitives.Gwei {
if x != nil {
return x.ConsolidationBalanceToConsume
}
return github_com_OffchainLabs_prysm_v6_consensus_types_primitives.Gwei(0)
}
func (x *BeaconStateGloas) GetEarliestConsolidationEpoch() github_com_OffchainLabs_prysm_v6_consensus_types_primitives.Epoch {
if x != nil {
return x.EarliestConsolidationEpoch
}
return github_com_OffchainLabs_prysm_v6_consensus_types_primitives.Epoch(0)
}
func (x *BeaconStateGloas) GetPendingDeposits() []*PendingDeposit {
if x != nil {
return x.PendingDeposits
}
return nil
}
func (x *BeaconStateGloas) GetPendingPartialWithdrawals() []*PendingPartialWithdrawal {
if x != nil {
return x.PendingPartialWithdrawals
}
return nil
}
func (x *BeaconStateGloas) GetPendingConsolidations() []*PendingConsolidation {
if x != nil {
return x.PendingConsolidations
}
return nil
}
func (x *BeaconStateGloas) GetProposerLookahead() []uint64 {
if x != nil {
return x.ProposerLookahead
}
return nil
}
var File_proto_prysm_v1alpha1_beacon_state_proto protoreflect.FileDescriptor
var file_proto_prysm_v1alpha1_beacon_state_proto_rawDesc = []byte{
@@ -3529,17 +3869,224 @@ var file_proto_prysm_v1alpha1_beacon_state_proto_rawDesc = []byte{
0x70, 0x72, 0x6f, 0x70, 0x6f, 0x73, 0x65, 0x72, 0x5f, 0x6c, 0x6f, 0x6f, 0x6b, 0x61, 0x68, 0x65,
0x61, 0x64, 0x18, 0xc9, 0x65, 0x20, 0x03, 0x28, 0x04, 0x42, 0x06, 0x8a, 0xb5, 0x18, 0x02, 0x36,
0x34, 0x52, 0x11, 0x70, 0x72, 0x6f, 0x70, 0x6f, 0x73, 0x65, 0x72, 0x4c, 0x6f, 0x6f, 0x6b, 0x61,
0x68, 0x65, 0x61, 0x64, 0x42, 0x9a, 0x01, 0x0a, 0x19, 0x6f, 0x72, 0x67, 0x2e, 0x65, 0x74, 0x68,
0x68, 0x65, 0x61, 0x64, 0x22, 0xe8, 0x19, 0x0a, 0x10, 0x42, 0x65, 0x61, 0x63, 0x6f, 0x6e, 0x53,
0x74, 0x61, 0x74, 0x65, 0x47, 0x6c, 0x6f, 0x61, 0x73, 0x12, 0x22, 0x0a, 0x0c, 0x67, 0x65, 0x6e,
0x65, 0x73, 0x69, 0x73, 0x5f, 0x74, 0x69, 0x6d, 0x65, 0x18, 0xe9, 0x07, 0x20, 0x01, 0x28, 0x04,
0x52, 0x0b, 0x67, 0x65, 0x6e, 0x65, 0x73, 0x69, 0x73, 0x54, 0x69, 0x6d, 0x65, 0x12, 0x3f, 0x0a,
0x17, 0x67, 0x65, 0x6e, 0x65, 0x73, 0x69, 0x73, 0x5f, 0x76, 0x61, 0x6c, 0x69, 0x64, 0x61, 0x74,
0x6f, 0x72, 0x73, 0x5f, 0x72, 0x6f, 0x6f, 0x74, 0x18, 0xea, 0x07, 0x20, 0x01, 0x28, 0x0c, 0x42,
0x06, 0x8a, 0xb5, 0x18, 0x02, 0x33, 0x32, 0x52, 0x15, 0x67, 0x65, 0x6e, 0x65, 0x73, 0x69, 0x73,
0x56, 0x61, 0x6c, 0x69, 0x64, 0x61, 0x74, 0x6f, 0x72, 0x73, 0x52, 0x6f, 0x6f, 0x74, 0x12, 0x59,
0x0a, 0x04, 0x73, 0x6c, 0x6f, 0x74, 0x18, 0xeb, 0x07, 0x20, 0x01, 0x28, 0x04, 0x42, 0x44, 0x82,
0xb5, 0x18, 0x40, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x4f, 0x66,
0x66, 0x63, 0x68, 0x61, 0x69, 0x6e, 0x4c, 0x61, 0x62, 0x73, 0x2f, 0x70, 0x72, 0x79, 0x73, 0x6d,
0x2f, 0x76, 0x36, 0x2f, 0x63, 0x6f, 0x6e, 0x73, 0x65, 0x6e, 0x73, 0x75, 0x73, 0x2d, 0x74, 0x79,
0x70, 0x65, 0x73, 0x2f, 0x70, 0x72, 0x69, 0x6d, 0x69, 0x74, 0x69, 0x76, 0x65, 0x73, 0x2e, 0x53,
0x6c, 0x6f, 0x74, 0x52, 0x04, 0x73, 0x6c, 0x6f, 0x74, 0x12, 0x30, 0x0a, 0x04, 0x66, 0x6f, 0x72,
0x6b, 0x18, 0xec, 0x07, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x65, 0x74, 0x68, 0x65, 0x72,
0x65, 0x75, 0x6d, 0x2e, 0x65, 0x74, 0x68, 0x2e, 0x76, 0x31, 0x61, 0x6c, 0x70, 0x68, 0x61, 0x31,
0x2e, 0x46, 0x6f, 0x72, 0x6b, 0x52, 0x04, 0x66, 0x6f, 0x72, 0x6b, 0x12, 0x59, 0x0a, 0x13, 0x6c,
0x61, 0x74, 0x65, 0x73, 0x74, 0x5f, 0x62, 0x6c, 0x6f, 0x63, 0x6b, 0x5f, 0x68, 0x65, 0x61, 0x64,
0x65, 0x72, 0x18, 0xd1, 0x0f, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x28, 0x2e, 0x65, 0x74, 0x68, 0x65,
0x72, 0x65, 0x75, 0x6d, 0x2e, 0x65, 0x74, 0x68, 0x2e, 0x76, 0x31, 0x61, 0x6c, 0x70, 0x68, 0x61,
0x31, 0x2e, 0x42, 0x65, 0x61, 0x63, 0x6f, 0x6e, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x48, 0x65, 0x61,
0x64, 0x65, 0x72, 0x52, 0x11, 0x6c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x42, 0x6c, 0x6f, 0x63, 0x6b,
0x48, 0x65, 0x61, 0x64, 0x65, 0x72, 0x12, 0x2d, 0x0a, 0x0b, 0x62, 0x6c, 0x6f, 0x63, 0x6b, 0x5f,
0x72, 0x6f, 0x6f, 0x74, 0x73, 0x18, 0xd2, 0x0f, 0x20, 0x03, 0x28, 0x0c, 0x42, 0x0b, 0x8a, 0xb5,
0x18, 0x07, 0x38, 0x31, 0x39, 0x32, 0x2c, 0x33, 0x32, 0x52, 0x0a, 0x62, 0x6c, 0x6f, 0x63, 0x6b,
0x52, 0x6f, 0x6f, 0x74, 0x73, 0x12, 0x2d, 0x0a, 0x0b, 0x73, 0x74, 0x61, 0x74, 0x65, 0x5f, 0x72,
0x6f, 0x6f, 0x74, 0x73, 0x18, 0xd3, 0x0f, 0x20, 0x03, 0x28, 0x0c, 0x42, 0x0b, 0x8a, 0xb5, 0x18,
0x07, 0x38, 0x31, 0x39, 0x32, 0x2c, 0x33, 0x32, 0x52, 0x0a, 0x73, 0x74, 0x61, 0x74, 0x65, 0x52,
0x6f, 0x6f, 0x74, 0x73, 0x12, 0x40, 0x0a, 0x10, 0x68, 0x69, 0x73, 0x74, 0x6f, 0x72, 0x69, 0x63,
0x61, 0x6c, 0x5f, 0x72, 0x6f, 0x6f, 0x74, 0x73, 0x18, 0xd4, 0x0f, 0x20, 0x03, 0x28, 0x0c, 0x42,
0x14, 0x8a, 0xb5, 0x18, 0x04, 0x3f, 0x2c, 0x33, 0x32, 0x92, 0xb5, 0x18, 0x08, 0x31, 0x36, 0x37,
0x37, 0x37, 0x32, 0x31, 0x36, 0x52, 0x0f, 0x68, 0x69, 0x73, 0x74, 0x6f, 0x72, 0x69, 0x63, 0x61,
0x6c, 0x52, 0x6f, 0x6f, 0x74, 0x73, 0x12, 0x3d, 0x0a, 0x09, 0x65, 0x74, 0x68, 0x31, 0x5f, 0x64,
0x61, 0x74, 0x61, 0x18, 0xb9, 0x17, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1f, 0x2e, 0x65, 0x74, 0x68,
0x65, 0x72, 0x65, 0x75, 0x6d, 0x2e, 0x65, 0x74, 0x68, 0x2e, 0x76, 0x31, 0x61, 0x6c, 0x70, 0x68,
0x61, 0x31, 0x42, 0x10, 0x42, 0x65, 0x61, 0x63, 0x6f, 0x6e, 0x53, 0x74, 0x61, 0x74, 0x65, 0x50,
0x72, 0x6f, 0x74, 0x6f, 0x50, 0x01, 0x5a, 0x39, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63,
0x61, 0x31, 0x2e, 0x45, 0x74, 0x68, 0x31, 0x44, 0x61, 0x74, 0x61, 0x52, 0x08, 0x65, 0x74, 0x68,
0x31, 0x44, 0x61, 0x74, 0x61, 0x12, 0x52, 0x0a, 0x0f, 0x65, 0x74, 0x68, 0x31, 0x5f, 0x64, 0x61,
0x74, 0x61, 0x5f, 0x76, 0x6f, 0x74, 0x65, 0x73, 0x18, 0xba, 0x17, 0x20, 0x03, 0x28, 0x0b, 0x32,
0x1f, 0x2e, 0x65, 0x74, 0x68, 0x65, 0x72, 0x65, 0x75, 0x6d, 0x2e, 0x65, 0x74, 0x68, 0x2e, 0x76,
0x31, 0x61, 0x6c, 0x70, 0x68, 0x61, 0x31, 0x2e, 0x45, 0x74, 0x68, 0x31, 0x44, 0x61, 0x74, 0x61,
0x42, 0x08, 0x92, 0xb5, 0x18, 0x04, 0x32, 0x30, 0x34, 0x38, 0x52, 0x0d, 0x65, 0x74, 0x68, 0x31,
0x44, 0x61, 0x74, 0x61, 0x56, 0x6f, 0x74, 0x65, 0x73, 0x12, 0x2d, 0x0a, 0x12, 0x65, 0x74, 0x68,
0x31, 0x5f, 0x64, 0x65, 0x70, 0x6f, 0x73, 0x69, 0x74, 0x5f, 0x69, 0x6e, 0x64, 0x65, 0x78, 0x18,
0xbb, 0x17, 0x20, 0x01, 0x28, 0x04, 0x52, 0x10, 0x65, 0x74, 0x68, 0x31, 0x44, 0x65, 0x70, 0x6f,
0x73, 0x69, 0x74, 0x49, 0x6e, 0x64, 0x65, 0x78, 0x12, 0x54, 0x0a, 0x0a, 0x76, 0x61, 0x6c, 0x69,
0x64, 0x61, 0x74, 0x6f, 0x72, 0x73, 0x18, 0xa1, 0x1f, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x20, 0x2e,
0x65, 0x74, 0x68, 0x65, 0x72, 0x65, 0x75, 0x6d, 0x2e, 0x65, 0x74, 0x68, 0x2e, 0x76, 0x31, 0x61,
0x6c, 0x70, 0x68, 0x61, 0x31, 0x2e, 0x56, 0x61, 0x6c, 0x69, 0x64, 0x61, 0x74, 0x6f, 0x72, 0x42,
0x11, 0x92, 0xb5, 0x18, 0x0d, 0x31, 0x30, 0x39, 0x39, 0x35, 0x31, 0x31, 0x36, 0x32, 0x37, 0x37,
0x37, 0x36, 0x52, 0x0a, 0x76, 0x61, 0x6c, 0x69, 0x64, 0x61, 0x74, 0x6f, 0x72, 0x73, 0x12, 0x2e,
0x0a, 0x08, 0x62, 0x61, 0x6c, 0x61, 0x6e, 0x63, 0x65, 0x73, 0x18, 0xa2, 0x1f, 0x20, 0x03, 0x28,
0x04, 0x42, 0x11, 0x92, 0xb5, 0x18, 0x0d, 0x31, 0x30, 0x39, 0x39, 0x35, 0x31, 0x31, 0x36, 0x32,
0x37, 0x37, 0x37, 0x36, 0x52, 0x08, 0x62, 0x61, 0x6c, 0x61, 0x6e, 0x63, 0x65, 0x73, 0x12, 0x30,
0x0a, 0x0c, 0x72, 0x61, 0x6e, 0x64, 0x61, 0x6f, 0x5f, 0x6d, 0x69, 0x78, 0x65, 0x73, 0x18, 0x89,
0x27, 0x20, 0x03, 0x28, 0x0c, 0x42, 0x0c, 0x8a, 0xb5, 0x18, 0x08, 0x36, 0x35, 0x35, 0x33, 0x36,
0x2c, 0x33, 0x32, 0x52, 0x0b, 0x72, 0x61, 0x6e, 0x64, 0x61, 0x6f, 0x4d, 0x69, 0x78, 0x65, 0x73,
0x12, 0x27, 0x0a, 0x09, 0x73, 0x6c, 0x61, 0x73, 0x68, 0x69, 0x6e, 0x67, 0x73, 0x18, 0xf1, 0x2e,
0x20, 0x03, 0x28, 0x04, 0x42, 0x08, 0x8a, 0xb5, 0x18, 0x04, 0x38, 0x31, 0x39, 0x32, 0x52, 0x09,
0x73, 0x6c, 0x61, 0x73, 0x68, 0x69, 0x6e, 0x67, 0x73, 0x12, 0x54, 0x0a, 0x1c, 0x70, 0x72, 0x65,
0x76, 0x69, 0x6f, 0x75, 0x73, 0x5f, 0x65, 0x70, 0x6f, 0x63, 0x68, 0x5f, 0x70, 0x61, 0x72, 0x74,
0x69, 0x63, 0x69, 0x70, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0xd9, 0x36, 0x20, 0x01, 0x28, 0x0c,
0x42, 0x11, 0x92, 0xb5, 0x18, 0x0d, 0x31, 0x30, 0x39, 0x39, 0x35, 0x31, 0x31, 0x36, 0x32, 0x37,
0x37, 0x37, 0x36, 0x52, 0x1a, 0x70, 0x72, 0x65, 0x76, 0x69, 0x6f, 0x75, 0x73, 0x45, 0x70, 0x6f,
0x63, 0x68, 0x50, 0x61, 0x72, 0x74, 0x69, 0x63, 0x69, 0x70, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12,
0x52, 0x0a, 0x1b, 0x63, 0x75, 0x72, 0x72, 0x65, 0x6e, 0x74, 0x5f, 0x65, 0x70, 0x6f, 0x63, 0x68,
0x5f, 0x70, 0x61, 0x72, 0x74, 0x69, 0x63, 0x69, 0x70, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0xda,
0x36, 0x20, 0x01, 0x28, 0x0c, 0x42, 0x11, 0x92, 0xb5, 0x18, 0x0d, 0x31, 0x30, 0x39, 0x39, 0x35,
0x31, 0x31, 0x36, 0x32, 0x37, 0x37, 0x37, 0x36, 0x52, 0x19, 0x63, 0x75, 0x72, 0x72, 0x65, 0x6e,
0x74, 0x45, 0x70, 0x6f, 0x63, 0x68, 0x50, 0x61, 0x72, 0x74, 0x69, 0x63, 0x69, 0x70, 0x61, 0x74,
0x69, 0x6f, 0x6e, 0x12, 0x68, 0x0a, 0x12, 0x6a, 0x75, 0x73, 0x74, 0x69, 0x66, 0x69, 0x63, 0x61,
0x74, 0x69, 0x6f, 0x6e, 0x5f, 0x62, 0x69, 0x74, 0x73, 0x18, 0xc1, 0x3e, 0x20, 0x01, 0x28, 0x0c,
0x42, 0x38, 0x82, 0xb5, 0x18, 0x2f, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d,
0x2f, 0x70, 0x72, 0x79, 0x73, 0x6d, 0x61, 0x74, 0x69, 0x63, 0x6c, 0x61, 0x62, 0x73, 0x2f, 0x67,
0x6f, 0x2d, 0x62, 0x69, 0x74, 0x66, 0x69, 0x65, 0x6c, 0x64, 0x2e, 0x42, 0x69, 0x74, 0x76, 0x65,
0x63, 0x74, 0x6f, 0x72, 0x34, 0x8a, 0xb5, 0x18, 0x01, 0x31, 0x52, 0x11, 0x6a, 0x75, 0x73, 0x74,
0x69, 0x66, 0x69, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x42, 0x69, 0x74, 0x73, 0x12, 0x66, 0x0a,
0x1d, 0x70, 0x72, 0x65, 0x76, 0x69, 0x6f, 0x75, 0x73, 0x5f, 0x6a, 0x75, 0x73, 0x74, 0x69, 0x66,
0x69, 0x65, 0x64, 0x5f, 0x63, 0x68, 0x65, 0x63, 0x6b, 0x70, 0x6f, 0x69, 0x6e, 0x74, 0x18, 0xc2,
0x3e, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x21, 0x2e, 0x65, 0x74, 0x68, 0x65, 0x72, 0x65, 0x75, 0x6d,
0x2e, 0x65, 0x74, 0x68, 0x2e, 0x76, 0x31, 0x61, 0x6c, 0x70, 0x68, 0x61, 0x31, 0x2e, 0x43, 0x68,
0x65, 0x63, 0x6b, 0x70, 0x6f, 0x69, 0x6e, 0x74, 0x52, 0x1b, 0x70, 0x72, 0x65, 0x76, 0x69, 0x6f,
0x75, 0x73, 0x4a, 0x75, 0x73, 0x74, 0x69, 0x66, 0x69, 0x65, 0x64, 0x43, 0x68, 0x65, 0x63, 0x6b,
0x70, 0x6f, 0x69, 0x6e, 0x74, 0x12, 0x64, 0x0a, 0x1c, 0x63, 0x75, 0x72, 0x72, 0x65, 0x6e, 0x74,
0x5f, 0x6a, 0x75, 0x73, 0x74, 0x69, 0x66, 0x69, 0x65, 0x64, 0x5f, 0x63, 0x68, 0x65, 0x63, 0x6b,
0x70, 0x6f, 0x69, 0x6e, 0x74, 0x18, 0xc3, 0x3e, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x21, 0x2e, 0x65,
0x74, 0x68, 0x65, 0x72, 0x65, 0x75, 0x6d, 0x2e, 0x65, 0x74, 0x68, 0x2e, 0x76, 0x31, 0x61, 0x6c,
0x70, 0x68, 0x61, 0x31, 0x2e, 0x43, 0x68, 0x65, 0x63, 0x6b, 0x70, 0x6f, 0x69, 0x6e, 0x74, 0x52,
0x1a, 0x63, 0x75, 0x72, 0x72, 0x65, 0x6e, 0x74, 0x4a, 0x75, 0x73, 0x74, 0x69, 0x66, 0x69, 0x65,
0x64, 0x43, 0x68, 0x65, 0x63, 0x6b, 0x70, 0x6f, 0x69, 0x6e, 0x74, 0x12, 0x55, 0x0a, 0x14, 0x66,
0x69, 0x6e, 0x61, 0x6c, 0x69, 0x7a, 0x65, 0x64, 0x5f, 0x63, 0x68, 0x65, 0x63, 0x6b, 0x70, 0x6f,
0x69, 0x6e, 0x74, 0x18, 0xc4, 0x3e, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x21, 0x2e, 0x65, 0x74, 0x68,
0x65, 0x72, 0x65, 0x75, 0x6d, 0x2e, 0x65, 0x74, 0x68, 0x2e, 0x76, 0x31, 0x61, 0x6c, 0x70, 0x68,
0x61, 0x31, 0x2e, 0x43, 0x68, 0x65, 0x63, 0x6b, 0x70, 0x6f, 0x69, 0x6e, 0x74, 0x52, 0x13, 0x66,
0x69, 0x6e, 0x61, 0x6c, 0x69, 0x7a, 0x65, 0x64, 0x43, 0x68, 0x65, 0x63, 0x6b, 0x70, 0x6f, 0x69,
0x6e, 0x74, 0x12, 0x3f, 0x0a, 0x11, 0x69, 0x6e, 0x61, 0x63, 0x74, 0x69, 0x76, 0x69, 0x74, 0x79,
0x5f, 0x73, 0x63, 0x6f, 0x72, 0x65, 0x73, 0x18, 0xa9, 0x46, 0x20, 0x03, 0x28, 0x04, 0x42, 0x11,
0x92, 0xb5, 0x18, 0x0d, 0x31, 0x30, 0x39, 0x39, 0x35, 0x31, 0x31, 0x36, 0x32, 0x37, 0x37, 0x37,
0x36, 0x52, 0x10, 0x69, 0x6e, 0x61, 0x63, 0x74, 0x69, 0x76, 0x69, 0x74, 0x79, 0x53, 0x63, 0x6f,
0x72, 0x65, 0x73, 0x12, 0x5b, 0x0a, 0x16, 0x63, 0x75, 0x72, 0x72, 0x65, 0x6e, 0x74, 0x5f, 0x73,
0x79, 0x6e, 0x63, 0x5f, 0x63, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x74, 0x65, 0x65, 0x18, 0xaa, 0x46,
0x20, 0x01, 0x28, 0x0b, 0x32, 0x24, 0x2e, 0x65, 0x74, 0x68, 0x65, 0x72, 0x65, 0x75, 0x6d, 0x2e,
0x65, 0x74, 0x68, 0x2e, 0x76, 0x31, 0x61, 0x6c, 0x70, 0x68, 0x61, 0x31, 0x2e, 0x53, 0x79, 0x6e,
0x63, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x74, 0x65, 0x65, 0x52, 0x14, 0x63, 0x75, 0x72, 0x72,
0x65, 0x6e, 0x74, 0x53, 0x79, 0x6e, 0x63, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x74, 0x65, 0x65,
0x12, 0x55, 0x0a, 0x13, 0x6e, 0x65, 0x78, 0x74, 0x5f, 0x73, 0x79, 0x6e, 0x63, 0x5f, 0x63, 0x6f,
0x6d, 0x6d, 0x69, 0x74, 0x74, 0x65, 0x65, 0x18, 0xab, 0x46, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x24,
0x2e, 0x65, 0x74, 0x68, 0x65, 0x72, 0x65, 0x75, 0x6d, 0x2e, 0x65, 0x74, 0x68, 0x2e, 0x76, 0x31,
0x61, 0x6c, 0x70, 0x68, 0x61, 0x31, 0x2e, 0x53, 0x79, 0x6e, 0x63, 0x43, 0x6f, 0x6d, 0x6d, 0x69,
0x74, 0x74, 0x65, 0x65, 0x52, 0x11, 0x6e, 0x65, 0x78, 0x74, 0x53, 0x79, 0x6e, 0x63, 0x43, 0x6f,
0x6d, 0x6d, 0x69, 0x74, 0x74, 0x65, 0x65, 0x12, 0x77, 0x0a, 0x1f, 0x6c, 0x61, 0x74, 0x65, 0x73,
0x74, 0x5f, 0x65, 0x78, 0x65, 0x63, 0x75, 0x74, 0x69, 0x6f, 0x6e, 0x5f, 0x70, 0x61, 0x79, 0x6c,
0x6f, 0x61, 0x64, 0x5f, 0x68, 0x65, 0x61, 0x64, 0x65, 0x72, 0x18, 0x91, 0x4e, 0x20, 0x01, 0x28,
0x0b, 0x32, 0x2f, 0x2e, 0x65, 0x74, 0x68, 0x65, 0x72, 0x65, 0x75, 0x6d, 0x2e, 0x65, 0x6e, 0x67,
0x69, 0x6e, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x45, 0x78, 0x65, 0x63, 0x75, 0x74, 0x69, 0x6f, 0x6e,
0x50, 0x61, 0x79, 0x6c, 0x6f, 0x61, 0x64, 0x48, 0x65, 0x61, 0x64, 0x65, 0x72, 0x47, 0x6c, 0x6f,
0x61, 0x73, 0x52, 0x1c, 0x6c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x45, 0x78, 0x65, 0x63, 0x75, 0x74,
0x69, 0x6f, 0x6e, 0x50, 0x61, 0x79, 0x6c, 0x6f, 0x61, 0x64, 0x48, 0x65, 0x61, 0x64, 0x65, 0x72,
0x12, 0x33, 0x0a, 0x15, 0x6e, 0x65, 0x78, 0x74, 0x5f, 0x77, 0x69, 0x74, 0x68, 0x64, 0x72, 0x61,
0x77, 0x61, 0x6c, 0x5f, 0x69, 0x6e, 0x64, 0x65, 0x78, 0x18, 0xf9, 0x55, 0x20, 0x01, 0x28, 0x04,
0x52, 0x13, 0x6e, 0x65, 0x78, 0x74, 0x57, 0x69, 0x74, 0x68, 0x64, 0x72, 0x61, 0x77, 0x61, 0x6c,
0x49, 0x6e, 0x64, 0x65, 0x78, 0x12, 0x96, 0x01, 0x0a, 0x1f, 0x6e, 0x65, 0x78, 0x74, 0x5f, 0x77,
0x69, 0x74, 0x68, 0x64, 0x72, 0x61, 0x77, 0x61, 0x6c, 0x5f, 0x76, 0x61, 0x6c, 0x69, 0x64, 0x61,
0x74, 0x6f, 0x72, 0x5f, 0x69, 0x6e, 0x64, 0x65, 0x78, 0x18, 0xfa, 0x55, 0x20, 0x01, 0x28, 0x04,
0x42, 0x4e, 0x82, 0xb5, 0x18, 0x4a, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d,
0x2f, 0x4f, 0x66, 0x66, 0x63, 0x68, 0x61, 0x69, 0x6e, 0x4c, 0x61, 0x62, 0x73, 0x2f, 0x70, 0x72,
0x79, 0x73, 0x6d, 0x2f, 0x76, 0x36, 0x2f, 0x63, 0x6f, 0x6e, 0x73, 0x65, 0x6e, 0x73, 0x75, 0x73,
0x2d, 0x74, 0x79, 0x70, 0x65, 0x73, 0x2f, 0x70, 0x72, 0x69, 0x6d, 0x69, 0x74, 0x69, 0x76, 0x65,
0x73, 0x2e, 0x56, 0x61, 0x6c, 0x69, 0x64, 0x61, 0x74, 0x6f, 0x72, 0x49, 0x6e, 0x64, 0x65, 0x78,
0x52, 0x1c, 0x6e, 0x65, 0x78, 0x74, 0x57, 0x69, 0x74, 0x68, 0x64, 0x72, 0x61, 0x77, 0x61, 0x6c,
0x56, 0x61, 0x6c, 0x69, 0x64, 0x61, 0x74, 0x6f, 0x72, 0x49, 0x6e, 0x64, 0x65, 0x78, 0x12, 0x6a,
0x0a, 0x14, 0x68, 0x69, 0x73, 0x74, 0x6f, 0x72, 0x69, 0x63, 0x61, 0x6c, 0x5f, 0x73, 0x75, 0x6d,
0x6d, 0x61, 0x72, 0x69, 0x65, 0x73, 0x18, 0xfb, 0x55, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x28, 0x2e,
0x65, 0x74, 0x68, 0x65, 0x72, 0x65, 0x75, 0x6d, 0x2e, 0x65, 0x74, 0x68, 0x2e, 0x76, 0x31, 0x61,
0x6c, 0x70, 0x68, 0x61, 0x31, 0x2e, 0x48, 0x69, 0x73, 0x74, 0x6f, 0x72, 0x69, 0x63, 0x61, 0x6c,
0x53, 0x75, 0x6d, 0x6d, 0x61, 0x72, 0x79, 0x42, 0x0c, 0x92, 0xb5, 0x18, 0x08, 0x31, 0x36, 0x37,
0x37, 0x37, 0x32, 0x31, 0x36, 0x52, 0x13, 0x68, 0x69, 0x73, 0x74, 0x6f, 0x72, 0x69, 0x63, 0x61,
0x6c, 0x53, 0x75, 0x6d, 0x6d, 0x61, 0x72, 0x69, 0x65, 0x73, 0x12, 0x40, 0x0a, 0x1c, 0x64, 0x65,
0x70, 0x6f, 0x73, 0x69, 0x74, 0x5f, 0x72, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x73, 0x5f, 0x73,
0x74, 0x61, 0x72, 0x74, 0x5f, 0x69, 0x6e, 0x64, 0x65, 0x78, 0x18, 0xe1, 0x5d, 0x20, 0x01, 0x28,
0x04, 0x52, 0x19, 0x64, 0x65, 0x70, 0x6f, 0x73, 0x69, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73,
0x74, 0x73, 0x53, 0x74, 0x61, 0x72, 0x74, 0x49, 0x6e, 0x64, 0x65, 0x78, 0x12, 0x82, 0x01, 0x0a,
0x1a, 0x64, 0x65, 0x70, 0x6f, 0x73, 0x69, 0x74, 0x5f, 0x62, 0x61, 0x6c, 0x61, 0x6e, 0x63, 0x65,
0x5f, 0x74, 0x6f, 0x5f, 0x63, 0x6f, 0x6e, 0x73, 0x75, 0x6d, 0x65, 0x18, 0xe2, 0x5d, 0x20, 0x01,
0x28, 0x04, 0x42, 0x44, 0x82, 0xb5, 0x18, 0x40, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63,
0x6f, 0x6d, 0x2f, 0x4f, 0x66, 0x66, 0x63, 0x68, 0x61, 0x69, 0x6e, 0x4c, 0x61, 0x62, 0x73, 0x2f,
0x70, 0x72, 0x79, 0x73, 0x6d, 0x2f, 0x76, 0x36, 0x2f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2f, 0x70,
0x72, 0x79, 0x73, 0x6d, 0x2f, 0x76, 0x31, 0x61, 0x6c, 0x70, 0x68, 0x61, 0x31, 0x3b, 0x65, 0x74,
0x68, 0xaa, 0x02, 0x15, 0x45, 0x74, 0x68, 0x65, 0x72, 0x65, 0x75, 0x6d, 0x2e, 0x45, 0x74, 0x68,
0x2e, 0x56, 0x31, 0x41, 0x6c, 0x70, 0x68, 0x61, 0x31, 0xca, 0x02, 0x15, 0x45, 0x74, 0x68, 0x65,
0x72, 0x65, 0x75, 0x6d, 0x5c, 0x45, 0x74, 0x68, 0x5c, 0x76, 0x31, 0x61, 0x6c, 0x70, 0x68, 0x61,
0x31, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33,
0x70, 0x72, 0x79, 0x73, 0x6d, 0x2f, 0x76, 0x36, 0x2f, 0x63, 0x6f, 0x6e, 0x73, 0x65, 0x6e, 0x73,
0x75, 0x73, 0x2d, 0x74, 0x79, 0x70, 0x65, 0x73, 0x2f, 0x70, 0x72, 0x69, 0x6d, 0x69, 0x74, 0x69,
0x76, 0x65, 0x73, 0x2e, 0x47, 0x77, 0x65, 0x69, 0x52, 0x17, 0x64, 0x65, 0x70, 0x6f, 0x73, 0x69,
0x74, 0x42, 0x61, 0x6c, 0x61, 0x6e, 0x63, 0x65, 0x54, 0x6f, 0x43, 0x6f, 0x6e, 0x73, 0x75, 0x6d,
0x65, 0x12, 0x7c, 0x0a, 0x17, 0x65, 0x78, 0x69, 0x74, 0x5f, 0x62, 0x61, 0x6c, 0x61, 0x6e, 0x63,
0x65, 0x5f, 0x74, 0x6f, 0x5f, 0x63, 0x6f, 0x6e, 0x73, 0x75, 0x6d, 0x65, 0x18, 0xe3, 0x5d, 0x20,
0x01, 0x28, 0x04, 0x42, 0x44, 0x82, 0xb5, 0x18, 0x40, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e,
0x63, 0x6f, 0x6d, 0x2f, 0x4f, 0x66, 0x66, 0x63, 0x68, 0x61, 0x69, 0x6e, 0x4c, 0x61, 0x62, 0x73,
0x2f, 0x70, 0x72, 0x79, 0x73, 0x6d, 0x2f, 0x76, 0x36, 0x2f, 0x63, 0x6f, 0x6e, 0x73, 0x65, 0x6e,
0x73, 0x75, 0x73, 0x2d, 0x74, 0x79, 0x70, 0x65, 0x73, 0x2f, 0x70, 0x72, 0x69, 0x6d, 0x69, 0x74,
0x69, 0x76, 0x65, 0x73, 0x2e, 0x47, 0x77, 0x65, 0x69, 0x52, 0x14, 0x65, 0x78, 0x69, 0x74, 0x42,
0x61, 0x6c, 0x61, 0x6e, 0x63, 0x65, 0x54, 0x6f, 0x43, 0x6f, 0x6e, 0x73, 0x75, 0x6d, 0x65, 0x12,
0x76, 0x0a, 0x13, 0x65, 0x61, 0x72, 0x6c, 0x69, 0x65, 0x73, 0x74, 0x5f, 0x65, 0x78, 0x69, 0x74,
0x5f, 0x65, 0x70, 0x6f, 0x63, 0x68, 0x18, 0xe4, 0x5d, 0x20, 0x01, 0x28, 0x04, 0x42, 0x45, 0x82,
0xb5, 0x18, 0x41, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x4f, 0x66,
0x66, 0x63, 0x68, 0x61, 0x69, 0x6e, 0x4c, 0x61, 0x62, 0x73, 0x2f, 0x70, 0x72, 0x79, 0x73, 0x6d,
0x2f, 0x76, 0x36, 0x2f, 0x63, 0x6f, 0x6e, 0x73, 0x65, 0x6e, 0x73, 0x75, 0x73, 0x2d, 0x74, 0x79,
0x70, 0x65, 0x73, 0x2f, 0x70, 0x72, 0x69, 0x6d, 0x69, 0x74, 0x69, 0x76, 0x65, 0x73, 0x2e, 0x45,
0x70, 0x6f, 0x63, 0x68, 0x52, 0x11, 0x65, 0x61, 0x72, 0x6c, 0x69, 0x65, 0x73, 0x74, 0x45, 0x78,
0x69, 0x74, 0x45, 0x70, 0x6f, 0x63, 0x68, 0x12, 0x8e, 0x01, 0x0a, 0x20, 0x63, 0x6f, 0x6e, 0x73,
0x6f, 0x6c, 0x69, 0x64, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x5f, 0x62, 0x61, 0x6c, 0x61, 0x6e, 0x63,
0x65, 0x5f, 0x74, 0x6f, 0x5f, 0x63, 0x6f, 0x6e, 0x73, 0x75, 0x6d, 0x65, 0x18, 0xe5, 0x5d, 0x20,
0x01, 0x28, 0x04, 0x42, 0x44, 0x82, 0xb5, 0x18, 0x40, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e,
0x63, 0x6f, 0x6d, 0x2f, 0x4f, 0x66, 0x66, 0x63, 0x68, 0x61, 0x69, 0x6e, 0x4c, 0x61, 0x62, 0x73,
0x2f, 0x70, 0x72, 0x79, 0x73, 0x6d, 0x2f, 0x76, 0x36, 0x2f, 0x63, 0x6f, 0x6e, 0x73, 0x65, 0x6e,
0x73, 0x75, 0x73, 0x2d, 0x74, 0x79, 0x70, 0x65, 0x73, 0x2f, 0x70, 0x72, 0x69, 0x6d, 0x69, 0x74,
0x69, 0x76, 0x65, 0x73, 0x2e, 0x47, 0x77, 0x65, 0x69, 0x52, 0x1d, 0x63, 0x6f, 0x6e, 0x73, 0x6f,
0x6c, 0x69, 0x64, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x42, 0x61, 0x6c, 0x61, 0x6e, 0x63, 0x65, 0x54,
0x6f, 0x43, 0x6f, 0x6e, 0x73, 0x75, 0x6d, 0x65, 0x12, 0x88, 0x01, 0x0a, 0x1c, 0x65, 0x61, 0x72,
0x6c, 0x69, 0x65, 0x73, 0x74, 0x5f, 0x63, 0x6f, 0x6e, 0x73, 0x6f, 0x6c, 0x69, 0x64, 0x61, 0x74,
0x69, 0x6f, 0x6e, 0x5f, 0x65, 0x70, 0x6f, 0x63, 0x68, 0x18, 0xe6, 0x5d, 0x20, 0x01, 0x28, 0x04,
0x42, 0x45, 0x82, 0xb5, 0x18, 0x41, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d,
0x2f, 0x4f, 0x66, 0x66, 0x63, 0x68, 0x61, 0x69, 0x6e, 0x4c, 0x61, 0x62, 0x73, 0x2f, 0x70, 0x72,
0x79, 0x73, 0x6d, 0x2f, 0x76, 0x36, 0x2f, 0x63, 0x6f, 0x6e, 0x73, 0x65, 0x6e, 0x73, 0x75, 0x73,
0x2d, 0x74, 0x79, 0x70, 0x65, 0x73, 0x2f, 0x70, 0x72, 0x69, 0x6d, 0x69, 0x74, 0x69, 0x76, 0x65,
0x73, 0x2e, 0x45, 0x70, 0x6f, 0x63, 0x68, 0x52, 0x1a, 0x65, 0x61, 0x72, 0x6c, 0x69, 0x65, 0x73,
0x74, 0x43, 0x6f, 0x6e, 0x73, 0x6f, 0x6c, 0x69, 0x64, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x45, 0x70,
0x6f, 0x63, 0x68, 0x12, 0x60, 0x0a, 0x10, 0x70, 0x65, 0x6e, 0x64, 0x69, 0x6e, 0x67, 0x5f, 0x64,
0x65, 0x70, 0x6f, 0x73, 0x69, 0x74, 0x73, 0x18, 0xe7, 0x5d, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x25,
0x2e, 0x65, 0x74, 0x68, 0x65, 0x72, 0x65, 0x75, 0x6d, 0x2e, 0x65, 0x74, 0x68, 0x2e, 0x76, 0x31,
0x61, 0x6c, 0x70, 0x68, 0x61, 0x31, 0x2e, 0x50, 0x65, 0x6e, 0x64, 0x69, 0x6e, 0x67, 0x44, 0x65,
0x70, 0x6f, 0x73, 0x69, 0x74, 0x42, 0x0d, 0x92, 0xb5, 0x18, 0x09, 0x31, 0x33, 0x34, 0x32, 0x31,
0x37, 0x37, 0x32, 0x38, 0x52, 0x0f, 0x70, 0x65, 0x6e, 0x64, 0x69, 0x6e, 0x67, 0x44, 0x65, 0x70,
0x6f, 0x73, 0x69, 0x74, 0x73, 0x12, 0x7f, 0x0a, 0x1b, 0x70, 0x65, 0x6e, 0x64, 0x69, 0x6e, 0x67,
0x5f, 0x70, 0x61, 0x72, 0x74, 0x69, 0x61, 0x6c, 0x5f, 0x77, 0x69, 0x74, 0x68, 0x64, 0x72, 0x61,
0x77, 0x61, 0x6c, 0x73, 0x18, 0xe8, 0x5d, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x2f, 0x2e, 0x65, 0x74,
0x68, 0x65, 0x72, 0x65, 0x75, 0x6d, 0x2e, 0x65, 0x74, 0x68, 0x2e, 0x76, 0x31, 0x61, 0x6c, 0x70,
0x68, 0x61, 0x31, 0x2e, 0x50, 0x65, 0x6e, 0x64, 0x69, 0x6e, 0x67, 0x50, 0x61, 0x72, 0x74, 0x69,
0x61, 0x6c, 0x57, 0x69, 0x74, 0x68, 0x64, 0x72, 0x61, 0x77, 0x61, 0x6c, 0x42, 0x0d, 0x92, 0xb5,
0x18, 0x09, 0x31, 0x33, 0x34, 0x32, 0x31, 0x37, 0x37, 0x32, 0x38, 0x52, 0x19, 0x70, 0x65, 0x6e,
0x64, 0x69, 0x6e, 0x67, 0x50, 0x61, 0x72, 0x74, 0x69, 0x61, 0x6c, 0x57, 0x69, 0x74, 0x68, 0x64,
0x72, 0x61, 0x77, 0x61, 0x6c, 0x73, 0x12, 0x6f, 0x0a, 0x16, 0x70, 0x65, 0x6e, 0x64, 0x69, 0x6e,
0x67, 0x5f, 0x63, 0x6f, 0x6e, 0x73, 0x6f, 0x6c, 0x69, 0x64, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x73,
0x18, 0xe9, 0x5d, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x2b, 0x2e, 0x65, 0x74, 0x68, 0x65, 0x72, 0x65,
0x75, 0x6d, 0x2e, 0x65, 0x74, 0x68, 0x2e, 0x76, 0x31, 0x61, 0x6c, 0x70, 0x68, 0x61, 0x31, 0x2e,
0x50, 0x65, 0x6e, 0x64, 0x69, 0x6e, 0x67, 0x43, 0x6f, 0x6e, 0x73, 0x6f, 0x6c, 0x69, 0x64, 0x61,
0x74, 0x69, 0x6f, 0x6e, 0x42, 0x0a, 0x92, 0xb5, 0x18, 0x06, 0x32, 0x36, 0x32, 0x31, 0x34, 0x34,
0x52, 0x15, 0x70, 0x65, 0x6e, 0x64, 0x69, 0x6e, 0x67, 0x43, 0x6f, 0x6e, 0x73, 0x6f, 0x6c, 0x69,
0x64, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x12, 0x36, 0x0a, 0x12, 0x70, 0x72, 0x6f, 0x70, 0x6f,
0x73, 0x65, 0x72, 0x5f, 0x6c, 0x6f, 0x6f, 0x6b, 0x61, 0x68, 0x65, 0x61, 0x64, 0x18, 0xc9, 0x65,
0x20, 0x03, 0x28, 0x04, 0x42, 0x06, 0x8a, 0xb5, 0x18, 0x02, 0x36, 0x34, 0x52, 0x11, 0x70, 0x72,
0x6f, 0x70, 0x6f, 0x73, 0x65, 0x72, 0x4c, 0x6f, 0x6f, 0x6b, 0x61, 0x68, 0x65, 0x61, 0x64, 0x42,
0x9a, 0x01, 0x0a, 0x19, 0x6f, 0x72, 0x67, 0x2e, 0x65, 0x74, 0x68, 0x65, 0x72, 0x65, 0x75, 0x6d,
0x2e, 0x65, 0x74, 0x68, 0x2e, 0x76, 0x31, 0x61, 0x6c, 0x70, 0x68, 0x61, 0x31, 0x42, 0x10, 0x42,
0x65, 0x61, 0x63, 0x6f, 0x6e, 0x53, 0x74, 0x61, 0x74, 0x65, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x50,
0x01, 0x5a, 0x39, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x4f, 0x66,
0x66, 0x63, 0x68, 0x61, 0x69, 0x6e, 0x4c, 0x61, 0x62, 0x73, 0x2f, 0x70, 0x72, 0x79, 0x73, 0x6d,
0x2f, 0x76, 0x36, 0x2f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2f, 0x70, 0x72, 0x79, 0x73, 0x6d, 0x2f,
0x76, 0x31, 0x61, 0x6c, 0x70, 0x68, 0x61, 0x31, 0x3b, 0x65, 0x74, 0x68, 0xaa, 0x02, 0x15, 0x45,
0x74, 0x68, 0x65, 0x72, 0x65, 0x75, 0x6d, 0x2e, 0x45, 0x74, 0x68, 0x2e, 0x56, 0x31, 0x41, 0x6c,
0x70, 0x68, 0x61, 0x31, 0xca, 0x02, 0x15, 0x45, 0x74, 0x68, 0x65, 0x72, 0x65, 0x75, 0x6d, 0x5c,
0x45, 0x74, 0x68, 0x5c, 0x76, 0x31, 0x61, 0x6c, 0x70, 0x68, 0x61, 0x31, 0x62, 0x06, 0x70, 0x72,
0x6f, 0x74, 0x6f, 0x33,
}
var (
@@ -3554,7 +4101,7 @@ func file_proto_prysm_v1alpha1_beacon_state_proto_rawDescGZIP() []byte {
return file_proto_prysm_v1alpha1_beacon_state_proto_rawDescData
}
var file_proto_prysm_v1alpha1_beacon_state_proto_msgTypes = make([]protoimpl.MessageInfo, 16)
var file_proto_prysm_v1alpha1_beacon_state_proto_msgTypes = make([]protoimpl.MessageInfo, 17)
var file_proto_prysm_v1alpha1_beacon_state_proto_goTypes = []any{
(*BeaconState)(nil), // 0: ethereum.eth.v1alpha1.BeaconState
(*PendingAttestation)(nil), // 1: ethereum.eth.v1alpha1.PendingAttestation
@@ -3572,114 +4119,131 @@ var file_proto_prysm_v1alpha1_beacon_state_proto_goTypes = []any{
(*BeaconStateDeneb)(nil), // 13: ethereum.eth.v1alpha1.BeaconStateDeneb
(*BeaconStateElectra)(nil), // 14: ethereum.eth.v1alpha1.BeaconStateElectra
(*BeaconStateFulu)(nil), // 15: ethereum.eth.v1alpha1.BeaconStateFulu
(*Fork)(nil), // 16: ethereum.eth.v1alpha1.Fork
(*BeaconBlockHeader)(nil), // 17: ethereum.eth.v1alpha1.BeaconBlockHeader
(*Eth1Data)(nil), // 18: ethereum.eth.v1alpha1.Eth1Data
(*Validator)(nil), // 19: ethereum.eth.v1alpha1.Validator
(*Checkpoint)(nil), // 20: ethereum.eth.v1alpha1.Checkpoint
(*AttestationData)(nil), // 21: ethereum.eth.v1alpha1.AttestationData
(*SyncCommittee)(nil), // 22: ethereum.eth.v1alpha1.SyncCommittee
(*v1.ExecutionPayloadHeader)(nil), // 23: ethereum.engine.v1.ExecutionPayloadHeader
(*v1.ExecutionPayloadHeaderCapella)(nil), // 24: ethereum.engine.v1.ExecutionPayloadHeaderCapella
(*HistoricalSummary)(nil), // 25: ethereum.eth.v1alpha1.HistoricalSummary
(*v1.ExecutionPayloadHeaderDeneb)(nil), // 26: ethereum.engine.v1.ExecutionPayloadHeaderDeneb
(*PendingDeposit)(nil), // 27: ethereum.eth.v1alpha1.PendingDeposit
(*PendingPartialWithdrawal)(nil), // 28: ethereum.eth.v1alpha1.PendingPartialWithdrawal
(*PendingConsolidation)(nil), // 29: ethereum.eth.v1alpha1.PendingConsolidation
(*BeaconStateGloas)(nil), // 16: ethereum.eth.v1alpha1.BeaconStateGloas
(*Fork)(nil), // 17: ethereum.eth.v1alpha1.Fork
(*BeaconBlockHeader)(nil), // 18: ethereum.eth.v1alpha1.BeaconBlockHeader
(*Eth1Data)(nil), // 19: ethereum.eth.v1alpha1.Eth1Data
(*Validator)(nil), // 20: ethereum.eth.v1alpha1.Validator
(*Checkpoint)(nil), // 21: ethereum.eth.v1alpha1.Checkpoint
(*AttestationData)(nil), // 22: ethereum.eth.v1alpha1.AttestationData
(*SyncCommittee)(nil), // 23: ethereum.eth.v1alpha1.SyncCommittee
(*v1.ExecutionPayloadHeader)(nil), // 24: ethereum.engine.v1.ExecutionPayloadHeader
(*v1.ExecutionPayloadHeaderCapella)(nil), // 25: ethereum.engine.v1.ExecutionPayloadHeaderCapella
(*HistoricalSummary)(nil), // 26: ethereum.eth.v1alpha1.HistoricalSummary
(*v1.ExecutionPayloadHeaderDeneb)(nil), // 27: ethereum.engine.v1.ExecutionPayloadHeaderDeneb
(*PendingDeposit)(nil), // 28: ethereum.eth.v1alpha1.PendingDeposit
(*PendingPartialWithdrawal)(nil), // 29: ethereum.eth.v1alpha1.PendingPartialWithdrawal
(*PendingConsolidation)(nil), // 30: ethereum.eth.v1alpha1.PendingConsolidation
(*v1.ExecutionPayloadHeaderGloas)(nil), // 31: ethereum.engine.v1.ExecutionPayloadHeaderGloas
}
var file_proto_prysm_v1alpha1_beacon_state_proto_depIdxs = []int32{
16, // 0: ethereum.eth.v1alpha1.BeaconState.fork:type_name -> ethereum.eth.v1alpha1.Fork
17, // 1: ethereum.eth.v1alpha1.BeaconState.latest_block_header:type_name -> ethereum.eth.v1alpha1.BeaconBlockHeader
18, // 2: ethereum.eth.v1alpha1.BeaconState.eth1_data:type_name -> ethereum.eth.v1alpha1.Eth1Data
18, // 3: ethereum.eth.v1alpha1.BeaconState.eth1_data_votes:type_name -> ethereum.eth.v1alpha1.Eth1Data
19, // 4: ethereum.eth.v1alpha1.BeaconState.validators:type_name -> ethereum.eth.v1alpha1.Validator
1, // 5: ethereum.eth.v1alpha1.BeaconState.previous_epoch_attestations:type_name -> ethereum.eth.v1alpha1.PendingAttestation
1, // 6: ethereum.eth.v1alpha1.BeaconState.current_epoch_attestations:type_name -> ethereum.eth.v1alpha1.PendingAttestation
20, // 7: ethereum.eth.v1alpha1.BeaconState.previous_justified_checkpoint:type_name -> ethereum.eth.v1alpha1.Checkpoint
20, // 8: ethereum.eth.v1alpha1.BeaconState.current_justified_checkpoint:type_name -> ethereum.eth.v1alpha1.Checkpoint
20, // 9: ethereum.eth.v1alpha1.BeaconState.finalized_checkpoint:type_name -> ethereum.eth.v1alpha1.Checkpoint
21, // 10: ethereum.eth.v1alpha1.PendingAttestation.data:type_name -> ethereum.eth.v1alpha1.AttestationData
16, // 11: ethereum.eth.v1alpha1.CheckPtInfo.fork:type_name -> ethereum.eth.v1alpha1.Fork
16, // 12: ethereum.eth.v1alpha1.BeaconStateAltair.fork:type_name -> ethereum.eth.v1alpha1.Fork
17, // 13: ethereum.eth.v1alpha1.BeaconStateAltair.latest_block_header:type_name -> ethereum.eth.v1alpha1.BeaconBlockHeader
18, // 14: ethereum.eth.v1alpha1.BeaconStateAltair.eth1_data:type_name -> ethereum.eth.v1alpha1.Eth1Data
18, // 15: ethereum.eth.v1alpha1.BeaconStateAltair.eth1_data_votes:type_name -> ethereum.eth.v1alpha1.Eth1Data
19, // 16: ethereum.eth.v1alpha1.BeaconStateAltair.validators:type_name -> ethereum.eth.v1alpha1.Validator
20, // 17: ethereum.eth.v1alpha1.BeaconStateAltair.previous_justified_checkpoint:type_name -> ethereum.eth.v1alpha1.Checkpoint
20, // 18: ethereum.eth.v1alpha1.BeaconStateAltair.current_justified_checkpoint:type_name -> ethereum.eth.v1alpha1.Checkpoint
20, // 19: ethereum.eth.v1alpha1.BeaconStateAltair.finalized_checkpoint:type_name -> ethereum.eth.v1alpha1.Checkpoint
22, // 20: ethereum.eth.v1alpha1.BeaconStateAltair.current_sync_committee:type_name -> ethereum.eth.v1alpha1.SyncCommittee
22, // 21: ethereum.eth.v1alpha1.BeaconStateAltair.next_sync_committee:type_name -> ethereum.eth.v1alpha1.SyncCommittee
16, // 22: ethereum.eth.v1alpha1.BeaconStateBellatrix.fork:type_name -> ethereum.eth.v1alpha1.Fork
17, // 23: ethereum.eth.v1alpha1.BeaconStateBellatrix.latest_block_header:type_name -> ethereum.eth.v1alpha1.BeaconBlockHeader
18, // 24: ethereum.eth.v1alpha1.BeaconStateBellatrix.eth1_data:type_name -> ethereum.eth.v1alpha1.Eth1Data
18, // 25: ethereum.eth.v1alpha1.BeaconStateBellatrix.eth1_data_votes:type_name -> ethereum.eth.v1alpha1.Eth1Data
19, // 26: ethereum.eth.v1alpha1.BeaconStateBellatrix.validators:type_name -> ethereum.eth.v1alpha1.Validator
20, // 27: ethereum.eth.v1alpha1.BeaconStateBellatrix.previous_justified_checkpoint:type_name -> ethereum.eth.v1alpha1.Checkpoint
20, // 28: ethereum.eth.v1alpha1.BeaconStateBellatrix.current_justified_checkpoint:type_name -> ethereum.eth.v1alpha1.Checkpoint
20, // 29: ethereum.eth.v1alpha1.BeaconStateBellatrix.finalized_checkpoint:type_name -> ethereum.eth.v1alpha1.Checkpoint
22, // 30: ethereum.eth.v1alpha1.BeaconStateBellatrix.current_sync_committee:type_name -> ethereum.eth.v1alpha1.SyncCommittee
22, // 31: ethereum.eth.v1alpha1.BeaconStateBellatrix.next_sync_committee:type_name -> ethereum.eth.v1alpha1.SyncCommittee
23, // 32: ethereum.eth.v1alpha1.BeaconStateBellatrix.latest_execution_payload_header:type_name -> ethereum.engine.v1.ExecutionPayloadHeader
16, // 33: ethereum.eth.v1alpha1.BeaconStateCapella.fork:type_name -> ethereum.eth.v1alpha1.Fork
17, // 34: ethereum.eth.v1alpha1.BeaconStateCapella.latest_block_header:type_name -> ethereum.eth.v1alpha1.BeaconBlockHeader
18, // 35: ethereum.eth.v1alpha1.BeaconStateCapella.eth1_data:type_name -> ethereum.eth.v1alpha1.Eth1Data
18, // 36: ethereum.eth.v1alpha1.BeaconStateCapella.eth1_data_votes:type_name -> ethereum.eth.v1alpha1.Eth1Data
19, // 37: ethereum.eth.v1alpha1.BeaconStateCapella.validators:type_name -> ethereum.eth.v1alpha1.Validator
20, // 38: ethereum.eth.v1alpha1.BeaconStateCapella.previous_justified_checkpoint:type_name -> ethereum.eth.v1alpha1.Checkpoint
20, // 39: ethereum.eth.v1alpha1.BeaconStateCapella.current_justified_checkpoint:type_name -> ethereum.eth.v1alpha1.Checkpoint
20, // 40: ethereum.eth.v1alpha1.BeaconStateCapella.finalized_checkpoint:type_name -> ethereum.eth.v1alpha1.Checkpoint
22, // 41: ethereum.eth.v1alpha1.BeaconStateCapella.current_sync_committee:type_name -> ethereum.eth.v1alpha1.SyncCommittee
22, // 42: ethereum.eth.v1alpha1.BeaconStateCapella.next_sync_committee:type_name -> ethereum.eth.v1alpha1.SyncCommittee
24, // 43: ethereum.eth.v1alpha1.BeaconStateCapella.latest_execution_payload_header:type_name -> ethereum.engine.v1.ExecutionPayloadHeaderCapella
25, // 44: ethereum.eth.v1alpha1.BeaconStateCapella.historical_summaries:type_name -> ethereum.eth.v1alpha1.HistoricalSummary
16, // 45: ethereum.eth.v1alpha1.BeaconStateDeneb.fork:type_name -> ethereum.eth.v1alpha1.Fork
17, // 46: ethereum.eth.v1alpha1.BeaconStateDeneb.latest_block_header:type_name -> ethereum.eth.v1alpha1.BeaconBlockHeader
18, // 47: ethereum.eth.v1alpha1.BeaconStateDeneb.eth1_data:type_name -> ethereum.eth.v1alpha1.Eth1Data
18, // 48: ethereum.eth.v1alpha1.BeaconStateDeneb.eth1_data_votes:type_name -> ethereum.eth.v1alpha1.Eth1Data
19, // 49: ethereum.eth.v1alpha1.BeaconStateDeneb.validators:type_name -> ethereum.eth.v1alpha1.Validator
20, // 50: ethereum.eth.v1alpha1.BeaconStateDeneb.previous_justified_checkpoint:type_name -> ethereum.eth.v1alpha1.Checkpoint
20, // 51: ethereum.eth.v1alpha1.BeaconStateDeneb.current_justified_checkpoint:type_name -> ethereum.eth.v1alpha1.Checkpoint
20, // 52: ethereum.eth.v1alpha1.BeaconStateDeneb.finalized_checkpoint:type_name -> ethereum.eth.v1alpha1.Checkpoint
22, // 53: ethereum.eth.v1alpha1.BeaconStateDeneb.current_sync_committee:type_name -> ethereum.eth.v1alpha1.SyncCommittee
22, // 54: ethereum.eth.v1alpha1.BeaconStateDeneb.next_sync_committee:type_name -> ethereum.eth.v1alpha1.SyncCommittee
26, // 55: ethereum.eth.v1alpha1.BeaconStateDeneb.latest_execution_payload_header:type_name -> ethereum.engine.v1.ExecutionPayloadHeaderDeneb
25, // 56: ethereum.eth.v1alpha1.BeaconStateDeneb.historical_summaries:type_name -> ethereum.eth.v1alpha1.HistoricalSummary
16, // 57: ethereum.eth.v1alpha1.BeaconStateElectra.fork:type_name -> ethereum.eth.v1alpha1.Fork
17, // 58: ethereum.eth.v1alpha1.BeaconStateElectra.latest_block_header:type_name -> ethereum.eth.v1alpha1.BeaconBlockHeader
18, // 59: ethereum.eth.v1alpha1.BeaconStateElectra.eth1_data:type_name -> ethereum.eth.v1alpha1.Eth1Data
18, // 60: ethereum.eth.v1alpha1.BeaconStateElectra.eth1_data_votes:type_name -> ethereum.eth.v1alpha1.Eth1Data
19, // 61: ethereum.eth.v1alpha1.BeaconStateElectra.validators:type_name -> ethereum.eth.v1alpha1.Validator
20, // 62: ethereum.eth.v1alpha1.BeaconStateElectra.previous_justified_checkpoint:type_name -> ethereum.eth.v1alpha1.Checkpoint
20, // 63: ethereum.eth.v1alpha1.BeaconStateElectra.current_justified_checkpoint:type_name -> ethereum.eth.v1alpha1.Checkpoint
20, // 64: ethereum.eth.v1alpha1.BeaconStateElectra.finalized_checkpoint:type_name -> ethereum.eth.v1alpha1.Checkpoint
22, // 65: ethereum.eth.v1alpha1.BeaconStateElectra.current_sync_committee:type_name -> ethereum.eth.v1alpha1.SyncCommittee
22, // 66: ethereum.eth.v1alpha1.BeaconStateElectra.next_sync_committee:type_name -> ethereum.eth.v1alpha1.SyncCommittee
26, // 67: ethereum.eth.v1alpha1.BeaconStateElectra.latest_execution_payload_header:type_name -> ethereum.engine.v1.ExecutionPayloadHeaderDeneb
25, // 68: ethereum.eth.v1alpha1.BeaconStateElectra.historical_summaries:type_name -> ethereum.eth.v1alpha1.HistoricalSummary
27, // 69: ethereum.eth.v1alpha1.BeaconStateElectra.pending_deposits:type_name -> ethereum.eth.v1alpha1.PendingDeposit
28, // 70: ethereum.eth.v1alpha1.BeaconStateElectra.pending_partial_withdrawals:type_name -> ethereum.eth.v1alpha1.PendingPartialWithdrawal
29, // 71: ethereum.eth.v1alpha1.BeaconStateElectra.pending_consolidations:type_name -> ethereum.eth.v1alpha1.PendingConsolidation
16, // 72: ethereum.eth.v1alpha1.BeaconStateFulu.fork:type_name -> ethereum.eth.v1alpha1.Fork
17, // 73: ethereum.eth.v1alpha1.BeaconStateFulu.latest_block_header:type_name -> ethereum.eth.v1alpha1.BeaconBlockHeader
18, // 74: ethereum.eth.v1alpha1.BeaconStateFulu.eth1_data:type_name -> ethereum.eth.v1alpha1.Eth1Data
18, // 75: ethereum.eth.v1alpha1.BeaconStateFulu.eth1_data_votes:type_name -> ethereum.eth.v1alpha1.Eth1Data
19, // 76: ethereum.eth.v1alpha1.BeaconStateFulu.validators:type_name -> ethereum.eth.v1alpha1.Validator
20, // 77: ethereum.eth.v1alpha1.BeaconStateFulu.previous_justified_checkpoint:type_name -> ethereum.eth.v1alpha1.Checkpoint
20, // 78: ethereum.eth.v1alpha1.BeaconStateFulu.current_justified_checkpoint:type_name -> ethereum.eth.v1alpha1.Checkpoint
20, // 79: ethereum.eth.v1alpha1.BeaconStateFulu.finalized_checkpoint:type_name -> ethereum.eth.v1alpha1.Checkpoint
22, // 80: ethereum.eth.v1alpha1.BeaconStateFulu.current_sync_committee:type_name -> ethereum.eth.v1alpha1.SyncCommittee
22, // 81: ethereum.eth.v1alpha1.BeaconStateFulu.next_sync_committee:type_name -> ethereum.eth.v1alpha1.SyncCommittee
26, // 82: ethereum.eth.v1alpha1.BeaconStateFulu.latest_execution_payload_header:type_name -> ethereum.engine.v1.ExecutionPayloadHeaderDeneb
25, // 83: ethereum.eth.v1alpha1.BeaconStateFulu.historical_summaries:type_name -> ethereum.eth.v1alpha1.HistoricalSummary
27, // 84: ethereum.eth.v1alpha1.BeaconStateFulu.pending_deposits:type_name -> ethereum.eth.v1alpha1.PendingDeposit
28, // 85: ethereum.eth.v1alpha1.BeaconStateFulu.pending_partial_withdrawals:type_name -> ethereum.eth.v1alpha1.PendingPartialWithdrawal
29, // 86: ethereum.eth.v1alpha1.BeaconStateFulu.pending_consolidations:type_name -> ethereum.eth.v1alpha1.PendingConsolidation
87, // [87:87] is the sub-list for method output_type
87, // [87:87] is the sub-list for method input_type
87, // [87:87] is the sub-list for extension type_name
87, // [87:87] is the sub-list for extension extendee
0, // [0:87] is the sub-list for field type_name
17, // 0: ethereum.eth.v1alpha1.BeaconState.fork:type_name -> ethereum.eth.v1alpha1.Fork
18, // 1: ethereum.eth.v1alpha1.BeaconState.latest_block_header:type_name -> ethereum.eth.v1alpha1.BeaconBlockHeader
19, // 2: ethereum.eth.v1alpha1.BeaconState.eth1_data:type_name -> ethereum.eth.v1alpha1.Eth1Data
19, // 3: ethereum.eth.v1alpha1.BeaconState.eth1_data_votes:type_name -> ethereum.eth.v1alpha1.Eth1Data
20, // 4: ethereum.eth.v1alpha1.BeaconState.validators:type_name -> ethereum.eth.v1alpha1.Validator
1, // 5: ethereum.eth.v1alpha1.BeaconState.previous_epoch_attestations:type_name -> ethereum.eth.v1alpha1.PendingAttestation
1, // 6: ethereum.eth.v1alpha1.BeaconState.current_epoch_attestations:type_name -> ethereum.eth.v1alpha1.PendingAttestation
21, // 7: ethereum.eth.v1alpha1.BeaconState.previous_justified_checkpoint:type_name -> ethereum.eth.v1alpha1.Checkpoint
21, // 8: ethereum.eth.v1alpha1.BeaconState.current_justified_checkpoint:type_name -> ethereum.eth.v1alpha1.Checkpoint
21, // 9: ethereum.eth.v1alpha1.BeaconState.finalized_checkpoint:type_name -> ethereum.eth.v1alpha1.Checkpoint
22, // 10: ethereum.eth.v1alpha1.PendingAttestation.data:type_name -> ethereum.eth.v1alpha1.AttestationData
17, // 11: ethereum.eth.v1alpha1.CheckPtInfo.fork:type_name -> ethereum.eth.v1alpha1.Fork
17, // 12: ethereum.eth.v1alpha1.BeaconStateAltair.fork:type_name -> ethereum.eth.v1alpha1.Fork
18, // 13: ethereum.eth.v1alpha1.BeaconStateAltair.latest_block_header:type_name -> ethereum.eth.v1alpha1.BeaconBlockHeader
19, // 14: ethereum.eth.v1alpha1.BeaconStateAltair.eth1_data:type_name -> ethereum.eth.v1alpha1.Eth1Data
19, // 15: ethereum.eth.v1alpha1.BeaconStateAltair.eth1_data_votes:type_name -> ethereum.eth.v1alpha1.Eth1Data
20, // 16: ethereum.eth.v1alpha1.BeaconStateAltair.validators:type_name -> ethereum.eth.v1alpha1.Validator
21, // 17: ethereum.eth.v1alpha1.BeaconStateAltair.previous_justified_checkpoint:type_name -> ethereum.eth.v1alpha1.Checkpoint
21, // 18: ethereum.eth.v1alpha1.BeaconStateAltair.current_justified_checkpoint:type_name -> ethereum.eth.v1alpha1.Checkpoint
21, // 19: ethereum.eth.v1alpha1.BeaconStateAltair.finalized_checkpoint:type_name -> ethereum.eth.v1alpha1.Checkpoint
23, // 20: ethereum.eth.v1alpha1.BeaconStateAltair.current_sync_committee:type_name -> ethereum.eth.v1alpha1.SyncCommittee
23, // 21: ethereum.eth.v1alpha1.BeaconStateAltair.next_sync_committee:type_name -> ethereum.eth.v1alpha1.SyncCommittee
17, // 22: ethereum.eth.v1alpha1.BeaconStateBellatrix.fork:type_name -> ethereum.eth.v1alpha1.Fork
18, // 23: ethereum.eth.v1alpha1.BeaconStateBellatrix.latest_block_header:type_name -> ethereum.eth.v1alpha1.BeaconBlockHeader
19, // 24: ethereum.eth.v1alpha1.BeaconStateBellatrix.eth1_data:type_name -> ethereum.eth.v1alpha1.Eth1Data
19, // 25: ethereum.eth.v1alpha1.BeaconStateBellatrix.eth1_data_votes:type_name -> ethereum.eth.v1alpha1.Eth1Data
20, // 26: ethereum.eth.v1alpha1.BeaconStateBellatrix.validators:type_name -> ethereum.eth.v1alpha1.Validator
21, // 27: ethereum.eth.v1alpha1.BeaconStateBellatrix.previous_justified_checkpoint:type_name -> ethereum.eth.v1alpha1.Checkpoint
21, // 28: ethereum.eth.v1alpha1.BeaconStateBellatrix.current_justified_checkpoint:type_name -> ethereum.eth.v1alpha1.Checkpoint
21, // 29: ethereum.eth.v1alpha1.BeaconStateBellatrix.finalized_checkpoint:type_name -> ethereum.eth.v1alpha1.Checkpoint
23, // 30: ethereum.eth.v1alpha1.BeaconStateBellatrix.current_sync_committee:type_name -> ethereum.eth.v1alpha1.SyncCommittee
23, // 31: ethereum.eth.v1alpha1.BeaconStateBellatrix.next_sync_committee:type_name -> ethereum.eth.v1alpha1.SyncCommittee
24, // 32: ethereum.eth.v1alpha1.BeaconStateBellatrix.latest_execution_payload_header:type_name -> ethereum.engine.v1.ExecutionPayloadHeader
17, // 33: ethereum.eth.v1alpha1.BeaconStateCapella.fork:type_name -> ethereum.eth.v1alpha1.Fork
18, // 34: ethereum.eth.v1alpha1.BeaconStateCapella.latest_block_header:type_name -> ethereum.eth.v1alpha1.BeaconBlockHeader
19, // 35: ethereum.eth.v1alpha1.BeaconStateCapella.eth1_data:type_name -> ethereum.eth.v1alpha1.Eth1Data
19, // 36: ethereum.eth.v1alpha1.BeaconStateCapella.eth1_data_votes:type_name -> ethereum.eth.v1alpha1.Eth1Data
20, // 37: ethereum.eth.v1alpha1.BeaconStateCapella.validators:type_name -> ethereum.eth.v1alpha1.Validator
21, // 38: ethereum.eth.v1alpha1.BeaconStateCapella.previous_justified_checkpoint:type_name -> ethereum.eth.v1alpha1.Checkpoint
21, // 39: ethereum.eth.v1alpha1.BeaconStateCapella.current_justified_checkpoint:type_name -> ethereum.eth.v1alpha1.Checkpoint
21, // 40: ethereum.eth.v1alpha1.BeaconStateCapella.finalized_checkpoint:type_name -> ethereum.eth.v1alpha1.Checkpoint
23, // 41: ethereum.eth.v1alpha1.BeaconStateCapella.current_sync_committee:type_name -> ethereum.eth.v1alpha1.SyncCommittee
23, // 42: ethereum.eth.v1alpha1.BeaconStateCapella.next_sync_committee:type_name -> ethereum.eth.v1alpha1.SyncCommittee
25, // 43: ethereum.eth.v1alpha1.BeaconStateCapella.latest_execution_payload_header:type_name -> ethereum.engine.v1.ExecutionPayloadHeaderCapella
26, // 44: ethereum.eth.v1alpha1.BeaconStateCapella.historical_summaries:type_name -> ethereum.eth.v1alpha1.HistoricalSummary
17, // 45: ethereum.eth.v1alpha1.BeaconStateDeneb.fork:type_name -> ethereum.eth.v1alpha1.Fork
18, // 46: ethereum.eth.v1alpha1.BeaconStateDeneb.latest_block_header:type_name -> ethereum.eth.v1alpha1.BeaconBlockHeader
19, // 47: ethereum.eth.v1alpha1.BeaconStateDeneb.eth1_data:type_name -> ethereum.eth.v1alpha1.Eth1Data
19, // 48: ethereum.eth.v1alpha1.BeaconStateDeneb.eth1_data_votes:type_name -> ethereum.eth.v1alpha1.Eth1Data
20, // 49: ethereum.eth.v1alpha1.BeaconStateDeneb.validators:type_name -> ethereum.eth.v1alpha1.Validator
21, // 50: ethereum.eth.v1alpha1.BeaconStateDeneb.previous_justified_checkpoint:type_name -> ethereum.eth.v1alpha1.Checkpoint
21, // 51: ethereum.eth.v1alpha1.BeaconStateDeneb.current_justified_checkpoint:type_name -> ethereum.eth.v1alpha1.Checkpoint
21, // 52: ethereum.eth.v1alpha1.BeaconStateDeneb.finalized_checkpoint:type_name -> ethereum.eth.v1alpha1.Checkpoint
23, // 53: ethereum.eth.v1alpha1.BeaconStateDeneb.current_sync_committee:type_name -> ethereum.eth.v1alpha1.SyncCommittee
23, // 54: ethereum.eth.v1alpha1.BeaconStateDeneb.next_sync_committee:type_name -> ethereum.eth.v1alpha1.SyncCommittee
27, // 55: ethereum.eth.v1alpha1.BeaconStateDeneb.latest_execution_payload_header:type_name -> ethereum.engine.v1.ExecutionPayloadHeaderDeneb
26, // 56: ethereum.eth.v1alpha1.BeaconStateDeneb.historical_summaries:type_name -> ethereum.eth.v1alpha1.HistoricalSummary
17, // 57: ethereum.eth.v1alpha1.BeaconStateElectra.fork:type_name -> ethereum.eth.v1alpha1.Fork
18, // 58: ethereum.eth.v1alpha1.BeaconStateElectra.latest_block_header:type_name -> ethereum.eth.v1alpha1.BeaconBlockHeader
19, // 59: ethereum.eth.v1alpha1.BeaconStateElectra.eth1_data:type_name -> ethereum.eth.v1alpha1.Eth1Data
19, // 60: ethereum.eth.v1alpha1.BeaconStateElectra.eth1_data_votes:type_name -> ethereum.eth.v1alpha1.Eth1Data
20, // 61: ethereum.eth.v1alpha1.BeaconStateElectra.validators:type_name -> ethereum.eth.v1alpha1.Validator
21, // 62: ethereum.eth.v1alpha1.BeaconStateElectra.previous_justified_checkpoint:type_name -> ethereum.eth.v1alpha1.Checkpoint
21, // 63: ethereum.eth.v1alpha1.BeaconStateElectra.current_justified_checkpoint:type_name -> ethereum.eth.v1alpha1.Checkpoint
21, // 64: ethereum.eth.v1alpha1.BeaconStateElectra.finalized_checkpoint:type_name -> ethereum.eth.v1alpha1.Checkpoint
23, // 65: ethereum.eth.v1alpha1.BeaconStateElectra.current_sync_committee:type_name -> ethereum.eth.v1alpha1.SyncCommittee
23, // 66: ethereum.eth.v1alpha1.BeaconStateElectra.next_sync_committee:type_name -> ethereum.eth.v1alpha1.SyncCommittee
27, // 67: ethereum.eth.v1alpha1.BeaconStateElectra.latest_execution_payload_header:type_name -> ethereum.engine.v1.ExecutionPayloadHeaderDeneb
26, // 68: ethereum.eth.v1alpha1.BeaconStateElectra.historical_summaries:type_name -> ethereum.eth.v1alpha1.HistoricalSummary
28, // 69: ethereum.eth.v1alpha1.BeaconStateElectra.pending_deposits:type_name -> ethereum.eth.v1alpha1.PendingDeposit
29, // 70: ethereum.eth.v1alpha1.BeaconStateElectra.pending_partial_withdrawals:type_name -> ethereum.eth.v1alpha1.PendingPartialWithdrawal
30, // 71: ethereum.eth.v1alpha1.BeaconStateElectra.pending_consolidations:type_name -> ethereum.eth.v1alpha1.PendingConsolidation
17, // 72: ethereum.eth.v1alpha1.BeaconStateFulu.fork:type_name -> ethereum.eth.v1alpha1.Fork
18, // 73: ethereum.eth.v1alpha1.BeaconStateFulu.latest_block_header:type_name -> ethereum.eth.v1alpha1.BeaconBlockHeader
19, // 74: ethereum.eth.v1alpha1.BeaconStateFulu.eth1_data:type_name -> ethereum.eth.v1alpha1.Eth1Data
19, // 75: ethereum.eth.v1alpha1.BeaconStateFulu.eth1_data_votes:type_name -> ethereum.eth.v1alpha1.Eth1Data
20, // 76: ethereum.eth.v1alpha1.BeaconStateFulu.validators:type_name -> ethereum.eth.v1alpha1.Validator
21, // 77: ethereum.eth.v1alpha1.BeaconStateFulu.previous_justified_checkpoint:type_name -> ethereum.eth.v1alpha1.Checkpoint
21, // 78: ethereum.eth.v1alpha1.BeaconStateFulu.current_justified_checkpoint:type_name -> ethereum.eth.v1alpha1.Checkpoint
21, // 79: ethereum.eth.v1alpha1.BeaconStateFulu.finalized_checkpoint:type_name -> ethereum.eth.v1alpha1.Checkpoint
23, // 80: ethereum.eth.v1alpha1.BeaconStateFulu.current_sync_committee:type_name -> ethereum.eth.v1alpha1.SyncCommittee
23, // 81: ethereum.eth.v1alpha1.BeaconStateFulu.next_sync_committee:type_name -> ethereum.eth.v1alpha1.SyncCommittee
27, // 82: ethereum.eth.v1alpha1.BeaconStateFulu.latest_execution_payload_header:type_name -> ethereum.engine.v1.ExecutionPayloadHeaderDeneb
26, // 83: ethereum.eth.v1alpha1.BeaconStateFulu.historical_summaries:type_name -> ethereum.eth.v1alpha1.HistoricalSummary
28, // 84: ethereum.eth.v1alpha1.BeaconStateFulu.pending_deposits:type_name -> ethereum.eth.v1alpha1.PendingDeposit
29, // 85: ethereum.eth.v1alpha1.BeaconStateFulu.pending_partial_withdrawals:type_name -> ethereum.eth.v1alpha1.PendingPartialWithdrawal
30, // 86: ethereum.eth.v1alpha1.BeaconStateFulu.pending_consolidations:type_name -> ethereum.eth.v1alpha1.PendingConsolidation
17, // 87: ethereum.eth.v1alpha1.BeaconStateGloas.fork:type_name -> ethereum.eth.v1alpha1.Fork
18, // 88: ethereum.eth.v1alpha1.BeaconStateGloas.latest_block_header:type_name -> ethereum.eth.v1alpha1.BeaconBlockHeader
19, // 89: ethereum.eth.v1alpha1.BeaconStateGloas.eth1_data:type_name -> ethereum.eth.v1alpha1.Eth1Data
19, // 90: ethereum.eth.v1alpha1.BeaconStateGloas.eth1_data_votes:type_name -> ethereum.eth.v1alpha1.Eth1Data
20, // 91: ethereum.eth.v1alpha1.BeaconStateGloas.validators:type_name -> ethereum.eth.v1alpha1.Validator
21, // 92: ethereum.eth.v1alpha1.BeaconStateGloas.previous_justified_checkpoint:type_name -> ethereum.eth.v1alpha1.Checkpoint
21, // 93: ethereum.eth.v1alpha1.BeaconStateGloas.current_justified_checkpoint:type_name -> ethereum.eth.v1alpha1.Checkpoint
21, // 94: ethereum.eth.v1alpha1.BeaconStateGloas.finalized_checkpoint:type_name -> ethereum.eth.v1alpha1.Checkpoint
23, // 95: ethereum.eth.v1alpha1.BeaconStateGloas.current_sync_committee:type_name -> ethereum.eth.v1alpha1.SyncCommittee
23, // 96: ethereum.eth.v1alpha1.BeaconStateGloas.next_sync_committee:type_name -> ethereum.eth.v1alpha1.SyncCommittee
31, // 97: ethereum.eth.v1alpha1.BeaconStateGloas.latest_execution_payload_header:type_name -> ethereum.engine.v1.ExecutionPayloadHeaderGloas
26, // 98: ethereum.eth.v1alpha1.BeaconStateGloas.historical_summaries:type_name -> ethereum.eth.v1alpha1.HistoricalSummary
28, // 99: ethereum.eth.v1alpha1.BeaconStateGloas.pending_deposits:type_name -> ethereum.eth.v1alpha1.PendingDeposit
29, // 100: ethereum.eth.v1alpha1.BeaconStateGloas.pending_partial_withdrawals:type_name -> ethereum.eth.v1alpha1.PendingPartialWithdrawal
30, // 101: ethereum.eth.v1alpha1.BeaconStateGloas.pending_consolidations:type_name -> ethereum.eth.v1alpha1.PendingConsolidation
102, // [102:102] is the sub-list for method output_type
102, // [102:102] is the sub-list for method input_type
102, // [102:102] is the sub-list for extension type_name
102, // [102:102] is the sub-list for extension extendee
0, // [0:102] is the sub-list for field type_name
}
func init() { file_proto_prysm_v1alpha1_beacon_state_proto_init() }
@@ -3696,7 +4260,7 @@ func file_proto_prysm_v1alpha1_beacon_state_proto_init() {
GoPackagePath: reflect.TypeOf(x{}).PkgPath(),
RawDescriptor: file_proto_prysm_v1alpha1_beacon_state_proto_rawDesc,
NumEnums: 0,
NumMessages: 16,
NumMessages: 17,
NumExtensions: 0,
NumServices: 0,
},

View File

@@ -723,3 +723,119 @@ message BeaconStateFulu {
repeated uint64 proposer_lookahead = 13001
[ (ethereum.eth.ext.ssz_size) = "proposer_lookahead_size" ];
}
// ----------------------------------------------------------------------------
// Gloas
// ----------------------------------------------------------------------------
message BeaconStateGloas {
// Versioning [1001-2000]
uint64 genesis_time = 1001;
bytes genesis_validators_root = 1002 [ (ethereum.eth.ext.ssz_size) = "32" ];
uint64 slot = 1003 [
(ethereum.eth.ext.cast_type) =
"github.com/OffchainLabs/prysm/v6/consensus-types/primitives.Slot"
];
Fork fork = 1004;
// History [2001-3000]
BeaconBlockHeader latest_block_header = 2001;
repeated bytes block_roots = 2002
[ (ethereum.eth.ext.ssz_size) = "block_roots.size" ];
repeated bytes state_roots = 2003
[ (ethereum.eth.ext.ssz_size) = "state_roots.size" ];
repeated bytes historical_roots = 2004 [
(ethereum.eth.ext.ssz_size) = "?,32",
(ethereum.eth.ext.ssz_max) = "16777216"
];
// Eth1 [3001-4000]
Eth1Data eth1_data = 3001;
repeated Eth1Data eth1_data_votes = 3002
[ (ethereum.eth.ext.ssz_max) = "eth1_data_votes.size" ];
uint64 eth1_deposit_index = 3003;
// Registry [4001-5000]
repeated Validator validators = 4001
[ (ethereum.eth.ext.ssz_max) = "1099511627776" ];
repeated uint64 balances = 4002
[ (ethereum.eth.ext.ssz_max) = "1099511627776" ];
// Randomness [5001-6000]
repeated bytes randao_mixes = 5001
[ (ethereum.eth.ext.ssz_size) = "randao_mixes.size" ];
// Slashings [6001-7000]
repeated uint64 slashings = 6001
[ (ethereum.eth.ext.ssz_size) = "slashings.size" ];
// Participation [7001-8000]
bytes previous_epoch_participation = 7001
[ (ethereum.eth.ext.ssz_max) = "1099511627776" ];
bytes current_epoch_participation = 7002
[ (ethereum.eth.ext.ssz_max) = "1099511627776" ];
// Finality [8001-9000]
// Spec type [4]Bitvector which means this would be a fixed size of 4 bits.
bytes justification_bits = 8001 [
(ethereum.eth.ext.ssz_size) = "1",
(ethereum.eth.ext.cast_type) =
"github.com/prysmaticlabs/go-bitfield.Bitvector4"
];
Checkpoint previous_justified_checkpoint = 8002;
Checkpoint current_justified_checkpoint = 8003;
Checkpoint finalized_checkpoint = 8004;
// Fields introduced in Altair fork [9001-10000]
repeated uint64 inactivity_scores = 9001
[ (ethereum.eth.ext.ssz_max) = "1099511627776" ];
SyncCommittee current_sync_committee = 9002;
SyncCommittee next_sync_committee = 9003;
// Fields introduced in Bellatrix fork [10001-11000]
// [Modified in EIP7928] - Gloas uses ExecutionPayloadHeaderGloas
ethereum.engine.v1.ExecutionPayloadHeaderGloas
latest_execution_payload_header = 10001;
// Fields introduced in Capella fork [11001-12000]
uint64 next_withdrawal_index = 11001;
uint64 next_withdrawal_validator_index = 11002
[ (ethereum.eth.ext.cast_type) =
"github.com/OffchainLabs/prysm/v6/consensus-types/"
"primitives.ValidatorIndex" ];
repeated HistoricalSummary historical_summaries = 11003
[ (ethereum.eth.ext.ssz_max) = "16777216" ];
// Fields introduced in Electra fork [12001-13000]
uint64 deposit_requests_start_index = 12001;
uint64 deposit_balance_to_consume = 12002 [
(ethereum.eth.ext.cast_type) =
"github.com/OffchainLabs/prysm/v6/consensus-types/primitives.Gwei"
];
uint64 exit_balance_to_consume = 12003 [
(ethereum.eth.ext.cast_type) =
"github.com/OffchainLabs/prysm/v6/consensus-types/primitives.Gwei"
];
uint64 earliest_exit_epoch = 12004 [
(ethereum.eth.ext.cast_type) =
"github.com/OffchainLabs/prysm/v6/consensus-types/primitives.Epoch"
];
uint64 consolidation_balance_to_consume = 12005 [
(ethereum.eth.ext.cast_type) =
"github.com/OffchainLabs/prysm/v6/consensus-types/primitives.Gwei"
];
uint64 earliest_consolidation_epoch = 12006 [
(ethereum.eth.ext.cast_type) =
"github.com/OffchainLabs/prysm/v6/consensus-types/primitives.Epoch"
];
repeated PendingDeposit pending_deposits = 12007
[ (ethereum.eth.ext.ssz_max) = "pending_deposits_limit" ];
repeated PendingPartialWithdrawal pending_partial_withdrawals = 12008
[ (ethereum.eth.ext.ssz_max) = "pending_partial_withdrawals_limit" ];
repeated PendingConsolidation pending_consolidations = 12009
[ (ethereum.eth.ext.ssz_max) = "pending_consolidations_limit" ];
// Fields introduced in Fulu fork [13001-14000]
repeated uint64 proposer_lookahead = 13001
[ (ethereum.eth.ext.ssz_size) = "proposer_lookahead_size" ];
}

File diff suppressed because it is too large Load Diff

View File

@@ -106,6 +106,7 @@ type SignRequest struct {
// *SignRequest_AggregateAttestationAndProofElectra
// *SignRequest_BlockFulu
// *SignRequest_BlindedBlockFulu
// *SignRequest_BlockGloas
Object isSignRequest_Object `protobuf_oneof:"object"`
SigningSlot github_com_OffchainLabs_prysm_v6_consensus_types_primitives.Slot `protobuf:"varint,6,opt,name=signing_slot,json=signingSlot,proto3" json:"signing_slot,omitempty" cast-type:"github.com/OffchainLabs/prysm/v6/consensus-types/primitives.Slot"`
unknownFields protoimpl.UnknownFields
@@ -368,6 +369,15 @@ func (x *SignRequest) GetBlindedBlockFulu() *v1alpha1.BlindedBeaconBlockFulu {
return nil
}
func (x *SignRequest) GetBlockGloas() *v1alpha1.BeaconBlockGloas {
if x != nil {
if x, ok := x.Object.(*SignRequest_BlockGloas); ok {
return x.BlockGloas
}
}
return nil
}
func (x *SignRequest) GetSigningSlot() github_com_OffchainLabs_prysm_v6_consensus_types_primitives.Slot {
if x != nil {
return x.SigningSlot
@@ -467,6 +477,10 @@ type SignRequest_BlindedBlockFulu struct {
BlindedBlockFulu *v1alpha1.BlindedBeaconBlockFulu `protobuf:"bytes,122,opt,name=blinded_block_fulu,json=blindedBlockFulu,proto3,oneof"`
}
type SignRequest_BlockGloas struct {
BlockGloas *v1alpha1.BeaconBlockGloas `protobuf:"bytes,123,opt,name=block_gloas,json=blockGloas,proto3,oneof"`
}
func (*SignRequest_Block) isSignRequest_Object() {}
func (*SignRequest_AttestationData) isSignRequest_Object() {}
@@ -511,6 +525,8 @@ func (*SignRequest_BlockFulu) isSignRequest_Object() {}
func (*SignRequest_BlindedBlockFulu) isSignRequest_Object() {}
func (*SignRequest_BlockGloas) isSignRequest_Object() {}
type SignResponse struct {
state protoimpl.MessageState `protogen:"open.v1"`
Signature []byte `protobuf:"bytes,1,opt,name=signature,proto3" json:"signature,omitempty"`
@@ -758,7 +774,7 @@ var file_proto_prysm_v1alpha1_validator_client_keymanager_proto_rawDesc = []byte
0x6e, 0x5f, 0x73, 0x74, 0x61, 0x74, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x29, 0x70,
0x72, 0x6f, 0x74, 0x6f, 0x2f, 0x70, 0x72, 0x79, 0x73, 0x6d, 0x2f, 0x76, 0x31, 0x61, 0x6c, 0x70,
0x68, 0x61, 0x31, 0x2f, 0x73, 0x79, 0x6e, 0x63, 0x5f, 0x63, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x74,
0x65, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22, 0xe5, 0x11, 0x0a, 0x0b, 0x53, 0x69, 0x67,
0x65, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22, 0xb1, 0x12, 0x0a, 0x0b, 0x53, 0x69, 0x67,
0x6e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x1d, 0x0a, 0x0a, 0x70, 0x75, 0x62, 0x6c,
0x69, 0x63, 0x5f, 0x6b, 0x65, 0x79, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x09, 0x70, 0x75,
0x62, 0x6c, 0x69, 0x63, 0x4b, 0x65, 0x79, 0x12, 0x21, 0x0a, 0x0c, 0x73, 0x69, 0x67, 0x6e, 0x69,
@@ -893,84 +909,89 @@ var file_proto_prysm_v1alpha1_validator_client_keymanager_proto_rawDesc = []byte
0x61, 0x6c, 0x70, 0x68, 0x61, 0x31, 0x2e, 0x42, 0x6c, 0x69, 0x6e, 0x64, 0x65, 0x64, 0x42, 0x65,
0x61, 0x63, 0x6f, 0x6e, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x46, 0x75, 0x6c, 0x75, 0x48, 0x00, 0x52,
0x10, 0x62, 0x6c, 0x69, 0x6e, 0x64, 0x65, 0x64, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x46, 0x75, 0x6c,
0x75, 0x12, 0x67, 0x0a, 0x0c, 0x73, 0x69, 0x67, 0x6e, 0x69, 0x6e, 0x67, 0x5f, 0x73, 0x6c, 0x6f,
0x74, 0x18, 0x06, 0x20, 0x01, 0x28, 0x04, 0x42, 0x44, 0x82, 0xb5, 0x18, 0x40, 0x67, 0x69, 0x74,
0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x4f, 0x66, 0x66, 0x63, 0x68, 0x61, 0x69, 0x6e,
0x4c, 0x61, 0x62, 0x73, 0x2f, 0x70, 0x72, 0x79, 0x73, 0x6d, 0x2f, 0x76, 0x36, 0x2f, 0x63, 0x6f,
0x6e, 0x73, 0x65, 0x6e, 0x73, 0x75, 0x73, 0x2d, 0x74, 0x79, 0x70, 0x65, 0x73, 0x2f, 0x70, 0x72,
0x69, 0x6d, 0x69, 0x74, 0x69, 0x76, 0x65, 0x73, 0x2e, 0x53, 0x6c, 0x6f, 0x74, 0x52, 0x0b, 0x73,
0x69, 0x67, 0x6e, 0x69, 0x6e, 0x67, 0x53, 0x6c, 0x6f, 0x74, 0x42, 0x08, 0x0a, 0x06, 0x6f, 0x62,
0x6a, 0x65, 0x63, 0x74, 0x4a, 0x04, 0x08, 0x04, 0x10, 0x05, 0x4a, 0x04, 0x08, 0x05, 0x10, 0x06,
0x22, 0xb7, 0x01, 0x0a, 0x0c, 0x53, 0x69, 0x67, 0x6e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73,
0x65, 0x12, 0x1c, 0x0a, 0x09, 0x73, 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x18, 0x01,
0x20, 0x01, 0x28, 0x0c, 0x52, 0x09, 0x73, 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x12,
0x4b, 0x0a, 0x06, 0x73, 0x74, 0x61, 0x74, 0x75, 0x73, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0e, 0x32,
0x33, 0x2e, 0x65, 0x74, 0x68, 0x65, 0x72, 0x65, 0x75, 0x6d, 0x2e, 0x76, 0x61, 0x6c, 0x69, 0x64,
0x61, 0x74, 0x6f, 0x72, 0x2e, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x73, 0x2e, 0x76, 0x32,
0x2e, 0x53, 0x69, 0x67, 0x6e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x2e, 0x53, 0x74,
0x61, 0x74, 0x75, 0x73, 0x52, 0x06, 0x73, 0x74, 0x61, 0x74, 0x75, 0x73, 0x22, 0x3c, 0x0a, 0x06,
0x53, 0x74, 0x61, 0x74, 0x75, 0x73, 0x12, 0x0b, 0x0a, 0x07, 0x55, 0x4e, 0x4b, 0x4e, 0x4f, 0x57,
0x4e, 0x10, 0x00, 0x12, 0x0d, 0x0a, 0x09, 0x53, 0x55, 0x43, 0x43, 0x45, 0x45, 0x44, 0x45, 0x44,
0x10, 0x01, 0x12, 0x0a, 0x0a, 0x06, 0x44, 0x45, 0x4e, 0x49, 0x45, 0x44, 0x10, 0x02, 0x12, 0x0a,
0x0a, 0x06, 0x46, 0x41, 0x49, 0x4c, 0x45, 0x44, 0x10, 0x03, 0x22, 0xb3, 0x01, 0x0a, 0x15, 0x50,
0x72, 0x6f, 0x70, 0x6f, 0x73, 0x65, 0x72, 0x4f, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x50, 0x61, 0x79,
0x6c, 0x6f, 0x61, 0x64, 0x12, 0x23, 0x0a, 0x0d, 0x66, 0x65, 0x65, 0x5f, 0x72, 0x65, 0x63, 0x69,
0x70, 0x69, 0x65, 0x6e, 0x74, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, 0x66, 0x65, 0x65,
0x52, 0x65, 0x63, 0x69, 0x70, 0x69, 0x65, 0x6e, 0x74, 0x12, 0x47, 0x0a, 0x07, 0x62, 0x75, 0x69,
0x6c, 0x64, 0x65, 0x72, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x2d, 0x2e, 0x65, 0x74, 0x68,
0x65, 0x72, 0x65, 0x75, 0x6d, 0x2e, 0x76, 0x61, 0x6c, 0x69, 0x64, 0x61, 0x74, 0x6f, 0x72, 0x2e,
0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x73, 0x2e, 0x76, 0x32, 0x2e, 0x42, 0x75, 0x69, 0x6c,
0x64, 0x65, 0x72, 0x43, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x52, 0x07, 0x62, 0x75, 0x69, 0x6c, 0x64,
0x65, 0x72, 0x12, 0x1f, 0x0a, 0x08, 0x67, 0x72, 0x61, 0x66, 0x66, 0x69, 0x74, 0x69, 0x18, 0x03,
0x20, 0x01, 0x28, 0x09, 0x48, 0x00, 0x52, 0x08, 0x67, 0x72, 0x61, 0x66, 0x66, 0x69, 0x74, 0x69,
0x88, 0x01, 0x01, 0x42, 0x0b, 0x0a, 0x09, 0x5f, 0x67, 0x72, 0x61, 0x66, 0x66, 0x69, 0x74, 0x69,
0x22, 0xa5, 0x01, 0x0a, 0x0d, 0x42, 0x75, 0x69, 0x6c, 0x64, 0x65, 0x72, 0x43, 0x6f, 0x6e, 0x66,
0x69, 0x67, 0x12, 0x18, 0x0a, 0x07, 0x65, 0x6e, 0x61, 0x62, 0x6c, 0x65, 0x64, 0x18, 0x01, 0x20,
0x01, 0x28, 0x08, 0x52, 0x07, 0x65, 0x6e, 0x61, 0x62, 0x6c, 0x65, 0x64, 0x12, 0x62, 0x0a, 0x09,
0x67, 0x61, 0x73, 0x5f, 0x6c, 0x69, 0x6d, 0x69, 0x74, 0x18, 0x02, 0x20, 0x01, 0x28, 0x04, 0x42,
0x45, 0x82, 0xb5, 0x18, 0x41, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f,
0x4f, 0x66, 0x66, 0x63, 0x68, 0x61, 0x69, 0x6e, 0x4c, 0x61, 0x62, 0x73, 0x2f, 0x70, 0x72, 0x79,
0x73, 0x6d, 0x2f, 0x76, 0x36, 0x2f, 0x63, 0x6f, 0x6e, 0x73, 0x65, 0x6e, 0x73, 0x75, 0x73, 0x2d,
0x74, 0x79, 0x70, 0x65, 0x73, 0x2f, 0x76, 0x61, 0x6c, 0x69, 0x64, 0x61, 0x74, 0x6f, 0x72, 0x2e,
0x55, 0x69, 0x6e, 0x74, 0x36, 0x34, 0x52, 0x08, 0x67, 0x61, 0x73, 0x4c, 0x69, 0x6d, 0x69, 0x74,
0x12, 0x16, 0x0a, 0x06, 0x72, 0x65, 0x6c, 0x61, 0x79, 0x73, 0x18, 0x03, 0x20, 0x03, 0x28, 0x09,
0x52, 0x06, 0x72, 0x65, 0x6c, 0x61, 0x79, 0x73, 0x22, 0xe7, 0x02, 0x0a, 0x17, 0x50, 0x72, 0x6f,
0x70, 0x6f, 0x73, 0x65, 0x72, 0x53, 0x65, 0x74, 0x74, 0x69, 0x6e, 0x67, 0x73, 0x50, 0x61, 0x79,
0x6c, 0x6f, 0x61, 0x64, 0x12, 0x74, 0x0a, 0x0f, 0x70, 0x72, 0x6f, 0x70, 0x6f, 0x73, 0x65, 0x72,
0x5f, 0x63, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x4b, 0x2e,
0x65, 0x74, 0x68, 0x65, 0x72, 0x65, 0x75, 0x6d, 0x2e, 0x76, 0x61, 0x6c, 0x69, 0x64, 0x61, 0x74,
0x6f, 0x72, 0x2e, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x73, 0x2e, 0x76, 0x32, 0x2e, 0x50,
0x72, 0x6f, 0x70, 0x6f, 0x73, 0x65, 0x72, 0x53, 0x65, 0x74, 0x74, 0x69, 0x6e, 0x67, 0x73, 0x50,
0x61, 0x79, 0x6c, 0x6f, 0x61, 0x64, 0x2e, 0x50, 0x72, 0x6f, 0x70, 0x6f, 0x73, 0x65, 0x72, 0x43,
0x6f, 0x6e, 0x66, 0x69, 0x67, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x52, 0x0e, 0x70, 0x72, 0x6f, 0x70,
0x6f, 0x73, 0x65, 0x72, 0x43, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x12, 0x5c, 0x0a, 0x0e, 0x64, 0x65,
0x66, 0x61, 0x75, 0x6c, 0x74, 0x5f, 0x63, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x18, 0x02, 0x20, 0x01,
0x28, 0x0b, 0x32, 0x35, 0x2e, 0x65, 0x74, 0x68, 0x65, 0x72, 0x65, 0x75, 0x6d, 0x2e, 0x76, 0x61,
0x6c, 0x69, 0x64, 0x61, 0x74, 0x6f, 0x72, 0x2e, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x73,
0x2e, 0x76, 0x32, 0x2e, 0x50, 0x72, 0x6f, 0x70, 0x6f, 0x73, 0x65, 0x72, 0x4f, 0x70, 0x74, 0x69,
0x6f, 0x6e, 0x50, 0x61, 0x79, 0x6c, 0x6f, 0x61, 0x64, 0x52, 0x0d, 0x64, 0x65, 0x66, 0x61, 0x75,
0x6c, 0x74, 0x43, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x1a, 0x78, 0x0a, 0x13, 0x50, 0x72, 0x6f, 0x70,
0x6f, 0x73, 0x65, 0x72, 0x43, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x12,
0x10, 0x0a, 0x03, 0x6b, 0x65, 0x79, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x03, 0x6b, 0x65,
0x79, 0x12, 0x4b, 0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b,
0x32, 0x35, 0x2e, 0x65, 0x74, 0x68, 0x65, 0x72, 0x65, 0x75, 0x6d, 0x2e, 0x76, 0x61, 0x6c, 0x69,
0x64, 0x61, 0x74, 0x6f, 0x72, 0x2e, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x73, 0x2e, 0x76,
0x32, 0x2e, 0x50, 0x72, 0x6f, 0x70, 0x6f, 0x73, 0x65, 0x72, 0x4f, 0x70, 0x74, 0x69, 0x6f, 0x6e,
0x50, 0x61, 0x79, 0x6c, 0x6f, 0x61, 0x64, 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x3a, 0x02,
0x38, 0x01, 0x42, 0xcd, 0x01, 0x0a, 0x22, 0x6f, 0x72, 0x67, 0x2e, 0x65, 0x74, 0x68, 0x65, 0x72,
0x65, 0x75, 0x6d, 0x2e, 0x76, 0x61, 0x6c, 0x69, 0x64, 0x61, 0x74, 0x6f, 0x72, 0x2e, 0x61, 0x63,
0x63, 0x6f, 0x75, 0x6e, 0x74, 0x73, 0x2e, 0x76, 0x32, 0x42, 0x0f, 0x4b, 0x65, 0x79, 0x6d, 0x61,
0x6e, 0x61, 0x67, 0x65, 0x72, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x50, 0x01, 0x5a, 0x52, 0x67, 0x69,
0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x4f, 0x66, 0x66, 0x63, 0x68, 0x61, 0x69,
0x6e, 0x4c, 0x61, 0x62, 0x73, 0x2f, 0x70, 0x72, 0x79, 0x73, 0x6d, 0x2f, 0x76, 0x36, 0x2f, 0x70,
0x72, 0x6f, 0x74, 0x6f, 0x2f, 0x70, 0x72, 0x79, 0x73, 0x6d, 0x2f, 0x76, 0x31, 0x61, 0x6c, 0x70,
0x68, 0x61, 0x31, 0x2f, 0x76, 0x61, 0x6c, 0x69, 0x64, 0x61, 0x74, 0x6f, 0x72, 0x2d, 0x63, 0x6c,
0x69, 0x65, 0x6e, 0x74, 0x3b, 0x76, 0x61, 0x6c, 0x69, 0x64, 0x61, 0x74, 0x6f, 0x72, 0x70, 0x62,
0xaa, 0x02, 0x1e, 0x45, 0x74, 0x68, 0x65, 0x72, 0x65, 0x75, 0x6d, 0x2e, 0x56, 0x61, 0x6c, 0x69,
0x64, 0x61, 0x74, 0x6f, 0x72, 0x2e, 0x41, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x73, 0x2e, 0x56,
0x32, 0xca, 0x02, 0x1e, 0x45, 0x74, 0x68, 0x65, 0x72, 0x65, 0x75, 0x6d, 0x5c, 0x56, 0x61, 0x6c,
0x69, 0x64, 0x61, 0x74, 0x6f, 0x72, 0x5c, 0x41, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x73, 0x5c,
0x56, 0x32, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33,
0x75, 0x12, 0x4a, 0x0a, 0x0b, 0x62, 0x6c, 0x6f, 0x63, 0x6b, 0x5f, 0x67, 0x6c, 0x6f, 0x61, 0x73,
0x18, 0x7b, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x27, 0x2e, 0x65, 0x74, 0x68, 0x65, 0x72, 0x65, 0x75,
0x6d, 0x2e, 0x65, 0x74, 0x68, 0x2e, 0x76, 0x31, 0x61, 0x6c, 0x70, 0x68, 0x61, 0x31, 0x2e, 0x42,
0x65, 0x61, 0x63, 0x6f, 0x6e, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x47, 0x6c, 0x6f, 0x61, 0x73, 0x48,
0x00, 0x52, 0x0a, 0x62, 0x6c, 0x6f, 0x63, 0x6b, 0x47, 0x6c, 0x6f, 0x61, 0x73, 0x12, 0x67, 0x0a,
0x0c, 0x73, 0x69, 0x67, 0x6e, 0x69, 0x6e, 0x67, 0x5f, 0x73, 0x6c, 0x6f, 0x74, 0x18, 0x06, 0x20,
0x01, 0x28, 0x04, 0x42, 0x44, 0x82, 0xb5, 0x18, 0x40, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e,
0x63, 0x6f, 0x6d, 0x2f, 0x4f, 0x66, 0x66, 0x63, 0x68, 0x61, 0x69, 0x6e, 0x4c, 0x61, 0x62, 0x73,
0x2f, 0x70, 0x72, 0x79, 0x73, 0x6d, 0x2f, 0x76, 0x36, 0x2f, 0x63, 0x6f, 0x6e, 0x73, 0x65, 0x6e,
0x73, 0x75, 0x73, 0x2d, 0x74, 0x79, 0x70, 0x65, 0x73, 0x2f, 0x70, 0x72, 0x69, 0x6d, 0x69, 0x74,
0x69, 0x76, 0x65, 0x73, 0x2e, 0x53, 0x6c, 0x6f, 0x74, 0x52, 0x0b, 0x73, 0x69, 0x67, 0x6e, 0x69,
0x6e, 0x67, 0x53, 0x6c, 0x6f, 0x74, 0x42, 0x08, 0x0a, 0x06, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74,
0x4a, 0x04, 0x08, 0x04, 0x10, 0x05, 0x4a, 0x04, 0x08, 0x05, 0x10, 0x06, 0x22, 0xb7, 0x01, 0x0a,
0x0c, 0x53, 0x69, 0x67, 0x6e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x1c, 0x0a,
0x09, 0x73, 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0c,
0x52, 0x09, 0x73, 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x12, 0x4b, 0x0a, 0x06, 0x73,
0x74, 0x61, 0x74, 0x75, 0x73, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0e, 0x32, 0x33, 0x2e, 0x65, 0x74,
0x68, 0x65, 0x72, 0x65, 0x75, 0x6d, 0x2e, 0x76, 0x61, 0x6c, 0x69, 0x64, 0x61, 0x74, 0x6f, 0x72,
0x2e, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x73, 0x2e, 0x76, 0x32, 0x2e, 0x53, 0x69, 0x67,
0x6e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x2e, 0x53, 0x74, 0x61, 0x74, 0x75, 0x73,
0x52, 0x06, 0x73, 0x74, 0x61, 0x74, 0x75, 0x73, 0x22, 0x3c, 0x0a, 0x06, 0x53, 0x74, 0x61, 0x74,
0x75, 0x73, 0x12, 0x0b, 0x0a, 0x07, 0x55, 0x4e, 0x4b, 0x4e, 0x4f, 0x57, 0x4e, 0x10, 0x00, 0x12,
0x0d, 0x0a, 0x09, 0x53, 0x55, 0x43, 0x43, 0x45, 0x45, 0x44, 0x45, 0x44, 0x10, 0x01, 0x12, 0x0a,
0x0a, 0x06, 0x44, 0x45, 0x4e, 0x49, 0x45, 0x44, 0x10, 0x02, 0x12, 0x0a, 0x0a, 0x06, 0x46, 0x41,
0x49, 0x4c, 0x45, 0x44, 0x10, 0x03, 0x22, 0xb3, 0x01, 0x0a, 0x15, 0x50, 0x72, 0x6f, 0x70, 0x6f,
0x73, 0x65, 0x72, 0x4f, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x50, 0x61, 0x79, 0x6c, 0x6f, 0x61, 0x64,
0x12, 0x23, 0x0a, 0x0d, 0x66, 0x65, 0x65, 0x5f, 0x72, 0x65, 0x63, 0x69, 0x70, 0x69, 0x65, 0x6e,
0x74, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, 0x66, 0x65, 0x65, 0x52, 0x65, 0x63, 0x69,
0x70, 0x69, 0x65, 0x6e, 0x74, 0x12, 0x47, 0x0a, 0x07, 0x62, 0x75, 0x69, 0x6c, 0x64, 0x65, 0x72,
0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x2d, 0x2e, 0x65, 0x74, 0x68, 0x65, 0x72, 0x65, 0x75,
0x6d, 0x2e, 0x76, 0x61, 0x6c, 0x69, 0x64, 0x61, 0x74, 0x6f, 0x72, 0x2e, 0x61, 0x63, 0x63, 0x6f,
0x75, 0x6e, 0x74, 0x73, 0x2e, 0x76, 0x32, 0x2e, 0x42, 0x75, 0x69, 0x6c, 0x64, 0x65, 0x72, 0x43,
0x6f, 0x6e, 0x66, 0x69, 0x67, 0x52, 0x07, 0x62, 0x75, 0x69, 0x6c, 0x64, 0x65, 0x72, 0x12, 0x1f,
0x0a, 0x08, 0x67, 0x72, 0x61, 0x66, 0x66, 0x69, 0x74, 0x69, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09,
0x48, 0x00, 0x52, 0x08, 0x67, 0x72, 0x61, 0x66, 0x66, 0x69, 0x74, 0x69, 0x88, 0x01, 0x01, 0x42,
0x0b, 0x0a, 0x09, 0x5f, 0x67, 0x72, 0x61, 0x66, 0x66, 0x69, 0x74, 0x69, 0x22, 0xa5, 0x01, 0x0a,
0x0d, 0x42, 0x75, 0x69, 0x6c, 0x64, 0x65, 0x72, 0x43, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x12, 0x18,
0x0a, 0x07, 0x65, 0x6e, 0x61, 0x62, 0x6c, 0x65, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x08, 0x52,
0x07, 0x65, 0x6e, 0x61, 0x62, 0x6c, 0x65, 0x64, 0x12, 0x62, 0x0a, 0x09, 0x67, 0x61, 0x73, 0x5f,
0x6c, 0x69, 0x6d, 0x69, 0x74, 0x18, 0x02, 0x20, 0x01, 0x28, 0x04, 0x42, 0x45, 0x82, 0xb5, 0x18,
0x41, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x4f, 0x66, 0x66, 0x63,
0x68, 0x61, 0x69, 0x6e, 0x4c, 0x61, 0x62, 0x73, 0x2f, 0x70, 0x72, 0x79, 0x73, 0x6d, 0x2f, 0x76,
0x36, 0x2f, 0x63, 0x6f, 0x6e, 0x73, 0x65, 0x6e, 0x73, 0x75, 0x73, 0x2d, 0x74, 0x79, 0x70, 0x65,
0x73, 0x2f, 0x76, 0x61, 0x6c, 0x69, 0x64, 0x61, 0x74, 0x6f, 0x72, 0x2e, 0x55, 0x69, 0x6e, 0x74,
0x36, 0x34, 0x52, 0x08, 0x67, 0x61, 0x73, 0x4c, 0x69, 0x6d, 0x69, 0x74, 0x12, 0x16, 0x0a, 0x06,
0x72, 0x65, 0x6c, 0x61, 0x79, 0x73, 0x18, 0x03, 0x20, 0x03, 0x28, 0x09, 0x52, 0x06, 0x72, 0x65,
0x6c, 0x61, 0x79, 0x73, 0x22, 0xe7, 0x02, 0x0a, 0x17, 0x50, 0x72, 0x6f, 0x70, 0x6f, 0x73, 0x65,
0x72, 0x53, 0x65, 0x74, 0x74, 0x69, 0x6e, 0x67, 0x73, 0x50, 0x61, 0x79, 0x6c, 0x6f, 0x61, 0x64,
0x12, 0x74, 0x0a, 0x0f, 0x70, 0x72, 0x6f, 0x70, 0x6f, 0x73, 0x65, 0x72, 0x5f, 0x63, 0x6f, 0x6e,
0x66, 0x69, 0x67, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x4b, 0x2e, 0x65, 0x74, 0x68, 0x65,
0x72, 0x65, 0x75, 0x6d, 0x2e, 0x76, 0x61, 0x6c, 0x69, 0x64, 0x61, 0x74, 0x6f, 0x72, 0x2e, 0x61,
0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x73, 0x2e, 0x76, 0x32, 0x2e, 0x50, 0x72, 0x6f, 0x70, 0x6f,
0x73, 0x65, 0x72, 0x53, 0x65, 0x74, 0x74, 0x69, 0x6e, 0x67, 0x73, 0x50, 0x61, 0x79, 0x6c, 0x6f,
0x61, 0x64, 0x2e, 0x50, 0x72, 0x6f, 0x70, 0x6f, 0x73, 0x65, 0x72, 0x43, 0x6f, 0x6e, 0x66, 0x69,
0x67, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x52, 0x0e, 0x70, 0x72, 0x6f, 0x70, 0x6f, 0x73, 0x65, 0x72,
0x43, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x12, 0x5c, 0x0a, 0x0e, 0x64, 0x65, 0x66, 0x61, 0x75, 0x6c,
0x74, 0x5f, 0x63, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x35,
0x2e, 0x65, 0x74, 0x68, 0x65, 0x72, 0x65, 0x75, 0x6d, 0x2e, 0x76, 0x61, 0x6c, 0x69, 0x64, 0x61,
0x74, 0x6f, 0x72, 0x2e, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x73, 0x2e, 0x76, 0x32, 0x2e,
0x50, 0x72, 0x6f, 0x70, 0x6f, 0x73, 0x65, 0x72, 0x4f, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x50, 0x61,
0x79, 0x6c, 0x6f, 0x61, 0x64, 0x52, 0x0d, 0x64, 0x65, 0x66, 0x61, 0x75, 0x6c, 0x74, 0x43, 0x6f,
0x6e, 0x66, 0x69, 0x67, 0x1a, 0x78, 0x0a, 0x13, 0x50, 0x72, 0x6f, 0x70, 0x6f, 0x73, 0x65, 0x72,
0x43, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x12, 0x10, 0x0a, 0x03, 0x6b,
0x65, 0x79, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x03, 0x6b, 0x65, 0x79, 0x12, 0x4b, 0x0a,
0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x35, 0x2e, 0x65,
0x74, 0x68, 0x65, 0x72, 0x65, 0x75, 0x6d, 0x2e, 0x76, 0x61, 0x6c, 0x69, 0x64, 0x61, 0x74, 0x6f,
0x72, 0x2e, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x73, 0x2e, 0x76, 0x32, 0x2e, 0x50, 0x72,
0x6f, 0x70, 0x6f, 0x73, 0x65, 0x72, 0x4f, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x50, 0x61, 0x79, 0x6c,
0x6f, 0x61, 0x64, 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x3a, 0x02, 0x38, 0x01, 0x42, 0xcd,
0x01, 0x0a, 0x22, 0x6f, 0x72, 0x67, 0x2e, 0x65, 0x74, 0x68, 0x65, 0x72, 0x65, 0x75, 0x6d, 0x2e,
0x76, 0x61, 0x6c, 0x69, 0x64, 0x61, 0x74, 0x6f, 0x72, 0x2e, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e,
0x74, 0x73, 0x2e, 0x76, 0x32, 0x42, 0x0f, 0x4b, 0x65, 0x79, 0x6d, 0x61, 0x6e, 0x61, 0x67, 0x65,
0x72, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x50, 0x01, 0x5a, 0x52, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62,
0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x4f, 0x66, 0x66, 0x63, 0x68, 0x61, 0x69, 0x6e, 0x4c, 0x61, 0x62,
0x73, 0x2f, 0x70, 0x72, 0x79, 0x73, 0x6d, 0x2f, 0x76, 0x36, 0x2f, 0x70, 0x72, 0x6f, 0x74, 0x6f,
0x2f, 0x70, 0x72, 0x79, 0x73, 0x6d, 0x2f, 0x76, 0x31, 0x61, 0x6c, 0x70, 0x68, 0x61, 0x31, 0x2f,
0x76, 0x61, 0x6c, 0x69, 0x64, 0x61, 0x74, 0x6f, 0x72, 0x2d, 0x63, 0x6c, 0x69, 0x65, 0x6e, 0x74,
0x3b, 0x76, 0x61, 0x6c, 0x69, 0x64, 0x61, 0x74, 0x6f, 0x72, 0x70, 0x62, 0xaa, 0x02, 0x1e, 0x45,
0x74, 0x68, 0x65, 0x72, 0x65, 0x75, 0x6d, 0x2e, 0x56, 0x61, 0x6c, 0x69, 0x64, 0x61, 0x74, 0x6f,
0x72, 0x2e, 0x41, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x73, 0x2e, 0x56, 0x32, 0xca, 0x02, 0x1e,
0x45, 0x74, 0x68, 0x65, 0x72, 0x65, 0x75, 0x6d, 0x5c, 0x56, 0x61, 0x6c, 0x69, 0x64, 0x61, 0x74,
0x6f, 0x72, 0x5c, 0x41, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x73, 0x5c, 0x56, 0x32, 0x62, 0x06,
0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33,
}
var (
@@ -1013,6 +1034,7 @@ var file_proto_prysm_v1alpha1_validator_client_keymanager_proto_goTypes = []any{
(*v1alpha1.BlindedBeaconBlockElectra)(nil), // 22: ethereum.eth.v1alpha1.BlindedBeaconBlockElectra
(*v1alpha1.AggregateAttestationAndProofElectra)(nil), // 23: ethereum.eth.v1alpha1.AggregateAttestationAndProofElectra
(*v1alpha1.BlindedBeaconBlockFulu)(nil), // 24: ethereum.eth.v1alpha1.BlindedBeaconBlockFulu
(*v1alpha1.BeaconBlockGloas)(nil), // 25: ethereum.eth.v1alpha1.BeaconBlockGloas
}
var file_proto_prysm_v1alpha1_validator_client_keymanager_proto_depIdxs = []int32{
7, // 0: ethereum.validator.accounts.v2.SignRequest.block:type_name -> ethereum.eth.v1alpha1.BeaconBlock
@@ -1034,16 +1056,17 @@ var file_proto_prysm_v1alpha1_validator_client_keymanager_proto_depIdxs = []int3
23, // 16: ethereum.validator.accounts.v2.SignRequest.aggregate_attestation_and_proof_electra:type_name -> ethereum.eth.v1alpha1.AggregateAttestationAndProofElectra
21, // 17: ethereum.validator.accounts.v2.SignRequest.block_fulu:type_name -> ethereum.eth.v1alpha1.BeaconBlockElectra
24, // 18: ethereum.validator.accounts.v2.SignRequest.blinded_block_fulu:type_name -> ethereum.eth.v1alpha1.BlindedBeaconBlockFulu
0, // 19: ethereum.validator.accounts.v2.SignResponse.status:type_name -> ethereum.validator.accounts.v2.SignResponse.Status
4, // 20: ethereum.validator.accounts.v2.ProposerOptionPayload.builder:type_name -> ethereum.validator.accounts.v2.BuilderConfig
6, // 21: ethereum.validator.accounts.v2.ProposerSettingsPayload.proposer_config:type_name -> ethereum.validator.accounts.v2.ProposerSettingsPayload.ProposerConfigEntry
3, // 22: ethereum.validator.accounts.v2.ProposerSettingsPayload.default_config:type_name -> ethereum.validator.accounts.v2.ProposerOptionPayload
3, // 23: ethereum.validator.accounts.v2.ProposerSettingsPayload.ProposerConfigEntry.value:type_name -> ethereum.validator.accounts.v2.ProposerOptionPayload
24, // [24:24] is the sub-list for method output_type
24, // [24:24] is the sub-list for method input_type
24, // [24:24] is the sub-list for extension type_name
24, // [24:24] is the sub-list for extension extendee
0, // [0:24] is the sub-list for field type_name
25, // 19: ethereum.validator.accounts.v2.SignRequest.block_gloas:type_name -> ethereum.eth.v1alpha1.BeaconBlockGloas
0, // 20: ethereum.validator.accounts.v2.SignResponse.status:type_name -> ethereum.validator.accounts.v2.SignResponse.Status
4, // 21: ethereum.validator.accounts.v2.ProposerOptionPayload.builder:type_name -> ethereum.validator.accounts.v2.BuilderConfig
6, // 22: ethereum.validator.accounts.v2.ProposerSettingsPayload.proposer_config:type_name -> ethereum.validator.accounts.v2.ProposerSettingsPayload.ProposerConfigEntry
3, // 23: ethereum.validator.accounts.v2.ProposerSettingsPayload.default_config:type_name -> ethereum.validator.accounts.v2.ProposerOptionPayload
3, // 24: ethereum.validator.accounts.v2.ProposerSettingsPayload.ProposerConfigEntry.value:type_name -> ethereum.validator.accounts.v2.ProposerOptionPayload
25, // [25:25] is the sub-list for method output_type
25, // [25:25] is the sub-list for method input_type
25, // [25:25] is the sub-list for extension type_name
25, // [25:25] is the sub-list for extension extendee
0, // [0:25] is the sub-list for field type_name
}
func init() { file_proto_prysm_v1alpha1_validator_client_keymanager_proto_init() }
@@ -1074,6 +1097,7 @@ func file_proto_prysm_v1alpha1_validator_client_keymanager_proto_init() {
(*SignRequest_AggregateAttestationAndProofElectra)(nil),
(*SignRequest_BlockFulu)(nil),
(*SignRequest_BlindedBlockFulu)(nil),
(*SignRequest_BlockGloas)(nil),
}
file_proto_prysm_v1alpha1_validator_client_keymanager_proto_msgTypes[2].OneofWrappers = []any{}
type x struct{}

View File

@@ -80,6 +80,8 @@ message SignRequest {
// Fulu objects.
ethereum.eth.v1alpha1.BeaconBlockElectra block_fulu = 121;
ethereum.eth.v1alpha1.BlindedBeaconBlockFulu blinded_block_fulu = 122;
ethereum.eth.v1alpha1.BeaconBlockGloas block_gloas = 123;
}
reserved 4, 5; // Reserving old, deleted fields.

View File

@@ -14,6 +14,7 @@ const (
Deneb
Electra
Fulu
Gloas
)
var versionToString = map[int]string{
@@ -24,6 +25,7 @@ var versionToString = map[int]string{
Deneb: "deneb",
Electra: "electra",
Fulu: "fulu",
Gloas: "gloas",
}
// stringToVersion and allVersions are populated in init()

View File

@@ -1,4 +1,4 @@
version: v1.6.0-beta.0
version: v1.6.0-beta.1
style: full
specrefs:
@@ -18,6 +18,7 @@ exceptions:
- UPDATE_TIMEOUT#altair
# Not implemented: gloas (future fork)
- BUILDER_PENDING_WITHDRAWALS_LIMIT#gloas
- MAX_PAYLOAD_ATTESTATIONS#gloas
- PTC_SIZE#gloas
@@ -50,7 +51,6 @@ exceptions:
# Not implemented: gloas (future fork)
- BUILDER_PAYMENT_THRESHOLD_DENOMINATOR#gloas
- BUILDER_PAYMENT_THRESHOLD_NUMERATOR#gloas
- BUILDER_PENDING_WITHDRAWALS_LIMIT#gloas
- BUILDER_WITHDRAWAL_PREFIX#gloas
- DOMAIN_BEACON_BUILDER#gloas
- DOMAIN_PTC_ATTESTER#gloas
@@ -82,6 +82,12 @@ exceptions:
- Eth1Block#phase0
- MatrixEntry#fulu
# Not implemented: capella
- LightClientBootstrap#capella
- LightClientFinalityUpdate#capella
- LightClientOptimisticUpdate#capella
- LightClientUpdate#capella
# Not implemented: gloas (future fork)
- BeaconBlockBody#gloas
- BeaconState#gloas
@@ -106,6 +112,9 @@ exceptions:
- OptimisticStore#bellatrix
- Store#phase0
# Not implemented: capella
- LightClientStore#capella
# Not implemented: gloas (future fork)
- LatestMessage#gloas
- Store#gloas
@@ -213,6 +222,7 @@ exceptions:
- xor#phase0
# Not implemented: altair
- compute_merkle_proof#altair
- compute_sync_committee_period_at_slot#altair
- get_contribution_and_proof#altair
- get_contribution_due_ms#altair
@@ -354,6 +364,7 @@ exceptions:
- upgrade_to_gloas#gloas
- validate_merge_block#gloas
- validate_on_attestation#gloas
- verify_data_column_sidecar#gloas
- verify_data_column_sidecar_inclusion_proof#gloas
- verify_execution_payload_envelope_signature#gloas
- verify_execution_payload_bid_signature#gloas

View File

@@ -971,12 +971,12 @@
- file: proto/prysm/v1alpha1/light_client.proto
search: message LightClientHeaderCapella {
spec: |
<spec ssz_object="LightClientHeader" fork="capella" hash="366cbdcd">
<spec ssz_object="LightClientHeader" fork="capella" hash="b625e61e">
class LightClientHeader(Container):
# Beacon block header
beacon: BeaconBlockHeader
# Execution payload header corresponding to `beacon.body_root` (from Capella onward)
# [New in Capella]
execution: ExecutionPayloadHeader
# [New in Capella]
execution_branch: ExecutionBranch
</spec>

View File

@@ -1303,9 +1303,24 @@
- file: crypto/bls/bls.go
search: func AggregatePublicKeys(
spec: |
<spec fn="eth_aggregate_pubkeys" fork="altair" hash="977edbdb">
<spec fn="eth_aggregate_pubkeys" fork="altair" hash="bfb5ddd0">
def eth_aggregate_pubkeys(pubkeys: Sequence[BLSPubkey]) -> BLSPubkey:
return bls.AggregatePKs(pubkeys)
"""
Return the aggregate public key for the public keys in ``pubkeys``.
Note: the ``+`` operation should be interpreted as elliptic curve point addition, which takes as input
elliptic curve points that must be decoded from the input ``BLSPubkey``s.
This implementation is for demonstrative purposes only and ignores encoding/decoding concerns.
Refer to the BLS signature draft standard for more information.
"""
assert len(pubkeys) > 0
# Ensure that the given inputs are valid pubkeys
assert all(bls.KeyValidate(pubkey) for pubkey in pubkeys)
result = copy(pubkeys[0])
for pubkey in pubkeys[1:]:
result += pubkey
return result
</spec>
- name: eth_fast_aggregate_verify
@@ -4494,12 +4509,12 @@
- file: beacon-chain/core/helpers/weak_subjectivity.go
search: func IsWithinWeakSubjectivityPeriod(
spec: |
<spec fn="is_within_weak_subjectivity_period" fork="phase0" hash="f8a94089">
<spec fn="is_within_weak_subjectivity_period" fork="phase0" hash="aef08e82">
def is_within_weak_subjectivity_period(
store: Store, ws_state: BeaconState, ws_checkpoint: Checkpoint
) -> bool:
# Clients may choose to validate the input state against the input Weak Subjectivity Checkpoint
assert ws_state.latest_block_header.state_root == ws_checkpoint.root
assert get_block_root(ws_state, ws_checkpoint.epoch) == ws_checkpoint.root
assert compute_epoch_at_slot(ws_state.slot) == ws_checkpoint.epoch
ws_period = compute_weak_subjectivity_period(ws_state)
@@ -4511,12 +4526,12 @@
- name: is_within_weak_subjectivity_period#electra
sources: []
spec: |
<spec fn="is_within_weak_subjectivity_period" fork="electra" hash="c89ae316">
<spec fn="is_within_weak_subjectivity_period" fork="electra" hash="d05d230d">
def is_within_weak_subjectivity_period(
store: Store, ws_state: BeaconState, ws_checkpoint: Checkpoint
) -> bool:
# Clients may choose to validate the input state against the input Weak Subjectivity Checkpoint
assert ws_state.latest_block_header.state_root == ws_checkpoint.root
assert get_block_root(ws_state, ws_checkpoint.epoch) == ws_checkpoint.root
assert compute_epoch_at_slot(ws_state.slot) == ws_checkpoint.epoch
# [Modified in Electra]
@@ -7649,8 +7664,8 @@
- name: upgrade_lc_bootstrap_to_capella
sources: []
spec: |
<spec fn="upgrade_lc_bootstrap_to_capella" fork="capella" hash="2c8939e7">
def upgrade_lc_bootstrap_to_capella(pre: bellatrix.LightClientBootstrap) -> LightClientBootstrap:
<spec fn="upgrade_lc_bootstrap_to_capella" fork="capella" hash="d5f1203a">
def upgrade_lc_bootstrap_to_capella(pre: altair.LightClientBootstrap) -> LightClientBootstrap:
return LightClientBootstrap(
header=upgrade_lc_header_to_capella(pre.header),
current_sync_committee=pre.current_sync_committee,
@@ -7687,9 +7702,9 @@
- name: upgrade_lc_finality_update_to_capella
sources: []
spec: |
<spec fn="upgrade_lc_finality_update_to_capella" fork="capella" hash="5315d1df">
<spec fn="upgrade_lc_finality_update_to_capella" fork="capella" hash="c314b172">
def upgrade_lc_finality_update_to_capella(
pre: bellatrix.LightClientFinalityUpdate,
pre: altair.LightClientFinalityUpdate,
) -> LightClientFinalityUpdate:
return LightClientFinalityUpdate(
attested_header=upgrade_lc_header_to_capella(pre.attested_header),
@@ -7735,10 +7750,12 @@
- name: upgrade_lc_header_to_capella
sources: []
spec: |
<spec fn="upgrade_lc_header_to_capella" fork="capella" hash="9eaa5026">
def upgrade_lc_header_to_capella(pre: bellatrix.LightClientHeader) -> LightClientHeader:
<spec fn="upgrade_lc_header_to_capella" fork="capella" hash="9f7a832d">
def upgrade_lc_header_to_capella(pre: altair.LightClientHeader) -> LightClientHeader:
return LightClientHeader(
beacon=pre.beacon,
execution=ExecutionPayloadHeader(),
execution_branch=ExecutionBranch(),
)
</spec>
@@ -7789,9 +7806,9 @@
- name: upgrade_lc_optimistic_update_to_capella
sources: []
spec: |
<spec fn="upgrade_lc_optimistic_update_to_capella" fork="capella" hash="488c41c5">
<spec fn="upgrade_lc_optimistic_update_to_capella" fork="capella" hash="c4c29295">
def upgrade_lc_optimistic_update_to_capella(
pre: bellatrix.LightClientOptimisticUpdate,
pre: altair.LightClientOptimisticUpdate,
) -> LightClientOptimisticUpdate:
return LightClientOptimisticUpdate(
attested_header=upgrade_lc_header_to_capella(pre.attested_header),
@@ -7831,8 +7848,8 @@
- name: upgrade_lc_store_to_capella
sources: []
spec: |
<spec fn="upgrade_lc_store_to_capella" fork="capella" hash="a25064df">
def upgrade_lc_store_to_capella(pre: bellatrix.LightClientStore) -> LightClientStore:
<spec fn="upgrade_lc_store_to_capella" fork="capella" hash="d02773ec">
def upgrade_lc_store_to_capella(pre: altair.LightClientStore) -> LightClientStore:
if pre.best_valid_update is None:
best_valid_update = None
else:
@@ -7891,8 +7908,8 @@
- name: upgrade_lc_update_to_capella
sources: []
spec: |
<spec fn="upgrade_lc_update_to_capella" fork="capella" hash="e7dbaf33">
def upgrade_lc_update_to_capella(pre: bellatrix.LightClientUpdate) -> LightClientUpdate:
<spec fn="upgrade_lc_update_to_capella" fork="capella" hash="ba863d2f">
def upgrade_lc_update_to_capella(pre: altair.LightClientUpdate) -> LightClientUpdate:
return LightClientUpdate(
attested_header=upgrade_lc_header_to_capella(pre.attested_header),
next_sync_committee=pre.next_sync_committee,
@@ -8539,7 +8556,7 @@
- file: beacon-chain/core/peerdas/p2p_interface.go
search: func VerifyDataColumnSidecar(
spec: |
<spec fn="verify_data_column_sidecar" fork="fulu" hash="509c0986">
<spec fn="verify_data_column_sidecar" fork="fulu" hash="1517491f">
def verify_data_column_sidecar(sidecar: DataColumnSidecar) -> bool:
"""
Verify if the data column sidecar is valid.
@@ -8552,6 +8569,11 @@
if len(sidecar.kzg_commitments) == 0:
return False
# Check that the sidecar respects the blob limit
epoch = compute_epoch_at_slot(sidecar.signed_block_header.message.slot)
if len(sidecar.kzg_commitments) > get_blob_parameters(epoch).max_blobs_per_block:
return False
# The column length must be equal to the number of commitments/proofs
if len(sidecar.column) != len(sidecar.kzg_commitments) or len(sidecar.column) != len(
sidecar.kzg_proofs

View File

@@ -110,6 +110,6 @@ consensus_spec_tests = repository_rule(
"repo": attr.string(default = "ethereum/consensus-specs"),
"workflow": attr.string(default = "generate_vectors.yml"),
"branch": attr.string(default = "dev"),
"release_url_template": attr.string(default = "https://github.com/ethereum/consensus-spec-tests/releases/download/%s"),
"release_url_template": attr.string(default = "https://github.com/ethereum/consensus-specs/releases/download/%s"),
},
)

View File

@@ -84,7 +84,7 @@ func (acm *CLIManager) prepareBeaconClients(ctx context.Context) (*iface.Validat
conn := validatorHelpers.NewNodeConnection(
grpcConn,
acm.beaconApiEndpoint,
acm.beaconApiTimeout,
validatorHelpers.WithBeaconApiTimeout(acm.beaconApiTimeout),
)
restHandler := beaconApi.NewBeaconApiRestHandler(

View File

@@ -153,6 +153,12 @@ func (v *validator) ProposeBlock(ctx context.Context, slot primitives.Slot, pubK
log.WithError(err).Error("Failed to build generic signed block")
return
}
case version.Gloas:
genericSignedBlock, err = buildGenericSignedBlockGloasWithBlobs(pb, b)
if err != nil {
log.WithError(err).Error("Failed to build generic signed block")
return
}
default:
log.Errorf("Unsupported block version %s", version.String(blk.Version()))
}
@@ -291,6 +297,22 @@ func buildGenericSignedBlockFuluWithBlobs(pb proto.Message, b *ethpb.GenericBeac
}, nil
}
func buildGenericSignedBlockGloasWithBlobs(pb proto.Message, b *ethpb.GenericBeaconBlock) (*ethpb.GenericSignedBeaconBlock, error) {
gloasBlock, ok := pb.(*ethpb.SignedBeaconBlockGloas)
if !ok {
return nil, errors.New("could cast to gloas block")
}
return &ethpb.GenericSignedBeaconBlock{
Block: &ethpb.GenericSignedBeaconBlock_Gloas{
Gloas: &ethpb.SignedBeaconBlockContentsGloas{
Block: gloasBlock,
KzgProofs: b.GetGloas().KzgProofs,
Blobs: b.GetGloas().Blobs,
},
},
}, nil
}
// ProposeExit performs a voluntary exit on a validator.
// The exit is signed by the validator before being sent to the beacon node for broadcasting.
func ProposeExit(

View File

@@ -6,6 +6,7 @@ import (
"strings"
"time"
api "github.com/OffchainLabs/prysm/v6/api/client"
eventClient "github.com/OffchainLabs/prysm/v6/api/client/event"
grpcutil "github.com/OffchainLabs/prysm/v6/api/grpc"
"github.com/OffchainLabs/prysm/v6/async/event"
@@ -79,6 +80,7 @@ type Config struct {
BeaconNodeGRPCEndpoint string
BeaconNodeCert string
BeaconApiEndpoint string
BeaconApiHeaders map[string][]string
BeaconApiTimeout time.Duration
Graffiti string
GraffitiStruct *graffiti.Graffiti
@@ -142,7 +144,8 @@ func NewValidatorService(ctx context.Context, cfg *Config) (*ValidatorService, e
s.conn = validatorHelpers.NewNodeConnection(
grpcConn,
cfg.BeaconApiEndpoint,
cfg.BeaconApiTimeout,
validatorHelpers.WithBeaconApiHeaders(cfg.BeaconApiHeaders),
validatorHelpers.WithBeaconApiTimeout(cfg.BeaconApiTimeout),
)
return s, nil
@@ -185,8 +188,9 @@ func (v *ValidatorService) Start() {
return
}
headersTransport := api.NewCustomHeadersTransport(http.DefaultTransport, v.conn.GetBeaconApiHeaders())
restHandler := beaconApi.NewBeaconApiRestHandler(
http.Client{Timeout: v.conn.GetBeaconApiTimeout(), Transport: otelhttp.NewTransport(http.DefaultTransport)},
http.Client{Timeout: v.conn.GetBeaconApiTimeout(), Transport: otelhttp.NewTransport(headersTransport)},
hosts[0],
)

View File

@@ -10,16 +10,37 @@ import (
type NodeConnection interface {
GetGrpcClientConn() *grpc.ClientConn
GetBeaconApiUrl() string
GetBeaconApiHeaders() map[string][]string
setBeaconApiHeaders(map[string][]string)
GetBeaconApiTimeout() time.Duration
setBeaconApiTimeout(time.Duration)
dummy()
}
type nodeConnection struct {
grpcClientConn *grpc.ClientConn
beaconApiUrl string
beaconApiHeaders map[string][]string
beaconApiTimeout time.Duration
}
// NodeConnectionOption is a functional option for configuring the node connection.
type NodeConnectionOption func(nc NodeConnection)
// WithBeaconApiHeaders sets the HTTP headers that should be sent to the server along with each request.
func WithBeaconApiHeaders(headers map[string][]string) NodeConnectionOption {
return func(nc NodeConnection) {
nc.setBeaconApiHeaders(headers)
}
}
// WithBeaconApiTimeout sets the HTTP request timeout.
func WithBeaconApiTimeout(timeout time.Duration) NodeConnectionOption {
return func(nc NodeConnection) {
nc.setBeaconApiTimeout(timeout)
}
}
func (c *nodeConnection) GetGrpcClientConn() *grpc.ClientConn {
return c.grpcClientConn
}
@@ -28,16 +49,30 @@ func (c *nodeConnection) GetBeaconApiUrl() string {
return c.beaconApiUrl
}
func (c *nodeConnection) GetBeaconApiHeaders() map[string][]string {
return c.beaconApiHeaders
}
func (c *nodeConnection) setBeaconApiHeaders(headers map[string][]string) {
c.beaconApiHeaders = headers
}
func (c *nodeConnection) GetBeaconApiTimeout() time.Duration {
return c.beaconApiTimeout
}
func (c *nodeConnection) setBeaconApiTimeout(timeout time.Duration) {
c.beaconApiTimeout = timeout
}
func (*nodeConnection) dummy() {}
func NewNodeConnection(grpcConn *grpc.ClientConn, beaconApiUrl string, beaconApiTimeout time.Duration) NodeConnection {
func NewNodeConnection(grpcConn *grpc.ClientConn, beaconApiUrl string, opts ...NodeConnectionOption) NodeConnection {
conn := &nodeConnection{}
conn.grpcClientConn = grpcConn
conn.beaconApiUrl = beaconApiUrl
conn.beaconApiTimeout = beaconApiTimeout
for _, opt := range opts {
opt(conn)
}
return conn
}

View File

@@ -433,6 +433,7 @@ func (c *ValidatorClient) registerValidatorService(cliCtx *cli.Context) error {
BeaconNodeGRPCEndpoint: cliCtx.String(flags.BeaconRPCProviderFlag.Name),
BeaconNodeCert: cliCtx.String(flags.CertFlag.Name),
BeaconApiEndpoint: cliCtx.String(flags.BeaconRESTApiProviderFlag.Name),
BeaconApiHeaders: parseBeaconApiHeaders(cliCtx.String(flags.BeaconRESTApiHeaders.Name)),
BeaconApiTimeout: time.Second * 30,
Graffiti: g.ParseHexGraffiti(cliCtx.String(flags.GraffitiFlag.Name)),
GraffitiStruct: graffitiStruct,
@@ -552,6 +553,7 @@ func (c *ValidatorClient) registerRPCService(cliCtx *cli.Context) error {
GRPCHeaders: strings.Split(cliCtx.String(flags.GRPCHeadersFlag.Name), ","),
BeaconNodeGRPCEndpoint: cliCtx.String(flags.BeaconRPCProviderFlag.Name),
BeaconApiEndpoint: cliCtx.String(flags.BeaconRESTApiProviderFlag.Name),
BeaconAPIHeaders: parseBeaconApiHeaders(cliCtx.String(flags.BeaconRESTApiHeaders.Name)),
BeaconApiTimeout: time.Second * 30,
BeaconNodeCert: cliCtx.String(flags.CertFlag.Name),
DB: c.db,
@@ -636,3 +638,23 @@ func clearDB(ctx context.Context, dataDir string, force bool, isDatabaseMinimal
return nil
}
func parseBeaconApiHeaders(rawHeaders string) map[string][]string {
result := make(map[string][]string)
pairs := strings.Split(rawHeaders, ",")
for _, pair := range pairs {
key, value, found := strings.Cut(pair, "=")
if !found {
// Skip malformed pairs
continue
}
key = strings.TrimSpace(key)
value = strings.TrimSpace(value)
if key == "" || value == "" {
// Skip malformed pairs
continue
}
result[key] = append(result[key], value)
}
return result
}

View File

@@ -308,3 +308,17 @@ func TestWeb3SignerConfig(t *testing.T) {
})
}
}
func Test_parseBeaconApiHeaders(t *testing.T) {
t.Run("ok", func(t *testing.T) {
h := parseBeaconApiHeaders("key1=value1,key1=value2,key2=value3")
assert.Equal(t, 2, len(h))
assert.DeepEqual(t, []string{"value1", "value2"}, h["key1"])
assert.DeepEqual(t, []string{"value3"}, h["key2"])
})
t.Run("ignores malformed", func(t *testing.T) {
h := parseBeaconApiHeaders("key1=value1,key2value2,key3=,=key4")
assert.Equal(t, 1, len(h))
assert.DeepEqual(t, []string{"value1"}, h["key1"])
})
}

View File

@@ -23,6 +23,7 @@ go_library(
],
deps = [
"//api:go_default_library",
"//api/client:go_default_library",
"//api/grpc:go_default_library",
"//api/pagination:go_default_library",
"//api/server:go_default_library",

View File

@@ -3,6 +3,7 @@ package rpc
import (
"net/http"
api "github.com/OffchainLabs/prysm/v6/api/client"
grpcutil "github.com/OffchainLabs/prysm/v6/api/grpc"
ethpb "github.com/OffchainLabs/prysm/v6/proto/prysm/v1alpha1"
"github.com/OffchainLabs/prysm/v6/validator/client"
@@ -52,11 +53,13 @@ func (s *Server) registerBeaconClient() error {
conn := validatorHelpers.NewNodeConnection(
grpcConn,
s.beaconApiEndpoint,
s.beaconApiTimeout,
validatorHelpers.WithBeaconApiHeaders(s.beaconApiHeaders),
validatorHelpers.WithBeaconApiTimeout(s.beaconApiTimeout),
)
headersTransport := api.NewCustomHeadersTransport(http.DefaultTransport, conn.GetBeaconApiHeaders())
restHandler := beaconApi.NewBeaconApiRestHandler(
http.Client{Timeout: s.beaconApiTimeout, Transport: otelhttp.NewTransport(http.DefaultTransport)},
http.Client{Timeout: s.beaconApiTimeout, Transport: otelhttp.NewTransport(headersTransport)},
s.beaconApiEndpoint,
)

View File

@@ -34,6 +34,7 @@ type Config struct {
GRPCHeaders []string
BeaconNodeGRPCEndpoint string
BeaconApiEndpoint string
BeaconAPIHeaders map[string][]string
BeaconApiTimeout time.Duration
BeaconNodeCert string
DB db.Database
@@ -64,6 +65,7 @@ type Server struct {
authTokenPath string
beaconNodeCert string
beaconApiEndpoint string
beaconApiHeaders map[string][]string
beaconNodeEndpoint string
healthClient ethpb.HealthClient
nodeClient iface.NodeClient
@@ -103,6 +105,7 @@ func NewServer(ctx context.Context, cfg *Config) *Server {
wallet: cfg.Wallet,
beaconApiTimeout: cfg.BeaconApiTimeout,
beaconApiEndpoint: cfg.BeaconApiEndpoint,
beaconApiHeaders: cfg.BeaconAPIHeaders,
beaconNodeEndpoint: cfg.BeaconNodeGRPCEndpoint,
router: cfg.Router,
}