diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 4e270c391..deeb5a596 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -29,6 +29,50 @@ jobs: - name: Check license header run: make check-license + - name: Setup Go + uses: actions/setup-go@v6 + with: + go-version-file: go.mod + + - name: Install go-licenses + run: go install github.com/google/go-licenses@v1.6.0 + + # LGPL-3.0 is classified as restricted, and go-licenses reads go-ethereum's + # root COPYING file, so it reports the whole module as GPL-3.0. Only library + # packages outside cmd/ are linked, which are LGPL-3.0, and that combination + # is allowed here deliberately. See dev/licenses-overrides.tsv. + # The targets and cgo modes match dev/licenses-generate.sh, because the + # linked packages differ between them. + - name: Check third party licenses + run: | + for target in linux/amd64 linux/arm64; do + for cgo in 1 0; do + GOOS="${target%/*}" GOARCH="${target#*/}" CGO_ENABLED=$cgo \ + go-licenses check ./... \ + --disallowed_types=forbidden,restricted,unknown \ + --ignore github.com/ethereum/go-ethereum + done + done + + # The go-ethereum exception above holds only while no package under its + # GPL-3.0 cmd/ directory is linked. + - name: Check that no go-ethereum command is linked + run: | + for target in linux/amd64 linux/arm64; do + for cgo in 1 0; do + deps=$(GOOS="${target%/*}" GOARCH="${target#*/}" CGO_ENABLED=$cgo go list -deps ./...) + if grep '^github.com/ethereum/go-ethereum/cmd/' <<<"$deps"; then + echo "a go-ethereum cmd/ package is linked for $target with CGO_ENABLED=$cgo" >&2 + exit 1 + fi + done + done + + - name: Check third party notices are current + run: | + dev/licenses-generate.sh > THIRD_PARTY_LICENSES.md + git diff --exit-code THIRD_PARTY_LICENSES.md + - name: Lint Markdown docs uses: DavidAnson/markdownlint-cli2-action@ded1f9488f68a970bc66ea5619e13e9b52e601cd # v23 with: diff --git a/Dockerfile b/Dockerfile index 9306b036a..83b5bc545 100644 --- a/Dockerfile +++ b/Dockerfile @@ -51,10 +51,10 @@ FROM common-env AS go-installer RUN < $@ +# Phony, because the notices depend on more than files make can see: go.sum, +# the imported packages, and licence URLs that go-licenses resolves online. +THIRD_PARTY_LICENSES.md: ## Update the THIRD_PARTY_LICENSES.md file + dev/licenses-generate.sh > $@.tmp || { rm -f $@.tmp; exit 1; } + mv $@.tmp $@ # ============================================================================= # Install @@ -859,6 +872,16 @@ copy-debian-package: ## Copy debian package from debian packager image build-debian-package: install mkdir -p $(DESTDIR)/DEBIAN $(DOC_INSTALL_PATH) install -m0644 LICENSE $(DOC_INSTALL_PATH)/copyright + install -m0644 THIRD_PARTY_LICENSES.md $(DOC_INSTALL_PATH)/ + install -m0644 licenses/LGPL-3.0.txt $(DOC_INSTALL_PATH)/ + install -m0644 licenses/GPL-3.0.txt $(DOC_INSTALL_PATH)/ + { \ + echo ""; \ + echo "The binaries in this package statically link third party components."; \ + echo "They are listed with their licences in THIRD_PARTY_LICENSES.md, in this"; \ + echo "directory. Some are covered by the GNU LGPL-3.0, whose text is in"; \ + echo "LGPL-3.0.txt, alongside the GPL-3.0.txt it builds on."; \ + } >> $(DOC_INSTALL_PATH)/copyright sed 's|ARG_VERSION|$(ROLLUPS_NODE_VERSION)|g;s|ARG_ARCH|$(DEB_ARCH)|g' control.template > $(DESTDIR)/DEBIAN/control dpkg-deb -Zxz --root-owner-group --build $(DESTDIR) $(DEB_FILENAME) @@ -867,7 +890,7 @@ build-debian-package: install clean clean-go clean-contracts clean-docs clean-devnet-files clean-dapps clean-test-dependencies clean-test-logs clean-integration-compose clean-debian-packages \ test unit-test unit-test-with-compose integration-test integration-test-with-compose integration-test-local test-with-compose ci-test coverage-report \ integration-test-shard-check list-integration-shards list-integration-cells \ - generate generate-contracts generate-config generate-inspect check-generate generate-db \ + generate generate-contracts generate-config generate-inspect check-generate generate-db THIRD_PARTY_LICENSES.md \ docs generate-cli-docs generate-config-docs \ lint fmt fmt-check vet escape check-license \ devnet image tester-image debian-packager run-with-compose shutdown-compose \ diff --git a/README.md b/README.md index 891bd548e..563091f44 100644 --- a/README.md +++ b/README.md @@ -16,9 +16,9 @@ We provide packages for debian (.deb) in **amd64** and **arm64** variants on the ##### System Requirements -- Cartesi Machine emulator == 0.20.x +- Cartesi Machine emulator == 0.21.x - GNU Make >= 3.81 -- Go >= 1.24.1 +- Go >= 1.27.1 Follow the [Cartesi Machine installation instructions](https://github.com/cartesi/machine-emulator?tab=readme-ov-file#installation). @@ -106,7 +106,7 @@ Note we have a [code of conduct](CODE_OF_CONDUCT.md), please follow it in all yo ## Authors -The Cartesi Machine emulator is actively developed by [Cartesi](https://cartesi.io/)'s Machine Reference Unit, with significant contributions from many open-source developers. +The Cartesi Rollups Node is actively developed by [Cartesi](https://cartesi.io/)'s Node Reference Unit, with significant contributions from many open-source developers. For a complete list of authors, see the [AUTHORS](AUTHORS) file. ## License @@ -115,3 +115,8 @@ The repository and all contributions to it are licensed under the [Apache 2.0](h Please review our [LICENSE](LICENSE) file for the Apache 2.0 license and also the [third party licenses](THIRD_PARTY_LICENSES.md) file for information on third-party software licenses. Note: This component currently has dependencies licensed under the GNU LGPL, version 3, so you should treat this component as a whole as being under the LGPL version 3. But all Cartesi-written code in this component is licensed under the Apache License, version 2, and can be used independently under the Apache v2 license. + +The Cartesi Machine emulator is a dynamic library in its own package. A recipient can replace it without a new build of the node. +go-ethereum is statically linked into every binary. Only its library packages are used, that is, everything outside `cmd/`. +The complete source of this project is in this repository under Apache 2.0. To build the node against a different go-ethereum, add a `replace` directive for `github.com/ethereum/go-ethereum` to `go.mod` and run `make build`. +The full text of the LGPL-3.0 and the GPL-3.0 is in [licenses/](licenses). diff --git a/THIRD_PARTY_LICENSES.md b/THIRD_PARTY_LICENSES.md index 70e345046..37a66cfd1 100644 --- a/THIRD_PARTY_LICENSES.md +++ b/THIRD_PARTY_LICENSES.md @@ -1,22 +1,53 @@ # Third Party Licenses -## github.com/BurntSushi/toml +This file lists the third party components distributed with the Cartesi Rollups Node. +Regenerate it with `make THIRD_PARTY_LICENSES.md` — never edit it directly. -* Name: github.com/BurntSushi/toml -* Version: v1.6.0 -* License: [MIT](https://github.com/BurntSushi/toml/blob/v1.6.0/COPYING) +The entries immediately below cover components that are not Go modules and are therefore +invisible to `go-licenses`; they are maintained by hand in `dev/licenses-manual.md`. +Everything after them is generated from the module graph, with the corrections listed in +`dev/licenses-overrides.tsv` applied. + +Two components reach users under the GNU Lesser General Public License v3.0: go-ethereum, +statically linked into every binary, and the Cartesi Machine emulator, loaded at run time. +The LGPL-3.0 is written as a set of additional permissions on top of the GPL-3.0. Both texts +are in [licenses/LGPL-3.0.txt](licenses/LGPL-3.0.txt) and +[licenses/GPL-3.0.txt](licenses/GPL-3.0.txt). + +The emulator is a dynamic library in its own package. A recipient can replace it without a new +build of the node. go-ethereum is statically linked. The complete source of this project is in +this repository under Apache-2.0. To build the node against a different go-ethereum, add a +`replace` directive for `github.com/ethereum/go-ethereum` to `go.mod` and run `make build`. + +The Go bindings under `pkg/contracts/` are generated from the release artifacts of +cartesi/rollups-contracts and cartesi/dave, pinned and checksum-verified by the Makefile. Both +repositories are Apache-2.0. They are listed below for attribution. + +## github.com/cartesi/machine-emulator + +* Name: github.com/cartesi/machine-emulator +* Version: 0.21.0 +* License: [LGPL-3.0](https://github.com/cartesi/machine-emulator/blob/v0.21.0/COPYING) -## github.com/FactomProject/basen +## github.com/cartesi/rollups-contracts -* Name: github.com/FactomProject/basen -* Version: v0.0.0-20150613233007-fe3947df716e -* License: [MIT](https://github.com/FactomProject/basen/blob/fe3947df716e/LICENSE) +* Name: github.com/cartesi/rollups-contracts +* Version: 3.0.0-alpha.10 +* License: [Apache-2.0](https://github.com/cartesi/rollups-contracts/blob/v3.0.0-alpha.10/LICENSE) +* Note: source of the generated contract bindings under pkg/contracts/. -## github.com/FactomProject/btcutilecc +## github.com/cartesi/dave -* Name: github.com/FactomProject/btcutilecc -* Version: v0.0.0-20130527213604-d3a63a5752ec -* License: [Unknown](Unknown) +* Name: github.com/cartesi/dave +* Version: 3.0.0-alpha.5 +* License: [Apache-2.0](https://github.com/cartesi/dave/blob/v3.0.0-alpha.5/LICENSE) +* Note: source of the generated PRT contract bindings under pkg/contracts/. + +## github.com/BurntSushi/toml + +* Name: github.com/BurntSushi/toml +* Version: v1.6.0 +* License: [MIT](https://github.com/BurntSushi/toml/blob/v1.6.0/COPYING) ## github.com/apapsch/go-jsonmerge/v2 @@ -27,116 +58,116 @@ ## github.com/aws/aws-sdk-go-v2 * Name: github.com/aws/aws-sdk-go-v2 -* Version: v1.41.12 -* License: [Apache-2.0](https://github.com/aws/aws-sdk-go-v2/blob/v1.41.12/LICENSE.txt) +* Version: v1.47.1 +* License: [Apache-2.0](https://github.com/aws/aws-sdk-go-v2/blob/v1.47.1/LICENSE.txt) ## github.com/aws/aws-sdk-go-v2/config * Name: github.com/aws/aws-sdk-go-v2/config -* Version: v1.32.23 -* License: [Apache-2.0](https://github.com/aws/aws-sdk-go-v2/blob/config/v1.32.23/config/LICENSE.txt) +* Version: v1.33.6 +* License: [Apache-2.0](https://github.com/aws/aws-sdk-go-v2/blob/config/v1.33.6/config/LICENSE.txt) ## github.com/aws/aws-sdk-go-v2/credentials * Name: github.com/aws/aws-sdk-go-v2/credentials -* Version: v1.19.22 -* License: [Apache-2.0](https://github.com/aws/aws-sdk-go-v2/blob/credentials/v1.19.22/credentials/LICENSE.txt) +* Version: v1.20.6 +* License: [Apache-2.0](https://github.com/aws/aws-sdk-go-v2/blob/credentials/v1.20.6/credentials/LICENSE.txt) ## github.com/aws/aws-sdk-go-v2/feature/ec2/imds * Name: github.com/aws/aws-sdk-go-v2/feature/ec2/imds -* Version: v1.18.28 -* License: [Apache-2.0](https://github.com/aws/aws-sdk-go-v2/blob/feature/ec2/imds/v1.18.28/feature/ec2/imds/LICENSE.txt) +* Version: v1.20.1 +* License: [Apache-2.0](https://github.com/aws/aws-sdk-go-v2/blob/feature/ec2/imds/v1.20.1/feature/ec2/imds/LICENSE.txt) ## github.com/aws/aws-sdk-go-v2/internal/configsources * Name: github.com/aws/aws-sdk-go-v2/internal/configsources -* Version: v1.4.28 -* License: [Apache-2.0](https://github.com/aws/aws-sdk-go-v2/blob/internal/configsources/v1.4.28/internal/configsources/LICENSE.txt) +* Version: v1.5.4 +* License: [Apache-2.0](https://github.com/aws/aws-sdk-go-v2/blob/internal/configsources/v1.5.4/internal/configsources/LICENSE.txt) ## github.com/aws/aws-sdk-go-v2/internal/endpoints/v2 * Name: github.com/aws/aws-sdk-go-v2/internal/endpoints/v2 -* Version: v2.7.28 -* License: [Apache-2.0](https://github.com/aws/aws-sdk-go-v2/blob/internal/endpoints/v2.7.28/internal/endpoints/v2/LICENSE.txt) +* Version: v2.8.4 +* License: [Apache-2.0](https://github.com/aws/aws-sdk-go-v2/blob/internal/endpoints/v2.8.4/internal/endpoints/v2/LICENSE.txt) ## github.com/aws/aws-sdk-go-v2/internal/sync/singleflight * Name: github.com/aws/aws-sdk-go-v2/internal/sync/singleflight -* Version: v1.41.12 -* License: [BSD-3-Clause](https://github.com/aws/aws-sdk-go-v2/blob/v1.41.12/internal/sync/singleflight/LICENSE) +* Version: v1.47.1 +* License: [BSD-3-Clause](https://github.com/aws/aws-sdk-go-v2/blob/v1.47.1/internal/sync/singleflight/LICENSE) ## github.com/aws/aws-sdk-go-v2/internal/v4a * Name: github.com/aws/aws-sdk-go-v2/internal/v4a -* Version: v1.4.29 -* License: [Apache-2.0](https://github.com/aws/aws-sdk-go-v2/blob/internal/v4a/v1.4.29/internal/v4a/LICENSE.txt) +* Version: v1.5.4 +* License: [Apache-2.0](https://github.com/aws/aws-sdk-go-v2/blob/internal/v4a/v1.5.4/internal/v4a/LICENSE.txt) ## github.com/aws/aws-sdk-go-v2/service/internal/accept-encoding * Name: github.com/aws/aws-sdk-go-v2/service/internal/accept-encoding -* Version: v1.13.12 -* License: [Apache-2.0](https://github.com/aws/aws-sdk-go-v2/blob/service/internal/accept-encoding/v1.13.12/service/internal/accept-encoding/LICENSE.txt) +* Version: v1.13.19 +* License: [Apache-2.0](https://github.com/aws/aws-sdk-go-v2/blob/service/internal/accept-encoding/v1.13.19/service/internal/accept-encoding/LICENSE.txt) ## github.com/aws/aws-sdk-go-v2/service/internal/presigned-url * Name: github.com/aws/aws-sdk-go-v2/service/internal/presigned-url -* Version: v1.13.28 -* License: [Apache-2.0](https://github.com/aws/aws-sdk-go-v2/blob/service/internal/presigned-url/v1.13.28/service/internal/presigned-url/LICENSE.txt) +* Version: v1.14.4 +* License: [Apache-2.0](https://github.com/aws/aws-sdk-go-v2/blob/service/internal/presigned-url/v1.14.4/service/internal/presigned-url/LICENSE.txt) ## github.com/aws/aws-sdk-go-v2/service/kms * Name: github.com/aws/aws-sdk-go-v2/service/kms -* Version: v1.53.3 -* License: [Apache-2.0](https://github.com/aws/aws-sdk-go-v2/blob/service/kms/v1.53.3/service/kms/LICENSE.txt) +* Version: v1.61.1 +* License: [Apache-2.0](https://github.com/aws/aws-sdk-go-v2/blob/service/kms/v1.61.1/service/kms/LICENSE.txt) ## github.com/aws/aws-sdk-go-v2/service/signin * Name: github.com/aws/aws-sdk-go-v2/service/signin -* Version: v1.1.4 -* License: [Apache-2.0](https://github.com/aws/aws-sdk-go-v2/blob/service/signin/v1.1.4/service/signin/LICENSE.txt) +* Version: v1.10.1 +* License: [Apache-2.0](https://github.com/aws/aws-sdk-go-v2/blob/service/signin/v1.10.1/service/signin/LICENSE.txt) ## github.com/aws/aws-sdk-go-v2/service/sso * Name: github.com/aws/aws-sdk-go-v2/service/sso -* Version: v1.31.2 -* License: [Apache-2.0](https://github.com/aws/aws-sdk-go-v2/blob/service/sso/v1.31.2/service/sso/LICENSE.txt) +* Version: v1.38.1 +* License: [Apache-2.0](https://github.com/aws/aws-sdk-go-v2/blob/service/sso/v1.38.1/service/sso/LICENSE.txt) ## github.com/aws/aws-sdk-go-v2/service/ssooidc * Name: github.com/aws/aws-sdk-go-v2/service/ssooidc -* Version: v1.36.5 -* License: [Apache-2.0](https://github.com/aws/aws-sdk-go-v2/blob/service/ssooidc/v1.36.5/service/ssooidc/LICENSE.txt) +* Version: v1.43.1 +* License: [Apache-2.0](https://github.com/aws/aws-sdk-go-v2/blob/service/ssooidc/v1.43.1/service/ssooidc/LICENSE.txt) ## github.com/aws/aws-sdk-go-v2/service/sts * Name: github.com/aws/aws-sdk-go-v2/service/sts -* Version: v1.43.2 -* License: [Apache-2.0](https://github.com/aws/aws-sdk-go-v2/blob/service/sts/v1.43.2/service/sts/LICENSE.txt) +* Version: v1.51.1 +* License: [Apache-2.0](https://github.com/aws/aws-sdk-go-v2/blob/service/sts/v1.51.1/service/sts/LICENSE.txt) ## github.com/aws/smithy-go * Name: github.com/aws/smithy-go -* Version: v1.27.2 -* License: [Apache-2.0](https://github.com/aws/smithy-go/blob/v1.27.2/LICENSE) +* Version: v1.28.2 +* License: [Apache-2.0](https://github.com/aws/smithy-go/blob/v1.28.2/LICENSE) ## github.com/aws/smithy-go/internal/sync/singleflight * Name: github.com/aws/smithy-go/internal/sync/singleflight -* Version: v1.27.2 -* License: [BSD-3-Clause](https://github.com/aws/smithy-go/blob/v1.27.2/internal/sync/singleflight/LICENSE) +* Version: v1.28.2 +* License: [BSD-3-Clause](https://github.com/aws/smithy-go/blob/v1.28.2/internal/sync/singleflight/LICENSE) -## github.com/bits-and-blooms/bitset +## github.com/aws/smithy-go/transport/http/protocol/internal/json/internal/stdlib -* Name: github.com/bits-and-blooms/bitset -* Version: v1.24.5 -* License: [BSD-3-Clause](https://github.com/bits-and-blooms/bitset/blob/v1.24.5/LICENSE) +* Name: github.com/aws/smithy-go/transport/http/protocol/internal/json/internal/stdlib +* Version: v1.28.2 +* License: [BSD-3-Clause](https://github.com/aws/smithy-go/blob/v1.28.2/transport/http/protocol/internal/json/internal/stdlib/LICENSE) -## github.com/cartesi/machine-emulator +## github.com/bits-and-blooms/bitset -* Name: github.com/cartesi/machine-emulator -* Version: 0.20.0 -* License: [LGPL-3.0](https://github.com/cartesi/machine-emulator/blob/v0.20.0/COPYING) +* Name: github.com/bits-and-blooms/bitset +* Version: v1.25.0 +* License: [BSD-3-Clause](https://github.com/bits-and-blooms/bitset/blob/v1.25.0/LICENSE) ## github.com/cespare/xxhash/v2 @@ -147,8 +178,8 @@ ## github.com/consensys/gnark-crypto * Name: github.com/consensys/gnark-crypto -* Version: v0.20.1 -* License: [Apache-2.0](https://github.com/consensys/gnark-crypto/blob/v0.20.1/LICENSE) +* Version: v0.21.0 +* License: [Apache-2.0](https://github.com/consensys/gnark-crypto/blob/v0.21.0/LICENSE) ## github.com/cpuguy83/go-md2man/v2/md2man @@ -162,41 +193,49 @@ * Version: v1.5.0 * License: [Apache-2.0](https://github.com/crate-crypto/go-eth-kzg/blob/v1.5.0/LICENSE) -## github.com/davecgh/go-spew/spew - -* Name: github.com/davecgh/go-spew/spew -* Version: v1.1.2-0.20180830191138-d8f796af33cc -* License: [ISC](https://github.com/davecgh/go-spew/blob/d8f796af33cc/LICENSE) - ## github.com/deckarep/golang-set/v2 * Name: github.com/deckarep/golang-set/v2 * Version: v2.9.0 * License: [MIT](https://github.com/deckarep/golang-set/blob/v2.9.0/LICENSE) +## github.com/decred/dcrd/dcrec/secp256k1/v4 + +* Name: github.com/decred/dcrd/dcrec/secp256k1/v4 +* Version: v4.4.1 +* License: [ISC](https://github.com/decred/dcrd/blob/dcrec/secp256k1/v4.4.1/LICENSE) + ## github.com/ethereum/go-ethereum * Name: github.com/ethereum/go-ethereum -* Version: v1.17.3 -* License: [GPL-3.0](https://github.com/ethereum/go-ethereum/blob/v1.17.3/COPYING) +* Version: v1.17.7 +* License: [LGPL-3.0](https://github.com/ethereum/go-ethereum/blob/v1.17.7/COPYING.LESSER) +* Note: only the library packages are used, that is, everything outside cmd/, and those are LGPL-3.0. The GPL-3.0 COPYING file at the module root covers go-ethereum's own binaries, which this project does not build or distribute. ## github.com/ethereum/go-ethereum/crypto/keccak * Name: github.com/ethereum/go-ethereum/crypto/keccak -* Version: v1.17.3 -* License: [BSD-3-Clause](https://github.com/ethereum/go-ethereum/blob/v1.17.3/crypto/keccak/LICENSE) +* Version: v1.17.7 +* License: [BSD-3-Clause](https://github.com/ethereum/go-ethereum/blob/v1.17.7/crypto/keccak/LICENSE) ## github.com/ethereum/go-ethereum/crypto/secp256k1 * Name: github.com/ethereum/go-ethereum/crypto/secp256k1 -* Version: v1.17.3 -* License: [BSD-3-Clause](https://github.com/ethereum/go-ethereum/blob/v1.17.3/crypto/secp256k1/LICENSE) +* Version: v1.17.7 +* License: [BSD-3-Clause](https://github.com/ethereum/go-ethereum/blob/v1.17.7/crypto/secp256k1/LICENSE) +* Note: built with cgo, this package also compiles the bundled libsecp256k1 C library, which is under the [MIT licence](https://github.com/ethereum/go-ethereum/blob/v1.17.7/crypto/secp256k1/libsecp256k1/COPYING) ## github.com/ethereum/go-ethereum/metrics * Name: github.com/ethereum/go-ethereum/metrics -* Version: v1.17.3 -* License: [BSD-2-Clause-FreeBSD](https://github.com/ethereum/go-ethereum/blob/v1.17.3/metrics/LICENSE) +* Version: v1.17.7 +* License: [BSD-2-Clause-FreeBSD](https://github.com/ethereum/go-ethereum/blob/v1.17.7/metrics/LICENSE) + +## github.com/fjl/jsonw + +* Name: github.com/fjl/jsonw +* Version: v0.1.0 +* License: [MIT](https://github.com/fjl/jsonw/blob/v0.1.0/LICENSE) ## github.com/fsnotify/fsnotify @@ -207,14 +246,14 @@ ## github.com/go-jet/jet/v2 * Name: github.com/go-jet/jet/v2 -* Version: v2.15.0 -* License: [Apache-2.0](https://github.com/go-jet/jet/blob/v2.15.0/LICENSE) +* Version: v2.16.0 +* License: [Apache-2.0](https://github.com/go-jet/jet/blob/v2.16.0/LICENSE) ## github.com/go-logr/logr * Name: github.com/go-logr/logr -* Version: v1.4.3 -* License: [Apache-2.0](https://github.com/go-logr/logr/blob/v1.4.3/LICENSE) +* Version: v1.4.4 +* License: [Apache-2.0](https://github.com/go-logr/logr/blob/v1.4.4/LICENSE) ## github.com/go-logr/stdr @@ -231,8 +270,8 @@ ## github.com/golang-migrate/migrate/v4 * Name: github.com/golang-migrate/migrate/v4 -* Version: v4.19.1 -* License: [MIT](https://github.com/golang-migrate/migrate/blob/v4.19.1/LICENSE) +* Version: v4.20.1 +* License: [MIT](https://github.com/golang-migrate/migrate/blob/v4.20.1/LICENSE) ## github.com/google/uuid @@ -321,8 +360,8 @@ ## github.com/jackc/pgx/v5 * Name: github.com/jackc/pgx/v5 -* Version: v5.10.0 -* License: [MIT](https://github.com/jackc/pgx/blob/v5.10.0/LICENSE) +* Version: v5.11.0 +* License: [MIT](https://github.com/jackc/pgx/blob/v5.11.0/LICENSE) ## github.com/jackc/puddle/v2 @@ -339,26 +378,20 @@ ## github.com/lmittmann/tint * Name: github.com/lmittmann/tint -* Version: v1.1.3 -* License: [MIT](https://github.com/lmittmann/tint/blob/v1.1.3/LICENSE) +* Version: v1.2.0 +* License: [MIT](https://github.com/lmittmann/tint/blob/v1.2.0/LICENSE) ## github.com/oapi-codegen/runtime * Name: github.com/oapi-codegen/runtime -* Version: v1.4.1 -* License: [Apache-2.0](https://github.com/oapi-codegen/runtime/blob/v1.4.1/LICENSE) +* Version: v1.7.0 +* License: [Apache-2.0](https://github.com/oapi-codegen/runtime/blob/v1.7.0/LICENSE) ## github.com/pelletier/go-toml/v2 * Name: github.com/pelletier/go-toml/v2 -* Version: v2.3.1 -* License: [MIT](https://github.com/pelletier/go-toml/blob/v2.3.1/LICENSE) - -## github.com/pmezard/go-difflib/difflib - -* Name: github.com/pmezard/go-difflib/difflib -* Version: v1.0.1-0.20181226105442-5d4384ee4fb2 -* License: [BSD-3-Clause](https://github.com/pmezard/go-difflib/blob/5d4384ee4fb2/LICENSE) +* Version: v2.4.3 +* License: [MIT](https://github.com/pelletier/go-toml/blob/v2.4.3/LICENSE) ## github.com/russross/blackfriday/v2 @@ -411,8 +444,20 @@ ## github.com/stretchr/testify * Name: github.com/stretchr/testify -* Version: v1.11.1 -* License: [MIT](https://github.com/stretchr/testify/blob/v1.11.1/LICENSE) +* Version: v1.12.1 +* License: [MIT](https://github.com/stretchr/testify/blob/v1.12.1/LICENSE) + +## github.com/stretchr/testify/internal/difflib + +* Name: github.com/stretchr/testify/internal/difflib +* Version: v1.12.1 +* License: [BSD-3-Clause](https://github.com/stretchr/testify/blob/v1.12.1/internal/difflib/LICENSE) + +## github.com/stretchr/testify/internal/spew + +* Name: github.com/stretchr/testify/internal/spew +* Version: v1.12.1 +* License: [ISC](https://github.com/stretchr/testify/blob/v1.12.1/internal/spew/LICENSE) ## github.com/subosito/gotenv @@ -432,12 +477,6 @@ * Version: v0.12.0 * License: [Apache-2.0](https://github.com/tklauser/numcpus/blob/v0.12.0/LICENSE) -## github.com/tyler-smith/go-bip32 - -* Name: github.com/tyler-smith/go-bip32 -* Version: v1.0.0 -* License: [MIT](https://github.com/tyler-smith/go-bip32/blob/v1.0.0/LICENSE) - ## github.com/tyler-smith/go-bip39 * Name: github.com/tyler-smith/go-bip39 @@ -447,8 +486,8 @@ ## go.mongodb.org/mongo-driver * Name: go.mongodb.org/mongo-driver -* Version: v1.17.9 -* License: [Apache-2.0](https://github.com/mongodb/mongo-go-driver/blob/v1.17.9/LICENSE) +* Version: v1.17.10 +* License: [Apache-2.0](https://github.com/mongodb/mongo-go-driver/blob/v1.17.10/LICENSE) ## go.opentelemetry.io/auto/sdk @@ -459,53 +498,47 @@ ## go.opentelemetry.io/otel * Name: go.opentelemetry.io/otel -* Version: v1.44.0 -* License: [Apache-2.0](https://github.com/open-telemetry/opentelemetry-go/blob/v1.44.0/LICENSE) +* Version: v1.46.0 +* License: [Apache-2.0](https://github.com/open-telemetry/opentelemetry-go/blob/v1.46.0/LICENSE) ## go.opentelemetry.io/otel/metric * Name: go.opentelemetry.io/otel/metric -* Version: v1.44.0 -* License: [Apache-2.0](https://github.com/open-telemetry/opentelemetry-go/blob/metric/v1.44.0/metric/LICENSE) +* Version: v1.46.0 +* License: [Apache-2.0](https://github.com/open-telemetry/opentelemetry-go/blob/metric/v1.46.0/metric/LICENSE) ## go.opentelemetry.io/otel/trace * Name: go.opentelemetry.io/otel/trace -* Version: v1.44.0 -* License: [Apache-2.0](https://github.com/open-telemetry/opentelemetry-go/blob/trace/v1.44.0/trace/LICENSE) +* Version: v1.46.0 +* License: [Apache-2.0](https://github.com/open-telemetry/opentelemetry-go/blob/trace/v1.46.0/trace/LICENSE) ## go.yaml.in/yaml/v3 * Name: go.yaml.in/yaml/v3 -* Version: v3.0.4 -* License: [MIT](https://github.com/yaml/go-yaml/blob/v3.0.4/LICENSE) +* Version: v3.0.5 +* License: [MIT](https://github.com/yaml/go-yaml/blob/v3.0.5/LICENSE) ## golang.org/x/crypto * Name: golang.org/x/crypto -* Version: v0.52.0 -* License: [BSD-3-Clause](https://cs.opensource.google/go/x/crypto/+/v0.52.0:LICENSE) +* Version: v0.57.0 +* License: [BSD-3-Clause](https://cs.opensource.google/go/x/crypto/+/v0.57.0:LICENSE) ## golang.org/x/sync * Name: golang.org/x/sync -* Version: v0.20.0 -* License: [BSD-3-Clause](https://cs.opensource.google/go/x/sync/+/v0.20.0:LICENSE) +* Version: v0.23.0 +* License: [BSD-3-Clause](https://cs.opensource.google/go/x/sync/+/v0.23.0:LICENSE) ## golang.org/x/sys * Name: golang.org/x/sys -* Version: v0.45.0 -* License: [BSD-3-Clause](https://cs.opensource.google/go/x/sys/+/v0.45.0:LICENSE) +* Version: v0.48.0 +* License: [BSD-3-Clause](https://cs.opensource.google/go/x/sys/+/v0.48.0:LICENSE) ## golang.org/x/text * Name: golang.org/x/text -* Version: v0.37.0 -* License: [BSD-3-Clause](https://cs.opensource.google/go/x/text/+/v0.37.0:LICENSE) - -## gopkg.in/yaml.v3 - -* Name: gopkg.in/yaml.v3 -* Version: v3.0.1 -* License: [MIT](https://github.com/go-yaml/yaml/blob/v3.0.1/LICENSE) +* Version: v0.42.0 +* License: [BSD-3-Clause](https://cs.opensource.google/go/x/text/+/v0.42.0:LICENSE) diff --git a/cmd/cartesi-rollups-cli/root/app/register/register.go b/cmd/cartesi-rollups-cli/root/app/register/register.go index ef7e88822..1f4cea074 100644 --- a/cmd/cartesi-rollups-cli/root/app/register/register.go +++ b/cmd/cartesi-rollups-cli/root/app/register/register.go @@ -23,7 +23,6 @@ import ( "github.com/ethereum/go-ethereum/accounts/abi/bind" "github.com/ethereum/go-ethereum/common" - "github.com/ethereum/go-ethereum/ethclient" "github.com/spf13/cobra" "github.com/spf13/viper" ) @@ -284,7 +283,7 @@ func getTemplateHash( ) (*common.Hash, error) { ethEndpoint, err := config.GetBlockchainHttpEndpoint() cobra.CheckErr(err) - client, err := ethclient.Dial(ethEndpoint.Raw()) + client, err := ethutil.DialEthClient(ctx, ethEndpoint.Raw()) if err != nil { return nil, fmt.Errorf("failed to connect to the blockchain http endpoint: %s", ethEndpoint) } @@ -299,7 +298,7 @@ func hasCodeAt( if err != nil { return false, fmt.Errorf("failed to get blockchain http endpoint address: %w", err) } - client, err := ethclient.Dial(ethEndpoint.Raw()) + client, err := ethutil.DialEthClient(ctx, ethEndpoint.Raw()) if err != nil { return false, fmt.Errorf("failed to connect to the blockchain http endpoint: %s", ethEndpoint) } @@ -318,7 +317,7 @@ func getConsensus( if err != nil { return common.Address{}, fmt.Errorf("failed to get blockchain http endpoint address: %w", err) } - client, err := ethclient.Dial(ethEndpoint.Raw()) + client, err := ethutil.DialEthClient(ctx, ethEndpoint.Raw()) if err != nil { return common.Address{}, fmt.Errorf("failed to connect to the blockchain http endpoint: %s", ethEndpoint) } @@ -333,7 +332,7 @@ func getInputBox( if err != nil { return common.Address{}, fmt.Errorf("failed to get blockchain http endpoint address: %w", err) } - client, err := ethclient.Dial(ethEndpoint.Raw()) + client, err := ethutil.DialEthClient(ctx, ethEndpoint.Raw()) if err != nil { return common.Address{}, fmt.Errorf("failed to connect to the blockchain http endpoint: %s", ethEndpoint) } @@ -348,7 +347,7 @@ func getEpochLength( if err != nil { return 0, fmt.Errorf("failed to get blockchain http endpoint address: %w", err) } - client, err := ethclient.Dial(ethEndpoint.Raw()) + client, err := ethutil.DialEthClient(ctx, ethEndpoint.Raw()) if err != nil { return 0, fmt.Errorf("failed to connect to the blockchain http endpoint: %s", ethEndpoint) } @@ -363,7 +362,7 @@ func getClaimStagingPeriod( if err != nil { return 0, fmt.Errorf("failed to get blockchain http endpoint address: %w", err) } - client, err := ethclient.Dial(ethEndpoint.Raw()) + client, err := ethutil.DialEthClient(ctx, ethEndpoint.Raw()) if err != nil { return 0, fmt.Errorf("failed to connect to the blockchain http endpoint: %s", ethEndpoint) } @@ -387,7 +386,7 @@ func getConsensusType( if err != nil { return "", fmt.Errorf("failed to get blockchain http endpoint address: %w", err) } - client, err := ethclient.DialContext(ctx, ethEndpoint.Raw()) + client, err := ethutil.DialEthClient(ctx, ethEndpoint.Raw()) if err != nil { return "", fmt.Errorf("failed to connect to the blockchain http endpoint: %s", ethEndpoint) } @@ -423,7 +422,7 @@ func readApplicationWithdrawalConfig( if err != nil { return model.WithdrawalConfig{}, fmt.Errorf("failed to get blockchain http endpoint address: %w", err) } - client, err := ethclient.Dial(ethEndpoint.Raw()) + client, err := ethutil.DialEthClient(ctx, ethEndpoint.Raw()) if err != nil { return model.WithdrawalConfig{}, fmt.Errorf("failed to connect to the blockchain http endpoint: %s", ethEndpoint) } @@ -442,7 +441,7 @@ func getInputBoxDeploymentBlock( if err != nil { return nil, fmt.Errorf("failed to get blockchain http endpoint address: %w", err) } - client, err := ethclient.Dial(ethEndpoint.Raw()) + client, err := ethutil.DialEthClient(ctx, ethEndpoint.Raw()) if err != nil { return nil, fmt.Errorf("failed to connect to the blockchain http endpoint: %s", ethEndpoint) } diff --git a/cmd/cartesi-rollups-cli/root/contract/contract.go b/cmd/cartesi-rollups-cli/root/contract/contract.go index ea20f74db..6a555bb6f 100644 --- a/cmd/cartesi-rollups-cli/root/contract/contract.go +++ b/cmd/cartesi-rollups-cli/root/contract/contract.go @@ -189,7 +189,7 @@ func newChainClient( appAddr common.Address, block *big.Int, ) (*chainClient, error) { - client, err := ethclient.DialContext(ctx, endpoint) + client, err := ethutil.DialEthClient(ctx, endpoint) if err != nil { return nil, fmt.Errorf("connect to RPC endpoint: %w", err) } diff --git a/cmd/cartesi-rollups-cli/root/deploy/application.go b/cmd/cartesi-rollups-cli/root/deploy/application.go index e9865e4cd..7f1ef23fe 100644 --- a/cmd/cartesi-rollups-cli/root/deploy/application.go +++ b/cmd/cartesi-rollups-cli/root/deploy/application.go @@ -153,7 +153,7 @@ func runDeployApplication(cmd *cobra.Command, args []string) { ethEndpoint, err := config.GetBlockchainHttpEndpoint() cobra.CheckErr(err) - client, err := ethclient.DialContext(ctx, ethEndpoint.Raw()) + client, err := ethutil.DialEthClient(ctx, ethEndpoint.Raw()) cobra.CheckErr(err) defer client.Close() diff --git a/cmd/cartesi-rollups-cli/root/deploy/authority.go b/cmd/cartesi-rollups-cli/root/deploy/authority.go index 416ac2dc7..ecef5a4f8 100644 --- a/cmd/cartesi-rollups-cli/root/deploy/authority.go +++ b/cmd/cartesi-rollups-cli/root/deploy/authority.go @@ -16,7 +16,6 @@ import ( "github.com/ethereum/go-ethereum/accounts/abi/bind" "github.com/ethereum/go-ethereum/common" "github.com/ethereum/go-ethereum/core/types" - "github.com/ethereum/go-ethereum/ethclient" "github.com/spf13/cobra" ) @@ -70,7 +69,7 @@ func runDeployAuthority(cmd *cobra.Command, _ []string) { ethEndpoint, err := config.GetBlockchainHttpEndpoint() cobra.CheckErr(err) - client, err := ethclient.DialContext(ctx, ethEndpoint.Raw()) + client, err := ethutil.DialEthClient(ctx, ethEndpoint.Raw()) cobra.CheckErr(err) defer client.Close() diff --git a/cmd/cartesi-rollups-cli/root/deploy/quorum.go b/cmd/cartesi-rollups-cli/root/deploy/quorum.go index 35f21191c..36fc6b3f0 100644 --- a/cmd/cartesi-rollups-cli/root/deploy/quorum.go +++ b/cmd/cartesi-rollups-cli/root/deploy/quorum.go @@ -16,7 +16,6 @@ import ( "github.com/ethereum/go-ethereum/accounts/abi/bind" "github.com/ethereum/go-ethereum/common" "github.com/ethereum/go-ethereum/core/types" - "github.com/ethereum/go-ethereum/ethclient" "github.com/spf13/cobra" ) @@ -70,7 +69,7 @@ func runDeployQuorum(cmd *cobra.Command, _ []string) { ethEndpoint, err := config.GetBlockchainHttpEndpoint() cobra.CheckErr(err) - client, err := ethclient.DialContext(ctx, ethEndpoint.Raw()) + client, err := ethutil.DialEthClient(ctx, ethEndpoint.Raw()) cobra.CheckErr(err) defer client.Close() diff --git a/cmd/cartesi-rollups-cli/root/deposit/deposit.go b/cmd/cartesi-rollups-cli/root/deposit/deposit.go index c446ff10a..cde8bda3c 100644 --- a/cmd/cartesi-rollups-cli/root/deposit/deposit.go +++ b/cmd/cartesi-rollups-cli/root/deposit/deposit.go @@ -19,11 +19,11 @@ import ( "github.com/cartesi/rollups-node/pkg/contracts/ierc20metadata" "github.com/cartesi/rollups-node/pkg/contracts/ierc20portal" "github.com/cartesi/rollups-node/pkg/contracts/iinputbox" + "github.com/cartesi/rollups-node/pkg/ethutil" "github.com/ethereum/go-ethereum/accounts/abi/bind" "github.com/ethereum/go-ethereum/common" "github.com/ethereum/go-ethereum/common/hexutil" "github.com/ethereum/go-ethereum/core/types" - "github.com/ethereum/go-ethereum/ethclient" "github.com/spf13/cobra" ) @@ -143,7 +143,7 @@ func runERC20(cmd *cobra.Command, args []string) error { if err != nil { return err } - client, err := ethclient.DialContext(ctx, ethEndpoint.Raw()) + client, err := ethutil.DialEthClient(ctx, ethEndpoint.Raw()) if err != nil { return err } diff --git a/cmd/cartesi-rollups-cli/root/execute/execute.go b/cmd/cartesi-rollups-cli/root/execute/execute.go index f0c35d958..77de74a1a 100644 --- a/cmd/cartesi-rollups-cli/root/execute/execute.go +++ b/cmd/cartesi-rollups-cli/root/execute/execute.go @@ -16,7 +16,6 @@ import ( "github.com/ethereum/go-ethereum/common" "github.com/ethereum/go-ethereum/common/hexutil" "github.com/ethereum/go-ethereum/core/types" - "github.com/ethereum/go-ethereum/ethclient" "github.com/spf13/cobra" "github.com/cartesi/rollups-node/cmd/cartesi-rollups-cli/util" @@ -24,6 +23,7 @@ import ( "github.com/cartesi/rollups-node/internal/config" "github.com/cartesi/rollups-node/internal/repository/factory" "github.com/cartesi/rollups-node/pkg/contracts/iapplication" + "github.com/cartesi/rollups-node/pkg/ethutil" ) var Cmd = newCommand() @@ -112,7 +112,7 @@ func (o *options) run(cmd *cobra.Command, args []string) error { if err != nil { return err } - client, err := ethclient.DialContext(ctx, ethEndpoint.Raw()) + client, err := ethutil.DialEthClient(ctx, ethEndpoint.Raw()) if err != nil { return err } diff --git a/cmd/cartesi-rollups-cli/root/foreclose/foreclose.go b/cmd/cartesi-rollups-cli/root/foreclose/foreclose.go index c71632267..99a0ef296 100644 --- a/cmd/cartesi-rollups-cli/root/foreclose/foreclose.go +++ b/cmd/cartesi-rollups-cli/root/foreclose/foreclose.go @@ -10,13 +10,13 @@ import ( "github.com/ethereum/go-ethereum/accounts/abi/bind" "github.com/ethereum/go-ethereum/common" "github.com/ethereum/go-ethereum/core/types" - "github.com/ethereum/go-ethereum/ethclient" "github.com/spf13/cobra" "github.com/cartesi/rollups-node/cmd/cartesi-rollups-cli/util" "github.com/cartesi/rollups-node/internal/cli" "github.com/cartesi/rollups-node/internal/config" "github.com/cartesi/rollups-node/pkg/contracts/iapplication" + "github.com/cartesi/rollups-node/pkg/ethutil" ) var Cmd = &cobra.Command{ @@ -90,7 +90,7 @@ func run(cmd *cobra.Command, args []string) error { return err } - client, err := ethclient.DialContext(ctx, ethEndpoint.Raw()) + client, err := ethutil.DialEthClient(ctx, ethEndpoint.Raw()) if err != nil { return err } diff --git a/cmd/cartesi-rollups-cli/root/provedriveroot/provedriveroot.go b/cmd/cartesi-rollups-cli/root/provedriveroot/provedriveroot.go index d47f240c5..3113c2ec7 100644 --- a/cmd/cartesi-rollups-cli/root/provedriveroot/provedriveroot.go +++ b/cmd/cartesi-rollups-cli/root/provedriveroot/provedriveroot.go @@ -13,13 +13,13 @@ import ( "github.com/ethereum/go-ethereum/common" "github.com/ethereum/go-ethereum/common/hexutil" "github.com/ethereum/go-ethereum/core/types" - "github.com/ethereum/go-ethereum/ethclient" "github.com/spf13/cobra" "github.com/cartesi/rollups-node/cmd/cartesi-rollups-cli/util" "github.com/cartesi/rollups-node/internal/cli" "github.com/cartesi/rollups-node/internal/config" "github.com/cartesi/rollups-node/pkg/contracts/iapplication" + "github.com/cartesi/rollups-node/pkg/ethutil" ) var Cmd = &cobra.Command{ @@ -107,7 +107,7 @@ func run(cmd *cobra.Command, args []string) error { if err != nil { return err } - client, err := ethclient.DialContext(ctx, ethEndpoint.Raw()) + client, err := ethutil.DialEthClient(ctx, ethEndpoint.Raw()) if err != nil { return err } diff --git a/cmd/cartesi-rollups-cli/root/refund/refund.go b/cmd/cartesi-rollups-cli/root/refund/refund.go index 5844be787..72e4b3e64 100644 --- a/cmd/cartesi-rollups-cli/root/refund/refund.go +++ b/cmd/cartesi-rollups-cli/root/refund/refund.go @@ -16,13 +16,13 @@ import ( "github.com/ethereum/go-ethereum/common" "github.com/ethereum/go-ethereum/common/hexutil" "github.com/ethereum/go-ethereum/core/types" - "github.com/ethereum/go-ethereum/ethclient" "github.com/spf13/cobra" "github.com/cartesi/rollups-node/cmd/cartesi-rollups-cli/util" "github.com/cartesi/rollups-node/internal/cli" "github.com/cartesi/rollups-node/internal/config" "github.com/cartesi/rollups-node/pkg/contracts/iapplication" + "github.com/cartesi/rollups-node/pkg/ethutil" ) var Cmd = newCommand() @@ -114,7 +114,7 @@ func (o *options) run(cmd *cobra.Command, args []string) error { if err != nil { return err } - client, err := ethclient.DialContext(ctx, endpoint.Raw()) + client, err := ethutil.DialEthClient(ctx, endpoint.Raw()) if err != nil { return fmt.Errorf("connect to Ethereum: %w", err) } diff --git a/cmd/cartesi-rollups-cli/root/refund/refund_test.go b/cmd/cartesi-rollups-cli/root/refund/refund_test.go index fa54691cd..ed2f5cae7 100644 --- a/cmd/cartesi-rollups-cli/root/refund/refund_test.go +++ b/cmd/cartesi-rollups-cli/root/refund/refund_test.go @@ -172,7 +172,9 @@ func (r *refundRPC) EstimateGas(context.Context, map[string]json.RawMessage) (he return testGasLimit, r.estimateErr } -func (r *refundRPC) GetTransactionReceipt(_ context.Context, hash common.Hash) (*types.Receipt, error) { +// The result is any so that a pending receipt is an untyped nil. The RPC server +// calls MarshalJSON directly, and a nil *types.Receipt makes it panic. +func (r *refundRPC) GetTransactionReceipt(_ context.Context, hash common.Hash) (any, error) { r.receipts.Add(1) if r.pending { return nil, nil diff --git a/cmd/cartesi-rollups-cli/root/send/send.go b/cmd/cartesi-rollups-cli/root/send/send.go index 197302314..b83a9422d 100644 --- a/cmd/cartesi-rollups-cli/root/send/send.go +++ b/cmd/cartesi-rollups-cli/root/send/send.go @@ -16,12 +16,12 @@ import ( "github.com/cartesi/rollups-node/internal/config" "github.com/cartesi/rollups-node/pkg/contracts/iapplication" "github.com/cartesi/rollups-node/pkg/contracts/iinputbox" + "github.com/cartesi/rollups-node/pkg/ethutil" "github.com/ethereum/go-ethereum/accounts/abi/bind" "github.com/ethereum/go-ethereum/common" "github.com/ethereum/go-ethereum/common/hexutil" "github.com/ethereum/go-ethereum/core/types" - "github.com/ethereum/go-ethereum/ethclient" "github.com/spf13/cobra" ) @@ -139,7 +139,7 @@ func run(cmd *cobra.Command, args []string) error { return err } - client, err := ethclient.DialContext(ctx, ethEndpoint.Raw()) + client, err := ethutil.DialEthClient(ctx, ethEndpoint.Raw()) if err != nil { return err } diff --git a/cmd/cartesi-rollups-cli/root/validate/validate.go b/cmd/cartesi-rollups-cli/root/validate/validate.go index 9ae180b41..656995a46 100644 --- a/cmd/cartesi-rollups-cli/root/validate/validate.go +++ b/cmd/cartesi-rollups-cli/root/validate/validate.go @@ -14,7 +14,6 @@ import ( "github.com/cartesi/rollups-node/pkg/contracts/iapplication" "github.com/cartesi/rollups-node/pkg/ethutil" - "github.com/ethereum/go-ethereum/ethclient" "github.com/spf13/cobra" ) @@ -87,7 +86,7 @@ func run(cmd *cobra.Command, args []string) { os.Exit(0) } - client, err := ethclient.DialContext(ctx, ethEndpoint.Raw()) + client, err := ethutil.DialEthClient(ctx, ethEndpoint.Raw()) cobra.CheckErr(err) if !asJSONParam { diff --git a/cmd/cartesi-rollups-cli/root/withdraw/withdraw.go b/cmd/cartesi-rollups-cli/root/withdraw/withdraw.go index 86d92ba0c..e52e8ad4a 100644 --- a/cmd/cartesi-rollups-cli/root/withdraw/withdraw.go +++ b/cmd/cartesi-rollups-cli/root/withdraw/withdraw.go @@ -14,7 +14,6 @@ import ( "github.com/ethereum/go-ethereum/common" "github.com/ethereum/go-ethereum/common/hexutil" "github.com/ethereum/go-ethereum/core/types" - "github.com/ethereum/go-ethereum/ethclient" "github.com/spf13/cobra" "github.com/cartesi/rollups-node/cmd/cartesi-rollups-cli/util" @@ -113,7 +112,7 @@ func run(cmd *cobra.Command, args []string) error { if err != nil { return err } - client, err := ethclient.DialContext(ctx, ethEndpoint.Raw()) + client, err := ethutil.DialEthClient(ctx, ethEndpoint.Raw()) if err != nil { return err } diff --git a/cmd/cartesi-rollups-machine-tool/main.go b/cmd/cartesi-rollups-machine-tool/main.go index 56d603468..7108d7256 100644 --- a/cmd/cartesi-rollups-machine-tool/main.go +++ b/cmd/cartesi-rollups-machine-tool/main.go @@ -92,6 +92,12 @@ func runReplay(ctx context.Context, opts replayOptions) error { return fmt.Errorf("database connection is required for replay: %w", err) } opts.DatabaseConnection = dsn.Raw() + } else { + dsn, err := config.ToURLFromString(opts.DatabaseConnection) + if err != nil { + return fmt.Errorf("--database-connection: %w", err) + } + opts.DatabaseConnection = dsn.Raw() } if opts.HasToEpoch == opts.HasToInputIndex { return errors.New("exactly one replay target is required: --to-epoch or --to-input-index") diff --git a/dev/licenses-generate.sh b/dev/licenses-generate.sh new file mode 100755 index 000000000..07164f758 --- /dev/null +++ b/dev/licenses-generate.sh @@ -0,0 +1,124 @@ +#!/usr/bin/env bash +# (c) Cartesi and individual authors (see AUTHORS) +# SPDX-License-Identifier: Apache-2.0 (see LICENSE) +# +# Write THIRD_PARTY_LICENSES.md to stdout. Invoked by `make THIRD_PARTY_LICENSES.md`. +# +# go-licenses only sees Go modules, and only the ones reachable for the platform +# it happens to run under. Redirecting its report straight over the notices file +# therefore drops both the hand-written entries and any module that is only +# linked on another target. This script keeps that knowledge outside the +# generated file: +# +# 1. run the report once per released target and cgo mode, and merge the +# results, +# 2. drop the entry go-licenses emits for this module itself, +# 3. apply the corrections listed in dev/licenses-overrides.tsv, +# 4. prepend the hand-written entries in dev/licenses-manual.md. + +set -euo pipefail + +MODULE=github.com/cartesi/rollups-node +TEMPLATE=dev/licenses.tpl +MANUAL=dev/licenses-manual.md +OVERRIDES=dev/licenses-overrides.tsv + +# The platforms binaries are released for. The notices file describes what is +# distributed, and the .deb and the container image are both Linux. +TARGETS="linux/amd64 linux/arm64" + +# The machine artifacts are built with cgo and the other artifacts without it, +# and the two builds of a dependency may reach different packages. go-ethereum, +# for one, links libsecp256k1 with cgo and a pure Go secp256k1 without it. +CGO_MODES="1 0" + +# Other go-licenses versions classify some licences differently. CI installs +# this version too. +GO_LICENSES_VERSION=v1.6.0 +build_info=$(go version -m "$(command -v go-licenses)" 2>/dev/null) || build_info= +if ! grep -Eq "^[[:space:]]+mod[[:space:]]+github.com/google/go-licenses[[:space:]]+$GO_LICENSES_VERSION([[:space:]]|$)" \ + <<<"$build_info"; then + echo "licenses-generate: go-licenses $GO_LICENSES_VERSION is required" >&2 + exit 1 +fi + +# go-licenses recognises the standard library by its GOROOT, which is the GOROOT +# of the Go that built it unless GOROOT is set. Use the GOROOT of the go command, +# so that a go-licenses built by another Go installation works too. +GOROOT=$(go env GOROOT) +export GOROOT + +# Collect the reports before processing them, so that a go-licenses failure +# stops the script here. +reports=$( + for target in $TARGETS; do + for cgo in $CGO_MODES; do + GOOS="${target%/*}" GOARCH="${target#*/}" CGO_ENABLED=$cgo \ + go-licenses report --template "$TEMPLATE" ./... || exit 1 + done + done +) + +cat "$MANUAL" + +# Flatten each entry to a single "name version license url" record. +printf '%s\n' "$reports" | + awk -v self="$MODULE" ' + /^## / { name = substr($0, 4); next } + /^\* Version: / { version = substr($0, 12); next } + /^\* License: / { + link = substr($0, 12) + split_at = index(link, "](") + license = substr(link, 2, split_at - 2) + url = substr(link, split_at + 2, length(link) - split_at - 2) + if (name != self) + printf "%s\t%s\t%s\t%s\n", name, version, license, url + next + } + ' | + # A module reached by more than one target is listed once: deduplicate on + # the module name, which also restores the generator's own ordering. + LC_ALL=C sort -t "$(printf '\t')" -k1,1 -u | + # Render the records back as Markdown, applying the overrides. + awk -F'\t' -v overrides="$OVERRIDES" ' + BEGIN { + while ((getline line < overrides) > 0) { + if (line ~ /^#/ || line ~ /^[ \t]*$/) + continue + split(line, field, "\t") + override_license[field[1]] = field[2] + override_url[field[1]] = field[3] + override_note[field[1]] = field[4] + } + } + { + name = $1; version = $2; license = $3; url = $4; note = "" + if (name in override_license) { + license = override_license[name] + url = override_url[name] + note = override_note[name] + gsub(/\{version\}/, version, url) + gsub(/\{version\}/, version, note) + applied[name] = 1 + } + # go-licenses writes Unknown when it cannot classify a licence, or + # when it cannot resolve the URL, as happens without network access. + if (license == "Unknown" || url == "Unknown") { + printf "licenses-generate: unknown licence or URL for %s\n", name > "/dev/stderr" + failed = 1 + } + printf "\n## %s\n\n", name + printf "* Name: %s\n* Version: %s\n* License: [%s](%s)\n", name, version, license, url + if (note != "") + printf "* Note: %s\n", note + } + END { + for (name in override_license) { + if (!(name in applied)) { + printf "licenses-generate: no entry matches the override for %s\n", name > "/dev/stderr" + failed = 1 + } + } + exit failed + } + ' diff --git a/dev/licenses-manual.md b/dev/licenses-manual.md new file mode 100644 index 000000000..3b002b0cd --- /dev/null +++ b/dev/licenses-manual.md @@ -0,0 +1,44 @@ +# Third Party Licenses + +This file lists the third party components distributed with the Cartesi Rollups Node. +Regenerate it with `make THIRD_PARTY_LICENSES.md` — never edit it directly. + +The entries immediately below cover components that are not Go modules and are therefore +invisible to `go-licenses`; they are maintained by hand in `dev/licenses-manual.md`. +Everything after them is generated from the module graph, with the corrections listed in +`dev/licenses-overrides.tsv` applied. + +Two components reach users under the GNU Lesser General Public License v3.0: go-ethereum, +statically linked into every binary, and the Cartesi Machine emulator, loaded at run time. +The LGPL-3.0 is written as a set of additional permissions on top of the GPL-3.0. Both texts +are in [licenses/LGPL-3.0.txt](licenses/LGPL-3.0.txt) and +[licenses/GPL-3.0.txt](licenses/GPL-3.0.txt). + +The emulator is a dynamic library in its own package. A recipient can replace it without a new +build of the node. go-ethereum is statically linked. The complete source of this project is in +this repository under Apache-2.0. To build the node against a different go-ethereum, add a +`replace` directive for `github.com/ethereum/go-ethereum` to `go.mod` and run `make build`. + +The Go bindings under `pkg/contracts/` are generated from the release artifacts of +cartesi/rollups-contracts and cartesi/dave, pinned and checksum-verified by the Makefile. Both +repositories are Apache-2.0. They are listed below for attribution. + +## github.com/cartesi/machine-emulator + +* Name: github.com/cartesi/machine-emulator +* Version: 0.21.0 +* License: [LGPL-3.0](https://github.com/cartesi/machine-emulator/blob/v0.21.0/COPYING) + +## github.com/cartesi/rollups-contracts + +* Name: github.com/cartesi/rollups-contracts +* Version: 3.0.0-alpha.10 +* License: [Apache-2.0](https://github.com/cartesi/rollups-contracts/blob/v3.0.0-alpha.10/LICENSE) +* Note: source of the generated contract bindings under pkg/contracts/. + +## github.com/cartesi/dave + +* Name: github.com/cartesi/dave +* Version: 3.0.0-alpha.5 +* License: [Apache-2.0](https://github.com/cartesi/dave/blob/v3.0.0-alpha.5/LICENSE) +* Note: source of the generated PRT contract bindings under pkg/contracts/. diff --git a/dev/licenses-overrides.tsv b/dev/licenses-overrides.tsv new file mode 100644 index 000000000..ee63bbdfc --- /dev/null +++ b/dev/licenses-overrides.tsv @@ -0,0 +1,17 @@ +# Corrections applied to the entries go-licenses derives from the module graph, +# re-applied on every regeneration: +# - go-licenses resolves a licence from the file at the module root, which is +# wrong for modules that licence parts of their tree differently; +# - it resolves the directory of a nested major version, such as /v2, with a +# network request, and without network access it picks the wrong one; +# - when a module directory has no licence file, the module zip carries the +# licence at the repository root, but go-licenses links the missing file; +# - it does not see the C code that a package compiles with cgo. +# +# Tab-separated: module name, licence name, licence URL, note. {version} in the URL +# and in the note is replaced with the resolved module version. The note is +# optional. The script fails when a line matches no entry. +github.com/aws/aws-sdk-go-v2/internal/endpoints/v2 Apache-2.0 https://github.com/aws/aws-sdk-go-v2/blob/internal/endpoints/{version}/internal/endpoints/v2/LICENSE.txt +github.com/decred/dcrd/dcrec/secp256k1/v4 ISC https://github.com/decred/dcrd/blob/dcrec/secp256k1/{version}/LICENSE +github.com/ethereum/go-ethereum LGPL-3.0 https://github.com/ethereum/go-ethereum/blob/{version}/COPYING.LESSER only the library packages are used, that is, everything outside cmd/, and those are LGPL-3.0. The GPL-3.0 COPYING file at the module root covers go-ethereum's own binaries, which this project does not build or distribute. +github.com/ethereum/go-ethereum/crypto/secp256k1 BSD-3-Clause https://github.com/ethereum/go-ethereum/blob/{version}/crypto/secp256k1/LICENSE built with cgo, this package also compiles the bundled libsecp256k1 C library, which is under the [MIT licence](https://github.com/ethereum/go-ethereum/blob/{version}/crypto/secp256k1/libsecp256k1/COPYING) diff --git a/dev/licenses.tpl b/dev/licenses.tpl index 7e383c4b3..0344e5786 100644 --- a/dev/licenses.tpl +++ b/dev/licenses.tpl @@ -1,4 +1,3 @@ -# Third Party Licenses {{ range . }} ## {{ .Name }} diff --git a/dev/tools.go b/dev/tools.go index 84a45da94..3b8dbeee4 100644 --- a/dev/tools.go +++ b/dev/tools.go @@ -6,7 +6,7 @@ package main import ( - _ "github.com/deepmap/oapi-codegen/v2/cmd/oapi-codegen" + _ "github.com/oapi-codegen/oapi-codegen/v2/cmd/oapi-codegen" // Import the Jet CLI tool for code generation _ "github.com/go-jet/jet/v2/cmd/jet" ) diff --git a/go.mod b/go.mod index ee3f893cf..2861ecbd6 100644 --- a/go.mod +++ b/go.mod @@ -1,77 +1,70 @@ module github.com/cartesi/rollups-node -go 1.26.3 +go 1.27.1 require ( - github.com/ethereum/go-ethereum v1.17.3 - github.com/spf13/cobra v1.10.2 - github.com/stretchr/testify v1.11.1 - github.com/tyler-smith/go-bip32 v1.0.0 - github.com/tyler-smith/go-bip39 v1.1.0 -) - -require github.com/BurntSushi/toml v1.6.0 - -require ( - github.com/aws/aws-sdk-go-v2 v1.41.12 - github.com/aws/aws-sdk-go-v2/config v1.32.23 - github.com/aws/aws-sdk-go-v2/service/kms v1.53.3 - github.com/deepmap/oapi-codegen/v2 v2.2.0 - github.com/go-jet/jet/v2 v2.15.0 - github.com/golang-migrate/migrate/v4 v4.19.1 + github.com/BurntSushi/toml v1.6.0 + github.com/aws/aws-sdk-go-v2 v1.47.1 + github.com/aws/aws-sdk-go-v2/config v1.33.6 + github.com/aws/aws-sdk-go-v2/service/kms v1.61.1 + github.com/ethereum/go-ethereum v1.17.7 + github.com/go-jet/jet/v2 v2.16.0 + github.com/golang-migrate/migrate/v4 v4.20.1 github.com/google/uuid v1.6.0 github.com/hashicorp/go-retryablehttp v0.7.8 github.com/holiman/uint256 v1.3.2 - github.com/jackc/pgx/v5 v5.10.0 - github.com/lmittmann/tint v1.1.3 - github.com/oapi-codegen/runtime v1.4.1 + github.com/jackc/pgx/v5 v5.11.0 + github.com/lmittmann/tint v1.2.0 + github.com/oapi-codegen/oapi-codegen/v2 v2.8.0 + github.com/oapi-codegen/runtime v1.7.0 + github.com/spf13/cobra v1.10.2 github.com/spf13/pflag v1.0.10 github.com/spf13/viper v1.21.0 - golang.org/x/sync v0.20.0 - golang.org/x/text v0.37.0 + github.com/stretchr/testify v1.12.1 + github.com/tyler-smith/go-bip39 v1.1.0 + golang.org/x/sync v0.23.0 + golang.org/x/text v0.42.0 ) require ( filippo.io/edwards25519 v1.2.0 // indirect - github.com/FactomProject/basen v0.0.0-20150613233007-fe3947df716e // indirect - github.com/FactomProject/btcutilecc v0.0.0-20130527213604-d3a63a5752ec // indirect github.com/Microsoft/go-winio v0.6.2 // indirect - github.com/ProjectZKM/Ziren/crates/go-runtime/zkvm_runtime v0.0.0-20260519063510-53a8eff4e716 // indirect + github.com/ProjectZKM/Ziren/crates/go-runtime/zkvm_runtime v0.0.0-20260930021100-1f4573542fc8 // indirect github.com/apapsch/go-jsonmerge/v2 v2.0.0 // indirect - github.com/aws/aws-sdk-go-v2/credentials v1.19.22 // indirect - github.com/aws/aws-sdk-go-v2/feature/ec2/imds v1.18.28 // indirect - github.com/aws/aws-sdk-go-v2/internal/configsources v1.4.28 // indirect - github.com/aws/aws-sdk-go-v2/internal/endpoints/v2 v2.7.28 // indirect - github.com/aws/aws-sdk-go-v2/internal/v4a v1.4.29 // indirect - github.com/aws/aws-sdk-go-v2/service/internal/accept-encoding v1.13.12 // indirect - github.com/aws/aws-sdk-go-v2/service/internal/presigned-url v1.13.28 // indirect - github.com/aws/aws-sdk-go-v2/service/signin v1.1.4 // indirect - github.com/aws/aws-sdk-go-v2/service/sso v1.31.2 // indirect - github.com/aws/aws-sdk-go-v2/service/ssooidc v1.36.5 // indirect - github.com/aws/aws-sdk-go-v2/service/sts v1.43.2 // indirect - github.com/aws/smithy-go v1.27.2 // indirect - github.com/bits-and-blooms/bitset v1.24.5 // indirect + github.com/aws/aws-sdk-go-v2/credentials v1.20.6 // indirect + github.com/aws/aws-sdk-go-v2/feature/ec2/imds v1.20.1 // indirect + github.com/aws/aws-sdk-go-v2/internal/configsources v1.5.4 // indirect + github.com/aws/aws-sdk-go-v2/internal/endpoints/v2 v2.8.4 // indirect + github.com/aws/aws-sdk-go-v2/internal/v4a v1.5.4 // indirect + github.com/aws/aws-sdk-go-v2/service/internal/accept-encoding v1.13.19 // indirect + github.com/aws/aws-sdk-go-v2/service/internal/presigned-url v1.14.4 // indirect + github.com/aws/aws-sdk-go-v2/service/signin v1.10.1 // indirect + github.com/aws/aws-sdk-go-v2/service/sso v1.38.1 // indirect + github.com/aws/aws-sdk-go-v2/service/ssooidc v1.43.1 // indirect + github.com/aws/aws-sdk-go-v2/service/sts v1.51.1 // indirect + github.com/aws/smithy-go v1.28.2 // indirect + github.com/bits-and-blooms/bitset v1.25.0 // indirect github.com/cespare/xxhash/v2 v2.3.0 // indirect - github.com/consensys/gnark-crypto v0.20.1 // indirect + github.com/consensys/gnark-crypto v0.21.0 // indirect github.com/cpuguy83/go-md2man/v2 v2.0.7 // indirect github.com/crate-crypto/go-eth-kzg v1.5.0 // indirect - github.com/davecgh/go-spew v1.1.2-0.20180830191138-d8f796af33cc // indirect github.com/deckarep/golang-set/v2 v2.9.0 // indirect github.com/decred/dcrd/dcrec/secp256k1/v4 v4.4.1 // indirect - github.com/ethereum/c-kzg-4844/v2 v2.1.7 // indirect + github.com/dprotaso/go-yit v0.0.0-20220510233725-9ba8df137936 // indirect + github.com/ethereum/c-kzg-4844/v2 v2.1.8 // indirect + github.com/fjl/jsonw v0.1.0 // indirect github.com/fsnotify/fsnotify v1.10.1 // indirect - github.com/getkin/kin-openapi v0.124.0 // indirect - github.com/go-logr/logr v1.4.3 // indirect + github.com/getkin/kin-openapi v0.142.0 // indirect + github.com/go-logr/logr v1.4.4 // indirect github.com/go-logr/stdr v1.2.2 // indirect github.com/go-ole/go-ole v1.3.0 // indirect - github.com/go-openapi/jsonpointer v0.21.0 // indirect - github.com/go-openapi/swag v0.23.0 // indirect + github.com/go-openapi/jsonpointer v0.23.1 // indirect + github.com/go-openapi/swag/jsonname v0.26.0 // indirect github.com/go-sql-driver/mysql v1.10.0 // indirect github.com/go-viper/mapstructure/v2 v2.5.0 // indirect github.com/gorilla/websocket v1.5.3 // indirect github.com/hashicorp/go-cleanhttp v0.5.2 // indirect github.com/inconshreveable/mousetrap v1.1.0 // indirect - github.com/invopop/yaml v0.2.0 // indirect github.com/jackc/chunkreader/v2 v2.0.1 // indirect github.com/jackc/pgconn v1.14.3 // indirect github.com/jackc/pgerrcode v0.0.0-20250907135507-afb5586c32a6 // indirect @@ -82,38 +75,37 @@ require ( github.com/jackc/pgtype v1.14.4 // indirect github.com/jackc/pgx/v4 v4.18.3 // indirect github.com/jackc/puddle/v2 v2.2.2 // indirect - github.com/josharian/intern v1.0.0 // indirect - github.com/klauspost/compress v1.17.9 // indirect github.com/lib/pq v1.12.3 // indirect - github.com/mailru/easyjson v0.7.7 // indirect - github.com/mattn/go-sqlite3 v1.14.44 // indirect + github.com/mattn/go-sqlite3 v1.14.50 // indirect github.com/mitchellh/mapstructure v1.5.0 // indirect - github.com/mohae/deepcopy v0.0.0-20170929034955-c48cc78d4826 // indirect - github.com/pelletier/go-toml/v2 v2.3.1 // indirect - github.com/perimeterx/marshmallow v1.1.5 // indirect - github.com/pmezard/go-difflib v1.0.1-0.20181226105442-5d4384ee4fb2 // indirect + github.com/oasdiff/yaml v0.1.1 // indirect + github.com/oasdiff/yaml3 v0.0.14 // indirect + github.com/pelletier/go-toml/v2 v2.4.3 // indirect github.com/russross/blackfriday/v2 v2.1.0 // indirect github.com/sagikazarmark/locafero v0.12.0 // indirect + github.com/santhosh-tekuri/jsonschema/v6 v6.0.2 // indirect github.com/shirou/gopsutil v3.21.11+incompatible // indirect + github.com/speakeasy-api/jsonpath v0.6.3 // indirect + github.com/speakeasy-api/openapi v1.24.0 // indirect github.com/spf13/afero v1.15.0 // indirect github.com/spf13/cast v1.10.0 // indirect - github.com/stretchr/objx v0.5.2 // indirect + github.com/stretchr/objx v0.5.3 // indirect github.com/subosito/gotenv v1.6.0 // indirect - github.com/supranational/blst v0.3.16 // indirect + github.com/supranational/blst v0.3.17 // indirect github.com/tklauser/go-sysconf v0.4.0 // indirect github.com/tklauser/numcpus v0.12.0 // indirect + github.com/vmware-labs/yaml-jsonpath v0.3.2 // indirect github.com/yusufpapurcu/wmi v1.2.4 // indirect - go.mongodb.org/mongo-driver v1.17.9 // indirect + go.mongodb.org/mongo-driver v1.17.10 // indirect go.opentelemetry.io/auto/sdk v1.2.1 // indirect - go.opentelemetry.io/otel v1.44.0 // indirect - go.opentelemetry.io/otel/metric v1.44.0 // indirect - go.opentelemetry.io/otel/trace v1.44.0 // indirect - go.yaml.in/yaml/v3 v3.0.4 // indirect - golang.org/x/crypto v0.52.0 // indirect + go.opentelemetry.io/otel v1.46.0 // indirect + go.opentelemetry.io/otel/metric v1.46.0 // indirect + go.opentelemetry.io/otel/trace v1.46.0 // indirect + go.yaml.in/yaml/v3 v3.0.5 // indirect + golang.org/x/crypto v0.57.0 // indirect golang.org/x/exp v0.0.0-20250305212735-054e65f0b394 // indirect - golang.org/x/mod v0.35.0 // indirect - golang.org/x/sys v0.45.0 // indirect - golang.org/x/tools v0.44.0 // indirect - gopkg.in/yaml.v2 v2.4.0 // indirect + golang.org/x/mod v0.41.0 // indirect + golang.org/x/sys v0.48.0 // indirect + golang.org/x/tools v0.49.0 // indirect gopkg.in/yaml.v3 v3.0.1 // indirect ) diff --git a/go.sum b/go.sum index a491659e0..046bcbaf1 100644 --- a/go.sum +++ b/go.sum @@ -1,70 +1,73 @@ filippo.io/edwards25519 v1.2.0 h1:crnVqOiS4jqYleHd9vaKZ+HKtHfllngJIiOpNpoJsjo= filippo.io/edwards25519 v1.2.0/go.mod h1:xzAOLCNug/yB62zG1bQ8uziwrIqIuxhctzJT18Q77mc= -github.com/Azure/go-ansiterm v0.0.0-20230124172434-306776ec8161 h1:L/gRVlceqvL25UVaW/CKtUDjefjrs0SPonmDGUVOYP0= -github.com/Azure/go-ansiterm v0.0.0-20230124172434-306776ec8161/go.mod h1:xomTg63KZ2rFqZQzSB4Vz2SUXa1BpHTVz9L5PTmPC4E= +github.com/Azure/go-ansiterm v0.0.0-20250102033503-faa5f7b0171c h1:udKWzYgxTojEKWjV8V+WSxDXJ4NFATAsZjh8iIbsQIg= +github.com/Azure/go-ansiterm v0.0.0-20250102033503-faa5f7b0171c/go.mod h1:xomTg63KZ2rFqZQzSB4Vz2SUXa1BpHTVz9L5PTmPC4E= github.com/BurntSushi/toml v0.3.1/go.mod h1:xHWCNGjB5oqiDr8zfno3MHue2Ht5sIBksp03qcyfWMU= github.com/BurntSushi/toml v1.6.0 h1:dRaEfpa2VI55EwlIW72hMRHdWouJeRF7TPYhI+AUQjk= github.com/BurntSushi/toml v1.6.0/go.mod h1:ukJfTF/6rtPPRCnwkur4qwRxa8vTRFBF0uk2lLoLwho= -github.com/DataDog/zstd v1.4.5 h1:EndNeuB0l9syBZhut0wns3gV1hL8zX8LIu6ZiVHWLIQ= -github.com/DataDog/zstd v1.4.5/go.mod h1:1jcaCB/ufaK+sKp1NBhlGmpz41jOoPQ35bpF36t7BBo= -github.com/FactomProject/basen v0.0.0-20150613233007-fe3947df716e h1:ahyvB3q25YnZWly5Gq1ekg6jcmWaGj/vG/MhF4aisoc= -github.com/FactomProject/basen v0.0.0-20150613233007-fe3947df716e/go.mod h1:kGUqhHd//musdITWjFvNTHn90WG9bMLBEPQZ17Cmlpw= -github.com/FactomProject/btcutilecc v0.0.0-20130527213604-d3a63a5752ec h1:1Qb69mGp/UtRPn422BH4/Y4Q3SLUrD9KHuDkm8iodFc= -github.com/FactomProject/btcutilecc v0.0.0-20130527213604-d3a63a5752ec/go.mod h1:CD8UlnlLDiqb36L110uqiP2iSflVjx9g/3U9hCI4q2U= +github.com/DataDog/zstd v1.5.7 h1:ybO8RBeh29qrxIhCA9E8gKY6xfONU9T6G6aP9DTKfLE= +github.com/DataDog/zstd v1.5.7/go.mod h1:g4AWEaM3yOg3HYfnJ3YIawPnVdXJh9QME85blwSAmyw= github.com/Masterminds/semver/v3 v3.1.1 h1:hLg3sBzpNErnxhQtUy/mmLR2I9foDujNK030IGemrRc= github.com/Masterminds/semver/v3 v3.1.1/go.mod h1:VPu/7SZ7ePZ3QOrcuXROw5FAcLl4a0cBrbBpGY/8hQs= github.com/Microsoft/go-winio v0.6.2 h1:F2VQgta7ecxGYO8k3ZZz3RS8fVIXVxONVUPlNERoyfY= github.com/Microsoft/go-winio v0.6.2/go.mod h1:yd8OoFMLzJbo9gZq8j5qaps8bJ9aShtEA8Ipt1oGCvU= -github.com/ProjectZKM/Ziren/crates/go-runtime/zkvm_runtime v0.0.0-20260519063510-53a8eff4e716 h1:/6T7wq3q2pv8PG6BV1d2kSYNSQGrjUwdt9U0colET+A= -github.com/ProjectZKM/Ziren/crates/go-runtime/zkvm_runtime v0.0.0-20260519063510-53a8eff4e716/go.mod h1:ioLG6R+5bUSO1oeGSDxOV3FADARuMoytZCSX6MEMQkI= +github.com/ProjectZKM/Ziren/crates/go-runtime/zkvm_runtime v0.0.0-20260930021100-1f4573542fc8 h1:7wsDnPWRSDAvK2mUSBH8O5+3e2sMa/joQ8UJR7jcVMs= +github.com/ProjectZKM/Ziren/crates/go-runtime/zkvm_runtime v0.0.0-20260930021100-1f4573542fc8/go.mod h1:uO5tzF6zbEbGmzjjDjqrYuAdGqqGJYYYSGijnBePEeg= +github.com/RaduBerinde/axisds v0.1.0 h1:YItk/RmU5nvlsv/awo2Fjx97Mfpt4JfgtEVAGPrLdz8= +github.com/RaduBerinde/axisds v0.1.0/go.mod h1:UHGJonU9z4YYGKJxSaC6/TNcLOBptpmM5m2Cksbnw0Y= +github.com/RaduBerinde/btreemap v0.0.0-20250419174037-3d62b7205d54 h1:bsU8Tzxr/PNz75ayvCnxKZWEYdLMPDkUgticP4a4Bvk= +github.com/RaduBerinde/btreemap v0.0.0-20250419174037-3d62b7205d54/go.mod h1:0tr7FllbE9gJkHq7CVeeDDFAFKQVy5RnCSSNBOvdqbc= github.com/RaveNoX/go-jsoncommentstrip v1.0.0/go.mod h1:78ihd09MekBnJnxpICcwzCMzGrKSKYe4AqU6PDYYpjk= github.com/VictoriaMetrics/fastcache v1.13.0 h1:AW4mheMR5Vd9FkAPUv+NH6Nhw+fmbTMGMsNAoA/+4G0= github.com/VictoriaMetrics/fastcache v1.13.0/go.mod h1:hHXhl4DA2fTL2HTZDJFXWgW0LNjo6B+4aj2Wmng3TjU= github.com/apapsch/go-jsonmerge/v2 v2.0.0 h1:axGnT1gRIfimI7gJifB699GoE/oq+F2MU7Dml6nw9rQ= github.com/apapsch/go-jsonmerge/v2 v2.0.0/go.mod h1:lvDnEdqiQrp0O42VQGgmlKpxL1AP2+08jFMw88y4klk= -github.com/aws/aws-sdk-go-v2 v1.41.12 h1:DIKX2c31ekm9RA2D9FBj1EWXx++9AdAqRw+e78Tq2Ck= -github.com/aws/aws-sdk-go-v2 v1.41.12/go.mod h1:27+ACypSLljLAEKsCYOmrjKh83vuTRkuAe9Uv/3A4bg= -github.com/aws/aws-sdk-go-v2/config v1.32.23 h1:PYDobtcsJXK6bQe9I8RQk6s19Bz3xa3xRU08Hy1Em3Y= -github.com/aws/aws-sdk-go-v2/config v1.32.23/go.mod h1:QID4dqUQVgEOYPKsPWd1sNWCCR2c5g7o3jeEtIXPOZU= -github.com/aws/aws-sdk-go-v2/credentials v1.19.22 h1:SHfH6wyPsEgG7fVsi5rQxWEt7tuIcN2PGhb1mTFv6tE= -github.com/aws/aws-sdk-go-v2/credentials v1.19.22/go.mod h1:54nO8lKD4aQPOntM/VTWjnR+DYzTwx0YkSMZMhAgewQ= -github.com/aws/aws-sdk-go-v2/feature/ec2/imds v1.18.28 h1:b+kcDejJrXc30zU/w8Tc9klISwaO5wh+6T0sMBdDoHM= -github.com/aws/aws-sdk-go-v2/feature/ec2/imds v1.18.28/go.mod h1:LnI62O9GnSv6GcuLXxOYqlq0C8EmxMcgnF6m7LdYuOY= -github.com/aws/aws-sdk-go-v2/internal/configsources v1.4.28 h1:Xf2j7NdVcUKomlZ4iihOP4AZ3Fzlr8h4yKpXeP+OFPg= -github.com/aws/aws-sdk-go-v2/internal/configsources v1.4.28/go.mod h1:O8cDo1dW63jU7ki//kRe1z+tLGcpnD1jrouitsQddDw= -github.com/aws/aws-sdk-go-v2/internal/endpoints/v2 v2.7.28 h1:KqIfN9kpkKkcBqBbNpNGTIrXO6ExTUvFKvXkC+YAzVo= -github.com/aws/aws-sdk-go-v2/internal/endpoints/v2 v2.7.28/go.mod h1:uxtQiKvLtNS4iXVsH2McVD/ls8FKN/uUhe1hGxPjrw0= -github.com/aws/aws-sdk-go-v2/internal/v4a v1.4.29 h1:VkE9FuzTQVjBBrnj4+oCdxCLFIz7aqLYKUCjtvxVcOs= -github.com/aws/aws-sdk-go-v2/internal/v4a v1.4.29/go.mod h1:H32Z2Qth9b+9LqjyBsCnozMQ8H2N7YBUDVXwbs0iggg= -github.com/aws/aws-sdk-go-v2/service/internal/accept-encoding v1.13.12 h1:ZD2+BSw9vFsNlKYIasSNt3uDbjqqXIBcM13UJv/Lx2k= -github.com/aws/aws-sdk-go-v2/service/internal/accept-encoding v1.13.12/go.mod h1:Ms4zlcVBbXbiP7EVLhl+lgjvA/a7YphqQ3Ih3174EmI= -github.com/aws/aws-sdk-go-v2/service/internal/presigned-url v1.13.28 h1:axj4mEDletwKmTm/9jR+DkIMmCfcn5vE4jBMAAN+3Vg= -github.com/aws/aws-sdk-go-v2/service/internal/presigned-url v1.13.28/go.mod h1:3Aaz69M0jqfSHLKqxgolgUBFT4hpwSNc7DzC95orEi8= -github.com/aws/aws-sdk-go-v2/service/kms v1.53.3 h1:X0Kb55BNFOpaRHBQWnUIQCs6+4kixloGDYppaq0BO2s= -github.com/aws/aws-sdk-go-v2/service/kms v1.53.3/go.mod h1:tlJhRqwP49jatVF/KivCKd139NAnn6KTvRjHIBN7E5Y= -github.com/aws/aws-sdk-go-v2/service/signin v1.1.4 h1:YcpVyIPLCbiypN6KSphijN5fC7DDjX114SqA7prnnxg= -github.com/aws/aws-sdk-go-v2/service/signin v1.1.4/go.mod h1:5ZICS++oFTRPfa1GsBqFDWX/8WamZ/QQOcCzIuU/zLw= -github.com/aws/aws-sdk-go-v2/service/sso v1.31.2 h1:ySNWu7TPmj5fKFIa1GYvX+Ddxd5ccruqC20aMNuyWDM= -github.com/aws/aws-sdk-go-v2/service/sso v1.31.2/go.mod h1:A+U9luAOwFeB1kseyWCITVg7/NntoPebCFR9pQ4ch9A= -github.com/aws/aws-sdk-go-v2/service/ssooidc v1.36.5 h1:KSzGGqfk39O+WU3OEyYbx6F7sLDQCqxlOJ+2IksfK6U= -github.com/aws/aws-sdk-go-v2/service/ssooidc v1.36.5/go.mod h1:ATs88lXDeQB6CZOgQ5BIl9JbYS+EsCWUSDyff6L/oVo= -github.com/aws/aws-sdk-go-v2/service/sts v1.43.2 h1:RTO7mmGyedgnNmcPh3yQizNfc6GKoV5iqfdJavuf9vw= -github.com/aws/aws-sdk-go-v2/service/sts v1.43.2/go.mod h1:fBhUZXDin9YYqhcpOMjIcpdik25rVwWyxLdPH1RZd9s= -github.com/aws/smithy-go v1.27.2 h1:y9NPmSE6am6LjEFPfqHqG/jJk7AauQvhCJONKh7kpzk= -github.com/aws/smithy-go v1.27.2/go.mod h1:YE2RhdIuDbA5E5bTdciG9KrW3+TiEONeUWCqxX9i1Fc= +github.com/aws/aws-sdk-go-v2 v1.47.1 h1:uOIZnp4PK3ZhKI0dNrJrhTEsLxbpXHTAJlwoS1pvAtw= +github.com/aws/aws-sdk-go-v2 v1.47.1/go.mod h1:bttEH6JqnUL8LepvDVfdrds/fZ5bCIxzpe3abyUrhDU= +github.com/aws/aws-sdk-go-v2/config v1.33.6 h1:MBjkSTLczek/UgiK+EYPIoRTqE7gP8vtW3OFbFo7Nug= +github.com/aws/aws-sdk-go-v2/config v1.33.6/go.mod h1:grRAFzdAZJrwcbasJRg2MPvIrVjtlfXllHssN6+E1JE= +github.com/aws/aws-sdk-go-v2/credentials v1.20.6 h1:NpAFXCU7NzXNkdGK3zQTtsRJ+3v9tZQV0xcdRw8uBdw= +github.com/aws/aws-sdk-go-v2/credentials v1.20.6/go.mod h1:mcZCoiPnyMvP8VMNbygNX5lLqSlkYJIMPODylQMurOk= +github.com/aws/aws-sdk-go-v2/feature/ec2/imds v1.20.1 h1:8gALAAmacnIXh+z6VkdDanv4/IkG5APdg4DZLDTmLog= +github.com/aws/aws-sdk-go-v2/feature/ec2/imds v1.20.1/go.mod h1:Z7IJhJU+poOdJjUR2wpyY21ossQ1XS/R3Lk9Msq5kM4= +github.com/aws/aws-sdk-go-v2/internal/configsources v1.5.4 h1:CLq4+8UHCI+ZZYl/EuJxXovaIVN2xeeT8JV+dsApQ5E= +github.com/aws/aws-sdk-go-v2/internal/configsources v1.5.4/go.mod h1:Wv4q5sAM04xAMkoOedxLx2inVf6K5FdxYp+A61L+q/0= +github.com/aws/aws-sdk-go-v2/internal/endpoints/v2 v2.8.4 h1:dD4MR81I7YkpEBRk6UP9rocC2QnT3qVuXwzlYTtfGEs= +github.com/aws/aws-sdk-go-v2/internal/endpoints/v2 v2.8.4/go.mod h1:EcXV1kAFd5XwSkDHlj94gnF3q5CkJyYiIJfH8N0VmrE= +github.com/aws/aws-sdk-go-v2/internal/v4a v1.5.4 h1:7Wo47d/xn/7KttCSBd8EGYeZ7ULRFRkUHr6vkZPBzVQ= +github.com/aws/aws-sdk-go-v2/internal/v4a v1.5.4/go.mod h1:tDB2IVC1xC3vX8o+6uRlzhTxP3g1b77CZXFX/oD2FnQ= +github.com/aws/aws-sdk-go-v2/service/internal/accept-encoding v1.13.19 h1:bAdDl/HkGCcGPoe25ToSHEw23VIxt6CT5fLcg111BKg= +github.com/aws/aws-sdk-go-v2/service/internal/accept-encoding v1.13.19/go.mod h1:KaUzbLxv4CeSxh6ZCl9B4m7CuFenS8kUEaDs+f/DQr4= +github.com/aws/aws-sdk-go-v2/service/internal/presigned-url v1.14.4 h1:29SvnfGhXjTl8ONxFwbj2rs6lbhiFXD2CgFQmbT/bXY= +github.com/aws/aws-sdk-go-v2/service/internal/presigned-url v1.14.4/go.mod h1:wm04I5DMuNVvZHFe/dHnUxincvNbbK7AiNBbYsQivek= +github.com/aws/aws-sdk-go-v2/service/kms v1.61.1 h1:BNBCE5IGMCehEPpSbPqhdyV4ZS9Y1Yr9NuvR9itr7aE= +github.com/aws/aws-sdk-go-v2/service/kms v1.61.1/go.mod h1:XBCtQL8tXGOCYe8ExoWRURhDQ5QnfyWbP9px5DNsuog= +github.com/aws/aws-sdk-go-v2/service/signin v1.10.1 h1:DzCCWLzcIRQ77F3DEUljud7bEjTgFOIKXP52NmVRyhU= +github.com/aws/aws-sdk-go-v2/service/signin v1.10.1/go.mod h1:xpo/geVldu8payT375WekctUzopG/hBU7miiqItMUlw= +github.com/aws/aws-sdk-go-v2/service/sso v1.38.1 h1:Umtl/0YZhng4xndfW3lKJrYYP7NLEjI6bGXVomwLcs0= +github.com/aws/aws-sdk-go-v2/service/sso v1.38.1/go.mod h1:rRD/dnm7q0HYE/I5TMaPgkWyyUGLcwuxHLABsLnQ3e0= +github.com/aws/aws-sdk-go-v2/service/ssooidc v1.43.1 h1:orIWdNiLgzrhu/11RcPPKO/SBzUUymbUQuZbSPImghg= +github.com/aws/aws-sdk-go-v2/service/ssooidc v1.43.1/go.mod h1:skwM/xsbR/1ReUTesv9BhpJp1VjajR7DWQnuVLwiXsQ= +github.com/aws/aws-sdk-go-v2/service/sts v1.51.1 h1:0HOqZXRvMytH6bFHVIc0oJX07sZjfhz0zXtjs6gdE8s= +github.com/aws/aws-sdk-go-v2/service/sts v1.51.1/go.mod h1:26zA0GhDrLo+yiLI2yXWxqB1PdsShfLikoI7GOEgugM= +github.com/aws/smithy-go v1.28.2 h1:myhcykQcatTul2B/zITjDk203G7t0awUAs1hVry5Bvg= +github.com/aws/smithy-go v1.28.2/go.mod h1:YE2RhdIuDbA5E5bTdciG9KrW3+TiEONeUWCqxX9i1Fc= github.com/beorn7/perks v1.0.1 h1:VlbKKnNfV8bJzeqoa4cOKqO6bYr3WgKZxO8Z16+hsOM= github.com/beorn7/perks v1.0.1/go.mod h1:G2ZrVWU2WbWT9wwq4/hrbKbnv/1ERSJQ0ibhJ6rlkpw= -github.com/bits-and-blooms/bitset v1.24.5 h1:654xBVHc23gJMAgOTkPNoCVfiRxuIOAUnAZFtopqJ4w= -github.com/bits-and-blooms/bitset v1.24.5/go.mod h1:7hO7Gc7Pp1vODcmWvKMRA9BNmbv6a/7QIWpPxHddWR8= +github.com/bits-and-blooms/bitset v1.25.0 h1:0Ro0qF4abCkM6SqWPVj29sFhAbMPAZpaDD7xhJ10beM= +github.com/bits-and-blooms/bitset v1.25.0/go.mod h1:7hO7Gc7Pp1vODcmWvKMRA9BNmbv6a/7QIWpPxHddWR8= github.com/bmatcuk/doublestar v1.1.1/go.mod h1:UD6OnuiIn0yFxxA2le/rnRU1G4RaI4UvFv1sNto9p6w= github.com/cespare/cp v0.1.0 h1:SE+dxFebS7Iik5LK0tsi1k9ZCxEaFX4AjQmoyA+1dJk= github.com/cespare/cp v0.1.0/go.mod h1:SOGHArjBr4JWaSDEVpWpo/hNg6RoKrls6Oh40hiwW+s= github.com/cespare/xxhash/v2 v2.3.0 h1:UL815xU9SqsFlibzuggzjXhog7bL6oX9BbNZnL2UFvs= github.com/cespare/xxhash/v2 v2.3.0/go.mod h1:VGX0DQ3Q6kWi7AoAeZDth3/j3BFtOZR5XLFGgcrjCOs= -github.com/cmars/basen v0.0.0-20150613233007-fe3947df716e h1:0XBUw73chJ1VYSsfvcPvVT7auykAJce9FpRr10L6Qhw= -github.com/cmars/basen v0.0.0-20150613233007-fe3947df716e/go.mod h1:P13beTBKr5Q18lJe1rIoLUqjM+CB1zYrRg44ZqGuQSA= +github.com/chzyer/logex v1.1.10/go.mod h1:+Ywpsq7O8HXn0nuIou7OrIPyXbp3wmkHB+jjWRnGsAI= +github.com/chzyer/readline v0.0.0-20180603132655-2972be24d48e/go.mod h1:nSuG5e5PlCu98SY8svDHJxuZscDgtXS6KTTbou5AhLI= +github.com/chzyer/test v0.0.0-20180213035817-a1ea475d72b1/go.mod h1:Q3SI9o4m/ZMnBNeIyt5eFwwo7qiLfzFZmjNmxjkiQlU= github.com/cockroachdb/apd v1.1.0 h1:3LFP3629v+1aKXU5Q37mxmRxX/pIu1nijXydLShEq5I= github.com/cockroachdb/apd v1.1.0/go.mod h1:8Sl8LxpKi29FqWXR16WEFZRNSz3SoPzUzeMeY4+DwBQ= +github.com/cockroachdb/crlib v0.0.0-20241112164430-1264a2edc35b h1:SHlYZ/bMx7frnmeqCu+xm0TCxXLzX3jQIVuFbnFGtFU= +github.com/cockroachdb/crlib v0.0.0-20241112164430-1264a2edc35b/go.mod h1:Gq51ZeKaFCXk6QwuGM0w1dnaOqc/F5zKT2zA9D6Xeac= github.com/cockroachdb/errors v1.11.3 h1:5bA+k2Y6r+oz/6Z/RFlNeVCesGARKuC6YymtcDrbC/I= github.com/cockroachdb/errors v1.11.3/go.mod h1:m4UIW4CDjx+R5cybPsNrRbreomiFqt8o1h1wUVazSd8= github.com/cockroachdb/fifo v0.0.0-20240606204812-0bbfbd93a7ce h1:giXvy4KSc/6g/esnpM7Geqxka4WSqI1SZc7sMJFd3y4= @@ -73,12 +76,16 @@ github.com/cockroachdb/logtags v0.0.0-20230118201751-21c54148d20b h1:r6VH0faHjZe github.com/cockroachdb/logtags v0.0.0-20230118201751-21c54148d20b/go.mod h1:Vz9DsVWQQhf3vs21MhPMZpMGSht7O/2vFW2xusFUVOs= github.com/cockroachdb/pebble v1.1.5 h1:5AAWCBWbat0uE0blr8qzufZP5tBjkRyy/jWe1QWLnvw= github.com/cockroachdb/pebble v1.1.5/go.mod h1:17wO9el1YEigxkP/YtV8NtCivQDgoCyBg5c4VR/eOWo= +github.com/cockroachdb/pebble/v2 v2.1.4 h1:j9wPgMDbkErFdAKYFGhsoCcvzcjR+6zrJ4jhKtJ6bOk= +github.com/cockroachdb/pebble/v2 v2.1.4/go.mod h1:Reo1RTniv1UjVTAu/Fv74y5i3kJ5gmVrPhO9UtFiKn8= github.com/cockroachdb/redact v1.1.5 h1:u1PMllDkdFfPWaNGMyLD1+so+aq3uUItthCFqzwPJ30= github.com/cockroachdb/redact v1.1.5/go.mod h1:BVNblN9mBWFyMyqK1k3AAiSxhvhfK2oOZZ2lK+dpvRg= +github.com/cockroachdb/swiss v0.0.0-20260820225851-333444432258 h1:IJ+uNItEm0qx9FE2AgIc1PMsCUtk8nbSIzhQE1t5GWw= +github.com/cockroachdb/swiss v0.0.0-20260820225851-333444432258/go.mod h1:yBRu/cnL4ks9bgy4vAASdjIW+/xMlFwuHKqtmh3GZQg= github.com/cockroachdb/tokenbucket v0.0.0-20230807174530-cc333fc44b06 h1:zuQyyAKVxetITBuuhv3BI9cMrmStnpT18zmgmTxunpo= github.com/cockroachdb/tokenbucket v0.0.0-20230807174530-cc333fc44b06/go.mod h1:7nc4anLGjupUW/PeY5qiNYsdNXj7zopG+eqsS7To5IQ= -github.com/consensys/gnark-crypto v0.20.1 h1:PXDUBvk8AzhvWowHLWBEAfUQcV1/aZgWIqD6eMpXmDg= -github.com/consensys/gnark-crypto v0.20.1/go.mod h1:RBWrSgy+IDbGR69RRV313th3M/aZU1ubk2om+qHuTSc= +github.com/consensys/gnark-crypto v0.21.0 h1:FDHibVIk4T5LkOKAkiN38g8gEvOxNcM10mLHOqvFTD0= +github.com/consensys/gnark-crypto v0.21.0/go.mod h1:hdTjDNjdkYJ1oVuc8emh9XEhfM1SbyZhJigFqItiOLk= github.com/containerd/errdefs v1.0.0 h1:tg5yIfIlQIrxYtu9ajqY42W3lpS19XqdxRQeEwYG8PI= github.com/containerd/errdefs v1.0.0/go.mod h1:+YBYIdtsnF4Iw6nWZhJcqGSg/dwvV7tyJ/kCkyJ2k+M= github.com/containerd/errdefs/pkg v0.3.0 h1:9IKJ06FvyNlexW690DXuQNx2KA2cUJXx151Xdx3ZPPE= @@ -105,63 +112,71 @@ github.com/decred/dcrd/dcrec/secp256k1/v4 v4.4.1 h1:5RVFMOWjMyRy8cARdy79nAmgYw3h github.com/decred/dcrd/dcrec/secp256k1/v4 v4.4.1/go.mod h1:ZXNYxsqcloTdSy/rNShjYzMhyjf0LaoftYK0p+A3h40= github.com/deepmap/oapi-codegen v1.6.0 h1:w/d1ntwh91XI0b/8ja7+u5SvA4IFfM0UNNLmiDR1gg0= github.com/deepmap/oapi-codegen v1.6.0/go.mod h1:ryDa9AgbELGeB+YEXE1dR53yAjHwFvE9iAUlWl9Al3M= -github.com/deepmap/oapi-codegen/v2 v2.2.0 h1:FW4f7C0Xb6EaezBSB3GYw2QGwHD5ChDflG+3xSZBdvY= -github.com/deepmap/oapi-codegen/v2 v2.2.0/go.mod h1:L4zUv7ULYDtYSb/aYk/xO3OYcQU6BoU/0viULkbi2DE= github.com/dhui/dktest v0.4.6 h1:+DPKyScKSEp3VLtbMDHcUq6V5Lm5zfZZVb0Sk7Ahom4= github.com/dhui/dktest v0.4.6/go.mod h1:JHTSYDtKkvFNFHJKqCzVzqXecyv+tKt8EzceOmQOgbU= github.com/distribution/reference v0.6.0 h1:0IXCQ5g4/QMHHkarYzh5l+u8T3t73zM5QvfrDyIgxBk= github.com/distribution/reference v0.6.0/go.mod h1:BbU0aIcezP1/5jX/8MP0YiH4SdvB5Y4f/wlDRiLyi3E= -github.com/docker/docker v28.3.3+incompatible h1:Dypm25kh4rmk49v1eiVbsAtpAsYURjYkaKubwuBdxEI= -github.com/docker/docker v28.3.3+incompatible/go.mod h1:eEKB0N0r5NX/I1kEveEz05bcu8tLC/8azJZsviup8Sk= -github.com/docker/go-connections v0.5.0 h1:USnMq7hx7gwdVZq1L49hLXaFtUdTADjXGp+uj1Br63c= -github.com/docker/go-connections v0.5.0/go.mod h1:ov60Kzw0kKElRwhNs9UlUHAE/F9Fe6GLaXnqyDdmEXc= +github.com/dlclark/regexp2 v1.11.4 h1:rPYF9/LECdNymJufQKmri9gV604RvvABwgOA8un7yAo= +github.com/dlclark/regexp2 v1.11.4/go.mod h1:DHkYz0B9wPfa6wondMfaivmHpzrQ3v9q8cnmRbL6yW8= +github.com/docker/docker v28.5.2+incompatible h1:DBX0Y0zAjZbSrm1uzOkdr1onVghKaftjlSWt4AFexzM= +github.com/docker/docker v28.5.2+incompatible/go.mod h1:eEKB0N0r5NX/I1kEveEz05bcu8tLC/8azJZsviup8Sk= +github.com/docker/go-connections v0.7.0 h1:6SsRfJddP22WMrCkj19x9WKjEDTB+ahsdiGYf0mN39c= +github.com/docker/go-connections v0.7.0/go.mod h1:no1qkHdjq7kLMGUXYAduOhYPSJxxvgWBh7ogVvptn3Q= github.com/docker/go-units v0.5.0 h1:69rxXcBk27SvSaaxTtLh/8llcHD8vYHT7WSdRZ/jvr4= github.com/docker/go-units v0.5.0/go.mod h1:fgPhTUdO+D/Jk86RDLlptpiXQzgHJF7gydDDbaIK4Dk= +github.com/dprotaso/go-yit v0.0.0-20191028211022-135eb7262960/go.mod h1:9HQzr9D/0PGwMEbC3d5AB7oi67+h4TsQqItC1GVYG58= +github.com/dprotaso/go-yit v0.0.0-20220510233725-9ba8df137936 h1:PRxIJD8XjimM5aTknUK9w6DHLDox2r2M3DI4i2pnd3w= +github.com/dprotaso/go-yit v0.0.0-20220510233725-9ba8df137936/go.mod h1:ttYvX5qlB+mlV1okblJqcSMtR4c52UKxDiX9GRBS8+Q= github.com/emicklei/dot v1.6.2 h1:08GN+DD79cy/tzN6uLCT84+2Wk9u+wvqP+Hkx/dIR8A= github.com/emicklei/dot v1.6.2/go.mod h1:DeV7GvQtIw4h2u73RKBkkFdvVAz0D9fzeJrgPW6gy/s= -github.com/ethereum/c-kzg-4844/v2 v2.1.7 h1:aat3CuITdDbPC6pmEGRT0zJ5eOxzrZj8TJT5z7Xk//M= -github.com/ethereum/c-kzg-4844/v2 v2.1.7/go.mod h1:8HMkUZ5JRv4hpw/XUrYWSQNAUzhHMg2UDb/U+5m+XNw= +github.com/ethereum/c-kzg-4844/v2 v2.1.8 h1:oQ48q/TMe2SKU8qBE3N7e4/HlG3EpJftom6EsPQgJ58= +github.com/ethereum/c-kzg-4844/v2 v2.1.8/go.mod h1:8HMkUZ5JRv4hpw/XUrYWSQNAUzhHMg2UDb/U+5m+XNw= github.com/ethereum/go-bigmodexpfix v0.0.0-20250911101455-f9e208c548ab h1:rvv6MJhy07IMfEKuARQ9TKojGqLVNxQajaXEp/BoqSk= github.com/ethereum/go-bigmodexpfix v0.0.0-20250911101455-f9e208c548ab/go.mod h1:IuLm4IsPipXKF7CW5Lzf68PIbZ5yl7FFd74l/E0o9A8= -github.com/ethereum/go-ethereum v1.17.3 h1:Ev/sQHH+UdKZHWjuVzhu2pxhi/sXaPZl23Q+Q5LDd4Q= -github.com/ethereum/go-ethereum v1.17.3/go.mod h1:f2EhRwqewIZkGoQekywI2Y2RZAMTSavLNkD9qItFy1A= +github.com/ethereum/go-ethereum v1.17.7 h1:jhoGxw/5aYPYUwEIfzfog0RcsiJuLA6SSqsHdhkx1tA= +github.com/ethereum/go-ethereum v1.17.7/go.mod h1:nl9wZjMuIjAottU6bq82UihXPbyY0jHHwkYXhnYhmU4= github.com/fatih/color v1.16.0 h1:zmkK9Ngbjj+K0yRhTVONQh1p/HknKYSlNT+vZCzyokM= github.com/fatih/color v1.16.0/go.mod h1:fL2Sau1YI5c0pdGEVCbKQbLXB6edEj1ZgiY4NijnWvE= -github.com/felixge/httpsnoop v1.0.4 h1:NFTV2Zj1bL4mc9sqWACXbQFVBBg2W3GPvqp8/ESS2Wg= -github.com/felixge/httpsnoop v1.0.4/go.mod h1:m8KPJKqk1gH5J9DgRY2ASl2lWCfGKXixSwevea8zH2U= +github.com/felixge/httpsnoop v1.1.0 h1:3YtUj32ZZkqZtt3sZZsClsymw/QDuVfpNhoA31zeORc= +github.com/felixge/httpsnoop v1.1.0/go.mod h1:Zqxgdd+1Rkcz8euOqdr7lqgCRJztwr5hp9vDSi5UZCE= github.com/ferranbt/fastssz v0.1.4 h1:OCDB+dYDEQDvAgtAGnTSidK1Pe2tW3nFV40XyMkTeDY= github.com/ferranbt/fastssz v0.1.4/go.mod h1:Ea3+oeoRGGLGm5shYAeDgu6PGUlcvQhE2fILyD9+tGg= +github.com/fjl/jsonw v0.1.0 h1:V3MyR79fjLpn/+bMgvegdGUIhoJOzjmqWcKDgcOmY1I= +github.com/fjl/jsonw v0.1.0/go.mod h1:2KMLevM6FXEJnfhtk7naXu9vZdVfOma1GlnGdPRlumU= github.com/frankban/quicktest v1.14.6 h1:7Xjx+VpznH+oBnejlPUj8oUpdxnVs4f8XU8WnHkI4W8= github.com/frankban/quicktest v1.14.6/go.mod h1:4ptaffx2x8+WTWXmUCuVU6aPUX1/Mz7zb5vbUoiM6w0= +github.com/fsnotify/fsnotify v1.4.7/go.mod h1:jwhsz4b93w/PPRr/qN1Yymfu8t87LnFCMoQvtojpjFo= +github.com/fsnotify/fsnotify v1.4.9/go.mod h1:znqG4EE+3YCdAaPaxE2ZRY/06pZUdp0tY4IgpuI1SZQ= github.com/fsnotify/fsnotify v1.10.1 h1:b0/UzAf9yR5rhf3RPm9gf3ehBPpf0oZKIjtpKrx59Ho= github.com/fsnotify/fsnotify v1.10.1/go.mod h1:TLheqan6HD6GBK6PrDWyDPBaEV8LspOxvPSjC+bVfgo= github.com/gballet/go-libpcsclite v0.0.0-20190607065134-2772fd86a8ff h1:tY80oXqGNY4FhTFhk+o9oFHGINQ/+vhlm8HFzi6znCI= github.com/gballet/go-libpcsclite v0.0.0-20190607065134-2772fd86a8ff/go.mod h1:x7DCsMOv1taUwEWCzT4cmDeAkigA5/QCwUodaVOe8Ww= -github.com/getkin/kin-openapi v0.124.0 h1:VSFNMB9C9rTKBnQ/fpyDU8ytMTr4dWI9QovSKj9kz/M= -github.com/getkin/kin-openapi v0.124.0/go.mod h1:wb1aSZA/iWmorQP9KTAS/phLj/t17B5jT7+fS8ed9NM= +github.com/getkin/kin-openapi v0.142.0 h1:izj0vBdFprMhitfzaX8sTqztsEQyvwhssBoB6n8NO7w= +github.com/getkin/kin-openapi v0.142.0/go.mod h1:3BH9M9XDe/y9M5DSvEocVYAYq1w0qrhJHjC/vZi0AaY= github.com/getsentry/sentry-go v0.27.0 h1:Pv98CIbtB3LkMWmXi4Joa5OOcwbmnX88sF5qbK3r3Ps= github.com/getsentry/sentry-go v0.27.0/go.mod h1:lc76E2QywIyW8WuBnwl8Lc4bkmQH4+w1gwTf25trprY= -github.com/go-jet/jet/v2 v2.15.0 h1:IXfRJaFSWVPL8y2fnJAtwGumQhyr+T0hpBn3GOiayqw= -github.com/go-jet/jet/v2 v2.15.0/go.mod h1:+WUK1HdnzxYLpwYO24SjHGRSlD04+PFPG/GRMLiT24M= +github.com/go-jet/jet/v2 v2.16.0 h1:R6gpEPAVVvpSBaU4wM2bnR+j5hT6lqYgfrdfzr+NPm8= +github.com/go-jet/jet/v2 v2.16.0/go.mod h1:MILY2HK89zo7ODycULCCWLnwNklbMJkw4L5notrLpIA= github.com/go-kit/log v0.1.0/go.mod h1:zbhenjAZHb184qTLMA9ZjW7ThYL0H2mk7Q6pNt4vbaY= github.com/go-logfmt/logfmt v0.5.0/go.mod h1:wCYkCAKZfumFQihp8CzCvQ3paCTfi41vtzG1KdI/P7A= github.com/go-logr/logr v1.2.2/go.mod h1:jdQByPbusPIv2/zmleS9BjJVeZ6kBagPoEUsqbVz/1A= -github.com/go-logr/logr v1.4.3 h1:CjnDlHq8ikf6E492q6eKboGOC0T8CDaOvkHCIg8idEI= -github.com/go-logr/logr v1.4.3/go.mod h1:9T104GzyrTigFIr8wt5mBrctHMim0Nb2HLGrmQ40KvY= +github.com/go-logr/logr v1.4.4 h1:tG4xh9yMsRCAiodLVTxyrkzSZ9+o0L1Kg/+cPVcbP/8= +github.com/go-logr/logr v1.4.4/go.mod h1:9T104GzyrTigFIr8wt5mBrctHMim0Nb2HLGrmQ40KvY= github.com/go-logr/stdr v1.2.2 h1:hSWxHoqTgW2S2qGc0LTAI563KZ5YKYRhT3MFKZMbjag= github.com/go-logr/stdr v1.2.2/go.mod h1:mMo/vtBO5dYbehREoey6XUKy/eSumjCCveDpRre4VKE= github.com/go-ole/go-ole v1.2.6/go.mod h1:pprOEPIfldk/42T2oK7lQ4v4JSDwmV0As9GaiUsvbm0= github.com/go-ole/go-ole v1.3.0 h1:Dt6ye7+vXGIKZ7Xtk4s6/xVdGDQynvom7xCFEdWr6uE= github.com/go-ole/go-ole v1.3.0/go.mod h1:5LS6F96DhAwUc7C+1HLexzMXY1xGRSryjyPPKW6zv78= -github.com/go-openapi/jsonpointer v0.21.0 h1:YgdVicSA9vH5RiHs9TZW5oyafXZFc6+2Vc1rr/O9oNQ= -github.com/go-openapi/jsonpointer v0.21.0/go.mod h1:IUyH9l/+uyhIYQ/PXVA41Rexl+kOkAPDdXEYns6fzUY= -github.com/go-openapi/swag v0.23.0 h1:vsEVJDUo2hPJ2tu0/Xc+4noaxyEffXNIs3cOULZ+GrE= -github.com/go-openapi/swag v0.23.0/go.mod h1:esZ8ITTYEsH1V2trKHjAN8Ai7xHb8RV+YSZ577vPjgQ= +github.com/go-openapi/jsonpointer v0.23.1 h1:1HBACs7XIwR2RcmItfdSFlALhGbe6S92p0ry4d1GWg4= +github.com/go-openapi/jsonpointer v0.23.1/go.mod h1:iWRmZTrGn7XwYhtPt/fvdSFj1OfNBngqRT2UG3BxSqY= +github.com/go-openapi/swag/jsonname v0.26.0 h1:gV1NFX9M8avo0YSpmWogqfQISigCmpaiNci8cGECU5w= +github.com/go-openapi/swag/jsonname v0.26.0/go.mod h1:urBBR8bZNoDYGr653ynhIx+gTeIz0ARZxHkAPktJK2M= +github.com/go-openapi/testify/v2 v2.4.2 h1:tiByHpvE9uHrrKjOszax7ZvKB7QOgizBWGBLuq0ePx4= +github.com/go-openapi/testify/v2 v2.4.2/go.mod h1:SgsVHtfooshd0tublTtJ50FPKhujf47YRqauXXOUxfw= github.com/go-sql-driver/mysql v1.10.0 h1:Q+1LV8DkHJvSYAdR83XzuhDaTykuDx0l6fkXxoWCWfw= github.com/go-sql-driver/mysql v1.10.0/go.mod h1:M+cqaI7+xxXGG9swrdeUIoPG3Y3KCkF0pZej+SK+nWk= github.com/go-stack/stack v1.8.0/go.mod h1:v0f6uXyyMGvRgIKkXu+yp6POWl0qKG85gN/melR3HDY= -github.com/go-test/deep v1.0.8 h1:TDsG77qcSprGbC6vTN8OuXp5g+J+b5Pcguhf7Zt61VM= -github.com/go-test/deep v1.0.8/go.mod h1:5C2ZWiW0ErCdrYzpqxLbTX7MG14M9iiw8DgHncVwcsE= +github.com/go-task/slim-sprig v0.0.0-20210107165309-348f09dbbbc0/go.mod h1:fyg7847qk6SyHyPtNmDHnmrv/HOrqktSC+C9fM+CJOE= github.com/go-viper/mapstructure/v2 v2.5.0 h1:vM5IJoUAy3d7zRSVtIwQgBj7BiWtMPfmPEgAXnvj1Ro= github.com/go-viper/mapstructure/v2 v2.5.0/go.mod h1:oJDH3BJKyqBA2TXFhDsKDGDTlndYOZ6rGS0BRZIxGhM= github.com/gofrs/flock v0.12.1 h1:MTLVXXHf8ekldpJk3AKicLij9MdwOWkZ+a/jHHZby9E= @@ -172,16 +187,30 @@ github.com/gogo/protobuf v1.3.2 h1:Ov1cvc58UF3b5XjBnZv7+opcTcQFZebYjWzi34vdm4Q= github.com/gogo/protobuf v1.3.2/go.mod h1:P1XiOD3dCwIKUDQYPy72D8LYyHL2YPYrpS2s69NZV8Q= github.com/golang-jwt/jwt/v4 v4.5.2 h1:YtQM7lnr8iZ+j5q71MGKkNw9Mn7AjHM68uc9g5fXeUI= github.com/golang-jwt/jwt/v4 v4.5.2/go.mod h1:m21LjoU+eqJr34lmDMbreY2eSTRJ1cv77w39/MY0Ch0= -github.com/golang-migrate/migrate/v4 v4.19.1 h1:OCyb44lFuQfYXYLx1SCxPZQGU7mcaZ7gH9yH4jSFbBA= -github.com/golang-migrate/migrate/v4 v4.19.1/go.mod h1:CTcgfjxhaUtsLipnLoQRWCrjYXycRz/g5+RWDuYgPrE= +github.com/golang-migrate/migrate/v4 v4.20.1 h1:2N/ToVTKrKl58ynBpgeVJ4In7VcLCjWTZtm4eP1LxhU= +github.com/golang-migrate/migrate/v4 v4.20.1/go.mod h1:DDPgKVb4ovSWc4FwSPfV2Uz1160f4XBiTHTrAJtljmM= +github.com/golang/protobuf v1.2.0/go.mod h1:6lQm79b+lXiMfvg/cZm0SGofjICqVBUtrP5yJMmIC1U= +github.com/golang/protobuf v1.4.0-rc.1/go.mod h1:ceaxUfeHdC40wWswd/P6IGgMaK3YpKi5j83Wpe3EHw8= +github.com/golang/protobuf v1.4.0-rc.1.0.20200221234624-67d41d38c208/go.mod h1:xKAWHe0F5eneWXFV3EuXVDTCmh+JuBKY0li0aMyXATA= +github.com/golang/protobuf v1.4.0-rc.2/go.mod h1:LlEzMj4AhA7rCAGe4KMBDvJI+AwstrUpVNzEA03Pprs= +github.com/golang/protobuf v1.4.0-rc.4.0.20200313231945-b860323f09d0/go.mod h1:WU3c8KckQ9AFe+yFwt9sWVRKCVIyN9cPHBJSNnbL67w= +github.com/golang/protobuf v1.4.0/go.mod h1:jodUvKwWbYaEsadDk5Fwe5c77LiNKVO9IDvqG2KuDX0= +github.com/golang/protobuf v1.4.2/go.mod h1:oDoupMAO8OvCJWAcko0GGGIgR6R6ocIYbsSw735rRwI= +github.com/golang/protobuf v1.5.0/go.mod h1:FsONVRAS9T7sI+LIUmWTfcYkHO4aIWwzhcaSAoJOfIk= +github.com/golang/protobuf v1.5.2/go.mod h1:XVQd3VNwM+JqD3oG2Ue2ip4fOMUkwXdXDdiuN0vRsmY= github.com/golang/protobuf v1.5.4 h1:i7eJL8qZTpSEXOPTxNKhASYpMn+8e5Q6AdndVa1dWek= github.com/golang/protobuf v1.5.4/go.mod h1:lnTiLA8Wa4RWRcIUkrtSVa5nRhsEGBg48fD6rSs7xps= -github.com/golang/snappy v1.0.0 h1:Oy607GVXHs7RtbggtPBnr2RmDArIsAefDwvrdWvRhGs= -github.com/golang/snappy v1.0.0/go.mod h1:/XxbfmMg8lxefKM7IXC3fBNl/7bRcc72aCRzEWrmP2Q= +github.com/golang/snappy v1.0.1-0.20260716114414-9ae09f520e93 h1:GpQQr4L8jsBtJSURCDqQboOdgpVMU6vR9REjc8nR4Qc= +github.com/golang/snappy v1.0.1-0.20260716114414-9ae09f520e93/go.mod h1:/XxbfmMg8lxefKM7IXC3fBNl/7bRcc72aCRzEWrmP2Q= +github.com/google/go-cmp v0.3.0/go.mod h1:8QqcDgzrUqlUb/G2PQTWiueGozuR1884gddMywk6iLU= +github.com/google/go-cmp v0.3.1/go.mod h1:8QqcDgzrUqlUb/G2PQTWiueGozuR1884gddMywk6iLU= +github.com/google/go-cmp v0.4.0/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE= +github.com/google/go-cmp v0.5.5/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE= github.com/google/go-cmp v0.7.0 h1:wk8382ETsv4JYUZwIsn6YpYiWiBsYLSJiTsyBybVuN8= github.com/google/go-cmp v0.7.0/go.mod h1:pXiqmnSA92OHEEa9HXL2W4E7lf9JzCmGVUdgjX3N/iU= github.com/google/gofuzz v1.2.0 h1:xRy4A+RhZaiKjJ1bPfwQ8sedCA+YS2YcCHW6ec7JMi0= github.com/google/gofuzz v1.2.0/go.mod h1:dBl0BpW6vV/+mYPU4Po3pmUjxk6FQPldtuIdl/M65Eg= +github.com/google/pprof v0.0.0-20210407192527-94a9f03dee38/go.mod h1:kpwsk12EmLew5upagYY7GY0pfYCcupk39gWOCRROcvE= github.com/google/renameio v0.1.0/go.mod h1:KWCgfxg9yswjAJkECMjeO8J8rahYeXnNhOm40UhjYkI= github.com/google/uuid v1.6.0 h1:NIvaJDMOsjHA8n1jAhLSgzrAzy1Hgr+hNrb57e+94F0= github.com/google/uuid v1.6.0/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo= @@ -207,8 +236,10 @@ github.com/holiman/bloomfilter/v2 v2.0.3 h1:73e0e/V0tCydx14a0SCYS/EWCxgwLZ18CZcZ github.com/holiman/bloomfilter/v2 v2.0.3/go.mod h1:zpoh+gs7qcpqrHr3dB55AMiJwo0iURXE7ZOP9L9hSkA= github.com/holiman/uint256 v1.3.2 h1:a9EgMPSC1AAaj1SZL5zIQD3WbwTuHrMGOerLjGmM/TA= github.com/holiman/uint256 v1.3.2/go.mod h1:EOMSn4q6Nyt9P6efbI3bueV4e1b3dGlUCXeiRV4ng7E= +github.com/hpcloud/tail v1.0.0/go.mod h1:ab1qPbhIpdTxEkNHXyeSf5vhxWSCs/tWer42PpOxQnU= github.com/huin/goupnp v1.3.0 h1:UvLUlWDNpoUdYzb2TCn+MuTWtcjXKSza2n6CBdQ0xXc= github.com/huin/goupnp v1.3.0/go.mod h1:gnGPsThkYa7bFi/KWmEysQRf48l2dvR5bxr2OFckNX8= +github.com/ianlancetaylor/demangle v0.0.0-20200824232613-28f6c0f3b639/go.mod h1:aSSvb/t6k1mPoxDqO4vJh6VOCGPwU4O0C2/Eqndh1Sc= github.com/inconshreveable/mousetrap v1.1.0 h1:wN+x4NVGpMsO7ErUn/mUI3vEoE6Jt13X2s0bqwp9tc8= github.com/inconshreveable/mousetrap v1.1.0/go.mod h1:vpF70FUmC8bwa3OWnCshd2FqLfsEA9PFc4w1p2J65bw= github.com/influxdata/influxdb-client-go/v2 v2.4.0 h1:HGBfZYStlx3Kqvsv1h2pJixbCl/jhnFtxpKFAv9Tu5k= @@ -217,8 +248,6 @@ github.com/influxdata/influxdb1-client v0.0.0-20220302092344-a9ab5670611c h1:qSH github.com/influxdata/influxdb1-client v0.0.0-20220302092344-a9ab5670611c/go.mod h1:qj24IKcXYK6Iy9ceXlo3Tc+vtHo9lIhSX5JddghvEPo= github.com/influxdata/line-protocol v0.0.0-20200327222509-2487e7298839 h1:W9WBk7wlPfJLvMCdtV4zPulc4uCPrlywQOmbFOhgQNU= github.com/influxdata/line-protocol v0.0.0-20200327222509-2487e7298839/go.mod h1:xaLFMmpvUxqXtVkUJfg9QmT88cDaCJ3ZKgdZ78oO8Qo= -github.com/invopop/yaml v0.2.0 h1:7zky/qH+O0DwAyoobXUqvVBwgBFRxKoQ/3FjcVpjTMY= -github.com/invopop/yaml v0.2.0/go.mod h1:2XuRLgs/ouIrW3XNzuNj7J3Nvu/Dig5MXvbCEdiBN3Q= github.com/jackc/chunkreader v1.0.0/go.mod h1:RT6O25fNZIuasFJRyZ4R/Y2BbhasbmZXF9QQ7T3kePo= github.com/jackc/chunkreader/v2 v2.0.0/go.mod h1:odVSm741yZoC3dpHEUXIqA9tQRhFrgOHwnPIn9lDKlk= github.com/jackc/chunkreader/v2 v2.0.1 h1:i+RDz65UE+mmpjTfyz0MoVTnzeYxroil2G82ki7MGG8= @@ -268,8 +297,8 @@ github.com/jackc/pgx/v4 v4.12.1-0.20210724153913-640aa07df17c/go.mod h1:1QD0+tgS github.com/jackc/pgx/v4 v4.18.2/go.mod h1:Ey4Oru5tH5sB6tV7hDmfWFahwF15Eb7DNXlRKx2CkVw= github.com/jackc/pgx/v4 v4.18.3 h1:dE2/TrEsGX3RBprb3qryqSV9Y60iZN1C6i8IrmW9/BA= github.com/jackc/pgx/v4 v4.18.3/go.mod h1:Ey4Oru5tH5sB6tV7hDmfWFahwF15Eb7DNXlRKx2CkVw= -github.com/jackc/pgx/v5 v5.10.0 h1:VhSvgU2jSli8o3AqIEOTJr7rZwAEUVo4E4XhR94Zfr0= -github.com/jackc/pgx/v5 v5.10.0/go.mod h1:mal1tBGAFfLHvZzaYh77YS/eC6IX9OWbRV1QIIM0Jn4= +github.com/jackc/pgx/v5 v5.11.0 h1:IzBBtyK9AHqf98cctWFifYSci2hgQR/cd56wB4p+ogg= +github.com/jackc/pgx/v5 v5.11.0/go.mod h1:mal1tBGAFfLHvZzaYh77YS/eC6IX9OWbRV1QIIM0Jn4= github.com/jackc/puddle v0.0.0-20190413234325-e4ced69a3a2b/go.mod h1:m4B5Dj62Y0fbyuIc15OsIqK0+JU8nkqQjsgx7dvjSWk= github.com/jackc/puddle v0.0.0-20190608224051-11cab39313c9/go.mod h1:m4B5Dj62Y0fbyuIc15OsIqK0+JU8nkqQjsgx7dvjSWk= github.com/jackc/puddle v1.1.3/go.mod h1:m4B5Dj62Y0fbyuIc15OsIqK0+JU8nkqQjsgx7dvjSWk= @@ -278,12 +307,10 @@ github.com/jackc/puddle/v2 v2.2.2 h1:PR8nw+E/1w0GLuRFSmiioY6UooMp6KJv0/61nB7icHo github.com/jackc/puddle/v2 v2.2.2/go.mod h1:vriiEXHvEE654aYKXXjOvZM39qJ0q+azkZFrfEOc3H4= github.com/jackpal/go-nat-pmp v1.0.2 h1:KzKSgb7qkJvOUTqYl9/Hg/me3pWgBmERKrTGD7BdWus= github.com/jackpal/go-nat-pmp v1.0.2/go.mod h1:QPH045xvCAeXUZOxsnwmrtiCoxIr9eob+4orBN1SBKc= -github.com/josharian/intern v1.0.0 h1:vlS4z54oSdjm0bgjRigI+G1HpF+tI+9rE5LLzOg8HmY= -github.com/josharian/intern v1.0.0/go.mod h1:5DoeVV0s6jJacbCEi61lwdGj/aVlrQvzHFFd8Hwg//Y= github.com/juju/gnuflag v0.0.0-20171113085948-2ce1bb71843d/go.mod h1:2PavIy+JPciBPrBUjwbNvtwB6RQlve+hkpll6QSNmOE= github.com/kisielk/gotool v1.0.0/go.mod h1:XhKaO+MFFWcvkIS/tQcRk01m1F5IRFswLeQ+oQHNcck= -github.com/klauspost/compress v1.17.9 h1:6KIumPrER1LHsvBVuDa0r5xaG0Es51mhhB9BQB2qeMA= -github.com/klauspost/compress v1.17.9/go.mod h1:Di0epgTjJY877eYKx5yC51cX2A2Vl2ibi7bDH9ttBbw= +github.com/klauspost/compress v1.17.11 h1:In6xLpyWOi1+C7tXUUWv2ot1QvBjxevKAaI6IXrJmUc= +github.com/klauspost/compress v1.17.11/go.mod h1:pMDklpSncoRMuLFrf1W9Ss9KT+0rH90U12bZKk7uwG0= github.com/klauspost/cpuid/v2 v2.2.7 h1:ZWSB3igEs+d0qvnxR/ZBzXVmxkgt8DdzP6m9pfuVLDM= github.com/klauspost/cpuid/v2 v2.2.7/go.mod h1:Lcz8mBdAVJIBVzewtcLocK12l3Y+JytZYpaMropDUws= github.com/konsorten/go-windows-terminal-sequences v1.0.1/go.mod h1:T0+1ngSBFLxvqU3pZ+m/2kptfBszLMUkC4ZK/EgS/cQ= @@ -306,10 +333,8 @@ github.com/lib/pq v1.2.0/go.mod h1:5WUZQaWbwv1U+lTReE5YruASi9Al49XbQIvNi/34Woo= github.com/lib/pq v1.10.2/go.mod h1:AlVN5x4E4T544tWzH6hKfbfQvm3HdbOxrmggDNAPY9o= github.com/lib/pq v1.12.3 h1:tTWxr2YLKwIvK90ZXEw8GP7UFHtcbTtty8zsI+YjrfQ= github.com/lib/pq v1.12.3/go.mod h1:/p+8NSbOcwzAEI7wiMXFlgydTwcgTr3OSKMsD2BitpA= -github.com/lmittmann/tint v1.1.3 h1:Hv4EaHWXQr+GTFnOU4VKf8UvAtZgn0VuKT+G0wFlO3I= -github.com/lmittmann/tint v1.1.3/go.mod h1:HIS3gSy7qNwGCj+5oRjAutErFBl4BzdQP6cJZ0NfMwE= -github.com/mailru/easyjson v0.7.7 h1:UGYAvKxe3sBsEDzO8ZeWOSlIQfWFlxbzLZe7hwFURr0= -github.com/mailru/easyjson v0.7.7/go.mod h1:xzfreul335JAWq5oZzymOObrkdz5UnU4kGfJJLY9Nlc= +github.com/lmittmann/tint v1.2.0 h1:AogHRHy8HUJUnNJBHJlYa+fR4YY8mko2cnCp67xn9JY= +github.com/lmittmann/tint v1.2.0/go.mod h1:HIS3gSy7qNwGCj+5oRjAutErFBl4BzdQP6cJZ0NfMwE= github.com/mattn/go-colorable v0.1.1/go.mod h1:FuOcm+DKB9mbwrcAfNl7/TZVBZ6rcnceauSikq3lYCQ= github.com/mattn/go-colorable v0.1.6/go.mod h1:u6P/XSegPjTcexA+o6vUJrdnUu04hMope9wVRipJSqc= github.com/mattn/go-colorable v0.1.14 h1:9A9LHSqF/7dyVVX6g0U9cwm9pG3kP9gSzcuIPHPsaIE= @@ -321,10 +346,12 @@ github.com/mattn/go-isatty v0.0.20 h1:xfD0iDuEKnDkl03q4limB+vH+GxLEtL/jb4xVJSWWE github.com/mattn/go-isatty v0.0.20/go.mod h1:W+V8PltTTMOvKvAeJH7IuucS94S2C6jfK/D7dTCTo3Y= github.com/mattn/go-runewidth v0.0.13 h1:lTGmDsbAYt5DmK6OnoV7EuIF1wEIFAcxld6ypU4OSgU= github.com/mattn/go-runewidth v0.0.13/go.mod h1:Jdepj2loyihRzMpdS35Xk/zdY8IAYHsh153qUoGf23w= -github.com/mattn/go-sqlite3 v1.14.44 h1:3VSe+xafpbzsLbdr2AWlAZk9yRHiBhTBakioXaCKTF8= -github.com/mattn/go-sqlite3 v1.14.44/go.mod h1:pjEuOr8IwzLJP2MfGeTb0A35jauH+C2kbHKBr7yXKVQ= +github.com/mattn/go-sqlite3 v1.14.50 h1:dmdFvo1XG4MPzA4IkAmE9upVz/Nj31uRoM5+jC8hYbY= +github.com/mattn/go-sqlite3 v1.14.50/go.mod h1:6JTjA44L93a0QCyJef5YvlPoKXntQPjzWv5gtm9sB6w= github.com/matttproud/golang_protobuf_extensions v1.0.4 h1:mmDVorXM7PCGKw94cs5zkfA9PSy5pEvNWRP0ET0TIVo= github.com/matttproud/golang_protobuf_extensions v1.0.4/go.mod h1:BSXmuO+STAnVfrANrmjBb36TMTDstsz7MSK+HVaYKv4= +github.com/minio/minlz v1.0.1-0.20250507153514-87eb42fe8882 h1:0lgqHvJWHLGW5TuObJrfyEi6+ASTKDBWikGvPqy9Yiw= +github.com/minio/minlz v1.0.1-0.20250507153514-87eb42fe8882/go.mod h1:qT0aEB35q79LLornSzeDH75LBf3aH1MV+jB5w9Wasec= github.com/minio/sha256-simd v1.0.0 h1:v1ta+49hkWZyvaKwrQB8elexRqm6Y0aMLjCNsrYxo6g= github.com/minio/sha256-simd v1.0.0/go.mod h1:OuYzVNI5vcoYIAmbIvHPl3N3jUzVedXbKy5RFepssQM= github.com/mitchellh/mapstructure v1.5.0 h1:jeMsZIYE/09sWLaz43PL7Gy6RuMjD2eJVyuac5Z2hdY= @@ -333,52 +360,69 @@ github.com/mitchellh/pointerstructure v1.2.0 h1:O+i9nHnXS3l/9Wu7r4NrEdwA2VFTicjU github.com/mitchellh/pointerstructure v1.2.0/go.mod h1:BRAsLI5zgXmw97Lf6s25bs8ohIXc3tViBH44KcwB2g4= github.com/moby/docker-image-spec v1.3.1 h1:jMKff3w6PgbfSa69GfNg+zN/XLhfXJGnEx3Nl2EsFP0= github.com/moby/docker-image-spec v1.3.1/go.mod h1:eKmb5VW8vQEh/BAr2yvVNvuiJuY6UIocYsFu/DxxRpo= -github.com/moby/term v0.5.0 h1:xt8Q1nalod/v7BqbG21f8mQPqH+xAaC9C3N3wfWbVP0= -github.com/moby/term v0.5.0/go.mod h1:8FzsFHVUBGZdbDsJw/ot+X+d5HLUbvklYLJ9uGfcI3Y= -github.com/mohae/deepcopy v0.0.0-20170929034955-c48cc78d4826 h1:RWengNIwukTxcDr9M+97sNutRR1RKhG96O6jWumTTnw= -github.com/mohae/deepcopy v0.0.0-20170929034955-c48cc78d4826/go.mod h1:TaXosZuwdSHYgviHp1DAtfrULt5eUgsSMsZf+YrPgl8= +github.com/moby/moby/api v1.54.2 h1:wiat9QAhnDQjA7wk1kh/TqHz2I1uUA7M7t9SAl/JNXg= +github.com/moby/moby/api v1.54.2/go.mod h1:+RQ6wluLwtYaTd1WnPLykIDPekkuyD/ROWQClE83pzs= +github.com/moby/moby/client v0.4.1 h1:DMQgisVoMkmMs7fp3ROSdiBnoAu8+vo3GggFl06M/wY= +github.com/moby/moby/client v0.4.1/go.mod h1:z52C9O2POPOsnxZAy//WtKcQ32P+jT/NGeXu/7nfjGQ= +github.com/moby/term v0.5.2 h1:6qk3FJAFDs6i/q3W/pQ97SX192qKfZgGjCQqfCJkgzQ= +github.com/moby/term v0.5.2/go.mod h1:d3djjFCrjnB+fl8NJux+EJzu0msscUP+f8it8hPkFLc= github.com/morikuni/aec v1.0.0 h1:nP9CBfwrvYnBRgY6qfDQkygYDmYwOilePFkwzv4dU8A= github.com/morikuni/aec v1.0.0/go.mod h1:BbKIizmSmc5MMPqRYbxO4ZU0S0+P200+tUnFx7PXmsc= +github.com/nxadm/tail v1.4.4/go.mod h1:kenIhsEOeOJmVchQTgglprH7qJGnHDVpk1VPCcaMI8A= +github.com/nxadm/tail v1.4.8 h1:nPr65rt6Y5JFSKQO7qToXr7pePgD6Gwiw05lkbyAQTE= +github.com/nxadm/tail v1.4.8/go.mod h1:+ncqLTQzXmGhMZNUePPaPqPvBxHAIsmXswZKocGu+AU= github.com/oapi-codegen/nullable v1.1.0 h1:eAh8JVc5430VtYVnq00Hrbpag9PFRGWLjxR1/3KntMs= github.com/oapi-codegen/nullable v1.1.0/go.mod h1:KUZ3vUzkmEKY90ksAmit2+5juDIhIZhfDl+0PwOQlFY= -github.com/oapi-codegen/runtime v1.4.1 h1:9nwLoI+KrWxzbBcp0jO/R8uXqbik/HUyCvPeU68Y/qo= -github.com/oapi-codegen/runtime v1.4.1/go.mod h1:GwV7hC2hviaMzj+ITfHVRESK5J2W/GefVwIND/bMGvU= +github.com/oapi-codegen/oapi-codegen/v2 v2.8.0 h1:s4hxMxuqtR8jPzXkBTtFwY/SBuj3gEAYikmbBSdtLMM= +github.com/oapi-codegen/oapi-codegen/v2 v2.8.0/go.mod h1:yae2TI9IYB5vxQ35gFrpXh9L5H1eJv4MAUK1jumGMTo= +github.com/oapi-codegen/runtime v1.7.0 h1:t7358VYPvNbWJ9gdAkIK/smVeHpBf6yp8VTsaZsb/7k= +github.com/oapi-codegen/runtime v1.7.0/go.mod h1:GwV7hC2hviaMzj+ITfHVRESK5J2W/GefVwIND/bMGvU= +github.com/oasdiff/yaml v0.1.1 h1:6nHx+pn9gBRM6YpBlFZFQGCCd1nuvqOBtTD3KKTgGxY= +github.com/oasdiff/yaml v0.1.1/go.mod h1:EYJNoyktvWMJ0Hmhx+6qTaqMOsalUaRGT8Sj1hNcegU= +github.com/oasdiff/yaml3 v0.0.14 h1:aLJee3hxBK2H5wdXd9iPcIXb93Nty1Ge0pT171eHtkw= +github.com/oasdiff/yaml3 v0.0.14/go.mod h1:csto2xfDjYccdUn/yw/bPjj/cYTdp6HtFA0J4TWG+gg= +github.com/onsi/ginkgo v1.6.0/go.mod h1:lLunBs/Ym6LB5Z9jYTR76FiuTmxDTDusOGeTQH+WWjE= +github.com/onsi/ginkgo v1.10.2/go.mod h1:lLunBs/Ym6LB5Z9jYTR76FiuTmxDTDusOGeTQH+WWjE= +github.com/onsi/ginkgo v1.12.1/go.mod h1:zj2OWP4+oCPe1qIXoGWkgMRwljMUYCdkwsT2108oapk= +github.com/onsi/ginkgo v1.16.4 h1:29JGrr5oVBm5ulCWet69zQkzWipVXIol6ygQUe/EzNc= +github.com/onsi/ginkgo v1.16.4/go.mod h1:dX+/inL/fNMqNlz0e9LfyB9TswhZpCVdJM/Z6Vvnwo0= +github.com/onsi/ginkgo/v2 v2.1.3/go.mod h1:vw5CSIxN1JObi/U8gcbwft7ZxR2dgaR70JSE3/PpL4c= +github.com/onsi/gomega v1.7.0/go.mod h1:ex+gbHU/CVuBBDIJjb2X0qEXbFg53c61hWP/1CpauHY= +github.com/onsi/gomega v1.7.1/go.mod h1:XdKZgCCFLUoM/7CFJVPcG8C1xQ1AJ0vpAezJrB7JYyY= +github.com/onsi/gomega v1.10.1/go.mod h1:iN09h71vgCQne3DLsj+A5owkum+a2tYe+TOCB1ybHNo= +github.com/onsi/gomega v1.17.0/go.mod h1:HnhC7FXeEQY45zxNK3PPoIUhzk/80Xly9PcubAlGdZY= +github.com/onsi/gomega v1.19.0 h1:4ieX6qQjPP/BfC3mpsAtIGGlxTWPeA3Inl/7DtXw1tw= +github.com/onsi/gomega v1.19.0/go.mod h1:LY+I3pBVzYsTBU1AnDwOSxaYi9WoWiqgwooUqq9yPro= github.com/opencontainers/go-digest v1.0.0 h1:apOUWs51W5PlhuyGyz9FCeeBIOUDA/6nW8Oi/yOhh5U= github.com/opencontainers/go-digest v1.0.0/go.mod h1:0JzlMkj0TRzQZfJkVvzbP0HBR3IKzErnv2BNG4W4MAM= -github.com/opencontainers/image-spec v1.1.0 h1:8SG7/vwALn54lVB/0yZ/MMwhFrPYtpEHQb2IpWsCzug= -github.com/opencontainers/image-spec v1.1.0/go.mod h1:W4s4sFTMaBeK1BQLXbG4AdM2szdn85PY75RI83NrTrM= +github.com/opencontainers/image-spec v1.1.1 h1:y0fUlFfIZhPF1W537XOLg0/fcx6zcHCJwooC2xJA040= +github.com/opencontainers/image-spec v1.1.1/go.mod h1:qpqAh3Dmcf36wStyyWU+kCeDgrGnAve2nCC8+7h8Q0M= github.com/opentracing/opentracing-go v1.1.0 h1:pWlfV3Bxv7k65HYwkikxat0+s3pV4bsqf19k25Ur8rU= github.com/opentracing/opentracing-go v1.1.0/go.mod h1:UkNAQd3GIcIGf0SeVgPpRdFStlNbqXla1AfSYxPUl2o= -github.com/pelletier/go-toml/v2 v2.3.1 h1:MYEvvGnQjeNkRF1qUuGolNtNExTDwct51yp7olPtrEc= -github.com/pelletier/go-toml/v2 v2.3.1/go.mod h1:2gIqNv+qfxSVS7cM2xJQKtLSTLUE9V8t9Stt+h56mCY= -github.com/perimeterx/marshmallow v1.1.5 h1:a2LALqQ1BlHM8PZblsDdidgv1mWi1DgC2UmX50IvK2s= -github.com/perimeterx/marshmallow v1.1.5/go.mod h1:dsXbUu8CRzfYP5a87xpp0xq9S3u0Vchtcl8we9tYaXw= +github.com/pelletier/go-toml/v2 v2.4.3 h1:GTRvJQutkOSftxIFD5xw9aepkYNuPWmVJpffdDPYVpY= +github.com/pelletier/go-toml/v2 v2.4.3/go.mod h1:2gIqNv+qfxSVS7cM2xJQKtLSTLUE9V8t9Stt+h56mCY= github.com/peterh/liner v1.1.1-0.20190123174540-a2c9a5303de7 h1:oYW+YCJ1pachXTQmzR3rNLYGGz4g/UgFcjb28p/viDM= github.com/peterh/liner v1.1.1-0.20190123174540-a2c9a5303de7/go.mod h1:CRroGNssyjTd/qIG2FyxByd2S8JEAZXBl4qUrZf8GS0= -github.com/pion/dtls/v2 v2.2.7 h1:cSUBsETxepsCSFSxC3mc/aDo14qQLMSL+O6IjG28yV8= -github.com/pion/dtls/v2 v2.2.7/go.mod h1:8WiMkebSHFD0T+dIU+UeBaoV7kDhOW5oDCzZ7WZ/F9s= -github.com/pion/logging v0.2.2 h1:M9+AIj/+pxNsDfAT64+MAVgJO0rsyLnoJKCqf//DoeY= -github.com/pion/logging v0.2.2/go.mod h1:k0/tDVsRCX2Mb2ZEmTqNa7CWsQPc+YYCB7Q+5pahoms= -github.com/pion/stun/v2 v2.0.0 h1:A5+wXKLAypxQri59+tmQKVs7+l6mMM+3d+eER9ifRU0= -github.com/pion/stun/v2 v2.0.0/go.mod h1:22qRSh08fSEttYUmJZGlriq9+03jtVmXNODgLccj8GQ= -github.com/pion/transport/v2 v2.2.1 h1:7qYnCBlpgSJNYMbLCKuSY9KbQdBFoETvPNETv0y4N7c= -github.com/pion/transport/v2 v2.2.1/go.mod h1:cXXWavvCnFF6McHTft3DWS9iic2Mftcz1Aq29pGcU5g= -github.com/pion/transport/v3 v3.0.1 h1:gDTlPJwROfSfz6QfSi0ZmeCSkFcnWWiiR9ES0ouANiM= -github.com/pion/transport/v3 v3.0.1/go.mod h1:UY7kiITrlMv7/IKgd5eTUcaahZx5oUN3l9SzK5f5xE0= +github.com/pion/dtls/v3 v3.1.2 h1:gqEdOUXLtCGW+afsBLO0LtDD8GnuBBjEy6HRtyofZTc= +github.com/pion/dtls/v3 v3.1.2/go.mod h1:Hw/igcX4pdY69z1Hgv5x7wJFrUkdgHwAn/Q/uo7YHRo= +github.com/pion/logging v0.2.4 h1:tTew+7cmQ+Mc1pTBLKH2puKsOvhm32dROumOZ655zB8= +github.com/pion/logging v0.2.4/go.mod h1:DffhXTKYdNZU+KtJ5pyQDjvOAh/GsNSyv1lbkFbe3so= +github.com/pion/stun/v3 v3.1.2 h1:86IhD8wFn6IDW4b1/0QzoQS+f5PeA8OHHRn8UZW5ErY= +github.com/pion/stun/v3 v3.1.2/go.mod h1:H7gDic7nNwlUL05pbs6T1dtaBehh/KjupxfWw3ZI7cA= +github.com/pion/transport/v4 v4.0.1 h1:sdROELU6BZ63Ab7FrOLn13M6YdJLY20wldXW2Cu2k8o= +github.com/pion/transport/v4 v4.0.1/go.mod h1:nEuEA4AD5lPdcIegQDpVLgNoDGreqM/YqmEx3ovP4jM= github.com/pkg/errors v0.8.1/go.mod h1:bwawxfHBFNV+L2hUp1rHADufV3IMtnDRdf1r5NINEl0= github.com/pkg/errors v0.9.1 h1:FEBLx1zS214owpjy7qsBeixbURkuhQAwrK5UwLGTwt4= github.com/pkg/errors v0.9.1/go.mod h1:bwawxfHBFNV+L2hUp1rHADufV3IMtnDRdf1r5NINEl0= github.com/pmezard/go-difflib v1.0.0/go.mod h1:iKH77koFhYxTK1pcRnkKkqfTogsbg7gZNVY4sRDYZ/4= -github.com/pmezard/go-difflib v1.0.1-0.20181226105442-5d4384ee4fb2 h1:Jamvg5psRIccs7FGNTlIRMkT8wgtp5eCXdBlqhYGL6U= -github.com/pmezard/go-difflib v1.0.1-0.20181226105442-5d4384ee4fb2/go.mod h1:iKH77koFhYxTK1pcRnkKkqfTogsbg7gZNVY4sRDYZ/4= -github.com/prometheus/client_golang v1.15.0 h1:5fCgGYogn0hFdhyhLbw7hEsWxufKtY9klyvdNfFlFhM= -github.com/prometheus/client_golang v1.15.0/go.mod h1:e9yaBhRPU2pPNsZwE+JdQl0KEt1N9XgF6zxWmaC0xOk= +github.com/prometheus/client_golang v1.16.0 h1:yk/hx9hDbrGHovbci4BY+pRMfSuuat626eFsHb7tmT8= +github.com/prometheus/client_golang v1.16.0/go.mod h1:Zsulrv/L9oM40tJ7T815tM89lFEugiJ9HzIqaAx4LKc= github.com/prometheus/client_model v0.3.0 h1:UBgGFHqYdG/TPFD1B1ogZywDqEkwp3fBMvqdiQ7Xew4= github.com/prometheus/client_model v0.3.0/go.mod h1:LDGWKZIo7rky3hgvBe+caln+Dr3dPggB5dvjtD7w9+w= github.com/prometheus/common v0.42.0 h1:EKsfXEYo4JpWMHH5cg+KOUWeuJSov1Id8zGR8eeI1YM= github.com/prometheus/common v0.42.0/go.mod h1:xBwqVerjNdUDjgODMpudtOMwlOwf2SaTr1yjz4b7Zbc= -github.com/prometheus/procfs v0.9.0 h1:wzCHvIvM5SxWqYvwgVL7yJY8Lz3PKn49KQtpgMYJfhI= -github.com/prometheus/procfs v0.9.0/go.mod h1:+pB4zwohETzFnmlpe6yd2lSc+0/46IYZRB/chUwxUZY= +github.com/prometheus/procfs v0.10.1 h1:kYK1Va/YMlutzCGazswoHKo//tZVlFpKYh+PymziUAg= +github.com/prometheus/procfs v0.10.1/go.mod h1:nwNm2aOCAYw8uTR/9bWRREkZFxAUcWzPHWJq+XBB/FM= github.com/rivo/uniseg v0.2.0 h1:S1pD9weZBuJdFmowNwbpi7BJ8TNftyUImj/0WQi72jY= github.com/rivo/uniseg v0.2.0/go.mod h1:J6wj4VEh+S6ZtnVlnTBMWIodfgj8LQOQFoIToxlJtxc= github.com/rogpeppe/go-internal v1.3.0/go.mod h1:M8bDsm7K2OlrFYOpmOWEs/qY81heoFRclV5y23lUDJ4= @@ -393,7 +437,11 @@ github.com/russross/blackfriday/v2 v2.1.0 h1:JIOH55/0cWyOuilr9/qlrm0BSXldqnqwMsf github.com/russross/blackfriday/v2 v2.1.0/go.mod h1:+Rmxgy9KzJVeS9/2gXHxylqXiyQDYRxCVz55jmeOWTM= github.com/sagikazarmark/locafero v0.12.0 h1:/NQhBAkUb4+fH1jivKHWusDYFjMOOKU88eegjfxfHb4= github.com/sagikazarmark/locafero v0.12.0/go.mod h1:sZh36u/YSZ918v0Io+U9ogLYQJ9tLLBmM4eneO6WwsI= +github.com/santhosh-tekuri/jsonschema/v6 v6.0.2 h1:KRzFb2m7YtdldCEkzs6KqmJw4nqEVZGK7IN2kJkjTuQ= +github.com/santhosh-tekuri/jsonschema/v6 v6.0.2/go.mod h1:JXeL+ps8p7/KNMjDQk3TCwPpBy0wYklyWTfbkIzdIFU= github.com/satori/go.uuid v1.2.0/go.mod h1:dA0hQrYB0VpLJoorglMZABFdXlWrHn1NEOzdhQKdks0= +github.com/sergi/go-diff v1.1.0 h1:we8PVUC3FE2uYfodKH/nBHMSetSfHDR6scGdBi+erh0= +github.com/sergi/go-diff v1.1.0/go.mod h1:STckp+ISIX8hZLjrqAeVduY0gWCT9IjLuqbuNXdaHfM= github.com/shirou/gopsutil v3.21.11+incompatible h1:+1+c1VGhc88SSonWP6foOcLhvnKlUeu/erjjvaPEYiI= github.com/shirou/gopsutil v3.21.11+incompatible/go.mod h1:5b4v6he4MtMOwMlS0TUMTu2PcXUg8+E1lC7eC3UO/RA= github.com/shopspring/decimal v0.0.0-20180709203117-cd690d0c9e24/go.mod h1:M+9NzErvs504Cn4c5DxATwIqPbtswREoFCre64PpcG4= @@ -401,6 +449,10 @@ github.com/shopspring/decimal v1.2.0 h1:abSATXmQEYyShuxI4/vyW3tV1MrKAJzCZ/0zLUXY github.com/shopspring/decimal v1.2.0/go.mod h1:DKyhrW/HYNuLGql+MJL6WCR6knT2jwCFRcu2hWCYk4o= github.com/sirupsen/logrus v1.4.1/go.mod h1:ni0Sbl8bgC9z8RoU9G6nDWqqs/fq4eDPysMBDgk/93Q= github.com/sirupsen/logrus v1.4.2/go.mod h1:tLMulIdttU9McNUspp0xgXVQah82FyeX6MwdIuYE2rE= +github.com/speakeasy-api/jsonpath v0.6.3 h1:c+QPwzAOdrWvzycuc9HFsIZcxKIaWcNpC+xhOW9rJxU= +github.com/speakeasy-api/jsonpath v0.6.3/go.mod h1:2cXloNuQ+RSXi5HTRaeBh7JEmjRXTiaKpFTdZiL7URI= +github.com/speakeasy-api/openapi v1.24.0 h1:opoD27rupX7zBVPq1HkIGLeMOzNNA7JalhYP8q34i04= +github.com/speakeasy-api/openapi v1.24.0/go.mod h1:g3+dIMe0AYgbbGvnlQZqesmjAVWSm9BmsjLevnefQrg= github.com/spf13/afero v1.15.0 h1:b/YBCLWAJdFWJTN9cLhiXXcD7mzKn9Dm86dNnfyQw1I= github.com/spf13/afero v1.15.0/go.mod h1:NC2ByUVxtQs4b3sIUphxK0NioZnmxgyCrfzeuq8lxMg= github.com/spf13/cast v1.10.0 h1:h2x0u2shc1QuLHfxi+cTJvs30+ZAHOGRic8uyGTDWxY= @@ -418,9 +470,8 @@ github.com/stretchr/objx v0.1.1/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+ github.com/stretchr/objx v0.2.0/go.mod h1:qt09Ya8vawLte6SNmTgCsAVtYtaKzEcn8ATUoHMkEqE= github.com/stretchr/objx v0.4.0/go.mod h1:YvHI0jy2hoMjB+UWwv71VJQ9isScKT/TqJzVSSt89Yw= github.com/stretchr/objx v0.5.0/go.mod h1:Yh+to48EsGEfYuaHDzXPcE3xhTkx73EhmCGUpEOglKo= -github.com/stretchr/objx v0.5.2 h1:xuMeJ0Sdp5ZMRXx/aWO6RZxdr3beISkG5/G/aIRr3pY= -github.com/stretchr/objx v0.5.2/go.mod h1:FRsXN1f5AsAjCGJKqEizvkpNtU+EGNCLh3NxZ/8L+MA= -github.com/stretchr/testify v1.1.5-0.20170601210322-f6abca593680/go.mod h1:a8OnRcib4nhh0OaRAV+Yts87kKdq0PP7pXfy6kDkUVs= +github.com/stretchr/objx v0.5.3 h1:jmXUvGomnU1o3W/V5h2VEradbpJDwGrzugQQvL0POH4= +github.com/stretchr/objx v0.5.3/go.mod h1:rDQraq+vQZU7Fde9LOZLr8Tax6zZvy4kuNKF+QYS+U0= github.com/stretchr/testify v1.2.2/go.mod h1:a8OnRcib4nhh0OaRAV+Yts87kKdq0PP7pXfy6kDkUVs= github.com/stretchr/testify v1.3.0/go.mod h1:M5WIy9Dh21IEIfnGCwXGc5bZfKNJtfHm1UVUgZn+9EI= github.com/stretchr/testify v1.4.0/go.mod h1:j7eGeouHqKxXV5pUuKE4zz7dFj8WfuZ+81PSLYec5m4= @@ -429,46 +480,47 @@ github.com/stretchr/testify v1.7.0/go.mod h1:6Fq8oRcR53rry900zMqJjRRixrwX3KX962/ github.com/stretchr/testify v1.7.1/go.mod h1:6Fq8oRcR53rry900zMqJjRRixrwX3KX962/h/Wwjteg= github.com/stretchr/testify v1.8.0/go.mod h1:yNjHg4UonilssWZ8iaSj1OCr/vHnekPRkoO+kdMU+MU= github.com/stretchr/testify v1.8.1/go.mod h1:w2LPCIKwWwSfY2zedu0+kehJoqGctiVI29o6fzry7u4= -github.com/stretchr/testify v1.11.1 h1:7s2iGBzp5EwR7/aIZr8ao5+dra3wiQyKjjFuvgVKu7U= -github.com/stretchr/testify v1.11.1/go.mod h1:wZwfW3scLgRK+23gO65QZefKpKQRnfz6sD981Nm4B6U= +github.com/stretchr/testify v1.12.1 h1:EuwCh5fleGS7H32xRwO3wRGT7DxrDhLAT6FF8MpWDWE= +github.com/stretchr/testify v1.12.1/go.mod h1:MDEgiDPPsNp5cuIrHPPCyornHKgEVbtFUmoNlxoYthg= github.com/subosito/gotenv v1.6.0 h1:9NlTDc1FTs4qu0DDq7AEtTPNw6SVm7uBMsUCUjABIf8= github.com/subosito/gotenv v1.6.0/go.mod h1:Dk4QP5c2W3ibzajGcXpNraDfq2IrhjMIvMSWPKKo0FU= -github.com/supranational/blst v0.3.16 h1:bTDadT+3fK497EvLdWRQEjiGnUtzJ7jjIUMF0jqwYhE= -github.com/supranational/blst v0.3.16/go.mod h1:jZJtfjgudtNl4en1tzwPIV3KjUnQUvG3/j+w+fVonLw= +github.com/supranational/blst v0.3.17 h1:OyduggShfN3CWEDdrqChEUZyt1iIsVAFApTKSzqoxAo= +github.com/supranational/blst v0.3.17/go.mod h1:jZJtfjgudtNl4en1tzwPIV3KjUnQUvG3/j+w+fVonLw= github.com/syndtr/goleveldb v1.0.1-0.20210819022825-2ae1ddf74ef7 h1:epCh84lMvA70Z7CTTCmYQn2CKbY8j86K7/FAIr141uY= github.com/syndtr/goleveldb v1.0.1-0.20210819022825-2ae1ddf74ef7/go.mod h1:q4W45IWZaF22tdD+VEXcAWRA037jwmWEB5VWYORlTpc= github.com/tklauser/go-sysconf v0.4.0 h1:7H0uAN+7RkwWRaxhYXDLqa5V3LPrJeV8wmD9dRUgPQU= github.com/tklauser/go-sysconf v0.4.0/go.mod h1:8mTNWyog7H+MpKijp4VmKJAd2bbYQ2zuUwkYRbUArPI= github.com/tklauser/numcpus v0.12.0 h1:NR85qdvHA9pFse3x3weVZ0r0ST8R6l5RHbZrlRaqob4= github.com/tklauser/numcpus v0.12.0/go.mod h1:ABHeXzJnr/qqwguhClkZKT1/8VABcYrsyUiUGobwWJg= -github.com/tyler-smith/go-bip32 v1.0.0 h1:sDR9juArbUgX+bO/iblgZnMPeWY1KZMUC2AFUJdv5KE= -github.com/tyler-smith/go-bip32 v1.0.0/go.mod h1:onot+eHknzV4BVPwrzqY5OoVpyCvnwD7lMawL5aQupE= github.com/tyler-smith/go-bip39 v1.1.0 h1:5eUemwrMargf3BSLRRCalXT93Ns6pQJIjYQN2nyfOP8= github.com/tyler-smith/go-bip39 v1.1.0/go.mod h1:gUYDtqQw1JS3ZJ8UWVcGTGqqr6YIN3CWg+kkNaLt55U= -github.com/ugorji/go/codec v1.2.12 h1:9LC83zGrHhuUA9l16C9AHXAqEV/2wBQ4nkvumAE65EE= -github.com/ugorji/go/codec v1.2.12/go.mod h1:UNopzCgEMSXjBc6AOMqYvWC1ktqTAfzJZUZgYf6w6lg= github.com/urfave/cli/v2 v2.27.5 h1:WoHEJLdsXr6dDWoJgMq/CboDmyY/8HMMH1fTECbih+w= github.com/urfave/cli/v2 v2.27.5/go.mod h1:3Sevf16NykTbInEnD0yKkjDAeZDS0A6bzhBH5hrMvTQ= +github.com/vmware-labs/yaml-jsonpath v0.3.2 h1:/5QKeCBGdsInyDCyVNLbXyilb61MXGi9NP674f9Hobk= +github.com/vmware-labs/yaml-jsonpath v0.3.2/go.mod h1:U6whw1z03QyqgWdgXxvVnQ90zN1BWz5V+51Ewf8k+rQ= +github.com/wlynxg/anet v0.0.5 h1:J3VJGi1gvo0JwZ/P1/Yc/8p63SoW98B5dHkYDmpgvvU= +github.com/wlynxg/anet v0.0.5/go.mod h1:eay5PRQr7fIVAMbTbchTnO9gG65Hg/uYGdc7mguHxoA= github.com/xrash/smetrics v0.0.0-20240521201337-686a1a2994c1 h1:gEOO8jv9F4OT7lGCjxCBTO/36wtF6j2nSip77qHd4x4= github.com/xrash/smetrics v0.0.0-20240521201337-686a1a2994c1/go.mod h1:Ohn+xnUBiLI6FVj/9LpzZWtj1/D6lUovWYBkxHVV3aM= +github.com/yuin/goldmark v1.2.1/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9decYSb74= github.com/yuin/goldmark v1.4.13/go.mod h1:6yULJ656Px+3vBD8DxQVa3kxgyrAnzto9xy5taEt/CY= github.com/yusufpapurcu/wmi v1.2.4 h1:zFUKzehAFReQwLys1b/iSMl+JQGSCSjtVqQn9bBrPo0= github.com/yusufpapurcu/wmi v1.2.4/go.mod h1:SBZ9tNy3G9/m5Oi98Zks0QjeHVDvuK0qfxQmPyzfmi0= github.com/zenazn/goji v0.9.0/go.mod h1:7S9M489iMyHBNxwZnk9/EHS098H4/F6TATF2mIxtB1Q= -go.mongodb.org/mongo-driver v1.17.9 h1:IexDdCuuNJ3BHrELgBlyaH9p60JXAvdzWR128q+U5tU= -go.mongodb.org/mongo-driver v1.17.9/go.mod h1:LlOhpH5NUEfhxcAwG0UEkMqwYcc4JU18gtCdGudk/tQ= +go.mongodb.org/mongo-driver v1.17.10 h1:kdAgQvu8TROXZpSkJQd5wzfaNCCrMbpZyKFtQ6qkPCE= +go.mongodb.org/mongo-driver v1.17.10/go.mod h1:LlOhpH5NUEfhxcAwG0UEkMqwYcc4JU18gtCdGudk/tQ= go.opentelemetry.io/auto/sdk v1.2.1 h1:jXsnJ4Lmnqd11kwkBV2LgLoFMZKizbCi5fNZ/ipaZ64= go.opentelemetry.io/auto/sdk v1.2.1/go.mod h1:KRTj+aOaElaLi+wW1kO/DZRXwkF4C5xPbEe3ZiIhN7Y= -go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp v0.61.0 h1:F7Jx+6hwnZ41NSFTO5q4LYDtJRXBf2PD0rNBkeB/lus= -go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp v0.61.0/go.mod h1:UHB22Z8QsdRDrnAtX4PntOl36ajSxcdUMt1sF7Y6E7Q= -go.opentelemetry.io/otel v1.44.0 h1:JjwHmHpA4iZ3wBxluu2fbbE7j4kqlE8jXyAyPXH7HqU= -go.opentelemetry.io/otel v1.44.0/go.mod h1:BMgjTHL9WPRlRjL2oZCBTL4whCGtXch2H4BhOPIAyYc= -go.opentelemetry.io/otel/metric v1.44.0 h1:1w0gILTcHdr3YI+ixLyjemwrVnsMURbTZFrSYCdDdmc= -go.opentelemetry.io/otel/metric v1.44.0/go.mod h1:8O7hanEPBNgEMmybD3s2VBKcgWOCsA6tzHBPODAiquo= -go.opentelemetry.io/otel/sdk v1.40.0 h1:KHW/jUzgo6wsPh9At46+h4upjtccTmuZCFAc9OJ71f8= -go.opentelemetry.io/otel/sdk v1.40.0/go.mod h1:Ph7EFdYvxq72Y8Li9q8KebuYUr2KoeyHx0DRMKrYBUE= -go.opentelemetry.io/otel/trace v1.44.0 h1:jxF5CsGYCe74MCRx2X4g7WsY/VBKRqqpNvXlX/6gtIk= -go.opentelemetry.io/otel/trace v1.44.0/go.mod h1:oLl1jrMQAVo6v3GAggN+1VH9VIz9iUSvW53sW1Q8PIE= +go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp v0.69.0 h1:8tvICD4vSTOOsNrsI4Ljf6C+6UKvpTEH5XY3JMoyPoo= +go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp v0.69.0/go.mod h1:z9+yiacE0IHRqM4qFfkbt/JYlmYXgss8GY/jXoNuPJI= +go.opentelemetry.io/otel v1.46.0 h1:FHt5/CDyVxi/8IM1CH7VE/rRgq3kLHa2mSTVMO8AWyc= +go.opentelemetry.io/otel v1.46.0/go.mod h1:Gj3SEScelsNC45tp4nSxRYlS+f5iez7W8XPMCt905kE= +go.opentelemetry.io/otel/metric v1.46.0 h1:yBnkXvgV7AXFILZc5K6IZe/CBFF3OS7BJ8ov6/lj0K8= +go.opentelemetry.io/otel/metric v1.46.0/go.mod h1:iPmdWqifKUdzziPkvvzIJXITl56fQx2mGM/DHLB3/2o= +go.opentelemetry.io/otel/sdk v1.46.0 h1:h5CNQQjEbuQXY/JfZtgt3i7HVFV3aHPO2OAwO2eTYPI= +go.opentelemetry.io/otel/sdk v1.46.0/go.mod h1:GAERFXFt5SYCEB+YiKUbMBeza6UaDH7GmGOZEfh2gSM= +go.opentelemetry.io/otel/trace v1.46.0 h1:OULy7ccdJnZtJ0UDYFOIGaCmiWzJ8Vi2G/Rsu60qs1c= +go.opentelemetry.io/otel/trace v1.46.0/go.mod h1:J7GAXweO77XSFkB/rmAqk9D6ihszhFjLU+d9WuUxDLI= go.uber.org/atomic v1.3.2/go.mod h1:gD2HeocX3+yG+ygLZcrzQJaqmWj9AIm7n08wl/qW/PE= go.uber.org/atomic v1.4.0/go.mod h1:gD2HeocX3+yG+ygLZcrzQJaqmWj9AIm7n08wl/qW/PE= go.uber.org/atomic v1.5.0/go.mod h1:sABNBOSYdrvTF6hTgEIbc7YasKWGhgEQZyfxyTvoXHQ= @@ -480,9 +532,9 @@ go.uber.org/tools v0.0.0-20190618225709-2cfd321de3ee/go.mod h1:vJERXedbb3MVM5f9E go.uber.org/zap v1.9.1/go.mod h1:vwi/ZaCAaUcBkycHslxD9B2zi4UTXhF60s6SWpuDF0Q= go.uber.org/zap v1.10.0/go.mod h1:vwi/ZaCAaUcBkycHslxD9B2zi4UTXhF60s6SWpuDF0Q= go.uber.org/zap v1.13.0/go.mod h1:zwrFLgMcdUuIBviXEYEH1YKNaOBnKXsx2IPda5bBwHM= -go.yaml.in/yaml/v3 v3.0.4 h1:tfq32ie2Jv2UxXFdLJdh3jXuOzWiL1fo0bu/FbuKpbc= go.yaml.in/yaml/v3 v3.0.4/go.mod h1:DhzuOOF2ATzADvBadXxruRBLzYTpT36CKvDb3+aBEFg= -golang.org/x/crypto v0.0.0-20170613210332-850760c427c5/go.mod h1:6SG95UA2DQfeDnfUPMdvaQW0Q7yPrPDi9nlGo2tz2b4= +go.yaml.in/yaml/v3 v3.0.5 h1:N6y/pJk8buWs9NY5ERU2HSMfm+IuD/OtfdAnq6kESPw= +go.yaml.in/yaml/v3 v3.0.5/go.mod h1:HVTZu1O7/Vkt2N+BFy8Zza+lnLsABggaTM2ZpNIGuKg= golang.org/x/crypto v0.0.0-20190308221718-c2843e01d9a2/go.mod h1:djNgcEr1/C05ACkg1iLfiJU5Ep61QUkGW8qpdssI0+w= golang.org/x/crypto v0.0.0-20190411191339-88737f569e3a/go.mod h1:WFFai1msRO1wXaEeE5yQxYXgSfI8pQAWXbQop6sCtWE= golang.org/x/crypto v0.0.0-20190510104115-cbcb75029529/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI= @@ -495,54 +547,72 @@ golang.org/x/crypto v0.0.0-20210711020723-a769d52b0f97/go.mod h1:GvvjBRRGRdwPK5y golang.org/x/crypto v0.0.0-20210921155107-089bfa567519/go.mod h1:GvvjBRRGRdwPK5ydBHafDWAxML/pGHZbMvKqRZ5+Abc= golang.org/x/crypto v0.19.0/go.mod h1:Iy9bg/ha4yyC70EfRS8jz+B6ybOBKMaSxLj6P6oBDfU= golang.org/x/crypto v0.20.0/go.mod h1:Xwo95rrVNIoSMx9wa1JroENMToLWn3RNVrTBpLHgZPQ= -golang.org/x/crypto v0.52.0 h1:RMs7fP2rXdep0CftQlK8Uf+kibLm7qkCcradZWYz988= -golang.org/x/crypto v0.52.0/go.mod h1:1QgfPxDqh0T2M/elOJtp9RvuR95kVjir0e6/BvEmGbc= +golang.org/x/crypto v0.57.0 h1:3ZVCjf8Ggz7zneR/EHRVx68Ctf+2pmIMP2UFhh9cC6M= +golang.org/x/crypto v0.57.0/go.mod h1:Fdz0i5U6CoizGwLda9DttjSk6qlZo25zYNtR+ycvuZA= golang.org/x/exp v0.0.0-20250305212735-054e65f0b394 h1:nDVHiLt8aIbd/VzvPWN6kSOPE7+F/fNFDSXLVYkE/Iw= golang.org/x/exp v0.0.0-20250305212735-054e65f0b394/go.mod h1:sIifuuw/Yco/y6yb6+bDNfyeQ/MdPUy/hKEMYQV17cM= golang.org/x/lint v0.0.0-20190930215403-16217165b5de/go.mod h1:6SW0HCj/g11FgYtHlgUYUwCkIfeOF89ocIRzGO/8vkc= golang.org/x/mod v0.0.0-20190513183733-4bf6d317e70e/go.mod h1:mXi4GBBbnImb6dmsKGUJ2LatrhH/nqhxcFungHvyanc= golang.org/x/mod v0.1.1-0.20191105210325-c90efee705ee/go.mod h1:QqPTAvyqsEbceGzBzNggFXnrqF1CaUcvgkdR5Ot7KZg= +golang.org/x/mod v0.3.0/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA= golang.org/x/mod v0.6.0-dev.0.20220419223038-86c51ed26bb4/go.mod h1:jJ57K6gSWd91VN4djpZkiMVwK6gcyfeH4XE8wZrZaV4= golang.org/x/mod v0.8.0/go.mod h1:iBbtSCu2XBx23ZKBPSOrRkjjQPZFPuis4dIYUhu/chs= -golang.org/x/mod v0.35.0 h1:Ww1D637e6Pg+Zb2KrWfHQUnH2dQRLBQyAtpr/haaJeM= -golang.org/x/mod v0.35.0/go.mod h1:+GwiRhIInF8wPm+4AoT6L0FA1QWAad3OMdTRx4tFYlU= +golang.org/x/mod v0.41.0 h1:qJmnOUb4YB+FsEuM3HcWucdZASCPGhsX6uljO6pog0c= +golang.org/x/mod v0.41.0/go.mod h1:Ek9pY8RKWXwsWvd3rQiHYtMqkjSUV+s1Rj7j4H5Ur6o= +golang.org/x/net v0.0.0-20180906233101-161cd47e91fd/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= golang.org/x/net v0.0.0-20190311183353-d8887717615a/go.mod h1:t9HGtf8HONx5eT2rtn7q6eTqICYqUVnKs3thJo3Qplg= golang.org/x/net v0.0.0-20190404232315-eb5bcb51f2a3/go.mod h1:t9HGtf8HONx5eT2rtn7q6eTqICYqUVnKs3thJo3Qplg= golang.org/x/net v0.0.0-20190620200207-3b0461eec859/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= golang.org/x/net v0.0.0-20190813141303-74dc4d7220e7/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= +golang.org/x/net v0.0.0-20200520004742-59133d7f0dd7/go.mod h1:qpuaurCH72eLCgpAm/N6yyVIVM9cpaDIP3A8BGJEC5A= +golang.org/x/net v0.0.0-20201021035429-f5854403a974/go.mod h1:sp8m0HH+o8qH0wwXwYZr8TS3Oi6o0r6Gce1SSxlDquU= golang.org/x/net v0.0.0-20210226172049-e18ecbb05110/go.mod h1:m0MpNAwzfU5UDzcl9v0D8zg8gWTRqZa9RBIspLL5mdg= +golang.org/x/net v0.0.0-20210428140749-89ef3d95e781/go.mod h1:OJAsFXCWl8Ukc7SiCT/9KSuxbyM7479/AVlXFRxuMCk= +golang.org/x/net v0.0.0-20220225172249-27dd8689420f/go.mod h1:CfG3xpIq0wQ8r1q4Su4UZFWDARRcnwPjda9FqA0JpMk= golang.org/x/net v0.0.0-20220722155237-a158d28d115b/go.mod h1:XRhObCWvk6IyKnWLug+ECip1KBveYUHfp+8e9klMJ9c= golang.org/x/net v0.6.0/go.mod h1:2Tu9+aMcznHK/AK1HMvgo6xiTLG5rD5rZLDS+rp2Bjs= golang.org/x/net v0.10.0/go.mod h1:0qNGK6F8kojg2nk9dLZ2mShWaEBan6FAoqfSigmmuDg= golang.org/x/net v0.21.0/go.mod h1:bIjVDfnllIU7BJ2DNgfnXvpSvtn8VRwhlsaeUTyUS44= -golang.org/x/net v0.54.0 h1:2zJIZAxAHV/OHCDTCOHAYehQzLfSXuf/5SoL/Dv6w/w= -golang.org/x/net v0.54.0/go.mod h1:Sj4oj8jK6XmHpBZU/zWHw3BV3abl4Kvi+Ut7cQcY+cQ= +golang.org/x/net v0.58.0 h1:ynWG7rqYi4ccpTEuPZ2QGWHktVEM9DMCj9yzDE0Q7To= +golang.org/x/net v0.58.0/go.mod h1:YwCddHnFlT7eLQqVprV19OnhLGtc5xOKgE0RyqgfWAU= +golang.org/x/sync v0.0.0-20180314180146-1d60e4601c6f/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.0.0-20190423024810-112230192c58/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= +golang.org/x/sync v0.0.0-20201020160332-67f06af15bc9/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.0.0-20220722155255-886fb9371eb4/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.1.0/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= -golang.org/x/sync v0.20.0 h1:e0PTpb7pjO8GAtTs2dQ6jYa5BWYlMuX047Dco/pItO4= -golang.org/x/sync v0.20.0/go.mod h1:9xrNwdLfx4jkKbNva9FpL6vEN7evnE43NNNJQ2LF3+0= +golang.org/x/sync v0.23.0 h1:KameEIfc1IkluZyXWLn39Wd4tURc6GbCiISGiZm2bQk= +golang.org/x/sync v0.23.0/go.mod h1:sUUOizhqBxiL6pEWpqNLUiaJn1ShEbZ6BBqskPbjZm0= golang.org/x/sys v0.0.0-20180905080454-ebe1bf3edb33/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= +golang.org/x/sys v0.0.0-20180909124046-d0be0721c37e/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= golang.org/x/sys v0.0.0-20190215142949-d0b11bdaac8a/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= golang.org/x/sys v0.0.0-20190222072716-a9d3bda3a223/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= golang.org/x/sys v0.0.0-20190403152447-81d4e9dc473e/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20190412213103-97732733099d/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20190422165155-953cdadca894/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20190813064441-fde4db37ae7a/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= +golang.org/x/sys v0.0.0-20190904154756-749cb33beabd/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20190916202348-b4ddaad3f8a3/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= +golang.org/x/sys v0.0.0-20191005200804-aed5e4c7ecf9/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20191026070338-33540a1f6037/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= +golang.org/x/sys v0.0.0-20191120155948-bd437916bb0e/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= +golang.org/x/sys v0.0.0-20191204072324-ce4227a45e2e/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20200116001909-b77594299b42/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20200223170610-d5e6a3e2c0ae/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= +golang.org/x/sys v0.0.0-20200323222414-85ca7c5b95cd/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= +golang.org/x/sys v0.0.0-20200930185726-fdedc70b468f/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20201119102817-f84b799fce68/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= +golang.org/x/sys v0.0.0-20210112080510-489259a85091/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= +golang.org/x/sys v0.0.0-20210423082822-04245dca01da/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20210615035016-665e8c7367d1/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= +golang.org/x/sys v0.0.0-20211216021012-1d35b9e2eb4e/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20220520151302-bc2c85ada10a/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20220722155257-8c9f86f7a55f/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.1.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.5.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.8.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.17.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA= -golang.org/x/sys v0.45.0 h1:dO4czNzziLiiXplLQgBCEpCvXQ3dnkn0SdaZSYdQ+FY= -golang.org/x/sys v0.45.0/go.mod h1:4GL1E5IUh+htKOUEOaiffhrAeqysfVGipDYzABqnCmw= +golang.org/x/sys v0.48.0 h1:bbX/i/6MgT9BVLM9RT1thmxL04yeTAhbEz4SyadbXoo= +golang.org/x/sys v0.48.0/go.mod h1:hNLxWAXmnKAxqDtdwIYC4bM9oQPEecfsnNMuSxOs3og= golang.org/x/term v0.0.0-20201117132131-f5c789dd3221/go.mod h1:Nr5EML6q2oocZ2LXRh80K7BxOlk5/8JxuGnuhpl+muw= golang.org/x/term v0.0.0-20201126162022-7de9c90e9dd1/go.mod h1:bj7SfCRtBDWHUb9snDiAeCFNEtKQo2Wmx5Cou7ajbmo= golang.org/x/term v0.0.0-20210927222741-03fcf44c2211/go.mod h1:jbD1KX2456YbFQfuXm/mYQcufACuNUgVhRMnK/tPxf8= @@ -558,10 +628,10 @@ golang.org/x/text v0.3.7/go.mod h1:u+2+/6zg+i71rQMx5EYifcz6MCKuco9NR6JIITiCfzQ= golang.org/x/text v0.7.0/go.mod h1:mrYo+phRRbMaCq/xk9113O4dZlRixOauAjOtrjsXDZ8= golang.org/x/text v0.9.0/go.mod h1:e1OnstbJyHTd6l/uOt8jFFHp6TRDWZR/bV3emEE/zU8= golang.org/x/text v0.14.0/go.mod h1:18ZOQIKpY8NJVqYksKHtTdi31H5itFRjB5/qKTNYzSU= -golang.org/x/text v0.37.0 h1:Cqjiwd9eSg8e0QAkyCaQTNHFIIzWtidPahFWR83rTrc= -golang.org/x/text v0.37.0/go.mod h1:a5sjxXGs9hsn/AJVwuElvCAo9v8QYLzvavO5z2PiM38= -golang.org/x/time v0.14.0 h1:MRx4UaLrDotUKUdCIqzPC48t1Y9hANFKIRpNx+Te8PI= -golang.org/x/time v0.14.0/go.mod h1:eL/Oa2bBBK0TkX57Fyni+NgnyQQN4LitPmob2Hjnqw4= +golang.org/x/text v0.42.0 h1:JbOZXgfeCPU9gacVtYliJqOhD+zhrEqK4LfdpmlUZqI= +golang.org/x/text v0.42.0/go.mod h1:ojzP1Z+2QtioaF8DTtO8K5q7JWVVYwZKenzujK0Zd0E= +golang.org/x/time v0.15.0 h1:bbrp8t3bGUeFOx08pvsMYRTCVSMk89u4tKbNOZbp88U= +golang.org/x/time v0.15.0/go.mod h1:Y4YMaQmXwGQZoFaVFk4YpCt4FLQMYKZe9oeV/f4MSno= golang.org/x/tools v0.0.0-20180917221912-90fa682c2a6e/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ= golang.org/x/tools v0.0.0-20190311212946-11955173bddd/go.mod h1:LCzVGOaR6xXOjkQ3onu1FJEFr0SW1gC7cKk1uF8kGRs= golang.org/x/tools v0.0.0-20190425163242-31fd60d6bfdc/go.mod h1:RgjU9mgBXZiqYHBnxXauZ1Gv1EHHAz9KjViQ78xBX0Q= @@ -571,32 +641,47 @@ golang.org/x/tools v0.0.0-20191029041327-9cc4af7d6b2c/go.mod h1:b+2E5dAYhXwXZwtn golang.org/x/tools v0.0.0-20191029190741-b9c20aec41a5/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo= golang.org/x/tools v0.0.0-20191119224855-298f0cb1881e/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo= golang.org/x/tools v0.0.0-20200103221440-774c71fcf114/go.mod h1:TB2adYChydJhpapKDTa4BR/hXlZSLoq2Wpct/0txZ28= +golang.org/x/tools v0.0.0-20201224043029-2b0845dc783e/go.mod h1:emZCQorbCU4vsT4fOWvOPXz4eW1wZW4PmDk9uLelYpA= golang.org/x/tools v0.1.12/go.mod h1:hNGJHUnrk76NpqgfD5Aqm5Crs+Hm0VOH/i9J2+nxYbc= golang.org/x/tools v0.6.0/go.mod h1:Xwgl3UAJ/d3gWutnCtw505GrjyAbvKui8lOU390QaIU= -golang.org/x/tools v0.44.0 h1:UP4ajHPIcuMjT1GqzDWRlalUEoY+uzoZKnhOjbIPD2c= -golang.org/x/tools v0.44.0/go.mod h1:KA0AfVErSdxRZIsOVipbv3rQhVXTnlU6UhKxHd1seDI= +golang.org/x/tools v0.49.0 h1:3NI7VXzL9+1WZD52Dx2ttoPwD5DWrFGpl9mFZDlmisI= +golang.org/x/tools v0.49.0/go.mod h1:SJNXV9DBKT0UbdttsQjbfJlAE/q+y36++zo3uL3N0Oo= golang.org/x/xerrors v0.0.0-20190410155217-1f06c39b4373/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= golang.org/x/xerrors v0.0.0-20190513163551-3ee3066db522/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= golang.org/x/xerrors v0.0.0-20190717185122-a985d3407aa7/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= golang.org/x/xerrors v0.0.0-20191011141410-1b5146add898/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= +golang.org/x/xerrors v0.0.0-20191204190536-9bdfabe68543/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= golang.org/x/xerrors v0.0.0-20200804184101-5ec99f83aff1/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= -google.golang.org/protobuf v1.36.11 h1:fV6ZwhNocDyBLK0dj+fg8ektcVegBBuEolpbTQyBNVE= -google.golang.org/protobuf v1.36.11/go.mod h1:HTf+CrKn2C3g5S8VImy6tdcUvCska2kB7j23XfzDpco= +google.golang.org/protobuf v0.0.0-20200109180630-ec00e32a8dfd/go.mod h1:DFci5gLYBciE7Vtevhsrf46CRTquxDuWsQurQQe4oz8= +google.golang.org/protobuf v0.0.0-20200221191635-4d8936d0db64/go.mod h1:kwYJMbMJ01Woi6D6+Kah6886xMZcty6N08ah7+eCXa0= +google.golang.org/protobuf v0.0.0-20200228230310-ab0ca4ff8a60/go.mod h1:cfTl7dwQJ+fmap5saPgwCLgHXTUD7jkjRqWcaiX5VyM= +google.golang.org/protobuf v1.20.1-0.20200309200217-e05f789c0967/go.mod h1:A+miEFZTKqfCUM6K7xSMQL9OKL/b6hQv+e19PK+JZNE= +google.golang.org/protobuf v1.21.0/go.mod h1:47Nbq4nVaFHyn7ilMalzfO3qCViNmqZ2kzikPIcrTAo= +google.golang.org/protobuf v1.23.0/go.mod h1:EGpADcykh3NcUnDUJcl1+ZksZNG86OlYog2l/sGQquU= +google.golang.org/protobuf v1.26.0-rc.1/go.mod h1:jlhhOSvTdKEhbULTjvd4ARK9grFBp09yW+WbY/TyQbw= +google.golang.org/protobuf v1.26.0/go.mod h1:9q0QmTI4eRPtz6boOQmLYwt+qCgq0jsYwAQnmE0givc= +google.golang.org/protobuf v1.36.12 h1:pJOKDDOyeXErUroCihFAd5LQuwXBSpVnKGrj5o/fwxc= +google.golang.org/protobuf v1.36.12/go.mod h1:HTf+CrKn2C3g5S8VImy6tdcUvCska2kB7j23XfzDpco= gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0= gopkg.in/check.v1 v1.0.0-20180628173108-788fd7840127/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0= +gopkg.in/check.v1 v1.0.0-20190902080502-41f04d3bba15/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0= gopkg.in/check.v1 v1.0.0-20201130134442-10cb98267c6c h1:Hei/4ADfdWqJk1ZMxUNpqntNwaWcugrBjAiHlqqRiVk= gopkg.in/check.v1 v1.0.0-20201130134442-10cb98267c6c/go.mod h1:JHkPIbrfpd72SG/EVd6muEfDQjcINNoR0C8j2r3qZ4Q= gopkg.in/errgo.v2 v2.1.0/go.mod h1:hNsd1EY+bozCKY1Ytp96fpM3vjJbqLJn88ws8XvfDNI= +gopkg.in/fsnotify.v1 v1.4.7/go.mod h1:Tz8NjZHkW78fSQdbUxIjBTcgA1z1m8ZHf0WmKUhAMys= gopkg.in/inconshreveable/log15.v2 v2.0.0-20180818164646-67afb5ed74ec/go.mod h1:aPpfJ7XW+gOuirDoZ8gHhLh3kZ1B08FtV2bbmy7Jv3s= gopkg.in/natefinch/lumberjack.v2 v2.2.1 h1:bBRl1b0OH9s/DuPhuXpNl+VtCaJXFZ5/uEFST95x9zc= gopkg.in/natefinch/lumberjack.v2 v2.2.1/go.mod h1:YD8tP3GAjkrDg1eZH7EGmyESg/lsYskCTPBJVb9jqSc= +gopkg.in/tomb.v1 v1.0.0-20141024135613-dd632973f1e7 h1:uRGJdciOHaEIrze2W8Q3AKkepLTh2hOroT7a+7czfdQ= +gopkg.in/tomb.v1 v1.0.0-20141024135613-dd632973f1e7/go.mod h1:dt/ZhP58zS4L8KSrWDmTeBkI65Dw0HsyUHuEVlX15mw= +gopkg.in/yaml.v2 v2.2.1/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI= gopkg.in/yaml.v2 v2.2.2/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI= +gopkg.in/yaml.v2 v2.2.4/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI= +gopkg.in/yaml.v2 v2.3.0/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI= gopkg.in/yaml.v2 v2.4.0 h1:D8xgwECY7CYvx+Y2n4sBz93Jn9JRvxdiyyo8CTfuKaY= gopkg.in/yaml.v2 v2.4.0/go.mod h1:RDklbk79AGWmwhnvt/jBztapEOGDOx6ZbXqjP6csGnQ= +gopkg.in/yaml.v3 v3.0.0-20191026110619-0b21df46bc1d/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM= gopkg.in/yaml.v3 v3.0.0-20200313102051-9f266ea9e77c/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM= -gopkg.in/yaml.v3 v3.0.0/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM= gopkg.in/yaml.v3 v3.0.1 h1:fxVm/GzAzEWqLHuvctI91KS9hhNmmWOoWu0XTYJS7CA= gopkg.in/yaml.v3 v3.0.1/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM= honnef.co/go/tools v0.0.1-2019.2.3/go.mod h1:a3bituU0lyd329TUQxRnasdCoJDkEUEAqEt0JzvZhAg= -launchpad.net/gocheck v0.0.0-20140225173054-000000000087 h1:Izowp2XBH6Ya6rv+hqbceQyw/gSGoXfH/UPoTGduL54= -launchpad.net/gocheck v0.0.0-20140225173054-000000000087/go.mod h1:hj7XX3B/0A+80Vse0e+BUHsHMTEhd0O4cpUHr/e/BUM= diff --git a/internal/claimer/fixtures_test.go b/internal/claimer/fixtures_test.go index 0de5bc678..d703db843 100644 --- a/internal/claimer/fixtures_test.go +++ b/internal/claimer/fixtures_test.go @@ -58,7 +58,7 @@ func newServiceMock(t *testing.T) (*Service, *claimerRepositoryMock, *claimerBlo // RFC3339 with milliseconds and without timezone TimeFormat: "2006-01-02T15:04:05.000", } - handler := tint.NewHandler(os.Stdout, opts) + handler := tint.NewTextHandler(os.Stdout, opts) repository := &claimerRepositoryMock{} blockchain := &claimerBlockchainMock{ submitterAddress: common.HexToAddress("0x0000000000000000000000000000000000000001"), diff --git a/internal/config/config.go b/internal/config/config.go index cd812b80a..55039738f 100644 --- a/internal/config/config.go +++ b/internal/config/config.go @@ -294,9 +294,30 @@ func ToURLFromString(s string) (SafeURL, error) { if err != nil { return SafeURL{}, fmt.Errorf("invalid URL [Redacted]") } + if result.Scheme == "postgres" || result.Scheme == "postgresql" { + if err := checkDatabaseURL(s, result); err != nil { + return SafeURL{}, err + } + } return NewSafeURL(result), nil } +// checkDatabaseURL rejects the database URLs that the node's database libraries +// read differently. From v5.11, pgx reads a URL like libpq: the last of repeated +// parameters wins, and '#' is part of the text. net/url, and the lib/pq driver of +// the migrations, take the first parameter and cut the URL at '#'. +func checkDatabaseURL(raw string, u *url.URL) error { + if strings.Contains(raw, "#") { + return errors.New("invalid database URL [Redacted]: encode '#' as %23") + } + for key, values := range u.Query() { + if len(values) > 1 { + return fmt.Errorf("invalid database URL [Redacted]: parameter %q is repeated", key) + } + } + return nil +} + // Service name constants for per-service configuration lookup. const ( ServiceNode = "node" diff --git a/internal/config/config_test.go b/internal/config/config_test.go index ce6da34a5..499555c36 100644 --- a/internal/config/config_test.go +++ b/internal/config/config_test.go @@ -127,6 +127,31 @@ func TestSafeURL(t *testing.T) { require.Error(t, err) require.Equal(t, "[REDACTED]", safe.String()) }) + + t.Run("ToURLFromString rejects ambiguous database URLs", func(t *testing.T) { + for _, raw := range []string{ + "postgres://user:s3cr#t@db:5432/rollups", + "postgres://user:s3cret@db:5432/rollups#", + "postgresql://user:s3cret@db:5432/rollups?sslmode=require&sslmode=disable", + } { + safe, err := ToURLFromString(raw) + require.Error(t, err, raw) + require.NotContains(t, err.Error(), "s3cr") + require.Equal(t, "[REDACTED]", safe.String()) + } + }) + + t.Run("ToURLFromString accepts encoded database URLs", func(t *testing.T) { + safe, err := ToURLFromString("postgres://user:s3cr%23t@db:5432/rollups?sslmode=require&connect_timeout=5") + require.NoError(t, err) + require.Equal(t, "postgres://db:5432", safe.String()) + }) + + t.Run("ToURLFromString keeps other schemes unchanged", func(t *testing.T) { + safe, err := ToURLFromString("https://host.example/path?key=a&key=b#fragment") + require.NoError(t, err) + require.Equal(t, "https://host.example", safe.String()) + }) } func TestEvmReaderReadyMaxStaleness(t *testing.T) { diff --git a/licenses/GPL-3.0.txt b/licenses/GPL-3.0.txt new file mode 100644 index 000000000..f288702d2 --- /dev/null +++ b/licenses/GPL-3.0.txt @@ -0,0 +1,674 @@ + GNU GENERAL PUBLIC LICENSE + Version 3, 29 June 2007 + + Copyright (C) 2007 Free Software Foundation, Inc. + Everyone is permitted to copy and distribute verbatim copies + of this license document, but changing it is not allowed. + + Preamble + + The GNU General Public License is a free, copyleft license for +software and other kinds of works. + + The licenses for most software and other practical works are designed +to take away your freedom to share and change the works. By contrast, +the GNU General Public License is intended to guarantee your freedom to +share and change all versions of a program--to make sure it remains free +software for all its users. We, the Free Software Foundation, use the +GNU General Public License for most of our software; it applies also to +any other work released this way by its authors. You can apply it to +your programs, too. + + When we speak of free software, we are referring to freedom, not +price. Our General Public Licenses are designed to make sure that you +have the freedom to distribute copies of free software (and charge for +them if you wish), that you receive source code or can get it if you +want it, that you can change the software or use pieces of it in new +free programs, and that you know you can do these things. + + To protect your rights, we need to prevent others from denying you +these rights or asking you to surrender the rights. Therefore, you have +certain responsibilities if you distribute copies of the software, or if +you modify it: responsibilities to respect the freedom of others. + + For example, if you distribute copies of such a program, whether +gratis or for a fee, you must pass on to the recipients the same +freedoms that you received. You must make sure that they, too, receive +or can get the source code. And you must show them these terms so they +know their rights. + + Developers that use the GNU GPL protect your rights with two steps: +(1) assert copyright on the software, and (2) offer you this License +giving you legal permission to copy, distribute and/or modify it. + + For the developers' and authors' protection, the GPL clearly explains +that there is no warranty for this free software. For both users' and +authors' sake, the GPL requires that modified versions be marked as +changed, so that their problems will not be attributed erroneously to +authors of previous versions. + + Some devices are designed to deny users access to install or run +modified versions of the software inside them, although the manufacturer +can do so. This is fundamentally incompatible with the aim of +protecting users' freedom to change the software. The systematic +pattern of such abuse occurs in the area of products for individuals to +use, which is precisely where it is most unacceptable. Therefore, we +have designed this version of the GPL to prohibit the practice for those +products. If such problems arise substantially in other domains, we +stand ready to extend this provision to those domains in future versions +of the GPL, as needed to protect the freedom of users. + + Finally, every program is threatened constantly by software patents. +States should not allow patents to restrict development and use of +software on general-purpose computers, but in those that do, we wish to +avoid the special danger that patents applied to a free program could +make it effectively proprietary. To prevent this, the GPL assures that +patents cannot be used to render the program non-free. + + The precise terms and conditions for copying, distribution and +modification follow. + + TERMS AND CONDITIONS + + 0. Definitions. + + "This License" refers to version 3 of the GNU General Public License. + + "Copyright" also means copyright-like laws that apply to other kinds of +works, such as semiconductor masks. + + "The Program" refers to any copyrightable work licensed under this +License. Each licensee is addressed as "you". "Licensees" and +"recipients" may be individuals or organizations. + + To "modify" a work means to copy from or adapt all or part of the work +in a fashion requiring copyright permission, other than the making of an +exact copy. The resulting work is called a "modified version" of the +earlier work or a work "based on" the earlier work. + + A "covered work" means either the unmodified Program or a work based +on the Program. + + To "propagate" a work means to do anything with it that, without +permission, would make you directly or secondarily liable for +infringement under applicable copyright law, except executing it on a +computer or modifying a private copy. Propagation includes copying, +distribution (with or without modification), making available to the +public, and in some countries other activities as well. + + To "convey" a work means any kind of propagation that enables other +parties to make or receive copies. Mere interaction with a user through +a computer network, with no transfer of a copy, is not conveying. + + An interactive user interface displays "Appropriate Legal Notices" +to the extent that it includes a convenient and prominently visible +feature that (1) displays an appropriate copyright notice, and (2) +tells the user that there is no warranty for the work (except to the +extent that warranties are provided), that licensees may convey the +work under this License, and how to view a copy of this License. If +the interface presents a list of user commands or options, such as a +menu, a prominent item in the list meets this criterion. + + 1. Source Code. + + The "source code" for a work means the preferred form of the work +for making modifications to it. "Object code" means any non-source +form of a work. + + A "Standard Interface" means an interface that either is an official +standard defined by a recognized standards body, or, in the case of +interfaces specified for a particular programming language, one that +is widely used among developers working in that language. + + The "System Libraries" of an executable work include anything, other +than the work as a whole, that (a) is included in the normal form of +packaging a Major Component, but which is not part of that Major +Component, and (b) serves only to enable use of the work with that +Major Component, or to implement a Standard Interface for which an +implementation is available to the public in source code form. A +"Major Component", in this context, means a major essential component +(kernel, window system, and so on) of the specific operating system +(if any) on which the executable work runs, or a compiler used to +produce the work, or an object code interpreter used to run it. + + The "Corresponding Source" for a work in object code form means all +the source code needed to generate, install, and (for an executable +work) run the object code and to modify the work, including scripts to +control those activities. However, it does not include the work's +System Libraries, or general-purpose tools or generally available free +programs which are used unmodified in performing those activities but +which are not part of the work. For example, Corresponding Source +includes interface definition files associated with source files for +the work, and the source code for shared libraries and dynamically +linked subprograms that the work is specifically designed to require, +such as by intimate data communication or control flow between those +subprograms and other parts of the work. + + The Corresponding Source need not include anything that users +can regenerate automatically from other parts of the Corresponding +Source. + + The Corresponding Source for a work in source code form is that +same work. + + 2. Basic Permissions. + + All rights granted under this License are granted for the term of +copyright on the Program, and are irrevocable provided the stated +conditions are met. This License explicitly affirms your unlimited +permission to run the unmodified Program. The output from running a +covered work is covered by this License only if the output, given its +content, constitutes a covered work. This License acknowledges your +rights of fair use or other equivalent, as provided by copyright law. + + You may make, run and propagate covered works that you do not +convey, without conditions so long as your license otherwise remains +in force. You may convey covered works to others for the sole purpose +of having them make modifications exclusively for you, or provide you +with facilities for running those works, provided that you comply with +the terms of this License in conveying all material for which you do +not control copyright. Those thus making or running the covered works +for you must do so exclusively on your behalf, under your direction +and control, on terms that prohibit them from making any copies of +your copyrighted material outside their relationship with you. + + Conveying under any other circumstances is permitted solely under +the conditions stated below. Sublicensing is not allowed; section 10 +makes it unnecessary. + + 3. Protecting Users' Legal Rights From Anti-Circumvention Law. + + No covered work shall be deemed part of an effective technological +measure under any applicable law fulfilling obligations under article +11 of the WIPO copyright treaty adopted on 20 December 1996, or +similar laws prohibiting or restricting circumvention of such +measures. + + When you convey a covered work, you waive any legal power to forbid +circumvention of technological measures to the extent such circumvention +is effected by exercising rights under this License with respect to +the covered work, and you disclaim any intention to limit operation or +modification of the work as a means of enforcing, against the work's +users, your or third parties' legal rights to forbid circumvention of +technological measures. + + 4. Conveying Verbatim Copies. + + You may convey verbatim copies of the Program's source code as you +receive it, in any medium, provided that you conspicuously and +appropriately publish on each copy an appropriate copyright notice; +keep intact all notices stating that this License and any +non-permissive terms added in accord with section 7 apply to the code; +keep intact all notices of the absence of any warranty; and give all +recipients a copy of this License along with the Program. + + You may charge any price or no price for each copy that you convey, +and you may offer support or warranty protection for a fee. + + 5. Conveying Modified Source Versions. + + You may convey a work based on the Program, or the modifications to +produce it from the Program, in the form of source code under the +terms of section 4, provided that you also meet all of these conditions: + + a) The work must carry prominent notices stating that you modified + it, and giving a relevant date. + + b) The work must carry prominent notices stating that it is + released under this License and any conditions added under section + 7. This requirement modifies the requirement in section 4 to + "keep intact all notices". + + c) You must license the entire work, as a whole, under this + License to anyone who comes into possession of a copy. This + License will therefore apply, along with any applicable section 7 + additional terms, to the whole of the work, and all its parts, + regardless of how they are packaged. This License gives no + permission to license the work in any other way, but it does not + invalidate such permission if you have separately received it. + + d) If the work has interactive user interfaces, each must display + Appropriate Legal Notices; however, if the Program has interactive + interfaces that do not display Appropriate Legal Notices, your + work need not make them do so. + + A compilation of a covered work with other separate and independent +works, which are not by their nature extensions of the covered work, +and which are not combined with it such as to form a larger program, +in or on a volume of a storage or distribution medium, is called an +"aggregate" if the compilation and its resulting copyright are not +used to limit the access or legal rights of the compilation's users +beyond what the individual works permit. Inclusion of a covered work +in an aggregate does not cause this License to apply to the other +parts of the aggregate. + + 6. Conveying Non-Source Forms. + + You may convey a covered work in object code form under the terms +of sections 4 and 5, provided that you also convey the +machine-readable Corresponding Source under the terms of this License, +in one of these ways: + + a) Convey the object code in, or embodied in, a physical product + (including a physical distribution medium), accompanied by the + Corresponding Source fixed on a durable physical medium + customarily used for software interchange. + + b) Convey the object code in, or embodied in, a physical product + (including a physical distribution medium), accompanied by a + written offer, valid for at least three years and valid for as + long as you offer spare parts or customer support for that product + model, to give anyone who possesses the object code either (1) a + copy of the Corresponding Source for all the software in the + product that is covered by this License, on a durable physical + medium customarily used for software interchange, for a price no + more than your reasonable cost of physically performing this + conveying of source, or (2) access to copy the + Corresponding Source from a network server at no charge. + + c) Convey individual copies of the object code with a copy of the + written offer to provide the Corresponding Source. This + alternative is allowed only occasionally and noncommercially, and + only if you received the object code with such an offer, in accord + with subsection 6b. + + d) Convey the object code by offering access from a designated + place (gratis or for a charge), and offer equivalent access to the + Corresponding Source in the same way through the same place at no + further charge. You need not require recipients to copy the + Corresponding Source along with the object code. If the place to + copy the object code is a network server, the Corresponding Source + may be on a different server (operated by you or a third party) + that supports equivalent copying facilities, provided you maintain + clear directions next to the object code saying where to find the + Corresponding Source. Regardless of what server hosts the + Corresponding Source, you remain obligated to ensure that it is + available for as long as needed to satisfy these requirements. + + e) Convey the object code using peer-to-peer transmission, provided + you inform other peers where the object code and Corresponding + Source of the work are being offered to the general public at no + charge under subsection 6d. + + A separable portion of the object code, whose source code is excluded +from the Corresponding Source as a System Library, need not be +included in conveying the object code work. + + A "User Product" is either (1) a "consumer product", which means any +tangible personal property which is normally used for personal, family, +or household purposes, or (2) anything designed or sold for incorporation +into a dwelling. In determining whether a product is a consumer product, +doubtful cases shall be resolved in favor of coverage. For a particular +product received by a particular user, "normally used" refers to a +typical or common use of that class of product, regardless of the status +of the particular user or of the way in which the particular user +actually uses, or expects or is expected to use, the product. A product +is a consumer product regardless of whether the product has substantial +commercial, industrial or non-consumer uses, unless such uses represent +the only significant mode of use of the product. + + "Installation Information" for a User Product means any methods, +procedures, authorization keys, or other information required to install +and execute modified versions of a covered work in that User Product from +a modified version of its Corresponding Source. The information must +suffice to ensure that the continued functioning of the modified object +code is in no case prevented or interfered with solely because +modification has been made. + + If you convey an object code work under this section in, or with, or +specifically for use in, a User Product, and the conveying occurs as +part of a transaction in which the right of possession and use of the +User Product is transferred to the recipient in perpetuity or for a +fixed term (regardless of how the transaction is characterized), the +Corresponding Source conveyed under this section must be accompanied +by the Installation Information. But this requirement does not apply +if neither you nor any third party retains the ability to install +modified object code on the User Product (for example, the work has +been installed in ROM). + + The requirement to provide Installation Information does not include a +requirement to continue to provide support service, warranty, or updates +for a work that has been modified or installed by the recipient, or for +the User Product in which it has been modified or installed. Access to a +network may be denied when the modification itself materially and +adversely affects the operation of the network or violates the rules and +protocols for communication across the network. + + Corresponding Source conveyed, and Installation Information provided, +in accord with this section must be in a format that is publicly +documented (and with an implementation available to the public in +source code form), and must require no special password or key for +unpacking, reading or copying. + + 7. Additional Terms. + + "Additional permissions" are terms that supplement the terms of this +License by making exceptions from one or more of its conditions. +Additional permissions that are applicable to the entire Program shall +be treated as though they were included in this License, to the extent +that they are valid under applicable law. If additional permissions +apply only to part of the Program, that part may be used separately +under those permissions, but the entire Program remains governed by +this License without regard to the additional permissions. + + When you convey a copy of a covered work, you may at your option +remove any additional permissions from that copy, or from any part of +it. (Additional permissions may be written to require their own +removal in certain cases when you modify the work.) You may place +additional permissions on material, added by you to a covered work, +for which you have or can give appropriate copyright permission. + + Notwithstanding any other provision of this License, for material you +add to a covered work, you may (if authorized by the copyright holders of +that material) supplement the terms of this License with terms: + + a) Disclaiming warranty or limiting liability differently from the + terms of sections 15 and 16 of this License; or + + b) Requiring preservation of specified reasonable legal notices or + author attributions in that material or in the Appropriate Legal + Notices displayed by works containing it; or + + c) Prohibiting misrepresentation of the origin of that material, or + requiring that modified versions of such material be marked in + reasonable ways as different from the original version; or + + d) Limiting the use for publicity purposes of names of licensors or + authors of the material; or + + e) Declining to grant rights under trademark law for use of some + trade names, trademarks, or service marks; or + + f) Requiring indemnification of licensors and authors of that + material by anyone who conveys the material (or modified versions of + it) with contractual assumptions of liability to the recipient, for + any liability that these contractual assumptions directly impose on + those licensors and authors. + + All other non-permissive additional terms are considered "further +restrictions" within the meaning of section 10. If the Program as you +received it, or any part of it, contains a notice stating that it is +governed by this License along with a term that is a further +restriction, you may remove that term. If a license document contains +a further restriction but permits relicensing or conveying under this +License, you may add to a covered work material governed by the terms +of that license document, provided that the further restriction does +not survive such relicensing or conveying. + + If you add terms to a covered work in accord with this section, you +must place, in the relevant source files, a statement of the +additional terms that apply to those files, or a notice indicating +where to find the applicable terms. + + Additional terms, permissive or non-permissive, may be stated in the +form of a separately written license, or stated as exceptions; +the above requirements apply either way. + + 8. Termination. + + You may not propagate or modify a covered work except as expressly +provided under this License. Any attempt otherwise to propagate or +modify it is void, and will automatically terminate your rights under +this License (including any patent licenses granted under the third +paragraph of section 11). + + However, if you cease all violation of this License, then your +license from a particular copyright holder is reinstated (a) +provisionally, unless and until the copyright holder explicitly and +finally terminates your license, and (b) permanently, if the copyright +holder fails to notify you of the violation by some reasonable means +prior to 60 days after the cessation. + + Moreover, your license from a particular copyright holder is +reinstated permanently if the copyright holder notifies you of the +violation by some reasonable means, this is the first time you have +received notice of violation of this License (for any work) from that +copyright holder, and you cure the violation prior to 30 days after +your receipt of the notice. + + Termination of your rights under this section does not terminate the +licenses of parties who have received copies or rights from you under +this License. If your rights have been terminated and not permanently +reinstated, you do not qualify to receive new licenses for the same +material under section 10. + + 9. Acceptance Not Required for Having Copies. + + You are not required to accept this License in order to receive or +run a copy of the Program. Ancillary propagation of a covered work +occurring solely as a consequence of using peer-to-peer transmission +to receive a copy likewise does not require acceptance. However, +nothing other than this License grants you permission to propagate or +modify any covered work. These actions infringe copyright if you do +not accept this License. Therefore, by modifying or propagating a +covered work, you indicate your acceptance of this License to do so. + + 10. Automatic Licensing of Downstream Recipients. + + Each time you convey a covered work, the recipient automatically +receives a license from the original licensors, to run, modify and +propagate that work, subject to this License. You are not responsible +for enforcing compliance by third parties with this License. + + An "entity transaction" is a transaction transferring control of an +organization, or substantially all assets of one, or subdividing an +organization, or merging organizations. If propagation of a covered +work results from an entity transaction, each party to that +transaction who receives a copy of the work also receives whatever +licenses to the work the party's predecessor in interest had or could +give under the previous paragraph, plus a right to possession of the +Corresponding Source of the work from the predecessor in interest, if +the predecessor has it or can get it with reasonable efforts. + + You may not impose any further restrictions on the exercise of the +rights granted or affirmed under this License. For example, you may +not impose a license fee, royalty, or other charge for exercise of +rights granted under this License, and you may not initiate litigation +(including a cross-claim or counterclaim in a lawsuit) alleging that +any patent claim is infringed by making, using, selling, offering for +sale, or importing the Program or any portion of it. + + 11. Patents. + + A "contributor" is a copyright holder who authorizes use under this +License of the Program or a work on which the Program is based. The +work thus licensed is called the contributor's "contributor version". + + A contributor's "essential patent claims" are all patent claims +owned or controlled by the contributor, whether already acquired or +hereafter acquired, that would be infringed by some manner, permitted +by this License, of making, using, or selling its contributor version, +but do not include claims that would be infringed only as a +consequence of further modification of the contributor version. For +purposes of this definition, "control" includes the right to grant +patent sublicenses in a manner consistent with the requirements of +this License. + + Each contributor grants you a non-exclusive, worldwide, royalty-free +patent license under the contributor's essential patent claims, to +make, use, sell, offer for sale, import and otherwise run, modify and +propagate the contents of its contributor version. + + In the following three paragraphs, a "patent license" is any express +agreement or commitment, however denominated, not to enforce a patent +(such as an express permission to practice a patent or covenant not to +sue for patent infringement). To "grant" such a patent license to a +party means to make such an agreement or commitment not to enforce a +patent against the party. + + If you convey a covered work, knowingly relying on a patent license, +and the Corresponding Source of the work is not available for anyone +to copy, free of charge and under the terms of this License, through a +publicly available network server or other readily accessible means, +then you must either (1) cause the Corresponding Source to be so +available, or (2) arrange to deprive yourself of the benefit of the +patent license for this particular work, or (3) arrange, in a manner +consistent with the requirements of this License, to extend the patent +license to downstream recipients. "Knowingly relying" means you have +actual knowledge that, but for the patent license, your conveying the +covered work in a country, or your recipient's use of the covered work +in a country, would infringe one or more identifiable patents in that +country that you have reason to believe are valid. + + If, pursuant to or in connection with a single transaction or +arrangement, you convey, or propagate by procuring conveyance of, a +covered work, and grant a patent license to some of the parties +receiving the covered work authorizing them to use, propagate, modify +or convey a specific copy of the covered work, then the patent license +you grant is automatically extended to all recipients of the covered +work and works based on it. + + A patent license is "discriminatory" if it does not include within +the scope of its coverage, prohibits the exercise of, or is +conditioned on the non-exercise of one or more of the rights that are +specifically granted under this License. You may not convey a covered +work if you are a party to an arrangement with a third party that is +in the business of distributing software, under which you make payment +to the third party based on the extent of your activity of conveying +the work, and under which the third party grants, to any of the +parties who would receive the covered work from you, a discriminatory +patent license (a) in connection with copies of the covered work +conveyed by you (or copies made from those copies), or (b) primarily +for and in connection with specific products or compilations that +contain the covered work, unless you entered into that arrangement, +or that patent license was granted, prior to 28 March 2007. + + Nothing in this License shall be construed as excluding or limiting +any implied license or other defenses to infringement that may +otherwise be available to you under applicable patent law. + + 12. No Surrender of Others' Freedom. + + If conditions are imposed on you (whether by court order, agreement or +otherwise) that contradict the conditions of this License, they do not +excuse you from the conditions of this License. If you cannot convey a +covered work so as to satisfy simultaneously your obligations under this +License and any other pertinent obligations, then as a consequence you may +not convey it at all. For example, if you agree to terms that obligate you +to collect a royalty for further conveying from those to whom you convey +the Program, the only way you could satisfy both those terms and this +License would be to refrain entirely from conveying the Program. + + 13. Use with the GNU Affero General Public License. + + Notwithstanding any other provision of this License, you have +permission to link or combine any covered work with a work licensed +under version 3 of the GNU Affero General Public License into a single +combined work, and to convey the resulting work. The terms of this +License will continue to apply to the part which is the covered work, +but the special requirements of the GNU Affero General Public License, +section 13, concerning interaction through a network will apply to the +combination as such. + + 14. Revised Versions of this License. + + The Free Software Foundation may publish revised and/or new versions of +the GNU General Public License from time to time. Such new versions will +be similar in spirit to the present version, but may differ in detail to +address new problems or concerns. + + Each version is given a distinguishing version number. If the +Program specifies that a certain numbered version of the GNU General +Public License "or any later version" applies to it, you have the +option of following the terms and conditions either of that numbered +version or of any later version published by the Free Software +Foundation. If the Program does not specify a version number of the +GNU General Public License, you may choose any version ever published +by the Free Software Foundation. + + If the Program specifies that a proxy can decide which future +versions of the GNU General Public License can be used, that proxy's +public statement of acceptance of a version permanently authorizes you +to choose that version for the Program. + + Later license versions may give you additional or different +permissions. However, no additional obligations are imposed on any +author or copyright holder as a result of your choosing to follow a +later version. + + 15. Disclaimer of Warranty. + + THERE IS NO WARRANTY FOR THE PROGRAM, TO THE EXTENT PERMITTED BY +APPLICABLE LAW. EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT +HOLDERS AND/OR OTHER PARTIES PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY +OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, +THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR +PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE PROGRAM +IS WITH YOU. SHOULD THE PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF +ALL NECESSARY SERVICING, REPAIR OR CORRECTION. + + 16. Limitation of Liability. + + IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING +WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MODIFIES AND/OR CONVEYS +THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, INCLUDING ANY +GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE +USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED TO LOSS OF +DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD +PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER PROGRAMS), +EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF +SUCH DAMAGES. + + 17. Interpretation of Sections 15 and 16. + + If the disclaimer of warranty and limitation of liability provided +above cannot be given local legal effect according to their terms, +reviewing courts shall apply local law that most closely approximates +an absolute waiver of all civil liability in connection with the +Program, unless a warranty or assumption of liability accompanies a +copy of the Program in return for a fee. + + END OF TERMS AND CONDITIONS + + How to Apply These Terms to Your New Programs + + If you develop a new program, and you want it to be of the greatest +possible use to the public, the best way to achieve this is to make it +free software which everyone can redistribute and change under these terms. + + To do so, attach the following notices to the program. It is safest +to attach them to the start of each source file to most effectively +state the exclusion of warranty; and each file should have at least +the "copyright" line and a pointer to where the full notice is found. + + + Copyright (C) + + This program is free software: you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation, either version 3 of the License, or + (at your option) any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with this program. If not, see . + +Also add information on how to contact you by electronic and paper mail. + + If the program does terminal interaction, make it output a short +notice like this when it starts in an interactive mode: + + Copyright (C) + This program comes with ABSOLUTELY NO WARRANTY; for details type `show w'. + This is free software, and you are welcome to redistribute it + under certain conditions; type `show c' for details. + +The hypothetical commands `show w' and `show c' should show the appropriate +parts of the General Public License. Of course, your program's commands +might be different; for a GUI interface, you would use an "about box". + + You should also get your employer (if you work as a programmer) or school, +if any, to sign a "copyright disclaimer" for the program, if necessary. +For more information on this, and how to apply and follow the GNU GPL, see +. + + The GNU General Public License does not permit incorporating your program +into proprietary programs. If your program is a subroutine library, you +may consider it more useful to permit linking proprietary applications with +the library. If this is what you want to do, use the GNU Lesser General +Public License instead of this License. But first, please read +. diff --git a/licenses/LGPL-3.0.txt b/licenses/LGPL-3.0.txt new file mode 100644 index 000000000..0a041280b --- /dev/null +++ b/licenses/LGPL-3.0.txt @@ -0,0 +1,165 @@ + GNU LESSER GENERAL PUBLIC LICENSE + Version 3, 29 June 2007 + + Copyright (C) 2007 Free Software Foundation, Inc. + Everyone is permitted to copy and distribute verbatim copies + of this license document, but changing it is not allowed. + + + This version of the GNU Lesser General Public License incorporates +the terms and conditions of version 3 of the GNU General Public +License, supplemented by the additional permissions listed below. + + 0. Additional Definitions. + + As used herein, "this License" refers to version 3 of the GNU Lesser +General Public License, and the "GNU GPL" refers to version 3 of the GNU +General Public License. + + "The Library" refers to a covered work governed by this License, +other than an Application or a Combined Work as defined below. + + An "Application" is any work that makes use of an interface provided +by the Library, but which is not otherwise based on the Library. +Defining a subclass of a class defined by the Library is deemed a mode +of using an interface provided by the Library. + + A "Combined Work" is a work produced by combining or linking an +Application with the Library. The particular version of the Library +with which the Combined Work was made is also called the "Linked +Version". + + The "Minimal Corresponding Source" for a Combined Work means the +Corresponding Source for the Combined Work, excluding any source code +for portions of the Combined Work that, considered in isolation, are +based on the Application, and not on the Linked Version. + + The "Corresponding Application Code" for a Combined Work means the +object code and/or source code for the Application, including any data +and utility programs needed for reproducing the Combined Work from the +Application, but excluding the System Libraries of the Combined Work. + + 1. Exception to Section 3 of the GNU GPL. + + You may convey a covered work under sections 3 and 4 of this License +without being bound by section 3 of the GNU GPL. + + 2. Conveying Modified Versions. + + If you modify a copy of the Library, and, in your modifications, a +facility refers to a function or data to be supplied by an Application +that uses the facility (other than as an argument passed when the +facility is invoked), then you may convey a copy of the modified +version: + + a) under this License, provided that you make a good faith effort to + ensure that, in the event an Application does not supply the + function or data, the facility still operates, and performs + whatever part of its purpose remains meaningful, or + + b) under the GNU GPL, with none of the additional permissions of + this License applicable to that copy. + + 3. Object Code Incorporating Material from Library Header Files. + + The object code form of an Application may incorporate material from +a header file that is part of the Library. You may convey such object +code under terms of your choice, provided that, if the incorporated +material is not limited to numerical parameters, data structure +layouts and accessors, or small macros, inline functions and templates +(ten or fewer lines in length), you do both of the following: + + a) Give prominent notice with each copy of the object code that the + Library is used in it and that the Library and its use are + covered by this License. + + b) Accompany the object code with a copy of the GNU GPL and this license + document. + + 4. Combined Works. + + You may convey a Combined Work under terms of your choice that, +taken together, effectively do not restrict modification of the +portions of the Library contained in the Combined Work and reverse +engineering for debugging such modifications, if you also do each of +the following: + + a) Give prominent notice with each copy of the Combined Work that + the Library is used in it and that the Library and its use are + covered by this License. + + b) Accompany the Combined Work with a copy of the GNU GPL and this license + document. + + c) For a Combined Work that displays copyright notices during + execution, include the copyright notice for the Library among + these notices, as well as a reference directing the user to the + copies of the GNU GPL and this license document. + + d) Do one of the following: + + 0) Convey the Minimal Corresponding Source under the terms of this + License, and the Corresponding Application Code in a form + suitable for, and under terms that permit, the user to + recombine or relink the Application with a modified version of + the Linked Version to produce a modified Combined Work, in the + manner specified by section 6 of the GNU GPL for conveying + Corresponding Source. + + 1) Use a suitable shared library mechanism for linking with the + Library. A suitable mechanism is one that (a) uses at run time + a copy of the Library already present on the user's computer + system, and (b) will operate properly with a modified version + of the Library that is interface-compatible with the Linked + Version. + + e) Provide Installation Information, but only if you would otherwise + be required to provide such information under section 6 of the + GNU GPL, and only to the extent that such information is + necessary to install and execute a modified version of the + Combined Work produced by recombining or relinking the + Application with a modified version of the Linked Version. (If + you use option 4d0, the Installation Information must accompany + the Minimal Corresponding Source and Corresponding Application + Code. If you use option 4d1, you must provide the Installation + Information in the manner specified by section 6 of the GNU GPL + for conveying Corresponding Source.) + + 5. Combined Libraries. + + You may place library facilities that are a work based on the +Library side by side in a single library together with other library +facilities that are not Applications and are not covered by this +License, and convey such a combined library under terms of your +choice, if you do both of the following: + + a) Accompany the combined library with a copy of the same work based + on the Library, uncombined with any other library facilities, + conveyed under the terms of this License. + + b) Give prominent notice with the combined library that part of it + is a work based on the Library, and explaining where to find the + accompanying uncombined form of the same work. + + 6. Revised Versions of the GNU Lesser General Public License. + + The Free Software Foundation may publish revised and/or new versions +of the GNU Lesser General Public License from time to time. Such new +versions will be similar in spirit to the present version, but may +differ in detail to address new problems or concerns. + + Each version is given a distinguishing version number. If the +Library as you received it specifies that a certain numbered version +of the GNU Lesser General Public License "or any later version" +applies to it, you have the option of following the terms and +conditions either of that published version or of any later version +published by the Free Software Foundation. If the Library as you +received it does not specify a version number of the GNU Lesser +General Public License, you may choose any version of the GNU Lesser +General Public License ever published by the Free Software Foundation. + + If the Library as you received it specifies that a proxy can decide +whether future versions of the GNU Lesser General Public License shall +apply, that proxy's public statement of acceptance of any version is +permanent authorization for you to choose that version for the +Library. diff --git a/pkg/contracts/iapplication/iapplication.go b/pkg/contracts/iapplication/iapplication.go index 66a00a8fe..305b5bb9d 100644 --- a/pkg/contracts/iapplication/iapplication.go +++ b/pkg/contracts/iapplication/iapplication.go @@ -4,9 +4,11 @@ package iapplication import ( + "context" "errors" "math/big" "strings" + "time" ethereum "github.com/ethereum/go-ethereum" "github.com/ethereum/go-ethereum/accounts/abi" @@ -27,6 +29,8 @@ var ( _ = types.BloomLookup _ = event.NewSubscription _ = abi.ConvertType + _ = time.Tick + _ = context.Background ) // AccountValidityProof is an auto generated low-level Go binding around an user-defined struct. @@ -1360,6 +1364,10 @@ func (_IApplication *IApplicationFilterer) WatchAccountsDriveMerkleRootProved(op // New log arrived, parse the event and forward to the user event := new(IApplicationAccountsDriveMerkleRootProved) if err := _IApplication.contract.UnpackLog(event, "AccountsDriveMerkleRootProved", log); err != nil { + // If the signature doesn't match, skip this log. + if errors.Is(err, bind.ErrEventSignatureMismatch) { + continue + } return err } event.Raw = log @@ -1493,6 +1501,10 @@ func (_IApplication *IApplicationFilterer) WatchForeclosure(opts *bind.WatchOpts // New log arrived, parse the event and forward to the user event := new(IApplicationForeclosure) if err := _IApplication.contract.UnpackLog(event, "Foreclosure", log); err != nil { + // If the signature doesn't match, skip this log. + if errors.Is(err, bind.ErrEventSignatureMismatch) { + continue + } return err } event.Raw = log @@ -1638,6 +1650,10 @@ func (_IApplication *IApplicationFilterer) WatchOutputExecuted(opts *bind.WatchO // New log arrived, parse the event and forward to the user event := new(IApplicationOutputExecuted) if err := _IApplication.contract.UnpackLog(event, "OutputExecuted", log); err != nil { + // If the signature doesn't match, skip this log. + if errors.Is(err, bind.ErrEventSignatureMismatch) { + continue + } return err } event.Raw = log @@ -1772,6 +1788,10 @@ func (_IApplication *IApplicationFilterer) WatchOutputsMerkleRootValidatorChange // New log arrived, parse the event and forward to the user event := new(IApplicationOutputsMerkleRootValidatorChanged) if err := _IApplication.contract.UnpackLog(event, "OutputsMerkleRootValidatorChanged", log); err != nil { + // If the signature doesn't match, skip this log. + if errors.Is(err, bind.ErrEventSignatureMismatch) { + continue + } return err } event.Raw = log @@ -1918,6 +1938,10 @@ func (_IApplication *IApplicationFilterer) WatchRefundIssued(opts *bind.WatchOpt // New log arrived, parse the event and forward to the user event := new(IApplicationRefundIssued) if err := _IApplication.contract.UnpackLog(event, "RefundIssued", log); err != nil { + // If the signature doesn't match, skip this log. + if errors.Is(err, bind.ErrEventSignatureMismatch) { + continue + } return err } event.Raw = log @@ -2064,6 +2088,10 @@ func (_IApplication *IApplicationFilterer) WatchWithdrawal(opts *bind.WatchOpts, // New log arrived, parse the event and forward to the user event := new(IApplicationWithdrawal) if err := _IApplication.contract.UnpackLog(event, "Withdrawal", log); err != nil { + // If the signature doesn't match, skip this log. + if errors.Is(err, bind.ErrEventSignatureMismatch) { + continue + } return err } event.Raw = log diff --git a/pkg/contracts/iapplicationfactory/iapplicationfactory.go b/pkg/contracts/iapplicationfactory/iapplicationfactory.go index 1b7899d7f..2b5dc6bb5 100644 --- a/pkg/contracts/iapplicationfactory/iapplicationfactory.go +++ b/pkg/contracts/iapplicationfactory/iapplicationfactory.go @@ -4,9 +4,11 @@ package iapplicationfactory import ( + "context" "errors" "math/big" "strings" + "time" ethereum "github.com/ethereum/go-ethereum" "github.com/ethereum/go-ethereum/accounts/abi" @@ -27,6 +29,8 @@ var ( _ = types.BloomLookup _ = event.NewSubscription _ = abi.ConvertType + _ = time.Tick + _ = context.Background ) // WithdrawalConfig is an auto generated low-level Go binding around an user-defined struct. @@ -439,6 +443,10 @@ func (_IApplicationFactory *IApplicationFactoryFilterer) WatchApplicationCreated // New log arrived, parse the event and forward to the user event := new(IApplicationFactoryApplicationCreated) if err := _IApplicationFactory.contract.UnpackLog(event, "ApplicationCreated", log); err != nil { + // If the signature doesn't match, skip this log. + if errors.Is(err, bind.ErrEventSignatureMismatch) { + continue + } return err } event.Raw = log diff --git a/pkg/contracts/iauthority/iauthority.go b/pkg/contracts/iauthority/iauthority.go index dd4526b14..8d8d5be6d 100644 --- a/pkg/contracts/iauthority/iauthority.go +++ b/pkg/contracts/iauthority/iauthority.go @@ -4,9 +4,11 @@ package iauthority import ( + "context" "errors" "math/big" "strings" + "time" ethereum "github.com/ethereum/go-ethereum" "github.com/ethereum/go-ethereum/accounts/abi" @@ -27,6 +29,8 @@ var ( _ = types.BloomLookup _ = event.NewSubscription _ = abi.ConvertType + _ = time.Tick + _ = context.Background ) // IConsensusClaim is an auto generated low-level Go binding around an user-defined struct. @@ -800,6 +804,10 @@ func (_IAuthority *IAuthorityFilterer) WatchClaimAccepted(opts *bind.WatchOpts, // New log arrived, parse the event and forward to the user event := new(IAuthorityClaimAccepted) if err := _IAuthority.contract.UnpackLog(event, "ClaimAccepted", log); err != nil { + // If the signature doesn't match, skip this log. + if errors.Is(err, bind.ErrEventSignatureMismatch) { + continue + } return err } event.Raw = log @@ -947,6 +955,10 @@ func (_IAuthority *IAuthorityFilterer) WatchClaimStaged(opts *bind.WatchOpts, si // New log arrived, parse the event and forward to the user event := new(IAuthorityClaimStaged) if err := _IAuthority.contract.UnpackLog(event, "ClaimStaged", log); err != nil { + // If the signature doesn't match, skip this log. + if errors.Is(err, bind.ErrEventSignatureMismatch) { + continue + } return err } event.Raw = log @@ -1103,6 +1115,10 @@ func (_IAuthority *IAuthorityFilterer) WatchClaimSubmitted(opts *bind.WatchOpts, // New log arrived, parse the event and forward to the user event := new(IAuthorityClaimSubmitted) if err := _IAuthority.contract.UnpackLog(event, "ClaimSubmitted", log); err != nil { + // If the signature doesn't match, skip this log. + if errors.Is(err, bind.ErrEventSignatureMismatch) { + continue + } return err } event.Raw = log diff --git a/pkg/contracts/iauthorityfactory/iauthorityfactory.go b/pkg/contracts/iauthorityfactory/iauthorityfactory.go index 9d8cea11a..842eb6177 100644 --- a/pkg/contracts/iauthorityfactory/iauthorityfactory.go +++ b/pkg/contracts/iauthorityfactory/iauthorityfactory.go @@ -4,9 +4,11 @@ package iauthorityfactory import ( + "context" "errors" "math/big" "strings" + "time" ethereum "github.com/ethereum/go-ethereum" "github.com/ethereum/go-ethereum/accounts/abi" @@ -27,6 +29,8 @@ var ( _ = types.BloomLookup _ = event.NewSubscription _ = abi.ConvertType + _ = time.Tick + _ = context.Background ) // IAuthorityFactoryMetaData contains all meta data concerning the IAuthorityFactory contract. @@ -415,6 +419,10 @@ func (_IAuthorityFactory *IAuthorityFactoryFilterer) WatchAuthorityCreated(opts // New log arrived, parse the event and forward to the user event := new(IAuthorityFactoryAuthorityCreated) if err := _IAuthorityFactory.contract.UnpackLog(event, "AuthorityCreated", log); err != nil { + // If the signature doesn't match, skip this log. + if errors.Is(err, bind.ErrEventSignatureMismatch) { + continue + } return err } event.Raw = log diff --git a/pkg/contracts/iconsensus/iconsensus.go b/pkg/contracts/iconsensus/iconsensus.go index 65686854d..f609bd510 100644 --- a/pkg/contracts/iconsensus/iconsensus.go +++ b/pkg/contracts/iconsensus/iconsensus.go @@ -4,9 +4,11 @@ package iconsensus import ( + "context" "errors" "math/big" "strings" + "time" ethereum "github.com/ethereum/go-ethereum" "github.com/ethereum/go-ethereum/accounts/abi" @@ -27,6 +29,8 @@ var ( _ = types.BloomLookup _ = event.NewSubscription _ = abi.ConvertType + _ = time.Tick + _ = context.Background ) // IConsensusClaim is an auto generated low-level Go binding around an user-defined struct. @@ -727,6 +731,10 @@ func (_IConsensus *IConsensusFilterer) WatchClaimAccepted(opts *bind.WatchOpts, // New log arrived, parse the event and forward to the user event := new(IConsensusClaimAccepted) if err := _IConsensus.contract.UnpackLog(event, "ClaimAccepted", log); err != nil { + // If the signature doesn't match, skip this log. + if errors.Is(err, bind.ErrEventSignatureMismatch) { + continue + } return err } event.Raw = log @@ -874,6 +882,10 @@ func (_IConsensus *IConsensusFilterer) WatchClaimStaged(opts *bind.WatchOpts, si // New log arrived, parse the event and forward to the user event := new(IConsensusClaimStaged) if err := _IConsensus.contract.UnpackLog(event, "ClaimStaged", log); err != nil { + // If the signature doesn't match, skip this log. + if errors.Is(err, bind.ErrEventSignatureMismatch) { + continue + } return err } event.Raw = log @@ -1030,6 +1042,10 @@ func (_IConsensus *IConsensusFilterer) WatchClaimSubmitted(opts *bind.WatchOpts, // New log arrived, parse the event and forward to the user event := new(IConsensusClaimSubmitted) if err := _IConsensus.contract.UnpackLog(event, "ClaimSubmitted", log); err != nil { + // If the signature doesn't match, skip this log. + if errors.Is(err, bind.ErrEventSignatureMismatch) { + continue + } return err } event.Raw = log diff --git a/pkg/contracts/idaveappfactory/idaveappfactory.go b/pkg/contracts/idaveappfactory/idaveappfactory.go index ae2621e60..ca8f832c4 100644 --- a/pkg/contracts/idaveappfactory/idaveappfactory.go +++ b/pkg/contracts/idaveappfactory/idaveappfactory.go @@ -4,9 +4,11 @@ package idaveappfactory import ( + "context" "errors" "math/big" "strings" + "time" ethereum "github.com/ethereum/go-ethereum" "github.com/ethereum/go-ethereum/accounts/abi" @@ -27,6 +29,8 @@ var ( _ = types.BloomLookup _ = event.NewSubscription _ = abi.ConvertType + _ = time.Tick + _ = context.Background ) // WithdrawalConfig is an auto generated low-level Go binding around an user-defined struct. @@ -358,6 +362,10 @@ func (_IDaveAppFactory *IDaveAppFactoryFilterer) WatchDaveAppCreated(opts *bind. // New log arrived, parse the event and forward to the user event := new(IDaveAppFactoryDaveAppCreated) if err := _IDaveAppFactory.contract.UnpackLog(event, "DaveAppCreated", log); err != nil { + // If the signature doesn't match, skip this log. + if errors.Is(err, bind.ErrEventSignatureMismatch) { + continue + } return err } event.Raw = log diff --git a/pkg/contracts/idaveconsensus/idaveconsensus.go b/pkg/contracts/idaveconsensus/idaveconsensus.go index a4b09abb6..33b0b9c9c 100644 --- a/pkg/contracts/idaveconsensus/idaveconsensus.go +++ b/pkg/contracts/idaveconsensus/idaveconsensus.go @@ -4,9 +4,11 @@ package idaveconsensus import ( + "context" "errors" "math/big" "strings" + "time" ethereum "github.com/ethereum/go-ethereum" "github.com/ethereum/go-ethereum/accounts/abi" @@ -27,6 +29,8 @@ var ( _ = types.BloomLookup _ = event.NewSubscription _ = abi.ConvertType + _ = time.Tick + _ = context.Background ) // LeafProof is an auto generated low-level Go binding around an user-defined struct. @@ -1082,6 +1086,10 @@ func (_IDaveConsensus *IDaveConsensusFilterer) WatchConsensusCreation(opts *bind // New log arrived, parse the event and forward to the user event := new(IDaveConsensusConsensusCreation) if err := _IDaveConsensus.contract.UnpackLog(event, "ConsensusCreation", log); err != nil { + // If the signature doesn't match, skip this log. + if errors.Is(err, bind.ErrEventSignatureMismatch) { + continue + } return err } event.Raw = log @@ -1231,6 +1239,10 @@ func (_IDaveConsensus *IDaveConsensusFilterer) WatchEpochSealed(opts *bind.Watch // New log arrived, parse the event and forward to the user event := new(IDaveConsensusEpochSealed) if err := _IDaveConsensus.contract.UnpackLog(event, "EpochSealed", log); err != nil { + // If the signature doesn't match, skip this log. + if errors.Is(err, bind.ErrEventSignatureMismatch) { + continue + } return err } event.Raw = log @@ -1377,6 +1389,10 @@ func (_IDaveConsensus *IDaveConsensusFilterer) WatchEpochStaged(opts *bind.Watch // New log arrived, parse the event and forward to the user event := new(IDaveConsensusEpochStaged) if err := _IDaveConsensus.contract.UnpackLog(event, "EpochStaged", log); err != nil { + // If the signature doesn't match, skip this log. + if errors.Is(err, bind.ErrEventSignatureMismatch) { + continue + } return err } event.Raw = log @@ -1540,6 +1556,10 @@ func (_IDaveConsensus *IDaveConsensusFilterer) WatchSentryClaim(opts *bind.Watch // New log arrived, parse the event and forward to the user event := new(IDaveConsensusSentryClaim) if err := _IDaveConsensus.contract.UnpackLog(event, "SentryClaim", log); err != nil { + // If the signature doesn't match, skip this log. + if errors.Is(err, bind.ErrEventSignatureMismatch) { + continue + } return err } event.Raw = log @@ -1702,6 +1722,10 @@ func (_IDaveConsensus *IDaveConsensusFilterer) WatchSentryRotation(opts *bind.Wa // New log arrived, parse the event and forward to the user event := new(IDaveConsensusSentryRotation) if err := _IDaveConsensus.contract.UnpackLog(event, "SentryRotation", log); err != nil { + // If the signature doesn't match, skip this log. + if errors.Is(err, bind.ErrEventSignatureMismatch) { + continue + } return err } event.Raw = log diff --git a/pkg/contracts/ierc20errors/ierc20errors.go b/pkg/contracts/ierc20errors/ierc20errors.go index 2dce90e12..ba8a8c4f9 100644 --- a/pkg/contracts/ierc20errors/ierc20errors.go +++ b/pkg/contracts/ierc20errors/ierc20errors.go @@ -4,9 +4,11 @@ package ierc20errors import ( + "context" "errors" "math/big" "strings" + "time" ethereum "github.com/ethereum/go-ethereum" "github.com/ethereum/go-ethereum/accounts/abi" @@ -27,6 +29,8 @@ var ( _ = types.BloomLookup _ = event.NewSubscription _ = abi.ConvertType + _ = time.Tick + _ = context.Background ) // IERC20ErrorsMetaData contains all meta data concerning the IERC20Errors contract. diff --git a/pkg/contracts/ierc20metadata/ierc20metadata.go b/pkg/contracts/ierc20metadata/ierc20metadata.go index 33e24b610..21dc1a2f6 100644 --- a/pkg/contracts/ierc20metadata/ierc20metadata.go +++ b/pkg/contracts/ierc20metadata/ierc20metadata.go @@ -4,9 +4,11 @@ package ierc20metadata import ( + "context" "errors" "math/big" "strings" + "time" ethereum "github.com/ethereum/go-ethereum" "github.com/ethereum/go-ethereum/accounts/abi" @@ -27,6 +29,8 @@ var ( _ = types.BloomLookup _ = event.NewSubscription _ = abi.ConvertType + _ = time.Tick + _ = context.Background ) // IERC20MetadataMetaData contains all meta data concerning the IERC20Metadata contract. @@ -551,6 +555,10 @@ func (_IERC20Metadata *IERC20MetadataFilterer) WatchApproval(opts *bind.WatchOpt // New log arrived, parse the event and forward to the user event := new(IERC20MetadataApproval) if err := _IERC20Metadata.contract.UnpackLog(event, "Approval", log); err != nil { + // If the signature doesn't match, skip this log. + if errors.Is(err, bind.ErrEventSignatureMismatch) { + continue + } return err } event.Raw = log @@ -705,6 +713,10 @@ func (_IERC20Metadata *IERC20MetadataFilterer) WatchTransfer(opts *bind.WatchOpt // New log arrived, parse the event and forward to the user event := new(IERC20MetadataTransfer) if err := _IERC20Metadata.contract.UnpackLog(event, "Transfer", log); err != nil { + // If the signature doesn't match, skip this log. + if errors.Is(err, bind.ErrEventSignatureMismatch) { + continue + } return err } event.Raw = log diff --git a/pkg/contracts/ierc20portal/ierc20portal.go b/pkg/contracts/ierc20portal/ierc20portal.go index e9158e856..395ff386f 100644 --- a/pkg/contracts/ierc20portal/ierc20portal.go +++ b/pkg/contracts/ierc20portal/ierc20portal.go @@ -4,9 +4,11 @@ package ierc20portal import ( + "context" "errors" "math/big" "strings" + "time" ethereum "github.com/ethereum/go-ethereum" "github.com/ethereum/go-ethereum/accounts/abi" @@ -27,6 +29,8 @@ var ( _ = types.BloomLookup _ = event.NewSubscription _ = abi.ConvertType + _ = time.Tick + _ = context.Background ) // IErc20PortalMetaData contains all meta data concerning the IErc20Portal contract. diff --git a/pkg/contracts/iinputbox/iinputbox.go b/pkg/contracts/iinputbox/iinputbox.go index e4b700084..3de190b5b 100644 --- a/pkg/contracts/iinputbox/iinputbox.go +++ b/pkg/contracts/iinputbox/iinputbox.go @@ -4,9 +4,11 @@ package iinputbox import ( + "context" "errors" "math/big" "strings" + "time" ethereum "github.com/ethereum/go-ethereum" "github.com/ethereum/go-ethereum/accounts/abi" @@ -27,6 +29,8 @@ var ( _ = types.BloomLookup _ = event.NewSubscription _ = abi.ConvertType + _ = time.Tick + _ = context.Background ) // IInputBoxMetaData contains all meta data concerning the IInputBox contract. @@ -476,6 +480,10 @@ func (_IInputBox *IInputBoxFilterer) WatchInputAdded(opts *bind.WatchOpts, sink // New log arrived, parse the event and forward to the user event := new(IInputBoxInputAdded) if err := _IInputBox.contract.UnpackLog(event, "InputAdded", log); err != nil { + // If the signature doesn't match, skip this log. + if errors.Is(err, bind.ErrEventSignatureMismatch) { + continue + } return err } event.Raw = log diff --git a/pkg/contracts/imultileveltournamentfactory/imultileveltournamentfactory.go b/pkg/contracts/imultileveltournamentfactory/imultileveltournamentfactory.go index f439b43fc..825460536 100644 --- a/pkg/contracts/imultileveltournamentfactory/imultileveltournamentfactory.go +++ b/pkg/contracts/imultileveltournamentfactory/imultileveltournamentfactory.go @@ -4,9 +4,11 @@ package imultileveltournamentfactory import ( + "context" "errors" "math/big" "strings" + "time" ethereum "github.com/ethereum/go-ethereum" "github.com/ethereum/go-ethereum/accounts/abi" @@ -27,6 +29,8 @@ var ( _ = types.BloomLookup _ = event.NewSubscription _ = abi.ConvertType + _ = time.Tick + _ = context.Background ) // TournamentParameters is an auto generated low-level Go binding around an user-defined struct. @@ -426,6 +430,10 @@ func (_IMultiLevelTournamentFactory *IMultiLevelTournamentFactoryFilterer) Watch // New log arrived, parse the event and forward to the user event := new(IMultiLevelTournamentFactoryTournamentCreated) if err := _IMultiLevelTournamentFactory.contract.UnpackLog(event, "TournamentCreated", log); err != nil { + // If the signature doesn't match, skip this log. + if errors.Is(err, bind.ErrEventSignatureMismatch) { + continue + } return err } event.Raw = log diff --git a/pkg/contracts/inputs/inputs.go b/pkg/contracts/inputs/inputs.go index aa8431243..9a1c3770b 100644 --- a/pkg/contracts/inputs/inputs.go +++ b/pkg/contracts/inputs/inputs.go @@ -4,9 +4,11 @@ package inputs import ( + "context" "errors" "math/big" "strings" + "time" ethereum "github.com/ethereum/go-ethereum" "github.com/ethereum/go-ethereum/accounts/abi" @@ -27,6 +29,8 @@ var ( _ = types.BloomLookup _ = event.NewSubscription _ = abi.ConvertType + _ = time.Tick + _ = context.Background ) // InputsMetaData contains all meta data concerning the Inputs contract. diff --git a/pkg/contracts/iquorum/iquorum.go b/pkg/contracts/iquorum/iquorum.go index e01b7adf9..31ffd2da9 100644 --- a/pkg/contracts/iquorum/iquorum.go +++ b/pkg/contracts/iquorum/iquorum.go @@ -4,9 +4,11 @@ package iquorum import ( + "context" "errors" "math/big" "strings" + "time" ethereum "github.com/ethereum/go-ethereum" "github.com/ethereum/go-ethereum/accounts/abi" @@ -27,6 +29,8 @@ var ( _ = types.BloomLookup _ = event.NewSubscription _ = abi.ConvertType + _ = time.Tick + _ = context.Background ) // IConsensusClaim is an auto generated low-level Go binding around an user-defined struct. @@ -944,6 +948,10 @@ func (_IQuorum *IQuorumFilterer) WatchClaimAccepted(opts *bind.WatchOpts, sink c // New log arrived, parse the event and forward to the user event := new(IQuorumClaimAccepted) if err := _IQuorum.contract.UnpackLog(event, "ClaimAccepted", log); err != nil { + // If the signature doesn't match, skip this log. + if errors.Is(err, bind.ErrEventSignatureMismatch) { + continue + } return err } event.Raw = log @@ -1091,6 +1099,10 @@ func (_IQuorum *IQuorumFilterer) WatchClaimStaged(opts *bind.WatchOpts, sink cha // New log arrived, parse the event and forward to the user event := new(IQuorumClaimStaged) if err := _IQuorum.contract.UnpackLog(event, "ClaimStaged", log); err != nil { + // If the signature doesn't match, skip this log. + if errors.Is(err, bind.ErrEventSignatureMismatch) { + continue + } return err } event.Raw = log @@ -1247,6 +1259,10 @@ func (_IQuorum *IQuorumFilterer) WatchClaimSubmitted(opts *bind.WatchOpts, sink // New log arrived, parse the event and forward to the user event := new(IQuorumClaimSubmitted) if err := _IQuorum.contract.UnpackLog(event, "ClaimSubmitted", log); err != nil { + // If the signature doesn't match, skip this log. + if errors.Is(err, bind.ErrEventSignatureMismatch) { + continue + } return err } event.Raw = log diff --git a/pkg/contracts/iquorumfactory/iquorumfactory.go b/pkg/contracts/iquorumfactory/iquorumfactory.go index 3fdbc699a..690b9686f 100644 --- a/pkg/contracts/iquorumfactory/iquorumfactory.go +++ b/pkg/contracts/iquorumfactory/iquorumfactory.go @@ -4,9 +4,11 @@ package iquorumfactory import ( + "context" "errors" "math/big" "strings" + "time" ethereum "github.com/ethereum/go-ethereum" "github.com/ethereum/go-ethereum/accounts/abi" @@ -27,6 +29,8 @@ var ( _ = types.BloomLookup _ = event.NewSubscription _ = abi.ConvertType + _ = time.Tick + _ = context.Background ) // IQuorumFactoryMetaData contains all meta data concerning the IQuorumFactory contract. @@ -415,6 +419,10 @@ func (_IQuorumFactory *IQuorumFactoryFilterer) WatchQuorumCreated(opts *bind.Wat // New log arrived, parse the event and forward to the user event := new(IQuorumFactoryQuorumCreated) if err := _IQuorumFactory.contract.UnpackLog(event, "QuorumCreated", log); err != nil { + // If the signature doesn't match, skip this log. + if errors.Is(err, bind.ErrEventSignatureMismatch) { + continue + } return err } event.Raw = log diff --git a/pkg/contracts/iselfhostedapplicationfactory/iselfhostedapplicationfactory.go b/pkg/contracts/iselfhostedapplicationfactory/iselfhostedapplicationfactory.go index 1aef2ddc5..f0f9a112c 100644 --- a/pkg/contracts/iselfhostedapplicationfactory/iselfhostedapplicationfactory.go +++ b/pkg/contracts/iselfhostedapplicationfactory/iselfhostedapplicationfactory.go @@ -4,9 +4,11 @@ package iselfhostedapplicationfactory import ( + "context" "errors" "math/big" "strings" + "time" ethereum "github.com/ethereum/go-ethereum" "github.com/ethereum/go-ethereum/accounts/abi" @@ -27,6 +29,8 @@ var ( _ = types.BloomLookup _ = event.NewSubscription _ = abi.ConvertType + _ = time.Tick + _ = context.Background ) // WithdrawalConfig is an auto generated low-level Go binding around an user-defined struct. diff --git a/pkg/contracts/itournament/itournament.go b/pkg/contracts/itournament/itournament.go index 9dfabe224..767bc07dd 100644 --- a/pkg/contracts/itournament/itournament.go +++ b/pkg/contracts/itournament/itournament.go @@ -4,9 +4,11 @@ package itournament import ( + "context" "errors" "math/big" "strings" + "time" ethereum "github.com/ethereum/go-ethereum" "github.com/ethereum/go-ethereum/accounts/abi" @@ -27,6 +29,8 @@ var ( _ = types.BloomLookup _ = event.NewSubscription _ = abi.ConvertType + _ = time.Tick + _ = context.Background ) // ITournamentBisectingMatchView is an auto generated low-level Go binding around an user-defined struct. @@ -1166,6 +1170,10 @@ func (_ITournament *ITournamentFilterer) WatchBondRecovered(opts *bind.WatchOpts // New log arrived, parse the event and forward to the user event := new(ITournamentBondRecovered) if err := _ITournament.contract.UnpackLog(event, "BondRecovered", log); err != nil { + // If the signature doesn't match, skip this log. + if errors.Is(err, bind.ErrEventSignatureMismatch) { + continue + } return err } event.Raw = log @@ -1322,6 +1330,10 @@ func (_ITournament *ITournamentFilterer) WatchCommitmentJoined(opts *bind.WatchO // New log arrived, parse the event and forward to the user event := new(ITournamentCommitmentJoined) if err := _ITournament.contract.UnpackLog(event, "CommitmentJoined", log); err != nil { + // If the signature doesn't match, skip this log. + if errors.Is(err, bind.ErrEventSignatureMismatch) { + continue + } return err } event.Raw = log @@ -1467,6 +1479,10 @@ func (_ITournament *ITournamentFilterer) WatchLeafMatchSealed(opts *bind.WatchOp // New log arrived, parse the event and forward to the user event := new(ITournamentLeafMatchSealed) if err := _ITournament.contract.UnpackLog(event, "LeafMatchSealed", log); err != nil { + // If the signature doesn't match, skip this log. + if errors.Is(err, bind.ErrEventSignatureMismatch) { + continue + } return err } event.Raw = log @@ -1615,6 +1631,10 @@ func (_ITournament *ITournamentFilterer) WatchMatchAdvanced(opts *bind.WatchOpts // New log arrived, parse the event and forward to the user event := new(ITournamentMatchAdvanced) if err := _ITournament.contract.UnpackLog(event, "MatchAdvanced", log); err != nil { + // If the signature doesn't match, skip this log. + if errors.Is(err, bind.ErrEventSignatureMismatch) { + continue + } return err } event.Raw = log @@ -1779,6 +1799,10 @@ func (_ITournament *ITournamentFilterer) WatchMatchCreated(opts *bind.WatchOpts, // New log arrived, parse the event and forward to the user event := new(ITournamentMatchCreated) if err := _ITournament.contract.UnpackLog(event, "MatchCreated", log); err != nil { + // If the signature doesn't match, skip this log. + if errors.Is(err, bind.ErrEventSignatureMismatch) { + continue + } return err } event.Raw = log @@ -1943,6 +1967,10 @@ func (_ITournament *ITournamentFilterer) WatchMatchDeleted(opts *bind.WatchOpts, // New log arrived, parse the event and forward to the user event := new(ITournamentMatchDeleted) if err := _ITournament.contract.UnpackLog(event, "MatchDeleted", log); err != nil { + // If the signature doesn't match, skip this log. + if errors.Is(err, bind.ErrEventSignatureMismatch) { + continue + } return err } event.Raw = log @@ -2096,6 +2124,10 @@ func (_ITournament *ITournamentFilterer) WatchNewInnerTournament(opts *bind.Watc // New log arrived, parse the event and forward to the user event := new(ITournamentNewInnerTournament) if err := _ITournament.contract.UnpackLog(event, "NewInnerTournament", log); err != nil { + // If the signature doesn't match, skip this log. + if errors.Is(err, bind.ErrEventSignatureMismatch) { + continue + } return err } event.Raw = log @@ -2252,6 +2284,10 @@ func (_ITournament *ITournamentFilterer) WatchPartialBondRefund(opts *bind.Watch // New log arrived, parse the event and forward to the user event := new(ITournamentPartialBondRefund) if err := _ITournament.contract.UnpackLog(event, "PartialBondRefund", log); err != nil { + // If the signature doesn't match, skip this log. + if errors.Is(err, bind.ErrEventSignatureMismatch) { + continue + } return err } event.Raw = log diff --git a/pkg/contracts/iusdwithdrawaloutputbuilder/iusdwithdrawaloutputbuilder.go b/pkg/contracts/iusdwithdrawaloutputbuilder/iusdwithdrawaloutputbuilder.go index bf5504b5c..037f31930 100644 --- a/pkg/contracts/iusdwithdrawaloutputbuilder/iusdwithdrawaloutputbuilder.go +++ b/pkg/contracts/iusdwithdrawaloutputbuilder/iusdwithdrawaloutputbuilder.go @@ -4,9 +4,11 @@ package iusdwithdrawaloutputbuilder import ( + "context" "errors" "math/big" "strings" + "time" ethereum "github.com/ethereum/go-ethereum" "github.com/ethereum/go-ethereum/accounts/abi" @@ -27,6 +29,8 @@ var ( _ = types.BloomLookup _ = event.NewSubscription _ = abi.ConvertType + _ = time.Tick + _ = context.Background ) // IUsdWithdrawalOutputBuilderMetaData contains all meta data concerning the IUsdWithdrawalOutputBuilder contract. diff --git a/pkg/contracts/outputs/outputs.go b/pkg/contracts/outputs/outputs.go index 77e96a1a0..cc0814151 100644 --- a/pkg/contracts/outputs/outputs.go +++ b/pkg/contracts/outputs/outputs.go @@ -4,9 +4,11 @@ package outputs import ( + "context" "errors" "math/big" "strings" + "time" ethereum "github.com/ethereum/go-ethereum" "github.com/ethereum/go-ethereum/accounts/abi" @@ -27,6 +29,8 @@ var ( _ = types.BloomLookup _ = event.NewSubscription _ = abi.ConvertType + _ = time.Tick + _ = context.Background ) // OutputsMetaData contains all meta data concerning the Outputs contract. diff --git a/pkg/ethutil/bip32.go b/pkg/ethutil/bip32.go new file mode 100644 index 000000000..fbea7514a --- /dev/null +++ b/pkg/ethutil/bip32.go @@ -0,0 +1,84 @@ +// (c) Cartesi and individual authors (see AUTHORS) +// SPDX-License-Identifier: Apache-2.0 (see LICENSE) + +package ethutil + +import ( + "crypto/hmac" + "crypto/sha512" + "encoding/binary" + "fmt" + "math/big" + + "github.com/ethereum/go-ethereum/crypto" +) + +// Minimal BIP-32 private key derivation over go-ethereum's secp256k1 curve. +// See https://github.com/bitcoin/bips/blob/master/bip-0032.mediawiki + +// hardenedKeyStart is the first child index that requires the parent private key. +const hardenedKeyStart uint32 = 0x80000000 + +// scalarSize is the length in bytes of a serialized secp256k1 scalar. +const scalarSize = 32 + +// masterKeySalt is the HMAC key BIP-32 mandates for master key generation. +var masterKeySalt = []byte("Bitcoin seed") + +// extendedKey is a BIP-32 extended private key: a secp256k1 scalar paired with +// the chain code that seeds the derivation of its children. +type extendedKey struct { + key []byte // scalarSize bytes, big endian + chainCode []byte +} + +// newMasterKey derives the master extended private key from a BIP-39 seed. +func newMasterKey(seed []byte) (*extendedKey, error) { + mac := hmac.New(sha512.New, masterKeySalt) + mac.Write(seed) + sum := mac.Sum(nil) + + key := new(big.Int).SetBytes(sum[:scalarSize]) + if key.Sign() == 0 || key.Cmp(crypto.S256().Params().N) >= 0 { + return nil, fmt.Errorf("seed produces an invalid master key") + } + return &extendedKey{key: sum[:scalarSize], chainCode: sum[scalarSize:]}, nil +} + +// childKey derives the child of k at index, following BIP-32 CKDpriv. +// Indexes at or above hardenedKeyStart derive hardened children. +func (k *extendedKey) childKey(index uint32) (*extendedKey, error) { + mac := hmac.New(sha512.New, k.chainCode) + if index >= hardenedKeyStart { + mac.Write([]byte{0}) + mac.Write(k.key) + } else { + parent, err := crypto.ToECDSA(k.key) + if err != nil { + return nil, fmt.Errorf("invalid parent key: %w", err) + } + mac.Write(crypto.CompressPubkey(&parent.PublicKey)) + } + mac.Write(binary.BigEndian.AppendUint32(nil, index)) + sum := mac.Sum(nil) + + // The child key is (parse256(IL) + parent) mod n. BIP-32 requires the + // caller to move on to the next index in the astronomically unlikely case + // that IL is out of range or the sum is zero; report it instead, so that a + // wrong result can never be mistaken for a valid key. + order := crypto.S256().Params().N + child := new(big.Int).SetBytes(sum[:scalarSize]) + if child.Cmp(order) >= 0 { + return nil, fmt.Errorf("child %v is out of the curve order", index) + } + child.Add(child, new(big.Int).SetBytes(k.key)) + child.Mod(child, order) + if child.Sign() == 0 { + return nil, fmt.Errorf("child %v derives the zero key", index) + } + + return &extendedKey{ + key: child.FillBytes(make([]byte, scalarSize)), + chainCode: sum[scalarSize:], + }, nil +} diff --git a/pkg/ethutil/bip32_test.go b/pkg/ethutil/bip32_test.go new file mode 100644 index 000000000..0d55113ee --- /dev/null +++ b/pkg/ethutil/bip32_test.go @@ -0,0 +1,190 @@ +// (c) Cartesi and individual authors (see AUTHORS) +// SPDX-License-Identifier: Apache-2.0 (see LICENSE) + +package ethutil + +import ( + "encoding/hex" + "testing" + + "github.com/stretchr/testify/require" +) + +// The published BIP-32 test vectors. They show that this derivation agrees with +// the standard. See https://github.com/bitcoin/bips/blob/master/bip-0032.mediawiki +const ( + vector1Seed = "000102030405060708090a0b0c0d0e0f" + vector2Seed = "fffcf9f6f3f0edeae7e4e1dedbd8d5d2cfccc9c6c3c0bdbab7b4b1aeaba8a5a2" + + "9f9c999693908d8a8784817e7b7875726f6c696663605d5a5754514e4b484542" + vector3Seed = "4b381541583be4423346c643850da4b320e46a87ae3d2a4e6da11eba819cd4ac" + + "ba45d239319ac14f863b8d5ab5a0d0c64d2e8a1e7d1457df2e5a3c51c73235be" + vector4Seed = "3ddd5602285899a946114506157c7997e5444528f3003f6134712147db19b678" +) + +type bip32Vector struct { + name string + seed string + path []uint32 + key string + chainCode string +} + +// hardened returns the child index that derives a hardened child at index. +func hardened(index uint32) uint32 { return hardenedKeyStart + index } + +var bip32Vectors = []bip32Vector{{ + name: "vector 1, m", + seed: vector1Seed, + key: "e8f32e723decf4051aefac8e2c93c9c5b214313817cdb01a1494b917c8436b35", + chainCode: "873dff81c02f525623fd1fe5167eac3a55a049de3d314bb42ee227ffed37d508", +}, { + name: "vector 1, m/0'", + seed: vector1Seed, + path: []uint32{hardenedKeyStart}, + key: "edb2e14f9ee77d26dd93b4ecede8d16ed408ce149b6cd80b0715a2d911a0afea", + chainCode: "47fdacbd0f1097043b78c63c20c34ef4ed9a111d980047ad16282c7ae6236141", +}, { + name: "vector 1, m/0'/1", + seed: vector1Seed, + path: []uint32{hardenedKeyStart, 1}, + key: "3c6cb8d0f6a264c91ea8b5030fadaa8e538b020f0a387421a12de9319dc93368", + chainCode: "2a7857631386ba23dacac34180dd1983734e444fdbf774041578e9b6adb37c19", +}, { + name: "vector 1, m/0'/1/2'", + seed: vector1Seed, + path: []uint32{hardenedKeyStart, 1, hardened(2)}, + key: "cbce0d719ecf7431d88e6a89fa1483e02e35092af60c042b1df2ff59fa424dca", + chainCode: "04466b9cc8e161e966409ca52986c584f07e9dc81f735db683c3ff6ec7b1503f", +}, { + name: "vector 1, m/0'/1/2'/2", + seed: vector1Seed, + path: []uint32{hardenedKeyStart, 1, hardened(2), 2}, + key: "0f479245fb19a38a1954c5c7c0ebab2f9bdfd96a17563ef28a6a4b1a2a764ef4", + chainCode: "cfb71883f01676f587d023cc53a35bc7f88f724b1f8c2892ac1275ac822a3edd", +}, { + name: "vector 1, m/0'/1/2'/2/1000000000", + seed: vector1Seed, + path: []uint32{hardenedKeyStart, 1, hardened(2), 2, 1000000000}, + key: "471b76e389e528d6de6d816857e012c5455051cad6660850e58372a6c3e6e7c8", + chainCode: "c783e67b921d2beb8f6b389cc646d7263b4145701dadd2161548a8b078e65e9e", +}, { + // Vector 2 uses a 512-bit seed and the largest child indexes. + name: "vector 2, m", + seed: vector2Seed, + key: "4b03d6fc340455b363f51020ad3ecca4f0850280cf436c70c727923f6db46c3e", + chainCode: "60499f801b896d83179a4374aeb7822aaeaceaa0db1f85ee3e904c4defbd9689", +}, { + name: "vector 2, m/0", + seed: vector2Seed, + path: []uint32{0}, + key: "abe74a98f6c7eabee0428f53798f0ab8aa1bd37873999041703c742f15ac7e1e", + chainCode: "f0909affaa7ee7abe5dd4e100598d4dc53cd709d5a5c2cac40e7412f232f7c9c", +}, { + // The child index here is 0xffffffff, the largest possible value. + name: "vector 2, m/0/2147483647'", + seed: vector2Seed, + path: []uint32{0, hardened(2147483647)}, + key: "877c779ad9687164e9c2f4f0f4ff0340814392330693ce95a58fe18fd52e6e93", + chainCode: "be17a268474a6bb9c61e1d720cf6215e2a88c5406c4aee7b38547f585c9a37d9", +}, { + name: "vector 2, m/0/2147483647'/1", + seed: vector2Seed, + path: []uint32{0, hardened(2147483647), 1}, + key: "704addf544a06e5ee4bea37098463c23613da32020d604506da8c0518e1da4b7", + chainCode: "f366f48f1ea9f2d1d3fe958c95ca84ea18e4c4ddb9366c336c927eb246fb38cb", +}, { + name: "vector 2, m/0/2147483647'/1/2147483646'", + seed: vector2Seed, + path: []uint32{0, hardened(2147483647), 1, hardened(2147483646)}, + key: "f1c7c871a54a804afe328b4c83a1c33b8e5ff48f5087273f04efa83b247d6a2d", + chainCode: "637807030d55d01f9a0cb3a7839515d796bd07706386a6eddf06cc29a65a0e29", +}, { + name: "vector 2, m/0/2147483647'/1/2147483646'/2", + seed: vector2Seed, + path: []uint32{0, hardened(2147483647), 1, hardened(2147483646), 2}, + key: "bb7d39bdb83ecf58f2fd82b6d918341cbef428661ef01ab97c28a4842125ac23", + chainCode: "9452b549be8cea3ecb7a84bec10dcfd94afe4d129ebfd3b3cb58eedf394ed271", +}, { + // Vector 3 shows that the master key keeps its leading zero. + name: "vector 3, m", + seed: vector3Seed, + key: "00ddb80b067e0d4993197fe10f2657a844a384589847602d56f0c629c81aae32", + chainCode: "01d28a3e53cffa419ec122c968b3259e16b65076495494d97cae10bbfec3c36f", +}, { + name: "vector 3, m/0'", + seed: vector3Seed, + path: []uint32{hardenedKeyStart}, + key: "491f7a2eebc7b57028e0d3faa0acda02e75c33b03c48fb288c41e2ea44e1daef", + chainCode: "e5fea12a97b927fc9dc3d2cb0d1ea1cf50aa5a1fdc1f933e8906bb38df3377bd", +}, { + // Vector 4 shows that a derived key also keeps its leading zero. + name: "vector 4, m", + seed: vector4Seed, + key: "12c0d59c7aa3a10973dbd3f478b65f2516627e3fe61e00c345be9a477ad2e215", + chainCode: "d0c8a1f6edf2500798c3e0b54f1b56e45f6d03e6076abd36e5e2f54101e44ce6", +}, { + name: "vector 4, m/0'", + seed: vector4Seed, + path: []uint32{hardenedKeyStart}, + key: "00d948e9261e41362a688b916f297121ba6bfb2274a3575ac0e456551dfd7f7e", + chainCode: "cdc0f06456a14876c898790e0b3b1a41c531170aec69da44ff7b7265bfe7743b", +}, { + name: "vector 4, m/0'/1'", + seed: vector4Seed, + path: []uint32{hardenedKeyStart, hardened(1)}, + key: "3a2086edd7d9df86c3487a5905a1712a9aa664bce8cc268141e07549eaa8661d", + chainCode: "a48ee6674c5264a237703fd383bccd9fad4d9378ac98ab05e6e7029b06360c0d", +}} + +// derive walks path from the master key of seed. +func derive(t *testing.T, seed string, path []uint32) *extendedKey { + t.Helper() + raw, err := hex.DecodeString(seed) + require.Nil(t, err) + + key, err := newMasterKey(raw) + require.Nil(t, err) + for _, index := range path { + key, err = key.childKey(index) + require.Nil(t, err) + } + return key +} + +func TestBIP32Vectors(t *testing.T) { + for _, v := range bip32Vectors { + t.Run(v.name, func(t *testing.T) { + key := derive(t, v.seed, v.path) + require.Equal(t, v.key, hex.EncodeToString(key.key)) + require.Equal(t, v.chainCode, hex.EncodeToString(key.chainCode)) + // A short key would still print the same hex, so check the length. + require.Len(t, key.key, scalarSize) + require.Len(t, key.chainCode, scalarSize) + }) + } +} + +// TestHardenedChildDiffers shows that the two branches of childKey do not +// derive the same child. Index n and index n' must give different keys. +func TestHardenedChildDiffers(t *testing.T) { + master := derive(t, vector1Seed, nil) + + normal, err := master.childKey(1) + require.Nil(t, err) + hard, err := master.childKey(hardened(1)) + require.Nil(t, err) + + require.NotEqual(t, normal.key, hard.key) + require.NotEqual(t, normal.chainCode, hard.chainCode) +} + +// TestChildKeyRejectsInvalidParent shows that childKey does not derive a child +// from a parent key that is not on the curve. +func TestChildKeyRejectsInvalidParent(t *testing.T) { + invalid := &extendedKey{ + key: make([]byte, scalarSize), + chainCode: make([]byte, scalarSize), + } + _, err := invalid.childKey(0) + require.Error(t, err) +} diff --git a/pkg/ethutil/client.go b/pkg/ethutil/client.go index 89bda63e9..68f1dab71 100644 --- a/pkg/ethutil/client.go +++ b/pkg/ethutil/client.go @@ -77,8 +77,10 @@ func NewEthClient( rclient.HTTPClient.Timeout = retryConfig.RequestTimeout rclient.Backoff = retryBackoff + httpClient := rclient.StandardClient() + httpClient.Transport = nullErrorTransport{next: httpClient.Transport} opts := []rpc.ClientOption{ - rpc.WithHTTPClient(rclient.StandardClient()), + rpc.WithHTTPClient(httpClient), } for _, opt := range rpcOptions { if opt != nil { @@ -95,6 +97,18 @@ func NewEthClient( return ethclient.NewClient(rpcClient), nil } +// DialEthClient connects to an Ethereum JSON-RPC endpoint like +// ethclient.DialContext, and accepts a null error member in the responses like +// NewEthClient. +func DialEthClient(ctx context.Context, endpoint string) (*ethclient.Client, error) { + httpClient := &http.Client{Transport: nullErrorTransport{next: http.DefaultTransport}} + rpcClient, err := rpc.DialOptions(ctx, endpoint, rpc.WithHTTPClient(httpClient)) + if err != nil { + return nil, err + } + return ethclient.NewClient(rpcClient), nil +} + // retryBackoff caps server-directed Retry-After delays while preserving the // library's default exponential backoff for every other case. func retryBackoff(minDuration, maxDuration time.Duration, attemptNum int, resp *http.Response) time.Duration { diff --git a/pkg/ethutil/mnemonic.go b/pkg/ethutil/mnemonic.go index 777e2b9cb..ba068f0af 100644 --- a/pkg/ethutil/mnemonic.go +++ b/pkg/ethutil/mnemonic.go @@ -5,11 +5,11 @@ package ethutil import ( "crypto/ecdsa" + "errors" "fmt" "github.com/ethereum/go-ethereum/common" "github.com/ethereum/go-ethereum/crypto" - "github.com/tyler-smith/go-bip32" "github.com/tyler-smith/go-bip39" ) @@ -25,18 +25,21 @@ func PrivateKeyToAddress(privateKey *ecdsa.PrivateKey) (common.Address, error) { // Create the private key from mnemonic and account index based on the BIP44 standard. // For more info on BIP44, see https://github.com/bitcoin/bips/blob/master/bip-0044.mediawiki func MnemonicToPrivateKey(mnemonic string, accountIndex uint32) (*ecdsa.PrivateKey, error) { + // An index from 2^31 up selects a hardened child, which is a different path. + if accountIndex >= hardenedKeyStart { + return nil, errors.New("account index must be below 2^31") + } seed, err := bip39.NewSeedWithErrorChecking(mnemonic, "") if err != nil { return nil, err } - masterKey, err := bip32.NewMasterKey(seed) + masterKey, err := newMasterKey(seed) if err != nil { return nil, fmt.Errorf("failed to generate master key: %w", err) } // get key at path m/44'/60'/0'/0/account - const hardenedKeyStart uint32 = 0x80000000 levels := []uint32{ hardenedKeyStart + 44, hardenedKeyStart + 60, @@ -46,11 +49,11 @@ func MnemonicToPrivateKey(mnemonic string, accountIndex uint32) (*ecdsa.PrivateK } key := masterKey for i, level := range levels { - key, err = key.NewChildKey(level) + key, err = key.childKey(level) if err != nil { return nil, fmt.Errorf("failed to get child %v: %w", i, err) } } - return crypto.ToECDSA(key.Key) + return crypto.ToECDSA(key.key) } diff --git a/pkg/ethutil/mnemonic_test.go b/pkg/ethutil/mnemonic_test.go index 65144fa88..1c74c4b21 100644 --- a/pkg/ethutil/mnemonic_test.go +++ b/pkg/ethutil/mnemonic_test.go @@ -4,23 +4,70 @@ package ethutil import ( + "math" + "strconv" "testing" "github.com/ethereum/go-ethereum/crypto" "github.com/stretchr/testify/require" ) -func testKey(t *testing.T, mnemonic string, account uint32, expected string) { - expectedKey, err := crypto.HexToECDSA(expected) - require.Nil(t, err) - - key, err := MnemonicToPrivateKey(mnemonic, account) - require.Nil(t, err) - require.Equal(t, expectedKey, key) +// The accounts that Anvil makes from FoundryMnemonic. They show that the full +// BIP-39 and BIP-44 path gives the keys that the devnet expects. +var foundryAccounts = []struct { + key string + address string +}{ + {"ac0974bec39a17e36ba4a6b4d238ff944bacb478cbed5efcae784d7bf4f2ff80", "0xf39Fd6e51aad88F6F4ce6aB8827279cffFb92266"}, + {"59c6995e998f97a5a0044966f0945389dc9e86dae88c7a8412f4603b6b78690d", "0x70997970C51812dc3A010C7d01b50e0d17dc79C8"}, + {"5de4111afa1a4b94908f83103eb1f1706367c2e68ca870fc3fb9a804cdab365a", "0x3C44CdDdB6a900fa2b585dd299e03d12FA4293BC"}, + {"7c852118294e51e653712a81e05800f419141751be58f605c371e15141b007a6", "0x90F79bf6EB2c4f870365E785982E1f101E93b906"}, + {"47e179ec197488593b187f80a00eb0da91f1b9d0b13f8733639f19c30a34926a", "0x15d34AAf54267DB7D7c367839AAf71A00a2C6A65"}, + {"8b3a350cf5c34c9194ca85829a2df0ec3153be0318b5e2d3348e872092edffba", "0x9965507D1a55bcC2695C58ba16FB37d819B0A4dc"}, + {"92db14e403b83dfe3df233f83dfa3a0d7096f21ca9b0d6d6b8d88b2b4ec1564e", "0x976EA74026E726554dB657fA54763abd0C3a0aa9"}, + {"4bbbf85ce3377467afe5d46f804f221813b2bb87f24d81f60f1fcdbf7cbf4356", "0x14dC79964da2C08b23698B3D3cc7Ca32193d9955"}, + {"dbda1821b80551c9d65939329250298aa3472ba22feea921c0cf5d620ea67b97", "0x23618e81E3f5cdF7f54C3d65f7FBc0aBf5B21E8f"}, + {"2a871d0798f97d79848a013d4936a73bf4cc922c825d33c1cf7073dff6d409c6", "0xa0Ee7A142d267C1f36714E4a8F75612F20a79720"}, } func TestMnemonicToPrivateKey(t *testing.T) { - mnemonic := "test test test test test test test test test test test junk" - testKey(t, mnemonic, 0, "ac0974bec39a17e36ba4a6b4d238ff944bacb478cbed5efcae784d7bf4f2ff80") - testKey(t, mnemonic, 1, "59c6995e998f97a5a0044966f0945389dc9e86dae88c7a8412f4603b6b78690d") + for index, account := range foundryAccounts { + expected, err := crypto.HexToECDSA(account.key) + require.Nil(t, err) + + key, err := MnemonicToPrivateKey(FoundryMnemonic, uint32(index)) + require.Nil(t, err) + require.Equal(t, expected, key) + + address, err := PrivateKeyToAddress(key) + require.Nil(t, err) + require.Equal(t, account.address, address.Hex()) + } +} + +func TestMnemonicToPrivateKeyRejectsBadMnemonic(t *testing.T) { + for _, mnemonic := range []string{ + "", + "test test test test test test test test test test test test", // bad checksum + "cartesi test test test test test test test test test test junk", + "test test test test test test test test test test junk", // 11 words + } { + _, err := MnemonicToPrivateKey(mnemonic, 0) + require.Error(t, err, "mnemonic %q", mnemonic) + } +} + +func TestPrivateKeyToAddressRejectsNil(t *testing.T) { + _, err := PrivateKeyToAddress(nil) + require.Error(t, err) +} + +func TestMnemonicToPrivateKeyRejectsHardenedIndex(t *testing.T) { + for _, index := range []uint32{hardenedKeyStart, hardenedKeyStart + 6, math.MaxUint32} { + _, err := MnemonicToPrivateKey(FoundryMnemonic, index) + require.Error(t, err, "index %v", index) + require.NotContains(t, err.Error(), strconv.FormatUint(uint64(index), 10)) + } + _, err := MnemonicToPrivateKey(FoundryMnemonic, hardenedKeyStart-1) + require.NoError(t, err) } diff --git a/pkg/ethutil/rpc_response.go b/pkg/ethutil/rpc_response.go new file mode 100644 index 000000000..be98fd8b8 --- /dev/null +++ b/pkg/ethutil/rpc_response.go @@ -0,0 +1,87 @@ +// (c) Cartesi and individual authors (see AUTHORS) +// SPDX-License-Identifier: Apache-2.0 (see LICENSE) + +package ethutil + +import ( + "bytes" + "encoding/json" + "fmt" + "io" + "net/http" +) + +// nullErrorTransport removes a null "error" member from JSON-RPC responses. +// JSON-RPC 2.0 forbids that member in a successful response, but some providers +// send it as null, and go-ethereum reports any error member as a failure since +// v1.17.5. +type nullErrorTransport struct { + next http.RoundTripper +} + +func (t nullErrorTransport) RoundTrip(req *http.Request) (*http.Response, error) { + resp, err := t.next.RoundTrip(req) + if err != nil { + return nil, err + } + body, err := io.ReadAll(resp.Body) + resp.Body.Close() + if err != nil { + return nil, fmt.Errorf("read rpc response: %w", err) + } + if fixed, changed := dropNullError(body); changed { + body = fixed + resp.ContentLength = int64(len(body)) + resp.Header.Del("Content-Length") + } + resp.Body = io.NopCloser(bytes.NewReader(body)) + return resp, nil +} + +var errorMemberName = []byte(`"error"`) + +// dropNullError removes a null "error" member from a JSON-RPC response or from +// each response of a batch. It reports whether it changed the body, and it leaves +// a body that is not a JSON object or array of objects alone. +func dropNullError(body []byte) ([]byte, bool) { + if !bytes.Contains(body, errorMemberName) { + return body, false + } + trimmed := bytes.TrimLeft(body, " \t\r\n") + if len(trimmed) > 0 && trimmed[0] == '[' { + var batch []map[string]json.RawMessage + if json.Unmarshal(body, &batch) != nil { + return body, false + } + changed := false + for _, msg := range batch { + changed = dropNullErrorMember(msg) || changed + } + return marshalIfChanged(body, batch, changed) + } + var msg map[string]json.RawMessage + if json.Unmarshal(body, &msg) != nil { + return body, false + } + return marshalIfChanged(body, msg, dropNullErrorMember(msg)) +} + +func dropNullErrorMember(msg map[string]json.RawMessage) bool { + value, ok := msg["error"] + if !ok || !bytes.Equal(bytes.TrimSpace(value), []byte("null")) { + return false + } + delete(msg, "error") + return true +} + +func marshalIfChanged(body []byte, value any, changed bool) ([]byte, bool) { + if !changed { + return body, false + } + fixed, err := json.Marshal(value) + if err != nil { + return body, false + } + return fixed, true +} diff --git a/pkg/ethutil/rpc_response_test.go b/pkg/ethutil/rpc_response_test.go new file mode 100644 index 000000000..90aee5cc6 --- /dev/null +++ b/pkg/ethutil/rpc_response_test.go @@ -0,0 +1,105 @@ +// (c) Cartesi and individual authors (see AUTHORS) +// SPDX-License-Identifier: Apache-2.0 (see LICENSE) + +package ethutil + +import ( + "encoding/json" + "fmt" + "log/slog" + "net/http" + "net/http/httptest" + "testing" + "time" + + "github.com/stretchr/testify/require" +) + +func TestDropNullError(t *testing.T) { + tests := []struct { + name string + body string + want string // empty when the body must come back unchanged + }{ + { + name: "single response", + body: `{"jsonrpc":"2.0","id":1,"result":"0x10","error":null}`, + want: `{"jsonrpc":"2.0","id":1,"result":"0x10"}`, + }, + { + name: "batch response", + body: `[{"jsonrpc":"2.0","id":1,"result":"0x1","error":null},` + + `{"jsonrpc":"2.0","id":2,"error":{"code":3,"message":"execution reverted"}}]`, + want: `[{"jsonrpc":"2.0","id":1,"result":"0x1"},` + + `{"jsonrpc":"2.0","id":2,"error":{"code":3,"message":"execution reverted"}}]`, + }, + { + name: "error object", + body: `{"jsonrpc":"2.0","id":1,"error":{"code":3,"message":"execution reverted"}}`, + }, + { + name: "no error member", + body: `{"jsonrpc":"2.0","id":1,"result":"0x10"}`, + }, + { + name: "error string in the result", + body: `{"jsonrpc":"2.0","id":1,"result":["error"]}`, + }, + { + name: "not JSON", + body: `"error" page`, + }, + } + for _, tc := range tests { + t.Run(tc.name, func(t *testing.T) { + got, changed := dropNullError([]byte(tc.body)) + if tc.want == "" { + require.False(t, changed) + require.Equal(t, tc.body, string(got)) + return + } + require.True(t, changed) + require.JSONEq(t, tc.want, string(got)) + }) + } +} + +// newNullErrorServer answers every JSON-RPC call with the result 0x10 and a null +// error member. +func newNullErrorServer(t *testing.T) *httptest.Server { + t.Helper() + server := httptest.NewServer(http.HandlerFunc(func(w http.ResponseWriter, r *http.Request) { + var request struct { + ID json.RawMessage `json:"id"` + } + if err := json.NewDecoder(r.Body).Decode(&request); err != nil { + http.Error(w, err.Error(), http.StatusBadRequest) + return + } + w.Header().Set("Content-Type", "application/json") + fmt.Fprintf(w, `{"jsonrpc":"2.0","id":%s,"result":"0x10","error":null}`, request.ID) + })) + t.Cleanup(server.Close) + return server +} + +func TestNewEthClientAcceptsNullError(t *testing.T) { + server := newNullErrorServer(t) + logger := slog.New(slog.DiscardHandler) + client, err := NewEthClient(t.Context(), server.URL, logger, RetryConfig{RequestTimeout: time.Second}) + require.NoError(t, err) + defer client.Close() + number, err := client.BlockNumber(t.Context()) + require.NoError(t, err) + require.Equal(t, uint64(16), number) +} + +func TestDialEthClientAcceptsNullError(t *testing.T) { + server := newNullErrorServer(t) + client, err := DialEthClient(t.Context(), server.URL) + require.NoError(t, err) + defer client.Close() + number, err := client.BlockNumber(t.Context()) + require.NoError(t, err) + require.Equal(t, uint64(16), number) +} diff --git a/pkg/inspectclient/generated.go b/pkg/inspectclient/generated.go index 549403c10..aa7cea639 100644 --- a/pkg/inspectclient/generated.go +++ b/pkg/inspectclient/generated.go @@ -1,6 +1,6 @@ // Package inspectclient provides primitives to interact with the openapi HTTP API. // -// Code generated by github.com/deepmap/oapi-codegen/v2 version v2.2.0 DO NOT EDIT. +// Code generated by github.com/oapi-codegen/oapi-codegen/v2 version v2.8.0 DO NOT EDIT. package inspectclient import ( @@ -24,25 +24,51 @@ const ( Rejected CompletionStatus = "Rejected" ) +// Valid indicates whether the value is a known member of the CompletionStatus enum. +func (e CompletionStatus) Valid() bool { + switch e { + case Accepted: + return true + case Exception: + return true + case Failed: + return true + case MachineHalted: + return true + case Rejected: + return true + default: + return false + } +} + // CompletionStatus How inspection completed. MachineHalted means the temporary inspect // execution halted; the canonical application machine is unchanged. // Failed means the node could not complete inspection because of an // operational limit, cancellation, timeout, protocol error, or internal // failure. Reports returned with Failed may be partial. +// +// Example: Accepted type CompletionStatus string // Error Detailed error message. +// +// Example: The request could not be understood by the server due to malformed syntax type Error = string // InspectResult defines model for InspectResult. type InspectResult struct { // Error Sanitized error description, present only when status is Exception or Failed + // + // Example: The node could not complete the inspection Error *string `json:"error,omitempty"` // ExceptionData Raw guest-provided CMIO exception payload, present only when status is Exception ExceptionData *Payload `json:"exception_data,omitempty"` // ProcessedInputCount Number of processed inputs since genesis + // + // Example: 0 ProcessedInputCount int `json:"processed_input_count"` // Reports Reports emitted before completion; for Failed, this may be only a partial prefix @@ -53,6 +79,9 @@ type InspectResult struct { // Failed means the node could not complete inspection because of an // operational limit, cancellation, timeout, protocol error, or internal // failure. Reports returned with Failed may be partial. + // + // + // Example: Accepted Status CompletionStatus `json:"status"` } @@ -60,6 +89,8 @@ type InspectResult struct { // The first two characters are '0x' followed by pairs of hexadecimal numbers that correspond to one byte. // For instance, '0xdeadbeef' corresponds to a payload with length 4 and bytes 222, 173, 190, 175. // An empty payload is represented by the string '0x'. +// +// Example: 0xdeadbeef type Payload = string // Report defines model for Report. @@ -68,10 +99,13 @@ type Report struct { // The first two characters are '0x' followed by pairs of hexadecimal numbers that correspond to one byte. // For instance, '0xdeadbeef' corresponds to a payload with length 4 and bytes 222, 173, 190, 175. // An empty payload is represented by the string '0x'. + // + // + // Example: 0xdeadbeef Payload Payload `json:"payload"` } -// RequestEditorFn is the function signature for the RequestEditor callback function +// RequestEditorFn is the function signature for the RequestEditor callback function type RequestEditorFn func(ctx context.Context, req *http.Request) error // Doer performs HTTP requests. @@ -144,10 +178,32 @@ func WithRequestEditorFn(fn RequestEditorFn) ClientOption { // The interface specification for the client above. type ClientInterface interface { - // InspectPostWithBody request with any body + + // InspectPostWithBody Inspect DApp state via POST + // + // This POST method sends an inspect-state request to the DApp backend, using the body contents as a binary payload for the inspect method. + // + // The response includes the inspection completion status, reports generated by the DApp backend, and the number of previously processed inputs. The optional `error` field contains a sanitized description when the status is `Exception` or `Failed`. For `Exception`, `exception_data` contains the raw CMIO payload supplied by the guest. + // + // The inspect operation is executed on a temporary fork of the machine created upon request arrival, which is discarded afterward. Note that this method is synchronous and not recommended for resource-intensive operations. + // + // Takes any type of body and a specified content type. + // + // Corresponds with POST inspect/{dapp} (the `InspectPost` operationId). InspectPostWithBody(ctx context.Context, dapp string, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) } +// InspectPostWithBody Inspect DApp state via POST +// +// This POST method sends an inspect-state request to the DApp backend, using the body contents as a binary payload for the inspect method. +// +// The response includes the inspection completion status, reports generated by the DApp backend, and the number of previously processed inputs. The optional `error` field contains a sanitized description when the status is `Exception` or `Failed`. For `Exception`, `exception_data` contains the raw CMIO payload supplied by the guest. +// +// The inspect operation is executed on a temporary fork of the machine created upon request arrival, which is discarded afterward. Note that this method is synchronous and not recommended for resource-intensive operations. +// +// Takes any type of body and a specified content type. +// +// Corresponds with POST inspect/{dapp} (the `InspectPost` operationId). func (c *Client) InspectPostWithBody(ctx context.Context, dapp string, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { req, err := NewInspectPostRequestWithBody(c.Server, dapp, contentType, body) if err != nil { @@ -160,13 +216,13 @@ func (c *Client) InspectPostWithBody(ctx context.Context, dapp string, contentTy return c.Client.Do(req) } -// NewInspectPostRequestWithBody generates requests for InspectPost with any type of body +// NewInspectPostRequestWithBody constructs an http.Request for the InspectPost method, with any body, and a specified content type func NewInspectPostRequestWithBody(server string, dapp string, contentType string, body io.Reader) (*http.Request, error) { var err error var pathParam0 string - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "dapp", runtime.ParamLocationPath, dapp) + pathParam0, err = runtime.StyleParamWithOptions("simple", false, "dapp", dapp, runtime.StyleParamOptions{ParamLocation: runtime.ParamLocationPath, Type: "string", Format: ""}) if err != nil { return nil, err } @@ -186,7 +242,7 @@ func NewInspectPostRequestWithBody(server string, dapp string, contentType strin return nil, err } - req, err := http.NewRequest("POST", queryURL.String(), body) + req, err := http.NewRequest(http.MethodPost, queryURL.String(), body) if err != nil { return nil, err } @@ -239,14 +295,36 @@ func WithBaseURL(baseURL string) ClientOption { // ClientWithResponsesInterface is the interface specification for the client with responses above. type ClientWithResponsesInterface interface { - // InspectPostWithBodyWithResponse request with any body + + // InspectPostWithBodyWithResponse Inspect DApp state via POST + // + // This POST method sends an inspect-state request to the DApp backend, using the body contents as a binary payload for the inspect method. + // + // The response includes the inspection completion status, reports generated by the DApp backend, and the number of previously processed inputs. The optional `error` field contains a sanitized description when the status is `Exception` or `Failed`. For `Exception`, `exception_data` contains the raw CMIO payload supplied by the guest. + // + // The inspect operation is executed on a temporary fork of the machine created upon request arrival, which is discarded afterward. Note that this method is synchronous and not recommended for resource-intensive operations. + // + // Takes any type of body and a specified content type, and returns a wrapper object for the known response body format(s). + // + // Corresponds with POST inspect/{dapp} (the `InspectPost` operationId). InspectPostWithBodyWithResponse(ctx context.Context, dapp string, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*InspectPostResponse, error) } type InspectPostResponse struct { Body []byte HTTPResponse *http.Response - JSON200 *InspectResult + // JSON200 the response for an HTTP 200 `application/json` response + JSON200 *InspectResult +} + +// GetJSON200 returns the response for an HTTP 200 `application/json` response +func (r InspectPostResponse) GetJSON200() *InspectResult { + return r.JSON200 +} + +// GetBody returns the raw response body bytes +func (r InspectPostResponse) GetBody() []byte { + return r.Body } // Status returns HTTPResponse.Status @@ -265,7 +343,25 @@ func (r InspectPostResponse) StatusCode() int { return 0 } -// InspectPostWithBodyWithResponse request with arbitrary body returning *InspectPostResponse +// ContentType is a convenience method to retrieve the Content-Type value from the HTTP response headers +func (r InspectPostResponse) ContentType() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Header.Get("Content-Type") + } + return "" +} + +// InspectPostWithBodyWithResponse Inspect DApp state via POST +// +// This POST method sends an inspect-state request to the DApp backend, using the body contents as a binary payload for the inspect method. +// +// The response includes the inspection completion status, reports generated by the DApp backend, and the number of previously processed inputs. The optional `error` field contains a sanitized description when the status is `Exception` or `Failed`. For `Exception`, `exception_data` contains the raw CMIO payload supplied by the guest. +// +// The inspect operation is executed on a temporary fork of the machine created upon request arrival, which is discarded afterward. Note that this method is synchronous and not recommended for resource-intensive operations. +// +// Takes any type of body and a specified content type, and returns a wrapper object for the known response body format(s). +// +// Corresponds with POST inspect/{dapp} (the `InspectPost` operationId). func (c *ClientWithResponses) InspectPostWithBodyWithResponse(ctx context.Context, dapp string, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*InspectPostResponse, error) { rsp, err := c.InspectPostWithBody(ctx, dapp, contentType, body, reqEditors...) if err != nil { diff --git a/pkg/inspectclient/main.go b/pkg/inspectclient/main.go index a816b2ec8..cd3c84b47 100644 --- a/pkg/inspectclient/main.go +++ b/pkg/inspectclient/main.go @@ -5,4 +5,4 @@ // to query the Rollups GraphQL API package inspectclient -//go:generate go run github.com/deepmap/oapi-codegen/v2/cmd/oapi-codegen -generate types,client -o generated.go -package inspectclient ../../api/openapi/inspect.yaml +//go:generate go run github.com/oapi-codegen/oapi-codegen/v2/cmd/oapi-codegen -generate types,client -o generated.go -package inspectclient ../../api/openapi/inspect.yaml diff --git a/pkg/service/service.go b/pkg/service/service.go index 8b938c1ec..65ed89952 100644 --- a/pkg/service/service.go +++ b/pkg/service/service.go @@ -73,6 +73,6 @@ func NewLogger(name string, level slog.Level, color bool) *slog.Logger { TimeFormat: "2006-01-02T15:04:05.000", NoColor: !color, } - handler := tint.NewHandler(os.Stdout, opts) + handler := tint.NewTextHandler(os.Stdout, opts) return slog.New(handler).With("service", name) }