Skip to content

Commit

Permalink
Merge pull request #283 from attestantio/gas-limit-verification
Browse files Browse the repository at this point in the history
Verify proposal gas limits.
  • Loading branch information
mcdee authored Jan 10, 2025
2 parents a33ecc1 + 3a13086 commit d8f0c84
Show file tree
Hide file tree
Showing 22 changed files with 473 additions and 151 deletions.
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ dev:
- use multisign for contributions and proofs with enabled accounts
- use multisign for signing slot selections with enabled accounts
- log all obtained attestation data if the majority strategy fails to reach threshold
- warn if block proposal gas limit is not the expected value

1.9.2:
- update go-eth2-wallet-dirk to enable mixed signing thresholds for multisign
Expand Down
10 changes: 9 additions & 1 deletion commands.go
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@ import (
_ "net/http/pprof"
"os"

consensusclient "github.com/attestantio/go-eth2-client"
"github.com/attestantio/go-eth2-client/spec/phase0"
"github.com/attestantio/vouch/services/accountmanager"
"github.com/attestantio/vouch/services/blockrelay"
Expand Down Expand Up @@ -63,7 +64,14 @@ func proposerConfigCheck(ctx context.Context, majordomo majordomo.Service) bool
fmt.Fprintf(os.Stderr, "Failed to start signer: %v\n", err)
return true
}
blockRelaySvc, err := startBlockRelay(ctx, majordomo, monitor, consensusClient, scheduler, chainTime, accountManager, signer)
log.Trace().Msg("Starting cache")
cacheSvc, err := startCache(ctx, monitor, chainTime, scheduler, consensusClient, consensusClient.(consensusclient.BeaconBlockHeadersProvider), consensusClient.(consensusclient.SignedBeaconBlockProvider))
if err != nil {
fmt.Fprintf(os.Stderr, "Failed to start cache: %v\n", err)
return true
}

blockRelaySvc, err := startBlockRelay(ctx, majordomo, monitor, consensusClient, scheduler, chainTime, accountManager, signer, cacheSvc)
if err != nil {
fmt.Fprintf(os.Stderr, "Failed to start block relay: %v\n", err)
return true
Expand Down
41 changes: 20 additions & 21 deletions go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -6,10 +6,10 @@ toolchain go1.23.2

require (
github.com/attestantio/go-block-relay v0.4.1
github.com/attestantio/go-builder-client v0.5.1
github.com/attestantio/go-eth2-client v0.21.11
github.com/attestantio/go-builder-client v0.5.3
github.com/attestantio/go-eth2-client v0.22.0
github.com/aws/aws-sdk-go v1.55.5
github.com/holiman/uint256 v1.3.1
github.com/holiman/uint256 v1.3.2
github.com/mitchellh/go-homedir v1.1.0
github.com/pkg/errors v0.9.1
github.com/prometheus/client_golang v1.20.5
Expand All @@ -19,7 +19,7 @@ require (
github.com/shopspring/decimal v1.4.0
github.com/spf13/pflag v1.0.5
github.com/spf13/viper v1.19.0
github.com/stretchr/testify v1.9.0
github.com/stretchr/testify v1.10.0
github.com/wealdtech/go-eth2-types/v2 v2.8.2
github.com/wealdtech/go-eth2-wallet v1.17.0
github.com/wealdtech/go-eth2-wallet-dirk v1.5.1
Expand All @@ -42,42 +42,41 @@ require (
)

require (
cloud.google.com/go/auth v0.10.1 // indirect
cloud.google.com/go/auth/oauth2adapt v0.2.5 // indirect
cloud.google.com/go/auth v0.11.0 // indirect
cloud.google.com/go/auth/oauth2adapt v0.2.6 // indirect
cloud.google.com/go/compute/metadata v0.5.2 // indirect
cloud.google.com/go/iam v1.2.2 // indirect
cloud.google.com/go/secretmanager v1.14.2 // indirect
github.com/beorn7/perks v1.0.1 // indirect
github.com/bytedance/sonic v1.12.4 // indirect
github.com/bytedance/sonic v1.12.5 // indirect
github.com/bytedance/sonic/loader v0.2.1 // indirect
github.com/cenkalti/backoff/v4 v4.3.0 // indirect
github.com/cespare/xxhash/v2 v2.3.0 // indirect
github.com/cloudwego/base64x v0.1.4 // indirect
github.com/cloudwego/iasm v0.2.0 // indirect
github.com/davecgh/go-spew v1.1.2-0.20180830191138-d8f796af33cc // indirect
github.com/emicklei/dot v1.6.2 // indirect
github.com/fatih/color v1.18.0 // indirect
github.com/emicklei/dot v1.6.4 // indirect
github.com/felixge/httpsnoop v1.0.4 // indirect
github.com/ferranbt/fastssz v0.1.4 // indirect
github.com/fsnotify/fsnotify v1.8.0 // indirect
github.com/gabriel-vasile/mimetype v1.4.6 // indirect
github.com/gabriel-vasile/mimetype v1.4.7 // indirect
github.com/gin-contrib/sse v0.1.0 // indirect
github.com/gin-gonic/gin v1.10.0 // indirect
github.com/go-logr/logr v1.4.2 // indirect
github.com/go-logr/stdr v1.2.2 // indirect
github.com/go-playground/locales v0.14.1 // indirect
github.com/go-playground/universal-translator v0.18.1 // indirect
github.com/go-playground/validator/v10 v10.22.1 // indirect
github.com/go-playground/validator/v10 v10.23.0 // indirect
github.com/goccy/go-json v0.10.3 // indirect
github.com/goccy/go-yaml v1.13.6 // indirect
github.com/golang/groupcache v0.0.0-20210331224755-41bb18bfe9da // indirect
github.com/goccy/go-yaml v1.15.6 // indirect
github.com/golang/groupcache v0.0.0-20241129210726-2c02b8208cf8 // indirect
github.com/google/go-cmp v0.6.0 // indirect
github.com/google/s2a-go v0.1.8 // indirect
github.com/google/uuid v1.6.0 // indirect
github.com/googleapis/enterprise-certificate-proxy v0.3.4 // indirect
github.com/googleapis/gax-go/v2 v2.13.0 // indirect
github.com/googleapis/gax-go/v2 v2.14.0 // indirect
github.com/gorilla/mux v1.8.1 // indirect
github.com/grpc-ecosystem/grpc-gateway/v2 v2.23.0 // indirect
github.com/grpc-ecosystem/grpc-gateway/v2 v2.24.0 // indirect
github.com/hashicorp/hcl v1.0.0 // indirect
github.com/herumi/bls-eth-go-binary v1.36.1 // indirect
github.com/huandu/go-clone v1.7.2 // indirect
Expand Down Expand Up @@ -124,7 +123,7 @@ require (
go.opentelemetry.io/contrib/instrumentation/google.golang.org/grpc/otelgrpc v0.57.0 // indirect
go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp v0.57.0 // indirect
go.opentelemetry.io/otel/metric v1.32.0 // indirect
go.opentelemetry.io/proto/otlp v1.3.1 // indirect
go.opentelemetry.io/proto/otlp v1.4.0 // indirect
go.uber.org/multierr v1.11.0 // indirect
golang.org/x/arch v0.12.0 // indirect
golang.org/x/crypto v0.29.0 // indirect
Expand All @@ -134,11 +133,11 @@ require (
golang.org/x/sys v0.27.0 // indirect
golang.org/x/text v0.20.0 // indirect
golang.org/x/time v0.8.0 // indirect
google.golang.org/api v0.205.0 // indirect
google.golang.org/genproto v0.0.0-20241104194629-dd2ea8efbc28 // indirect
google.golang.org/genproto/googleapis/api v0.0.0-20241104194629-dd2ea8efbc28 // indirect
google.golang.org/genproto/googleapis/rpc v0.0.0-20241104194629-dd2ea8efbc28 // indirect
google.golang.org/protobuf v1.35.1 // indirect
google.golang.org/api v0.209.0 // indirect
google.golang.org/genproto v0.0.0-20241202173237-19429a94021a // indirect
google.golang.org/genproto/googleapis/api v0.0.0-20241202173237-19429a94021a // indirect
google.golang.org/genproto/googleapis/rpc v0.0.0-20241202173237-19429a94021a // indirect
google.golang.org/protobuf v1.35.2 // indirect
gopkg.in/Knetic/govaluate.v3 v3.0.0 // indirect
gopkg.in/cenkalti/backoff.v1 v1.1.0 // indirect
gopkg.in/ini.v1 v1.67.0 // indirect
Expand Down
Loading

0 comments on commit d8f0c84

Please sign in to comment.