From 4309859bf153ba3bbdf4b4401365348386f28f9e Mon Sep 17 00:00:00 2001 From: Amaury Martiny Date: Fri, 6 Nov 2020 02:25:38 +0100 Subject: [PATCH 01/24] Small fixes in docs and error messages (#7826) * Small fixes in docs and error messages * Add chain id Co-authored-by: Federico Kunze <31522760+fedekunze@users.noreply.github.com> --- docs/run-node/interact-node.md | 8 ++++---- docs/run-node/keyring.md | 2 +- docs/run-node/run-node.md | 8 ++++---- types/tx/types.go | 2 +- 4 files changed, 10 insertions(+), 10 deletions(-) diff --git a/docs/run-node/interact-node.md b/docs/run-node/interact-node.md index 40cb58424..78c8b7500 100644 --- a/docs/run-node/interact-node.md +++ b/docs/run-node/interact-node.md @@ -19,10 +19,10 @@ simd query account $MY_VALIDATOR_ADDRESS --chain-id my-test-chain You should see the current balance of the account you created, equal to the original balance of `stake` you granted it minus the amount you delegated via the `gentx`. Now, create a second account: ```bash -simd keys add recipient +simd keys add recipient --keyring-backend test # Put the generated address in a variable for later use. -RECIPIENT=$(simd keys show recipient -a) +RECIPIENT=$(simd keys show recipient -a --keyring-backend test) ``` The command above creates a local key-pair that is not yet registered on the chain. An account is created the first time it receives tokens from another account. Now, run the following command to send tokens to the `recipient` account: @@ -37,10 +37,10 @@ simd query account $RECIPIENT --chain-id my-test-chain Finally, delegate some of the stake tokens sent to the `recipient` account to the validator: ```bash -simd tx staking delegate $(simd keys show my_validator --bech val -a) 500stake --from recipient --chain-id my-test-chain +simd tx staking delegate $(simd keys show my_validator --bech val -a --keyring-backend test) 500stake --from recipient --chain-id my-test-chain # Query the total delegations to `validator`. -simd query staking delegations-to $(simd keys show my_validator --bech val -a) --chain-id my-test-chain +simd query staking delegations-to $(simd keys show my_validator --bech val -a --keyring-backend test) --chain-id my-test-chain ``` You should see two delegations, the first one made from the `gentx`, and the second one you just performed from the `recipient` account. diff --git a/docs/run-node/keyring.md b/docs/run-node/keyring.md index c32b8dd93..9725007c9 100644 --- a/docs/run-node/keyring.md +++ b/docs/run-node/keyring.md @@ -115,7 +115,7 @@ To create a new key in the keyring, run the `add` subcommand with a `` $ simd keys add my_validator --keyring-backend test # Put the generated address in a variable for later use. -MY_VALIDATOR_ADDRESS=$(simd keys show my_validator -a) +MY_VALIDATOR_ADDRESS=$(simd keys show my_validator -a --keyring-backend test) ``` This command generates a new 24-word mnemonic phrase, persists it to the relevant backend, and outputs information about the keypair. If this keypair will be used to hold value-bearing tokens, be sure to write down the mnemonic phrase somewhere safe! diff --git a/docs/run-node/run-node.md b/docs/run-node/run-node.md index cda14436e..05708e63d 100644 --- a/docs/run-node/run-node.md +++ b/docs/run-node/run-node.md @@ -39,12 +39,12 @@ The `~/.simapp` folder has the following structure: |- priv_validator_key.json # Private key to use as a validator in the consensus protocol. ``` -Before starting the chain, you need to populate the state with at least one account. To do so, first [create a new account in the keyring](./keyring.md#adding-keys-to-the-keyring) named `my_validator` (feel free to choose another name). +Before starting the chain, you need to populate the state with at least one account. To do so, first [create a new account in the keyring](./keyring.md#adding-keys-to-the-keyring) named `my_validator` under the `test` keyring backend (feel free to choose another name and another backend). Now that you have created a local account, go ahead and grant it some `stake` tokens in your chain's genesis file. Doing so will also make sure your chain is aware of this account's existence: ```bash -simd add-genesis-account $(simd keys show my_validator -a) 100000000stake --chain-id my-test-chain +simd add-genesis-account $MY_VALIDATOR_ADDRESS 100000000stake ``` Recall that `$MY_VALIDATOR_ADDRESS` is a variable that holds the address of the `my_validator` key in the [keyring](./keyring.md#adding-keys-to-the-keyring). Also note that the tokens in the SDK have the `{amount}{denom}` format: `amount` is is a 18-digit-precision decimal number, and `denom` is the unique token identifier with its denomination key (e.g. `atom` or `uatom`). Here, we are granting `stake` tokens, as `stake` is the token identifier used for staking in [`simapp`](https://github.com/cosmos/cosmos-sdk/tree/v0.40.0-rc2/simapp). For your own chain with its own staking denom, that token identifier should be used instead. @@ -53,10 +53,10 @@ Now that your account has some tokens, you need to add a validator to your chain ```bash # Create a gentx. -simd gentx --name my_validator --amount 100000stake --chain-id my-test-chain +simd gentx my_validator --amount 100000stake --chain-id my-test-chain --keyring-backend test # Add the gentx to the genesis file. -simd collect-gentxs --chain-id my-test-chain +simd collect-gentxs ``` A `gentx` does three things: diff --git a/types/tx/types.go b/types/tx/types.go index e9066ef41..436f2cd9b 100644 --- a/types/tx/types.go +++ b/types/tx/types.go @@ -92,7 +92,7 @@ func (t *Tx) ValidateBasic() error { if len(sigs) != len(t.GetSigners()) { return sdkerrors.Wrapf( sdkerrors.ErrUnauthorized, - "wrong number of signers; expected %d, got %d", t.GetSigners(), len(sigs), + "wrong number of signers; expected %d, got %d", len(t.GetSigners()), len(sigs), ) } From 56c08d11171d32c1afec5053a48879cb639f429e Mon Sep 17 00:00:00 2001 From: Cory Date: Fri, 6 Nov 2020 02:13:52 -0800 Subject: [PATCH 02/24] Bump to tendermint v0.34-rc6 (#7828) * bump to tendermint v0.34-rc6 * update go.mod * tendermint version is now accessible as tmversion.TMCoreSemVer * add changelog entry Co-authored-by: Amaury Martiny --- CHANGELOG.md | 3 + Makefile | 2 +- go.mod | 2 +- go.sum | 10 + server/tm_cmds.go | 2 +- .../proto/tendermint/crypto/keys.proto | 3 +- .../proto/tendermint/types/evidence.proto | 35 +- x/staking/types/staking.pb.go | 1196 ++++++++--------- 8 files changed, 637 insertions(+), 616 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 01067c692..30a10deaf 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -36,6 +36,9 @@ Ref: https://keepachangelog.com/en/1.0.0/ ## [Unreleased] +### Improvements +* (tendermint) [\#7828](https://github.com/cosmos/cosmos-sdk/pull/7828) Update tendermint dependency to v0.34.0-rc6 + ## [v0.40.0-rc2](https://github.com/cosmos/cosmos-sdk/releases/tag/v0.40.0-rc2) - 2020-11-02 ### Client Breaking diff --git a/Makefile b/Makefile index dd21bbf2d..5eadb43a7 100644 --- a/Makefile +++ b/Makefile @@ -389,7 +389,7 @@ proto-check-breaking-docker: @$(DOCKER_BUF) check breaking --against-input $(HTTPS_GIT)#branch=master .PHONY: proto-check-breaking-ci -TM_URL = https://raw.githubusercontent.com/tendermint/tendermint/v0.34.0-rc5/proto/tendermint +TM_URL = https://raw.githubusercontent.com/tendermint/tendermint/v0.34.0-rc6/proto/tendermint GOGO_PROTO_URL = https://raw.githubusercontent.com/regen-network/protobuf/cosmos COSMOS_PROTO_URL = https://raw.githubusercontent.com/regen-network/cosmos-proto/master CONFIO_URL = https://raw.githubusercontent.com/confio/ics23/v0.6.3 diff --git a/go.mod b/go.mod index 0dcda260b..004cb69e0 100644 --- a/go.mod +++ b/go.mod @@ -45,7 +45,7 @@ require ( github.com/tendermint/btcd v0.1.1 github.com/tendermint/crypto v0.0.0-20191022145703-50d29ede1e15 github.com/tendermint/go-amino v0.16.0 - github.com/tendermint/tendermint v0.34.0-rc5 + github.com/tendermint/tendermint v0.34.0-rc6 github.com/tendermint/tm-db v0.6.2 golang.org/x/crypto v0.0.0-20201012173705-84dcc777aaee golang.org/x/net v0.0.0-20200930145003-4acb6c075d10 // indirect diff --git a/go.sum b/go.sum index 61fc2a908..6b5e5ed52 100644 --- a/go.sum +++ b/go.sum @@ -105,6 +105,7 @@ github.com/client9/misspell v0.3.4/go.mod h1:qj6jICC3Q7zFZvVWo7KLAzC3yx5G7kyvSDk github.com/cncf/udpa/go v0.0.0-20191209042840-269d4d468f6f/go.mod h1:M8M6+tZqaGXZJjfX53e64911xZQV5JYwmTeXPW+k8Sc= github.com/cockroachdb/datadriven v0.0.0-20190809214429-80d97fb3cbaa/go.mod h1:zn76sxSg3SzpJ0PPJaLDCu+Bu0Lg3sKTORVIj19EIF8= github.com/codahale/hdrhistogram v0.0.0-20161010025455-3a0bb77429bd/go.mod h1:sE/e/2PUdi/liOCUjSTXgM1o87ZssimdTWN964YiIeI= +github.com/confio/ics23/go v0.0.0-20200817220745-f173e6211efb/go.mod h1:E45NqnlpxGnpfTWL/xauN7MRwEE28T4Dd4uraToOaKg= github.com/confio/ics23/go v0.6.3 h1:PuGK2V1NJWZ8sSkNDq91jgT/cahFEW9RGp4Y5jxulf0= github.com/confio/ics23/go v0.6.3/go.mod h1:E45NqnlpxGnpfTWL/xauN7MRwEE28T4Dd4uraToOaKg= github.com/coreos/bbolt v1.3.2/go.mod h1:iRUV2dpdMOn7Bo10OQBFzIJO9kkE559Wcmn+qkEiiKk= @@ -119,6 +120,7 @@ github.com/coreos/pkg v0.0.0-20160727233714-3ac0863d7acf/go.mod h1:E3G3o1h8I7cfc github.com/coreos/pkg v0.0.0-20180928190104-399ea9e2e55f/go.mod h1:E3G3o1h8I7cfcXa63jLwjI0eiQQMgzzUDFVpN/nH/eA= github.com/cosmos/go-bip39 v0.0.0-20180819234021-555e2067c45d h1:49RLWk1j44Xu4fjHb6JFYmeUnDORVwHNkDxaQ0ctCVU= github.com/cosmos/go-bip39 v0.0.0-20180819234021-555e2067c45d/go.mod h1:tSxLoYXyBmiFeKpvmq4dzayMdCjCnu8uqmCysIGBT2Y= +github.com/cosmos/iavl v0.15.0-rc3.0.20201009144442-230e9bdf52cd/go.mod h1:3xOIaNNX19p0QrX0VqWa6voPRoJRGGYtny+DH8NEPvE= github.com/cosmos/iavl v0.15.0-rc4 h1:P1wmET7BueqCzfxsn+BzVkDWDLY9ij2JNwkbIdM7RG8= github.com/cosmos/iavl v0.15.0-rc4/go.mod h1:5CsecJdh44Uj4vZ6WSPeWq84hNW5BwRI36ZsAbfJvRw= github.com/cosmos/ledger-cosmos-go v0.11.1 h1:9JIYsGnXP613pb2vPjFeMMjBI5lEDsEaF6oYorTy6J4= @@ -274,12 +276,14 @@ github.com/gorilla/websocket v1.4.2 h1:+/TMaTYc4QFitKJxsQ7Yye35DkWvkdLcvGKqM+x0U github.com/gorilla/websocket v1.4.2/go.mod h1:YR8l580nyteQvAITg2hZ9XVh4b55+EU/adAjf1fMHhE= github.com/grpc-ecosystem/go-grpc-middleware v1.0.0/go.mod h1:FiyG127CGDf3tlThmgyCl78X/SZQqEOJBCDaAfeWzPs= github.com/grpc-ecosystem/go-grpc-middleware v1.0.1-0.20190118093823-f849b5445de4/go.mod h1:FiyG127CGDf3tlThmgyCl78X/SZQqEOJBCDaAfeWzPs= +github.com/grpc-ecosystem/go-grpc-middleware v1.2.1/go.mod h1:EaizFBKfUKtMIF5iaDEhniwNedqGo9FuLFzppDr3uwI= github.com/grpc-ecosystem/go-grpc-middleware v1.2.2/go.mod h1:EaizFBKfUKtMIF5iaDEhniwNedqGo9FuLFzppDr3uwI= github.com/grpc-ecosystem/go-grpc-prometheus v1.2.0/go.mod h1:8NvIoxWQoOIhqOTXgfV/d3M/q6VIi02HzZEHgUlZvzk= github.com/grpc-ecosystem/grpc-gateway v1.8.5/go.mod h1:vNeuVxBJEsws4ogUvrchl83t/GYV9WGTSLVdBhOQFDY= github.com/grpc-ecosystem/grpc-gateway v1.9.0/go.mod h1:vNeuVxBJEsws4ogUvrchl83t/GYV9WGTSLVdBhOQFDY= github.com/grpc-ecosystem/grpc-gateway v1.9.5 h1:UImYN5qQ8tuGpGE16ZmjvcTtTw24zw1QAp/SlnNrZhI= github.com/grpc-ecosystem/grpc-gateway v1.9.5/go.mod h1:vNeuVxBJEsws4ogUvrchl83t/GYV9WGTSLVdBhOQFDY= +github.com/grpc-ecosystem/grpc-gateway v1.14.7/go.mod h1:oYZKL012gGh6LMyg/xA7Q2yq6j8bu0wa+9w14EEthWU= github.com/grpc-ecosystem/grpc-gateway v1.15.2 h1:HC+hWRWf+v5zTMPyoaYTKIJih+4sd4XRWmj0qlG87Co= github.com/grpc-ecosystem/grpc-gateway v1.15.2/go.mod h1:vO11I9oWA+KsxmfFQPhLnnIb1VDE24M+pdxZFiuZcA8= github.com/gsterjov/go-libsecret v0.0.0-20161001094733-a6f4afe4910c h1:6rhixN/i8ZofjG1Y75iExal34USq5p+wiN1tpie8IrU= @@ -593,6 +597,8 @@ github.com/tendermint/go-amino v0.16.0/go.mod h1:TQU0M1i/ImAo+tYpZi73AU3V/dKeCoM github.com/tendermint/tendermint v0.34.0-rc4/go.mod h1:yotsojf2C1QBOw4dZrTcxbyxmPUrT4hNuOQWX9XUwB4= github.com/tendermint/tendermint v0.34.0-rc5 h1:2bnQfWyOMfTCbol5pwB8CgM2nxi6/Kz6zqlS6Udm/Cg= github.com/tendermint/tendermint v0.34.0-rc5/go.mod h1:yotsojf2C1QBOw4dZrTcxbyxmPUrT4hNuOQWX9XUwB4= +github.com/tendermint/tendermint v0.34.0-rc6 h1:SVuKGvvE22KxfuK8QUHctUrmOWJsncZSYXIYtcnoKN0= +github.com/tendermint/tendermint v0.34.0-rc6/go.mod h1:ugzyZO5foutZImv0Iyx/gOFCX6mjJTgbLHTwi17VDVg= github.com/tendermint/tm-db v0.6.2 h1:DOn8jwCdjJblrCFJbtonEIPD1IuJWpbRUUdR8GWE4RM= github.com/tendermint/tm-db v0.6.2/go.mod h1:GYtQ67SUvATOcoY8/+x6ylk8Qo02BQyLrAs+yAcLvGI= github.com/tmc/grpc-websocket-proxy v0.0.0-20170815181823-89b8d40f7ca8/go.mod h1:ncp9v5uamzpCO7NfCPTXjqaC+bZgJeR0sMTm6dMHP7U= @@ -638,6 +644,7 @@ golang.org/x/crypto v0.0.0-20200115085410-6d4e4cb37c7d/go.mod h1:LzIPMQfyMNhhGPh golang.org/x/crypto v0.0.0-20200510223506-06a226fb4e37/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto= golang.org/x/crypto v0.0.0-20200622213623-75b288015ac9/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto= golang.org/x/crypto v0.0.0-20200709230013-948cd5f35899/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto= +golang.org/x/crypto v0.0.0-20200820211705-5c72a883971a/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto= golang.org/x/crypto v0.0.0-20201012173705-84dcc777aaee h1:4yd7jl+vXjalO5ztz6Vc1VADv+S/80LGJmyl1ROJ2AI= golang.org/x/crypto v0.0.0-20201012173705-84dcc777aaee/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto= golang.org/x/exp v0.0.0-20190121172915-509febef88a4/go.mod h1:CJ0aWSM057203Lf6IL+f9T1iT9GByDxfZKAQTCR3kQA= @@ -802,6 +809,7 @@ google.golang.org/genproto v0.0.0-20200324203455-a04cca1dde73/go.mod h1:55QSHmfG google.golang.org/genproto v0.0.0-20200423170343-7949de9c1215/go.mod h1:55QSHmfGQM9UVYDPBsyGGes0y52j32PQ3BqQfXhyH3c= google.golang.org/genproto v0.0.0-20200513103714-09dca8ec2884/go.mod h1:55QSHmfGQM9UVYDPBsyGGes0y52j32PQ3BqQfXhyH3c= google.golang.org/genproto v0.0.0-20200526211855-cb27e3aa2013/go.mod h1:NbSheEEYHJ7i3ixzK3sjbqSGDJWnxyFXZblF3eUsNvo= +google.golang.org/genproto v0.0.0-20200825200019-8632dd797987/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no= google.golang.org/genproto v0.0.0-20201014134559-03b6142f0dc9 h1:fG84H9C3EXfuDlzkG+VEPDYHHExklP6scH1QZ5gQTqU= google.golang.org/genproto v0.0.0-20201014134559-03b6142f0dc9/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no= google.golang.org/grpc v1.17.0/go.mod h1:6QZJwpn2B+Zp71q/5VxRsJ6NXXVCE5NRUHRo+f3cWCs= @@ -819,6 +827,7 @@ google.golang.org/grpc v1.26.0/go.mod h1:qbnxyOmOxrQa7FizSgH+ReBfzJrCY1pSN7KXBS8 google.golang.org/grpc v1.27.0/go.mod h1:qbnxyOmOxrQa7FizSgH+ReBfzJrCY1pSN7KXBS8abTk= google.golang.org/grpc v1.28.0/go.mod h1:rpkK4SK4GF4Ach/+MFLZUBavHOvF2JJB5uozKKal+60= google.golang.org/grpc v1.29.1/go.mod h1:itym6AZVZYACWQqET3MqgPpjcuV5QH3BxFS3IjizoKk= +google.golang.org/grpc v1.31.0/go.mod h1:N36X2cJ7JwdamYAgDz+s+rVMFjt3numwzf/HckM8pak= google.golang.org/grpc v1.31.1/go.mod h1:N36X2cJ7JwdamYAgDz+s+rVMFjt3numwzf/HckM8pak= google.golang.org/grpc v1.32.0/go.mod h1:N36X2cJ7JwdamYAgDz+s+rVMFjt3numwzf/HckM8pak= google.golang.org/grpc v1.33.0 h1:IBKSUNL2uBS2DkJBncPP+TwT0sp9tgA8A75NjHt6umg= @@ -838,6 +847,7 @@ gopkg.in/alecthomas/kingpin.v2 v2.2.6/go.mod h1:FMv+mEhP44yOT+4EoQTLFTRgOQ1FBLks 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-20200227125254-8fa46927fb4f/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0= gopkg.in/check.v1 v1.0.0-20200902074654-038fdea0a05b h1:QRR6H1YWRnHb4Y/HeNFCTJLFVxaq6wH4YuVdsUOr75U= gopkg.in/check.v1 v1.0.0-20200902074654-038fdea0a05b/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0= gopkg.in/cheggaaa/pb.v1 v1.0.25/go.mod h1:V/YB90LKu/1FcN3WVnfiiE5oMCibMjukxqG/qStrOgw= diff --git a/server/tm_cmds.go b/server/tm_cmds.go index d6c8b665f..abea9c116 100644 --- a/server/tm_cmds.go +++ b/server/tm_cmds.go @@ -114,7 +114,7 @@ against which this app has been compiled. BlockProtocol uint64 P2PProtocol uint64 }{ - Tendermint: tversion.Version, + Tendermint: tversion.TMCoreSemVer, ABCI: tversion.ABCIVersion, BlockProtocol: tversion.BlockProtocol, P2PProtocol: tversion.P2PProtocol, diff --git a/third_party/proto/tendermint/crypto/keys.proto b/third_party/proto/tendermint/crypto/keys.proto index af9db49fc..16fd7adf3 100644 --- a/third_party/proto/tendermint/crypto/keys.proto +++ b/third_party/proto/tendermint/crypto/keys.proto @@ -11,6 +11,7 @@ message PublicKey { option (gogoproto.equal) = true; oneof sum { - bytes ed25519 = 1; + bytes ed25519 = 1; + bytes secp256k1 = 2; } } diff --git a/third_party/proto/tendermint/types/evidence.proto b/third_party/proto/tendermint/types/evidence.proto index 5f7d860bf..3b234571b 100644 --- a/third_party/proto/tendermint/types/evidence.proto +++ b/third_party/proto/tendermint/types/evidence.proto @@ -4,19 +4,9 @@ package tendermint.types; option go_package = "github.com/tendermint/tendermint/proto/tendermint/types"; import "gogoproto/gogo.proto"; +import "google/protobuf/timestamp.proto"; import "tendermint/types/types.proto"; - -// DuplicateVoteEvidence contains evidence a validator signed two conflicting -// votes. -message DuplicateVoteEvidence { - Vote vote_a = 1; - Vote vote_b = 2; -} - -message LightClientAttackEvidence { - LightBlock conflicting_block = 1; - int64 common_height = 2; -} +import "tendermint/types/validator.proto"; message Evidence { oneof sum { @@ -25,7 +15,24 @@ message Evidence { } } -// EvidenceData contains any evidence of malicious wrong-doing by validators -message EvidenceData { +// DuplicateVoteEvidence contains evidence of a validator signed two conflicting votes. +message DuplicateVoteEvidence { + tendermint.types.Vote vote_a = 1; + tendermint.types.Vote vote_b = 2; + int64 total_voting_power = 3; + int64 validator_power = 4; + google.protobuf.Timestamp timestamp = 5 [(gogoproto.nullable) = false, (gogoproto.stdtime) = true]; +} + +// LightClientAttackEvidence contains evidence of a set of validators attempting to mislead a light client. +message LightClientAttackEvidence { + tendermint.types.LightBlock conflicting_block = 1; + int64 common_height = 2; + repeated tendermint.types.Validator byzantine_validators = 3; + int64 total_voting_power = 4; + google.protobuf.Timestamp timestamp = 5 [(gogoproto.nullable) = false, (gogoproto.stdtime) = true]; +} + +message EvidenceList { repeated Evidence evidence = 1 [(gogoproto.nullable) = false]; } diff --git a/x/staking/types/staking.pb.go b/x/staking/types/staking.pb.go index 8b54a0ed2..865953c9d 100644 --- a/x/staking/types/staking.pb.go +++ b/x/staking/types/staking.pb.go @@ -1216,606 +1216,606 @@ func (this *Pool) Description() (desc *github_com_gogo_protobuf_protoc_gen_gogo_ func StakingDescription() (desc *github_com_gogo_protobuf_protoc_gen_gogo_descriptor.FileDescriptorSet) { d := &github_com_gogo_protobuf_protoc_gen_gogo_descriptor.FileDescriptorSet{} var gzipped = []byte{ - // 9584 bytes of a gzipped FileDescriptorSet + // 9578 bytes of a gzipped FileDescriptorSet 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xec, 0x7d, 0x6d, 0x70, 0x24, 0xd7, 0x71, 0xd8, 0xcd, 0x7e, 0x00, 0xbb, 0x8d, 0x05, 0xb0, 0x78, 0xc0, 0xdd, 0xed, 0x2d, 0x8f, 0x00, - 0x38, 0xfc, 0x3a, 0x1e, 0x49, 0x80, 0x3c, 0xf2, 0x8e, 0xc7, 0x3d, 0x89, 0x34, 0x16, 0xbb, 0x87, - 0x03, 0x0f, 0x5f, 0x1c, 0x00, 0x47, 0x7d, 0x39, 0x5b, 0x83, 0xdd, 0x87, 0xc5, 0x10, 0xbb, 0x33, - 0xc3, 0x99, 0xd9, 0x3b, 0x80, 0x92, 0xaa, 0x68, 0x49, 0x51, 0xa4, 0x73, 0x1c, 0x49, 0x91, 0xcb, - 0x91, 0x68, 0x9d, 0x22, 0x59, 0x4e, 0xe4, 0xc8, 0x4a, 0xfc, 0x21, 0x45, 0x89, 0x93, 0x54, 0x45, - 0x4a, 0xe2, 0x58, 0x52, 0x2a, 0x2e, 0xa9, 0xe2, 0x4a, 0x1c, 0x57, 0x7c, 0x76, 0x28, 0x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x2e, 0x76, 0x01, 0x92, 0xdb, 0x44, - 0xcb, 0x5c, 0xec, 0x20, 0x36, 0x60, 0x34, 0x41, 0x23, 0x0e, 0x1c, 0xd2, 0x88, 0x73, 0x30, 0xa4, - 0x63, 0xdb, 0xc1, 0x35, 0xe6, 0x11, 0xf1, 0x3e, 0x7d, 0x0a, 0x18, 0x51, 0xbb, 0x4b, 0x25, 0x0e, - 0xe5, 0x52, 0x6f, 0x81, 0x51, 0x57, 0xa4, 0x8a, 0xa5, 0xea, 0x75, 0xe1, 0x9b, 0xb3, 0x51, 0x92, - 0xcc, 0x94, 0x05, 0x9d, 0x42, 0xc8, 0x94, 0x11, 0x1c, 0x78, 0x46, 0x25, 0x00, 0x43, 0xc7, 0xc6, - 0x76, 0xa5, 0x86, 0xab, 0x8d, 0x5c, 0xaa, 0x8b, 0x95, 0x56, 0x09, 0x4a, 0x9b, 0x95, 0x0c, 0x06, - 0xad, 0x36, 0xd0, 0xd3, 0x9e, 0xab, 0x0d, 0x76, 0xf1, 0x94, 0x65, 0x16, 0x64, 0x6d, 0xde, 0xb6, - 0x09, 0x23, 0x16, 0x26, 0x7e, 0x8f, 0x6b, 0x5c, 0xb3, 0x34, 0x15, 0x62, 0x26, 0x52, 0x33, 0x85, - 0x93, 0x31, 0xc5, 0x86, 0x2d, 0xff, 0x23, 0xba, 0x17, 0x5c, 0x40, 0x85, 0xba, 0x15, 0xd0, 0x2c, - 0x94, 0x11, 0xc0, 0x15, 0xb5, 0x89, 0xf3, 0x2f, 0xc3, 0x48, 0xd0, 0x3c, 0x68, 0x02, 0x92, 0xb6, - 0xa3, 0x5a, 0x0e, 0xf5, 0xc2, 0xa4, 0xc2, 0x1e, 0x50, 0x16, 0xe2, 0x58, 0xaf, 0xd1, 0x2c, 0x97, - 0x54, 0xc8, 0x4f, 0xf4, 0x13, 0x9e, 0xc2, 0x71, 0xaa, 0xf0, 0x03, 0xed, 0x23, 0x1a, 0xe0, 0x1c, - 0xd6, 0x3b, 0xff,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xaf, 0x93, 0xe5, 0x4f, 0x95, 0xce, 0x58, 0x12, 0xcd, 0x69, 0xf7, 0xf6, 0xac, 0xee, 0x67, - 0xe6, 0xc9, 0x54, 0x56, 0x18, 0x60, 0xc5, 0xb1, 0xc2, 0x28, 0x49, 0x19, 0x41, 0x9c, 0x0d, 0xb3, - 0x62, 0x24, 0xa5, 0xf0, 0x27, 0xb4, 0x00, 0x03, 0x2f, 0xda, 0x94, 0xf7, 0x00, 0xe5, 0x7d, 0x5f, - 0x6f, 0xde, 0xcf, 0xad, 0x53, 0xe6, 0xe9, 0xe7, 0xd6, 0x2b, 0x2b, 0xab, 0xca, 0xf2, 0xdc, 0x92, - 0xc2, 0xc9, 0xd1, 0x09, 0x48, 0x34, 0xd4, 0x97, 0xf7, 0x83, 0x93, 0x1e, 0x05, 0xf5, 0x3b, 0x08, - 0x27, 0x20, 0x71, 0x0d, 0xab, 0xbb, 0xc1, 0xa9, 0x86, 0x82, 0xee, 0x60, 0x30, 0xcc, 0x42, 0x92, - 0xda, 0x0b, 0x01, 0x70, 0x8b, 0x65, 0x8f, 0xa0, 0x14, 0x24, 0xe6, 0x57, 0x15, 0x12, 0x10, 0x59, - 0xc8, 0x30, 0x68, 0x65, 0x6d, 0xb1, 0x3c, 0x5f, 0xce, 0xc6, 0xe4, 0xb3, 0x30, 0xc0, 0x8c, 0x40, - 0x82, 0xc5, 0x35, 0x43, 0xf6, 0x08, 0x7f, 0xe4, 0x3c, 0x24, 0xd1, 0xba, 0xb9, 0x5c, 0x2c, 0x2b, - 0xd9, 0x58, 0x70, 0xa8, 0x13, 0xd9, 0xa4, 0x6c, 0x43, 0xc6, 0x5f, 0x87, 0xff, 0x68, 0x16, 0xe3, - 0x5f, 0x96, 0x60, 0xc8, 0x57, 0x57, 0x93, 0x82, 0x48, 0x6d, 0x34, 0x8c, 0x6b, 0x15, 0xb5, 0xa1, - 0xa9, 0x36, 0x77, 0x0d, 0xa0, 0xa0, 0x39, 0x02, 0xe9, 0x77,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, - 0x4b, 0xe9, 0x11, 0x40, 0xa6, 0x61, 0x6b, 0x8e, 0x76, 0x15, 0x57, 0x34, 0x5d, 0x6c, 0x3e, 0x91, - 0x65, 0x4d, 0x42, 0xc9, 0x8a, 0x96, 0x45, 0xdd, 0x71, 0xb1, 0x75, 0x5c, 0x57, 0x43, 0xd8, 0x24, - 0x99, 0xc7, 0x95, 0xac, 0x68, 0x71, 0xb1, 0xef, 0x81, 0x4c, 0xcd, 0x68, 0x91, 0x5a, 0x8f, 0xe1, - 0x91, 0xb9, 0x43, 0x52, 0x86, 0x18, 0xcc, 0x45, 0xe1, 0x55, 0xbc, 0xb7, 0xeb, 0x95, 0x51, 0x86, - 0x18, 0x8c, 0xa1, 0x3c, 0x08, 0xa3, 0x6a, 0xbd, 0x6e, 0x11, 0xe6, 0x82, 0x11, 0x5b, 0x97, 0x8c, - 0xb8, 0x60, 0x8a, 0x98, 0x7f, 0x0e, 0x52, 0xc2, 0x0e, 0x64, 0xaa, 0x26, 0x96, 0xa8, 0x98, 0x6c, - 0xb1, 0x1d, 0x3b, 0x95, 0x56, 0x52, 0xba, 0x68, 0xbc, 0x07, 0x32, 0x9a, 0x5d, 0xf1, 0x36, 0xf1, - 0x63, 0xd3, 0xb1, 0x53, 0x29, 0x65, 0x48, 0xb3, 0xdd, 0x0d, 0x50, 0xf9, 0xb3, 0x31, 0x18, 0x09, - 0xbe, 0x84, 0x40, 0x25, 0x48, 0x35, 0x8c, 0xaa, 0x4a, 0x5d, 0x8b, 0xbd, 0x01, 0x3b, 0x15, 0xf1, - 0xde, 0x62, 0x66, 0x89, 0xe3, 0x2b, 0x2e, 0x65, 0xfe, 0xb7, 0x25, 0x48, 0x09, 0x30, 0x3a, 0x06, - 0x09, 0x53, 0x75, 0x76, 0x28, 0xbb, 0x64, 0x31, 0x96, 0x95, 0x14, 0xfa, 0x4c, 0xe0, 0xb6, 0xa9, - 0xea, 0xd4, 0x05, 0x38, 0x9c, 0x3c, 0x93, 0x71, 0x6d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7, 0xcf, 0x03, 0x35, 0x4f, 0xe1, 0x22, 0x0c, 0x07, - 0x0a, 0x9e, 0x68, 0x56, 0xef, 0xe3, 0xac, 0x32, 0xfe, 0x7a, 0xa7, 0x70, 0x16, 0x12, 0xa4, 0x78, - 0x89, 0x26, 0xff, 0xab, 0x9c, 0x9c, 0xa2, 0x17, 0xde, 0x0c, 0x29, 0x51, 0xb4, 0x44, 0x93, 0xbe, - 0x9f, 0x93, 0xba, 0x24, 0x84, 0x5c, 0x14, 0x2c, 0xd1, 0xe4, 0x7f, 0x4d, 0x90, 0x0b, 0x12, 0x42, - 0xde, 0xbf, 0x09, 0xbf, 0xfc, 0xd3, 0x09, 0x3e, 0xe9, 0x08, 0xdb, 0x5d, 0x80, 0x41, 0x5e, 0xa9, - 0x44, 0x53, 0x7f, 0x90, 0x77, 0x2e, 0x28, 0x0a, 0x4f, 0x41, 0xb2, 0x4f, 0x83, 0xff, 0x0c, 0x27, - 0x65, 0xf8, 0x85, 0x79, 0x18, 0xf2, 0x55, 0x27, 0xd1, 0xe4, 0x7f, 0x83, 0x93, 0xfb, 0xa9, 0x88, - 0xe8, 0xbc, 0x3a, 0x89, 0x66, 0xf0, 0x21, 0x21, 0x3a, 0xa7, 0x20, 0x66, 0x13, 0x85, 0x49, 0x34, - 0xf5, 0x87, 0x85, 0xd5, 0x05, 0x49, 0xe1, 0x59, 0x48, 0xbb, 0x93, 0x4d, 0x34, 0xfd, 0x47, 0x38, - 0xbd, 0x47, 0x43, 0x2c, 0xe0, 0x9b, 0xec, 0xa2, 0x59, 0xfc, 0x4d, 0x61, 0x01, 0x1f, 0x15, 0x09, - 0xa3, 0x70, 0x01, 0x13, 0xcd, 0xe9, 0xa3, 0x22, 0x8c, 0x42, 0xf5, 0x0b, 0x19, 0x4d, 0x9a, 0xf3, - 0xa3, 0x59, 0xfc, 0xac, 0x18, 0x4d, 0x8a, 0x4f, 0xc4, 0x08, 0x57, 0x04, 0xd1, 0x3c, 0xfe, 0x96, - 0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f, 0x55, 0xaa, - 0x71, 0xea, 0x90, 0x3d, 0x7f, 0x3a, 0x06, 0xe3, 0x9b, 0x22, 0xf3, 0xfc, 0xd8, 0xdb, 0x60, 0x0d, - 0x06, 0xb1, 0xee, 0x58, 0x1a, 0x35, 0x02, 0x19, 0xed, 0xc7, 0xba, 0x8d, 0x76, 0x07, 0x9d, 0xe8, - 0xc7, 0x6c, 0xc4, 0xa6, 0x3b, 0x67, 0x13, 0xb2, 0xc6, 0x87, 0xe2, 0x90, 0xeb, 0x46, 0x89, 0xe6, - 0x61, 0xb4, 0x6a, 0x61, 0x0a, 0xa8, 0xf8, 0x77, 0xfe, 0x8a, 0x79, 0xaf, 0xb2, 0x0c, 0x21, 0xc8, - 0xca, 0x88, 0x80, 0xf0, 0xd9, 0xa3, 0x0e, 0xa4, 0xec, 0x23, 0x6e, 0x47, 0xb0, 0xfa, 0xac, 0xf3, - 0x64, 0x3e, 0x7d, 0x88, 0x4e, 0x82, 0x0c, 0xd8, 0xfc, 0x31, 0xe2, 0x41, 0xe9, 0x04, 0xf2, 0x12, - 0x8c, 0x6a, 0xba, 0xe6, 0x68, 0x6a, 0xa3, 0xb2, 0xa5, 0x36, 0x54, 0xbd, 0x7a, 0x98, 0xaa, 0x99, - 0xa5, 0x7c, 0xde, 0x6d, 0x88, 0x9d, 0xac, 0x8c, 0x70, 0x48, 0x91, 0x01, 0xd0, 0x25, 0x18, 0x14, - 0x5d, 0x25, 0x0e, 0x55, 0x6d, 0x08, 0x72, 0x5f, 0x81, 0xf7, 0x33, 0x71, 0x18, 0x53, 0x70, 0xed, - 0xff, 0x0f, 0xc5, 0xc1, 0x86, 0x62, 0x19, 0x80, 0x85, 0x3b, 0x49, 0xb0, 0x87, 0x18, 0x0d, 0x92, - 0x30, 0xd2, 0x8c, 0x43, 0xc9, 0x76, 0x7c, 0xe3, 0x71, 0x33, 0x06, 0x19, 0xff, 0x78, 0xfc, 0x25, - 0x9d, 0x95, 0xd0, 0xa2, 0x97, 0x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 0x93, 0x8d, 0x7d, 0x2a, 0xd2, 0xfb, 0xf8, - 0x61, 0xe6, 0x40, 0xd7, 0xb6, 0xd9, 0x21, 0x41, 0x7e, 0x43, 0x3a, 0xcc, 0x4f, 0x66, 0x9f, 0x77, - 0xa3, 0x67, 0x17, 0xd8, 0x47, 0x1e, 0xdf, 0x27, 0xc1, 0x51, 0x8a, 0xe5, 0xc5, 0x1b, 0xc5, 0x14, - 0x77, 0xf6, 0xba, 0x7a, 0xcc, 0x92, 0xea, 0xdb, 0x82, 0x61, 0x9f, 0x65, 0xbc, 0x8f, 0xdf, 0x67, - 0x39, 0xe9, 0xeb, 0x3c, 0xcc, 0x56, 0x56, 0xc6, 0x1b, 0x6d, 0x94, 0x76, 0x68, 0x5d, 0x9f, 0x38, - 0xfc, 0xba, 0xfe, 0x39, 0x18, 0xf2, 0x65, 0xfa, 0x5c, 0x32, 0xe2, 0x9a, 0x69, 0x78, 0x13, 0xcd, - 0x4f, 0x8c, 0xde, 0x2f, 0xc1, 0xd1, 0x8e, 0x93, 0x20, 0xfd, 0x5f, 0xb4, 0x07, 0xdc, 0xa4, 0x0b, - 0x19, 0xa7, 0x23, 0x5f, 0x59, 0x99, 0x68, 0x75, 0xaa, 0x26, 0xd6, 0x60, 0x38, 0x30, 0x81, 0xe5, - 0xc4, 0x7f, 0x94, 0xee, 0xff, 0x86, 0x45, 0x90, 0x01, 0xca, 0x43, 0x0a, 0xef, 0x99, 0x86, 0xe5, - 0xe0, 0x1a, 0x3d, 0xf2, 0x90, 0x52, 0xdc, 0x67, 0x79, 0x05, 0x50, 0xfb, 0xe0, 0x86, 0xbf, 0x43, - 0x9a, 0xf6, 0xbe, 0x43, 0x3a, 0x01, 0x49, 0xff, 0x97, 0x3a, 0xd9, 0x83, 0xb7, 0x4f, 0x71, 0xbb, - 0x63, 0xfe, 0xff, 0x06, 0x00, 0x00, 0xff, 0xff, 0x5a, 0x69, 0x9a, 0x3e, 0x4a, 0x94, 0x00, 0x00, + 0x38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 0xd0, 0xb4, + 0x5c, 0xdd, 0x34, 0x9c, 0x42, 0x66, 0x5a, 0x3a, 0x35, 0x74, 0xe6, 0x64, 0x47, 0x47, 0x58, 0x63, + 0x38, 0x8a, 0x40, 0x46, 0x4b, 0x90, 0x77, 0xcc, 0x96, 0xad, 0xe1, 0xaa, 0x66, 0xd6, 0x70, 0x55, + 0x37, 0x76, 0xcc, 0x42, 0x96, 0x32, 0x98, 0x6a, 0x57, 0x84, 0x22, 0xce, 0x9b, 0x35, 0xbc, 0x64, + 0xec, 0x98, 0xca, 0x88, 0x13, 0x6a, 0xa3, 0x63, 0x30, 0xe0, 0xec, 0x1b, 0xae, 0x7a, 0xad, 0x90, + 0xa3, 0x1e, 0xc2, 0x5b, 0xf2, 0x6f, 0x0c, 0xc0, 0x68, 0x3f, 0x2e, 0x76, 0x1e, 0xd2, 0x3b, 0x44, + 0xcb, 0x42, 0xe2, 0x20, 0x36, 0x60, 0x34, 0x61, 0x23, 0x0e, 0x1c, 0xd2, 0x88, 0x73, 0x30, 0x64, + 0x60, 0xc7, 0xc5, 0x35, 0xe6, 0x11, 0xc9, 0x3e, 0x7d, 0x0a, 0x18, 0x51, 0xbb, 0x4b, 0xa5, 0x0e, + 0xe5, 0x52, 0x2f, 0xc0, 0xa8, 0x27, 0x52, 0xd5, 0x56, 0x8d, 0xba, 0xf0, 0xcd, 0xd9, 0x38, 0x49, + 0x66, 0x2a, 0x82, 0x4e, 0x21, 0x64, 0xca, 0x08, 0x0e, 0xb5, 0xd1, 0x02, 0x80, 0x69, 0x60, 0x73, + 0xa7, 0x5a, 0xc3, 0x5a, 0xa3, 0x90, 0xe9, 0x62, 0xa5, 0x35, 0x82, 0xd2, 0x66, 0x25, 0x93, 0x41, + 0xb5, 0x06, 0x7a, 0xca, 0x77, 0xb5, 0xc1, 0x2e, 0x9e, 0xb2, 0xc2, 0x26, 0x59, 0x9b, 0xb7, 0x6d, + 0xc1, 0x88, 0x8d, 0x89, 0xdf, 0xe3, 0x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 0x4d, 0x38, 0x9c, + 0xee, 0x8f, 0x03, 0x99, 0x4b, 0x0a, 0xa5, 0x43, 0x77, 0x40, 0x96, 0xfc, 0x65, 0xbe, 0x31, 0x40, + 0x65, 0xce, 0x10, 0x00, 0xf1, 0x0b, 0x54, 0x84, 0x0c, 0x9d, 0x26, 0x35, 0x2c, 0x96, 0x36, 0xaf, + 0x4d, 0x1c, 0xab, 0x86, 0x77, 0xd4, 0x56, 0xc3, 0xad, 0x5e, 0x51, 0x1b, 0x2d, 0x4c, 0x1d, 0x3e, + 0xab, 0xe4, 0x38, 0xf0, 0x32, 0x81, 0xa1, 0x29, 0x18, 0x62, 0xb3, 0x4a, 0x37, 0x6a, 0xf8, 0x1a, + 0x8d, 0x9e, 0x69, 0x85, 0x4d, 0xb4, 0x25, 0x02, 0x21, 0xdd, 0xbf, 0xe8, 0x98, 0x86, 0x70, 0x4d, + 0xda, 0x05, 0x01, 0xd0, 0xee, 0x9f, 0x88, 0x06, 0xee, 0x3b, 0x3b, 0xab, 0x17, 0xf5, 0x29, 0xf9, + 0x4b, 0x09, 0x48, 0xd1, 0x78, 0x31, 0x0a, 0x43, 0x9b, 0x6f, 0x59, 0xaf, 0x54, 0x17, 0xd6, 0xb6, + 0xca, 0xcb, 0x95, 0xbc, 0x84, 0x46, 0x00, 0x28, 0xe0, 0xc2, 0xf2, 0xda, 0xdc, 0x66, 0x3e, 0xe1, + 0xb5, 0x97, 0x56, 0x37, 0xcf, 0x3d, 0x9e, 0x4f, 0x7a, 0x04, 0x5b, 0x0c, 0x90, 0x0a, 0x22, 0x3c, + 0x76, 0x26, 0x9f, 0x46, 0x79, 0xc8, 0x31, 0x06, 0x4b, 0x2f, 0x54, 0x16, 0xce, 0x3d, 0x9e, 0x1f, + 0x08, 0x43, 0x1e, 0x3b, 0x93, 0x1f, 0x44, 0xc3, 0x90, 0xa5, 0x90, 0xf2, 0xda, 0xda, 0x72, 0x3e, + 0xe3, 0xf1, 0xdc, 0xd8, 0x54, 0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 0xb0, 0x83, 0xc5, 0xf6, 0x74, 0x87, + 0xd8, 0x7e, 0x1e, 0xc6, 0xda, 0x18, 0xf5, 0x1d, 0x63, 0xdf, 0x23, 0x41, 0xa1, 0x9b, 0x71, 0x62, + 0x22, 0x5d, 0x22, 0x14, 0xe9, 0xce, 0x47, 0x2d, 0x78, 0x57, 0xf7, 0x41, 0x68, 0x1b, 0xeb, 0xcf, + 0x4a, 0x70, 0xac, 0x73, 0xa6, 0xd8, 0x51, 0x86, 0xa7, 0x61, 0xa0, 0x89, 0xdd, 0x5d, 0x53, 0x64, + 0x4b, 0xf7, 0x75, 0x58, 0x83, 0xc9, 0xe3, 0xe8, 0x60, 0x73, 0xaa, 0xe0, 0x22, 0x9e, 0xec, 0x96, + 0xee, 0x31, 0x69, 0xda, 0x24, 0xfd, 0x40, 0x02, 0x8e, 0x76, 0x64, 0xde, 0x51, 0xd0, 0x3b, 0x01, + 0x74, 0xc3, 0x6a, 0xb9, 0x2c, 0x23, 0x62, 0x01, 0x36, 0x4b, 0x21, 0x34, 0x78, 0x91, 0xe0, 0xd9, + 0x72, 0xbd, 0xe7, 0x49, 0xfa, 0x1c, 0x18, 0x88, 0x22, 0x3c, 0xe9, 0x0b, 0x9a, 0xa2, 0x82, 0x4e, + 0x76, 0xd1, 0xb4, 0xcd, 0x31, 0x1f, 0x81, 0xbc, 0xd6, 0xd0, 0xb1, 0xe1, 0x56, 0x1d, 0xd7, 0xc6, + 0x6a, 0x53, 0x37, 0xea, 0x74, 0x05, 0xc9, 0x94, 0xd2, 0x3b, 0x6a, 0xc3, 0xc1, 0xca, 0x28, 0x7b, + 0xbc, 0x21, 0x9e, 0x12, 0x0a, 0xea, 0x40, 0x76, 0x80, 0x62, 0x20, 0x44, 0xc1, 0x1e, 0x7b, 0x14, + 0xf2, 0xcf, 0x66, 0x61, 0x28, 0x90, 0x57, 0xa3, 0xbb, 0x20, 0xf7, 0xa2, 0x7a, 0x45, 0xad, 0x8a, + 0xbd, 0x12, 0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0x22, 0xd4, 0xf1, 0x29, 0x8a, 0x36, 0x62, 0xed, 0x5a, 0xc1, 0x7e, 0xef, 0x86, 0x61, 0x82, 0xe9, + 0x77, 0xfa, 0x00, 0x4b, 0xc8, 0xac, 0xdd, 0x40, 0x8f, 0x8f, 0xc3, 0x31, 0x82, 0xd4, 0xc4, 0xae, + 0x5a, 0x53, 0x5d, 0x35, 0x80, 0xfd, 0x10, 0xc5, 0x26, 0x76, 0x5f, 0xe1, 0x0f, 0x43, 0x72, 0xda, + 0xad, 0xed, 0x7d, 0xcf, 0xb3, 0x1e, 0x66, 0x72, 0x12, 0x98, 0xf0, 0xad, 0xdb, 0x96, 0x74, 0xcb, + 0x25, 0xc8, 0x05, 0x1d, 0x1f, 0x65, 0x81, 0xb9, 0x7e, 0x5e, 0x22, 0x59, 0xd0, 0xfc, 0xda, 0x02, + 0xc9, 0x5f, 0xde, 0x5a, 0xc9, 0x27, 0x48, 0x1e, 0xb5, 0xbc, 0xb4, 0x59, 0xa9, 0x2a, 0x5b, 0xab, + 0x9b, 0x4b, 0x2b, 0x95, 0x7c, 0x32, 0x90, 0xb0, 0x3f, 0x9b, 0xca, 0xdc, 0x97, 0xbf, 0x5f, 0xfe, + 0x46, 0x02, 0x46, 0xc2, 0x3b, 0x30, 0xf4, 0x26, 0x38, 0x2e, 0xca, 0x25, 0x0e, 0x76, 0xab, 0x57, + 0x75, 0x9b, 0xce, 0xc8, 0xa6, 0xca, 0x56, 0x47, 0xcf, 0x27, 0x26, 0x38, 0xd6, 0x06, 0x76, 0x9f, + 0xd7, 0x6d, 0x32, 0xdf, 0x9a, 0xaa, 0x8b, 0x96, 0x61, 0xca, 0x30, 0xab, 0x8e, 0xab, 0x1a, 0x35, + 0xd5, 0xae, 0x55, 0xfd, 0x42, 0x55, 0x55, 0xd5, 0x34, 0xec, 0x38, 0x26, 0x5b, 0x09, 0x3d, 0x2e, + 0x27, 0x0d, 0x73, 0x83, 0x23, 0xfb, 0x4b, 0xc4, 0x1c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xb7, 0xf7, 0x28, 0x73, 0xaf, 0x8b, 0x47, 0x14, 0x1f, + 0x54, 0xca, 0x10, 0xad, 0xdf, 0xf8, 0xf4, 0x94, 0x54, 0x4e, 0x43, 0xd2, 0x69, 0x35, 0x6f, 0xab, + 0x8f, 0xbc, 0x96, 0x86, 0xe9, 0x20, 0x25, 0x0d, 0x50, 0x57, 0xd4, 0x86, 0x5e, 0x53, 0xfd, 0x1b, + 0xe0, 0xf9, 0x80, 0x0d, 0x28, 0x46, 0x67, 0x13, 0x14, 0x7b, 0x5a, 0x52, 0xfe, 0x75, 0x09, 0x72, + 0x97, 0x05, 0xe7, 0x0d, 0xec, 0xa2, 0xf3, 0x00, 0x5e, 0x4f, 0x62, 0xda, 0xdc, 0x31, 0x13, 0xed, + 0x6b, 0xc6, 0xa3, 0x51, 0x02, 0xe8, 0xe8, 0x09, 0xea, 0x88, 0x96, 0xe9, 0xf0, 0xfb, 0x2f, 0x31, + 0xa4, 0x1e, 0x32, 0x7a, 0x08, 0x10, 0x8d, 0x70, 0xd5, 0x2b, 0xa6, 0xab, 0x1b, 0xf5, 0xaa, 0x65, + 0x5e, 0xe5, 0x97, 0x05, 0x93, 0x4a, 0x9e, 0x3e, 0xb9, 0x4c, 0x1f, 0xac, 0x13, 0x38, 0x11, 0x3a, + 0xeb, 0x71, 0x21, 0xab, 0x89, 0x5a, 0xab, 0xd9, 0xd8, 0x71, 0x78, 0x10, 0x13, 0x4d, 0x74, 0x1e, + 0x06, 0xad, 0xd6, 0x76, 0x55, 0x44, 0x8c, 0xa1, 0x33, 0x27, 0x3b, 0xcd, 0x7f, 0xe1, 0x1f, 0x3c, + 0x02, 0x0c, 0x58, 0xad, 0x6d, 0xe2, 0x2d, 0x77, 0x41, 0xae, 0x83, 0x30, 0x43, 0x57, 0x7c, 0x39, + 0xe8, 0xf5, 0x75, 0xae, 0x41, 0xd5, 0xb2, 0x75, 0xd3, 0xd6, 0xdd, 0x7d, 0x7a, 0x7a, 0x25, 0xa9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 0xde, 0x02, 0xc2, 0xf9, 0x09, 0x1a, 0x74, 0x1f, 0x64, + 0xb4, 0x5d, 0x55, 0x37, 0xaa, 0x7a, 0x4d, 0x64, 0xbd, 0xaf, 0xdf, 0x98, 0x1a, 0x9c, 0x27, 0xb0, + 0xa5, 0x05, 0x65, 0x90, 0x3e, 0x5c, 0xaa, 0x91, 0x4c, 0x60, 0x17, 0xeb, 0xf5, 0x5d, 0x97, 0xcf, + 0x30, 0xde, 0x42, 0x4f, 0x42, 0x8a, 0x38, 0x04, 0xbf, 0xd9, 0x55, 0x6c, 0xdb, 0x7b, 0x78, 0x1b, + 0xc0, 0x72, 0x86, 0x74, 0xfc, 0xa1, 0x3f, 0x98, 0x92, 0x14, 0x4a, 0x81, 0xe6, 0x61, 0xb8, 0xa1, + 0x3a, 0x6e, 0x95, 0xae, 0x60, 0xa4, 0xfb, 0x34, 0x65, 0x71, 0xa2, 0xdd, 0x20, 0xdc, 0xb0, 0x5c, + 0xf4, 0x21, 0x42, 0xc5, 0x40, 0x35, 0x74, 0x0a, 0xf2, 0x94, 0x89, 0x66, 0x36, 0x9b, 0xba, 0xcb, + 0x72, 0xab, 0x01, 0x6a, 0xf7, 0x11, 0x02, 0x9f, 0xa7, 0x60, 0x9a, 0x61, 0xdd, 0x01, 0x59, 0x7a, + 0x95, 0x84, 0xa2, 0xb0, 0x63, 0x93, 0x19, 0x02, 0xa0, 0x0f, 0xef, 0x87, 0x51, 0x3f, 0x3e, 0x32, + 0x94, 0x0c, 0xe3, 0xe2, 0x83, 0x29, 0xe2, 0x23, 0x30, 0x61, 0xe0, 0x6b, 0xf4, 0x20, 0x67, 0x08, + 0x3b, 0x4b, 0xb1, 0x11, 0x79, 0x76, 0x39, 0x4c, 0x71, 0x2f, 0x8c, 0x68, 0xc2, 0xf8, 0x0c, 0x17, + 0x28, 0xee, 0xb0, 0x07, 0xa5, 0x68, 0x27, 0x20, 0xa3, 0x5a, 0x16, 0x43, 0x18, 0xe2, 0xf1, 0x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0x77, 0x1b, 0x8b, + 0x88, 0xbd, 0xd9, 0xda, 0xfc, 0xf5, 0x1b, 0x53, 0x92, 0x32, 0xaa, 0x45, 0x86, 0xe2, 0x6d, 0x30, + 0xd4, 0xb2, 0x6a, 0xaa, 0x8b, 0xab, 0x74, 0x1f, 0x97, 0x88, 0x5d, 0xe7, 0x27, 0x09, 0xaf, 0x9b, + 0x37, 0xa6, 0x10, 0x53, 0x2b, 0x40, 0x2c, 0xd3, 0xd5, 0x1f, 0x18, 0x84, 0x10, 0x04, 0x74, 0xfa, + 0xaa, 0x04, 0x43, 0x0b, 0x81, 0x93, 0x5e, 0x05, 0x18, 0x6c, 0x9a, 0x86, 0xbe, 0xc7, 0xfd, 0x31, + 0xab, 0x88, 0x26, 0x2a, 0x42, 0x86, 0x5d, 0xba, 0x73, 0xf7, 0x45, 0x29, 0x54, 0xb4, 0x09, 0xd5, + 0x55, 0xbc, 0xed, 0xe8, 0x62, 0x34, 0x14, 0xd1, 0x44, 0x17, 0x20, 0xef, 0x60, 0xad, 0x65, 0xeb, + 0xee, 0x7e, 0x55, 0x33, 0x0d, 0x57, 0xd5, 0x5c, 0x76, 0x7d, 0xab, 0x7c, 0xc7, 0xcd, 0x1b, 0x53, + 0xc7, 0x99, 0xac, 0x51, 0x0c, 0x59, 0x19, 0x15, 0xa0, 0x79, 0x06, 0x21, 0x3d, 0xd4, 0xb0, 0xab, + 0xea, 0x0d, 0xa7, 0xc0, 0xde, 0x93, 0x89, 0x66, 0x40, 0x97, 0xcf, 0x0f, 0x06, 0x0b, 0x5b, 0x17, + 0x20, 0x6f, 0x5a, 0xd8, 0x0e, 0x25, 0xa2, 0x52, 0xb4, 0xe7, 0x28, 0x86, 0xac, 0x8c, 0x0a, 0x90, + 0x48, 0x52, 0x5d, 0x32, 0xcc, 0x62, 0xa3, 0x68, 0xb5, 0xb6, 0xfd, 0x7a, 0xd8, 0x44, 0xdb, 0x68, + 0xcc, 0x19, 0xfb, 0xe5, 0xc7, 0x7c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ff, 0x75, 0x0a, 0xd0, + 0x8a, 0x53, 0x9f, 0x27, 0x49, 0x55, 0xe0, 0x88, 0x56, 0xa4, 0x66, 0x23, 0xfd, 0x40, 0x35, 0x9b, + 0x95, 0x50, 0x15, 0x24, 0x71, 0xb0, 0x4a, 0x6b, 0xdf, 0xa5, 0x90, 0xe4, 0x0f, 0xa5, 0x14, 0xd2, + 0x39, 0x53, 0x4a, 0xdd, 0xba, 0x2d, 0x55, 0xfa, 0xb0, 0xdb, 0x4a, 0x5e, 0xe1, 0x1c, 0xe8, 0x51, + 0xe1, 0x2c, 0x74, 0x2d, 0x63, 0x72, 0x6a, 0x74, 0x56, 0x5c, 0xc9, 0x19, 0xec, 0x6f, 0x6d, 0xe3, + 0x77, 0x76, 0x32, 0xef, 0x17, 0x2b, 0xdb, 0x49, 0x28, 0xb6, 0xbb, 0x93, 0x08, 0xbe, 0xf2, 0x47, + 0x92, 0x90, 0x5f, 0x71, 0xea, 0x95, 0x9a, 0xee, 0xde, 0x26, 0x5f, 0x7b, 0xa6, 0xfb, 0x36, 0x15, + 0xdd, 0xbc, 0x31, 0x35, 0xc2, 0x6c, 0xda, 0xc3, 0x92, 0x4d, 0x18, 0x8d, 0xbc, 0x1c, 0xe0, 0x9e, + 0xb5, 0x70, 0x98, 0x77, 0x14, 0x11, 0x56, 0x32, 0xdd, 0x55, 0x04, 0xfc, 0x1b, 0x5d, 0xeb, 0xec, + 0xcc, 0xcc, 0xa1, 0x2e, 0xde, 0xce, 0x9a, 0x9e, 0x3f, 0x66, 0x45, 0x28, 0x44, 0x07, 0xc5, 0x1b, + 0xb1, 0x3f, 0x92, 0x60, 0x68, 0xc5, 0x11, 0xbb, 0x68, 0xfc, 0x63, 0x5a, 0x51, 0x78, 0xc2, 0xbb, + 0x68, 0x92, 0xec, 0xcf, 0x6f, 0xc5, 0xe5, 0x13, 0xdf, 0x08, 0x47, 0x61, 0x3c, 0xa0, 0xa7, 0xa7, + 0xff, 0xef, 0x24, 0x68, 0x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x23, + 0x58, 0xd3, 0xab, 0x5b, 0xb8, 0x81, 0x35, 0xd7, 0x14, 0x47, 0x19, 0xbc, 0x36, 0x42, 0x90, 0xac, + 0xf3, 0x21, 0xca, 0x5e, 0x3c, 0xa2, 0x90, 0x06, 0x81, 0x79, 0x17, 0xea, 0x08, 0xcc, 0x6a, 0x91, + 0x51, 0x4b, 0x59, 0xa6, 0xa8, 0x99, 0x5e, 0x3c, 0xa2, 0xd0, 0x16, 0x2a, 0xc0, 0x00, 0x71, 0x59, + 0x97, 0x7d, 0x31, 0x98, 0xc0, 0x79, 0x1b, 0x1d, 0x83, 0xb4, 0xa5, 0xba, 0x1a, 0x3b, 0xeb, 0x4e, + 0x1e, 0xb0, 0x26, 0x09, 0xcc, 0xec, 0x4b, 0x0d, 0xd1, 0xff, 0x44, 0x45, 0x8c, 0xc1, 0x3e, 0x89, + 0x49, 0xe4, 0x5e, 0x57, 0x5d, 0x17, 0xdb, 0x06, 0x61, 0xc8, 0xd0, 0x11, 0x82, 0xd4, 0xb6, 0x59, + 0xdb, 0xe7, 0xff, 0x1d, 0x8b, 0xfe, 0xe6, 0xff, 0xb7, 0x87, 0xfa, 0x43, 0x95, 0x3e, 0x64, 0xff, + 0x14, 0x30, 0x27, 0x80, 0x65, 0x82, 0x54, 0x81, 0x71, 0xb5, 0x56, 0xd3, 0x89, 0x57, 0xab, 0x8d, + 0xea, 0xb6, 0x4e, 0xf7, 0xc3, 0x0e, 0xfd, 0x97, 0x8f, 0xdd, 0xc6, 0x02, 0xf9, 0x04, 0x65, 0x8e, + 0x5f, 0xce, 0xc2, 0xa0, 0xc5, 0x84, 0x92, 0xcf, 0xc3, 0x58, 0x9b, 0xa4, 0x44, 0xbe, 0x3d, 0xdd, + 0xa8, 0x89, 0x5b, 0x86, 0xe4, 0x37, 0x81, 0xd1, 0xcf, 0xda, 0xb2, 0x43, 0x22, 0xf4, 0x77, 0xf9, + 0xdd, 0xdd, 0xef, 0xa0, 0x8e, 0x04, 0xee, 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0xed, 0x7e, 0xd0, 0xa1, 0x43, + 0x0a, 0x2c, 0xdf, 0x47, 0x25, 0x99, 0x46, 0x93, 0x5d, 0x25, 0x61, 0xa9, 0xef, 0xad, 0x3e, 0x39, + 0xf0, 0x27, 0x83, 0x5d, 0x3f, 0x5e, 0x51, 0xc7, 0x06, 0x76, 0x74, 0xe7, 0x50, 0x1f, 0xaf, 0xe8, + 0xef, 0xf5, 0xd4, 0xef, 0xa6, 0x21, 0xb7, 0xc8, 0x7a, 0xd9, 0x70, 0x55, 0xf7, 0x07, 0xdc, 0x08, + 0x20, 0x87, 0x7f, 0x93, 0x8d, 0x7d, 0x2a, 0xd2, 0xff, 0xf8, 0x61, 0xee, 0x40, 0xd7, 0xb6, 0xd9, + 0x21, 0x41, 0x7e, 0x43, 0x3a, 0xca, 0x4f, 0x66, 0x9f, 0x77, 0xa3, 0x67, 0x17, 0xd8, 0x47, 0x1e, + 0xdf, 0x2b, 0xc1, 0x51, 0x8a, 0xe5, 0xcf, 0x37, 0x8a, 0x29, 0xee, 0xec, 0x75, 0xf5, 0x98, 0x65, + 0x35, 0x50, 0x82, 0x61, 0x9f, 0x65, 0xbc, 0x87, 0xdf, 0x67, 0x39, 0x19, 0xe8, 0x3c, 0xca, 0x56, + 0x56, 0xc6, 0x1b, 0x6d, 0x94, 0x4e, 0x64, 0x5f, 0x9f, 0x3a, 0xfc, 0xbe, 0xfe, 0x59, 0x18, 0x0a, + 0x44, 0xfa, 0x42, 0x3a, 0xe6, 0x9a, 0x69, 0xb4, 0x88, 0x16, 0x24, 0x46, 0xef, 0x93, 0xe0, 0x68, + 0xc7, 0x45, 0x90, 0xfe, 0xaf, 0xda, 0x03, 0x16, 0xe9, 0x22, 0xc6, 0xe9, 0xc8, 0x57, 0x56, 0x26, + 0x5a, 0x9d, 0xb2, 0x89, 0x75, 0x18, 0x0e, 0x2d, 0x60, 0x05, 0xf1, 0x1f, 0xa7, 0xfb, 0xbf, 0x61, + 0x11, 0x66, 0x80, 0x8a, 0x90, 0xc1, 0xd7, 0x2c, 0xd3, 0x76, 0x71, 0x8d, 0x1e, 0x79, 0xc8, 0x28, + 0x5e, 0x5b, 0x5e, 0x05, 0xd4, 0x3e, 0xb8, 0xd1, 0xef, 0x90, 0x66, 0xfd, 0xef, 0x90, 0x4e, 0x40, + 0x3a, 0xf8, 0xa5, 0x4e, 0xd6, 0xf0, 0xeb, 0x14, 0xb7, 0x7a, 0xce, 0xff, 0xdf, 0x00, 0x00, 0x00, + 0xff, 0xff, 0x01, 0xf6, 0xec, 0xd9, 0x42, 0x94, 0x00, 0x00, } r := bytes.NewReader(gzipped) gzipr, err := compress_gzip.NewReader(r) From 4d833f9ef0026734ff0564ecc0051b5c7d430956 Mon Sep 17 00:00:00 2001 From: Jonathan Gimeno Date: Fri, 6 Nov 2020 11:39:33 +0100 Subject: [PATCH 03/24] ADR 35: Rosetta API Support (#7492) Co-authored-by: Alessio Treglia Co-authored-by: SenorMonito Co-authored-by: Aleksandr Bezobchuk Co-authored-by: Aaron Craelius --- docs/architecture/README.md | 1 + .../adr-035-rosetta-api-support.md | 274 ++++++++++++++++++ 2 files changed, 275 insertions(+) create mode 100644 docs/architecture/adr-035-rosetta-api-support.md diff --git a/docs/architecture/README.md b/docs/architecture/README.md index 6d4c2a2ac..d9a52d389 100644 --- a/docs/architecture/README.md +++ b/docs/architecture/README.md @@ -71,3 +71,4 @@ Read about the [PROCESS](./PROCESS.md). - [ADR 028: Public Key Addresses](./adr-028-public-key-addresses.md) - [ADR 031: Protobuf Msg Services](./adr-031-msg-service.md) - [ADR 032: Typed Events](./adr-032-typed-events.md) +- [ADR 035: Rosetta API Support](./adr-035-rosetta-api-support.md) diff --git a/docs/architecture/adr-035-rosetta-api-support.md b/docs/architecture/adr-035-rosetta-api-support.md new file mode 100644 index 000000000..2da663f57 --- /dev/null +++ b/docs/architecture/adr-035-rosetta-api-support.md @@ -0,0 +1,274 @@ +# ADR 035: Rosetta API Support + +## Authors + +- Jonathan Gimeno (@jgimeno) +- David Grierson (@senormonito) +- Alessio Treglia (@alessio) + +## Context + +[Rosetta API](https://www.rosetta-api.org/) is an open-source specification and set of tools developed by Coinbase to +standardise blockchain interactions. + +Through the use of a standard API for integrating blockchain applications it will + +* Be easier for a user to interact with a given blockchain +* Allow exchanges to integrate new blockchains quickly and easily +* Enable application developers to build cross-blockchain applications such as block explorers, wallets and dApps at + considerably lower cost and effort. + +## Decision + +It is clear that adding Rosetta API support to the Cosmos SDK will bring value to all the developers and +Cosmos SDK based chains in the ecosystem. How it is implemented is key. + +The driving principles of the proposed design are: + +1. **Extensibility:** it must be as riskless and painless as possible for application developers to set-up network + configurations to expose Rosetta API-compliant services. +2. **Long term support:** This proposal aims to provide support for all the supported Cosmos SDK release series. +3. **Cost-efficiency:** Backporting changes to Rosetta API specifications from `master` to the various stable + branches of Cosmos SDK is a cost that needs to be reduced. + +We will achieve these delivering on these principles by the following: + +1. There will be an external repo called [cosmos-rosetta-gateway](https://github.com/tendermint/cosmos-rosetta-gateway) + for the implementation of the core Rosetta API features, particularly: + a. The types and interfaces. This separates design from implementation detail. + b. Some core implementations: specifically, the `Service` functionality as this is independent of the Cosmos SDK version. +2. Due to differences between the Cosmos release series, each series will have its own specific API implementations of `Network` struct and `Adapter` interface. +3. There will be two options for starting an API service in applications: + a. API shares the application process + b. API-specific process. + + +## Architecture + +### The External Repo + +As section will describe the proposed external library, including the service implementation, plus the defined types and interfaces. + +#### Service + +`Service` is a simple `struct` that is started and listens to the port specified in the options. This is meant to be used across all the Cosmos SDK versions that are actively supported. + +The constructor follows: + +`func New(options Options, network Network) (*Service, error)` + +#### Types + +`Service` accepts an `Options` `struct` that holds service configuration values, such as the port the service would be listening to: + +```golang +type Options struct { + ListenAddress string +} +``` + +The `Network` type holds network-specific properties (i.e. configuration values) and adapters. Pre-configured concrete types will be available for each Cosmos SDK release. Applications can also create their own custom types. + +```golang +type Network struct { + Properties rosetta.NetworkProperties + Adapter rosetta.Adapter +} +``` + +A `NetworkProperties` `struct` comprises basic values that are required by a Rosetta API `Service`: + +```golang +type NetworkProperties struct { + // Mandatory properties + Blockchain string + Network string + SupportedOperations []string +} +``` + +Rosetta API services use `Blockchain` and `Network` as identifiers, e.g. the developers of _gaia_, the application that powers the Cosmos Hub, may want to set those to `Cosmos Hub` and `cosmos-hub-3` respectively. + +`SupportedOperations` contains the transaction types that are supported by the library. At the present time, +only `cosmos-sdk/MsgSend` is supported in Launchpad. Additional operations will be added in due time. + +For Launchpad we will map the amino type name to the operation supported, in Stargate we will use the protoc one. + +#### Interfaces + +Every SDK version uses a different format to connect (rpc, gRpc, etc), we have abstracted this in what is called the +Adapter. This is an interface that defines the methods an adapter implementation must provide in order to be used +in the `Network` interface. + +Each Cosmos SDK release series will have their own Adapter implementations. +Developers can implement their own custom adapters as required. + +```golang +type Adapter interface { + DataAPI + ConstructionAPI +} + +type DataAPI interface { + server.NetworkAPIServicer + server.AccountAPIServicer + server.MempoolAPIServicer + server.BlockAPIServicer + server.ConstructionAPIServicer +} + +type ConstructionAPI interface { + server.ConstructionAPIServicer +} +``` + +Example in pseudo-code of an Adapter interface: + +```golang +type SomeAdapter struct { + cosmosClient client + tendermintClient client +} + +func NewSomeAdapter(cosmosClient client, tendermintClient client) rosetta.Adapter { + return &SomeAdapter{cosmosClient: cosmosClient, tendermintClient: tendermintClient} +} + +func (s SomeAdapter) NetworkStatus(ctx context.Context, request *types.NetworkRequest) (*types.NetworkStatusResponse, *types.Error) { + resp := s.tendermintClient.CallStatus() + // ... Parse status Response + // build NetworkStatusResponse + return networkStatusResp, nil +} + +func (s SomeAdapter) AccountBalance(ctx context.Context, request *types.AccountBalanceRequest) (*types.AccountBalanceResponse, *types.Error) { + resp := s.cosmosClient.Account() + // ... Parse cosmos specific account response + // build AccountBalanceResponse + return AccountBalanceResponse, nil +} + +// And we repeat for all the methods defined in the interface. +``` + +For further information about the `Servicer` interfaces, please refer to the [Coinbase's rosetta-sdk-go's documentation](https://pkg.go.dev/github.com/coinbase/rosetta-sdk-go@v0.5.9/server). + +### 2. Cosmos SDK Implementation + +As described, each Cosmos SDK release series will have version specific implementations of `Network` and `Adapter`, as +well as a `NewNetwork` constructor. + +Due to separation of interface and implementation, application developers have the option to override as needed, +using this code as reference. + +```golang +// NewNetwork returns the default application configuration. +func NewNetwork(options Options) service.Network { + cosmosClient := cosmos.NewClient(fmt.Sprintf("http://%s", options.CosmosEndpoint)) + tendermintClient := tendermint.NewClient(fmt.Sprintf("http://%s", options.TendermintEndpoint)) + + return service.Network{ + Properties: rosetta.NetworkProperties{ + Blockchain: options.Blockchain, + Network: options.Network, + SupportedOperations: []string{OperationTransfer}, + }, + Adapter: newAdapter( + cosmosClient, + tendermintClient, + properties{ + Blockchain: options.Blockchain, + Network: options.Network, + OfflineMode: options.OfflineMode, + }, + ), + } +} +``` + +### 3. API service invocation + +As stated at the start, application developers will have two methods for invocation of the Rosetta API service: + +1. Shared process for both application and API +2. Standalone API service + +#### Shared Process (Only Stargate) + +Rosetta API service could run within the same execution process as the application. New configuration option and +command line flags would be provided to support this: + +```golang + if config.Rosetta.Enable { + .... + get contecxt, flags, etc + ... + + h, err := service.New( + service.Options{ListenAddress: config.Rosetta.ListenAddress}, + rosetta.NewNetwork(cdc, options), + ) + if err != nil { + } + + ... + + go func() { + if err := h.Start(config); err != nil { + errCh <- err + } + }() + } + +``` + +#### Separate API service + +Client application developers can write a new command to launch a Rosetta API server as a separate process too: + +```golang +func RosettaCommand(cdc *codec.Codec) *cobra.Command { + + ... + cmd := &cobra.Command{ + Use: "rosetta", + .... + + RunE: func(cmd *cobra.Command, args []string) error { + .... + get contecxt, flags, etc + ... + + h, err := service.New( + service.Options{Endpoint: endpoint}, + rosetta.NewNetwork(cdc, options), + ) + if err != nil { + return err + } + + ... + + h.Start() + } + } + ... + +} +``` + +## Status + +Proposed + +## Consequences + +### Positive + +- Out-of-the-box Rosetta API support within Cosmos SDK. +- Blockchain interface standardisation + +## References + +- https://www.rosetta-api.org/ +- https://github.com/tendermint/cosmos-rosetta-gateway From e57745bebceab4a66e760a6755199940c6a9568b Mon Sep 17 00:00:00 2001 From: billy rennekamp Date: Fri, 6 Nov 2020 12:05:41 +0100 Subject: [PATCH 04/24] Update cosmovisor.md (#7837) --- docs/using-the-sdk/cosmovisor.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/using-the-sdk/cosmovisor.md b/docs/using-the-sdk/cosmovisor.md index 21d3ee34a..870bbae23 100644 --- a/docs/using-the-sdk/cosmovisor.md +++ b/docs/using-the-sdk/cosmovisor.md @@ -33,7 +33,7 @@ if there was an error. ## Data Folder Layout `$DAEMON_HOME/cosmovisor` is expected to belong completely to `cosmovisor` and -subprocesses the controlled by it. The folder content is organised as follows: +subprocesses that are controlled by it. The folder content is organised as follows: ``` . From da1c8162debe9078ee1527cf89bc3e3437a6d2af Mon Sep 17 00:00:00 2001 From: Cyrus Goh Date: Fri, 6 Nov 2020 03:21:53 -0800 Subject: [PATCH 05/24] docs: fix broken url in cn/basics/app-anatomy.md (master) (#7831) * Fix package-lock * Fix package-lock * update package-lock * bump docs theme to 1.0.171 * Fix typo, chinese character in URL * update dead doc links * bump docs theme to 1.0.172 * [favicons] add favicons * makefile: change build-docs target for shells other than bash * docs: set master as default version * docs: add v0.40.x to versions * bump vuepress-theme-cosmos 1.0.175 * docs: fix broken url in cn/basics/app-anatomy.md Co-authored-by: Denis Fadeev Co-authored-by: Federico Kunze <31522760+fedekunze@users.noreply.github.com> Co-authored-by: vms Co-authored-by: Helder Moreira Co-authored-by: Amaury Martiny Co-authored-by: Alessio Treglia Co-authored-by: mergify[bot] <37929162+mergify[bot]@users.noreply.github.com> --- docs/cn/basics/app-anatomy.md | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/docs/cn/basics/app-anatomy.md b/docs/cn/basics/app-anatomy.md index 7909c40c8..813e9c6c4 100644 --- a/docs/cn/basics/app-anatomy.md +++ b/docs/cn/basics/app-anatomy.md @@ -148,7 +148,8 @@ AppModule 在模块上公开了一组有用的方法,这些方法有助于将 模块的`处理程序`通常在名为 `handler.go` 的文件中定义,并包括: - NewHandler 将消息发到对应的回调 `handler`。 该函数返回一个 `handler` 函数,此前这个函数在 `AppModule` 中注册,以在应用程序的模块管理器中用于初始化应用程序的路由器。接下来是 [nameservice tutorial](https://github.com/cosmos/sdk-tutorials/tree/master/nameservice) 的一个例子。 - +++ https://github.com/cosmos/sdk-tutorials/blob/master/nameservice/x/nameservice/handler.go#L12-L26 + ++++ https://github.com/cosmos/sdk-tutorials/blob/86a27321cf89cc637581762e953d0c07f8c78ece/nameservice/x/nameservice/internal/keeper/querier.go#L19-L32 - 模块定义的每种消息类型的处理函数。开发人员在这些函数中编写消息处理逻辑。这通常包括进行状态检查以确保消息有效,并调用 [`keeper`](https://docs.cosmos.network/master/basics/app-anatomy.html#keeper) 的方法来更新状态。 From 590358652cc1cbc13872ea1659187e073ea38e75 Mon Sep 17 00:00:00 2001 From: Cory Date: Fri, 6 Nov 2020 11:15:26 -0800 Subject: [PATCH 06/24] update changelog for rc3 (#7843) --- CHANGELOG.md | 2 ++ 1 file changed, 2 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index 30a10deaf..c10fd1385 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -36,6 +36,8 @@ Ref: https://keepachangelog.com/en/1.0.0/ ## [Unreleased] +## [v0.40.0-rc3](https://github.com/cosmos/cosmos-sdk/releases/tag/v0.40.0-rc3) - 2020-11-06 + ### Improvements * (tendermint) [\#7828](https://github.com/cosmos/cosmos-sdk/pull/7828) Update tendermint dependency to v0.34.0-rc6 From dd9ef120f3415c4d84d3ce34267453ecb94b797f Mon Sep 17 00:00:00 2001 From: Ethan Buchman Date: Sat, 7 Nov 2020 15:38:26 -0500 Subject: [PATCH 07/24] x/cap: fix comments, SetIndex, and some tests (#7845) * x/cap: fix comments and some tests * fix lint * Apply suggestions from code review Co-authored-by: Alessio Treglia Co-authored-by: Alessio Treglia --- x/capability/genesis.go | 4 ++- x/capability/keeper/keeper.go | 42 +++++++++++++++++------------- x/capability/keeper/keeper_test.go | 28 +++++++++++++++----- 3 files changed, 49 insertions(+), 25 deletions(-) diff --git a/x/capability/genesis.go b/x/capability/genesis.go index 07bf6df7e..9bcca42a3 100644 --- a/x/capability/genesis.go +++ b/x/capability/genesis.go @@ -9,7 +9,9 @@ import ( // InitGenesis initializes the capability module's state from a provided genesis // state. func InitGenesis(ctx sdk.Context, k keeper.Keeper, genState types.GenesisState) { - k.SetIndex(ctx, genState.Index) + if err := k.SetIndex(ctx, genState.Index); err != nil { + panic(err) + } // set owners for each index and initialize capability for _, genOwner := range genState.Owners { diff --git a/x/capability/keeper/keeper.go b/x/capability/keeper/keeper.go index cb4d31df0..492d56c91 100644 --- a/x/capability/keeper/keeper.go +++ b/x/capability/keeper/keeper.go @@ -117,12 +117,22 @@ func (k *Keeper) InitializeAndSeal(ctx sdk.Context) { k.sealed = true } -// SetIndex sets the index to one in InitChain -// Since it is an exported function, we check that index is indeed unset, before initializing -func (k Keeper) SetIndex(ctx sdk.Context, index uint64) { +// SetIndex sets the index to one (or greater) in InitChain according +// to the GenesisState. It must only be called once. +// It will panic if the provided index is 0, or if the index is already set. +func (k Keeper) SetIndex(ctx sdk.Context, index uint64) error { + if index == 0 { + panic("SetIndex requires index > 0") + } + latest := k.GetLatestIndex(ctx) + if latest > 0 { + panic("SetIndex requires index to not be set") + } + // set the global index to the passed index store := ctx.KVStore(k.storeKey) store.Set(types.KeyIndex, types.IndexToKey(index)) + return nil } // GetLatestIndex returns the latest index of the CapabilityKeeper @@ -156,7 +166,8 @@ func (k Keeper) GetOwners(ctx sdk.Context, index uint64) (types.CapabilityOwners } // InitializeCapability takes in an index and an owners array. It creates the capability in memory -// and sets the fwd and reverse keys for each owner in the memstore +// and sets the fwd and reverse keys for each owner in the memstore. +// It is used during initialization from genesis. func (k Keeper) InitializeCapability(ctx sdk.Context, index uint64, owners types.CapabilityOwners) { memStore := ctx.KVStore(k.memKey) @@ -278,14 +289,12 @@ func (sk ScopedKeeper) ReleaseCapability(ctx sdk.Context, cap *types.Capability) memStore := ctx.KVStore(sk.memKey) - // Set the forward mapping between the module and capability tuple and the + // Delete the forward mapping between the module and capability tuple and the // capability name in the memKVStore memStore.Delete(types.FwdCapabilityKey(sk.module, cap)) - // Set the reverse mapping between the module and capability name and the - // index in the in-memory store. Since marshalling and unmarshalling into a store - // will change memory address of capability, we simply store index as value here - // and retrieve the in-memory pointer to the capability from our map + // Delete the reverse mapping between the module and capability name and the + // index in the in-memory store. memStore.Delete(types.RevCapabilityKey(sk.module, name)) // remove owner @@ -298,7 +307,7 @@ func (sk ScopedKeeper) ReleaseCapability(ctx sdk.Context, cap *types.Capability) if len(capOwners.Owners) == 0 { // remove capability owner set prefixStore.Delete(indexKey) - // since no one ones capability, we can delete capability from map + // since no one owns capability, we can delete capability from map delete(sk.capMap, cap.GetIndex()) } else { // update capability owner set @@ -370,7 +379,7 @@ func (sk ScopedKeeper) GetOwners(ctx sdk.Context, name string) (*types.Capabilit // LookupModules returns all the module owners for a given capability // as a string array and the capability itself. -// The method returns an errors if either the capability or the owners cannot be +// The method returns an error if either the capability or the owners cannot be // retreived from the memstore. func (sk ScopedKeeper) LookupModules(ctx sdk.Context, name string) ([]string, *types.Capability, error) { cap, ok := sk.GetCapability(ctx, name) @@ -413,16 +422,13 @@ func (sk ScopedKeeper) getOwners(ctx sdk.Context, cap *types.Capability) *types. bz := prefixStore.Get(indexKey) - var owners *types.CapabilityOwners if len(bz) == 0 { - owners = types.NewCapabilityOwners() - } else { - var capOwners types.CapabilityOwners - sk.cdc.MustUnmarshalBinaryBare(bz, &capOwners) - owners = &capOwners + return types.NewCapabilityOwners() } - return owners + var capOwners types.CapabilityOwners + sk.cdc.MustUnmarshalBinaryBare(bz, &capOwners) + return &capOwners } func logger(ctx sdk.Context) log.Logger { diff --git a/x/capability/keeper/keeper_test.go b/x/capability/keeper/keeper_test.go index fdd795341..c6f1d174b 100644 --- a/x/capability/keeper/keeper_test.go +++ b/x/capability/keeper/keeper_test.go @@ -75,11 +75,15 @@ func (suite *KeeperTestSuite) TestInitializeAndSeal() { func (suite *KeeperTestSuite) TestNewCapability() { sk := suite.keeper.ScopeToModule(banktypes.ModuleName) + got, ok := sk.GetCapability(suite.ctx, "transfer") + suite.Require().False(ok) + suite.Require().Nil(got) + cap, err := sk.NewCapability(suite.ctx, "transfer") suite.Require().NoError(err) suite.Require().NotNil(cap) - got, ok := sk.GetCapability(suite.ctx, "transfer") + got, ok = sk.GetCapability(suite.ctx, "transfer") suite.Require().True(ok) suite.Require().Equal(cap, got) suite.Require().True(cap == got, "expected memory addresses to be equal") @@ -88,9 +92,19 @@ func (suite *KeeperTestSuite) TestNewCapability() { suite.Require().False(ok) suite.Require().Nil(got) - cap, err = sk.NewCapability(suite.ctx, "transfer") + got, ok = sk.GetCapability(suite.ctx, "transfer") + suite.Require().True(ok) + suite.Require().Equal(cap, got) + suite.Require().True(cap == got, "expected memory addresses to be equal") + + cap2, err := sk.NewCapability(suite.ctx, "transfer") suite.Require().Error(err) - suite.Require().Nil(cap) + suite.Require().Nil(cap2) + + got, ok = sk.GetCapability(suite.ctx, "transfer") + suite.Require().True(ok) + suite.Require().Equal(cap, got) + suite.Require().True(cap == got, "expected memory addresses to be equal") } func (suite *KeeperTestSuite) TestOriginalCapabilityKeeper() { @@ -111,7 +125,8 @@ func (suite *KeeperTestSuite) TestAuthenticateCapability() { suite.Require().NoError(err) suite.Require().NotNil(cap1) - forgedCap := types.NewCapability(0) // index should be the same index as the first capability + forgedCap := types.NewCapability(cap1.Index) // index should be the same index as the first capability + suite.Require().False(sk1.AuthenticateCapability(suite.ctx, forgedCap, "transfer")) suite.Require().False(sk2.AuthenticateCapability(suite.ctx, forgedCap, "transfer")) cap2, err := sk2.NewCapability(suite.ctx, "bond") @@ -176,14 +191,15 @@ func (suite *KeeperTestSuite) TestGetOwners() { // Ensure all scoped keepers can get owners for _, sk := range sks { owners, ok := sk.GetOwners(suite.ctx, "transfer") - mods, cap, err := sk.LookupModules(suite.ctx, "transfer") + mods, gotCap, err := sk.LookupModules(suite.ctx, "transfer") suite.Require().True(ok, "could not retrieve owners") suite.Require().NotNil(owners, "owners is nil") suite.Require().NoError(err, "could not retrieve modules") - suite.Require().NotNil(cap, "capability is nil") + suite.Require().NotNil(gotCap, "capability is nil") suite.Require().NotNil(mods, "modules is nil") + suite.Require().Equal(cap, gotCap, "caps not equal") suite.Require().Equal(len(expectedOrder), len(owners.Owners), "length of owners is unexpected") for i, o := range owners.Owners { From 0e0ed66212483e9d9dbb137edde057ec193c2213 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 9 Nov 2020 09:43:08 +0100 Subject: [PATCH 08/24] build(deps): bump actions/cache from v2.1.2 to v2.1.3 (#7850) Bumps [actions/cache](https://github.com/actions/cache) from v2.1.2 to v2.1.3. - [Release notes](https://github.com/actions/cache/releases) - [Commits](https://github.com/actions/cache/compare/v2.1.2...0781355a23dac32fd3bac414512f4b903437991a) Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> --- .github/workflows/release-sims.yml | 4 ++-- .github/workflows/sims.yml | 10 +++++----- .github/workflows/test.yml | 4 ++-- 3 files changed, 9 insertions(+), 9 deletions(-) diff --git a/.github/workflows/release-sims.yml b/.github/workflows/release-sims.yml index 4f1dae7a9..68ca31051 100644 --- a/.github/workflows/release-sims.yml +++ b/.github/workflows/release-sims.yml @@ -30,7 +30,7 @@ jobs: - name: install runsim run: | export GO111MODULE="on" && go get github.com/cosmos/tools/cmd/runsim@v1.0.0 - - uses: actions/cache@v2.1.2 + - uses: actions/cache@v2.1.3 with: path: ~/go/bin key: ${{ runner.os }}-go-runsim-binary @@ -40,7 +40,7 @@ jobs: needs: [build, install-runsim] steps: - uses: actions/checkout@v2 - - uses: actions/cache@v2.1.2 + - uses: actions/cache@v2.1.3 with: path: ~/go/bin key: ${{ runner.os }}-go-runsim-binary diff --git a/.github/workflows/sims.yml b/.github/workflows/sims.yml index de2e9bb10..d50ddb63a 100644 --- a/.github/workflows/sims.yml +++ b/.github/workflows/sims.yml @@ -39,7 +39,7 @@ jobs: run: go version - name: Install runsim run: export GO111MODULE="on" && go get github.com/cosmos/tools/cmd/runsim@v1.0.0 - - uses: actions/cache@v2.1.2 + - uses: actions/cache@v2.1.3 with: path: ~/go/bin key: ${{ runner.os }}-go-runsim-binary @@ -60,7 +60,7 @@ jobs: **/**.go go.mod go.sum - - uses: actions/cache@v2.1.2 + - uses: actions/cache@v2.1.3 with: path: ~/go/bin key: ${{ runner.os }}-go-runsim-binary @@ -88,7 +88,7 @@ jobs: go.sum SET_ENV_NAME_INSERTIONS: 1 SET_ENV_NAME_LINES: 1 - - uses: actions/cache@v2.1.2 + - uses: actions/cache@v2.1.3 with: path: ~/go/bin key: ${{ runner.os }}-go-runsim-binary @@ -116,7 +116,7 @@ jobs: go.sum SET_ENV_NAME_INSERTIONS: 1 SET_ENV_NAME_LINES: 1 - - uses: actions/cache@v2.1.2 + - uses: actions/cache@v2.1.3 with: path: ~/go/bin key: ${{ runner.os }}-go-runsim-binary @@ -144,7 +144,7 @@ jobs: go.sum SET_ENV_NAME_INSERTIONS: 1 SET_ENV_NAME_LINES: 1 - - uses: actions/cache@v2.1.2 + - uses: actions/cache@v2.1.3 with: path: ~/go/bin key: ${{ runner.os }}-go-runsim-binary diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index 4c81b2200..afa753e23 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -26,7 +26,7 @@ jobs: - name: install tparse run: | export GO111MODULE="on" && go get github.com/mfridman/tparse@v0.8.3 - - uses: actions/cache@v2.1.2 + - uses: actions/cache@v2.1.3 with: path: ~/go/bin key: ${{ runner.os }}-go-tparse-binary @@ -216,7 +216,7 @@ jobs: with: name: "${{ github.sha }}-03-race-output" if: env.GIT_DIFF - - uses: actions/cache@v2.1.2 + - uses: actions/cache@v2.1.3 with: path: ~/go/bin key: ${{ runner.os }}-go-tparse-binary From f294db9ccff7d4de1d6a1ae5f8738177bd874a56 Mon Sep 17 00:00:00 2001 From: Federico Kunze <31522760+fedekunze@users.noreply.github.com> Date: Mon, 9 Nov 2020 09:49:16 +0100 Subject: [PATCH 09/24] x/ibc: transfer specs (#7580) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * x/ibc: transfer specs * update titles and list todos * denom trace and client UX * add UX recommendations and locked funds section * metrics * state transitions * Apply suggestions from code review Co-authored-by: colin axnér <25233464+colin-axner@users.noreply.github.com> * address comments from review * jack suggestions * add example * fix * address comments from call with @zakimanian * Update x/ibc/applications/transfer/spec/01_concepts.md Co-authored-by: Christopher Goes * add comment about verification * address comments from review Co-authored-by: colin axnér <25233464+colin-axner@users.noreply.github.com> Co-authored-by: Christopher Goes --- .../applications/transfer/spec/01_concepts.md | 100 +++++++++++++++++- x/ibc/applications/transfer/spec/02_state.md | 5 + .../transfer/spec/03_state_transitions.md | 31 ++++++ .../applications/transfer/spec/04_messages.md | 4 +- .../applications/transfer/spec/06_metrics.md | 14 +++ .../spec/{06_params.md => 07_params.md} | 6 +- x/ibc/applications/transfer/spec/README.md | 3 +- 7 files changed, 155 insertions(+), 8 deletions(-) create mode 100644 x/ibc/applications/transfer/spec/06_metrics.md rename x/ibc/applications/transfer/spec/{06_params.md => 07_params.md} (78%) diff --git a/x/ibc/applications/transfer/spec/01_concepts.md b/x/ibc/applications/transfer/spec/01_concepts.md index a9e1a30cc..55b8a6c0c 100644 --- a/x/ibc/applications/transfer/spec/01_concepts.md +++ b/x/ibc/applications/transfer/spec/01_concepts.md @@ -9,7 +9,103 @@ order: 1 ICS20 uses the recommended acknowledgement format as specified by [ICS 04](https://github.com/cosmos/ics/tree/master/spec/ics-004-channel-and-packet-semantics#acknowledgement-envelope). A successful receive of a transfer packet will result in a Result Acknowledgement being written -with the value `[]byte(byte(1))` in the `Response` field. +with the value `[]byte(byte(1))` in the `Response` field. An unsuccessful receive of a transfer packet will result in an Error Acknowledgement being written -with the error message in the `Response` field. +with the error message in the `Response` field. + +## Denomination Trace + +The denomination trace corresponds to the information that allows a token to be traced back to its +origin chain. It contains a sequence of port and channel identifiers ordered from the most recent to +the oldest in the timeline of transfers. + +This information is included on the token denomination field in the form of a hash to prevent an +unbounded denomination length. For example, the token `transfer/channelToA/uatom` will be displayed +as `ibc/7F1D3FCF4AE79E1554D670D1AD949A9BA4E4A3C76C63093E17E446A46061A7A2`. + +Each send to any chain other than the one it was previously received from is a movement forwards in +the token's timeline. This causes trace to be added to the token's history and the destination port +and destination channel to be prefixed to the denomination. In these instances the sender chain is +acting as the "source zone". When the token is sent back to the chain it previously received from, the +prefix is removed. This is a backwards movement in the token's timeline and the sender chain is +acting as the "sink zone". + +It is strongly recommended to read the full details of [ADR 001: Coin Source Tracing](./../../../../../docs/architecture/adr-001-coin-source-tracing.md) to understand the implications and context of the IBC token representations. + +### UX suggestions for clients + +For clients (wallets, exchanges, applications, block explorers, etc) that want to display the source of the token, it is recommended to use the following +alternatives for each of the cases below: + +#### Direct connection + +If the denomination trace contains a single identifier prefix pair (as in the example above), then +the easiest way to retrieve the chain and light client identifier is to map the trace information +directly. In summary, this requires querying the channel from the denomination trace identifiers, +and then the counterparty client state using the counterparty port and channel identifiers from the +retrieved channel. + +A general pseudo algorithm would look like the following: + +1. Query the full denomination trace. +2. Query the channel with the `portID/channelID` pair, which corresponds to the first destination of the + token. +3. Query the client state using the identifiers pair. Note that this query will return a `"Not + Found"` response if the current chain is not connected to this channel. +4. Retrieve the the client identifier or chain identifier from the client state (eg: on + Tendermint clients) and store it locally. + +Using the gRPC gataway client service the steps above would be, with a given IBC token `ibc/7F1D3FCF4AE79E1554D670D1AD949A9BA4E4A3C76C63093E17E446A46061A7A2` stored on `chainB`: + +1. `GET /ibc_transfer/v1beta1/denom_traces/7F1D3FCF4AE79E1554D670D1AD949A9BA4E4A3C76C63093E17E446A46061A7A2` -> `{"path": "transfer/channelToA", "base_denom": "uatom"}` +2. `GET /ibc/channel/v1beta1/channels/channelToA/ports/transfer/client_state"` -> `{"client_id": "clientA", "chain-id": "chainA", ...}` +3. `GET /ibc/channel/v1beta1/channels/channelToA/ports/transfer"` -> `{"channel_id": "channelToA", port_id": "transfer", counterparty: {"channel_id": "channelToB", port_id": "transfer"}, ...}` +4. `GET /ibc/channel/v1beta1/channels/channelToB/ports/transfer/client_state" -> {"client_id": "clientB", "chain-id": "chainB", ...}` + +Then, the token transfer chain path for the `uatom` denomination would be: `chainA` -> `chainB`. + +### Multiple hops + +The multiple channel hops case applies when the token has passed through multiple chains between the original source and final destination chains. + +The IBC protocol doesn't know the topology of the overall network (i.e connections between chains and identifier names between them). For this reason, in the the multiple hops case, a particular chain in the timeline of the individual transfers can't query the chain and client identifiers of the other chains. + +Take for example the following sequence of transfers `A -> B -> C` for an IBC token, with a final prefix path (trace info) of `transfer/channelChainC/transfer/channelChainB`. What the paragraph above means is that is that even in the case that chain `C` is directly connected to chain `A`, querying the port and channel identifiers that chain `B` uses to connect to chain `A` (eg: `transfer/channelChainA`) can be completely different from the one that chain `C` uses to connect to chain `A` (eg: `transfer/channelToChainA`). + +Thus the proposed solution for clients that the IBC team recommends are the following: + +- **Connect to all chains**: Connecting to all the chains in the timeline would allow clients to + perform the queries outlined in the [direct connection](#direct-connection) section to each + relevant chain. By repeatedly following the port and channel denomination trace transfer timeline, + clients should always be able to find all the relevant identifiers. This comes at the tradeoff + that the client must connect to nodes on each of the chains in order to perform the queries. +- **Relayer as a Service (RaaS)**: A longer term solution is to use/create a relayer service that + could map the denomination trace to the chain path timeline for each token (i.e `origin chain -> + chain #1 -> ... -> chain #(n-1) -> final chain`). These services could provide merkle proofs in + order to allow clients to optionally verify the path timeline correctness for themselves by + running light clients. If the proofs are not verified, they should be considered as trusted third + parties services. Additionally, client would be advised in the future to use RaaS that support the + largest number of connections between chains in the ecosystem. Unfortunately, none of the existing + public relayers (in [Golang](https://github.com/cosmos/relayer) and + [Rust](https://github.com/informalsystems/ibc-rs)), provide this service to clients. + +::: tip +The only viable alternative for clients (at the time of writing) to tokens with multiple connection hops, is to connect to all chains directly and perform relevant queries to each of them in the sequence. +::: + +## Locked Funds + +In some [exceptional cases](./../../../../../docs/architecture/adr-026-ibc-client-recovery-mechanisms.md#exceptional-cases), a client state associated with a given channel cannot be updated. This causes that funds from fungible tokens in that channel will be permanently locked and thus can no longer be transferred. + +To mitigate this, a client update governance proposal can be submitted to update the frozen client +with a new valid header. Once the proposal passes the client state will be unfrozen and the funds +from the associated channels will then be unlocked. This mechanism only applies to clients that +allow updates via governance, such as Tendermint clients. + +In addition to this, it's important to mention that a token must be sent back along the exact route +that it took originally un order to return it to its original form on the source chain (eg: the +Cosmos Hub for the `uatom`). Sending a token back to the same chain across a different channel will +**not** move the token back across its timeline. If a channel in the chain history closes before the +token can be sent back across that channel, then the token will not be returnable to its original +form. diff --git a/x/ibc/applications/transfer/spec/02_state.md b/x/ibc/applications/transfer/spec/02_state.md index b57ac80f2..9cab8d677 100644 --- a/x/ibc/applications/transfer/spec/02_state.md +++ b/x/ibc/applications/transfer/spec/02_state.md @@ -3,3 +3,8 @@ order: 2 --> # State + +The transfer IBC application module keeps state of the port to which the module is binded and the denomination trace information as outlined in [ADR 01](./../../../../../docs/architecture/adr-001-coin-source-tracing.md). + +- `Port`: `0x01 -> ProtocolBuffer(string)` +- `DenomTrace`: `0x02 | []bytes(traceHash) -> ProtocolBuffer(DenomTrace)` diff --git a/x/ibc/applications/transfer/spec/03_state_transitions.md b/x/ibc/applications/transfer/spec/03_state_transitions.md index 4782e38a4..9090da543 100644 --- a/x/ibc/applications/transfer/spec/03_state_transitions.md +++ b/x/ibc/applications/transfer/spec/03_state_transitions.md @@ -3,3 +3,34 @@ order: 3 --> # State Transitions + +## Send Fungible Tokens + +A successful fungible token send has two state transitions depending if the +transfer is a movement forward or backwards in the token's timeline: + +1. Sender chain is the source chain, *i.e* a transfer to any chain other than the one it was previously received from is a movement forwards in the token's timeline. This results in the following state transitions: + +- The coins are transferred to an escrow address (i.e locked) on the sender chain +- The coins are transferred to the receiving chain through IBC TAO logic. + +2. Sender chain is the sink chain, *i.e* the token is sent back to the chain it previously received from. This is a backwards movement in the token's timeline. This results in the following state transitions: + +- The coins (vouchers) are burned on the sender chain +- The coins transferred to the receiving chain though IBC TAO logic. + +## Receive Fungible Tokens + +A successful fungible token receive has two state transitions depending if the +transfer is a movement forward or backwards in the token's timeline: + +1. Receiver chain is the source chain. This is a backwards movement in the token's timeline. This results in the following state transitions: + +- The leftmost port and channel identifier pair is removed from the token denomination prefix. +- The tokens are unescrowed and sent to the receiving address. + +2. Receiver chain is the sink chain. This is a movement forwards in the token's timeline. This results in the following state transitions: + +- Token vouchers are minted by prefixing the destination port and channel identifiers to the trace information. +- The receiving chain stores the new trace information in the store (if not set already). +- The vouchers are sent to the receiving address. diff --git a/x/ibc/applications/transfer/spec/04_messages.md b/x/ibc/applications/transfer/spec/04_messages.md index dfd17d07f..9da7673eb 100644 --- a/x/ibc/applications/transfer/spec/04_messages.md +++ b/x/ibc/applications/transfer/spec/04_messages.md @@ -13,7 +13,7 @@ type MsgTransfer struct { SourcePort string SourceChannel string Token sdk.Coin - Sender sdk.AccAddress + Sender string Receiver string TimeoutHeight ibcexported.Height TimeoutTimestamp uint64 @@ -29,7 +29,7 @@ This message is expected to fail if: - `Sender` is empty - `Receiver` is empty - `TimeoutHeight` and `TimeoutTimestamp` are both zero -- `Token.Denom` is not a valid IBC denomination as per [ADR 001 - Coin Source Tracing](./../../../docs/architecture/adr-001-coin-source-tracing.md). +- `Token.Denom` is not a valid IBC denomination as per [ADR 001 - Coin Source Tracing](./../../../../../docs/architecture/adr-001-coin-source-tracing.md). This message will send a fungible token to the counterparty chain represented by the counterparty Channel End connected to the Channel End with the identifiers diff --git a/x/ibc/applications/transfer/spec/06_metrics.md b/x/ibc/applications/transfer/spec/06_metrics.md new file mode 100644 index 000000000..21bb51c0a --- /dev/null +++ b/x/ibc/applications/transfer/spec/06_metrics.md @@ -0,0 +1,14 @@ + + +# Metrics + +The transfer IBC application module exposes the following set of [metrics](./../../../../../docs/core/telemetry.md). + +| Metric | Description | Unit | Type | +|:--------------------------------|:------------------------------------------------------------------------------------------|:----------------|:--------| +| `tx_msg_ibc_transfer` | The total amount of tokens transferred via IBC in a `MsgTransfer` (source or sink chain) | token | gauge | +| `ibc_transfer_packet_receive` | The total amount of tokens received in a `FungibleTokenPacketData` (source or sink chain) | token | gauge | +| `ibc_transfer_send` | Total number of IBC transfers sent from a chain (source or sink) | transfer | counter | +| `ibc_transfer_receive` | Total number of IBC transfers received to a chain (source or sink) | transfer | counter | diff --git a/x/ibc/applications/transfer/spec/06_params.md b/x/ibc/applications/transfer/spec/07_params.md similarity index 78% rename from x/ibc/applications/transfer/spec/06_params.md rename to x/ibc/applications/transfer/spec/07_params.md index e6c7e7ff1..8d2b97c58 100644 --- a/x/ibc/applications/transfer/spec/06_params.md +++ b/x/ibc/applications/transfer/spec/07_params.md @@ -1,5 +1,5 @@ # Parameters @@ -17,7 +17,7 @@ The transfers enabled parameter controls send cross-chain transfer capabilities tokens. To prevent a single token from being transferred from the chain, set the `SendEnabled` parameter to `true` and -then set the bank module's [`SendEnabled` parameter](./../../bank/spec/05_params.md#sendenabled) for +then set the bank module's [`SendEnabled` parameter](./../../../../bank/spec/05_params.md#sendenabled) for the denomination to `false`. ## ReceiveEnabled @@ -26,5 +26,5 @@ The transfers enabled parameter controls receive cross-chain transfer capabiliti tokens. To prevent a single token from being transferred to the chain, set the `ReceiveEnabled` parameter to `true` and -then set the bank module's [`SendEnabled` parameter](./../../bank/spec/05_params.md#sendenabled) for +then set the bank module's [`SendEnabled` parameter](./../../../../bank/spec/05_params.md#sendenabled) for the denomination to `false`. diff --git a/x/ibc/applications/transfer/spec/README.md b/x/ibc/applications/transfer/spec/README.md index 963110e7a..5230fdde4 100644 --- a/x/ibc/applications/transfer/spec/README.md +++ b/x/ibc/applications/transfer/spec/README.md @@ -20,4 +20,5 @@ For the general specification please refer to the [ICS20 Specification](https:// 3. **[State Transitions](03_state_transitions.md)** 4. **[Messages](04_messages.md)** 5. **[Events](05_events.md)** -6. **[Parameters](06_params.md)** +6. **[Metrics](06_metrics.md)** +7. **[Parameters](07_params.md)** From 70fa17b55a97e99f2db09a9769416cf52a962193 Mon Sep 17 00:00:00 2001 From: Federico Kunze <31522760+fedekunze@users.noreply.github.com> Date: Mon, 9 Nov 2020 12:44:20 +0100 Subject: [PATCH 10/24] ibc: spec overview (#7853) --- x/ibc/core/spec/README.md | 92 +----------------------------- x/ibc/spec/README.md | 114 ++++++++++++++++++++++++++++++++++++++ 2 files changed, 117 insertions(+), 89 deletions(-) create mode 100644 x/ibc/spec/README.md diff --git a/x/ibc/core/spec/README.md b/x/ibc/core/spec/README.md index 432aca93e..0ae00bbcd 100644 --- a/x/ibc/core/spec/README.md +++ b/x/ibc/core/spec/README.md @@ -1,11 +1,11 @@ -# `ibc` +# `ibc core` ## Abstract @@ -23,89 +23,3 @@ For the general specification please refer to the [Interchain Standards](https:/ 4. **[Messages](04_messages.md)** 5. **[Callbacks](05_callbacks.md)** 6. **[Events](06_events.md)** - -## Implementation Details - -As stated above, the IBC implementation on the Cosmos SDK introduces some changes -to the general specification, in order to avoid code duplication and to take -advantage of the SDK architectural components such as the transaction routing -through `Handlers`. - -### Interchain Standards reference - -The following list is a mapping from each Interchain Standard to their implementation -in the SDK's `x/ibc` module: - -* [ICS 002 - Client Semantics](https://github.com/cosmos/ics/tree/master/spec/ics-002-client-semantics): Implemented in [`x/ibc/core/02-client`](https://github.com/cosmos/tree/master/ibc/core/02-client) -* [ICS 003 - Connection Semantics](https://github.com/cosmos/ics/blob/master/spec/ics-003-connection-semantics): Implemented in [`x/ibc/core/03-connection`](https://github.com/cosmos/tree/master/ibc/core/03-connection) -* [ICS 004 - Channel and Packet Semantics](https://github.com/cosmos/ics/blob/master/spec/ics-004-channel-and-packet-semantics): Implemented in [`x/ibc/core/04-channel`](https://github.com/cosmos/tree/master/ibc/core/04-channel) -* [ICS 005 - Port Allocation](https://github.com/cosmos/ics/blob/master/spec/ics-005-port-allocation): Implemented in [`x/ibc/core/05-port`](https://github.com/cosmos/tree/master/ibc/core/05-port) -* [ICS 006 - Solo Machine Client](https://github.com/cosmos/ics/blob/master/spec/ics-006-solo-machine-client): Implemented in [`x/ibc/light-clients/06-solomachine`](https://github.com/cosmos/tree/master/ibc/solomachine) -* [ICS 007 - Tendermint Client](https://github.com/cosmos/ics/blob/master/spec/ics-007-tendermint-client): Implemented in [`x/ibc/light-clients/07-tendermint`](https://github.com/cosmos/tree/master/ibc/light-clients/07-tendermint) -* [ICS 009 - Loopback Client](https://github.com/cosmos/ics/blob/master/spec/ics-009-loopback-client): Implemented in [`x/ibc/light-clients/09-localhost`](https://github.com/cosmos/tree/master/ibc/light-clients/09-localhost) -* [ICS 018- Relayer Algorithms](https://github.com/cosmos/ics/tree/master/spec/ics-018-relayer-algorithms): Implemented in it's own [relayer repository](https://github.com/cosmos/relayer) -* [ICS 020 - Fungible Token Transfer](https://github.com/cosmos/ics/tree/master/spec/ics-020-fungible-token-transfer): Implemented in [`x/ibc/applications/transfer`](https://github.com/cosmos/tree/master/ibc/applications/transfer) -* [ICS 023 - Vector Commitments](https://github.com/cosmos/ics/tree/master/spec/ics-023-vector-commitments): Implemented in [`x/ibc/core/23-commitment`](https://github.com/cosmos/tree/master/ibc/core/23-commitment) -* [ICS 024 - Host Requirements](https://github.com/cosmos/ics/tree/master/spec/ics-024-host-requirements): Implemented in [`x/ibc/core/24-host`](https://github.com/cosmos/tree/master/ibc/core/24-host) -* [ICS 025 - Handler Interface](https://github.com/cosmos/ics/tree/master/spec/ics-025-handler-interface): Handler interfaces are implemented at the top level in `x/ibc/handler.go`, -which call each ICS submodule's handlers (i.e `x/ibc/{XX-ICS}/handler.go`). -* [ICS 026 - Routing Module](https://github.com/cosmos/ics/blob/master/spec/ics-026-routing-module): Replaced by [ADR 15 - IBC Packet Receiver](../../../docs/architecture/adr-015-ibc-packet-receiver.md). - -### Architecture Decision Records (ADR) - -The following ADR provide the design and architecture decision of IBC-related components. - -* [ADR 001 - Coin Source Tracing](../../../docs/architecture/adr-001-coin-source-tracing.md): standard to hash the ICS20's fungible token -denomination trace path in order to support special characters and limit the maximum denomination length. -* [ADR 17 - Historical Header Module](../../../docs/architecture/adr-017-historical-header-module.md): Introduces the ability to introspect past -consensus states in order to verify their membership in the counterparty clients. -* [ADR 19 - Protobuf State Encoding](../../../docs/architecture/adr-019-protobuf-state-encoding.md): Migration from Amino to Protobuf for state encoding. -* [ADR 020 - Protocol Buffer Transaction Encoding](./../../docs/architecture/adr-020-protobuf-transaction-encoding.md): Client side migration to Protobuf. -* [ADR 021 - Protocol Buffer Query Encoding](../../../docs/architecture/adr-020-protobuf-query-encoding.md): Queries migration to Protobuf. -* [ADR 026 - IBC Client Recovery Mechanisms](../../../docs/architecture/adr-026-ibc-client-recovery-mechanisms.md): Allows IBC Clients to be recovered after freezing or expiry. - -### SDK Modules - -* [`x/capability`](https://github.com/cosmos/tree/master/x/capability): The capability module provides object-capability keys support through scoped keepers in order to authenticate usage of ports or channels. Check [ADR 3 - Dynamic Capability Store](../../../docs/architecture/adr-003-dynamic-capability-store.md) for more details. -* [`x/evidence`](https://github.com/cosmos/tree/master/x/evidence): The evidence module provides the interfaces and client logic to handle light client misbehaviour. Check [ADR 09 - Evidence Module](../../../docs/architecture/adr-009-evidence-module.md) for more details. - -## IBC module architecture - -> **NOTE for auditors**: If you're not familiar with the overall module structure from -the SDK modules, please check this [document](../../../docs/building-modules/structure.md) as -prerequisite reading. - -For ease of auditing, every Interchain Standard has been developed in its own -package. The development team separated the IBC TAO (Transport, Authentication, Ordering) ICS specifications from the IBC application level -specification. The following tree describes the architecture of the directories that -the `ibc` (TAO) and `ibc-transfer` ([ICS20](https://github.com/cosmos/ics/tree/master/spec/ics-020-fungible-token-transfer)) modules: - -```shell -x/ibc -├── applications/ -│ └──ibc-transfer/ -├── 02-client/ -├── 02-client/ -├── 03-connection/ -├── 04-channel/ -├── 05-port/ -├── light-clients/ -│   ├── 06-solomachine/ -│   ├── 07-tendermint/ -│   └── 09-localhost/ -├── 23-commitment/ -├── 24-host/ -├── client -│   ├── cli -│   │   └── cli.go -│   └── rest -│  └── rest.go -├── keeper -│  ├── keeper.go -│   └── querier.go -├── types -│ ├── errors.go -│ └── keys.go -├── handler.go -└── module.go -``` diff --git a/x/ibc/spec/README.md b/x/ibc/spec/README.md new file mode 100644 index 000000000..a699c10ab --- /dev/null +++ b/x/ibc/spec/README.md @@ -0,0 +1,114 @@ + + +# `ibc` + +## Abstract + +This specification defines the implementation of the IBC protocol on the Cosmos SDK, the +changes made to the specification and where to find each specific ICS spec within +the module. + +For the general specification please refer to the [Interchain Standards](https://github.com/cosmos/ics). + +## Contents + +1. **Applications** + + 1.1. [Transfer](./../applications/transfer/spec/README.md) +2. **[Core](./../core/spec/README.md)** +3. **Light Clients** + + 3.1 [Solo Machine Client](./../light-clients/06-solomachine/spec/README.md) + + 3.2 [Tendermint Client](./../light-clients/07-tendermint/spec/README.md) + + 3.3 [Localhost Client](./../light-clients/09-localhost/spec/README.md) + +## Implementation Details + +As stated above, the IBC implementation on the Cosmos SDK introduces some changes +to the general specification, in order to avoid code duplication and to take +advantage of the SDK architectural components such as the transaction routing +through `Handlers`. + +### Interchain Standards reference + +The following list is a mapping from each Interchain Standard to their implementation +in the SDK's `x/ibc` module: + +* [ICS 002 - Client Semantics](https://github.com/cosmos/ics/tree/master/spec/ics-002-client-semantics): Implemented in [`x/ibc/core/02-client`](https://github.com/cosmos/tree/master/ibc/core/02-client) +* [ICS 003 - Connection Semantics](https://github.com/cosmos/ics/blob/master/spec/ics-003-connection-semantics): Implemented in [`x/ibc/core/03-connection`](https://github.com/cosmos/tree/master/ibc/core/03-connection) +* [ICS 004 - Channel and Packet Semantics](https://github.com/cosmos/ics/blob/master/spec/ics-004-channel-and-packet-semantics): Implemented in [`x/ibc/core/04-channel`](https://github.com/cosmos/tree/master/ibc/core/04-channel) +* [ICS 005 - Port Allocation](https://github.com/cosmos/ics/blob/master/spec/ics-005-port-allocation): Implemented in [`x/ibc/core/05-port`](https://github.com/cosmos/tree/master/ibc/core/05-port) +* [ICS 006 - Solo Machine Client](https://github.com/cosmos/ics/blob/master/spec/ics-006-solo-machine-client): Implemented in [`x/ibc/light-clients/06-solomachine`](https://github.com/cosmos/tree/master/ibc/solomachine) +* [ICS 007 - Tendermint Client](https://github.com/cosmos/ics/blob/master/spec/ics-007-tendermint-client): Implemented in [`x/ibc/light-clients/07-tendermint`](https://github.com/cosmos/tree/master/ibc/light-clients/07-tendermint) +* [ICS 009 - Loopback Client](https://github.com/cosmos/ics/blob/master/spec/ics-009-loopback-client): Implemented in [`x/ibc/light-clients/09-localhost`](https://github.com/cosmos/tree/master/ibc/light-clients/09-localhost) +* [ICS 018- Relayer Algorithms](https://github.com/cosmos/ics/tree/master/spec/ics-018-relayer-algorithms): Implemented in it's own [relayer repository](https://github.com/cosmos/relayer) +* [ICS 020 - Fungible Token Transfer](https://github.com/cosmos/ics/tree/master/spec/ics-020-fungible-token-transfer): Implemented in [`x/ibc/applications/transfer`](https://github.com/cosmos/tree/master/ibc/applications/transfer) +* [ICS 023 - Vector Commitments](https://github.com/cosmos/ics/tree/master/spec/ics-023-vector-commitments): Implemented in [`x/ibc/core/23-commitment`](https://github.com/cosmos/tree/master/ibc/core/23-commitment) +* [ICS 024 - Host Requirements](https://github.com/cosmos/ics/tree/master/spec/ics-024-host-requirements): Implemented in [`x/ibc/core/24-host`](https://github.com/cosmos/tree/master/ibc/core/24-host) +* [ICS 025 - Handler Interface](https://github.com/cosmos/ics/tree/master/spec/ics-025-handler-interface): `Handler` interfaces are implemented at the top level in `x/ibc/handler.go`, +which call each ICS submodule's handlers (i.e `x/ibc/*/{XX-ICS}/handler.go`). +* [ICS 026 - Routing Module](https://github.com/cosmos/ics/blob/master/spec/ics-026-routing-module): Replaced by [ADR 15 - IBC Packet Receiver](../../../docs/architecture/adr-015-ibc-packet-receiver.md). + +### Architecture Decision Records (ADR) + +The following ADR provide the design and architecture decision of IBC-related components. + +* [ADR 001 - Coin Source Tracing](../../../docs/architecture/adr-001-coin-source-tracing.md): standard to hash the ICS20's fungible token +denomination trace path in order to support special characters and limit the maximum denomination length. +* [ADR 17 - Historical Header Module](../../../docs/architecture/adr-017-historical-header-module.md): Introduces the ability to introspect past +consensus states in order to verify their membership in the counterparty clients. +* [ADR 19 - Protobuf State Encoding](../../../docs/architecture/adr-019-protobuf-state-encoding.md): Migration from Amino to Protobuf for state encoding. +* [ADR 020 - Protocol Buffer Transaction Encoding](./../../docs/architecture/adr-020-protobuf-transaction-encoding.md): Client side migration to Protobuf. +* [ADR 021 - Protocol Buffer Query Encoding](../../../docs/architecture/adr-020-protobuf-query-encoding.md): Queries migration to Protobuf. +* [ADR 026 - IBC Client Recovery Mechanisms](../../../docs/architecture/adr-026-ibc-client-recovery-mechanisms.md): Allows IBC Clients to be recovered after freezing or expiry. + +### SDK Modules + +* [`x/capability`](https://github.com/cosmos/tree/master/x/capability): The capability module provides object-capability keys support through scoped keepers in order to authenticate usage of ports or channels. Check [ADR 3 - Dynamic Capability Store](../../../docs/architecture/adr-003-dynamic-capability-store.md) for more details. + +## IBC module architecture + +> **NOTE for auditors**: If you're not familiar with the overall module structure from +the SDK modules, please check this [document](../../../docs/building-modules/structure.md) as +prerequisite reading. + +For ease of auditing, every Interchain Standard has been developed in its own +package. The development team separated the IBC TAO (Transport, Authentication, Ordering) ICS specifications from the IBC application level +specification. The following tree describes the architecture of the directories that +the `ibc` (TAO) and `ibc-transfer` ([ICS20](https://github.com/cosmos/ics/tree/master/spec/ics-020-fungible-token-transfer)) modules: + +```shell +x/ibc +├── applications/ +│ └──transfer/ +├── core/ +│   ├── 02-client/ +│   ├── 03-connection/ +│   ├── 04-channel/ +│   ├── 05-port/ +│   ├── 23-commitment/ +│   ├── 24-host/ +│  ├── client +│  │   └── cli +│ │       └── cli.go +│  ├── keeper +│  │ ├── keeper.go +│   │ └── querier.go +│ ├── types +│ │ ├── errors.go +│ │ └── keys.go +│ ├── handler.go +│ └── module.go +├── light-clients/ +│   ├── 06-solomachine/ +│   ├── 07-tendermint/ +│   └── 09-localhost/ +└── testing/ +``` From e172a0833351102d53a94c9dcf4747aec64b8dc1 Mon Sep 17 00:00:00 2001 From: Alessio Treglia Date: Mon, 9 Nov 2020 15:17:36 +0000 Subject: [PATCH 11/24] enrich versioning with build deps (#7848) `version --long` output now shows the list of build dependencies. Redirect version's output to `stdout`. --- go.sum | 2 -- version/command.go | 1 + version/version.go | 37 +++++++++++++++++++++++++++++++------ version/version_test.go | 16 ++++++++-------- 4 files changed, 40 insertions(+), 16 deletions(-) diff --git a/go.sum b/go.sum index 6b5e5ed52..8090e2d10 100644 --- a/go.sum +++ b/go.sum @@ -595,8 +595,6 @@ github.com/tendermint/crypto v0.0.0-20191022145703-50d29ede1e15/go.mod h1:z4YtwM github.com/tendermint/go-amino v0.16.0 h1:GyhmgQKvqF82e2oZeuMSp9JTN0N09emoSZlb2lyGa2E= github.com/tendermint/go-amino v0.16.0/go.mod h1:TQU0M1i/ImAo+tYpZi73AU3V/dKeCoMC9Sphe2ZwGME= github.com/tendermint/tendermint v0.34.0-rc4/go.mod h1:yotsojf2C1QBOw4dZrTcxbyxmPUrT4hNuOQWX9XUwB4= -github.com/tendermint/tendermint v0.34.0-rc5 h1:2bnQfWyOMfTCbol5pwB8CgM2nxi6/Kz6zqlS6Udm/Cg= -github.com/tendermint/tendermint v0.34.0-rc5/go.mod h1:yotsojf2C1QBOw4dZrTcxbyxmPUrT4hNuOQWX9XUwB4= github.com/tendermint/tendermint v0.34.0-rc6 h1:SVuKGvvE22KxfuK8QUHctUrmOWJsncZSYXIYtcnoKN0= github.com/tendermint/tendermint v0.34.0-rc6/go.mod h1:ugzyZO5foutZImv0Iyx/gOFCX6mjJTgbLHTwi17VDVg= github.com/tendermint/tm-db v0.6.2 h1:DOn8jwCdjJblrCFJbtonEIPD1IuJWpbRUUdR8GWE4RM= diff --git a/version/command.go b/version/command.go index 9291c0a82..bb632aea5 100644 --- a/version/command.go +++ b/version/command.go @@ -17,6 +17,7 @@ func NewVersionCommand() *cobra.Command { Short: "Print the application binary version information", RunE: func(cmd *cobra.Command, _ []string) error { verInfo := NewInfo() + cmd.SetOut(cmd.OutOrStdout()) if long, _ := cmd.Flags().GetBool(flagLong); !long { cmd.Println(verInfo.Version) diff --git a/version/version.go b/version/version.go index 1e40d483d..25995932f 100644 --- a/version/version.go +++ b/version/version.go @@ -17,8 +17,10 @@ package version import ( + "encoding/json" "fmt" "runtime" + "runtime/debug" ) var ( @@ -36,12 +38,13 @@ var ( // Info defines the application version information. type Info struct { - Name string `json:"name" yaml:"name"` - AppName string `json:"server_name" yaml:"server_name"` - Version string `json:"version" yaml:"version"` - GitCommit string `json:"commit" yaml:"commit"` - BuildTags string `json:"build_tags" yaml:"build_tags"` - GoVersion string `json:"go" yaml:"go"` + Name string `json:"name" yaml:"name"` + AppName string `json:"server_name" yaml:"server_name"` + Version string `json:"version" yaml:"version"` + GitCommit string `json:"commit" yaml:"commit"` + BuildTags string `json:"build_tags" yaml:"build_tags"` + GoVersion string `json:"go" yaml:"go"` + BuildDeps []buildDep `json:"build_deps" yaml:"build_deps"` } func NewInfo() Info { @@ -52,6 +55,7 @@ func NewInfo() Info { GitCommit: Commit, BuildTags: BuildTags, GoVersion: fmt.Sprintf("go version %s %s/%s", runtime.Version(), runtime.GOOS, runtime.GOARCH), + BuildDeps: depsFromBuildInfo(), } } @@ -63,3 +67,24 @@ build tags: %s vi.Name, vi.Version, vi.GitCommit, vi.BuildTags, vi.GoVersion, ) } + +func depsFromBuildInfo() (deps []buildDep) { + buildInfo, ok := debug.ReadBuildInfo() + if !ok { + return nil + } + + for _, dep := range buildInfo.Deps { + deps = append(deps, buildDep{dep}) + } + + return +} + +type buildDep struct { + *debug.Module +} + +func (d buildDep) String() string { return fmt.Sprintf("%s@%s", d.Path, d.Version) } +func (d buildDep) MarshalJSON() ([]byte, error) { return json.Marshal(d.String()) } +func (d buildDep) MarshalYAML() (interface{}, error) { return d.String(), nil } diff --git a/version/version_test.go b/version/version_test.go index ef44f8d31..87608cfdb 100644 --- a/version/version_test.go +++ b/version/version_test.go @@ -1,4 +1,4 @@ -package version +package version_test import ( "encoding/json" @@ -11,10 +11,11 @@ import ( "github.com/tendermint/tendermint/libs/cli" "github.com/cosmos/cosmos-sdk/testutil" + "github.com/cosmos/cosmos-sdk/version" ) func TestNewInfo(t *testing.T) { - info := NewInfo() + info := version.NewInfo() want := fmt.Sprintf(`: git commit: build tags: @@ -23,7 +24,7 @@ build tags: } func TestInfo_String(t *testing.T) { - info := Info{ + info := version.Info{ Name: "testapp", AppName: "testappd", Version: "1.0.0", @@ -39,12 +40,12 @@ go version go1.14 linux/amd64` } func Test_runVersionCmd(t *testing.T) { - cmd := NewVersionCommand() + cmd := version.NewVersionCommand() _, mockOut := testutil.ApplyMockIO(cmd) cmd.SetArgs([]string{ fmt.Sprintf("--%s=''", cli.OutputFlag), - fmt.Sprintf("--%s=false", flagLong), + "--long=false", }) require.NoError(t, cmd.Execute()) @@ -52,11 +53,10 @@ func Test_runVersionCmd(t *testing.T) { mockOut.Reset() cmd.SetArgs([]string{ - fmt.Sprintf("--%s=json", cli.OutputFlag), - fmt.Sprintf("--%s=true", flagLong), + fmt.Sprintf("--%s=json", cli.OutputFlag), "--long=true", }) - info := NewInfo() + info := version.NewInfo() stringInfo, err := json.Marshal(info) require.NoError(t, err) require.NoError(t, cmd.Execute()) From 90e9370bd80d9a3d41f7203ddb71166865561569 Mon Sep 17 00:00:00 2001 From: Marie Gauthier Date: Mon, 9 Nov 2020 17:01:43 +0100 Subject: [PATCH 12/24] Replace tmcrypto.PubKey by our own cryptotypes.PubKey (#7419) * WIP on removing tm pub/privkey * Fix part of crypto tests * Add PrivKeyLedgerSecp256K1 proto type * Use BasePrivKey for ledger priv key type * Refacto continued * First round * x/staking * Continue porting * x/* done * Make build pass * More conversion * Remove IntoTmPubKey * Fix test * Remove crypto.PubKey in some other places * Revert ledger changes * Fix comment * Remove useless function * Add To/FromTmPublicKey * Add migrate tests * Fix test * Fix another test * Rename tm conversion functions * Less code * Rename BasePrivKey to LedgerPrivKey * Add changelog * Rename functions Co-authored-by: Amaury Martiny Co-authored-by: Alessio Treglia --- CHANGELOG.md | 4 + client/account_retriever.go | 5 +- client/debug/main.go | 4 +- client/keys/add.go | 6 +- client/keys/show.go | 4 +- client/keys/show_test.go | 5 +- client/rpc/validators.go | 7 +- client/test_helpers.go | 5 +- client/tx/tx.go | 4 +- crypto/armor.go | 9 +- crypto/armor_test.go | 3 +- crypto/codec/amino.go | 18 +-- crypto/codec/proto.go | 10 -- crypto/codec/tm.go | 57 +++++++ crypto/hd/algo.go | 8 +- crypto/keyring/info.go | 49 +++--- crypto/keyring/keyring.go | 33 +++-- crypto/keyring/keyring_test.go | 10 +- crypto/keyring/legacy.go | 6 +- crypto/keyring/output_test.go | 4 +- crypto/keyring/types.go | 5 +- crypto/keys/ed25519/ed25519.go | 28 +--- crypto/keys/ed25519/ed25519_test.go | 10 +- crypto/keys/internal/benchmarking/bench.go | 8 +- crypto/keys/multisig/codec.go | 5 - crypto/keys/multisig/multisig.go | 26 ++-- crypto/keys/multisig/multisig_test.go | 31 ++-- crypto/keys/secp256k1/bench_test.go | 5 +- crypto/keys/secp256k1/secp256k1.go | 6 +- crypto/keys/secp256k1/secp256k1_test.go | 10 +- crypto/ledger/encode_test.go | 6 +- crypto/ledger/ledger_secp256k1.go | 18 +-- crypto/ledger/ledger_test.go | 11 +- crypto/types/multisig/multisignature.go | 8 +- crypto/types/multisig/pubkey.go | 9 +- crypto/types/types.go | 37 +++-- server/tm_cmds.go | 10 +- simapp/helpers/test_helpers.go | 5 +- simapp/simd/cmd/testnet.go | 6 +- simapp/test_helpers.go | 20 ++- tests/mocks/account_retriever.go | 6 +- testutil/network/network.go | 6 +- testutil/testdata/tx.go | 5 +- types/address.go | 57 ++----- types/address_test.go | 4 +- types/rest/rest_test.go | 14 +- types/simulation/account.go | 9 +- types/tx/signing/signature.go | 7 +- types/tx/types.go | 5 +- types/tx_msg.go | 5 +- x/auth/ante/ante_test.go | 104 ++++++------- x/auth/ante/basic.go | 5 +- x/auth/ante/basic_test.go | 18 +-- x/auth/ante/fee_test.go | 7 +- x/auth/ante/setup_test.go | 8 +- x/auth/ante/sigverify.go | 5 +- x/auth/ante/sigverify_test.go | 47 +++--- x/auth/ante/testutil_test.go | 8 +- x/auth/client/cli/cli_test.go | 6 +- x/auth/keeper/keeper.go | 6 +- x/auth/legacy/legacytx/stdsign.go | 9 +- x/auth/legacy/legacytx/stdtx.go | 12 +- x/auth/legacy/legacytx/stdtx_test.go | 12 +- x/auth/legacy/v038/types.go | 27 ++-- x/auth/legacy/v039/migrate_test.go | 104 +++++++++++++ x/auth/legacy/v039/types.go | 37 ++--- x/auth/signing/sig_verifiable_tx.go | 5 +- x/auth/signing/verify.go | 5 +- x/auth/signing/verify_test.go | 4 +- x/auth/testutil/suite.go | 8 +- x/auth/tx/builder.go | 21 +-- x/auth/tx/sigs.go | 10 +- x/auth/types/account.go | 17 ++- x/auth/vesting/types/test_common.go | 5 +- x/bank/app_test.go | 18 +-- x/bank/simulation/operations.go | 11 +- x/distribution/types/common_test.go | 5 +- x/evidence/keeper/keeper_test.go | 6 +- x/evidence/types/expected_keepers.go | 5 +- x/genutil/legacy/v038/migrate.go | 3 - x/genutil/legacy/v039/migrate.go | 3 - x/genutil/types/types.go | 7 +- x/genutil/utils.go | 8 +- x/gov/common_test.go | 4 +- x/gov/keeper/tally_test.go | 4 +- x/ibc/core/02-client/keeper/client_test.go | 3 +- x/ibc/core/02-client/keeper/keeper_test.go | 8 +- x/ibc/core/02-client/types/genesis_test.go | 3 +- .../06-solomachine/types/consensus_state.go | 11 +- .../06-solomachine/types/header.go | 11 +- .../06-solomachine/types/proof.go | 5 +- .../06-solomachine/types/solomachine.go | 9 +- .../types/misbehaviour_handle_test.go | 3 +- .../07-tendermint/types/misbehaviour_test.go | 3 +- .../07-tendermint/types/tendermint_test.go | 3 +- .../07-tendermint/types/update_test.go | 3 +- x/ibc/testing/chain.go | 8 +- x/ibc/testing/chain_test.go | 5 +- x/ibc/testing/mock/privval.go | 6 +- x/ibc/testing/solomachine.go | 16 +- x/slashing/genesis.go | 2 +- x/slashing/keeper/hooks.go | 3 +- x/slashing/keeper/infractions.go | 5 +- x/slashing/keeper/keeper.go | 10 +- x/slashing/simulation/operations.go | 3 +- x/staking/client/cli/tx.go | 4 +- x/staking/genesis.go | 16 +- x/staking/handler_test.go | 14 +- x/staking/keeper/msg_server.go | 2 +- x/staking/keeper/validator_test.go | 4 +- x/staking/legacy/v034/types.go | 26 ++-- x/staking/legacy/v036/migrate_test.go | 103 +++++++++++++ x/staking/legacy/v036/types.go | 5 +- x/staking/legacy/v038/types.go | 5 +- x/staking/teststaking/helper.go | 10 +- x/staking/teststaking/tm.go | 43 ++++++ x/staking/teststaking/validator.go | 4 +- x/staking/types/commission_test.go | 23 +-- x/staking/types/data_test.go | 7 +- x/staking/types/delegation_test.go | 39 ++--- x/staking/types/exported.go | 7 +- x/staking/types/historical_info_test.go | 31 ++-- x/staking/types/keys.go | 16 +- x/staking/types/keys_test.go | 23 +-- x/staking/types/msg.go | 7 +- x/staking/types/msg_test.go | 34 ++--- x/staking/types/params_test.go | 7 +- x/staking/types/validator.go | 93 +++++------- x/staking/types/validator_test.go | 139 +++++++++--------- 129 files changed, 1079 insertions(+), 900 deletions(-) create mode 100644 crypto/codec/tm.go create mode 100644 x/auth/legacy/v039/migrate_test.go create mode 100644 x/staking/legacy/v036/migrate_test.go create mode 100644 x/staking/teststaking/tm.go diff --git a/CHANGELOG.md b/CHANGELOG.md index c10fd1385..bbe06901e 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -38,6 +38,10 @@ Ref: https://keepachangelog.com/en/1.0.0/ ## [v0.40.0-rc3](https://github.com/cosmos/cosmos-sdk/releases/tag/v0.40.0-rc3) - 2020-11-06 +### Client Breaking + +* (x/staking) [\#7419](https://github.com/cosmos/cosmos-sdk/pull/7419) The `TmConsPubKey` method on ValidatorI has been removed and replaced instead by `ConsPubKey` (which returns a SDK `cryptotypes.PubKey`) and `TmConsPublicKey` (which returns a Tendermint proto PublicKey). + ### Improvements * (tendermint) [\#7828](https://github.com/cosmos/cosmos-sdk/pull/7828) Update tendermint dependency to v0.34.0-rc6 diff --git a/client/account_retriever.go b/client/account_retriever.go index 51c0a7fa9..8e2fd14c1 100644 --- a/client/account_retriever.go +++ b/client/account_retriever.go @@ -1,15 +1,14 @@ package client import ( - "github.com/tendermint/tendermint/crypto" - + cryptotypes "github.com/cosmos/cosmos-sdk/crypto/types" sdk "github.com/cosmos/cosmos-sdk/types" ) // Account defines a read-only version of the auth module's AccountI. type Account interface { GetAddress() sdk.AccAddress - GetPubKey() crypto.PubKey // can return nil. + GetPubKey() cryptotypes.PubKey // can return nil. GetAccountNumber() uint64 GetSequence() uint64 } diff --git a/client/debug/main.go b/client/debug/main.go index ab9ec0cf8..54b75e712 100644 --- a/client/debug/main.go +++ b/client/debug/main.go @@ -8,10 +8,10 @@ import ( "strings" "github.com/spf13/cobra" - "github.com/tendermint/tendermint/crypto" "github.com/cosmos/cosmos-sdk/client" "github.com/cosmos/cosmos-sdk/crypto/keys/ed25519" + cryptotypes "github.com/cosmos/cosmos-sdk/crypto/types" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cosmos/cosmos-sdk/types/errors" "github.com/cosmos/cosmos-sdk/version" @@ -34,7 +34,7 @@ func Cmd() *cobra.Command { // getPubKeyFromString returns a Tendermint PubKey (PubKeyEd25519) by attempting // to decode the pubkey string from hex, base64, and finally bech32. If all // encodings fail, an error is returned. -func getPubKeyFromString(pkstr string) (crypto.PubKey, error) { +func getPubKeyFromString(pkstr string) (cryptotypes.PubKey, error) { bz, err := hex.DecodeString(pkstr) if err == nil { if len(bz) == ed25519.PubKeySize { diff --git a/client/keys/add.go b/client/keys/add.go index b2e267e83..c91f639c4 100644 --- a/client/keys/add.go +++ b/client/keys/add.go @@ -9,7 +9,6 @@ import ( bip39 "github.com/cosmos/go-bip39" "github.com/spf13/cobra" - "github.com/tendermint/tendermint/crypto" "github.com/tendermint/tendermint/libs/cli" "github.com/cosmos/cosmos-sdk/client" @@ -18,6 +17,7 @@ import ( "github.com/cosmos/cosmos-sdk/crypto/hd" "github.com/cosmos/cosmos-sdk/crypto/keyring" "github.com/cosmos/cosmos-sdk/crypto/keys/multisig" + cryptotypes "github.com/cosmos/cosmos-sdk/crypto/types" sdk "github.com/cosmos/cosmos-sdk/types" ) @@ -152,7 +152,7 @@ func RunAddCmd(cmd *cobra.Command, args []string, kb keyring.Keyring, inBuf *buf multisigKeys, _ := cmd.Flags().GetStringSlice(flagMultisig) if len(multisigKeys) != 0 { - var pks []crypto.PubKey + var pks []cryptotypes.PubKey multisigThreshold, _ := cmd.Flags().GetInt(flagMultiSigThreshold) if err := validateMultisigThreshold(multisigThreshold, len(multisigKeys)); err != nil { @@ -247,7 +247,7 @@ func RunAddCmd(cmd *cobra.Command, args []string, kb keyring.Keyring, inBuf *buf } if len(mnemonic) == 0 { - // read entropy seed straight from crypto.Rand and convert to mnemonic + // read entropy seed straight from tmcrypto.Rand and convert to mnemonic entropySeed, err := bip39.NewEntropy(mnemonicEntropySize) if err != nil { return err diff --git a/client/keys/show.go b/client/keys/show.go index 102f29793..2cb3c457f 100644 --- a/client/keys/show.go +++ b/client/keys/show.go @@ -5,13 +5,13 @@ import ( "fmt" "github.com/spf13/cobra" - tmcrypto "github.com/tendermint/tendermint/crypto" "github.com/tendermint/tendermint/libs/cli" "github.com/cosmos/cosmos-sdk/client" "github.com/cosmos/cosmos-sdk/crypto/keyring" "github.com/cosmos/cosmos-sdk/crypto/keys/multisig" "github.com/cosmos/cosmos-sdk/crypto/ledger" + cryptotypes "github.com/cosmos/cosmos-sdk/crypto/types" sdk "github.com/cosmos/cosmos-sdk/types" ) @@ -61,7 +61,7 @@ func runShowCmd(cmd *cobra.Command, args []string) (err error) { return fmt.Errorf("%s is not a valid name or address: %v", args[0], err) } } else { - pks := make([]tmcrypto.PubKey, len(args)) + pks := make([]cryptotypes.PubKey, len(args)) for i, keyref := range args { info, err := fetchKey(clientCtx.Keyring, keyref) if err != nil { diff --git a/client/keys/show_test.go b/client/keys/show_test.go index e68107b58..882a80683 100644 --- a/client/keys/show_test.go +++ b/client/keys/show_test.go @@ -7,14 +7,13 @@ import ( "github.com/stretchr/testify/require" - "github.com/tendermint/tendermint/crypto" - "github.com/cosmos/cosmos-sdk/client" "github.com/cosmos/cosmos-sdk/client/flags" "github.com/cosmos/cosmos-sdk/crypto/hd" "github.com/cosmos/cosmos-sdk/crypto/keyring" "github.com/cosmos/cosmos-sdk/crypto/keys/multisig" "github.com/cosmos/cosmos-sdk/crypto/keys/secp256k1" + cryptotypes "github.com/cosmos/cosmos-sdk/crypto/types" "github.com/cosmos/cosmos-sdk/testutil" sdk "github.com/cosmos/cosmos-sdk/types" ) @@ -23,7 +22,7 @@ func Test_multiSigKey_Properties(t *testing.T) { tmpKey1 := secp256k1.GenPrivKeyFromSecret([]byte("mySecret")) pk := multisig.NewLegacyAminoPubKey( 1, - []crypto.PubKey{tmpKey1.PubKey()}, + []cryptotypes.PubKey{tmpKey1.PubKey()}, ) tmp := keyring.NewMultiInfo("myMultisig", pk) diff --git a/client/rpc/validators.go b/client/rpc/validators.go index 591d3354c..0a15f4bc9 100644 --- a/client/rpc/validators.go +++ b/client/rpc/validators.go @@ -14,6 +14,7 @@ import ( "github.com/cosmos/cosmos-sdk/client" "github.com/cosmos/cosmos-sdk/client/flags" + cryptocodec "github.com/cosmos/cosmos-sdk/crypto/codec" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cosmos/cosmos-sdk/types/rest" ) @@ -99,7 +100,11 @@ func (rvo ResultValidatorsOutput) String() string { } func bech32ValidatorOutput(validator *tmtypes.Validator) (ValidatorOutput, error) { - bechValPubkey, err := sdk.Bech32ifyPubKey(sdk.Bech32PubKeyTypeConsPub, validator.PubKey) + pk, err := cryptocodec.FromTmPubKeyInterface(validator.PubKey) + if err != nil { + return ValidatorOutput{}, err + } + bechValPubkey, err := sdk.Bech32ifyPubKey(sdk.Bech32PubKeyTypeConsPub, pk) if err != nil { return ValidatorOutput{}, err } diff --git a/client/test_helpers.go b/client/test_helpers.go index 1140298fd..214184b50 100644 --- a/client/test_helpers.go +++ b/client/test_helpers.go @@ -3,8 +3,7 @@ package client import ( "fmt" - "github.com/tendermint/tendermint/crypto" - + cryptotypes "github.com/cosmos/cosmos-sdk/crypto/types" sdk "github.com/cosmos/cosmos-sdk/types" ) @@ -26,7 +25,7 @@ func (t TestAccount) GetAddress() sdk.AccAddress { } // GetPubKey implements client Account.GetPubKey -func (t TestAccount) GetPubKey() crypto.PubKey { +func (t TestAccount) GetPubKey() cryptotypes.PubKey { return nil } diff --git a/client/tx/tx.go b/client/tx/tx.go index fb0e71280..d1814c363 100644 --- a/client/tx/tx.go +++ b/client/tx/tx.go @@ -8,13 +8,13 @@ import ( "os" "github.com/spf13/pflag" - "github.com/tendermint/tendermint/crypto" "github.com/cosmos/cosmos-sdk/client" "github.com/cosmos/cosmos-sdk/client/flags" "github.com/cosmos/cosmos-sdk/client/input" codectypes "github.com/cosmos/cosmos-sdk/codec/types" "github.com/cosmos/cosmos-sdk/crypto/keys/secp256k1" + cryptotypes "github.com/cosmos/cosmos-sdk/crypto/types" sdk "github.com/cosmos/cosmos-sdk/types" sdkerrors "github.com/cosmos/cosmos-sdk/types/errors" "github.com/cosmos/cosmos-sdk/types/rest" @@ -343,7 +343,7 @@ func PrepareFactory(clientCtx client.Context, txf Factory) (Factory, error) { // corresponding SignatureV2 if the signing is successful. func SignWithPrivKey( signMode signing.SignMode, signerData authsigning.SignerData, - txBuilder client.TxBuilder, priv crypto.PrivKey, txConfig client.TxConfig, + txBuilder client.TxBuilder, priv cryptotypes.PrivKey, txConfig client.TxConfig, accSeq uint64, ) (signing.SignatureV2, error) { var sigV2 signing.SignatureV2 diff --git a/crypto/armor.go b/crypto/armor.go index d0637c709..3ee472707 100644 --- a/crypto/armor.go +++ b/crypto/armor.go @@ -11,6 +11,7 @@ import ( "github.com/cosmos/cosmos-sdk/codec/legacy" cryptoAmino "github.com/cosmos/cosmos-sdk/crypto/codec" + cryptotypes "github.com/cosmos/cosmos-sdk/crypto/types" sdkerrors "github.com/cosmos/cosmos-sdk/types/errors" ) @@ -124,7 +125,7 @@ func unarmorBytes(armorStr, blockType string) (bz []byte, header map[string]stri // encrypt/decrypt with armor // Encrypt and armor the private key. -func EncryptArmorPrivKey(privKey crypto.PrivKey, passphrase string, algo string) string { +func EncryptArmorPrivKey(privKey cryptotypes.PrivKey, passphrase string, algo string) string { saltBytes, encBytes := encryptPrivKey(privKey, passphrase) header := map[string]string{ "kdf": "bcrypt", @@ -143,7 +144,7 @@ func EncryptArmorPrivKey(privKey crypto.PrivKey, passphrase string, algo string) // encrypt the given privKey with the passphrase using a randomly // generated salt and the xsalsa20 cipher. returns the salt and the // encrypted priv key. -func encryptPrivKey(privKey crypto.PrivKey, passphrase string) (saltBytes []byte, encBytes []byte) { +func encryptPrivKey(privKey cryptotypes.PrivKey, passphrase string) (saltBytes []byte, encBytes []byte) { saltBytes = crypto.CRandBytes(16) key, err := bcrypt.GenerateFromPassword(saltBytes, []byte(passphrase), BcryptSecurityParameter) @@ -158,7 +159,7 @@ func encryptPrivKey(privKey crypto.PrivKey, passphrase string) (saltBytes []byte } // UnarmorDecryptPrivKey returns the privkey byte slice, a string of the algo type, and an error -func UnarmorDecryptPrivKey(armorStr string, passphrase string) (privKey crypto.PrivKey, algo string, err error) { +func UnarmorDecryptPrivKey(armorStr string, passphrase string) (privKey cryptotypes.PrivKey, algo string, err error) { blockType, header, encBytes, err := armor.DecodeArmor(armorStr) if err != nil { return privKey, "", err @@ -190,7 +191,7 @@ func UnarmorDecryptPrivKey(armorStr string, passphrase string) (privKey crypto.P return privKey, header[headerType], err } -func decryptPrivKey(saltBytes []byte, encBytes []byte, passphrase string) (privKey crypto.PrivKey, err error) { +func decryptPrivKey(saltBytes []byte, encBytes []byte, passphrase string) (privKey cryptotypes.PrivKey, err error) { key, err := bcrypt.GenerateFromPassword(saltBytes, []byte(passphrase), BcryptSecurityParameter) if err != nil { return privKey, sdkerrors.Wrap(err, "error generating bcrypt key from passphrase") diff --git a/crypto/armor_test.go b/crypto/armor_test.go index 3e5f256fa..3267ca98a 100644 --- a/crypto/armor_test.go +++ b/crypto/armor_test.go @@ -19,6 +19,7 @@ import ( "github.com/cosmos/cosmos-sdk/crypto/hd" "github.com/cosmos/cosmos-sdk/crypto/keyring" "github.com/cosmos/cosmos-sdk/crypto/keys/secp256k1" + cryptotypes "github.com/cosmos/cosmos-sdk/crypto/types" "github.com/cosmos/cosmos-sdk/types" ) @@ -46,7 +47,7 @@ func TestArmorUnarmorPrivKey(t *testing.T) { require.Contains(t, err.Error(), "unrecognized armor type") // armor key manually - encryptPrivKeyFn := func(privKey tmcrypto.PrivKey, passphrase string) (saltBytes []byte, encBytes []byte) { + encryptPrivKeyFn := func(privKey cryptotypes.PrivKey, passphrase string) (saltBytes []byte, encBytes []byte) { saltBytes = tmcrypto.CRandBytes(16) key, err := bcrypt.GenerateFromPassword(saltBytes, []byte(passphrase), crypto.BcryptSecurityParameter) require.NoError(t, err) diff --git a/crypto/codec/amino.go b/crypto/codec/amino.go index 5a98acbac..5cd61c3dd 100644 --- a/crypto/codec/amino.go +++ b/crypto/codec/amino.go @@ -1,8 +1,6 @@ package codec import ( - "github.com/tendermint/tendermint/crypto" - tmed25519 "github.com/tendermint/tendermint/crypto/ed25519" "github.com/tendermint/tendermint/crypto/sr25519" "github.com/cosmos/cosmos-sdk/codec" @@ -22,16 +20,9 @@ func init() { // RegisterCrypto registers all crypto dependency types with the provided Amino // codec. func RegisterCrypto(cdc *codec.LegacyAmino) { - // TODO We now register both Tendermint's PubKey and our own PubKey. In the - // long-term, we should move away from Tendermint's PubKey, and delete this - // first line. - cdc.RegisterInterface((*crypto.PubKey)(nil), nil) cdc.RegisterInterface((*cryptotypes.PubKey)(nil), nil) cdc.RegisterConcrete(sr25519.PubKey{}, sr25519.PubKeyName, nil) - // TODO Same as above, for ED25519 - cdc.RegisterConcrete(tmed25519.PubKey{}, - tmed25519.PubKeyName, nil) cdc.RegisterConcrete(&ed25519.PubKey{}, ed25519.PubKeyName, nil) cdc.RegisterConcrete(&secp256k1.PubKey{}, @@ -39,12 +30,9 @@ func RegisterCrypto(cdc *codec.LegacyAmino) { cdc.RegisterConcrete(&kmultisig.LegacyAminoPubKey{}, kmultisig.PubKeyAminoRoute, nil) - cdc.RegisterInterface((*crypto.PrivKey)(nil), nil) + cdc.RegisterInterface((*cryptotypes.PrivKey)(nil), nil) cdc.RegisterConcrete(sr25519.PrivKey{}, sr25519.PrivKeyName, nil) - // TODO Same as above - cdc.RegisterConcrete(tmed25519.PrivKey{}, - tmed25519.PrivKeyName, nil) cdc.RegisterConcrete(&ed25519.PrivKey{}, ed25519.PrivKeyName, nil) cdc.RegisterConcrete(&secp256k1.PrivKey{}, @@ -52,13 +40,13 @@ func RegisterCrypto(cdc *codec.LegacyAmino) { } // PrivKeyFromBytes unmarshals private key bytes and returns a PrivKey -func PrivKeyFromBytes(privKeyBytes []byte) (privKey crypto.PrivKey, err error) { +func PrivKeyFromBytes(privKeyBytes []byte) (privKey cryptotypes.PrivKey, err error) { err = amino.UnmarshalBinaryBare(privKeyBytes, &privKey) return } // PubKeyFromBytes unmarshals public key bytes and returns a PubKey -func PubKeyFromBytes(pubKeyBytes []byte) (pubKey crypto.PubKey, err error) { +func PubKeyFromBytes(pubKeyBytes []byte) (pubKey cryptotypes.PubKey, err error) { err = amino.UnmarshalBinaryBare(pubKeyBytes, &pubKey) return } diff --git a/crypto/codec/proto.go b/crypto/codec/proto.go index 845e60bf8..9c07ca110 100644 --- a/crypto/codec/proto.go +++ b/crypto/codec/proto.go @@ -1,8 +1,6 @@ package codec import ( - tmcrypto "github.com/tendermint/tendermint/crypto" - codectypes "github.com/cosmos/cosmos-sdk/codec/types" "github.com/cosmos/cosmos-sdk/crypto/keys/ed25519" "github.com/cosmos/cosmos-sdk/crypto/keys/multisig" @@ -12,14 +10,6 @@ import ( // RegisterInterfaces registers the sdk.Tx interface. func RegisterInterfaces(registry codectypes.InterfaceRegistry) { - // TODO We now register both Tendermint's PubKey and our own PubKey. In the - // long-term, we should move away from Tendermint's PubKey, and delete - // these lines. - registry.RegisterInterface("tendermint.crypto.PubKey", (*tmcrypto.PubKey)(nil)) - registry.RegisterImplementations((*tmcrypto.PubKey)(nil), &ed25519.PubKey{}) - registry.RegisterImplementations((*tmcrypto.PubKey)(nil), &secp256k1.PubKey{}) - registry.RegisterImplementations((*tmcrypto.PubKey)(nil), &multisig.LegacyAminoPubKey{}) - registry.RegisterInterface("cosmos.crypto.PubKey", (*cryptotypes.PubKey)(nil)) registry.RegisterImplementations((*cryptotypes.PubKey)(nil), &ed25519.PubKey{}) registry.RegisterImplementations((*cryptotypes.PubKey)(nil), &secp256k1.PubKey{}) diff --git a/crypto/codec/tm.go b/crypto/codec/tm.go new file mode 100644 index 000000000..6633f60c2 --- /dev/null +++ b/crypto/codec/tm.go @@ -0,0 +1,57 @@ +package codec + +import ( + tmcrypto "github.com/tendermint/tendermint/crypto" + "github.com/tendermint/tendermint/crypto/encoding" + tmprotocrypto "github.com/tendermint/tendermint/proto/tendermint/crypto" + + "github.com/cosmos/cosmos-sdk/crypto/keys/ed25519" + cryptotypes "github.com/cosmos/cosmos-sdk/crypto/types" + sdkerrors "github.com/cosmos/cosmos-sdk/types/errors" +) + +// FromTmProtoPublicKey converts a TM's tmprotocrypto.PublicKey into our own PubKey. +func FromTmProtoPublicKey(protoPk tmprotocrypto.PublicKey) (cryptotypes.PubKey, error) { + switch protoPk := protoPk.Sum.(type) { + case *tmprotocrypto.PublicKey_Ed25519: + return &ed25519.PubKey{ + Key: protoPk.Ed25519, + }, nil + default: + return nil, sdkerrors.Wrapf(sdkerrors.ErrInvalidType, "cannot convert %v from Tendermint public key", protoPk) + } +} + +// ToTmProtoPublicKey converts our own PubKey to TM's tmprotocrypto.PublicKey. +func ToTmProtoPublicKey(pk cryptotypes.PubKey) (tmprotocrypto.PublicKey, error) { + switch pk := pk.(type) { + case *ed25519.PubKey: + return tmprotocrypto.PublicKey{ + Sum: &tmprotocrypto.PublicKey_Ed25519{ + Ed25519: pk.Key, + }, + }, nil + default: + return tmprotocrypto.PublicKey{}, sdkerrors.Wrapf(sdkerrors.ErrInvalidType, "cannot convert %v to Tendermint public key", pk) + } +} + +// FromTmPubKeyInterface converts TM's tmcrypto.PubKey to our own PubKey. +func FromTmPubKeyInterface(tmPk tmcrypto.PubKey) (cryptotypes.PubKey, error) { + tmProtoPk, err := encoding.PubKeyToProto(tmPk) + if err != nil { + return nil, err + } + + return FromTmProtoPublicKey(tmProtoPk) +} + +// ToTmPubKeyInterface converts our own PubKey to TM's tmcrypto.PubKey. +func ToTmPubKeyInterface(pk cryptotypes.PubKey) (tmcrypto.PubKey, error) { + tmProtoPk, err := ToTmProtoPublicKey(pk) + if err != nil { + return nil, err + } + + return encoding.PubKeyFromProto(tmProtoPk) +} diff --git a/crypto/hd/algo.go b/crypto/hd/algo.go index 30636c56d..f934ad08a 100644 --- a/crypto/hd/algo.go +++ b/crypto/hd/algo.go @@ -2,9 +2,9 @@ package hd import ( bip39 "github.com/cosmos/go-bip39" - "github.com/tendermint/tendermint/crypto" "github.com/cosmos/cosmos-sdk/crypto/keys/secp256k1" + "github.com/cosmos/cosmos-sdk/crypto/types" ) // PubKeyType defines an algorithm to derive key-pairs which can be used for cryptographic signing. @@ -28,11 +28,11 @@ var ( ) type DeriveFn func(mnemonic string, bip39Passphrase, hdPath string) ([]byte, error) -type GenerateFn func(bz []byte) crypto.PrivKey +type GenerateFn func(bz []byte) types.PrivKey type WalletGenerator interface { Derive(mnemonic string, bip39Passphrase, hdPath string) ([]byte, error) - Generate(bz []byte) crypto.PrivKey + Generate(bz []byte) types.PrivKey } type secp256k1Algo struct { @@ -62,7 +62,7 @@ func (s secp256k1Algo) Derive() DeriveFn { // Generate generates a secp256k1 private key from the given bytes. func (s secp256k1Algo) Generate() GenerateFn { - return func(bz []byte) crypto.PrivKey { + return func(bz []byte) types.PrivKey { var bzArr = make([]byte, secp256k1.PrivKeySize) copy(bzArr, bz) diff --git a/crypto/keyring/info.go b/crypto/keyring/info.go index 366e474d2..f05e2f0dd 100644 --- a/crypto/keyring/info.go +++ b/crypto/keyring/info.go @@ -3,11 +3,10 @@ package keyring import ( "fmt" - "github.com/tendermint/tendermint/crypto" - codectypes "github.com/cosmos/cosmos-sdk/codec/types" "github.com/cosmos/cosmos-sdk/crypto/hd" "github.com/cosmos/cosmos-sdk/crypto/keys/multisig" + cryptotypes "github.com/cosmos/cosmos-sdk/crypto/types" "github.com/cosmos/cosmos-sdk/types" ) @@ -18,7 +17,7 @@ type Info interface { // Name of the key GetName() string // Public key - GetPubKey() crypto.PubKey + GetPubKey() cryptotypes.PubKey // Address GetAddress() types.AccAddress // Bip44 Path @@ -37,13 +36,13 @@ var ( // localInfo is the public information about a locally stored key // Note: Algo must be last field in struct for backwards amino compatibility type localInfo struct { - Name string `json:"name"` - PubKey crypto.PubKey `json:"pubkey"` - PrivKeyArmor string `json:"privkey.armor"` - Algo hd.PubKeyType `json:"algo"` + Name string `json:"name"` + PubKey cryptotypes.PubKey `json:"pubkey"` + PrivKeyArmor string `json:"privkey.armor"` + Algo hd.PubKeyType `json:"algo"` } -func newLocalInfo(name string, pub crypto.PubKey, privArmor string, algo hd.PubKeyType) Info { +func newLocalInfo(name string, pub cryptotypes.PubKey, privArmor string, algo hd.PubKeyType) Info { return &localInfo{ Name: name, PubKey: pub, @@ -63,7 +62,7 @@ func (i localInfo) GetName() string { } // GetType implements Info interface -func (i localInfo) GetPubKey() crypto.PubKey { +func (i localInfo) GetPubKey() cryptotypes.PubKey { return i.PubKey } @@ -85,13 +84,13 @@ func (i localInfo) GetPath() (*hd.BIP44Params, error) { // ledgerInfo is the public information about a Ledger key // Note: Algo must be last field in struct for backwards amino compatibility type ledgerInfo struct { - Name string `json:"name"` - PubKey crypto.PubKey `json:"pubkey"` - Path hd.BIP44Params `json:"path"` - Algo hd.PubKeyType `json:"algo"` + Name string `json:"name"` + PubKey cryptotypes.PubKey `json:"pubkey"` + Path hd.BIP44Params `json:"path"` + Algo hd.PubKeyType `json:"algo"` } -func newLedgerInfo(name string, pub crypto.PubKey, path hd.BIP44Params, algo hd.PubKeyType) Info { +func newLedgerInfo(name string, pub cryptotypes.PubKey, path hd.BIP44Params, algo hd.PubKeyType) Info { return &ledgerInfo{ Name: name, PubKey: pub, @@ -111,7 +110,7 @@ func (i ledgerInfo) GetName() string { } // GetPubKey implements Info interface -func (i ledgerInfo) GetPubKey() crypto.PubKey { +func (i ledgerInfo) GetPubKey() cryptotypes.PubKey { return i.PubKey } @@ -134,12 +133,12 @@ func (i ledgerInfo) GetPath() (*hd.BIP44Params, error) { // offlineInfo is the public information about an offline key // Note: Algo must be last field in struct for backwards amino compatibility type offlineInfo struct { - Name string `json:"name"` - PubKey crypto.PubKey `json:"pubkey"` - Algo hd.PubKeyType `json:"algo"` + Name string `json:"name"` + PubKey cryptotypes.PubKey `json:"pubkey"` + Algo hd.PubKeyType `json:"algo"` } -func newOfflineInfo(name string, pub crypto.PubKey, algo hd.PubKeyType) Info { +func newOfflineInfo(name string, pub cryptotypes.PubKey, algo hd.PubKeyType) Info { return &offlineInfo{ Name: name, PubKey: pub, @@ -158,7 +157,7 @@ func (i offlineInfo) GetName() string { } // GetPubKey implements Info interface -func (i offlineInfo) GetPubKey() crypto.PubKey { +func (i offlineInfo) GetPubKey() cryptotypes.PubKey { return i.PubKey } @@ -178,20 +177,20 @@ func (i offlineInfo) GetPath() (*hd.BIP44Params, error) { } type multisigPubKeyInfo struct { - PubKey crypto.PubKey `json:"pubkey"` - Weight uint `json:"weight"` + PubKey cryptotypes.PubKey `json:"pubkey"` + Weight uint `json:"weight"` } // multiInfo is the public information about a multisig key type multiInfo struct { Name string `json:"name"` - PubKey crypto.PubKey `json:"pubkey"` + PubKey cryptotypes.PubKey `json:"pubkey"` Threshold uint `json:"threshold"` PubKeys []multisigPubKeyInfo `json:"pubkeys"` } // NewMultiInfo creates a new multiInfo instance -func NewMultiInfo(name string, pub crypto.PubKey) Info { +func NewMultiInfo(name string, pub cryptotypes.PubKey) Info { multiPK := pub.(*multisig.LegacyAminoPubKey) pubKeys := make([]multisigPubKeyInfo, len(multiPK.PubKeys)) @@ -219,7 +218,7 @@ func (i multiInfo) GetName() string { } // GetPubKey implements Info interface -func (i multiInfo) GetPubKey() crypto.PubKey { +func (i multiInfo) GetPubKey() cryptotypes.PubKey { return i.PubKey } diff --git a/crypto/keyring/keyring.go b/crypto/keyring/keyring.go index 0d0e41b7c..d3220b5b4 100644 --- a/crypto/keyring/keyring.go +++ b/crypto/keyring/keyring.go @@ -22,6 +22,7 @@ import ( cryptoamino "github.com/cosmos/cosmos-sdk/crypto/codec" "github.com/cosmos/cosmos-sdk/crypto/hd" "github.com/cosmos/cosmos-sdk/crypto/ledger" + "github.com/cosmos/cosmos-sdk/crypto/types" sdk "github.com/cosmos/cosmos-sdk/types" sdkerrors "github.com/cosmos/cosmos-sdk/types/errors" ) @@ -76,10 +77,10 @@ type Keyring interface { SaveLedgerKey(uid string, algo SignatureAlgo, hrp string, coinType, account, index uint32) (Info, error) // SavePubKey stores a public key and returns the persisted Info structure. - SavePubKey(uid string, pubkey tmcrypto.PubKey, algo hd.PubKeyType) (Info, error) + SavePubKey(uid string, pubkey types.PubKey, algo hd.PubKeyType) (Info, error) // SaveMultisig stores and returns a new multsig (offline) key reference. - SaveMultisig(uid string, pubkey tmcrypto.PubKey) (Info, error) + SaveMultisig(uid string, pubkey types.PubKey) (Info, error) Signer @@ -90,10 +91,10 @@ type Keyring interface { // Signer is implemented by key stores that want to provide signing capabilities. type Signer interface { // Sign sign byte messages with a user key. - Sign(uid string, msg []byte) ([]byte, tmcrypto.PubKey, error) + Sign(uid string, msg []byte) ([]byte, types.PubKey, error) // SignByAddress sign byte messages with a user key providing the address. - SignByAddress(address sdk.Address, msg []byte) ([]byte, tmcrypto.PubKey, error) + SignByAddress(address sdk.Address, msg []byte) ([]byte, types.PubKey, error) } // Importer is implemented by key stores that support import of public and private keys. @@ -224,13 +225,13 @@ func (ks keystore) ExportPrivKeyArmor(uid, encryptPassphrase string) (armor stri } // ExportPrivateKeyObject exports an armored private key object. -func (ks keystore) ExportPrivateKeyObject(uid string) (tmcrypto.PrivKey, error) { +func (ks keystore) ExportPrivateKeyObject(uid string) (types.PrivKey, error) { info, err := ks.Key(uid) if err != nil { return nil, err } - var priv tmcrypto.PrivKey + var priv types.PrivKey switch linfo := info.(type) { case localInfo: @@ -301,13 +302,13 @@ func (ks keystore) ImportPubKey(uid string, armor string) error { return nil } -func (ks keystore) Sign(uid string, msg []byte) ([]byte, tmcrypto.PubKey, error) { +func (ks keystore) Sign(uid string, msg []byte) ([]byte, types.PubKey, error) { info, err := ks.Key(uid) if err != nil { return nil, nil, err } - var priv tmcrypto.PrivKey + var priv types.PrivKey switch i := info.(type) { case localInfo: @@ -335,7 +336,7 @@ func (ks keystore) Sign(uid string, msg []byte) ([]byte, tmcrypto.PubKey, error) return sig, priv.PubKey(), nil } -func (ks keystore) SignByAddress(address sdk.Address, msg []byte) ([]byte, tmcrypto.PubKey, error) { +func (ks keystore) SignByAddress(address sdk.Address, msg []byte) ([]byte, types.PubKey, error) { key, err := ks.KeyByAddress(address) if err != nil { return nil, nil, err @@ -359,7 +360,7 @@ func (ks keystore) SaveLedgerKey(uid string, algo SignatureAlgo, hrp string, coi return ks.writeLedgerKey(uid, priv.PubKey(), *hdPath, algo.Name()) } -func (ks keystore) writeLedgerKey(name string, pub tmcrypto.PubKey, path hd.BIP44Params, algo hd.PubKeyType) (Info, error) { +func (ks keystore) writeLedgerKey(name string, pub types.PubKey, path hd.BIP44Params, algo hd.PubKeyType) (Info, error) { info := newLedgerInfo(name, pub, path, algo) if err := ks.writeInfo(info); err != nil { return nil, err @@ -368,11 +369,11 @@ func (ks keystore) writeLedgerKey(name string, pub tmcrypto.PubKey, path hd.BIP4 return info, nil } -func (ks keystore) SaveMultisig(uid string, pubkey tmcrypto.PubKey) (Info, error) { +func (ks keystore) SaveMultisig(uid string, pubkey types.PubKey) (Info, error) { return ks.writeMultisigKey(uid, pubkey) } -func (ks keystore) SavePubKey(uid string, pubkey tmcrypto.PubKey, algo hd.PubKeyType) (Info, error) { +func (ks keystore) SavePubKey(uid string, pubkey types.PubKey, algo hd.PubKeyType) (Info, error) { return ks.writeOfflineKey(uid, pubkey, algo) } @@ -533,7 +534,7 @@ func (ks keystore) SupportedAlgorithms() (SigningAlgoList, SigningAlgoList) { // SignWithLedger signs a binary message with the ledger device referenced by an Info object // and returns the signed bytes and the public key. It returns an error if the device could // not be queried or it returned an error. -func SignWithLedger(info Info, msg []byte) (sig []byte, pub tmcrypto.PubKey, err error) { +func SignWithLedger(info Info, msg []byte) (sig []byte, pub types.PubKey, err error) { switch info.(type) { case *ledgerInfo, ledgerInfo: default: @@ -691,7 +692,7 @@ func newRealPrompt(dir string, buf io.Reader) func(string) (string, error) { } } -func (ks keystore) writeLocalKey(name string, priv tmcrypto.PrivKey, algo hd.PubKeyType) (Info, error) { +func (ks keystore) writeLocalKey(name string, priv types.PrivKey, algo hd.PubKeyType) (Info, error) { // encrypt private key using keyring pub := priv.PubKey() @@ -753,7 +754,7 @@ func (ks keystore) existsInDb(info Info) (bool, error) { return false, nil } -func (ks keystore) writeOfflineKey(name string, pub tmcrypto.PubKey, algo hd.PubKeyType) (Info, error) { +func (ks keystore) writeOfflineKey(name string, pub types.PubKey, algo hd.PubKeyType) (Info, error) { info := newOfflineInfo(name, pub, algo) err := ks.writeInfo(info) if err != nil { @@ -763,7 +764,7 @@ func (ks keystore) writeOfflineKey(name string, pub tmcrypto.PubKey, algo hd.Pub return info, nil } -func (ks keystore) writeMultisigKey(name string, pub tmcrypto.PubKey) (Info, error) { +func (ks keystore) writeMultisigKey(name string, pub types.PubKey) (Info, error) { info := NewMultiInfo(name, pub) err := ks.writeInfo(info) if err != nil { diff --git a/crypto/keyring/keyring_test.go b/crypto/keyring/keyring_test.go index 0cd75c9b4..540ea57bf 100644 --- a/crypto/keyring/keyring_test.go +++ b/crypto/keyring/keyring_test.go @@ -8,13 +8,13 @@ import ( "github.com/99designs/keyring" bip39 "github.com/cosmos/go-bip39" "github.com/stretchr/testify/require" - tmcrypto "github.com/tendermint/tendermint/crypto" "github.com/cosmos/cosmos-sdk/crypto" "github.com/cosmos/cosmos-sdk/crypto/hd" "github.com/cosmos/cosmos-sdk/crypto/keys/ed25519" "github.com/cosmos/cosmos-sdk/crypto/keys/multisig" "github.com/cosmos/cosmos-sdk/crypto/keys/secp256k1" + "github.com/cosmos/cosmos-sdk/crypto/types" sdk "github.com/cosmos/cosmos-sdk/types" ) @@ -166,7 +166,7 @@ func TestSignVerifyKeyRing(t *testing.T) { // let's try to validate and make sure it only works when everything is proper cases := []struct { - key tmcrypto.PubKey + key types.PubKey data []byte sig []byte valid bool @@ -380,7 +380,7 @@ func TestInMemoryCreateMultisig(t *testing.T) { kb, err := New("keybasename", "memory", "", nil) require.NoError(t, err) multi := multisig.NewLegacyAminoPubKey( - 1, []tmcrypto.PubKey{ + 1, []types.PubKey{ secp256k1.GenPrivKey().PubKey(), }, ) @@ -521,7 +521,7 @@ func TestInMemorySignVerify(t *testing.T) { // let's try to validate and make sure it only works when everything is proper cases := []struct { - key tmcrypto.PubKey + key types.PubKey data []byte sig []byte valid bool @@ -947,7 +947,7 @@ func TestAltKeyring_SaveMultisig(t *testing.T) { key := "multi" pub := multisig.NewLegacyAminoPubKey( 2, - []tmcrypto.PubKey{ + []types.PubKey{ &secp256k1.PubKey{Key: mnemonic1.GetPubKey().Bytes()}, &secp256k1.PubKey{Key: mnemonic2.GetPubKey().Bytes()}, }, diff --git a/crypto/keyring/legacy.go b/crypto/keyring/legacy.go index 2332266d4..59bdc3fc5 100644 --- a/crypto/keyring/legacy.go +++ b/crypto/keyring/legacy.go @@ -6,11 +6,11 @@ import ( "strings" "github.com/pkg/errors" - tmcrypto "github.com/tendermint/tendermint/crypto" tmos "github.com/tendermint/tendermint/libs/os" dbm "github.com/tendermint/tm-db" "github.com/cosmos/cosmos-sdk/crypto" + "github.com/cosmos/cosmos-sdk/crypto/types" sdk "github.com/cosmos/cosmos-sdk/types" sdkerrors "github.com/cosmos/cosmos-sdk/types/errors" ) @@ -101,13 +101,13 @@ func (kb dbKeybase) Get(name string) (Info, error) { // ExportPrivateKeyObject returns a PrivKey object given the key name and // passphrase. An error is returned if the key does not exist or if the Info for // the key is invalid. -func (kb dbKeybase) ExportPrivateKeyObject(name string, passphrase string) (tmcrypto.PrivKey, error) { +func (kb dbKeybase) ExportPrivateKeyObject(name string, passphrase string) (types.PrivKey, error) { info, err := kb.Get(name) if err != nil { return nil, err } - var priv tmcrypto.PrivKey + var priv types.PrivKey switch i := info.(type) { case localInfo: diff --git a/crypto/keyring/output_test.go b/crypto/keyring/output_test.go index dc98ad62b..c43b36bf7 100644 --- a/crypto/keyring/output_test.go +++ b/crypto/keyring/output_test.go @@ -4,10 +4,10 @@ import ( "testing" "github.com/stretchr/testify/require" - "github.com/tendermint/tendermint/crypto" kmultisig "github.com/cosmos/cosmos-sdk/crypto/keys/multisig" "github.com/cosmos/cosmos-sdk/crypto/keys/secp256k1" + "github.com/cosmos/cosmos-sdk/crypto/types" sdk "github.com/cosmos/cosmos-sdk/types" ) @@ -16,7 +16,7 @@ func TestBech32KeysOutput(t *testing.T) { bechTmpKey := sdk.MustBech32ifyPubKey(sdk.Bech32PubKeyTypeAccPub, tmpKey) tmpAddr := sdk.AccAddress(tmpKey.Address().Bytes()) - multisigPks := kmultisig.NewLegacyAminoPubKey(1, []crypto.PubKey{tmpKey}) + multisigPks := kmultisig.NewLegacyAminoPubKey(1, []types.PubKey{tmpKey}) multiInfo := NewMultiInfo("multisig", multisigPks) accAddr := sdk.AccAddress(multiInfo.GetPubKey().Address().Bytes()) bechPubKey := sdk.MustBech32ifyPubKey(sdk.Bech32PubKeyTypeAccPub, multiInfo.GetPubKey()) diff --git a/crypto/keyring/types.go b/crypto/keyring/types.go index 443896d78..0b893ea4c 100644 --- a/crypto/keyring/types.go +++ b/crypto/keyring/types.go @@ -1,9 +1,8 @@ package keyring import ( - "github.com/tendermint/tendermint/crypto" - "github.com/cosmos/cosmos-sdk/crypto/hd" + cryptotypes "github.com/cosmos/cosmos-sdk/crypto/types" ) // Language is a language to create the BIP 39 mnemonic in. @@ -68,5 +67,5 @@ type ( // DeriveKeyFunc defines the function to derive a new key from a seed and hd path DeriveKeyFunc func(mnemonic string, bip39Passphrase, hdPath string, algo hd.PubKeyType) ([]byte, error) // PrivKeyGenFunc defines the function to convert derived key bytes to a tendermint private key - PrivKeyGenFunc func(bz []byte, algo hd.PubKeyType) (crypto.PrivKey, error) + PrivKeyGenFunc func(bz []byte, algo hd.PubKeyType) (cryptotypes.PrivKey, error) ) diff --git a/crypto/keys/ed25519/ed25519.go b/crypto/keys/ed25519/ed25519.go index 4c935a076..17368c4b1 100644 --- a/crypto/keys/ed25519/ed25519.go +++ b/crypto/keys/ed25519/ed25519.go @@ -7,7 +7,6 @@ import ( "io" "github.com/tendermint/tendermint/crypto" - tmed25519 "github.com/tendermint/tendermint/crypto/ed25519" "github.com/tendermint/tendermint/crypto/tmhash" "github.com/cosmos/cosmos-sdk/codec" @@ -18,8 +17,8 @@ import ( //------------------------------------- const ( - PrivKeyName = "cosmos/PrivKeyEd25519" - PubKeyName = "cosmos/PubKeyEd25519" + PrivKeyName = "tendermint/PrivKeyEd25519" + PubKeyName = "tendermint/PubKeyEd25519" // PubKeySize is is the size, in bytes, of public keys as used in this package. PubKeySize = 32 // PrivKeySize is the size, in bytes, of private keys as used in this package. @@ -56,7 +55,7 @@ func (privKey *PrivKey) Sign(msg []byte) ([]byte, error) { // PubKey gets the corresponding public key from the private key. // // Panics if the private key is not initialized. -func (privKey *PrivKey) PubKey() crypto.PubKey { +func (privKey *PrivKey) PubKey() cryptotypes.PubKey { // If the latter 32 bytes of the privkey are all zero, privkey is not // initialized. initialized := false @@ -78,7 +77,7 @@ func (privKey *PrivKey) PubKey() crypto.PubKey { // Equals - you probably don't need to use this. // Runs in constant time based on length of the keys. -func (privKey *PrivKey) Equals(other crypto.PrivKey) bool { +func (privKey *PrivKey) Equals(other cryptotypes.LedgerPrivKey) bool { if privKey.Type() != other.Type() { return false } @@ -150,7 +149,6 @@ func GenPrivKeyFromSecret(secret []byte) *PrivKey { var _ cryptotypes.PubKey = &PubKey{} var _ codec.AminoMarshaler = &PubKey{} -var _ cryptotypes.IntoTmPubKey = &PubKey{} // Address is the SHA256-20 of the raw pubkey bytes. func (pubKey *PubKey) Address() crypto.Address { @@ -182,7 +180,7 @@ func (pubKey *PubKey) Type() string { return keyType } -func (pubKey *PubKey) Equals(other crypto.PubKey) bool { +func (pubKey *PubKey) Equals(other cryptotypes.PubKey) bool { if pubKey.Type() != other.Type() { return false } @@ -216,19 +214,3 @@ func (pubKey PubKey) MarshalAminoJSON() ([]byte, error) { func (pubKey *PubKey) UnmarshalAminoJSON(bz []byte) error { return pubKey.UnmarshalAmino(bz) } - -// AsTmPubKey converts our own PubKey into a Tendermint ED25519 pubkey. -func (pubKey *PubKey) AsTmPubKey() crypto.PubKey { - return tmed25519.PubKey(pubKey.Key) -} - -// FromTmEd25519 converts a Tendermint ED25519 pubkey into our own ED25519 -// PubKey. -func FromTmEd25519(pubKey crypto.PubKey) (*PubKey, error) { - tmPk, ok := pubKey.(tmed25519.PubKey) - if !ok { - return nil, fmt.Errorf("expected %T, got %T", tmed25519.PubKey{}, pubKey) - } - - return &PubKey{Key: []byte(tmPk)}, nil -} diff --git a/crypto/keys/ed25519/ed25519_test.go b/crypto/keys/ed25519/ed25519_test.go index 6b2ad36dc..59cce4066 100644 --- a/crypto/keys/ed25519/ed25519_test.go +++ b/crypto/keys/ed25519/ed25519_test.go @@ -9,10 +9,10 @@ import ( "github.com/stretchr/testify/require" "github.com/tendermint/tendermint/crypto" tmed25519 "github.com/tendermint/tendermint/crypto/ed25519" - "github.com/tendermint/tendermint/crypto/sr25519" "github.com/cosmos/cosmos-sdk/codec" ed25519 "github.com/cosmos/cosmos-sdk/crypto/keys/ed25519" + "github.com/cosmos/cosmos-sdk/crypto/keys/secp256k1" cryptotypes "github.com/cosmos/cosmos-sdk/crypto/types" ) @@ -51,7 +51,7 @@ func TestPubKeyEquals(t *testing.T) { testCases := []struct { msg string pubKey cryptotypes.PubKey - other crypto.PubKey + other cryptotypes.PubKey expectEq bool }{ { @@ -71,7 +71,7 @@ func TestPubKeyEquals(t *testing.T) { { "different types", ed25519PubKey, - sr25519.GenPrivKey().PubKey(), + secp256k1.GenPrivKey().PubKey(), false, }, } @@ -90,7 +90,7 @@ func TestPrivKeyEquals(t *testing.T) { testCases := []struct { msg string privKey cryptotypes.PrivKey - other crypto.PrivKey + other cryptotypes.PrivKey expectEq bool }{ { @@ -110,7 +110,7 @@ func TestPrivKeyEquals(t *testing.T) { { "different types", ed25519PrivKey, - sr25519.GenPrivKey(), + secp256k1.GenPrivKey(), false, }, } diff --git a/crypto/keys/internal/benchmarking/bench.go b/crypto/keys/internal/benchmarking/bench.go index b74b901db..a789da91f 100644 --- a/crypto/keys/internal/benchmarking/bench.go +++ b/crypto/keys/internal/benchmarking/bench.go @@ -4,7 +4,7 @@ import ( "io" "testing" - "github.com/tendermint/tendermint/crypto" + "github.com/cosmos/cosmos-sdk/crypto/types" ) // The code in this file is adapted from agl/ed25519. @@ -24,7 +24,7 @@ func (zeroReader) Read(buf []byte) (int, error) { // BenchmarkKeyGeneration benchmarks the given key generation algorithm using // a dummy reader. -func BenchmarkKeyGeneration(b *testing.B, generateKey func(reader io.Reader) crypto.PrivKey) { +func BenchmarkKeyGeneration(b *testing.B, generateKey func(reader io.Reader) types.PrivKey) { var zero zeroReader for i := 0; i < b.N; i++ { generateKey(zero) @@ -33,7 +33,7 @@ func BenchmarkKeyGeneration(b *testing.B, generateKey func(reader io.Reader) cry // BenchmarkSigning benchmarks the given signing algorithm using // the provided privkey. -func BenchmarkSigning(b *testing.B, priv crypto.PrivKey) { +func BenchmarkSigning(b *testing.B, priv types.PrivKey) { message := []byte("Hello, world!") b.ResetTimer() for i := 0; i < b.N; i++ { @@ -47,7 +47,7 @@ func BenchmarkSigning(b *testing.B, priv crypto.PrivKey) { // BenchmarkVerification benchmarks the given verification algorithm using // the provided privkey on a constant message. -func BenchmarkVerification(b *testing.B, priv crypto.PrivKey) { +func BenchmarkVerification(b *testing.B, priv types.PrivKey) { pub := priv.PubKey() // use a short message, so this time doesn't get dominated by hashing. message := []byte("Hello, world!") diff --git a/crypto/keys/multisig/codec.go b/crypto/keys/multisig/codec.go index c282d0122..b92576e4f 100644 --- a/crypto/keys/multisig/codec.go +++ b/crypto/keys/multisig/codec.go @@ -1,7 +1,6 @@ package multisig import ( - "github.com/tendermint/tendermint/crypto" "github.com/tendermint/tendermint/crypto/sr25519" "github.com/cosmos/cosmos-sdk/codec" @@ -19,10 +18,6 @@ const ( var AminoCdc = codec.NewLegacyAmino() func init() { - // TODO We now register both Tendermint's PubKey and our own PubKey. In the - // long-term, we should move away from Tendermint's PubKey, and delete this - // first line. - AminoCdc.RegisterInterface((*crypto.PubKey)(nil), nil) AminoCdc.RegisterInterface((*cryptotypes.PubKey)(nil), nil) AminoCdc.RegisterConcrete(ed25519.PubKey{}, ed25519.PubKeyName, nil) diff --git a/crypto/keys/multisig/multisig.go b/crypto/keys/multisig/multisig.go index 836eadbe1..590e5ba11 100644 --- a/crypto/keys/multisig/multisig.go +++ b/crypto/keys/multisig/multisig.go @@ -5,10 +5,8 @@ import ( tmcrypto "github.com/tendermint/tendermint/crypto" - proto "github.com/gogo/protobuf/proto" - "github.com/cosmos/cosmos-sdk/codec/types" - crypto "github.com/cosmos/cosmos-sdk/crypto/types" + cryptotypes "github.com/cosmos/cosmos-sdk/crypto/types" multisigtypes "github.com/cosmos/cosmos-sdk/crypto/types/multisig" "github.com/cosmos/cosmos-sdk/types/tx/signing" ) @@ -18,7 +16,7 @@ var _ types.UnpackInterfacesMessage = &LegacyAminoPubKey{} // NewLegacyAminoPubKey returns a new LegacyAminoPubKey. // Panics if len(pubKeys) < k or 0 >= k. -func NewLegacyAminoPubKey(k int, pubKeys []tmcrypto.PubKey) *LegacyAminoPubKey { +func NewLegacyAminoPubKey(k int, pubKeys []cryptotypes.PubKey) *LegacyAminoPubKey { if k <= 0 { panic("threshold k of n multisignature: k <= 0") } @@ -32,8 +30,8 @@ func NewLegacyAminoPubKey(k int, pubKeys []tmcrypto.PubKey) *LegacyAminoPubKey { return &LegacyAminoPubKey{Threshold: uint32(k), PubKeys: anyPubKeys} } -// Address implements crypto.PubKey Address method -func (m *LegacyAminoPubKey) Address() tmcrypto.Address { +// Address implements cryptotypes.PubKey Address method +func (m *LegacyAminoPubKey) Address() cryptotypes.Address { return tmcrypto.AddressHash(m.Bytes()) } @@ -91,7 +89,7 @@ func (m *LegacyAminoPubKey) VerifyMultisignature(getSignBytes multisigtypes.GetS return nil } -// VerifySignature implements crypto.PubKey VerifySignature method, +// VerifySignature implements cryptotypes.PubKey VerifySignature method, // it panics because it can't handle MultiSignatureData // cf. https://github.com/cosmos/cosmos-sdk/issues/7109#issuecomment-686329936 func (m *LegacyAminoPubKey) VerifySignature(msg []byte, sig []byte) bool { @@ -99,11 +97,11 @@ func (m *LegacyAminoPubKey) VerifySignature(msg []byte, sig []byte) bool { } // GetPubKeys implements the PubKey.GetPubKeys method -func (m *LegacyAminoPubKey) GetPubKeys() []tmcrypto.PubKey { +func (m *LegacyAminoPubKey) GetPubKeys() []cryptotypes.PubKey { if m != nil { - pubKeys := make([]tmcrypto.PubKey, len(m.PubKeys)) + pubKeys := make([]cryptotypes.PubKey, len(m.PubKeys)) for i := 0; i < len(m.PubKeys); i++ { - pubKeys[i] = m.PubKeys[i].GetCachedValue().(tmcrypto.PubKey) + pubKeys[i] = m.PubKeys[i].GetCachedValue().(cryptotypes.PubKey) } return pubKeys } @@ -113,7 +111,7 @@ func (m *LegacyAminoPubKey) GetPubKeys() []tmcrypto.PubKey { // Equals returns true if m and other both have the same number of keys, and // all constituent keys are the same, and in the same order. -func (m *LegacyAminoPubKey) Equals(key tmcrypto.PubKey) bool { +func (m *LegacyAminoPubKey) Equals(key cryptotypes.PubKey) bool { otherKey, ok := key.(multisigtypes.PubKey) if !ok { return false @@ -145,7 +143,7 @@ func (m *LegacyAminoPubKey) Type() string { // UnpackInterfaces implements UnpackInterfacesMessage.UnpackInterfaces func (m *LegacyAminoPubKey) UnpackInterfaces(unpacker types.AnyUnpacker) error { for _, any := range m.PubKeys { - var pk crypto.PubKey + var pk cryptotypes.PubKey err := unpacker.UnpackAny(any, &pk) if err != nil { return err @@ -154,11 +152,11 @@ func (m *LegacyAminoPubKey) UnpackInterfaces(unpacker types.AnyUnpacker) error { return nil } -func packPubKeys(pubKeys []tmcrypto.PubKey) ([]*types.Any, error) { +func packPubKeys(pubKeys []cryptotypes.PubKey) ([]*types.Any, error) { anyPubKeys := make([]*types.Any, len(pubKeys)) for i := 0; i < len(pubKeys); i++ { - any, err := types.NewAnyWithValue(pubKeys[i].(proto.Message)) + any, err := types.NewAnyWithValue(pubKeys[i]) if err != nil { return nil, err } diff --git a/crypto/keys/multisig/multisig_test.go b/crypto/keys/multisig/multisig_test.go index 9c18c97d0..2b91e74eb 100644 --- a/crypto/keys/multisig/multisig_test.go +++ b/crypto/keys/multisig/multisig_test.go @@ -3,19 +3,16 @@ package multisig_test import ( "testing" - tmcrypto "github.com/tendermint/tendermint/crypto" - - "github.com/cosmos/cosmos-sdk/codec/types" - crypto "github.com/cosmos/cosmos-sdk/crypto/types" - "github.com/cosmos/cosmos-sdk/crypto/types/multisig" - "github.com/cosmos/cosmos-sdk/x/auth/legacy/legacytx" - "github.com/stretchr/testify/require" "github.com/cosmos/cosmos-sdk/codec" + "github.com/cosmos/cosmos-sdk/codec/types" kmultisig "github.com/cosmos/cosmos-sdk/crypto/keys/multisig" "github.com/cosmos/cosmos-sdk/crypto/keys/secp256k1" + cryptotypes "github.com/cosmos/cosmos-sdk/crypto/types" + "github.com/cosmos/cosmos-sdk/crypto/types/multisig" "github.com/cosmos/cosmos-sdk/types/tx/signing" + "github.com/cosmos/cosmos-sdk/x/auth/legacy/legacytx" ) func TestAddress(t *testing.T) { @@ -30,12 +27,12 @@ func TestEquals(t *testing.T) { pubKey1 := secp256k1.GenPrivKey().PubKey() pubKey2 := secp256k1.GenPrivKey().PubKey() - multisigKey := kmultisig.NewLegacyAminoPubKey(1, []tmcrypto.PubKey{pubKey1, pubKey2}) - otherMultisigKey := kmultisig.NewLegacyAminoPubKey(1, []tmcrypto.PubKey{pubKey1, multisigKey}) + multisigKey := kmultisig.NewLegacyAminoPubKey(1, []cryptotypes.PubKey{pubKey1, pubKey2}) + otherMultisigKey := kmultisig.NewLegacyAminoPubKey(1, []cryptotypes.PubKey{pubKey1, multisigKey}) testCases := []struct { msg string - other tmcrypto.PubKey + other cryptotypes.PubKey expectEq bool }{ { @@ -255,8 +252,8 @@ func TestPubKeyMultisigThresholdAminoToIface(t *testing.T) { ab, err := kmultisig.AminoCdc.MarshalBinaryLengthPrefixed(multisigKey) require.NoError(t, err) - // like other crypto.Pubkey implementations (e.g. ed25519.PubKey), - // LegacyAminoPubKey should be deserializable into a crypto.LegacyAminoPubKey: + // like other cryptotypes.Pubkey implementations (e.g. ed25519.PubKey), + // LegacyAminoPubKey should be deserializable into a cryptotypes.LegacyAminoPubKey: var pubKey kmultisig.LegacyAminoPubKey err = kmultisig.AminoCdc.UnmarshalBinaryLengthPrefixed(ab, &pubKey) require.NoError(t, err) @@ -264,8 +261,8 @@ func TestPubKeyMultisigThresholdAminoToIface(t *testing.T) { require.Equal(t, multisigKey.Equals(&pubKey), true) } -func generatePubKeysAndSignatures(n int, msg []byte) (pubKeys []tmcrypto.PubKey, signatures []signing.SignatureData) { - pubKeys = make([]tmcrypto.PubKey, n) +func generatePubKeysAndSignatures(n int, msg []byte) (pubKeys []cryptotypes.PubKey, signatures []signing.SignatureData) { + pubKeys = make([]cryptotypes.PubKey, n) signatures = make([]signing.SignatureData, n) for i := 0; i < n; i++ { @@ -279,12 +276,12 @@ func generatePubKeysAndSignatures(n int, msg []byte) (pubKeys []tmcrypto.PubKey, } func generateNestedMultiSignature(n int, msg []byte) (multisig.PubKey, *signing.MultiSignatureData) { - pubKeys := make([]tmcrypto.PubKey, n) + pubKeys := make([]cryptotypes.PubKey, n) signatures := make([]signing.SignatureData, n) - bitArray := crypto.NewCompactBitArray(n) + bitArray := cryptotypes.NewCompactBitArray(n) for i := 0; i < n; i++ { nestedPks, nestedSigs := generatePubKeysAndSignatures(5, msg) - nestedBitArray := crypto.NewCompactBitArray(5) + nestedBitArray := cryptotypes.NewCompactBitArray(5) for j := 0; j < 5; j++ { nestedBitArray.SetIndex(j, true) } diff --git a/crypto/keys/secp256k1/bench_test.go b/crypto/keys/secp256k1/bench_test.go index e36f2df4b..423f7a5a5 100644 --- a/crypto/keys/secp256k1/bench_test.go +++ b/crypto/keys/secp256k1/bench_test.go @@ -4,13 +4,12 @@ import ( "io" "testing" - "github.com/tendermint/tendermint/crypto" - "github.com/cosmos/cosmos-sdk/crypto/keys/internal/benchmarking" + "github.com/cosmos/cosmos-sdk/crypto/types" ) func BenchmarkKeyGeneration(b *testing.B) { - benchmarkKeygenWrapper := func(reader io.Reader) crypto.PrivKey { + benchmarkKeygenWrapper := func(reader io.Reader) types.PrivKey { priv := genPrivKey(reader) return &PrivKey{Key: priv} } diff --git a/crypto/keys/secp256k1/secp256k1.go b/crypto/keys/secp256k1/secp256k1.go index 77d546812..eebe72a45 100644 --- a/crypto/keys/secp256k1/secp256k1.go +++ b/crypto/keys/secp256k1/secp256k1.go @@ -34,7 +34,7 @@ func (privKey *PrivKey) Bytes() []byte { // PubKey performs the point-scalar multiplication from the privKey on the // generator point to get the pubkey. -func (privKey *PrivKey) PubKey() crypto.PubKey { +func (privKey *PrivKey) PubKey() cryptotypes.PubKey { _, pubkeyObject := secp256k1.PrivKeyFromBytes(secp256k1.S256(), privKey.Key) pk := pubkeyObject.SerializeCompressed() return &PubKey{Key: pk} @@ -42,7 +42,7 @@ func (privKey *PrivKey) PubKey() crypto.PubKey { // Equals - you probably don't need to use this. // Runs in constant time based on length of the -func (privKey *PrivKey) Equals(other crypto.PrivKey) bool { +func (privKey *PrivKey) Equals(other cryptotypes.LedgerPrivKey) bool { return privKey.Type() == other.Type() && subtle.ConstantTimeCompare(privKey.Bytes(), other.Bytes()) == 1 } @@ -173,7 +173,7 @@ func (pubKey *PubKey) Type() string { return keyType } -func (pubKey *PubKey) Equals(other crypto.PubKey) bool { +func (pubKey *PubKey) Equals(other cryptotypes.PubKey) bool { return pubKey.Type() == other.Type() && bytes.Equal(pubKey.Bytes(), other.Bytes()) } diff --git a/crypto/keys/secp256k1/secp256k1_test.go b/crypto/keys/secp256k1/secp256k1_test.go index 0133d6850..d96b1dc38 100644 --- a/crypto/keys/secp256k1/secp256k1_test.go +++ b/crypto/keys/secp256k1/secp256k1_test.go @@ -12,9 +12,9 @@ import ( "github.com/stretchr/testify/assert" "github.com/stretchr/testify/require" "github.com/tendermint/tendermint/crypto" - "github.com/tendermint/tendermint/crypto/sr25519" "github.com/cosmos/cosmos-sdk/codec" + "github.com/cosmos/cosmos-sdk/crypto/keys/ed25519" "github.com/cosmos/cosmos-sdk/crypto/keys/secp256k1" cryptotypes "github.com/cosmos/cosmos-sdk/crypto/types" ) @@ -143,7 +143,7 @@ func TestPubKeyEquals(t *testing.T) { testCases := []struct { msg string pubKey cryptotypes.PubKey - other crypto.PubKey + other cryptotypes.PubKey expectEq bool }{ { @@ -163,7 +163,7 @@ func TestPubKeyEquals(t *testing.T) { { "different types", secp256K1PubKey, - sr25519.GenPrivKey().PubKey(), + ed25519.GenPrivKey().PubKey(), false, }, } @@ -182,7 +182,7 @@ func TestPrivKeyEquals(t *testing.T) { testCases := []struct { msg string privKey cryptotypes.PrivKey - other crypto.PrivKey + other cryptotypes.PrivKey expectEq bool }{ { @@ -202,7 +202,7 @@ func TestPrivKeyEquals(t *testing.T) { { "different types", secp256K1PrivKey, - sr25519.GenPrivKey(), + ed25519.GenPrivKey(), false, }, } diff --git a/crypto/ledger/encode_test.go b/crypto/ledger/encode_test.go index 6e0cf99f5..447891fde 100644 --- a/crypto/ledger/encode_test.go +++ b/crypto/ledger/encode_test.go @@ -6,7 +6,7 @@ import ( "github.com/stretchr/testify/require" - tcrypto "github.com/tendermint/tendermint/crypto" + cryptotypes "github.com/cosmos/cosmos-sdk/crypto/types" ) type byter interface { @@ -51,12 +51,12 @@ func TestNilEncodings(t *testing.T) { require.EqualValues(t, a, b) // Check nil PubKey. - var c, d tcrypto.PubKey + var c, d cryptotypes.PubKey checkAminoJSON(t, &c, &d, true) require.EqualValues(t, c, d) // Check nil PrivKey. - var e, f tcrypto.PrivKey + var e, f cryptotypes.PrivKey checkAminoJSON(t, &e, &f, true) require.EqualValues(t, e, f) diff --git a/crypto/ledger/ledger_secp256k1.go b/crypto/ledger/ledger_secp256k1.go index 3afdbac5f..659181d30 100644 --- a/crypto/ledger/ledger_secp256k1.go +++ b/crypto/ledger/ledger_secp256k1.go @@ -8,10 +8,10 @@ import ( "github.com/pkg/errors" tmbtcec "github.com/tendermint/btcd/btcec" - tmcrypto "github.com/tendermint/tendermint/crypto" "github.com/cosmos/cosmos-sdk/crypto/hd" "github.com/cosmos/cosmos-sdk/crypto/keys/secp256k1" + "github.com/cosmos/cosmos-sdk/crypto/types" ) var ( @@ -43,7 +43,7 @@ type ( // CachedPubKey should be private, but we want to encode it via // go-amino so we can view the address later, even without having the // ledger attached. - CachedPubKey tmcrypto.PubKey + CachedPubKey types.PubKey Path hd.BIP44Params } ) @@ -53,7 +53,7 @@ type ( // This function is marked as unsafe as it will retrieve a pubkey without user verification. // It can only be used to verify a pubkey but never to create new accounts/keys. In that case, // please refer to NewPrivKeySecp256k1 -func NewPrivKeySecp256k1Unsafe(path hd.BIP44Params) (tmcrypto.PrivKey, error) { +func NewPrivKeySecp256k1Unsafe(path hd.BIP44Params) (types.LedgerPrivKey, error) { device, err := getDevice() if err != nil { return nil, err @@ -70,7 +70,7 @@ func NewPrivKeySecp256k1Unsafe(path hd.BIP44Params) (tmcrypto.PrivKey, error) { // NewPrivKeySecp256k1 will generate a new key and store the public key for later use. // The request will require user confirmation and will show account and index in the device -func NewPrivKeySecp256k1(path hd.BIP44Params, hrp string) (tmcrypto.PrivKey, string, error) { +func NewPrivKeySecp256k1(path hd.BIP44Params, hrp string) (types.LedgerPrivKey, string, error) { device, err := getDevice() if err != nil { return nil, "", err @@ -86,7 +86,7 @@ func NewPrivKeySecp256k1(path hd.BIP44Params, hrp string) (tmcrypto.PrivKey, str } // PubKey returns the cached public key. -func (pkl PrivKeyLedgerSecp256k1) PubKey() tmcrypto.PubKey { +func (pkl PrivKeyLedgerSecp256k1) PubKey() types.PubKey { return pkl.CachedPubKey } @@ -102,7 +102,7 @@ func (pkl PrivKeyLedgerSecp256k1) Sign(message []byte) ([]byte, error) { } // ShowAddress triggers a ledger device to show the corresponding address. -func ShowAddress(path hd.BIP44Params, expectedPubKey tmcrypto.PubKey, +func ShowAddress(path hd.BIP44Params, expectedPubKey types.PubKey, accountAddressPrefix string) error { device, err := getDevice() if err != nil { @@ -154,7 +154,7 @@ func (pkl PrivKeyLedgerSecp256k1) Bytes() []byte { // Equals implements the PrivKey interface. It makes sure two private keys // refer to the same public key. -func (pkl PrivKeyLedgerSecp256k1) Equals(other tmcrypto.PrivKey) bool { +func (pkl PrivKeyLedgerSecp256k1) Equals(other types.LedgerPrivKey) bool { if otherKey, ok := other.(PrivKeyLedgerSecp256k1); ok { return pkl.CachedPubKey.Equals(otherKey.CachedPubKey) } @@ -234,7 +234,7 @@ func sign(device SECP256K1, pkl PrivKeyLedgerSecp256k1, msg []byte) ([]byte, err // // since this involves IO, it may return an error, which is not exposed // in the PubKey interface, so this function allows better error handling -func getPubKeyUnsafe(device SECP256K1, path hd.BIP44Params) (tmcrypto.PubKey, error) { +func getPubKeyUnsafe(device SECP256K1, path hd.BIP44Params) (types.PubKey, error) { publicKey, err := device.GetPublicKeySECP256K1(path.DerivationPath()) if err != nil { return nil, fmt.Errorf("please open Cosmos app on the Ledger device - error: %v", err) @@ -258,7 +258,7 @@ func getPubKeyUnsafe(device SECP256K1, path hd.BIP44Params) (tmcrypto.PubKey, er // // Since this involves IO, it may return an error, which is not exposed // in the PubKey interface, so this function allows better error handling. -func getPubKeyAddrSafe(device SECP256K1, path hd.BIP44Params, hrp string) (tmcrypto.PubKey, string, error) { +func getPubKeyAddrSafe(device SECP256K1, path hd.BIP44Params, hrp string) (types.PubKey, string, error) { publicKey, addr, err := device.GetAddressPubKeySECP256K1(path.DerivationPath(), hrp) if err != nil { return nil, "", fmt.Errorf("address %s rejected", addr) diff --git a/crypto/ledger/ledger_test.go b/crypto/ledger/ledger_test.go index 9b21e464b..bc85b2feb 100644 --- a/crypto/ledger/ledger_test.go +++ b/crypto/ledger/ledger_test.go @@ -6,10 +6,9 @@ import ( "github.com/stretchr/testify/require" - tmcrypto "github.com/tendermint/tendermint/crypto" - cryptoAmino "github.com/cosmos/cosmos-sdk/crypto/codec" "github.com/cosmos/cosmos-sdk/crypto/hd" + "github.com/cosmos/cosmos-sdk/crypto/types" "github.com/cosmos/cosmos-sdk/testutil" sdk "github.com/cosmos/cosmos-sdk/types" ) @@ -58,7 +57,7 @@ func TestPublicKeyUnsafeHDPath(t *testing.T) { const numIters = 10 - privKeys := make([]tmcrypto.PrivKey, numIters) + privKeys := make([]types.LedgerPrivKey, numIters) // Check with device for i := uint32(0); i < 10; i++ { @@ -70,8 +69,8 @@ func TestPublicKeyUnsafeHDPath(t *testing.T) { require.NotNil(t, priv) // Check other methods - require.NoError(t, priv.(PrivKeyLedgerSecp256k1).ValidateKey()) tmp := priv.(PrivKeyLedgerSecp256k1) + require.NoError(t, tmp.ValidateKey()) (&tmp).AssertIsPrivKeyInner() pubKeyAddr, err := sdk.Bech32ifyPubKey(sdk.Bech32PubKeyTypeAccPub, priv.PubKey()) @@ -151,7 +150,7 @@ func TestPublicKeyHDPath(t *testing.T) { const numIters = 10 - privKeys := make([]tmcrypto.PrivKey, numIters) + privKeys := make([]types.LedgerPrivKey, numIters) // Check with device for i := uint32(0); i < 10; i++ { @@ -170,8 +169,8 @@ func TestPublicKeyHDPath(t *testing.T) { "Is your device using test mnemonic: %s ?", testutil.TestMnemonic) // Check other methods - require.NoError(t, priv.(PrivKeyLedgerSecp256k1).ValidateKey()) tmp := priv.(PrivKeyLedgerSecp256k1) + require.NoError(t, tmp.ValidateKey()) (&tmp).AssertIsPrivKeyInner() pubKeyAddr, err := sdk.Bech32ifyPubKey(sdk.Bech32PubKeyTypeAccPub, priv.PubKey()) diff --git a/crypto/types/multisig/multisignature.go b/crypto/types/multisig/multisignature.go index b13072e28..20e3ef112 100644 --- a/crypto/types/multisig/multisignature.go +++ b/crypto/types/multisig/multisignature.go @@ -4,8 +4,6 @@ import ( "fmt" "strings" - "github.com/tendermint/tendermint/crypto" - "github.com/cosmos/cosmos-sdk/crypto/types" "github.com/cosmos/cosmos-sdk/types/tx/signing" ) @@ -27,7 +25,7 @@ func NewMultisig(n int) *signing.MultiSignatureData { } // GetIndex returns the index of pk in keys. Returns -1 if not found -func getIndex(pk crypto.PubKey, keys []crypto.PubKey) int { +func getIndex(pk types.PubKey, keys []types.PubKey) int { for i := 0; i < len(keys); i++ { if pk.Equals(keys[i]) { return i @@ -60,7 +58,7 @@ func AddSignature(mSig *signing.MultiSignatureData, sig signing.SignatureData, i // AddSignatureFromPubKey adds a signature to the multisig, at the index in // keys corresponding to the provided pubkey. -func AddSignatureFromPubKey(mSig *signing.MultiSignatureData, sig signing.SignatureData, pubkey crypto.PubKey, keys []crypto.PubKey) error { +func AddSignatureFromPubKey(mSig *signing.MultiSignatureData, sig signing.SignatureData, pubkey types.PubKey, keys []types.PubKey) error { if mSig == nil { return fmt.Errorf("value of mSig is nil %v", mSig) } @@ -85,6 +83,6 @@ func AddSignatureFromPubKey(mSig *signing.MultiSignatureData, sig signing.Signat return nil } -func AddSignatureV2(mSig *signing.MultiSignatureData, sig signing.SignatureV2, keys []crypto.PubKey) error { +func AddSignatureV2(mSig *signing.MultiSignatureData, sig signing.SignatureV2, keys []types.PubKey) error { return AddSignatureFromPubKey(mSig, sig.Data, sig.PubKey, keys) } diff --git a/crypto/types/multisig/pubkey.go b/crypto/types/multisig/pubkey.go index 51d432f59..2e778bae6 100644 --- a/crypto/types/multisig/pubkey.go +++ b/crypto/types/multisig/pubkey.go @@ -1,22 +1,21 @@ package multisig import ( - "github.com/tendermint/tendermint/crypto" - + "github.com/cosmos/cosmos-sdk/crypto/types" "github.com/cosmos/cosmos-sdk/types/tx/signing" ) // PubKey defines a type which supports multi-signature verification via MultiSignatureData // which supports multiple SignMode's. type PubKey interface { - crypto.PubKey + types.PubKey // VerifyMultisignature verifies the provide multi-signature represented by MultiSignatureData // using getSignBytes to retrieve the sign bytes to verify against for the provided mode. VerifyMultisignature(getSignBytes GetSignBytesFunc, sig *signing.MultiSignatureData) error - // GetPubKeys returns the crypto.PubKey's nested within the multi-sig PubKey - GetPubKeys() []crypto.PubKey + // GetPubKeys returns the types.PubKey's nested within the multi-sig PubKey + GetPubKeys() []types.PubKey // GetThreshold returns the threshold number of signatures that must be obtained to verify a signature. GetThreshold() uint diff --git a/crypto/types/types.go b/crypto/types/types.go index bce35d716..eccdba738 100644 --- a/crypto/types/types.go +++ b/crypto/types/types.go @@ -5,26 +5,39 @@ import ( tmcrypto "github.com/tendermint/tendermint/crypto" ) -// PubKey interface extends proto.Message -// and tendermint crypto.PubKey +// PubKey defines a public key and extends proto.Message. type PubKey interface { proto.Message - tmcrypto.PubKey + + Address() Address + Bytes() []byte + VerifySignature(msg []byte, sig []byte) bool + Equals(PubKey) bool + Type() string } -// PrivKey interface extends proto.Message -// and tendermint crypto.PrivKey +// LedgerPrivKey defines a private key that is not a proto message. For now, +// LedgerSecp256k1 keys are not converted to proto.Message yet, this is why +// they use LedgerPrivKey instead of PrivKey. All other keys must use PrivKey +// instead of LedgerPrivKey. +// TODO https://github.com/cosmos/cosmos-sdk/issues/7357. +type LedgerPrivKey interface { + Bytes() []byte + Sign(msg []byte) ([]byte, error) + PubKey() PubKey + Equals(LedgerPrivKey) bool + Type() string +} + +// PrivKey defines a private key and extends proto.Message. For now, it extends +// LedgerPrivKey (see godoc for LedgerPrivKey). Ultimately, we should remove +// LedgerPrivKey and add its methods here directly. +// TODO https://github.com/cosmos/cosmos-sdk/issues/7357. type PrivKey interface { proto.Message - tmcrypto.PrivKey + LedgerPrivKey } type ( Address = tmcrypto.Address ) - -// IntoTmPubKey allows our own PubKey types be converted into Tendermint's -// pubkey types. -type IntoTmPubKey interface { - AsTmPubKey() tmcrypto.PubKey -} diff --git a/server/tm_cmds.go b/server/tm_cmds.go index abea9c116..b05a88f79 100644 --- a/server/tm_cmds.go +++ b/server/tm_cmds.go @@ -39,7 +39,7 @@ func ShowNodeIDCmd() *cobra.Command { } } -// ShowValidator - ported from Tendermint, show this node's validator info +// ShowValidatorCmd - ported from Tendermint, show this node's validator info func ShowValidatorCmd() *cobra.Command { cmd := cobra.Command{ Use: "show-validator", @@ -59,12 +59,16 @@ func ShowValidatorCmd() *cobra.Command { return printlnJSON(valPubKey) } - pubkey, err := sdk.Bech32ifyPubKey(sdk.Bech32PubKeyTypeConsPub, valPubKey) + pubkey, err := cryptocodec.FromTmPubKeyInterface(valPubKey) + if err != nil { + return err + } + pubkeyBech32, err := sdk.Bech32ifyPubKey(sdk.Bech32PubKeyTypeConsPub, pubkey) if err != nil { return err } - fmt.Println(pubkey) + fmt.Println(pubkeyBech32) return nil }, } diff --git a/simapp/helpers/test_helpers.go b/simapp/helpers/test_helpers.go index 9e8a4d971..9ccecbd97 100644 --- a/simapp/helpers/test_helpers.go +++ b/simapp/helpers/test_helpers.go @@ -4,9 +4,8 @@ import ( "math/rand" "time" - "github.com/tendermint/tendermint/crypto" - "github.com/cosmos/cosmos-sdk/client" + cryptotypes "github.com/cosmos/cosmos-sdk/crypto/types" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cosmos/cosmos-sdk/types/simulation" "github.com/cosmos/cosmos-sdk/types/tx/signing" @@ -20,7 +19,7 @@ const ( ) // GenTx generates a signed mock transaction. -func GenTx(gen client.TxConfig, msgs []sdk.Msg, feeAmt sdk.Coins, gas uint64, chainID string, accNums, accSeqs []uint64, priv ...crypto.PrivKey) (sdk.Tx, error) { +func GenTx(gen client.TxConfig, msgs []sdk.Msg, feeAmt sdk.Coins, gas uint64, chainID string, accNums, accSeqs []uint64, priv ...cryptotypes.PrivKey) (sdk.Tx, error) { sigs := make([]signing.SignatureV2, len(priv)) // create a random length memo diff --git a/simapp/simd/cmd/testnet.go b/simapp/simd/cmd/testnet.go index d17e57fb9..3355c04b4 100644 --- a/simapp/simd/cmd/testnet.go +++ b/simapp/simd/cmd/testnet.go @@ -12,7 +12,6 @@ import ( "github.com/spf13/cobra" tmconfig "github.com/tendermint/tendermint/config" - "github.com/tendermint/tendermint/crypto" tmos "github.com/tendermint/tendermint/libs/os" tmrand "github.com/tendermint/tendermint/libs/rand" "github.com/tendermint/tendermint/types" @@ -23,6 +22,7 @@ import ( "github.com/cosmos/cosmos-sdk/client/tx" "github.com/cosmos/cosmos-sdk/crypto/hd" "github.com/cosmos/cosmos-sdk/crypto/keyring" + cryptotypes "github.com/cosmos/cosmos-sdk/crypto/types" "github.com/cosmos/cosmos-sdk/server" srvconfig "github.com/cosmos/cosmos-sdk/server/config" sdk "github.com/cosmos/cosmos-sdk/types" @@ -116,7 +116,7 @@ func InitTestnet( } nodeIDs := make([]string, numValidators) - valPubKeys := make([]crypto.PubKey, numValidators) + valPubKeys := make([]cryptotypes.PubKey, numValidators) simappConfig := srvconfig.DefaultConfig() simappConfig.MinGasPrices = minGasPrices @@ -311,7 +311,7 @@ func initGenFiles( func collectGenFiles( clientCtx client.Context, nodeConfig *tmconfig.Config, chainID string, - nodeIDs []string, valPubKeys []crypto.PubKey, numValidators int, + nodeIDs []string, valPubKeys []cryptotypes.PubKey, numValidators int, outputDir, nodeDirPrefix, nodeDaemonHome string, genBalIterator banktypes.GenesisBalancesIterator, ) error { diff --git a/simapp/test_helpers.go b/simapp/test_helpers.go index 6624c1df3..22df884fb 100644 --- a/simapp/test_helpers.go +++ b/simapp/test_helpers.go @@ -11,7 +11,6 @@ import ( "github.com/stretchr/testify/require" abci "github.com/tendermint/tendermint/abci/types" - "github.com/tendermint/tendermint/crypto" "github.com/tendermint/tendermint/libs/log" tmproto "github.com/tendermint/tendermint/proto/tendermint/types" tmtypes "github.com/tendermint/tendermint/types" @@ -20,7 +19,9 @@ import ( bam "github.com/cosmos/cosmos-sdk/baseapp" "github.com/cosmos/cosmos-sdk/client" codectypes "github.com/cosmos/cosmos-sdk/codec/types" + cryptocodec "github.com/cosmos/cosmos-sdk/crypto/codec" "github.com/cosmos/cosmos-sdk/crypto/keys/ed25519" + cryptotypes "github.com/cosmos/cosmos-sdk/crypto/types" "github.com/cosmos/cosmos-sdk/simapp/helpers" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cosmos/cosmos-sdk/types/errors" @@ -92,10 +93,7 @@ func SetupWithGenesisValSet(t *testing.T, valSet *tmtypes.ValidatorSet, genAccs bondAmt := sdk.NewInt(1000000) for _, val := range valSet.Validators { - // Currently validator requires tmcrypto.ed25519 keys, which don't support - // our Marshaling interfaces, so we need to pack them into our version of ed25519. - // There is ongoing work to add secp256k1 keys (https://github.com/cosmos/cosmos-sdk/pull/7604). - pk, err := ed25519.FromTmEd25519(val.PubKey) + pk, err := cryptocodec.FromTmPubKeyInterface(val.PubKey) require.NoError(t, err) pkAny, err := codectypes.PackAny(pk) require.NoError(t, err) @@ -230,7 +228,7 @@ func createIncrementalAccounts(accNum int) []sdk.AccAddress { } // AddTestAddrsFromPubKeys adds the addresses into the SimApp providing only the public keys. -func AddTestAddrsFromPubKeys(app *SimApp, ctx sdk.Context, pubKeys []crypto.PubKey, accAmt sdk.Int) { +func AddTestAddrsFromPubKeys(app *SimApp, ctx sdk.Context, pubKeys []cryptotypes.PubKey, accAmt sdk.Int) { initCoins := sdk.NewCoins(sdk.NewCoin(app.StakingKeeper.BondDenom(ctx), accAmt)) setTotalSupply(app, ctx, accAmt, len(pubKeys)) @@ -328,7 +326,7 @@ func CheckBalance(t *testing.T, app *SimApp, addr sdk.AccAddress, balances sdk.C // returned. func SignCheckDeliver( t *testing.T, txCfg client.TxConfig, app *bam.BaseApp, header tmproto.Header, msgs []sdk.Msg, - chainID string, accNums, accSeqs []uint64, expSimPass, expPass bool, priv ...crypto.PrivKey, + chainID string, accNums, accSeqs []uint64, expSimPass, expPass bool, priv ...cryptotypes.PrivKey, ) (sdk.GasInfo, *sdk.Result, error) { tx, err := helpers.GenTx( @@ -377,7 +375,7 @@ func SignCheckDeliver( // GenSequenceOfTxs generates a set of signed transactions of messages, such // that they differ only by having the sequence numbers incremented between // every transaction. -func GenSequenceOfTxs(txGen client.TxConfig, msgs []sdk.Msg, accNums []uint64, initSeqNums []uint64, numToGenerate int, priv ...crypto.PrivKey) ([]sdk.Tx, error) { +func GenSequenceOfTxs(txGen client.TxConfig, msgs []sdk.Msg, accNums []uint64, initSeqNums []uint64, numToGenerate int, priv ...cryptotypes.PrivKey) ([]sdk.Tx, error) { txs := make([]sdk.Tx, numToGenerate) var err error for i := 0; i < numToGenerate; i++ { @@ -407,8 +405,8 @@ func incrementAllSequenceNumbers(initSeqNums []uint64) { } // CreateTestPubKeys returns a total of numPubKeys public keys in ascending order. -func CreateTestPubKeys(numPubKeys int) []crypto.PubKey { - var publicKeys []crypto.PubKey +func CreateTestPubKeys(numPubKeys int) []cryptotypes.PubKey { + var publicKeys []cryptotypes.PubKey var buffer bytes.Buffer // start at 10 to avoid changing 1 to 01, 2 to 02, etc @@ -424,7 +422,7 @@ func CreateTestPubKeys(numPubKeys int) []crypto.PubKey { } // NewPubKeyFromHex returns a PubKey from a hex string. -func NewPubKeyFromHex(pk string) (res crypto.PubKey) { +func NewPubKeyFromHex(pk string) (res cryptotypes.PubKey) { pkBytes, err := hex.DecodeString(pk) if err != nil { panic(err) diff --git a/tests/mocks/account_retriever.go b/tests/mocks/account_retriever.go index 23b02b7dc..37fa1aa64 100644 --- a/tests/mocks/account_retriever.go +++ b/tests/mocks/account_retriever.go @@ -6,9 +6,9 @@ package mocks import ( client "github.com/cosmos/cosmos-sdk/client" + cryptotypes "github.com/cosmos/cosmos-sdk/crypto/types" types "github.com/cosmos/cosmos-sdk/types" gomock "github.com/golang/mock/gomock" - crypto "github.com/tendermint/tendermint/crypto" reflect "reflect" ) @@ -50,10 +50,10 @@ func (mr *MockAccountMockRecorder) GetAddress() *gomock.Call { } // GetPubKey mocks base method -func (m *MockAccount) GetPubKey() crypto.PubKey { +func (m *MockAccount) GetPubKey() cryptotypes.PubKey { m.ctrl.T.Helper() ret := m.ctrl.Call(m, "GetPubKey") - ret0, _ := ret[0].(crypto.PubKey) + ret0, _ := ret[0].(cryptotypes.PubKey) return ret0 } diff --git a/testutil/network/network.go b/testutil/network/network.go index 1ee11f8c9..a50c6fa93 100644 --- a/testutil/network/network.go +++ b/testutil/network/network.go @@ -16,7 +16,6 @@ import ( "github.com/stretchr/testify/require" tmcfg "github.com/tendermint/tendermint/config" - "github.com/tendermint/tendermint/crypto" tmflags "github.com/tendermint/tendermint/libs/cli/flags" "github.com/tendermint/tendermint/libs/log" tmrand "github.com/tendermint/tendermint/libs/rand" @@ -32,6 +31,7 @@ import ( codectypes "github.com/cosmos/cosmos-sdk/codec/types" "github.com/cosmos/cosmos-sdk/crypto/hd" "github.com/cosmos/cosmos-sdk/crypto/keyring" + cryptotypes "github.com/cosmos/cosmos-sdk/crypto/types" "github.com/cosmos/cosmos-sdk/server" "github.com/cosmos/cosmos-sdk/server/api" srvconfig "github.com/cosmos/cosmos-sdk/server/config" @@ -148,7 +148,7 @@ type ( Ctx *server.Context Dir string NodeID string - PubKey crypto.PubKey + PubKey cryptotypes.PubKey Moniker string APIAddress string RPCAddress string @@ -184,7 +184,7 @@ func New(t *testing.T, cfg Config) *Network { monikers := make([]string, cfg.NumValidators) nodeIDs := make([]string, cfg.NumValidators) - valPubKeys := make([]crypto.PubKey, cfg.NumValidators) + valPubKeys := make([]cryptotypes.PubKey, cfg.NumValidators) var ( genAccounts []authtypes.GenesisAccount diff --git a/testutil/testdata/tx.go b/testutil/testdata/tx.go index 09e1e365f..153846083 100644 --- a/testutil/testdata/tx.go +++ b/testutil/testdata/tx.go @@ -3,14 +3,13 @@ package testdata import ( "encoding/json" - "github.com/tendermint/tendermint/crypto" - "github.com/cosmos/cosmos-sdk/crypto/keys/secp256k1" + cryptotypes "github.com/cosmos/cosmos-sdk/crypto/types" sdk "github.com/cosmos/cosmos-sdk/types" ) // KeyTestPubAddr generates a new secp256k1 keypair. -func KeyTestPubAddr() (crypto.PrivKey, crypto.PubKey, sdk.AccAddress) { +func KeyTestPubAddr() (cryptotypes.PrivKey, cryptotypes.PubKey, sdk.AccAddress) { key := secp256k1.GenPrivKey() pub := key.PubKey() addr := sdk.AccAddress(pub.Address()) diff --git a/types/address.go b/types/address.go index 345c44fa8..a6d65e7a7 100644 --- a/types/address.go +++ b/types/address.go @@ -8,16 +8,12 @@ import ( "fmt" "strings" - "github.com/tendermint/tendermint/crypto" - tmed25519 "github.com/tendermint/tendermint/crypto/ed25519" yaml "gopkg.in/yaml.v2" "github.com/cosmos/cosmos-sdk/codec/legacy" cryptocodec "github.com/cosmos/cosmos-sdk/crypto/codec" - "github.com/cosmos/cosmos-sdk/crypto/keys/ed25519" - "github.com/cosmos/cosmos-sdk/crypto/keys/secp256k1" + cryptotypes "github.com/cosmos/cosmos-sdk/crypto/types" "github.com/cosmos/cosmos-sdk/types/bech32" - sdkerrors "github.com/cosmos/cosmos-sdk/types/errors" ) const ( @@ -452,7 +448,7 @@ func ConsAddressFromBech32(address string) (addr ConsAddress, err error) { } // get ConsAddress from pubkey -func GetConsAddress(pubkey crypto.PubKey) ConsAddress { +func GetConsAddress(pubkey cryptotypes.PubKey) ConsAddress { return ConsAddress(pubkey.Address()) } @@ -616,7 +612,8 @@ const ( // Bech32ifyPubKey returns a Bech32 encoded string containing the appropriate // prefix based on the key type provided for a given PublicKey. -func Bech32ifyPubKey(pkt Bech32PubKeyType, pubkey crypto.PubKey) (string, error) { +// TODO: Remove Bech32ifyPubKey and all usages (cosmos/cosmos-sdk/issues/#7357) +func Bech32ifyPubKey(pkt Bech32PubKeyType, pubkey cryptotypes.PubKey) (string, error) { var bech32Prefix string switch pkt { @@ -631,22 +628,11 @@ func Bech32ifyPubKey(pkt Bech32PubKeyType, pubkey crypto.PubKey) (string, error) } - // This piece of code is to keep backwards-compatibility. - // For ed25519 keys, our own ed25519 is registered in Amino under a - // different name than TM's ed25519. But since users are already using - // TM's ed25519 bech32 encoding, we explicitly say to bech32-encode our own - // ed25519 the same way as TM's ed25519. - // TODO: Remove Bech32ifyPubKey and all usages (cosmos/cosmos-sdk/issues/#7357) - pkToMarshal := pubkey - if ed25519Pk, ok := pubkey.(*ed25519.PubKey); ok { - pkToMarshal = ed25519Pk.AsTmPubKey() - } - - return bech32.ConvertAndEncode(bech32Prefix, legacy.Cdc.MustMarshalBinaryBare(pkToMarshal)) + return bech32.ConvertAndEncode(bech32Prefix, legacy.Cdc.MustMarshalBinaryBare(pubkey)) } // MustBech32ifyPubKey calls Bech32ifyPubKey except it panics on error. -func MustBech32ifyPubKey(pkt Bech32PubKeyType, pubkey crypto.PubKey) string { +func MustBech32ifyPubKey(pkt Bech32PubKeyType, pubkey cryptotypes.PubKey) string { res, err := Bech32ifyPubKey(pkt, pubkey) if err != nil { panic(err) @@ -657,7 +643,7 @@ func MustBech32ifyPubKey(pkt Bech32PubKeyType, pubkey crypto.PubKey) string { // GetPubKeyFromBech32 returns a PublicKey from a bech32-encoded PublicKey with // a given key type. -func GetPubKeyFromBech32(pkt Bech32PubKeyType, pubkeyStr string) (crypto.PubKey, error) { +func GetPubKeyFromBech32(pkt Bech32PubKeyType, pubkeyStr string) (cryptotypes.PubKey, error) { var bech32Prefix string switch pkt { @@ -677,36 +663,11 @@ func GetPubKeyFromBech32(pkt Bech32PubKeyType, pubkeyStr string) (crypto.PubKey, return nil, err } - aminoPk, err := cryptocodec.PubKeyFromBytes(bz) - if err != nil { - return nil, err - } - - var protoPk crypto.PubKey - switch aminoPk.(type) { - - // We are bech32ifying some secp256k1 keys in tests. - case *secp256k1.PubKey: - protoPk = aminoPk - case *ed25519.PubKey: - protoPk = aminoPk - - // Real-life case. - case tmed25519.PubKey: - protoPk = &ed25519.PubKey{ - Key: aminoPk.Bytes(), - } - - default: - // We only allow ed25519 pubkeys to be bech32-ed right now. - return nil, sdkerrors.Wrapf(sdkerrors.ErrInvalidType, "bech32 pubkey does not support %T", aminoPk) - } - - return protoPk, nil + return cryptocodec.PubKeyFromBytes(bz) } // MustGetPubKeyFromBech32 calls GetPubKeyFromBech32 except it panics on error. -func MustGetPubKeyFromBech32(pkt Bech32PubKeyType, pubkeyStr string) crypto.PubKey { +func MustGetPubKeyFromBech32(pkt Bech32PubKeyType, pubkeyStr string) cryptotypes.PubKey { res, err := GetPubKeyFromBech32(pkt, pubkeyStr) if err != nil { panic(err) diff --git a/types/address_test.go b/types/address_test.go index 9de4bea4f..5796c891a 100644 --- a/types/address_test.go +++ b/types/address_test.go @@ -10,11 +10,11 @@ import ( "github.com/stretchr/testify/require" "github.com/stretchr/testify/suite" - "github.com/tendermint/tendermint/crypto" "gopkg.in/yaml.v2" "github.com/cosmos/cosmos-sdk/crypto/keys/ed25519" "github.com/cosmos/cosmos-sdk/crypto/keys/secp256k1" + cryptotypes "github.com/cosmos/cosmos-sdk/crypto/types" "github.com/cosmos/cosmos-sdk/types" ) @@ -509,7 +509,7 @@ func (s *addressTestSuite) TestGetConsAddress() { pk := secp256k1.GenPrivKey().PubKey() s.Require().NotEqual(types.GetConsAddress(pk), pk.Address()) s.Require().True(bytes.Equal(types.GetConsAddress(pk).Bytes(), pk.Address().Bytes())) - s.Require().Panics(func() { types.GetConsAddress(crypto.PubKey(nil)) }) + s.Require().Panics(func() { types.GetConsAddress(cryptotypes.PubKey(nil)) }) } func (s *addressTestSuite) TestGetFromBech32() { diff --git a/types/rest/rest_test.go b/types/rest/rest_test.go index b4bf38611..0a3e16b29 100644 --- a/types/rest/rest_test.go +++ b/types/rest/rest_test.go @@ -12,13 +12,13 @@ import ( "github.com/spf13/viper" "github.com/stretchr/testify/require" - "github.com/tendermint/tendermint/crypto" "github.com/cosmos/cosmos-sdk/client" "github.com/cosmos/cosmos-sdk/client/flags" "github.com/cosmos/cosmos-sdk/codec" cryptocodec "github.com/cosmos/cosmos-sdk/crypto/codec" "github.com/cosmos/cosmos-sdk/crypto/keys/secp256k1" + cryptotypes "github.com/cosmos/cosmos-sdk/crypto/types" simappparams "github.com/cosmos/cosmos-sdk/simapp/params" "github.com/cosmos/cosmos-sdk/types" "github.com/cosmos/cosmos-sdk/types/rest" @@ -176,15 +176,15 @@ func TestParseQueryHeight(t *testing.T) { func TestProcessPostResponse(t *testing.T) { // mock account // PubKey field ensures amino encoding is used first since standard - // JSON encoding will panic on crypto.PubKey + // JSON encoding will panic on cryptotypes.PubKey t.Parallel() type mockAccount struct { - Address types.AccAddress `json:"address"` - Coins types.Coins `json:"coins"` - PubKey crypto.PubKey `json:"public_key"` - AccountNumber uint64 `json:"account_number"` - Sequence uint64 `json:"sequence"` + Address types.AccAddress `json:"address"` + Coins types.Coins `json:"coins"` + PubKey cryptotypes.PubKey `json:"public_key"` + AccountNumber uint64 `json:"account_number"` + Sequence uint64 `json:"sequence"` } // setup diff --git a/types/simulation/account.go b/types/simulation/account.go index b0c6b7bd6..e031b5a9e 100644 --- a/types/simulation/account.go +++ b/types/simulation/account.go @@ -3,10 +3,9 @@ package simulation import ( "math/rand" - "github.com/tendermint/tendermint/crypto" - "github.com/cosmos/cosmos-sdk/crypto/keys/ed25519" "github.com/cosmos/cosmos-sdk/crypto/keys/secp256k1" + cryptotypes "github.com/cosmos/cosmos-sdk/crypto/types" sdk "github.com/cosmos/cosmos-sdk/types" ) @@ -14,10 +13,10 @@ import ( // eventually more useful data can be placed in here. // (e.g. number of coins) type Account struct { - PrivKey crypto.PrivKey - PubKey crypto.PubKey + PrivKey cryptotypes.PrivKey + PubKey cryptotypes.PubKey Address sdk.AccAddress - ConsKey crypto.PrivKey + ConsKey cryptotypes.PrivKey } // Equals returns true if two accounts are equal diff --git a/types/tx/signing/signature.go b/types/tx/signing/signature.go index 0966cc06f..1323543f0 100644 --- a/types/tx/signing/signature.go +++ b/types/tx/signing/signature.go @@ -3,9 +3,8 @@ package signing import ( "fmt" - "github.com/tendermint/tendermint/crypto" - codectypes "github.com/cosmos/cosmos-sdk/codec/types" + cryptotypes "github.com/cosmos/cosmos-sdk/crypto/types" ) // SignatureV2 is a convenience type that is easier to use in application logic @@ -15,7 +14,7 @@ import ( // signatures. type SignatureV2 struct { // PubKey is the public key to use for verifying the signature - PubKey crypto.PubKey + PubKey cryptotypes.PubKey // Data is the actual data of the signature which includes SignMode's and // the signatures themselves for either single or multi-signatures. @@ -104,5 +103,5 @@ func (sds *SignatureDescriptors) UnpackInterfaces(unpacker codectypes.AnyUnpacke // UnpackInterfaces implements the UnpackInterfaceMessages.UnpackInterfaces method func (sd *SignatureDescriptor) UnpackInterfaces(unpacker codectypes.AnyUnpacker) error { - return unpacker.UnpackAny(sd.PublicKey, new(crypto.PubKey)) + return unpacker.UnpackAny(sd.PublicKey, new(cryptotypes.PubKey)) } diff --git a/types/tx/types.go b/types/tx/types.go index 436f2cd9b..c572d448a 100644 --- a/types/tx/types.go +++ b/types/tx/types.go @@ -4,9 +4,8 @@ import ( "fmt" "strings" - "github.com/tendermint/tendermint/crypto" - codectypes "github.com/cosmos/cosmos-sdk/codec/types" + cryptotypes "github.com/cosmos/cosmos-sdk/crypto/types" sdk "github.com/cosmos/cosmos-sdk/types" sdkerrors "github.com/cosmos/cosmos-sdk/types/errors" ) @@ -180,7 +179,7 @@ func (m *AuthInfo) UnpackInterfaces(unpacker codectypes.AnyUnpacker) error { // UnpackInterfaces implements the UnpackInterfaceMessages.UnpackInterfaces method func (m *SignerInfo) UnpackInterfaces(unpacker codectypes.AnyUnpacker) error { - return unpacker.UnpackAny(m.PublicKey, new(crypto.PubKey)) + return unpacker.UnpackAny(m.PublicKey, new(cryptotypes.PubKey)) } // RegisterInterfaces registers the sdk.Tx interface. diff --git a/types/tx_msg.go b/types/tx_msg.go index e75b7b6ae..ddc07fa16 100644 --- a/types/tx_msg.go +++ b/types/tx_msg.go @@ -1,9 +1,8 @@ package types import ( + cryptotypes "github.com/cosmos/cosmos-sdk/crypto/types" "github.com/gogo/protobuf/proto" - - "github.com/tendermint/tendermint/crypto" ) type ( @@ -42,7 +41,7 @@ type ( // Signature defines an interface for an application application-defined // concrete transaction type to be able to set and return transaction signatures. Signature interface { - GetPubKey() crypto.PubKey + GetPubKey() cryptotypes.PubKey GetSignature() []byte } diff --git a/x/auth/ante/ante_test.go b/x/auth/ante/ante_test.go index 0d9ef82f4..7659f3e10 100644 --- a/x/auth/ante/ante_test.go +++ b/x/auth/ante/ante_test.go @@ -8,11 +8,11 @@ import ( "testing" "github.com/stretchr/testify/require" - "github.com/tendermint/tendermint/crypto" "github.com/cosmos/cosmos-sdk/crypto/keys/ed25519" kmultisig "github.com/cosmos/cosmos-sdk/crypto/keys/multisig" "github.com/cosmos/cosmos-sdk/crypto/keys/secp256k1" + cryptotypes "github.com/cosmos/cosmos-sdk/crypto/types" "github.com/cosmos/cosmos-sdk/testutil/testdata" sdk "github.com/cosmos/cosmos-sdk/types" sdkerrors "github.com/cosmos/cosmos-sdk/types/errors" @@ -35,7 +35,7 @@ func (suite *AnteTestSuite) TestSimulateGasCost() { feeAmount := testdata.NewTestFeeAmount() gasLimit := testdata.NewTestGasLimit() accSeqs := []uint64{0, 0, 0} - privs := []crypto.PrivKey{accounts[0].priv, accounts[1].priv, accounts[2].priv} + privs := []cryptotypes.PrivKey{accounts[0].priv, accounts[1].priv, accounts[2].priv} accNums := []uint64{0, 1, 2} testCases := []TestCase{ @@ -91,7 +91,7 @@ func (suite *AnteTestSuite) TestAnteHandlerSigErrors() { // Variable data per test case var ( - privs []crypto.PrivKey + privs []cryptotypes.PrivKey accNums []uint64 accSeqs []uint64 ) @@ -100,7 +100,7 @@ func (suite *AnteTestSuite) TestAnteHandlerSigErrors() { { "check no signatures fails", func() { - privs, accNums, accSeqs = []crypto.PrivKey{}, []uint64{}, []uint64{} + privs, accNums, accSeqs = []cryptotypes.PrivKey{}, []uint64{}, []uint64{} // Create tx manually to test the tx's signers suite.Require().NoError(suite.txBuilder.SetMsgs(msgs...)) @@ -117,7 +117,7 @@ func (suite *AnteTestSuite) TestAnteHandlerSigErrors() { { "num sigs dont match GetSigners", func() { - privs, accNums, accSeqs = []crypto.PrivKey{priv0}, []uint64{0}, []uint64{0} + privs, accNums, accSeqs = []cryptotypes.PrivKey{priv0}, []uint64{0}, []uint64{0} }, false, false, @@ -126,7 +126,7 @@ func (suite *AnteTestSuite) TestAnteHandlerSigErrors() { { "unrecognized account", func() { - privs, accNums, accSeqs = []crypto.PrivKey{priv0, priv1, priv2}, []uint64{0, 1, 2}, []uint64{0, 0, 0} + privs, accNums, accSeqs = []cryptotypes.PrivKey{priv0, priv1, priv2}, []uint64{0, 1, 2}, []uint64{0, 0, 0} }, false, false, @@ -169,7 +169,7 @@ func (suite *AnteTestSuite) TestAnteHandlerAccountNumbers() { var ( accNums []uint64 msgs []sdk.Msg - privs []crypto.PrivKey + privs []cryptotypes.PrivKey accSeqs []uint64 ) @@ -180,7 +180,7 @@ func (suite *AnteTestSuite) TestAnteHandlerAccountNumbers() { msg := testdata.NewTestMsg(accounts[0].acc.GetAddress()) msgs = []sdk.Msg{msg} - privs, accNums, accSeqs = []crypto.PrivKey{accounts[0].priv}, []uint64{0}, []uint64{0} + privs, accNums, accSeqs = []cryptotypes.PrivKey{accounts[0].priv}, []uint64{0}, []uint64{0} }, false, true, @@ -189,7 +189,7 @@ func (suite *AnteTestSuite) TestAnteHandlerAccountNumbers() { { "new tx from wrong account number", func() { - privs, accNums, accSeqs = []crypto.PrivKey{accounts[0].priv}, []uint64{1}, []uint64{1} + privs, accNums, accSeqs = []cryptotypes.PrivKey{accounts[0].priv}, []uint64{1}, []uint64{1} }, false, false, @@ -198,7 +198,7 @@ func (suite *AnteTestSuite) TestAnteHandlerAccountNumbers() { { "new tx from correct account number", func() { - privs, accNums, accSeqs = []crypto.PrivKey{accounts[0].priv}, []uint64{0}, []uint64{1} + privs, accNums, accSeqs = []cryptotypes.PrivKey{accounts[0].priv}, []uint64{0}, []uint64{1} }, false, true, @@ -210,7 +210,7 @@ func (suite *AnteTestSuite) TestAnteHandlerAccountNumbers() { msg1 := testdata.NewTestMsg(accounts[0].acc.GetAddress(), accounts[1].acc.GetAddress()) msg2 := testdata.NewTestMsg(accounts[1].acc.GetAddress(), accounts[0].acc.GetAddress()) msgs = []sdk.Msg{msg1, msg2} - privs, accNums, accSeqs = []crypto.PrivKey{accounts[0].priv, accounts[1].priv}, []uint64{1, 0}, []uint64{2, 0} + privs, accNums, accSeqs = []cryptotypes.PrivKey{accounts[0].priv, accounts[1].priv}, []uint64{1, 0}, []uint64{2, 0} }, false, false, @@ -219,7 +219,7 @@ func (suite *AnteTestSuite) TestAnteHandlerAccountNumbers() { { "new tx with correct account numbers", func() { - privs, accNums, accSeqs = []crypto.PrivKey{accounts[0].priv, accounts[1].priv}, []uint64{0, 1}, []uint64{2, 0} + privs, accNums, accSeqs = []cryptotypes.PrivKey{accounts[0].priv, accounts[1].priv}, []uint64{0, 1}, []uint64{2, 0} }, false, true, @@ -251,7 +251,7 @@ func (suite *AnteTestSuite) TestAnteHandlerAccountNumbersAtBlockHeightZero() { var ( accNums []uint64 msgs []sdk.Msg - privs []crypto.PrivKey + privs []cryptotypes.PrivKey accSeqs []uint64 ) @@ -262,7 +262,7 @@ func (suite *AnteTestSuite) TestAnteHandlerAccountNumbersAtBlockHeightZero() { msg := testdata.NewTestMsg(accounts[0].acc.GetAddress()) msgs = []sdk.Msg{msg} - privs, accNums, accSeqs = []crypto.PrivKey{accounts[0].priv}, []uint64{0}, []uint64{0} + privs, accNums, accSeqs = []cryptotypes.PrivKey{accounts[0].priv}, []uint64{0}, []uint64{0} }, false, true, @@ -271,7 +271,7 @@ func (suite *AnteTestSuite) TestAnteHandlerAccountNumbersAtBlockHeightZero() { { "new tx from wrong account number", func() { - privs, accNums, accSeqs = []crypto.PrivKey{accounts[0].priv}, []uint64{1}, []uint64{1} + privs, accNums, accSeqs = []cryptotypes.PrivKey{accounts[0].priv}, []uint64{1}, []uint64{1} }, false, false, @@ -280,7 +280,7 @@ func (suite *AnteTestSuite) TestAnteHandlerAccountNumbersAtBlockHeightZero() { { "new tx from correct account number", func() { - privs, accNums, accSeqs = []crypto.PrivKey{accounts[0].priv}, []uint64{0}, []uint64{1} + privs, accNums, accSeqs = []cryptotypes.PrivKey{accounts[0].priv}, []uint64{0}, []uint64{1} }, false, true, @@ -293,7 +293,7 @@ func (suite *AnteTestSuite) TestAnteHandlerAccountNumbersAtBlockHeightZero() { msg2 := testdata.NewTestMsg(accounts[1].acc.GetAddress(), accounts[0].acc.GetAddress()) msgs = []sdk.Msg{msg1, msg2} - privs, accNums, accSeqs = []crypto.PrivKey{accounts[0].priv, accounts[1].priv}, []uint64{1, 0}, []uint64{2, 0} + privs, accNums, accSeqs = []cryptotypes.PrivKey{accounts[0].priv, accounts[1].priv}, []uint64{1, 0}, []uint64{2, 0} }, false, false, @@ -303,7 +303,7 @@ func (suite *AnteTestSuite) TestAnteHandlerAccountNumbersAtBlockHeightZero() { "new tx with another signer and correct account numbers", func() { // Note that accNums is [0,0] at block 0. - privs, accNums, accSeqs = []crypto.PrivKey{accounts[0].priv, accounts[1].priv}, []uint64{0, 0}, []uint64{2, 0} + privs, accNums, accSeqs = []cryptotypes.PrivKey{accounts[0].priv, accounts[1].priv}, []uint64{0, 0}, []uint64{2, 0} }, false, true, @@ -334,7 +334,7 @@ func (suite *AnteTestSuite) TestAnteHandlerSequences() { var ( accNums []uint64 msgs []sdk.Msg - privs []crypto.PrivKey + privs []cryptotypes.PrivKey accSeqs []uint64 ) @@ -345,7 +345,7 @@ func (suite *AnteTestSuite) TestAnteHandlerSequences() { msg := testdata.NewTestMsg(accounts[0].acc.GetAddress()) msgs = []sdk.Msg{msg} - privs, accNums, accSeqs = []crypto.PrivKey{accounts[0].priv}, []uint64{0}, []uint64{0} + privs, accNums, accSeqs = []cryptotypes.PrivKey{accounts[0].priv}, []uint64{0}, []uint64{0} }, false, true, @@ -354,7 +354,7 @@ func (suite *AnteTestSuite) TestAnteHandlerSequences() { { "test sending it again fails (replay protection)", func() { - privs, accNums, accSeqs = []crypto.PrivKey{accounts[0].priv}, []uint64{0}, []uint64{0} + privs, accNums, accSeqs = []cryptotypes.PrivKey{accounts[0].priv}, []uint64{0}, []uint64{0} }, false, false, @@ -363,7 +363,7 @@ func (suite *AnteTestSuite) TestAnteHandlerSequences() { { "fix sequence, should pass", func() { - privs, accNums, accSeqs = []crypto.PrivKey{accounts[0].priv}, []uint64{0}, []uint64{1} + privs, accNums, accSeqs = []cryptotypes.PrivKey{accounts[0].priv}, []uint64{0}, []uint64{1} }, false, true, @@ -376,7 +376,7 @@ func (suite *AnteTestSuite) TestAnteHandlerSequences() { msg2 := testdata.NewTestMsg(accounts[2].acc.GetAddress(), accounts[0].acc.GetAddress()) msgs = []sdk.Msg{msg1, msg2} - privs, accNums, accSeqs = []crypto.PrivKey{accounts[0].priv, accounts[1].priv, accounts[2].priv}, []uint64{0, 1, 2}, []uint64{2, 0, 0} + privs, accNums, accSeqs = []cryptotypes.PrivKey{accounts[0].priv, accounts[1].priv, accounts[2].priv}, []uint64{0, 1, 2}, []uint64{2, 0, 0} }, false, true, @@ -394,7 +394,7 @@ func (suite *AnteTestSuite) TestAnteHandlerSequences() { func() { msg := testdata.NewTestMsg(accounts[1].acc.GetAddress()) msgs = []sdk.Msg{msg} - privs, accNums, accSeqs = []crypto.PrivKey{accounts[1].priv}, []uint64{1}, []uint64{0} + privs, accNums, accSeqs = []cryptotypes.PrivKey{accounts[1].priv}, []uint64{1}, []uint64{0} }, false, false, @@ -415,7 +415,7 @@ func (suite *AnteTestSuite) TestAnteHandlerSequences() { msg := testdata.NewTestMsg(accounts[0].acc.GetAddress(), accounts[1].acc.GetAddress()) msgs = []sdk.Msg{msg} - privs, accNums, accSeqs = []crypto.PrivKey{accounts[0].priv, accounts[1].priv}, []uint64{0, 1}, []uint64{3, 2} + privs, accNums, accSeqs = []cryptotypes.PrivKey{accounts[0].priv, accounts[1].priv}, []uint64{0, 1}, []uint64{3, 2} }, false, true, @@ -445,7 +445,7 @@ func (suite *AnteTestSuite) TestAnteHandlerFees() { msgs := []sdk.Msg{testdata.NewTestMsg(addr0)} feeAmount := testdata.NewTestFeeAmount() gasLimit := testdata.NewTestGasLimit() - privs, accNums, accSeqs := []crypto.PrivKey{priv0}, []uint64{0}, []uint64{0} + privs, accNums, accSeqs := []cryptotypes.PrivKey{priv0}, []uint64{0}, []uint64{0} testCases := []struct { desc string @@ -517,7 +517,7 @@ func (suite *AnteTestSuite) TestAnteHandlerMemoGas() { // Same data for every test cases accounts := suite.CreateTestAccounts(1) msgs := []sdk.Msg{testdata.NewTestMsg(accounts[0].acc.GetAddress())} - privs, accNums, accSeqs := []crypto.PrivKey{accounts[0].priv}, []uint64{0}, []uint64{0} + privs, accNums, accSeqs := []cryptotypes.PrivKey{accounts[0].priv}, []uint64{0}, []uint64{0} // Variable data per test case var ( @@ -596,7 +596,7 @@ func (suite *AnteTestSuite) TestAnteHandlerMultiSigner() { var ( accNums []uint64 msgs []sdk.Msg - privs []crypto.PrivKey + privs []cryptotypes.PrivKey accSeqs []uint64 ) @@ -605,7 +605,7 @@ func (suite *AnteTestSuite) TestAnteHandlerMultiSigner() { "signers in order", func() { msgs = []sdk.Msg{msg1, msg2, msg3} - privs, accNums, accSeqs = []crypto.PrivKey{accounts[0].priv, accounts[1].priv, accounts[2].priv}, []uint64{0, 1, 2}, []uint64{0, 0, 0} + privs, accNums, accSeqs = []cryptotypes.PrivKey{accounts[0].priv, accounts[1].priv, accounts[2].priv}, []uint64{0, 1, 2}, []uint64{0, 0, 0} suite.txBuilder.SetMemo("Check signers are in expected order and different account numbers works") }, false, @@ -616,7 +616,7 @@ func (suite *AnteTestSuite) TestAnteHandlerMultiSigner() { "change sequence numbers (only accounts 0 and 1 sign)", func() { msgs = []sdk.Msg{msg1} - privs, accNums, accSeqs = []crypto.PrivKey{accounts[0].priv, accounts[1].priv}, []uint64{0, 1}, []uint64{1, 1} + privs, accNums, accSeqs = []cryptotypes.PrivKey{accounts[0].priv, accounts[1].priv}, []uint64{0, 1}, []uint64{1, 1} }, false, true, @@ -626,7 +626,7 @@ func (suite *AnteTestSuite) TestAnteHandlerMultiSigner() { "change sequence numbers (only accounts 1 and 2 sign)", func() { msgs = []sdk.Msg{msg2} - privs, accNums, accSeqs = []crypto.PrivKey{accounts[2].priv, accounts[0].priv}, []uint64{2, 0}, []uint64{1, 2} + privs, accNums, accSeqs = []cryptotypes.PrivKey{accounts[2].priv, accounts[0].priv}, []uint64{2, 0}, []uint64{1, 2} }, false, true, @@ -636,7 +636,7 @@ func (suite *AnteTestSuite) TestAnteHandlerMultiSigner() { "everyone signs again", func() { msgs = []sdk.Msg{msg1, msg2, msg3} - privs, accNums, accSeqs = []crypto.PrivKey{accounts[0].priv, accounts[1].priv, accounts[2].priv}, []uint64{0, 1, 2}, []uint64{3, 2, 2} + privs, accNums, accSeqs = []cryptotypes.PrivKey{accounts[0].priv, accounts[1].priv, accounts[2].priv}, []uint64{0, 1, 2}, []uint64{3, 2, 2} }, false, true, @@ -668,7 +668,7 @@ func (suite *AnteTestSuite) TestAnteHandlerBadSignBytes() { feeAmount sdk.Coins gasLimit uint64 msgs []sdk.Msg - privs []crypto.PrivKey + privs []cryptotypes.PrivKey accSeqs []uint64 ) @@ -680,7 +680,7 @@ func (suite *AnteTestSuite) TestAnteHandlerBadSignBytes() { feeAmount = testdata.NewTestFeeAmount() gasLimit = testdata.NewTestGasLimit() msgs = []sdk.Msg{msg0} - privs, accNums, accSeqs = []crypto.PrivKey{accounts[0].priv}, []uint64{0}, []uint64{0} + privs, accNums, accSeqs = []cryptotypes.PrivKey{accounts[0].priv}, []uint64{0}, []uint64{0} }, false, true, @@ -752,7 +752,7 @@ func (suite *AnteTestSuite) TestAnteHandlerBadSignBytes() { func() { feeAmount = testdata.NewTestFeeAmount() gasLimit = testdata.NewTestGasLimit() - privs, accNums, accSeqs = []crypto.PrivKey{accounts[1].priv}, []uint64{0}, []uint64{1} + privs, accNums, accSeqs = []cryptotypes.PrivKey{accounts[1].priv}, []uint64{0}, []uint64{1} }, false, false, @@ -762,7 +762,7 @@ func (suite *AnteTestSuite) TestAnteHandlerBadSignBytes() { "test wrong signer if public doesn't exist", func() { msgs = []sdk.Msg{testdata.NewTestMsg(accounts[1].acc.GetAddress())} - privs, accNums, accSeqs = []crypto.PrivKey{accounts[0].priv}, []uint64{1}, []uint64{0} + privs, accNums, accSeqs = []cryptotypes.PrivKey{accounts[0].priv}, []uint64{1}, []uint64{0} }, false, false, @@ -792,7 +792,7 @@ func (suite *AnteTestSuite) TestAnteHandlerSetPubKey() { var ( accNums []uint64 msgs []sdk.Msg - privs []crypto.PrivKey + privs []cryptotypes.PrivKey accSeqs []uint64 ) @@ -800,7 +800,7 @@ func (suite *AnteTestSuite) TestAnteHandlerSetPubKey() { { "test good tx", func() { - privs, accNums, accSeqs = []crypto.PrivKey{accounts[0].priv}, []uint64{0}, []uint64{0} + privs, accNums, accSeqs = []cryptotypes.PrivKey{accounts[0].priv}, []uint64{0}, []uint64{0} msgs = []sdk.Msg{testdata.NewTestMsg(accounts[0].acc.GetAddress())} }, false, @@ -835,7 +835,7 @@ func (suite *AnteTestSuite) TestAnteHandlerSetPubKey() { acc1 := suite.app.AccountKeeper.GetAccount(suite.ctx, accounts[1].acc.GetAddress()) suite.Require().Nil(acc1.GetPubKey()) - privs, accNums, accSeqs = []crypto.PrivKey{accounts[1].priv}, []uint64{1}, []uint64{0} + privs, accNums, accSeqs = []cryptotypes.PrivKey{accounts[1].priv}, []uint64{1}, []uint64{0} msgs = []sdk.Msg{testdata.NewTestMsg(accounts[1].acc.GetAddress())} suite.txBuilder.SetMsgs(msgs...) suite.txBuilder.SetFeeAmount(feeAmount) @@ -858,7 +858,7 @@ func (suite *AnteTestSuite) TestAnteHandlerSetPubKey() { suite.Require().Nil(acc1.GetPubKey()) // Set incorrect accSeq, to generate incorrect signature. - privs, accNums, accSeqs = []crypto.PrivKey{accounts[1].priv}, []uint64{1}, []uint64{1} + privs, accNums, accSeqs = []cryptotypes.PrivKey{accounts[1].priv}, []uint64{1}, []uint64{1} }, false, false, @@ -888,11 +888,11 @@ func (suite *AnteTestSuite) TestAnteHandlerSetPubKey() { } } -func generatePubKeysAndSignatures(n int, msg []byte, _ bool) (pubkeys []crypto.PubKey, signatures [][]byte) { - pubkeys = make([]crypto.PubKey, n) +func generatePubKeysAndSignatures(n int, msg []byte, _ bool) (pubkeys []cryptotypes.PubKey, signatures [][]byte) { + pubkeys = make([]cryptotypes.PubKey, n) signatures = make([][]byte, n) for i := 0; i < n; i++ { - var privkey crypto.PrivKey + var privkey cryptotypes.PrivKey privkey = secp256k1.GenPrivKey() // TODO: also generate ed25519 keys as below when ed25519 keys are @@ -910,7 +910,7 @@ func generatePubKeysAndSignatures(n int, msg []byte, _ bool) (pubkeys []crypto.P return } -func expectedGasCostByKeys(pubkeys []crypto.PubKey) uint64 { +func expectedGasCostByKeys(pubkeys []cryptotypes.PubKey) uint64 { cost := uint64(0) for _, pubkey := range pubkeys { pubkeyType := strings.ToLower(fmt.Sprintf("%T", pubkey)) @@ -927,8 +927,8 @@ func expectedGasCostByKeys(pubkeys []crypto.PubKey) uint64 { } func TestCountSubkeys(t *testing.T) { - genPubKeys := func(n int) []crypto.PubKey { - var ret []crypto.PubKey + genPubKeys := func(n int) []cryptotypes.PubKey { + var ret []cryptotypes.PubKey for i := 0; i < n; i++ { ret = append(ret, secp256k1.GenPrivKey().PubKey()) } @@ -938,10 +938,10 @@ func TestCountSubkeys(t *testing.T) { singleLevelMultiKey := kmultisig.NewLegacyAminoPubKey(4, genPubKeys(5)) multiLevelSubKey1 := kmultisig.NewLegacyAminoPubKey(4, genPubKeys(5)) multiLevelSubKey2 := kmultisig.NewLegacyAminoPubKey(4, genPubKeys(5)) - multiLevelMultiKey := kmultisig.NewLegacyAminoPubKey(2, []crypto.PubKey{ + multiLevelMultiKey := kmultisig.NewLegacyAminoPubKey(2, []cryptotypes.PubKey{ multiLevelSubKey1, multiLevelSubKey2, secp256k1.GenPrivKey().PubKey()}) type args struct { - pub crypto.PubKey + pub cryptotypes.PubKey } testCases := []struct { name string @@ -965,7 +965,7 @@ func (suite *AnteTestSuite) TestAnteHandlerSigLimitExceeded() { // Same data for every test cases accounts := suite.CreateTestAccounts(8) var addrs []sdk.AccAddress - var privs []crypto.PrivKey + var privs []cryptotypes.PrivKey for i := 0; i < 8; i++ { addrs = append(addrs, accounts[i].acc.GetAddress()) privs = append(privs, accounts[i].priv) @@ -1019,7 +1019,7 @@ func (suite *AnteTestSuite) TestCustomSignatureVerificationGasConsumer() { var ( accNums []uint64 msgs []sdk.Msg - privs []crypto.PrivKey + privs []cryptotypes.PrivKey accSeqs []uint64 ) @@ -1028,7 +1028,7 @@ func (suite *AnteTestSuite) TestCustomSignatureVerificationGasConsumer() { "verify that an secp256k1 account gets rejected", func() { msgs = []sdk.Msg{testdata.NewTestMsg(accounts[0].acc.GetAddress())} - privs, accNums, accSeqs = []crypto.PrivKey{accounts[0].priv}, []uint64{0}, []uint64{0} + privs, accNums, accSeqs = []cryptotypes.PrivKey{accounts[0].priv}, []uint64{0}, []uint64{0} }, false, false, @@ -1067,7 +1067,7 @@ func (suite *AnteTestSuite) TestAnteHandlerReCheck() { suite.txBuilder.SetMemo("thisisatestmemo") // test that operations skipped on recheck do not run - privs, accNums, accSeqs := []crypto.PrivKey{accounts[0].priv}, []uint64{0}, []uint64{0} + privs, accNums, accSeqs := []cryptotypes.PrivKey{accounts[0].priv}, []uint64{0}, []uint64{0} tx, err := suite.CreateTestTx(privs, accNums, accSeqs, suite.ctx.ChainID()) suite.Require().NoError(err) diff --git a/x/auth/ante/basic.go b/x/auth/ante/basic.go index f722e51a0..7ed834eba 100644 --- a/x/auth/ante/basic.go +++ b/x/auth/ante/basic.go @@ -1,10 +1,9 @@ package ante import ( - "github.com/tendermint/tendermint/crypto" - "github.com/cosmos/cosmos-sdk/codec/legacy" "github.com/cosmos/cosmos-sdk/crypto/keys/multisig" + cryptotypes "github.com/cosmos/cosmos-sdk/crypto/types" sdk "github.com/cosmos/cosmos-sdk/types" sdkerrors "github.com/cosmos/cosmos-sdk/types/errors" "github.com/cosmos/cosmos-sdk/types/tx/signing" @@ -110,7 +109,7 @@ func (cgts ConsumeTxSizeGasDecorator) AnteHandle(ctx sdk.Context, tx sdk.Tx, sim continue } - var pubkey crypto.PubKey + var pubkey cryptotypes.PubKey acc := cgts.ak.GetAccount(ctx, signer) diff --git a/x/auth/ante/basic_test.go b/x/auth/ante/basic_test.go index 8b304d180..085673488 100644 --- a/x/auth/ante/basic_test.go +++ b/x/auth/ante/basic_test.go @@ -3,13 +3,11 @@ package ante_test import ( "strings" - "github.com/cosmos/cosmos-sdk/testutil/testdata" - "github.com/cosmos/cosmos-sdk/types/tx/signing" - - "github.com/tendermint/tendermint/crypto" - + cryptotypes "github.com/cosmos/cosmos-sdk/crypto/types" "github.com/cosmos/cosmos-sdk/crypto/types/multisig" + "github.com/cosmos/cosmos-sdk/testutil/testdata" sdk "github.com/cosmos/cosmos-sdk/types" + "github.com/cosmos/cosmos-sdk/types/tx/signing" "github.com/cosmos/cosmos-sdk/x/auth/ante" ) @@ -28,7 +26,7 @@ func (suite *AnteTestSuite) TestValidateBasic() { suite.txBuilder.SetFeeAmount(feeAmount) suite.txBuilder.SetGasLimit(gasLimit) - privs, accNums, accSeqs := []crypto.PrivKey{}, []uint64{}, []uint64{} + privs, accNums, accSeqs := []cryptotypes.PrivKey{}, []uint64{}, []uint64{} invalidTx, err := suite.CreateTestTx(privs, accNums, accSeqs, suite.ctx.ChainID()) suite.Require().NoError(err) @@ -38,7 +36,7 @@ func (suite *AnteTestSuite) TestValidateBasic() { suite.Require().NotNil(err, "Did not error on invalid tx") - privs, accNums, accSeqs = []crypto.PrivKey{priv1}, []uint64{0}, []uint64{0} + privs, accNums, accSeqs = []cryptotypes.PrivKey{priv1}, []uint64{0}, []uint64{0} validTx, err := suite.CreateTestTx(privs, accNums, accSeqs, suite.ctx.ChainID()) suite.Require().NoError(err) @@ -69,7 +67,7 @@ func (suite *AnteTestSuite) TestValidateMemo() { suite.txBuilder.SetFeeAmount(feeAmount) suite.txBuilder.SetGasLimit(gasLimit) - privs, accNums, accSeqs := []crypto.PrivKey{priv1}, []uint64{0}, []uint64{0} + privs, accNums, accSeqs := []cryptotypes.PrivKey{priv1}, []uint64{0}, []uint64{0} suite.txBuilder.SetMemo(strings.Repeat("01234567890", 500)) invalidTx, err := suite.CreateTestTx(privs, accNums, accSeqs, suite.ctx.ChainID()) suite.Require().NoError(err) @@ -120,7 +118,7 @@ func (suite *AnteTestSuite) TestConsumeGasForTxSize() { suite.txBuilder.SetGasLimit(gasLimit) suite.txBuilder.SetMemo(strings.Repeat("01234567890", 10)) - privs, accNums, accSeqs := []crypto.PrivKey{priv1}, []uint64{0}, []uint64{0} + privs, accNums, accSeqs := []cryptotypes.PrivKey{priv1}, []uint64{0}, []uint64{0} tx, err := suite.CreateTestTx(privs, accNums, accSeqs, suite.ctx.ChainID()) suite.Require().NoError(err) @@ -214,7 +212,7 @@ func (suite *AnteTestSuite) TestTxHeightTimeoutDecorator() { suite.txBuilder.SetMemo(strings.Repeat("01234567890", 10)) suite.txBuilder.SetTimeoutHeight(tc.timeout) - privs, accNums, accSeqs := []crypto.PrivKey{priv1}, []uint64{0}, []uint64{0} + privs, accNums, accSeqs := []cryptotypes.PrivKey{priv1}, []uint64{0}, []uint64{0} tx, err := suite.CreateTestTx(privs, accNums, accSeqs, suite.ctx.ChainID()) suite.Require().NoError(err) diff --git a/x/auth/ante/fee_test.go b/x/auth/ante/fee_test.go index 4264baf39..84e5adb60 100644 --- a/x/auth/ante/fee_test.go +++ b/x/auth/ante/fee_test.go @@ -1,10 +1,9 @@ package ante_test import ( + cryptotypes "github.com/cosmos/cosmos-sdk/crypto/types" "github.com/cosmos/cosmos-sdk/testutil/testdata" - "github.com/tendermint/tendermint/crypto" - sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cosmos/cosmos-sdk/x/auth/ante" ) @@ -27,7 +26,7 @@ func (suite *AnteTestSuite) TestEnsureMempoolFees() { suite.txBuilder.SetFeeAmount(feeAmount) suite.txBuilder.SetGasLimit(gasLimit) - privs, accNums, accSeqs := []crypto.PrivKey{priv1}, []uint64{0}, []uint64{0} + privs, accNums, accSeqs := []cryptotypes.PrivKey{priv1}, []uint64{0}, []uint64{0} tx, err := suite.CreateTestTx(privs, accNums, accSeqs, suite.ctx.ChainID()) suite.Require().NoError(err) @@ -76,7 +75,7 @@ func (suite *AnteTestSuite) TestDeductFees() { suite.txBuilder.SetFeeAmount(feeAmount) suite.txBuilder.SetGasLimit(gasLimit) - privs, accNums, accSeqs := []crypto.PrivKey{priv1}, []uint64{0}, []uint64{0} + privs, accNums, accSeqs := []cryptotypes.PrivKey{priv1}, []uint64{0}, []uint64{0} tx, err := suite.CreateTestTx(privs, accNums, accSeqs, suite.ctx.ChainID()) suite.Require().NoError(err) diff --git a/x/auth/ante/setup_test.go b/x/auth/ante/setup_test.go index 8454ec26a..4942665ca 100644 --- a/x/auth/ante/setup_test.go +++ b/x/auth/ante/setup_test.go @@ -1,10 +1,8 @@ package ante_test import ( + cryptotypes "github.com/cosmos/cosmos-sdk/crypto/types" "github.com/cosmos/cosmos-sdk/testutil/testdata" - - "github.com/tendermint/tendermint/crypto" - sdk "github.com/cosmos/cosmos-sdk/types" sdkerrors "github.com/cosmos/cosmos-sdk/types/errors" "github.com/cosmos/cosmos-sdk/x/auth/ante" @@ -25,7 +23,7 @@ func (suite *AnteTestSuite) TestSetup() { suite.txBuilder.SetFeeAmount(feeAmount) suite.txBuilder.SetGasLimit(gasLimit) - privs, accNums, accSeqs := []crypto.PrivKey{priv1}, []uint64{0}, []uint64{0} + privs, accNums, accSeqs := []cryptotypes.PrivKey{priv1}, []uint64{0}, []uint64{0} tx, err := suite.CreateTestTx(privs, accNums, accSeqs, suite.ctx.ChainID()) suite.Require().NoError(err) @@ -60,7 +58,7 @@ func (suite *AnteTestSuite) TestRecoverPanic() { suite.txBuilder.SetFeeAmount(feeAmount) suite.txBuilder.SetGasLimit(gasLimit) - privs, accNums, accSeqs := []crypto.PrivKey{priv1}, []uint64{0}, []uint64{0} + privs, accNums, accSeqs := []cryptotypes.PrivKey{priv1}, []uint64{0}, []uint64{0} tx, err := suite.CreateTestTx(privs, accNums, accSeqs, suite.ctx.ChainID()) suite.Require().NoError(err) diff --git a/x/auth/ante/sigverify.go b/x/auth/ante/sigverify.go index 80ea9317e..79fbbcdc6 100644 --- a/x/auth/ante/sigverify.go +++ b/x/auth/ante/sigverify.go @@ -5,11 +5,10 @@ import ( "encoding/hex" "fmt" - "github.com/tendermint/tendermint/crypto" - "github.com/cosmos/cosmos-sdk/crypto/keys/ed25519" kmultisig "github.com/cosmos/cosmos-sdk/crypto/keys/multisig" "github.com/cosmos/cosmos-sdk/crypto/keys/secp256k1" + cryptotypes "github.com/cosmos/cosmos-sdk/crypto/types" "github.com/cosmos/cosmos-sdk/crypto/types/multisig" sdk "github.com/cosmos/cosmos-sdk/types" sdkerrors "github.com/cosmos/cosmos-sdk/types/errors" @@ -424,7 +423,7 @@ func GetSignerAcc(ctx sdk.Context, ak AccountKeeper, addr sdk.AccAddress) (types } // CountSubKeys counts the total number of keys for a multi-sig public key. -func CountSubKeys(pub crypto.PubKey) int { +func CountSubKeys(pub cryptotypes.PubKey) int { v, ok := pub.(*kmultisig.LegacyAminoPubKey) if !ok { return 1 diff --git a/x/auth/ante/sigverify_test.go b/x/auth/ante/sigverify_test.go index 2eb235b2f..337618fab 100644 --- a/x/auth/ante/sigverify_test.go +++ b/x/auth/ante/sigverify_test.go @@ -3,13 +3,12 @@ package ante_test import ( "fmt" - "github.com/tendermint/tendermint/crypto" - "github.com/cosmos/cosmos-sdk/client" "github.com/cosmos/cosmos-sdk/codec" "github.com/cosmos/cosmos-sdk/crypto/keys/ed25519" kmultisig "github.com/cosmos/cosmos-sdk/crypto/keys/multisig" "github.com/cosmos/cosmos-sdk/crypto/keys/secp256k1" + cryptotypes "github.com/cosmos/cosmos-sdk/crypto/types" "github.com/cosmos/cosmos-sdk/crypto/types/multisig" "github.com/cosmos/cosmos-sdk/simapp" "github.com/cosmos/cosmos-sdk/testutil/testdata" @@ -30,7 +29,7 @@ func (suite *AnteTestSuite) TestSetPubKey() { priv3, pub3, addr3 := testdata.KeyTestPubAddr() addrs := []sdk.AccAddress{addr1, addr2, addr3} - pubs := []crypto.PubKey{pub1, pub2, pub3} + pubs := []cryptotypes.PubKey{pub1, pub2, pub3} msgs := make([]sdk.Msg, len(addrs)) // set accounts and create msg for each address @@ -47,7 +46,7 @@ func (suite *AnteTestSuite) TestSetPubKey() { suite.txBuilder.SetFeeAmount(feeAmount) suite.txBuilder.SetGasLimit(gasLimit) - privs, accNums, accSeqs := []crypto.PrivKey{priv1, priv2, priv3}, []uint64{0, 1, 2}, []uint64{0, 0, 0} + privs, accNums, accSeqs := []cryptotypes.PrivKey{priv1, priv2, priv3}, []uint64{0, 1, 2}, []uint64{0, 0, 0} tx, err := suite.CreateTestTx(privs, accNums, accSeqs, suite.ctx.ChainID()) suite.Require().NoError(err) @@ -85,7 +84,7 @@ func (suite *AnteTestSuite) TestConsumeSignatureVerificationGas() { type args struct { meter sdk.GasMeter sig signing.SignatureData - pubkey crypto.PubKey + pubkey cryptotypes.PubKey params types.Params } tests := []struct { @@ -148,20 +147,20 @@ func (suite *AnteTestSuite) TestSigVerification() { type testCase struct { name string - privs []crypto.PrivKey + privs []cryptotypes.PrivKey accNums []uint64 accSeqs []uint64 recheck bool shouldErr bool } testCases := []testCase{ - {"no signers", []crypto.PrivKey{}, []uint64{}, []uint64{}, false, true}, - {"not enough signers", []crypto.PrivKey{priv1, priv2}, []uint64{0, 1}, []uint64{0, 0}, false, true}, - {"wrong order signers", []crypto.PrivKey{priv3, priv2, priv1}, []uint64{2, 1, 0}, []uint64{0, 0, 0}, false, true}, - {"wrong accnums", []crypto.PrivKey{priv1, priv2, priv3}, []uint64{7, 8, 9}, []uint64{0, 0, 0}, false, true}, - {"wrong sequences", []crypto.PrivKey{priv1, priv2, priv3}, []uint64{0, 1, 2}, []uint64{3, 4, 5}, false, true}, - {"valid tx", []crypto.PrivKey{priv1, priv2, priv3}, []uint64{0, 1, 2}, []uint64{0, 0, 0}, false, false}, - {"no err on recheck", []crypto.PrivKey{}, []uint64{}, []uint64{}, true, false}, + {"no signers", []cryptotypes.PrivKey{}, []uint64{}, []uint64{}, false, true}, + {"not enough signers", []cryptotypes.PrivKey{priv1, priv2}, []uint64{0, 1}, []uint64{0, 0}, false, true}, + {"wrong order signers", []cryptotypes.PrivKey{priv3, priv2, priv1}, []uint64{2, 1, 0}, []uint64{0, 0, 0}, false, true}, + {"wrong accnums", []cryptotypes.PrivKey{priv1, priv2, priv3}, []uint64{7, 8, 9}, []uint64{0, 0, 0}, false, true}, + {"wrong sequences", []cryptotypes.PrivKey{priv1, priv2, priv3}, []uint64{0, 1, 2}, []uint64{3, 4, 5}, false, true}, + {"valid tx", []cryptotypes.PrivKey{priv1, priv2, priv3}, []uint64{0, 1, 2}, []uint64{0, 0, 0}, false, false}, + {"no err on recheck", []cryptotypes.PrivKey{}, []uint64{}, []uint64{}, true, false}, } for i, tc := range testCases { suite.ctx = suite.ctx.WithIsReCheckTx(tc.recheck) @@ -233,20 +232,20 @@ func (suite *AnteTestSuite) TestSigVerification_ExplicitAmino() { type testCase struct { name string - privs []crypto.PrivKey + privs []cryptotypes.PrivKey accNums []uint64 accSeqs []uint64 recheck bool shouldErr bool } testCases := []testCase{ - {"no signers", []crypto.PrivKey{}, []uint64{}, []uint64{}, false, true}, - {"not enough signers", []crypto.PrivKey{priv1, priv2}, []uint64{0, 1}, []uint64{0, 0}, false, true}, - {"wrong order signers", []crypto.PrivKey{priv3, priv2, priv1}, []uint64{2, 1, 0}, []uint64{0, 0, 0}, false, true}, - {"wrong accnums", []crypto.PrivKey{priv1, priv2, priv3}, []uint64{7, 8, 9}, []uint64{0, 0, 0}, false, true}, - {"wrong sequences", []crypto.PrivKey{priv1, priv2, priv3}, []uint64{0, 1, 2}, []uint64{3, 4, 5}, false, true}, - {"valid tx", []crypto.PrivKey{priv1, priv2, priv3}, []uint64{0, 1, 2}, []uint64{0, 0, 0}, false, false}, - {"no err on recheck", []crypto.PrivKey{}, []uint64{}, []uint64{}, true, false}, + {"no signers", []cryptotypes.PrivKey{}, []uint64{}, []uint64{}, false, true}, + {"not enough signers", []cryptotypes.PrivKey{priv1, priv2}, []uint64{0, 1}, []uint64{0, 0}, false, true}, + {"wrong order signers", []cryptotypes.PrivKey{priv3, priv2, priv1}, []uint64{2, 1, 0}, []uint64{0, 0, 0}, false, true}, + {"wrong accnums", []cryptotypes.PrivKey{priv1, priv2, priv3}, []uint64{7, 8, 9}, []uint64{0, 0, 0}, false, true}, + {"wrong sequences", []cryptotypes.PrivKey{priv1, priv2, priv3}, []uint64{0, 1, 2}, []uint64{3, 4, 5}, false, true}, + {"valid tx", []cryptotypes.PrivKey{priv1, priv2, priv3}, []uint64{0, 1, 2}, []uint64{0, 0, 0}, false, false}, + {"no err on recheck", []cryptotypes.PrivKey{}, []uint64{}, []uint64{}, true, false}, } for i, tc := range testCases { suite.ctx = suite.ctx.WithIsReCheckTx(tc.recheck) @@ -270,7 +269,7 @@ func (suite *AnteTestSuite) TestSigVerification_ExplicitAmino() { func (suite *AnteTestSuite) TestSigIntegration() { // generate private keys - privs := []crypto.PrivKey{ + privs := []cryptotypes.PrivKey{ secp256k1.GenPrivKey(), secp256k1.GenPrivKey(), secp256k1.GenPrivKey(), @@ -288,7 +287,7 @@ func (suite *AnteTestSuite) TestSigIntegration() { suite.Require().Equal(initialSigCost*uint64(len(privs)), doubleCost-initialCost) } -func (suite *AnteTestSuite) runSigDecorators(params types.Params, _ bool, privs ...crypto.PrivKey) (sdk.Gas, error) { +func (suite *AnteTestSuite) runSigDecorators(params types.Params, _ bool, privs ...cryptotypes.PrivKey) (sdk.Gas, error) { suite.SetupTest(true) // setup suite.txBuilder = suite.clientCtx.TxConfig.NewTxBuilder() @@ -343,7 +342,7 @@ func (suite *AnteTestSuite) TestIncrementSequenceDecorator() { msgs := []sdk.Msg{testdata.NewTestMsg(addr)} suite.Require().NoError(suite.txBuilder.SetMsgs(msgs...)) - privs := []crypto.PrivKey{priv} + privs := []cryptotypes.PrivKey{priv} accNums := []uint64{suite.app.AccountKeeper.GetAccount(suite.ctx, addr).GetAccountNumber()} accSeqs := []uint64{suite.app.AccountKeeper.GetAccount(suite.ctx, addr).GetSequence()} feeAmount := testdata.NewTestFeeAmount() diff --git a/x/auth/ante/testutil_test.go b/x/auth/ante/testutil_test.go index 9d8924eea..5a1cfc4ec 100644 --- a/x/auth/ante/testutil_test.go +++ b/x/auth/ante/testutil_test.go @@ -6,11 +6,11 @@ import ( "testing" "github.com/stretchr/testify/suite" - "github.com/tendermint/tendermint/crypto" tmproto "github.com/tendermint/tendermint/proto/tendermint/types" "github.com/cosmos/cosmos-sdk/client" "github.com/cosmos/cosmos-sdk/client/tx" + cryptotypes "github.com/cosmos/cosmos-sdk/crypto/types" "github.com/cosmos/cosmos-sdk/simapp" "github.com/cosmos/cosmos-sdk/testutil/testdata" sdk "github.com/cosmos/cosmos-sdk/types" @@ -24,7 +24,7 @@ import ( // TestAccount represents an account used in the tests in x/auth/ante. type TestAccount struct { acc types.AccountI - priv crypto.PrivKey + priv cryptotypes.PrivKey } // AnteTestSuite is a test suite to be used with ante handler tests. @@ -86,7 +86,7 @@ func (suite *AnteTestSuite) CreateTestAccounts(numAccs int) []TestAccount { } // CreateTestTx is a helper function to create a tx given multiple inputs. -func (suite *AnteTestSuite) CreateTestTx(privs []crypto.PrivKey, accNums []uint64, accSeqs []uint64, chainID string) (xauthsigning.Tx, error) { +func (suite *AnteTestSuite) CreateTestTx(privs []cryptotypes.PrivKey, accNums []uint64, accSeqs []uint64, chainID string) (xauthsigning.Tx, error) { // First round: we gather all the signer infos. We use the "set empty // signature" hack to do that. var sigsV2 []signing.SignatureV2 @@ -142,7 +142,7 @@ type TestCase struct { } // CreateTestTx is a helper function to create a tx given multiple inputs. -func (suite *AnteTestSuite) RunTestCase(privs []crypto.PrivKey, msgs []sdk.Msg, feeAmount sdk.Coins, gasLimit uint64, accNums, accSeqs []uint64, chainID string, tc TestCase) { +func (suite *AnteTestSuite) RunTestCase(privs []cryptotypes.PrivKey, msgs []sdk.Msg, feeAmount sdk.Coins, gasLimit uint64, accNums, accSeqs []uint64, chainID string, tc TestCase) { suite.Run(fmt.Sprintf("Case %s", tc.desc), func() { suite.Require().NoError(suite.txBuilder.SetMsgs(msgs...)) suite.txBuilder.SetFeeAmount(feeAmount) diff --git a/x/auth/client/cli/cli_test.go b/x/auth/client/cli/cli_test.go index 4961e91c3..4ba383139 100644 --- a/x/auth/client/cli/cli_test.go +++ b/x/auth/client/cli/cli_test.go @@ -1,5 +1,3 @@ -// +build norace - package cli_test import ( @@ -12,7 +10,6 @@ import ( "github.com/stretchr/testify/require" "github.com/stretchr/testify/suite" - tmcrypto "github.com/tendermint/tendermint/crypto" tmcli "github.com/tendermint/tendermint/libs/cli" "github.com/cosmos/cosmos-sdk/client" @@ -22,6 +19,7 @@ import ( "github.com/cosmos/cosmos-sdk/crypto/hd" "github.com/cosmos/cosmos-sdk/crypto/keyring" kmultisig "github.com/cosmos/cosmos-sdk/crypto/keys/multisig" + cryptotypes "github.com/cosmos/cosmos-sdk/crypto/types" "github.com/cosmos/cosmos-sdk/simapp" "github.com/cosmos/cosmos-sdk/testutil" clitestutil "github.com/cosmos/cosmos-sdk/testutil/cli" @@ -63,7 +61,7 @@ func (s *IntegrationTestSuite) SetupSuite() { account2, _, err := kb.NewMnemonic("newAccount2", keyring.English, sdk.FullFundraiserPath, hd.Secp256k1) s.Require().NoError(err) - multi := kmultisig.NewLegacyAminoPubKey(2, []tmcrypto.PubKey{account1.GetPubKey(), account2.GetPubKey()}) + multi := kmultisig.NewLegacyAminoPubKey(2, []cryptotypes.PubKey{account1.GetPubKey(), account2.GetPubKey()}) _, err = kb.SaveMultisig("multi", multi) s.Require().NoError(err) diff --git a/x/auth/keeper/keeper.go b/x/auth/keeper/keeper.go index 86189b62a..75724f7d3 100644 --- a/x/auth/keeper/keeper.go +++ b/x/auth/keeper/keeper.go @@ -4,10 +4,10 @@ import ( "fmt" gogotypes "github.com/gogo/protobuf/types" - "github.com/tendermint/tendermint/crypto" "github.com/tendermint/tendermint/libs/log" "github.com/cosmos/cosmos-sdk/codec" + cryptotypes "github.com/cosmos/cosmos-sdk/crypto/types" sdk "github.com/cosmos/cosmos-sdk/types" sdkerrors "github.com/cosmos/cosmos-sdk/types/errors" "github.com/cosmos/cosmos-sdk/x/auth/types" @@ -35,7 +35,7 @@ type AccountKeeperI interface { IterateAccounts(sdk.Context, func(types.AccountI) bool) // Fetch the public key of an account at a specified address - GetPubKey(sdk.Context, sdk.AccAddress) (crypto.PubKey, error) + GetPubKey(sdk.Context, sdk.AccAddress) (cryptotypes.PubKey, error) // Fetch the sequence of an account at a specified address. GetSequence(sdk.Context, sdk.AccAddress) (uint64, error) @@ -90,7 +90,7 @@ func (ak AccountKeeper) Logger(ctx sdk.Context) log.Logger { } // GetPubKey Returns the PubKey of the account at address -func (ak AccountKeeper) GetPubKey(ctx sdk.Context, addr sdk.AccAddress) (crypto.PubKey, error) { +func (ak AccountKeeper) GetPubKey(ctx sdk.Context, addr sdk.AccAddress) (cryptotypes.PubKey, error) { acc := ak.GetAccount(ctx, addr) if acc == nil { return nil, sdkerrors.Wrapf(sdkerrors.ErrUnknownAddress, "account %s does not exist", addr) diff --git a/x/auth/legacy/legacytx/stdsign.go b/x/auth/legacy/legacytx/stdsign.go index 49792d3a2..2ba194dad 100644 --- a/x/auth/legacy/legacytx/stdsign.go +++ b/x/auth/legacy/legacytx/stdsign.go @@ -3,11 +3,10 @@ package legacytx import ( "encoding/json" - "github.com/tendermint/tendermint/crypto" - "github.com/cosmos/cosmos-sdk/codec" "github.com/cosmos/cosmos-sdk/codec/legacy" codectypes "github.com/cosmos/cosmos-sdk/codec/types" + cryptotypes "github.com/cosmos/cosmos-sdk/crypto/types" "github.com/cosmos/cosmos-sdk/crypto/types/multisig" sdk "github.com/cosmos/cosmos-sdk/types" sdkerrors "github.com/cosmos/cosmos-sdk/types/errors" @@ -57,8 +56,8 @@ func StdSignBytes(chainID string, accnum, sequence, timeout uint64, fee StdFee, // Deprecated: StdSignature represents a sig type StdSignature struct { - crypto.PubKey `json:"pub_key" yaml:"pub_key"` // optional - Signature []byte `json:"signature" yaml:"signature"` + cryptotypes.PubKey `json:"pub_key" yaml:"pub_key"` // optional + Signature []byte `json:"signature" yaml:"signature"` } // StdSignatureToSignatureV2 converts a StdSignature to a SignatureV2 @@ -75,7 +74,7 @@ func StdSignatureToSignatureV2(cdc *codec.LegacyAmino, sig StdSignature) (signin }, nil } -func pubKeySigToSigData(cdc *codec.LegacyAmino, key crypto.PubKey, sig []byte) (signing.SignatureData, error) { +func pubKeySigToSigData(cdc *codec.LegacyAmino, key cryptotypes.PubKey, sig []byte) (signing.SignatureData, error) { multiPK, ok := key.(multisig.PubKey) if !ok { return &signing.SingleSignatureData{ diff --git a/x/auth/legacy/legacytx/stdtx.go b/x/auth/legacy/legacytx/stdtx.go index 270a8d727..ba3215010 100644 --- a/x/auth/legacy/legacytx/stdtx.go +++ b/x/auth/legacy/legacytx/stdtx.go @@ -3,11 +3,11 @@ package legacytx import ( "fmt" - "github.com/tendermint/tendermint/crypto" "gopkg.in/yaml.v2" "github.com/cosmos/cosmos-sdk/codec/legacy" codectypes "github.com/cosmos/cosmos-sdk/codec/types" + cryptotypes "github.com/cosmos/cosmos-sdk/crypto/types" sdk "github.com/cosmos/cosmos-sdk/types" sdkerrors "github.com/cosmos/cosmos-sdk/types/errors" txtypes "github.com/cosmos/cosmos-sdk/types/tx" @@ -73,7 +73,7 @@ func (fee StdFee) GasPrices() sdk.DecCoins { } // Deprecated -func NewStdSignature(pk crypto.PubKey, sig []byte) StdSignature { +func NewStdSignature(pk cryptotypes.PubKey, sig []byte) StdSignature { return StdSignature{PubKey: pk, Signature: sig} } @@ -82,9 +82,9 @@ func (ss StdSignature) GetSignature() []byte { return ss.Signature } -// GetPubKey returns the public key of a signature as a crypto.PubKey using the +// GetPubKey returns the public key of a signature as a cryptotypes.PubKey using the // Amino codec. -func (ss StdSignature) GetPubKey() crypto.PubKey { +func (ss StdSignature) GetPubKey() cryptotypes.PubKey { return ss.PubKey } @@ -238,8 +238,8 @@ func (tx StdTx) GetSignaturesV2() ([]signing.SignatureV2, error) { // GetPubkeys returns the pubkeys of signers if the pubkey is included in the signature // If pubkey is not included in the signature, then nil is in the slice instead -func (tx StdTx) GetPubKeys() []crypto.PubKey { - pks := make([]crypto.PubKey, len(tx.Signatures)) +func (tx StdTx) GetPubKeys() []cryptotypes.PubKey { + pks := make([]cryptotypes.PubKey, len(tx.Signatures)) for i, stdSig := range tx.Signatures { pks[i] = stdSig.GetPubKey() diff --git a/x/auth/legacy/legacytx/stdtx_test.go b/x/auth/legacy/legacytx/stdtx_test.go index 96460f538..a702a8284 100644 --- a/x/auth/legacy/legacytx/stdtx_test.go +++ b/x/auth/legacy/legacytx/stdtx_test.go @@ -5,7 +5,6 @@ import ( "testing" "github.com/stretchr/testify/require" - "github.com/tendermint/tendermint/crypto" "github.com/tendermint/tendermint/libs/log" tmproto "github.com/tendermint/tendermint/proto/tendermint/types" yaml "gopkg.in/yaml.v2" @@ -15,6 +14,7 @@ import ( "github.com/cosmos/cosmos-sdk/crypto/keys/ed25519" kmultisig "github.com/cosmos/cosmos-sdk/crypto/keys/multisig" "github.com/cosmos/cosmos-sdk/crypto/types" + cryptotypes "github.com/cosmos/cosmos-sdk/crypto/types" "github.com/cosmos/cosmos-sdk/testutil/testdata" sdk "github.com/cosmos/cosmos-sdk/types" sdkerrors "github.com/cosmos/cosmos-sdk/types/errors" @@ -39,7 +39,7 @@ func NewTestStdFee() StdFee { } // Deprecated, use TxBuilder. -func NewTestTx(ctx sdk.Context, msgs []sdk.Msg, privs []crypto.PrivKey, accNums []uint64, seqs []uint64, timeout uint64, fee StdFee) sdk.Tx { +func NewTestTx(ctx sdk.Context, msgs []sdk.Msg, privs []cryptotypes.PrivKey, accNums []uint64, seqs []uint64, timeout uint64, fee StdFee) sdk.Tx { sigs := make([]StdSignature, len(privs)) for i, priv := range privs { signBytes := StdSignBytes(ctx.ChainID(), accNums[i], seqs[i], timeout, fee, msgs, "") @@ -126,7 +126,7 @@ func TestTxValidateBasic(t *testing.T) { require.Equal(t, sdkerrors.ErrInsufficientFee.ABCICode(), code) // require to fail validation when no signatures exist - privs, accNums, seqs := []crypto.PrivKey{}, []uint64{}, []uint64{} + privs, accNums, seqs := []cryptotypes.PrivKey{}, []uint64{}, []uint64{} tx = NewTestTx(ctx, msgs, privs, accNums, seqs, 0, fee) err = tx.ValidateBasic() @@ -135,7 +135,7 @@ func TestTxValidateBasic(t *testing.T) { require.Equal(t, sdkerrors.ErrNoSignatures.ABCICode(), code) // require to fail validation when signatures do not match expected signers - privs, accNums, seqs = []crypto.PrivKey{priv1}, []uint64{0, 1}, []uint64{0, 0} + privs, accNums, seqs = []cryptotypes.PrivKey{priv1}, []uint64{0, 1}, []uint64{0, 0} tx = NewTestTx(ctx, msgs, privs, accNums, seqs, 0, fee) err = tx.ValidateBasic() @@ -154,7 +154,7 @@ func TestTxValidateBasic(t *testing.T) { require.Equal(t, sdkerrors.ErrInvalidRequest.ABCICode(), code) // require to pass when above criteria are matched - privs, accNums, seqs = []crypto.PrivKey{priv1, priv2}, []uint64{0, 1}, []uint64{0, 0} + privs, accNums, seqs = []cryptotypes.PrivKey{priv1, priv2}, []uint64{0, 1}, []uint64{0, 0} tx = NewTestTx(ctx, msgs, privs, accNums, seqs, 0, fee) err = tx.ValidateBasic() @@ -231,7 +231,7 @@ func TestSignatureV2Conversions(t *testing.T) { // multisigs _, pubKey2, _ := testdata.KeyTestPubAddr() - multiPK := kmultisig.NewLegacyAminoPubKey(1, []crypto.PubKey{ + multiPK := kmultisig.NewLegacyAminoPubKey(1, []cryptotypes.PubKey{ pubKey, pubKey2, }) dummy2 := []byte("dummySig2") diff --git a/x/auth/legacy/v038/types.go b/x/auth/legacy/v038/types.go index aeb554eee..e9977c1d2 100644 --- a/x/auth/legacy/v038/types.go +++ b/x/auth/legacy/v038/types.go @@ -11,9 +11,11 @@ import ( "sort" "strings" - "github.com/tendermint/tendermint/crypto" + tmcrypto "github.com/tendermint/tendermint/crypto" "github.com/cosmos/cosmos-sdk/codec" + cryptocodec "github.com/cosmos/cosmos-sdk/crypto/codec" + cryptotypes "github.com/cosmos/cosmos-sdk/crypto/types" sdk "github.com/cosmos/cosmos-sdk/types" v034auth "github.com/cosmos/cosmos-sdk/x/auth/legacy/v034" ) @@ -45,11 +47,11 @@ type ( } BaseAccount struct { - Address sdk.AccAddress `json:"address" yaml:"address"` - Coins sdk.Coins `json:"coins,omitempty" yaml:"coins,omitempty"` - PubKey crypto.PubKey `json:"public_key" yaml:"public_key"` - AccountNumber uint64 `json:"account_number" yaml:"account_number"` - Sequence uint64 `json:"sequence" yaml:"sequence"` + Address sdk.AccAddress `json:"address" yaml:"address"` + Coins sdk.Coins `json:"coins,omitempty" yaml:"coins,omitempty"` + PubKey cryptotypes.PubKey `json:"public_key" yaml:"public_key"` + AccountNumber uint64 `json:"account_number" yaml:"account_number"` + Sequence uint64 `json:"sequence" yaml:"sequence"` } baseAccountPretty struct { @@ -127,7 +129,7 @@ func NewBaseAccountWithAddress(addr sdk.AccAddress) BaseAccount { } func NewBaseAccount( - address sdk.AccAddress, coins sdk.Coins, pk crypto.PubKey, accountNumber, sequence uint64, + address sdk.AccAddress, coins sdk.Coins, pk cryptotypes.PubKey, accountNumber, sequence uint64, ) *BaseAccount { return &BaseAccount{ @@ -259,7 +261,7 @@ func (bva *BaseVestingAccount) UnmarshalJSON(bz []byte) error { } var ( - pk crypto.PubKey + pk cryptotypes.PubKey err error ) @@ -328,7 +330,7 @@ func (cva *ContinuousVestingAccount) UnmarshalJSON(bz []byte) error { } var ( - pk crypto.PubKey + pk cryptotypes.PubKey err error ) @@ -394,7 +396,7 @@ func (dva *DelayedVestingAccount) UnmarshalJSON(bz []byte) error { } var ( - pk crypto.PubKey + pk cryptotypes.PubKey err error ) @@ -417,7 +419,7 @@ func (dva *DelayedVestingAccount) UnmarshalJSON(bz []byte) error { } func NewModuleAddress(name string) sdk.AccAddress { - return sdk.AccAddress(crypto.AddressHash([]byte(name))) + return sdk.AccAddress(tmcrypto.AddressHash([]byte(name))) } func NewModuleAccount(baseAccount *BaseAccount, name string, permissions ...string) *ModuleAccount { @@ -437,7 +439,7 @@ func (ma ModuleAccount) Validate() error { return errors.New("module account name cannot be blank") } - if !ma.Address.Equals(sdk.AccAddress(crypto.AddressHash([]byte(ma.Name)))) { + if !ma.Address.Equals(sdk.AccAddress(tmcrypto.AddressHash([]byte(ma.Name)))) { return fmt.Errorf("address %s cannot be derived from the module name '%s'", ma.Address, ma.Name) } @@ -517,6 +519,7 @@ func ValidateGenAccounts(genAccounts GenesisAccounts) error { } func RegisterLegacyAminoCodec(cdc *codec.LegacyAmino) { + cryptocodec.RegisterCrypto(cdc) cdc.RegisterInterface((*GenesisAccount)(nil), nil) cdc.RegisterInterface((*Account)(nil), nil) cdc.RegisterConcrete(&BaseAccount{}, "cosmos-sdk/Account", nil) diff --git a/x/auth/legacy/v039/migrate_test.go b/x/auth/legacy/v039/migrate_test.go new file mode 100644 index 000000000..6972789c0 --- /dev/null +++ b/x/auth/legacy/v039/migrate_test.go @@ -0,0 +1,104 @@ +package v039_test + +import ( + "testing" + + "github.com/stretchr/testify/require" + + "github.com/cosmos/cosmos-sdk/codec" + "github.com/cosmos/cosmos-sdk/crypto/keys/ed25519" + "github.com/cosmos/cosmos-sdk/crypto/keys/secp256k1" + sdk "github.com/cosmos/cosmos-sdk/types" + v038auth "github.com/cosmos/cosmos-sdk/x/auth/legacy/v038" + v039auth "github.com/cosmos/cosmos-sdk/x/auth/legacy/v039" +) + +func TestMigrate(t *testing.T) { + aminoCdc := codec.NewLegacyAmino() + v039auth.RegisterLegacyAminoCodec(aminoCdc) + + pub1 := ed25519.GenPrivKeyFromSecret([]byte("acc1")).PubKey() + pub2 := secp256k1.GenPrivKeyFromSecret([]byte("acc2")).PubKey() + + acc1 := v038auth.BaseAccount{ + Address: sdk.AccAddress(pub1.Address()), + Coins: sdk.NewCoins(sdk.NewInt64Coin("stake", 400000)), + Sequence: 1, + AccountNumber: 1, + PubKey: pub1, + } + acc2 := v038auth.BaseAccount{ + Address: sdk.AccAddress(pub2.Address()), + Coins: sdk.NewCoins(sdk.NewInt64Coin("stake", 400000)), + Sequence: 2, + AccountNumber: 2, + PubKey: pub2, + } + + migrated := v039auth.Migrate( + v038auth.GenesisState{ + Accounts: v038auth.GenesisAccounts{&acc1, &acc2}, + }, + ) + + expectedAcc1 := v039auth.NewBaseAccount(acc1.Address, acc1.Coins, acc1.PubKey, acc1.AccountNumber, acc1.Sequence) + expectedAcc2 := v039auth.NewBaseAccount(acc2.Address, acc2.Coins, acc2.PubKey, acc2.AccountNumber, acc2.Sequence) + + require.Equal( + t, migrated, v039auth.GenesisState{ + Accounts: v038auth.GenesisAccounts{expectedAcc1, expectedAcc2}, + }, + ) + + json, err := aminoCdc.MarshalJSONIndent(migrated, "", " ") + require.NoError(t, err) + + expectedJSON := `{ + "params": { + "max_memo_characters": "0", + "tx_sig_limit": "0", + "tx_size_cost_per_byte": "0", + "sig_verify_cost_ed25519": "0", + "sig_verify_cost_secp256k1": "0" + }, + "accounts": [ + { + "type": "cosmos-sdk/Account", + "value": { + "address": "cosmos1j7skdhh9raxdmfhmcy2gxz8hgn0jnhfmujjsfe", + "coins": [ + { + "denom": "stake", + "amount": "400000" + } + ], + "public_key": { + "type": "tendermint/PubKeyEd25519", + "value": "eB0AcLMLKFRNFfh4XAAMstexfAIUQQCDnfjLZ2KJg+A=" + }, + "account_number": "1", + "sequence": "1" + } + }, + { + "type": "cosmos-sdk/Account", + "value": { + "address": "cosmos1v57fx2l2rt6ehujuu99u2fw05779m5e2ux4z2h", + "coins": [ + { + "denom": "stake", + "amount": "400000" + } + ], + "public_key": { + "type": "tendermint/PubKeySecp256k1", + "value": "AruDygh5HprMOpHOEato85dLgAsybMJVyxBGUa3KuWCr" + }, + "account_number": "2", + "sequence": "2" + } + } + ] +}` + require.Equal(t, expectedJSON, string(json)) +} diff --git a/x/auth/legacy/v039/types.go b/x/auth/legacy/v039/types.go index a75bc74a6..55c3014eb 100644 --- a/x/auth/legacy/v039/types.go +++ b/x/auth/legacy/v039/types.go @@ -9,10 +9,12 @@ import ( "fmt" "strings" - "github.com/tendermint/tendermint/crypto" + tmcrypto "github.com/tendermint/tendermint/crypto" "github.com/cosmos/cosmos-sdk/codec" "github.com/cosmos/cosmos-sdk/codec/legacy" + cryptocodec "github.com/cosmos/cosmos-sdk/crypto/codec" + cryptotypes "github.com/cosmos/cosmos-sdk/crypto/types" sdk "github.com/cosmos/cosmos-sdk/types" v034auth "github.com/cosmos/cosmos-sdk/x/auth/legacy/v034" v038auth "github.com/cosmos/cosmos-sdk/x/auth/legacy/v038" @@ -29,11 +31,11 @@ type ( } BaseAccount struct { - Address sdk.AccAddress `json:"address" yaml:"address"` - Coins sdk.Coins `json:"coins,omitempty" yaml:"coins,omitempty"` - PubKey crypto.PubKey `json:"public_key" yaml:"public_key"` - AccountNumber uint64 `json:"account_number" yaml:"account_number"` - Sequence uint64 `json:"sequence" yaml:"sequence"` + Address sdk.AccAddress `json:"address" yaml:"address"` + Coins sdk.Coins `json:"coins,omitempty" yaml:"coins,omitempty"` + PubKey cryptotypes.PubKey `json:"public_key" yaml:"public_key"` + AccountNumber uint64 `json:"account_number" yaml:"account_number"` + Sequence uint64 `json:"sequence" yaml:"sequence"` } BaseVestingAccount struct { @@ -47,15 +49,15 @@ type ( } vestingAccountJSON struct { - Address sdk.AccAddress `json:"address" yaml:"address"` - Coins sdk.Coins `json:"coins,omitempty" yaml:"coins"` - PubKey crypto.PubKey `json:"public_key" yaml:"public_key"` - AccountNumber uint64 `json:"account_number" yaml:"account_number"` - Sequence uint64 `json:"sequence" yaml:"sequence"` - OriginalVesting sdk.Coins `json:"original_vesting" yaml:"original_vesting"` - DelegatedFree sdk.Coins `json:"delegated_free" yaml:"delegated_free"` - DelegatedVesting sdk.Coins `json:"delegated_vesting" yaml:"delegated_vesting"` - EndTime int64 `json:"end_time" yaml:"end_time"` + Address sdk.AccAddress `json:"address" yaml:"address"` + Coins sdk.Coins `json:"coins,omitempty" yaml:"coins"` + PubKey cryptotypes.PubKey `json:"public_key" yaml:"public_key"` + AccountNumber uint64 `json:"account_number" yaml:"account_number"` + Sequence uint64 `json:"sequence" yaml:"sequence"` + OriginalVesting sdk.Coins `json:"original_vesting" yaml:"original_vesting"` + DelegatedFree sdk.Coins `json:"delegated_free" yaml:"delegated_free"` + DelegatedVesting sdk.Coins `json:"delegated_vesting" yaml:"delegated_vesting"` + EndTime int64 `json:"end_time" yaml:"end_time"` // custom fields based on concrete vesting type which can be omitted StartTime int64 `json:"start_time,omitempty" yaml:"start_time,omitempty"` @@ -117,7 +119,7 @@ func NewBaseAccountWithAddress(addr sdk.AccAddress) BaseAccount { } func NewBaseAccount( - address sdk.AccAddress, coins sdk.Coins, pk crypto.PubKey, accountNumber, sequence uint64, + address sdk.AccAddress, coins sdk.Coins, pk cryptotypes.PubKey, accountNumber, sequence uint64, ) *BaseAccount { return &BaseAccount{ @@ -380,7 +382,7 @@ func (ma ModuleAccount) Validate() error { return errors.New("module account name cannot be blank") } - if x := sdk.AccAddress(crypto.AddressHash([]byte(ma.Name))); !ma.Address.Equals(x) { + if x := sdk.AccAddress(tmcrypto.AddressHash([]byte(ma.Name))); !ma.Address.Equals(x) { return fmt.Errorf("address %s cannot be derived from the module name '%s'; expected: %s", ma.Address, ma.Name, x) } @@ -415,6 +417,7 @@ func (ma *ModuleAccount) UnmarshalJSON(bz []byte) error { } func RegisterLegacyAminoCodec(cdc *codec.LegacyAmino) { + cryptocodec.RegisterCrypto(cdc) cdc.RegisterInterface((*v038auth.GenesisAccount)(nil), nil) cdc.RegisterInterface((*v038auth.Account)(nil), nil) cdc.RegisterConcrete(&BaseAccount{}, "cosmos-sdk/Account", nil) diff --git a/x/auth/signing/sig_verifiable_tx.go b/x/auth/signing/sig_verifiable_tx.go index 6621d3fcb..8381ad491 100644 --- a/x/auth/signing/sig_verifiable_tx.go +++ b/x/auth/signing/sig_verifiable_tx.go @@ -1,8 +1,7 @@ package signing import ( - "github.com/tendermint/tendermint/crypto" - + cryptotypes "github.com/cosmos/cosmos-sdk/crypto/types" "github.com/cosmos/cosmos-sdk/types" "github.com/cosmos/cosmos-sdk/types/tx/signing" ) @@ -12,7 +11,7 @@ import ( type SigVerifiableTx interface { types.Tx GetSigners() []types.AccAddress - GetPubKeys() []crypto.PubKey // If signer already has pubkey in context, this list will have nil in its place + GetPubKeys() []cryptotypes.PubKey // If signer already has pubkey in context, this list will have nil in its place GetSignaturesV2() ([]signing.SignatureV2, error) } diff --git a/x/auth/signing/verify.go b/x/auth/signing/verify.go index 0e66f026f..5a5395de6 100644 --- a/x/auth/signing/verify.go +++ b/x/auth/signing/verify.go @@ -3,8 +3,7 @@ package signing import ( "fmt" - "github.com/tendermint/tendermint/crypto" - + cryptotypes "github.com/cosmos/cosmos-sdk/crypto/types" "github.com/cosmos/cosmos-sdk/crypto/types/multisig" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cosmos/cosmos-sdk/types/tx/signing" @@ -12,7 +11,7 @@ import ( // VerifySignature verifies a transaction signature contained in SignatureData abstracting over different signing modes // and single vs multi-signatures. -func VerifySignature(pubKey crypto.PubKey, signerData SignerData, sigData signing.SignatureData, handler SignModeHandler, tx sdk.Tx) error { +func VerifySignature(pubKey cryptotypes.PubKey, signerData SignerData, sigData signing.SignatureData, handler SignModeHandler, tx sdk.Tx) error { switch data := sigData.(type) { case *signing.SingleSignatureData: signBytes, err := handler.GetSignBytes(data.SignMode, signerData, tx) diff --git a/x/auth/signing/verify_test.go b/x/auth/signing/verify_test.go index f0929c76c..7e842d135 100644 --- a/x/auth/signing/verify_test.go +++ b/x/auth/signing/verify_test.go @@ -4,11 +4,11 @@ import ( "testing" "github.com/stretchr/testify/require" - "github.com/tendermint/tendermint/crypto" tmproto "github.com/tendermint/tendermint/proto/tendermint/types" "github.com/cosmos/cosmos-sdk/codec" kmultisig "github.com/cosmos/cosmos-sdk/crypto/keys/multisig" + cryptotypes "github.com/cosmos/cosmos-sdk/crypto/types" "github.com/cosmos/cosmos-sdk/crypto/types/multisig" "github.com/cosmos/cosmos-sdk/simapp" "github.com/cosmos/cosmos-sdk/testutil/testdata" @@ -65,7 +65,7 @@ func TestVerifySignature(t *testing.T) { err = signing.VerifySignature(pubKey, signerData, sigV2.Data, handler, stdTx) require.NoError(t, err) - pkSet := []crypto.PubKey{pubKey, pubKey1} + pkSet := []cryptotypes.PubKey{pubKey, pubKey1} multisigKey := kmultisig.NewLegacyAminoPubKey(2, pkSet) multisignature := multisig.NewMultisig(2) msgs = []sdk.Msg{testdata.NewTestMsg(addr, addr1)} diff --git a/x/auth/testutil/suite.go b/x/auth/testutil/suite.go index 518e502de..f8002e68e 100644 --- a/x/auth/testutil/suite.go +++ b/x/auth/testutil/suite.go @@ -4,10 +4,10 @@ import ( "bytes" "github.com/stretchr/testify/suite" - "github.com/tendermint/tendermint/crypto" "github.com/cosmos/cosmos-sdk/client" kmultisig "github.com/cosmos/cosmos-sdk/crypto/keys/multisig" + cryptotypes "github.com/cosmos/cosmos-sdk/crypto/types" "github.com/cosmos/cosmos-sdk/crypto/types/multisig" "github.com/cosmos/cosmos-sdk/testutil/testdata" sdk "github.com/cosmos/cosmos-sdk/types" @@ -81,7 +81,7 @@ func (s *TxConfigTestSuite) TestTxBuilderSetMsgs() { func (s *TxConfigTestSuite) TestTxBuilderSetSignatures() { privKey, pubkey, addr := testdata.KeyTestPubAddr() privKey2, pubkey2, _ := testdata.KeyTestPubAddr() - multisigPk := kmultisig.NewLegacyAminoPubKey(2, []crypto.PubKey{pubkey, pubkey2}) + multisigPk := kmultisig.NewLegacyAminoPubKey(2, []cryptotypes.PubKey{pubkey, pubkey2}) txBuilder := s.TxConfig.NewTxBuilder() @@ -268,7 +268,7 @@ func (s *TxConfigTestSuite) TestTxEncodeDecode() { tx3Sigs, err := tx3.GetSignaturesV2() s.Require().NoError(err) s.Require().Equal([]signingtypes.SignatureV2{sig}, tx3Sigs) - s.Require().Equal([]crypto.PubKey{pubkey}, tx3.GetPubKeys()) + s.Require().Equal([]cryptotypes.PubKey{pubkey}, tx3.GetPubKeys()) log("JSON encode transaction") jsonTxBytes, err := s.TxConfig.TxJSONEncoder()(tx) @@ -287,7 +287,7 @@ func (s *TxConfigTestSuite) TestTxEncodeDecode() { tx3Sigs, err = tx3.GetSignaturesV2() s.Require().NoError(err) s.Require().Equal([]signingtypes.SignatureV2{sig}, tx3Sigs) - s.Require().Equal([]crypto.PubKey{pubkey}, tx3.GetPubKeys()) + s.Require().Equal([]cryptotypes.PubKey{pubkey}, tx3.GetPubKeys()) } func (s *TxConfigTestSuite) TestWrapTxBuilder() { diff --git a/x/auth/tx/builder.go b/x/auth/tx/builder.go index b3697e70b..4c76d529a 100644 --- a/x/auth/tx/builder.go +++ b/x/auth/tx/builder.go @@ -1,15 +1,12 @@ package tx import ( - "fmt" - "github.com/gogo/protobuf/proto" - "github.com/tendermint/tendermint/crypto" "github.com/cosmos/cosmos-sdk/client" codectypes "github.com/cosmos/cosmos-sdk/codec/types" + cryptotypes "github.com/cosmos/cosmos-sdk/crypto/types" sdk "github.com/cosmos/cosmos-sdk/types" - sdkerrors "github.com/cosmos/cosmos-sdk/types/errors" "github.com/cosmos/cosmos-sdk/types/tx" "github.com/cosmos/cosmos-sdk/types/tx/signing" "github.com/cosmos/cosmos-sdk/x/auth/ante" @@ -103,9 +100,9 @@ func (w *wrapper) GetSigners() []sdk.AccAddress { return w.tx.GetSigners() } -func (w *wrapper) GetPubKeys() []crypto.PubKey { +func (w *wrapper) GetPubKeys() []cryptotypes.PubKey { signerInfos := w.tx.AuthInfo.SignerInfos - pks := make([]crypto.PubKey, len(signerInfos)) + pks := make([]cryptotypes.PubKey, len(signerInfos)) for i, si := range signerInfos { // NOTE: it is okay to leave this nil if there is no PubKey in the SignerInfo. @@ -114,7 +111,7 @@ func (w *wrapper) GetPubKeys() []crypto.PubKey { continue } - pk, ok := si.PublicKey.GetCachedValue().(crypto.PubKey) + pk, ok := si.PublicKey.GetCachedValue().(cryptotypes.PubKey) if ok { pks[i] = pk } @@ -366,11 +363,7 @@ func (w *wrapper) SetNonCriticalExtensionOptions(extOpts ...*codectypes.Any) { w.bodyBz = nil } -// PubKeyToAny converts a crypto.PubKey to a proto Any. -func PubKeyToAny(key crypto.PubKey) (*codectypes.Any, error) { - protoMsg, ok := key.(proto.Message) - if !ok { - return nil, sdkerrors.Wrap(sdkerrors.ErrInvalidPubKey, fmt.Sprintf("can't proto encode %T", protoMsg)) - } - return codectypes.NewAnyWithValue(protoMsg) +// PubKeyToAny converts a cryptotypes.PubKey to a proto Any. +func PubKeyToAny(key cryptotypes.PubKey) (*codectypes.Any, error) { + return codectypes.NewAnyWithValue(key) } diff --git a/x/auth/tx/sigs.go b/x/auth/tx/sigs.go index d0e43ede7..b40935b4b 100644 --- a/x/auth/tx/sigs.go +++ b/x/auth/tx/sigs.go @@ -3,10 +3,8 @@ package tx import ( "fmt" - "github.com/tendermint/tendermint/crypto" - "github.com/cosmos/cosmos-sdk/codec" - "github.com/cosmos/cosmos-sdk/crypto/types" + cryptotypes "github.com/cosmos/cosmos-sdk/crypto/types" "github.com/cosmos/cosmos-sdk/types/tx" "github.com/cosmos/cosmos-sdk/types/tx/signing" ) @@ -33,7 +31,7 @@ func SignatureDataToModeInfoAndSig(data signing.SignatureData) (*tx.ModeInfo, [] modeInfos[i], sigs[i] = SignatureDataToModeInfoAndSig(d) } - multisig := types.MultiSignature{ + multisig := cryptotypes.MultiSignature{ Signatures: sigs, } sig, err := multisig.Marshal() @@ -92,7 +90,7 @@ func ModeInfoAndSigToSignatureData(modeInfo *tx.ModeInfo, sig []byte) (signing.S // decodeMultisignatures safely decodes the the raw bytes as a MultiSignature protobuf message func decodeMultisignatures(bz []byte) ([][]byte, error) { - multisig := types.MultiSignature{} + multisig := cryptotypes.MultiSignature{} err := multisig.Unmarshal(bz) if err != nil { return nil, err @@ -137,7 +135,7 @@ func (g config) UnmarshalSignatureJSON(bz []byte) ([]signing.SignatureV2, error) sigs := make([]signing.SignatureV2, len(sigDescs.Signatures)) for i, desc := range sigDescs.Signatures { - pubKey, _ := desc.PublicKey.GetCachedValue().(crypto.PubKey) + pubKey, _ := desc.PublicKey.GetCachedValue().(cryptotypes.PubKey) data := signing.SignatureDataFromProto(desc.Data) diff --git a/x/auth/types/account.go b/x/auth/types/account.go index 476e607c4..532b80d30 100644 --- a/x/auth/types/account.go +++ b/x/auth/types/account.go @@ -13,6 +13,7 @@ import ( "github.com/cosmos/cosmos-sdk/codec" codectypes "github.com/cosmos/cosmos-sdk/codec/types" + cryptotypes "github.com/cosmos/cosmos-sdk/crypto/types" sdk "github.com/cosmos/cosmos-sdk/types" ) @@ -26,7 +27,7 @@ var ( // NewBaseAccount creates a new BaseAccount object //nolint:interfacer -func NewBaseAccount(address sdk.AccAddress, pubKey crypto.PubKey, accountNumber, sequence uint64) *BaseAccount { +func NewBaseAccount(address sdk.AccAddress, pubKey cryptotypes.PubKey, accountNumber, sequence uint64) *BaseAccount { acc := &BaseAccount{ Address: address.String(), AccountNumber: accountNumber, @@ -70,11 +71,11 @@ func (acc *BaseAccount) SetAddress(addr sdk.AccAddress) error { } // GetPubKey - Implements sdk.AccountI. -func (acc BaseAccount) GetPubKey() (pk crypto.PubKey) { +func (acc BaseAccount) GetPubKey() (pk cryptotypes.PubKey) { if acc.PubKey == nil { return nil } - content, ok := acc.PubKey.GetCachedValue().(crypto.PubKey) + content, ok := acc.PubKey.GetCachedValue().(cryptotypes.PubKey) if !ok { return nil } @@ -82,7 +83,7 @@ func (acc BaseAccount) GetPubKey() (pk crypto.PubKey) { } // SetPubKey - Implements sdk.AccountI. -func (acc *BaseAccount) SetPubKey(pubKey crypto.PubKey) error { +func (acc *BaseAccount) SetPubKey(pubKey cryptotypes.PubKey) error { any, err := codectypes.PackAny(pubKey) if err != nil { return err @@ -150,7 +151,7 @@ func (acc BaseAccount) UnpackInterfaces(unpacker codectypes.AnyUnpacker) error { if acc.PubKey == nil { return nil } - var pubKey crypto.PubKey + var pubKey cryptotypes.PubKey return unpacker.UnpackAny(acc.PubKey, &pubKey) } @@ -209,7 +210,7 @@ func (ma ModuleAccount) GetPermissions() []string { } // SetPubKey - Implements AccountI -func (ma ModuleAccount) SetPubKey(pubKey crypto.PubKey) error { +func (ma ModuleAccount) SetPubKey(pubKey cryptotypes.PubKey) error { return fmt.Errorf("not supported for module accounts") } @@ -311,8 +312,8 @@ type AccountI interface { GetAddress() sdk.AccAddress SetAddress(sdk.AccAddress) error // errors if already set. - GetPubKey() crypto.PubKey // can return nil. - SetPubKey(crypto.PubKey) error + GetPubKey() cryptotypes.PubKey // can return nil. + SetPubKey(cryptotypes.PubKey) error GetAccountNumber() uint64 SetAccountNumber(uint64) error diff --git a/x/auth/vesting/types/test_common.go b/x/auth/vesting/types/test_common.go index 347faba04..0e22ea235 100644 --- a/x/auth/vesting/types/test_common.go +++ b/x/auth/vesting/types/test_common.go @@ -1,9 +1,8 @@ package types import ( - "github.com/tendermint/tendermint/crypto" - "github.com/cosmos/cosmos-sdk/crypto/keys/secp256k1" + cryptotypes "github.com/cosmos/cosmos-sdk/crypto/types" "github.com/cosmos/cosmos-sdk/testutil/testdata" sdk "github.com/cosmos/cosmos-sdk/types" @@ -22,7 +21,7 @@ func NewTestCoins() sdk.Coins { } // KeyTestPubAddr generates a test key pair -func KeyTestPubAddr() (crypto.PrivKey, crypto.PubKey, sdk.AccAddress) { +func KeyTestPubAddr() (cryptotypes.PrivKey, cryptotypes.PubKey, sdk.AccAddress) { key := secp256k1.GenPrivKey() pub := key.PubKey() addr := sdk.AccAddress(pub.Address()) diff --git a/x/bank/app_test.go b/x/bank/app_test.go index 713aa0999..82d898b09 100644 --- a/x/bank/app_test.go +++ b/x/bank/app_test.go @@ -4,10 +4,10 @@ import ( "testing" "github.com/stretchr/testify/require" - "github.com/tendermint/tendermint/crypto" tmproto "github.com/tendermint/tendermint/proto/tendermint/types" "github.com/cosmos/cosmos-sdk/crypto/keys/secp256k1" + cryptotypes "github.com/cosmos/cosmos-sdk/crypto/types" "github.com/cosmos/cosmos-sdk/simapp" sdk "github.com/cosmos/cosmos-sdk/types" authtypes "github.com/cosmos/cosmos-sdk/x/auth/types" @@ -28,7 +28,7 @@ type ( msgs []sdk.Msg accNums []uint64 accSeqs []uint64 - privKeys []crypto.PrivKey + privKeys []cryptotypes.PrivKey expectedBalances []expectedBalance } ) @@ -228,7 +228,7 @@ func TestMsgMultiSendWithAccounts(t *testing.T) { accSeqs: []uint64{0}, expSimPass: true, expPass: true, - privKeys: []crypto.PrivKey{priv1}, + privKeys: []cryptotypes.PrivKey{priv1}, expectedBalances: []expectedBalance{ {addr1, sdk.Coins{sdk.NewInt64Coin("foocoin", 57)}}, {addr2, sdk.Coins{sdk.NewInt64Coin("foocoin", 10)}}, @@ -241,7 +241,7 @@ func TestMsgMultiSendWithAccounts(t *testing.T) { accSeqs: []uint64{1}, expSimPass: true, // doesn't check signature expPass: false, - privKeys: []crypto.PrivKey{priv1}, + privKeys: []cryptotypes.PrivKey{priv1}, }, { desc: "wrong accSeq should not pass Simulate", @@ -250,7 +250,7 @@ func TestMsgMultiSendWithAccounts(t *testing.T) { accSeqs: []uint64{0}, // wrong account sequence expSimPass: false, expPass: false, - privKeys: []crypto.PrivKey{priv1}, + privKeys: []cryptotypes.PrivKey{priv1}, }, } @@ -297,7 +297,7 @@ func TestMsgMultiSendMultipleOut(t *testing.T) { accSeqs: []uint64{0}, expSimPass: true, expPass: true, - privKeys: []crypto.PrivKey{priv1}, + privKeys: []cryptotypes.PrivKey{priv1}, expectedBalances: []expectedBalance{ {addr1, sdk.Coins{sdk.NewInt64Coin("foocoin", 32)}}, {addr2, sdk.Coins{sdk.NewInt64Coin("foocoin", 47)}}, @@ -351,7 +351,7 @@ func TestMsgMultiSendMultipleInOut(t *testing.T) { accSeqs: []uint64{0, 0}, expSimPass: true, expPass: true, - privKeys: []crypto.PrivKey{priv1, priv4}, + privKeys: []cryptotypes.PrivKey{priv1, priv4}, expectedBalances: []expectedBalance{ {addr1, sdk.Coins{sdk.NewInt64Coin("foocoin", 32)}}, {addr4, sdk.Coins{sdk.NewInt64Coin("foocoin", 32)}}, @@ -395,7 +395,7 @@ func TestMsgMultiSendDependent(t *testing.T) { accSeqs: []uint64{0}, expSimPass: true, expPass: true, - privKeys: []crypto.PrivKey{priv1}, + privKeys: []cryptotypes.PrivKey{priv1}, expectedBalances: []expectedBalance{ {addr1, sdk.Coins{sdk.NewInt64Coin("foocoin", 32)}}, {addr2, sdk.Coins{sdk.NewInt64Coin("foocoin", 10)}}, @@ -407,7 +407,7 @@ func TestMsgMultiSendDependent(t *testing.T) { accSeqs: []uint64{0}, expSimPass: true, expPass: true, - privKeys: []crypto.PrivKey{priv2}, + privKeys: []cryptotypes.PrivKey{priv2}, expectedBalances: []expectedBalance{ {addr1, sdk.Coins{sdk.NewInt64Coin("foocoin", 42)}}, }, diff --git a/x/bank/simulation/operations.go b/x/bank/simulation/operations.go index c1e64d80d..9fcc80f0f 100644 --- a/x/bank/simulation/operations.go +++ b/x/bank/simulation/operations.go @@ -3,10 +3,9 @@ package simulation import ( "math/rand" - "github.com/tendermint/tendermint/crypto" - "github.com/cosmos/cosmos-sdk/baseapp" "github.com/cosmos/cosmos-sdk/codec" + cryptotypes "github.com/cosmos/cosmos-sdk/crypto/types" "github.com/cosmos/cosmos-sdk/simapp/helpers" simappparams "github.com/cosmos/cosmos-sdk/simapp/params" sdk "github.com/cosmos/cosmos-sdk/types" @@ -72,7 +71,7 @@ func SimulateMsgSend(ak types.AccountKeeper, bk keeper.Keeper) simtypes.Operatio msg := types.NewMsgSend(simAccount.Address, toSimAcc.Address, coins) - err := sendMsgSend(r, app, bk, ak, msg, ctx, chainID, []crypto.PrivKey{simAccount.PrivKey}) + err := sendMsgSend(r, app, bk, ak, msg, ctx, chainID, []cryptotypes.PrivKey{simAccount.PrivKey}) if err != nil { return simtypes.NoOpMsg(types.ModuleName, msg.Type(), "invalid transfers"), nil, err } @@ -85,7 +84,7 @@ func SimulateMsgSend(ak types.AccountKeeper, bk keeper.Keeper) simtypes.Operatio // nolint: interfacer func sendMsgSend( r *rand.Rand, app *baseapp.BaseApp, bk keeper.Keeper, ak types.AccountKeeper, - msg *types.MsgSend, ctx sdk.Context, chainID string, privkeys []crypto.PrivKey, + msg *types.MsgSend, ctx sdk.Context, chainID string, privkeys []cryptotypes.PrivKey, ) error { var ( @@ -144,7 +143,7 @@ func SimulateMsgMultiSend(ak types.AccountKeeper, bk keeper.Keeper) simtypes.Ope outputs := make([]types.Output, r.Intn(3)+1) // collect signer privKeys - privs := make([]crypto.PrivKey, len(inputs)) + privs := make([]cryptotypes.PrivKey, len(inputs)) // use map to check if address already exists as input usedAddrs := make(map[string]bool) @@ -227,7 +226,7 @@ func SimulateMsgMultiSend(ak types.AccountKeeper, bk keeper.Keeper) simtypes.Ope // nolint: interfacer func sendMsgMultiSend( r *rand.Rand, app *baseapp.BaseApp, bk keeper.Keeper, ak types.AccountKeeper, - msg *types.MsgMultiSend, ctx sdk.Context, chainID string, privkeys []crypto.PrivKey, + msg *types.MsgMultiSend, ctx sdk.Context, chainID string, privkeys []cryptotypes.PrivKey, ) error { accountNumbers := make([]uint64, len(msg.Inputs)) diff --git a/x/distribution/types/common_test.go b/x/distribution/types/common_test.go index a8301b4e4..4e6ef6b01 100644 --- a/x/distribution/types/common_test.go +++ b/x/distribution/types/common_test.go @@ -1,9 +1,8 @@ package types import ( - "github.com/tendermint/tendermint/crypto" - "github.com/cosmos/cosmos-sdk/crypto/keys/ed25519" + cryptotypes "github.com/cosmos/cosmos-sdk/crypto/types" sdk "github.com/cosmos/cosmos-sdk/types" ) @@ -25,5 +24,5 @@ var ( valAddr3 = sdk.ValAddress(valPk3.Address()) emptyValAddr sdk.ValAddress - emptyPubkey crypto.PubKey + emptyPubkey cryptotypes.PubKey ) diff --git a/x/evidence/keeper/keeper_test.go b/x/evidence/keeper/keeper_test.go index 65e52b30e..916573046 100644 --- a/x/evidence/keeper/keeper_test.go +++ b/x/evidence/keeper/keeper_test.go @@ -6,11 +6,11 @@ import ( "time" "github.com/stretchr/testify/suite" - "github.com/tendermint/tendermint/crypto" tmproto "github.com/tendermint/tendermint/proto/tendermint/types" "github.com/cosmos/cosmos-sdk/baseapp" "github.com/cosmos/cosmos-sdk/crypto/keys/ed25519" + cryptotypes "github.com/cosmos/cosmos-sdk/crypto/types" "github.com/cosmos/cosmos-sdk/simapp" sdk "github.com/cosmos/cosmos-sdk/types" authtypes "github.com/cosmos/cosmos-sdk/x/auth/types" @@ -22,7 +22,7 @@ import ( ) var ( - pubkeys = []crypto.PubKey{ + pubkeys = []cryptotypes.PubKey{ newPubKey("0B485CFC0EECC619440448436F8FC9DF40566F2369E72400281454CB552AFB50"), newPubKey("0B485CFC0EECC619440448436F8FC9DF40566F2369E72400281454CB552AFB51"), newPubKey("0B485CFC0EECC619440448436F8FC9DF40566F2369E72400281454CB552AFB52"), @@ -38,7 +38,7 @@ var ( initCoins = sdk.NewCoins(sdk.NewCoin(sdk.DefaultBondDenom, initAmt)) ) -func newPubKey(pk string) (res crypto.PubKey) { +func newPubKey(pk string) (res cryptotypes.PubKey) { pkBytes, err := hex.DecodeString(pk) if err != nil { panic(err) diff --git a/x/evidence/types/expected_keepers.go b/x/evidence/types/expected_keepers.go index 23c9b40bd..0f1d87774 100644 --- a/x/evidence/types/expected_keepers.go +++ b/x/evidence/types/expected_keepers.go @@ -3,8 +3,7 @@ package types import ( "time" - "github.com/tendermint/tendermint/crypto" - + cryptotypes "github.com/cosmos/cosmos-sdk/crypto/types" sdk "github.com/cosmos/cosmos-sdk/types" stakingtypes "github.com/cosmos/cosmos-sdk/x/staking/types" ) @@ -19,7 +18,7 @@ type ( // SlashingKeeper defines the slashing module interface contract needed by the // evidence module. SlashingKeeper interface { - GetPubkey(sdk.Context, crypto.Address) (crypto.PubKey, error) + GetPubkey(sdk.Context, cryptotypes.Address) (cryptotypes.PubKey, error) IsTombstoned(sdk.Context, sdk.ConsAddress) bool HasValidatorSigningInfo(sdk.Context, sdk.ConsAddress) bool Tombstone(sdk.Context, sdk.ConsAddress) diff --git a/x/genutil/legacy/v038/migrate.go b/x/genutil/legacy/v038/migrate.go index cd71f57b1..374092298 100644 --- a/x/genutil/legacy/v038/migrate.go +++ b/x/genutil/legacy/v038/migrate.go @@ -3,7 +3,6 @@ package v038 import ( "github.com/cosmos/cosmos-sdk/client" "github.com/cosmos/cosmos-sdk/codec" - cryptocodec "github.com/cosmos/cosmos-sdk/crypto/codec" v036auth "github.com/cosmos/cosmos-sdk/x/auth/legacy/v036" v038auth "github.com/cosmos/cosmos-sdk/x/auth/legacy/v038" v036distr "github.com/cosmos/cosmos-sdk/x/distribution/legacy/v036" @@ -18,12 +17,10 @@ import ( // Migrate migrates exported state from v0.36/v0.37 to a v0.38 genesis state. func Migrate(appState types.AppMap, _ client.Context) types.AppMap { v036Codec := codec.NewLegacyAmino() - cryptocodec.RegisterCrypto(v036Codec) v036gov.RegisterLegacyAminoCodec(v036Codec) v036distr.RegisterLegacyAminoCodec(v036Codec) v038Codec := codec.NewLegacyAmino() - cryptocodec.RegisterCrypto(v038Codec) v038auth.RegisterLegacyAminoCodec(v038Codec) v036gov.RegisterLegacyAminoCodec(v038Codec) v036distr.RegisterLegacyAminoCodec(v038Codec) diff --git a/x/genutil/legacy/v039/migrate.go b/x/genutil/legacy/v039/migrate.go index bf112c152..97442e938 100644 --- a/x/genutil/legacy/v039/migrate.go +++ b/x/genutil/legacy/v039/migrate.go @@ -3,7 +3,6 @@ package v039 import ( "github.com/cosmos/cosmos-sdk/client" "github.com/cosmos/cosmos-sdk/codec" - cryptocodec "github.com/cosmos/cosmos-sdk/crypto/codec" v038auth "github.com/cosmos/cosmos-sdk/x/auth/legacy/v038" v039auth "github.com/cosmos/cosmos-sdk/x/auth/legacy/v039" v036distr "github.com/cosmos/cosmos-sdk/x/distribution/legacy/v036" @@ -17,13 +16,11 @@ import ( // serialization of accounts do change. func Migrate(appState types.AppMap, _ client.Context) types.AppMap { v038Codec := codec.NewLegacyAmino() - cryptocodec.RegisterCrypto(v038Codec) v038auth.RegisterLegacyAminoCodec(v038Codec) v036gov.RegisterLegacyAminoCodec(v038Codec) v036distr.RegisterLegacyAminoCodec(v038Codec) v039Codec := codec.NewLegacyAmino() - cryptocodec.RegisterCrypto(v039Codec) v039auth.RegisterLegacyAminoCodec(v039Codec) v036gov.RegisterLegacyAminoCodec(v039Codec) v036distr.RegisterLegacyAminoCodec(v039Codec) diff --git a/x/genutil/types/types.go b/x/genutil/types/types.go index d902d8ccb..694eebdbe 100644 --- a/x/genutil/types/types.go +++ b/x/genutil/types/types.go @@ -3,9 +3,8 @@ package types import ( "encoding/json" - "github.com/tendermint/tendermint/crypto" - "github.com/cosmos/cosmos-sdk/client" + cryptotypes "github.com/cosmos/cosmos-sdk/crypto/types" ) // DONTCOVER @@ -32,11 +31,11 @@ type InitConfig struct { ChainID string GenTxsDir string NodeID string - ValPubKey crypto.PubKey + ValPubKey cryptotypes.PubKey } // NewInitConfig creates a new InitConfig object -func NewInitConfig(chainID, genTxsDir, nodeID string, valPubKey crypto.PubKey) InitConfig { +func NewInitConfig(chainID, genTxsDir, nodeID string, valPubKey cryptotypes.PubKey) InitConfig { return InitConfig{ ChainID: chainID, GenTxsDir: genTxsDir, diff --git a/x/genutil/utils.go b/x/genutil/utils.go index 5eea11718..14ac11f53 100644 --- a/x/genutil/utils.go +++ b/x/genutil/utils.go @@ -6,13 +6,13 @@ import ( "time" cfg "github.com/tendermint/tendermint/config" - "github.com/tendermint/tendermint/crypto" tmos "github.com/tendermint/tendermint/libs/os" "github.com/tendermint/tendermint/p2p" "github.com/tendermint/tendermint/privval" tmtypes "github.com/tendermint/tendermint/types" - "github.com/cosmos/cosmos-sdk/crypto/keys/ed25519" + cryptocodec "github.com/cosmos/cosmos-sdk/crypto/codec" + cryptotypes "github.com/cosmos/cosmos-sdk/crypto/types" ) // ExportGenesisFile creates and writes the genesis configuration to disk. An @@ -47,7 +47,7 @@ func ExportGenesisFileWithTime( } // InitializeNodeValidatorFiles creates private validator and p2p configuration files. -func InitializeNodeValidatorFiles(config *cfg.Config) (nodeID string, valPubKey crypto.PubKey, err error) { +func InitializeNodeValidatorFiles(config *cfg.Config) (nodeID string, valPubKey cryptotypes.PubKey, err error) { nodeKey, err := p2p.LoadOrGenNodeKey(config.NodeKeyFile()) if err != nil { return "", nil, err @@ -70,7 +70,7 @@ func InitializeNodeValidatorFiles(config *cfg.Config) (nodeID string, valPubKey return "", nil, err } - valPubKey, err = ed25519.FromTmEd25519(tmValPubKey) + valPubKey, err = cryptocodec.FromTmPubKeyInterface(tmValPubKey) if err != nil { return "", nil, err } diff --git a/x/gov/common_test.go b/x/gov/common_test.go index d8648b478..5ef50ea5d 100644 --- a/x/gov/common_test.go +++ b/x/gov/common_test.go @@ -7,9 +7,9 @@ import ( "testing" "github.com/stretchr/testify/require" - "github.com/tendermint/tendermint/crypto" "github.com/cosmos/cosmos-sdk/crypto/keys/ed25519" + cryptotypes "github.com/cosmos/cosmos-sdk/crypto/types" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cosmos/cosmos-sdk/x/gov/types" stakingtypes "github.com/cosmos/cosmos-sdk/x/staking/types" @@ -71,7 +71,7 @@ func SortByteArrays(src [][]byte) [][]byte { const contextKeyBadProposal = "contextKeyBadProposal" var ( - pubkeys = []crypto.PubKey{ + pubkeys = []cryptotypes.PubKey{ ed25519.GenPrivKey().PubKey(), ed25519.GenPrivKey().PubKey(), ed25519.GenPrivKey().PubKey(), diff --git a/x/gov/keeper/tally_test.go b/x/gov/keeper/tally_test.go index 6c23a510e..77f468cd2 100644 --- a/x/gov/keeper/tally_test.go +++ b/x/gov/keeper/tally_test.go @@ -410,9 +410,9 @@ func TestTallyJailedValidator(t *testing.T) { _ = staking.EndBlocker(ctx, app.StakingKeeper) - consKey, err := val2.TmConsPubKey() + consAddr, err := val2.GetConsAddr() require.NoError(t, err) - app.StakingKeeper.Jail(ctx, sdk.ConsAddress(consKey.Address())) + app.StakingKeeper.Jail(ctx, sdk.ConsAddress(consAddr.Bytes())) tp := TestProposal proposal, err := app.GovKeeper.SubmitProposal(ctx, tp) diff --git a/x/ibc/core/02-client/keeper/client_test.go b/x/ibc/core/02-client/keeper/client_test.go index 31cf5d80f..30528b88c 100644 --- a/x/ibc/core/02-client/keeper/client_test.go +++ b/x/ibc/core/02-client/keeper/client_test.go @@ -6,7 +6,6 @@ import ( tmtypes "github.com/tendermint/tendermint/types" - cryptotypes "github.com/cosmos/cosmos-sdk/crypto/types" "github.com/cosmos/cosmos-sdk/x/ibc/core/02-client/types" clienttypes "github.com/cosmos/cosmos-sdk/x/ibc/core/02-client/types" commitmenttypes "github.com/cosmos/cosmos-sdk/x/ibc/core/23-commitment/types" @@ -379,7 +378,7 @@ func (suite *KeeperTestSuite) TestCheckMisbehaviourAndUpdateState() { altPrivVal := ibctestingmock.NewPV() altPubKey, err := altPrivVal.GetPubKey() suite.Require().NoError(err) - altVal := tmtypes.NewValidator(altPubKey.(cryptotypes.IntoTmPubKey).AsTmPubKey(), 4) + altVal := tmtypes.NewValidator(altPubKey, 4) // Set valSet here with suite.valSet so it doesn't get reset on each testcase valSet := suite.valSet diff --git a/x/ibc/core/02-client/keeper/keeper_test.go b/x/ibc/core/02-client/keeper/keeper_test.go index 24675f4e9..d5e162b09 100644 --- a/x/ibc/core/02-client/keeper/keeper_test.go +++ b/x/ibc/core/02-client/keeper/keeper_test.go @@ -12,7 +12,7 @@ import ( "github.com/cosmos/cosmos-sdk/baseapp" "github.com/cosmos/cosmos-sdk/codec" - cryptotypes "github.com/cosmos/cosmos-sdk/crypto/types" + cryptocodec "github.com/cosmos/cosmos-sdk/crypto/codec" "github.com/cosmos/cosmos-sdk/simapp" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cosmos/cosmos-sdk/x/ibc/core/02-client/keeper" @@ -91,7 +91,7 @@ func (suite *KeeperTestSuite) SetupTest() { testClientHeightMinus1 := types.NewHeight(0, height-1) - validator := tmtypes.NewValidator(pubKey.(cryptotypes.IntoTmPubKey).AsTmPubKey(), 1) + validator := tmtypes.NewValidator(pubKey, 1) suite.valSet = tmtypes.NewValidatorSet([]*tmtypes.Validator{validator}) suite.valSetHash = suite.valSet.Hash() suite.header = suite.chainA.CreateTMClientHeader(testChainID, int64(testClientHeight.VersionHeight), testClientHeightMinus1, now2, suite.valSet, suite.valSet, []tmtypes.PrivValidator{suite.privVal}) @@ -100,7 +100,9 @@ func (suite *KeeperTestSuite) SetupTest() { var validators stakingtypes.Validators for i := 1; i < 11; i++ { privVal := ibctestingmock.NewPV() - pk, err := privVal.GetPubKey() + tmPk, err := privVal.GetPubKey() + suite.Require().NoError(err) + pk, err := cryptocodec.FromTmPubKeyInterface(tmPk) suite.Require().NoError(err) val, err := stakingtypes.NewValidator(sdk.ValAddress(pk.Address()), pk, stakingtypes.Description{}) suite.Require().NoError(err) diff --git a/x/ibc/core/02-client/types/genesis_test.go b/x/ibc/core/02-client/types/genesis_test.go index 1de910335..41d88edae 100644 --- a/x/ibc/core/02-client/types/genesis_test.go +++ b/x/ibc/core/02-client/types/genesis_test.go @@ -5,7 +5,6 @@ import ( tmtypes "github.com/tendermint/tendermint/types" - cryptotypes "github.com/cosmos/cosmos-sdk/crypto/types" client "github.com/cosmos/cosmos-sdk/x/ibc/core/02-client" "github.com/cosmos/cosmos-sdk/x/ibc/core/02-client/types" channeltypes "github.com/cosmos/cosmos-sdk/x/ibc/core/04-channel/types" @@ -49,7 +48,7 @@ func (suite *TypesTestSuite) TestValidateGenesis() { now := time.Now().UTC() - val := tmtypes.NewValidator(pubKey.(cryptotypes.IntoTmPubKey).AsTmPubKey(), 10) + val := tmtypes.NewValidator(pubKey, 10) valSet := tmtypes.NewValidatorSet([]*tmtypes.Validator{val}) heightMinus1 := types.NewHeight(0, height-1) diff --git a/x/ibc/light-clients/06-solomachine/types/consensus_state.go b/x/ibc/light-clients/06-solomachine/types/consensus_state.go index f912aa350..2b637a7ad 100644 --- a/x/ibc/light-clients/06-solomachine/types/consensus_state.go +++ b/x/ibc/light-clients/06-solomachine/types/consensus_state.go @@ -3,8 +3,7 @@ package types import ( "strings" - tmcrypto "github.com/tendermint/tendermint/crypto" - + cryptotypes "github.com/cosmos/cosmos-sdk/crypto/types" sdkerrors "github.com/cosmos/cosmos-sdk/types/errors" clienttypes "github.com/cosmos/cosmos-sdk/x/ibc/core/02-client/types" "github.com/cosmos/cosmos-sdk/x/ibc/core/exported" @@ -27,11 +26,11 @@ func (cs ConsensusState) GetRoot() exported.Root { return nil } -// GetPubKey unmarshals the public key into a tmcrypto.PubKey type. -func (cs ConsensusState) GetPubKey() tmcrypto.PubKey { - publicKey, ok := cs.PublicKey.GetCachedValue().(tmcrypto.PubKey) +// GetPubKey unmarshals the public key into a cryptotypes.PubKey type. +func (cs ConsensusState) GetPubKey() cryptotypes.PubKey { + publicKey, ok := cs.PublicKey.GetCachedValue().(cryptotypes.PubKey) if !ok { - panic("ConsensusState PublicKey is not crypto.PubKey") + panic("ConsensusState PublicKey is not cryptotypes.PubKey") } return publicKey diff --git a/x/ibc/light-clients/06-solomachine/types/header.go b/x/ibc/light-clients/06-solomachine/types/header.go index a4f757a37..e833a7020 100644 --- a/x/ibc/light-clients/06-solomachine/types/header.go +++ b/x/ibc/light-clients/06-solomachine/types/header.go @@ -3,8 +3,7 @@ package types import ( "strings" - tmcrypto "github.com/tendermint/tendermint/crypto" - + cryptotypes "github.com/cosmos/cosmos-sdk/crypto/types" sdkerrors "github.com/cosmos/cosmos-sdk/types/errors" clienttypes "github.com/cosmos/cosmos-sdk/x/ibc/core/02-client/types" "github.com/cosmos/cosmos-sdk/x/ibc/core/exported" @@ -24,11 +23,11 @@ func (h Header) GetHeight() exported.Height { return clienttypes.NewHeight(0, h.Sequence) } -// GetPubKey unmarshals the new public key into a tmcrypto.PubKey type. -func (h Header) GetPubKey() tmcrypto.PubKey { - publicKey, ok := h.NewPublicKey.GetCachedValue().(tmcrypto.PubKey) +// GetPubKey unmarshals the new public key into a cryptotypes.PubKey type. +func (h Header) GetPubKey() cryptotypes.PubKey { + publicKey, ok := h.NewPublicKey.GetCachedValue().(cryptotypes.PubKey) if !ok { - panic("Header NewPublicKey is not crypto.PubKey") + panic("Header NewPublicKey is not cryptotypes.PubKey") } return publicKey diff --git a/x/ibc/light-clients/06-solomachine/types/proof.go b/x/ibc/light-clients/06-solomachine/types/proof.go index 7a5204e7f..c6f4c8b48 100644 --- a/x/ibc/light-clients/06-solomachine/types/proof.go +++ b/x/ibc/light-clients/06-solomachine/types/proof.go @@ -1,9 +1,8 @@ package types import ( - "github.com/tendermint/tendermint/crypto" - "github.com/cosmos/cosmos-sdk/codec" + cryptotypes "github.com/cosmos/cosmos-sdk/crypto/types" "github.com/cosmos/cosmos-sdk/crypto/types/multisig" sdkerrors "github.com/cosmos/cosmos-sdk/types/errors" "github.com/cosmos/cosmos-sdk/types/tx/signing" @@ -19,7 +18,7 @@ import ( // The type of the signature data determines how the public key is used to // verify the signature. An error is returned if signature verification fails // or an invalid SignatureData type is provided. -func VerifySignature(pubKey crypto.PubKey, signBytes []byte, sigData signing.SignatureData) error { +func VerifySignature(pubKey cryptotypes.PubKey, signBytes []byte, sigData signing.SignatureData) error { switch data := sigData.(type) { case *signing.SingleSignatureData: if !pubKey.VerifySignature(signBytes, data.Signature) { diff --git a/x/ibc/light-clients/06-solomachine/types/solomachine.go b/x/ibc/light-clients/06-solomachine/types/solomachine.go index 06d8fc05f..d3936ef42 100644 --- a/x/ibc/light-clients/06-solomachine/types/solomachine.go +++ b/x/ibc/light-clients/06-solomachine/types/solomachine.go @@ -1,9 +1,8 @@ package types import ( - "github.com/tendermint/tendermint/crypto" - codectypes "github.com/cosmos/cosmos-sdk/codec/types" + cryptotypes "github.com/cosmos/cosmos-sdk/crypto/types" "github.com/cosmos/cosmos-sdk/x/ibc/core/exported" ) @@ -20,17 +19,17 @@ func (cs ClientState) UnpackInterfaces(unpacker codectypes.AnyUnpacker) error { // UnpackInterfaces implements the UnpackInterfaceMessages.UnpackInterfaces method func (cs ConsensusState) UnpackInterfaces(unpacker codectypes.AnyUnpacker) error { - return unpacker.UnpackAny(cs.PublicKey, new(crypto.PubKey)) + return unpacker.UnpackAny(cs.PublicKey, new(cryptotypes.PubKey)) } // UnpackInterfaces implements the UnpackInterfaceMessages.UnpackInterfaces method func (h Header) UnpackInterfaces(unpacker codectypes.AnyUnpacker) error { - return unpacker.UnpackAny(h.NewPublicKey, new(crypto.PubKey)) + return unpacker.UnpackAny(h.NewPublicKey, new(cryptotypes.PubKey)) } // UnpackInterfaces implements the UnpackInterfaceMessages.UnpackInterfaces method func (hd HeaderData) UnpackInterfaces(unpacker codectypes.AnyUnpacker) error { - return unpacker.UnpackAny(hd.NewPubKey, new(crypto.PubKey)) + return unpacker.UnpackAny(hd.NewPubKey, new(cryptotypes.PubKey)) } // UnpackInterfaces implements the UnpackInterfaceMessages.UnpackInterfaces method diff --git a/x/ibc/light-clients/07-tendermint/types/misbehaviour_handle_test.go b/x/ibc/light-clients/07-tendermint/types/misbehaviour_handle_test.go index 213361186..e0fc26389 100644 --- a/x/ibc/light-clients/07-tendermint/types/misbehaviour_handle_test.go +++ b/x/ibc/light-clients/07-tendermint/types/misbehaviour_handle_test.go @@ -7,7 +7,6 @@ import ( "github.com/tendermint/tendermint/crypto/tmhash" tmtypes "github.com/tendermint/tendermint/types" - cryptotypes "github.com/cosmos/cosmos-sdk/crypto/types" "github.com/cosmos/cosmos-sdk/simapp" clienttypes "github.com/cosmos/cosmos-sdk/x/ibc/core/02-client/types" commitmenttypes "github.com/cosmos/cosmos-sdk/x/ibc/core/23-commitment/types" @@ -22,7 +21,7 @@ func (suite *TendermintTestSuite) TestCheckMisbehaviourAndUpdateState() { altPubKey, err := altPrivVal.GetPubKey() suite.Require().NoError(err) - altVal := tmtypes.NewValidator(altPubKey.(cryptotypes.IntoTmPubKey).AsTmPubKey(), 4) + altVal := tmtypes.NewValidator(altPubKey, 4) // Create bothValSet with both suite validator and altVal bothValSet := tmtypes.NewValidatorSet(append(suite.valSet.Validators, altVal)) diff --git a/x/ibc/light-clients/07-tendermint/types/misbehaviour_test.go b/x/ibc/light-clients/07-tendermint/types/misbehaviour_test.go index 22bd8674f..6f70c4b71 100644 --- a/x/ibc/light-clients/07-tendermint/types/misbehaviour_test.go +++ b/x/ibc/light-clients/07-tendermint/types/misbehaviour_test.go @@ -7,7 +7,6 @@ import ( tmproto "github.com/tendermint/tendermint/proto/tendermint/types" tmtypes "github.com/tendermint/tendermint/types" - cryptotypes "github.com/cosmos/cosmos-sdk/crypto/types" clienttypes "github.com/cosmos/cosmos-sdk/x/ibc/core/02-client/types" "github.com/cosmos/cosmos-sdk/x/ibc/light-clients/07-tendermint/types" ibctesting "github.com/cosmos/cosmos-sdk/x/ibc/testing" @@ -37,7 +36,7 @@ func (suite *TendermintTestSuite) TestMisbehaviourValidateBasic() { versionHeight := int64(height.VersionHeight) - altVal := tmtypes.NewValidator(altPubKey.(cryptotypes.IntoTmPubKey).AsTmPubKey(), versionHeight) + altVal := tmtypes.NewValidator(altPubKey, versionHeight) // Create bothValSet with both suite validator and altVal bothValSet := tmtypes.NewValidatorSet(append(suite.valSet.Validators, altVal)) diff --git a/x/ibc/light-clients/07-tendermint/types/tendermint_test.go b/x/ibc/light-clients/07-tendermint/types/tendermint_test.go index b175bfd5a..171d33f56 100644 --- a/x/ibc/light-clients/07-tendermint/types/tendermint_test.go +++ b/x/ibc/light-clients/07-tendermint/types/tendermint_test.go @@ -11,7 +11,6 @@ import ( tmtypes "github.com/tendermint/tendermint/types" "github.com/cosmos/cosmos-sdk/codec" - cryptotypes "github.com/cosmos/cosmos-sdk/crypto/types" "github.com/cosmos/cosmos-sdk/simapp" sdk "github.com/cosmos/cosmos-sdk/types" clienttypes "github.com/cosmos/cosmos-sdk/x/ibc/core/02-client/types" @@ -82,7 +81,7 @@ func (suite *TendermintTestSuite) SetupTest() { heightMinus1 := clienttypes.NewHeight(0, height.VersionHeight-1) - val := tmtypes.NewValidator(pubKey.(cryptotypes.IntoTmPubKey).AsTmPubKey(), 10) + val := tmtypes.NewValidator(pubKey, 10) suite.valSet = tmtypes.NewValidatorSet([]*tmtypes.Validator{val}) suite.valsHash = suite.valSet.Hash() suite.header = suite.chainA.CreateTMClientHeader(chainID, int64(height.VersionHeight), heightMinus1, suite.now, suite.valSet, suite.valSet, []tmtypes.PrivValidator{suite.privVal}) diff --git a/x/ibc/light-clients/07-tendermint/types/update_test.go b/x/ibc/light-clients/07-tendermint/types/update_test.go index 2d075ad0a..0941e6321 100644 --- a/x/ibc/light-clients/07-tendermint/types/update_test.go +++ b/x/ibc/light-clients/07-tendermint/types/update_test.go @@ -5,7 +5,6 @@ import ( tmtypes "github.com/tendermint/tendermint/types" - cryptotypes "github.com/cosmos/cosmos-sdk/crypto/types" clienttypes "github.com/cosmos/cosmos-sdk/x/ibc/core/02-client/types" commitmenttypes "github.com/cosmos/cosmos-sdk/x/ibc/core/23-commitment/types" types "github.com/cosmos/cosmos-sdk/x/ibc/light-clients/07-tendermint/types" @@ -35,7 +34,7 @@ func (suite *TendermintTestSuite) TestCheckHeaderAndUpdateState() { heightMinus3 := clienttypes.NewHeight(height.VersionNumber, height.VersionHeight-3) heightPlus5 := clienttypes.NewHeight(height.VersionNumber, height.VersionHeight+5) - altVal := tmtypes.NewValidator(altPubKey.(cryptotypes.IntoTmPubKey).AsTmPubKey(), versionHeight) + altVal := tmtypes.NewValidator(altPubKey, versionHeight) // Create bothValSet with both suite validator and altVal. Would be valid update bothValSet := tmtypes.NewValidatorSet(append(suite.valSet.Validators, altVal)) diff --git a/x/ibc/testing/chain.go b/x/ibc/testing/chain.go index 2c0554c6a..c29c111e8 100644 --- a/x/ibc/testing/chain.go +++ b/x/ibc/testing/chain.go @@ -9,7 +9,6 @@ import ( "github.com/stretchr/testify/require" abci "github.com/tendermint/tendermint/abci/types" - "github.com/tendermint/tendermint/crypto" "github.com/tendermint/tendermint/crypto/tmhash" tmproto "github.com/tendermint/tendermint/proto/tendermint/types" tmprotoversion "github.com/tendermint/tendermint/proto/tendermint/version" @@ -37,6 +36,7 @@ import ( solomachinetypes "github.com/cosmos/cosmos-sdk/x/ibc/light-clients/06-solomachine/types" ibctmtypes "github.com/cosmos/cosmos-sdk/x/ibc/light-clients/07-tendermint/types" "github.com/cosmos/cosmos-sdk/x/ibc/testing/mock" + "github.com/cosmos/cosmos-sdk/x/staking/teststaking" stakingtypes "github.com/cosmos/cosmos-sdk/x/staking/types" ) @@ -109,7 +109,7 @@ type TestChain struct { Vals *tmtypes.ValidatorSet Signers []tmtypes.PrivValidator - senderPrivKey crypto.PrivKey + senderPrivKey cryptotypes.PrivKey SenderAccount authtypes.AccountI // IBC specific helpers @@ -132,7 +132,7 @@ func NewTestChain(t *testing.T, chainID string) *TestChain { require.NoError(t, err) // create validator set with single validator - validator := tmtypes.NewValidator(pubKey.(cryptotypes.IntoTmPubKey).AsTmPubKey(), 1) + validator := tmtypes.NewValidator(pubKey, 1) valSet := tmtypes.NewValidatorSet([]*tmtypes.Validator{validator}) signers := []tmtypes.PrivValidator{privVal} @@ -346,7 +346,7 @@ func (chain *TestChain) GetValsAtHeight(height int64) (*tmtypes.ValidatorSet, bo valSet := stakingtypes.Validators(histInfo.Valset) - tmValidators, err := valSet.ToTmValidators() + tmValidators, err := teststaking.ToTmValidators(valSet) if err != nil { panic(err) } diff --git a/x/ibc/testing/chain_test.go b/x/ibc/testing/chain_test.go index 243eb0644..bf5af6de6 100644 --- a/x/ibc/testing/chain_test.go +++ b/x/ibc/testing/chain_test.go @@ -6,7 +6,6 @@ import ( "github.com/stretchr/testify/require" tmtypes "github.com/tendermint/tendermint/types" - cryptotypes "github.com/cosmos/cosmos-sdk/crypto/types" ibctesting "github.com/cosmos/cosmos-sdk/x/ibc/testing" "github.com/cosmos/cosmos-sdk/x/ibc/testing/mock" ) @@ -20,8 +19,8 @@ func TestCreateSortedSignerArray(t *testing.T) { pubKey2, err := privVal2.GetPubKey() require.NoError(t, err) - validator1 := tmtypes.NewValidator(pubKey1.(cryptotypes.IntoTmPubKey).AsTmPubKey(), 1) - validator2 := tmtypes.NewValidator(pubKey2.(cryptotypes.IntoTmPubKey).AsTmPubKey(), 2) + validator1 := tmtypes.NewValidator(pubKey1, 1) + validator2 := tmtypes.NewValidator(pubKey2, 2) expected := []tmtypes.PrivValidator{privVal2, privVal1} diff --git a/x/ibc/testing/mock/privval.go b/x/ibc/testing/mock/privval.go index ec40a8aad..fe46659b3 100644 --- a/x/ibc/testing/mock/privval.go +++ b/x/ibc/testing/mock/privval.go @@ -5,7 +5,9 @@ import ( tmproto "github.com/tendermint/tendermint/proto/tendermint/types" tmtypes "github.com/tendermint/tendermint/types" + cryptocodec "github.com/cosmos/cosmos-sdk/crypto/codec" "github.com/cosmos/cosmos-sdk/crypto/keys/ed25519" + cryptotypes "github.com/cosmos/cosmos-sdk/crypto/types" ) var _ tmtypes.PrivValidator = PV{} @@ -13,7 +15,7 @@ var _ tmtypes.PrivValidator = PV{} // MockPV implements PrivValidator without any safety or persistence. // Only use it for testing. type PV struct { - PrivKey crypto.PrivKey + PrivKey cryptotypes.PrivKey } func NewPV() PV { @@ -22,7 +24,7 @@ func NewPV() PV { // GetPubKey implements PrivValidator interface func (pv PV) GetPubKey() (crypto.PubKey, error) { - return pv.PrivKey.PubKey(), nil + return cryptocodec.ToTmPubKeyInterface(pv.PrivKey.PubKey()) } // SignVote implements PrivValidator interface diff --git a/x/ibc/testing/solomachine.go b/x/ibc/testing/solomachine.go index 21b02516e..6b2508f30 100644 --- a/x/ibc/testing/solomachine.go +++ b/x/ibc/testing/solomachine.go @@ -4,11 +4,11 @@ import ( "testing" "github.com/stretchr/testify/require" - "github.com/tendermint/tendermint/crypto" "github.com/cosmos/cosmos-sdk/codec" kmultisig "github.com/cosmos/cosmos-sdk/crypto/keys/multisig" "github.com/cosmos/cosmos-sdk/crypto/keys/secp256k1" + cryptotypes "github.com/cosmos/cosmos-sdk/crypto/types" "github.com/cosmos/cosmos-sdk/crypto/types/multisig" "github.com/cosmos/cosmos-sdk/types/tx/signing" "github.com/cosmos/cosmos-sdk/x/auth/tx" @@ -28,9 +28,9 @@ type Solomachine struct { cdc codec.BinaryMarshaler ClientID string - PrivateKeys []crypto.PrivKey // keys used for signing - PublicKeys []crypto.PubKey // keys used for generating solo machine pub key - PublicKey crypto.PubKey // key used for verification + PrivateKeys []cryptotypes.PrivKey // keys used for signing + PublicKeys []cryptotypes.PubKey // keys used for generating solo machine pub key + PublicKey cryptotypes.PubKey // key used for verification Sequence uint64 Time uint64 Diversifier string @@ -63,17 +63,17 @@ func NewSolomachine(t *testing.T, cdc codec.BinaryMarshaler, clientID, diversifi // The key type can be swapped for any key type supported by the PublicKey // interface, if needed. The same is true for the amino based Multisignature // public key. -func GenerateKeys(t *testing.T, n uint64) ([]crypto.PrivKey, []crypto.PubKey, crypto.PubKey) { +func GenerateKeys(t *testing.T, n uint64) ([]cryptotypes.PrivKey, []cryptotypes.PubKey, cryptotypes.PubKey) { require.NotEqual(t, uint64(0), n, "generation of zero keys is not allowed") - privKeys := make([]crypto.PrivKey, n) - pubKeys := make([]crypto.PubKey, n) + privKeys := make([]cryptotypes.PrivKey, n) + pubKeys := make([]cryptotypes.PubKey, n) for i := uint64(0); i < n; i++ { privKeys[i] = secp256k1.GenPrivKey() pubKeys[i] = privKeys[i].PubKey() } - var pk crypto.PubKey + var pk cryptotypes.PubKey if len(privKeys) > 1 { // generate multi sig pk pk = kmultisig.NewLegacyAminoPubKey(int(n), pubKeys) diff --git a/x/slashing/genesis.go b/x/slashing/genesis.go index ae8f31555..2c8b66757 100644 --- a/x/slashing/genesis.go +++ b/x/slashing/genesis.go @@ -12,7 +12,7 @@ import ( func InitGenesis(ctx sdk.Context, keeper keeper.Keeper, stakingKeeper types.StakingKeeper, data *types.GenesisState) { stakingKeeper.IterateValidators(ctx, func(index int64, validator stakingtypes.ValidatorI) bool { - consPk, err := validator.TmConsPubKey() + consPk, err := validator.ConsPubKey() if err != nil { panic(err) } diff --git a/x/slashing/keeper/hooks.go b/x/slashing/keeper/hooks.go index daf2e051e..d59601425 100644 --- a/x/slashing/keeper/hooks.go +++ b/x/slashing/keeper/hooks.go @@ -28,11 +28,12 @@ func (k Keeper) AfterValidatorBonded(ctx sdk.Context, address sdk.ConsAddress, _ // AfterValidatorCreated adds the address-pubkey relation when a validator is created. func (k Keeper) AfterValidatorCreated(ctx sdk.Context, valAddr sdk.ValAddress) error { validator := k.sk.Validator(ctx, valAddr) - consPk, err := validator.TmConsPubKey() + consPk, err := validator.ConsPubKey() if err != nil { return err } k.AddPubkey(ctx, consPk) + return nil } diff --git a/x/slashing/keeper/infractions.go b/x/slashing/keeper/infractions.go index a8e349b75..168b97b23 100644 --- a/x/slashing/keeper/infractions.go +++ b/x/slashing/keeper/infractions.go @@ -3,14 +3,13 @@ package keeper import ( "fmt" - "github.com/tendermint/tendermint/crypto" - + cryptotypes "github.com/cosmos/cosmos-sdk/crypto/types" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cosmos/cosmos-sdk/x/slashing/types" ) // HandleValidatorSignature handles a validator signature, must be called once per validator per block. -func (k Keeper) HandleValidatorSignature(ctx sdk.Context, addr crypto.Address, power int64, signed bool) { +func (k Keeper) HandleValidatorSignature(ctx sdk.Context, addr cryptotypes.Address, power int64, signed bool) { logger := k.Logger(ctx) height := ctx.BlockHeight() diff --git a/x/slashing/keeper/keeper.go b/x/slashing/keeper/keeper.go index ee46915b7..999e82404 100644 --- a/x/slashing/keeper/keeper.go +++ b/x/slashing/keeper/keeper.go @@ -5,10 +5,10 @@ import ( gogotypes "github.com/gogo/protobuf/types" - "github.com/tendermint/tendermint/crypto" "github.com/tendermint/tendermint/libs/log" "github.com/cosmos/cosmos-sdk/codec" + cryptotypes "github.com/cosmos/cosmos-sdk/crypto/types" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cosmos/cosmos-sdk/x/slashing/types" ) @@ -42,7 +42,7 @@ func (k Keeper) Logger(ctx sdk.Context) log.Logger { } // AddPubkey sets a address-pubkey relation -func (k Keeper) AddPubkey(ctx sdk.Context, pubkey crypto.PubKey) { +func (k Keeper) AddPubkey(ctx sdk.Context, pubkey cryptotypes.PubKey) { addr := pubkey.Address() pkStr, err := sdk.Bech32ifyPubKey(sdk.Bech32PubKeyTypeConsPub, pubkey) @@ -54,7 +54,7 @@ func (k Keeper) AddPubkey(ctx sdk.Context, pubkey crypto.PubKey) { } // GetPubkey returns the pubkey from the adddress-pubkey relation -func (k Keeper) GetPubkey(ctx sdk.Context, address crypto.Address) (crypto.PubKey, error) { +func (k Keeper) GetPubkey(ctx sdk.Context, address cryptotypes.Address) (cryptotypes.PubKey, error) { store := ctx.KVStore(k.storeKey) var pubkey gogotypes.StringValue @@ -99,14 +99,14 @@ func (k Keeper) Jail(ctx sdk.Context, consAddr sdk.ConsAddress) { k.sk.Jail(ctx, consAddr) } -func (k Keeper) setAddrPubkeyRelation(ctx sdk.Context, addr crypto.Address, pubkey string) { +func (k Keeper) setAddrPubkeyRelation(ctx sdk.Context, addr cryptotypes.Address, pubkey string) { store := ctx.KVStore(k.storeKey) bz := k.cdc.MustMarshalBinaryBare(&gogotypes.StringValue{Value: pubkey}) store.Set(types.AddrPubkeyRelationKey(addr), bz) } -func (k Keeper) deleteAddrPubkeyRelation(ctx sdk.Context, addr crypto.Address) { +func (k Keeper) deleteAddrPubkeyRelation(ctx sdk.Context, addr cryptotypes.Address) { store := ctx.KVStore(k.storeKey) store.Delete(types.AddrPubkeyRelationKey(addr)) } diff --git a/x/slashing/simulation/operations.go b/x/slashing/simulation/operations.go index d63700727..20acc9e91 100644 --- a/x/slashing/simulation/operations.go +++ b/x/slashing/simulation/operations.go @@ -65,11 +65,10 @@ func SimulateMsgUnjail(ak types.AccountKeeper, bk types.BankKeeper, k keeper.Kee return simtypes.NoOpMsg(types.ModuleName, types.TypeMsgUnjail, "validator is not jailed"), nil, nil } - cons, err := validator.TmConsPubKey() + consAddr, err := validator.GetConsAddr() if err != nil { return simtypes.NoOpMsg(types.ModuleName, types.TypeMsgUnjail, "unable to get validator consensus key"), nil, err } - consAddr := sdk.ConsAddress(cons.Address()) info, found := k.GetValidatorSigningInfo(ctx, consAddr) if !found { return simtypes.NoOpMsg(types.ModuleName, types.TypeMsgUnjail, "unable to find validator signing info"), nil, nil // skip diff --git a/x/staking/client/cli/tx.go b/x/staking/client/cli/tx.go index ab486c5a9..e83e50f27 100644 --- a/x/staking/client/cli/tx.go +++ b/x/staking/client/cli/tx.go @@ -7,11 +7,11 @@ import ( "github.com/spf13/cobra" flag "github.com/spf13/pflag" - "github.com/tendermint/tendermint/crypto" "github.com/cosmos/cosmos-sdk/client" "github.com/cosmos/cosmos-sdk/client/flags" "github.com/cosmos/cosmos-sdk/client/tx" + cryptotypes "github.com/cosmos/cosmos-sdk/crypto/types" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cosmos/cosmos-sdk/version" "github.com/cosmos/cosmos-sdk/x/staking/types" @@ -416,7 +416,7 @@ type TxCreateValidatorConfig struct { Identity string } -func PrepareConfigForTxCreateValidator(flagSet *flag.FlagSet, moniker, nodeID, chainID string, valPubKey crypto.PubKey) (TxCreateValidatorConfig, error) { +func PrepareConfigForTxCreateValidator(flagSet *flag.FlagSet, moniker, nodeID, chainID string, valPubKey cryptotypes.PubKey) (TxCreateValidatorConfig, error) { c := TxCreateValidatorConfig{} ip, err := flagSet.GetString(FlagIP) diff --git a/x/staking/genesis.go b/x/staking/genesis.go index 1b646f236..02f6bc317 100644 --- a/x/staking/genesis.go +++ b/x/staking/genesis.go @@ -5,9 +5,9 @@ import ( "log" abci "github.com/tendermint/tendermint/abci/types" - "github.com/tendermint/tendermint/crypto" tmtypes "github.com/tendermint/tendermint/types" + cryptocodec "github.com/cosmos/cosmos-sdk/crypto/codec" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cosmos/cosmos-sdk/x/staking/keeper" "github.com/cosmos/cosmos-sdk/x/staking/types" @@ -198,14 +198,18 @@ func ExportGenesis(ctx sdk.Context, keeper keeper.Keeper) *types.GenesisState { // WriteValidators returns a slice of bonded genesis validators. func WriteValidators(ctx sdk.Context, keeper keeper.Keeper) (vals []tmtypes.GenesisValidator, err error) { keeper.IterateLastValidators(ctx, func(_ int64, validator types.ValidatorI) (stop bool) { - var consPk crypto.PubKey - consPk, err = validator.TmConsPubKey() + pk, err := validator.ConsPubKey() if err != nil { return true } + tmPk, err := cryptocodec.ToTmPubKeyInterface(pk) + if err != nil { + return true + } + vals = append(vals, tmtypes.GenesisValidator{ - Address: sdk.ConsAddress(consPk.Address()).Bytes(), - PubKey: consPk, + Address: sdk.ConsAddress(tmPk.Address()).Bytes(), + PubKey: tmPk, Power: validator.GetConsensusPower(), Name: validator.GetMoniker(), }) @@ -231,7 +235,7 @@ func validateGenesisStateValidators(validators []types.Validator) error { for i := 0; i < len(validators); i++ { val := validators[i] - consPk, err := val.TmConsPubKey() + consPk, err := val.ConsPubKey() if err != nil { return err } diff --git a/x/staking/handler_test.go b/x/staking/handler_test.go index 34a8cd78e..844fc7799 100644 --- a/x/staking/handler_test.go +++ b/x/staking/handler_test.go @@ -11,8 +11,8 @@ import ( tmproto "github.com/tendermint/tendermint/proto/tendermint/types" tmtypes "github.com/tendermint/tendermint/types" + cryptocodec "github.com/cosmos/cosmos-sdk/crypto/codec" "github.com/cosmos/cosmos-sdk/crypto/keys/secp256k1" - cryptotypes "github.com/cosmos/cosmos-sdk/crypto/types" "github.com/cosmos/cosmos-sdk/simapp" "github.com/cosmos/cosmos-sdk/testutil/testdata" sdk "github.com/cosmos/cosmos-sdk/types" @@ -132,9 +132,11 @@ func TestDuplicatesMsgCreateValidator(t *testing.T) { validator := tstaking.CheckValidator(addr1, types.Bonded, false) assert.Equal(t, addr1.String(), validator.OperatorAddress) - consKey, err := validator.TmConsPubKey() + consKey, err := validator.TmConsPublicKey() require.NoError(t, err) - assert.Equal(t, pk1.(cryptotypes.IntoTmPubKey).AsTmPubKey(), consKey) + tmPk1, err := cryptocodec.ToTmProtoPublicKey(pk1) + require.NoError(t, err) + assert.Equal(t, tmPk1, consKey) assert.Equal(t, valTokens, validator.BondedTokens()) assert.Equal(t, valTokens.ToDec(), validator.DelegatorShares) assert.Equal(t, types.Description{}, validator.Description) @@ -155,9 +157,11 @@ func TestDuplicatesMsgCreateValidator(t *testing.T) { validator = tstaking.CheckValidator(addr2, types.Bonded, false) assert.Equal(t, addr2.String(), validator.OperatorAddress) - consPk, err := validator.TmConsPubKey() + consPk, err := validator.TmConsPublicKey() require.NoError(t, err) - assert.Equal(t, pk2.(cryptotypes.IntoTmPubKey).AsTmPubKey(), consPk) + tmPk2, err := cryptocodec.ToTmProtoPublicKey(pk2) + require.NoError(t, err) + assert.Equal(t, tmPk2, consPk) assert.True(sdk.IntEq(t, valTokens, validator.Tokens)) assert.True(sdk.DecEq(t, valTokens.ToDec(), validator.DelegatorShares)) assert.Equal(t, types.Description{}, validator.Description) diff --git a/x/staking/keeper/msg_server.go b/x/staking/keeper/msg_server.go index 472a96c48..3f112a0ab 100644 --- a/x/staking/keeper/msg_server.go +++ b/x/staking/keeper/msg_server.go @@ -41,7 +41,7 @@ func (k msgServer) CreateValidator(goCtx context.Context, msg *types.MsgCreateVa pk, ok := msg.Pubkey.GetCachedValue().(cryptotypes.PubKey) if !ok { - return nil, sdkerrors.Wrapf(sdkerrors.ErrInvalidType, "Expecting crypto.PubKey, got %T", pk) + return nil, sdkerrors.Wrapf(sdkerrors.ErrInvalidType, "Expecting cryptotypes.PubKey, got %T", pk) } if _, found := k.GetValidatorByConsAddr(ctx, sdk.GetConsAddress(pk)); found { diff --git a/x/staking/keeper/validator_test.go b/x/staking/keeper/validator_test.go index c28b6db35..894a60085 100644 --- a/x/staking/keeper/validator_test.go +++ b/x/staking/keeper/validator_test.go @@ -8,9 +8,9 @@ import ( "github.com/stretchr/testify/assert" "github.com/stretchr/testify/require" abci "github.com/tendermint/tendermint/abci/types" - "github.com/tendermint/tendermint/crypto" tmproto "github.com/tendermint/tendermint/proto/tendermint/types" + cryptotypes "github.com/cosmos/cosmos-sdk/crypto/types" "github.com/cosmos/cosmos-sdk/simapp" sdk "github.com/cosmos/cosmos-sdk/types" banktypes "github.com/cosmos/cosmos-sdk/x/bank/types" @@ -19,7 +19,7 @@ import ( "github.com/cosmos/cosmos-sdk/x/staking/types" ) -func newMonikerValidator(t *testing.T, operator sdk.ValAddress, pubKey crypto.PubKey, moniker string) types.Validator { +func newMonikerValidator(t *testing.T, operator sdk.ValAddress, pubKey cryptotypes.PubKey, moniker string) types.Validator { v, err := types.NewValidator(operator, pubKey, types.Description{Moniker: moniker}) require.NoError(t, err) return v diff --git a/x/staking/legacy/v034/types.go b/x/staking/legacy/v034/types.go index 6e93b7986..9f8622d4b 100644 --- a/x/staking/legacy/v034/types.go +++ b/x/staking/legacy/v034/types.go @@ -5,9 +5,8 @@ package v034 import ( "time" - "github.com/tendermint/tendermint/crypto" - "github.com/cosmos/cosmos-sdk/codec/legacy" + cryptotypes "github.com/cosmos/cosmos-sdk/crypto/types" sdk "github.com/cosmos/cosmos-sdk/types" ) @@ -76,17 +75,17 @@ type ( } Validator struct { - OperatorAddress sdk.ValAddress `json:"operator_address"` - ConsPubKey crypto.PubKey `json:"consensus_pubkey"` - Jailed bool `json:"jailed"` - Status BondStatus `json:"status"` - Tokens sdk.Int `json:"tokens"` - DelegatorShares sdk.Dec `json:"delegator_shares"` - Description Description `json:"description"` - UnbondingHeight int64 `json:"unbonding_height"` - UnbondingCompletionTime time.Time `json:"unbonding_time"` - Commission Commission `json:"commission"` - MinSelfDelegation sdk.Int `json:"min_self_delegation"` + OperatorAddress sdk.ValAddress `json:"operator_address"` + ConsPubKey cryptotypes.PubKey `json:"consensus_pubkey"` + Jailed bool `json:"jailed"` + Status BondStatus `json:"status"` + Tokens sdk.Int `json:"tokens"` + DelegatorShares sdk.Dec `json:"delegator_shares"` + Description Description `json:"description"` + UnbondingHeight int64 `json:"unbonding_height"` + UnbondingCompletionTime time.Time `json:"unbonding_time"` + Commission Commission `json:"commission"` + MinSelfDelegation sdk.Int `json:"min_self_delegation"` } Validators []Validator @@ -170,6 +169,7 @@ func (v *Validator) UnmarshalJSON(data []byte) error { if err != nil { return err } + *v = Validator{ OperatorAddress: bv.OperatorAddress, ConsPubKey: consPubKey, diff --git a/x/staking/legacy/v036/migrate_test.go b/x/staking/legacy/v036/migrate_test.go new file mode 100644 index 000000000..7278774bf --- /dev/null +++ b/x/staking/legacy/v036/migrate_test.go @@ -0,0 +1,103 @@ +package v036_test + +import ( + "testing" + + "github.com/cosmos/cosmos-sdk/codec" + "github.com/cosmos/cosmos-sdk/crypto/keys/ed25519" + "github.com/cosmos/cosmos-sdk/crypto/keys/secp256k1" + v034staking "github.com/cosmos/cosmos-sdk/x/staking/legacy/v034" + v036staking "github.com/cosmos/cosmos-sdk/x/staking/legacy/v036" + "github.com/stretchr/testify/require" +) + +func TestMigrate(t *testing.T) { + aminoCdc := codec.NewLegacyAmino() + consPubKeyEd := ed25519.GenPrivKeyFromSecret([]byte("val0")).PubKey() + consPubKeySecp := secp256k1.GenPrivKeyFromSecret([]byte("val1")).PubKey() + stakingGenState := v034staking.GenesisState{ + Validators: v034staking.Validators{ + v034staking.Validator{ + ConsPubKey: consPubKeyEd, + Status: v034staking.Unbonded, + }, v034staking.Validator{ + ConsPubKey: consPubKeySecp, + Status: v034staking.Unbonded, + }, + }, + } + + migrated := v036staking.Migrate(stakingGenState) + + json, err := aminoCdc.MarshalJSONIndent(migrated, "", " ") + require.NoError(t, err) + + expectedJSON := `{ + "params": { + "unbonding_time": "0", + "max_validators": 0, + "max_entries": 0, + "bond_denom": "" + }, + "last_total_power": "0", + "last_validator_powers": null, + "validators": [ + { + "operator_address": "", + "consensus_pubkey": "cosmosvalconspub1zcjduepq9ymett3nlv6fytn7lqxzd3q3ckvd79eqlcf3wkhgamcl4rzghesq83ecpx", + "jailed": false, + "status": 0, + "tokens": "0", + "delegator_shares": "0", + "description": { + "moniker": "", + "identity": "", + "website": "", + "details": "" + }, + "unbonding_height": "0", + "unbonding_time": "0001-01-01T00:00:00Z", + "commission": { + "commission_rates": { + "rate": "0", + "max_rate": "0", + "max_change_rate": "0" + }, + "update_time": "0001-01-01T00:00:00Z" + }, + "min_self_delegation": "0" + }, + { + "operator_address": "", + "consensus_pubkey": "cosmosvalconspub1addwnpepqwfxk5k5pugwz3quqyzvzupefm3589tw6x9dkzjdkuzn7hgpz33ag84e406", + "jailed": false, + "status": 0, + "tokens": "0", + "delegator_shares": "0", + "description": { + "moniker": "", + "identity": "", + "website": "", + "details": "" + }, + "unbonding_height": "0", + "unbonding_time": "0001-01-01T00:00:00Z", + "commission": { + "commission_rates": { + "rate": "0", + "max_rate": "0", + "max_change_rate": "0" + }, + "update_time": "0001-01-01T00:00:00Z" + }, + "min_self_delegation": "0" + } + ], + "delegations": null, + "unbonding_delegations": null, + "redelegations": null, + "exported": false +}` + + require.Equal(t, expectedJSON, string(json)) +} diff --git a/x/staking/legacy/v036/types.go b/x/staking/legacy/v036/types.go index 6c110bbe5..b433b0070 100644 --- a/x/staking/legacy/v036/types.go +++ b/x/staking/legacy/v036/types.go @@ -5,9 +5,8 @@ package v036 import ( "time" - "github.com/tendermint/tendermint/crypto" - "github.com/cosmos/cosmos-sdk/codec/legacy" + cryptotypes "github.com/cosmos/cosmos-sdk/crypto/types" sdk "github.com/cosmos/cosmos-sdk/types" v034staking "github.com/cosmos/cosmos-sdk/x/staking/legacy/v034" ) @@ -30,7 +29,7 @@ type ( Validator struct { OperatorAddress sdk.ValAddress `json:"operator_address" yaml:"operator_address"` - ConsPubKey crypto.PubKey `json:"consensus_pubkey" yaml:"consensus_pubkey"` + ConsPubKey cryptotypes.PubKey `json:"consensus_pubkey" yaml:"consensus_pubkey"` Jailed bool `json:"jailed" yaml:"jailed"` Status v034staking.BondStatus `json:"status" yaml:"status"` Tokens sdk.Int `json:"tokens" yaml:"tokens"` diff --git a/x/staking/legacy/v038/types.go b/x/staking/legacy/v038/types.go index aff9a559d..58ffa1351 100644 --- a/x/staking/legacy/v038/types.go +++ b/x/staking/legacy/v038/types.go @@ -5,9 +5,8 @@ package v038 import ( "time" - "github.com/tendermint/tendermint/crypto" - "github.com/cosmos/cosmos-sdk/codec/legacy" + cryptotypes "github.com/cosmos/cosmos-sdk/crypto/types" sdk "github.com/cosmos/cosmos-sdk/types" v034staking "github.com/cosmos/cosmos-sdk/x/staking/legacy/v034" v036staking "github.com/cosmos/cosmos-sdk/x/staking/legacy/v036" @@ -28,7 +27,7 @@ type ( Validator struct { OperatorAddress sdk.ValAddress `json:"operator_address" yaml:"operator_address"` - ConsPubKey crypto.PubKey `json:"consensus_pubkey" yaml:"consensus_pubkey"` + ConsPubKey cryptotypes.PubKey `json:"consensus_pubkey" yaml:"consensus_pubkey"` Jailed bool `json:"jailed" yaml:"jailed"` Status v034staking.BondStatus `json:"status" yaml:"status"` Tokens sdk.Int `json:"tokens" yaml:"tokens"` diff --git a/x/staking/teststaking/helper.go b/x/staking/teststaking/helper.go index c0ba45bb1..e63c816ab 100644 --- a/x/staking/teststaking/helper.go +++ b/x/staking/teststaking/helper.go @@ -5,8 +5,8 @@ import ( "time" "github.com/stretchr/testify/require" - "github.com/tendermint/tendermint/crypto" + cryptotypes "github.com/cosmos/cosmos-sdk/crypto/types" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cosmos/cosmos-sdk/x/staking" "github.com/cosmos/cosmos-sdk/x/staking/keeper" @@ -32,14 +32,14 @@ func NewHelper(t *testing.T, ctx sdk.Context, k keeper.Keeper) *Helper { } // CreateValidator calls handler to create a new staking validator -func (sh *Helper) CreateValidator(addr sdk.ValAddress, pk crypto.PubKey, stakeAmount int64, ok bool) { +func (sh *Helper) CreateValidator(addr sdk.ValAddress, pk cryptotypes.PubKey, stakeAmount int64, ok bool) { coin := sdk.NewCoin(sh.Denom, sdk.NewInt(stakeAmount)) sh.createValidator(addr, pk, coin, ok) } // CreateValidatorWithValPower calls handler to create a new staking validator with zero // commission -func (sh *Helper) CreateValidatorWithValPower(addr sdk.ValAddress, pk crypto.PubKey, valPower int64, ok bool) sdk.Int { +func (sh *Helper) CreateValidatorWithValPower(addr sdk.ValAddress, pk cryptotypes.PubKey, valPower int64, ok bool) sdk.Int { amount := sdk.TokensFromConsensusPower(valPower) coin := sdk.NewCoin(sh.Denom, amount) sh.createValidator(addr, pk, coin, ok) @@ -47,14 +47,14 @@ func (sh *Helper) CreateValidatorWithValPower(addr sdk.ValAddress, pk crypto.Pub } // CreateValidatorMsg returns a message used to create validator in this service. -func (sh *Helper) CreateValidatorMsg(addr sdk.ValAddress, pk crypto.PubKey, stakeAmount int64) *stakingtypes.MsgCreateValidator { +func (sh *Helper) CreateValidatorMsg(addr sdk.ValAddress, pk cryptotypes.PubKey, stakeAmount int64) *stakingtypes.MsgCreateValidator { coin := sdk.NewCoin(sh.Denom, sdk.NewInt(stakeAmount)) msg, err := stakingtypes.NewMsgCreateValidator(addr, pk, coin, stakingtypes.Description{}, sh.Commission, sdk.OneInt()) require.NoError(sh.t, err) return msg } -func (sh *Helper) createValidator(addr sdk.ValAddress, pk crypto.PubKey, coin sdk.Coin, ok bool) { +func (sh *Helper) createValidator(addr sdk.ValAddress, pk cryptotypes.PubKey, coin sdk.Coin, ok bool) { msg, err := stakingtypes.NewMsgCreateValidator(addr, pk, coin, stakingtypes.Description{}, sh.Commission, sdk.OneInt()) require.NoError(sh.t, err) sh.Handle(msg, ok) diff --git a/x/staking/teststaking/tm.go b/x/staking/teststaking/tm.go new file mode 100644 index 000000000..9a9c030d0 --- /dev/null +++ b/x/staking/teststaking/tm.go @@ -0,0 +1,43 @@ +package teststaking + +import ( + tmcrypto "github.com/tendermint/tendermint/crypto" + tmtypes "github.com/tendermint/tendermint/types" + + cryptocodec "github.com/cosmos/cosmos-sdk/crypto/codec" + "github.com/cosmos/cosmos-sdk/x/staking/types" +) + +// GetTmConsPubKey gets the validator's public key as a tmcrypto.PubKey. +func GetTmConsPubKey(v types.Validator) (tmcrypto.PubKey, error) { + pk, err := v.ConsPubKey() + if err != nil { + return nil, err + } + + return cryptocodec.ToTmPubKeyInterface(pk) +} + +// ToTmValidator casts an SDK validator to a tendermint type Validator. +func ToTmValidator(v types.Validator) (*tmtypes.Validator, error) { + tmPk, err := GetTmConsPubKey(v) + if err != nil { + return nil, err + } + + return tmtypes.NewValidator(tmPk, v.ConsensusPower()), nil +} + +// ToTmValidators casts all validators to the corresponding tendermint type. +func ToTmValidators(v types.Validators) ([]*tmtypes.Validator, error) { + validators := make([]*tmtypes.Validator, len(v)) + var err error + for i, val := range v { + validators[i], err = ToTmValidator(val) + if err != nil { + return nil, err + } + } + + return validators, nil +} diff --git a/x/staking/teststaking/validator.go b/x/staking/teststaking/validator.go index 90dd48599..901395d76 100644 --- a/x/staking/teststaking/validator.go +++ b/x/staking/teststaking/validator.go @@ -4,14 +4,14 @@ import ( "testing" "github.com/stretchr/testify/require" - "github.com/tendermint/tendermint/crypto" + cryptotypes "github.com/cosmos/cosmos-sdk/crypto/types" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cosmos/cosmos-sdk/x/staking/types" ) // NewValidator is a testing helper method to create validators in tests -func NewValidator(t *testing.T, operator sdk.ValAddress, pubKey crypto.PubKey) types.Validator { +func NewValidator(t *testing.T, operator sdk.ValAddress, pubKey cryptotypes.PubKey) types.Validator { v, err := types.NewValidator(operator, pubKey, types.Description{}) require.NoError(t, err) return v diff --git a/x/staking/types/commission_test.go b/x/staking/types/commission_test.go index ec6186122..3ca95cf4b 100644 --- a/x/staking/types/commission_test.go +++ b/x/staking/types/commission_test.go @@ -1,4 +1,4 @@ -package types +package types_test import ( "testing" @@ -7,27 +7,28 @@ import ( "github.com/stretchr/testify/require" sdk "github.com/cosmos/cosmos-sdk/types" + "github.com/cosmos/cosmos-sdk/x/staking/types" ) func TestCommissionValidate(t *testing.T) { testCases := []struct { - input Commission + input types.Commission expectErr bool }{ // invalid commission; max rate < 0% - {NewCommission(sdk.ZeroDec(), sdk.MustNewDecFromStr("-1.00"), sdk.ZeroDec()), true}, + {types.NewCommission(sdk.ZeroDec(), sdk.MustNewDecFromStr("-1.00"), sdk.ZeroDec()), true}, // invalid commission; max rate > 100% - {NewCommission(sdk.ZeroDec(), sdk.MustNewDecFromStr("2.00"), sdk.ZeroDec()), true}, + {types.NewCommission(sdk.ZeroDec(), sdk.MustNewDecFromStr("2.00"), sdk.ZeroDec()), true}, // invalid commission; rate < 0% - {NewCommission(sdk.MustNewDecFromStr("-1.00"), sdk.ZeroDec(), sdk.ZeroDec()), true}, + {types.NewCommission(sdk.MustNewDecFromStr("-1.00"), sdk.ZeroDec(), sdk.ZeroDec()), true}, // invalid commission; rate > max rate - {NewCommission(sdk.MustNewDecFromStr("0.75"), sdk.MustNewDecFromStr("0.50"), sdk.ZeroDec()), true}, + {types.NewCommission(sdk.MustNewDecFromStr("0.75"), sdk.MustNewDecFromStr("0.50"), sdk.ZeroDec()), true}, // invalid commission; max change rate < 0% - {NewCommission(sdk.OneDec(), sdk.OneDec(), sdk.MustNewDecFromStr("-1.00")), true}, + {types.NewCommission(sdk.OneDec(), sdk.OneDec(), sdk.MustNewDecFromStr("-1.00")), true}, // invalid commission; max change rate > max rate - {NewCommission(sdk.OneDec(), sdk.MustNewDecFromStr("0.75"), sdk.MustNewDecFromStr("0.90")), true}, + {types.NewCommission(sdk.OneDec(), sdk.MustNewDecFromStr("0.75"), sdk.MustNewDecFromStr("0.90")), true}, // valid commission - {NewCommission(sdk.MustNewDecFromStr("0.20"), sdk.OneDec(), sdk.MustNewDecFromStr("0.10")), false}, + {types.NewCommission(sdk.MustNewDecFromStr("0.20"), sdk.OneDec(), sdk.MustNewDecFromStr("0.10")), false}, } for i, tc := range testCases { @@ -38,11 +39,11 @@ func TestCommissionValidate(t *testing.T) { func TestCommissionValidateNewRate(t *testing.T) { now := time.Now().UTC() - c1 := NewCommission(sdk.MustNewDecFromStr("0.40"), sdk.MustNewDecFromStr("0.80"), sdk.MustNewDecFromStr("0.10")) + c1 := types.NewCommission(sdk.MustNewDecFromStr("0.40"), sdk.MustNewDecFromStr("0.80"), sdk.MustNewDecFromStr("0.10")) c1.UpdateTime = now testCases := []struct { - input Commission + input types.Commission newRate sdk.Dec blockTime time.Time expectErr bool diff --git a/x/staking/types/data_test.go b/x/staking/types/data_test.go index 5505b9d5c..3f8b290f9 100644 --- a/x/staking/types/data_test.go +++ b/x/staking/types/data_test.go @@ -1,12 +1,11 @@ -package types +package types_test import ( "fmt" - "github.com/tendermint/tendermint/crypto" - codectypes "github.com/cosmos/cosmos-sdk/codec/types" "github.com/cosmos/cosmos-sdk/crypto/keys/ed25519" + cryptotypes "github.com/cosmos/cosmos-sdk/crypto/types" sdk "github.com/cosmos/cosmos-sdk/types" ) @@ -23,7 +22,7 @@ var ( valAddr3 = sdk.ValAddress(pk3.Address()) emptyAddr sdk.ValAddress - emptyPubkey crypto.PubKey + emptyPubkey cryptotypes.PubKey ) func init() { diff --git a/x/staking/types/delegation_test.go b/x/staking/types/delegation_test.go index 7723570ff..7ca5e8132 100644 --- a/x/staking/types/delegation_test.go +++ b/x/staking/types/delegation_test.go @@ -1,4 +1,4 @@ -package types +package types_test import ( "encoding/json" @@ -9,10 +9,11 @@ import ( "github.com/cosmos/cosmos-sdk/codec" sdk "github.com/cosmos/cosmos-sdk/types" + "github.com/cosmos/cosmos-sdk/x/staking/types" ) func TestDelegationEqual(t *testing.T) { - d1 := NewDelegation(sdk.AccAddress(valAddr1), valAddr2, sdk.NewDec(100)) + d1 := types.NewDelegation(sdk.AccAddress(valAddr1), valAddr2, sdk.NewDec(100)) d2 := d1 ok := d1.String() == d2.String() @@ -26,12 +27,12 @@ func TestDelegationEqual(t *testing.T) { } func TestDelegationString(t *testing.T) { - d := NewDelegation(sdk.AccAddress(valAddr1), valAddr2, sdk.NewDec(100)) + d := types.NewDelegation(sdk.AccAddress(valAddr1), valAddr2, sdk.NewDec(100)) require.NotEmpty(t, d.String()) } func TestUnbondingDelegationEqual(t *testing.T) { - ubd1 := NewUnbondingDelegation(sdk.AccAddress(valAddr1), valAddr2, 0, + ubd1 := types.NewUnbondingDelegation(sdk.AccAddress(valAddr1), valAddr2, 0, time.Unix(0, 0), sdk.NewInt(0)) ubd2 := ubd1 @@ -46,17 +47,17 @@ func TestUnbondingDelegationEqual(t *testing.T) { } func TestUnbondingDelegationString(t *testing.T) { - ubd := NewUnbondingDelegation(sdk.AccAddress(valAddr1), valAddr2, 0, + ubd := types.NewUnbondingDelegation(sdk.AccAddress(valAddr1), valAddr2, 0, time.Unix(0, 0), sdk.NewInt(0)) require.NotEmpty(t, ubd.String()) } func TestRedelegationEqual(t *testing.T) { - r1 := NewRedelegation(sdk.AccAddress(valAddr1), valAddr2, valAddr3, 0, + r1 := types.NewRedelegation(sdk.AccAddress(valAddr1), valAddr2, valAddr3, 0, time.Unix(0, 0), sdk.NewInt(0), sdk.NewDec(0)) - r2 := NewRedelegation(sdk.AccAddress(valAddr1), valAddr2, valAddr3, 0, + r2 := types.NewRedelegation(sdk.AccAddress(valAddr1), valAddr2, valAddr3, 0, time.Unix(0, 0), sdk.NewInt(0), sdk.NewDec(0)) @@ -71,7 +72,7 @@ func TestRedelegationEqual(t *testing.T) { } func TestRedelegationString(t *testing.T) { - r := NewRedelegation(sdk.AccAddress(valAddr1), valAddr2, valAddr3, 0, + r := types.NewRedelegation(sdk.AccAddress(valAddr1), valAddr2, valAddr3, 0, time.Unix(0, 0), sdk.NewInt(0), sdk.NewDec(10)) @@ -80,11 +81,11 @@ func TestRedelegationString(t *testing.T) { func TestDelegationResponses(t *testing.T) { cdc := codec.NewLegacyAmino() - dr1 := NewDelegationResp(sdk.AccAddress(valAddr1), valAddr2, sdk.NewDec(5), + dr1 := types.NewDelegationResp(sdk.AccAddress(valAddr1), valAddr2, sdk.NewDec(5), sdk.NewCoin(sdk.DefaultBondDenom, sdk.NewInt(5))) - dr2 := NewDelegationResp(sdk.AccAddress(valAddr1), valAddr3, sdk.NewDec(5), + dr2 := types.NewDelegationResp(sdk.AccAddress(valAddr1), valAddr3, sdk.NewDec(5), sdk.NewCoin(sdk.DefaultBondDenom, sdk.NewInt(5))) - drs := DelegationResponses{dr1, dr2} + drs := types.DelegationResponses{dr1, dr2} bz1, err := json.Marshal(dr1) require.NoError(t, err) @@ -102,20 +103,20 @@ func TestDelegationResponses(t *testing.T) { require.Equal(t, bz1, bz2) - var drs2 DelegationResponses + var drs2 types.DelegationResponses require.NoError(t, cdc.UnmarshalJSON(bz2, &drs2)) require.Equal(t, drs, drs2) } func TestRedelegationResponses(t *testing.T) { cdc := codec.NewLegacyAmino() - entries := []RedelegationEntryResponse{ - NewRedelegationEntryResponse(0, time.Unix(0, 0), sdk.NewDec(5), sdk.NewInt(5), sdk.NewInt(5)), - NewRedelegationEntryResponse(0, time.Unix(0, 0), sdk.NewDec(5), sdk.NewInt(5), sdk.NewInt(5)), + entries := []types.RedelegationEntryResponse{ + types.NewRedelegationEntryResponse(0, time.Unix(0, 0), sdk.NewDec(5), sdk.NewInt(5), sdk.NewInt(5)), + types.NewRedelegationEntryResponse(0, time.Unix(0, 0), sdk.NewDec(5), sdk.NewInt(5), sdk.NewInt(5)), } - rdr1 := NewRedelegationResponse(sdk.AccAddress(valAddr1), valAddr2, valAddr3, entries) - rdr2 := NewRedelegationResponse(sdk.AccAddress(valAddr2), valAddr1, valAddr3, entries) - rdrs := RedelegationResponses{rdr1, rdr2} + rdr1 := types.NewRedelegationResponse(sdk.AccAddress(valAddr1), valAddr2, valAddr3, entries) + rdr2 := types.NewRedelegationResponse(sdk.AccAddress(valAddr2), valAddr1, valAddr3, entries) + rdrs := types.RedelegationResponses{rdr1, rdr2} bz1, err := json.Marshal(rdr1) require.NoError(t, err) @@ -133,7 +134,7 @@ func TestRedelegationResponses(t *testing.T) { require.Equal(t, bz1, bz2) - var rdrs2 RedelegationResponses + var rdrs2 types.RedelegationResponses require.NoError(t, cdc.UnmarshalJSON(bz2, &rdrs2)) bz3, err := cdc.MarshalJSON(rdrs2) diff --git a/x/staking/types/exported.go b/x/staking/types/exported.go index f8cf8be99..a02adc34b 100644 --- a/x/staking/types/exported.go +++ b/x/staking/types/exported.go @@ -1,8 +1,10 @@ package types import ( + tmprotocrypto "github.com/tendermint/tendermint/proto/tendermint/crypto" + + cryptotypes "github.com/cosmos/cosmos-sdk/crypto/types" sdk "github.com/cosmos/cosmos-sdk/types" - "github.com/tendermint/tendermint/crypto" ) // DelegationI delegation bond for a delegated proof of stake system @@ -21,7 +23,8 @@ type ValidatorI interface { IsUnbonded() bool // check if has status unbonded IsUnbonding() bool // check if has status unbonding GetOperator() sdk.ValAddress // operator address to receive/return validators coins - TmConsPubKey() (crypto.PubKey, error) // validation consensus pubkey + ConsPubKey() (cryptotypes.PubKey, error) // validation consensus pubkey (cryptotypes.PubKey) + TmConsPublicKey() (tmprotocrypto.PublicKey, error) // validation consensus pubkey (Tendermint) GetConsAddr() (sdk.ConsAddress, error) // validation consensus address GetTokens() sdk.Int // validation tokens GetBondedTokens() sdk.Int // validator bonded tokens diff --git a/x/staking/types/historical_info_test.go b/x/staking/types/historical_info_test.go index f7f6f2a86..ca3e48951 100644 --- a/x/staking/types/historical_info_test.go +++ b/x/staking/types/historical_info_test.go @@ -1,10 +1,11 @@ -package types +package types_test import ( "math/rand" "sort" "testing" + "github.com/cosmos/cosmos-sdk/x/staking/types" "github.com/stretchr/testify/require" tmproto "github.com/tendermint/tendermint/proto/tendermint/types" ) @@ -14,8 +15,8 @@ var header = tmproto.Header{ Height: 5, } -func createValidators(t *testing.T) []Validator { - return []Validator{ +func createValidators(t *testing.T) []types.Validator { + return []types.Validator{ newValidator(t, valAddr1, pk1), newValidator(t, valAddr2, pk2), newValidator(t, valAddr3, pk3), @@ -24,48 +25,48 @@ func createValidators(t *testing.T) []Validator { func TestHistoricalInfo(t *testing.T) { validators := createValidators(t) - hi := NewHistoricalInfo(header, validators) - require.True(t, sort.IsSorted(Validators(hi.Valset)), "Validators are not sorted") + hi := types.NewHistoricalInfo(header, validators) + require.True(t, sort.IsSorted(types.Validators(hi.Valset)), "Validators are not sorted") var value []byte require.NotPanics(t, func() { - value = ModuleCdc.MustMarshalBinaryBare(&hi) + value = types.ModuleCdc.MustMarshalBinaryBare(&hi) }) require.NotNil(t, value, "Marshalled HistoricalInfo is nil") - recv, err := UnmarshalHistoricalInfo(ModuleCdc, value) + recv, err := types.UnmarshalHistoricalInfo(types.ModuleCdc, value) require.Nil(t, err, "Unmarshalling HistoricalInfo failed") require.Equal(t, hi.Header, recv.Header) for i := range hi.Valset { require.True(t, hi.Valset[i].Equal(&recv.Valset[i])) } - require.True(t, sort.IsSorted(Validators(hi.Valset)), "Validators are not sorted") + require.True(t, sort.IsSorted(types.Validators(hi.Valset)), "Validators are not sorted") } func TestValidateBasic(t *testing.T) { validators := createValidators(t) - hi := HistoricalInfo{ + hi := types.HistoricalInfo{ Header: header, } - err := ValidateBasic(hi) + err := types.ValidateBasic(hi) require.Error(t, err, "ValidateBasic passed on nil ValSet") // Ensure validators are not sorted - for sort.IsSorted(Validators(validators)) { + for sort.IsSorted(types.Validators(validators)) { rand.Shuffle(len(validators), func(i, j int) { it := validators[i] validators[i] = validators[j] validators[j] = it }) } - hi = HistoricalInfo{ + hi = types.HistoricalInfo{ Header: header, Valset: validators, } - err = ValidateBasic(hi) + err = types.ValidateBasic(hi) require.Error(t, err, "ValidateBasic passed on unsorted ValSet") - hi = NewHistoricalInfo(header, validators) - err = ValidateBasic(hi) + hi = types.NewHistoricalInfo(header, validators) + err = types.ValidateBasic(hi) require.NoError(t, err, "ValidateBasic failed on valid HistoricalInfo") } diff --git a/x/staking/types/keys.go b/x/staking/types/keys.go index 71aa58750..40d62244a 100644 --- a/x/staking/types/keys.go +++ b/x/staking/types/keys.go @@ -71,17 +71,8 @@ func AddressFromLastValidatorPowerKey(key []byte) []byte { // VALUE: validator operator address ([]byte) func GetValidatorsByPowerIndexKey(validator Validator) []byte { // NOTE the address doesn't need to be stored because counter bytes must always be different - return getValidatorPowerRank(validator) -} + // NOTE the larger values are of higher value -// get the bonded validator index key for an operator address -func GetLastValidatorPowerKey(operator sdk.ValAddress) []byte { - return append(LastValidatorPowerKey, operator...) -} - -// get the power ranking of a validator -// NOTE the larger values are of higher value -func getValidatorPowerRank(validator Validator) []byte { consensusPower := sdk.TokensToConsensusPower(validator.Tokens) consensusPowerBytes := make([]byte, 8) binary.BigEndian.PutUint64(consensusPowerBytes, uint64(consensusPower)) @@ -109,6 +100,11 @@ func getValidatorPowerRank(validator Validator) []byte { return key } +// get the bonded validator index key for an operator address +func GetLastValidatorPowerKey(operator sdk.ValAddress) []byte { + return append(LastValidatorPowerKey, operator...) +} + // parse the validators operator address from power rank key func ParseValidatorPowerRankKey(key []byte) (operAddr []byte) { powerBytesLen := 8 diff --git a/x/staking/types/keys_test.go b/x/staking/types/keys_test.go index 3569b126c..0f63617f2 100644 --- a/x/staking/types/keys_test.go +++ b/x/staking/types/keys_test.go @@ -1,4 +1,4 @@ -package types +package types_test import ( "bytes" @@ -11,6 +11,7 @@ import ( "github.com/cosmos/cosmos-sdk/crypto/keys/ed25519" sdk "github.com/cosmos/cosmos-sdk/types" + "github.com/cosmos/cosmos-sdk/x/staking/types" ) var ( @@ -33,7 +34,7 @@ func TestGetValidatorPowerRank(t *testing.T) { val4.Tokens = sdk.TokensFromConsensusPower(x.Int64()) tests := []struct { - validator Validator + validator types.Validator wantHex string }{ {val1, "2300000000000000009c288ede7df62742fc3b7d0962045a8cef0f79f6"}, @@ -42,7 +43,7 @@ func TestGetValidatorPowerRank(t *testing.T) { {val4, "2300000100000000009c288ede7df62742fc3b7d0962045a8cef0f79f6"}, } for i, tt := range tests { - got := hex.EncodeToString(getValidatorPowerRank(tt.validator)) + got := hex.EncodeToString(types.GetValidatorsByPowerIndexKey(tt.validator)) require.Equal(t, tt.wantHex, got, "Keys did not match on test case %d", i) } @@ -63,7 +64,7 @@ func TestGetREDByValDstIndexKey(t *testing.T) { "363ab62f0d93849be495e21e3e9013a517038f45bd5ef3b5f25c54946d4a89fc0d09d2f126614540f263d771218209d8bd03c482f69dfba57310f08609"}, } for i, tt := range tests { - got := hex.EncodeToString(GetREDByValDstIndexKey(tt.delAddr, tt.valSrcAddr, tt.valDstAddr)) + got := hex.EncodeToString(types.GetREDByValDstIndexKey(tt.delAddr, tt.valSrcAddr, tt.valDstAddr)) require.Equal(t, tt.wantHex, got, "Keys did not match on test case %d", i) } @@ -84,7 +85,7 @@ func TestGetREDByValSrcIndexKey(t *testing.T) { "3563d771218209d8bd03c482f69dfba57310f086095ef3b5f25c54946d4a89fc0d09d2f126614540f23ab62f0d93849be495e21e3e9013a517038f45bd"}, } for i, tt := range tests { - got := hex.EncodeToString(GetREDByValSrcIndexKey(tt.delAddr, tt.valSrcAddr, tt.valDstAddr)) + got := hex.EncodeToString(types.GetREDByValSrcIndexKey(tt.delAddr, tt.valSrcAddr, tt.valDstAddr)) require.Equal(t, tt.wantHex, got, "Keys did not match on test case %d", i) } @@ -94,8 +95,8 @@ func TestGetValidatorQueueKey(t *testing.T) { ts := time.Now() height := int64(1024) - bz := GetValidatorQueueKey(ts, height) - rTs, rHeight, err := ParseValidatorQueueKey(bz) + bz := types.GetValidatorQueueKey(ts, height) + rTs, rHeight, err := types.ParseValidatorQueueKey(bz) require.NoError(t, err) require.Equal(t, ts.UTC(), rTs.UTC()) require.Equal(t, rHeight, height) @@ -105,11 +106,11 @@ func TestTestGetValidatorQueueKeyOrder(t *testing.T) { ts := time.Now().UTC() height := int64(1000) - endKey := GetValidatorQueueKey(ts, height) + endKey := types.GetValidatorQueueKey(ts, height) - keyA := GetValidatorQueueKey(ts.Add(-10*time.Minute), height-10) - keyB := GetValidatorQueueKey(ts.Add(-5*time.Minute), height+50) - keyC := GetValidatorQueueKey(ts.Add(10*time.Minute), height+100) + keyA := types.GetValidatorQueueKey(ts.Add(-10*time.Minute), height-10) + keyB := types.GetValidatorQueueKey(ts.Add(-5*time.Minute), height+50) + keyC := types.GetValidatorQueueKey(ts.Add(10*time.Minute), height+100) require.Equal(t, -1, bytes.Compare(keyA, endKey)) // keyA <= endKey require.Equal(t, -1, bytes.Compare(keyB, endKey)) // keyB <= endKey diff --git a/x/staking/types/msg.go b/x/staking/types/msg.go index 51e19ac26..85d0c1d3c 100644 --- a/x/staking/types/msg.go +++ b/x/staking/types/msg.go @@ -3,9 +3,8 @@ package types import ( "bytes" - "github.com/tendermint/tendermint/crypto" - codectypes "github.com/cosmos/cosmos-sdk/codec/types" + cryptotypes "github.com/cosmos/cosmos-sdk/crypto/types" sdk "github.com/cosmos/cosmos-sdk/types" sdkerrors "github.com/cosmos/cosmos-sdk/types/errors" ) @@ -32,7 +31,7 @@ var ( // NewMsgCreateValidator creates a new MsgCreateValidator instance. // Delegator address and validator address are the same. func NewMsgCreateValidator( - valAddr sdk.ValAddress, pubKey crypto.PubKey, selfDelegation sdk.Coin, + valAddr sdk.ValAddress, pubKey cryptotypes.PubKey, selfDelegation sdk.Coin, description Description, commission CommissionRates, minSelfDelegation sdk.Int, ) (*MsgCreateValidator, error) { pkAny, err := codectypes.PackAny(pubKey) @@ -140,7 +139,7 @@ func (msg MsgCreateValidator) ValidateBasic() error { // UnpackInterfaces implements UnpackInterfacesMessage.UnpackInterfaces func (msg MsgCreateValidator) UnpackInterfaces(unpacker codectypes.AnyUnpacker) error { - var pubKey crypto.PubKey + var pubKey cryptotypes.PubKey return unpacker.UnpackAny(msg.Pubkey, &pubKey) } diff --git a/x/staking/types/msg_test.go b/x/staking/types/msg_test.go index eb83b3316..3b858a64d 100644 --- a/x/staking/types/msg_test.go +++ b/x/staking/types/msg_test.go @@ -1,10 +1,9 @@ -package types +package types_test import ( "testing" "github.com/stretchr/testify/require" - "github.com/tendermint/tendermint/crypto" "github.com/cosmos/cosmos-sdk/codec" codectypes "github.com/cosmos/cosmos-sdk/codec/types" @@ -12,6 +11,7 @@ import ( "github.com/cosmos/cosmos-sdk/crypto/keys/ed25519" cryptotypes "github.com/cosmos/cosmos-sdk/crypto/types" sdk "github.com/cosmos/cosmos-sdk/types" + "github.com/cosmos/cosmos-sdk/x/staking/types" ) var ( @@ -22,7 +22,7 @@ var ( func TestMsgDecode(t *testing.T) { registry := codectypes.NewInterfaceRegistry() cryptocodec.RegisterInterfaces(registry) - RegisterInterfaces(registry) + types.RegisterInterfaces(registry) cdc := codec.NewProtoCodec(registry) // firstly we start testing the pubkey serialization @@ -36,8 +36,8 @@ func TestMsgDecode(t *testing.T) { // now let's try to serialize the whole message - commission1 := NewCommissionRates(sdk.ZeroDec(), sdk.ZeroDec(), sdk.ZeroDec()) - msg, err := NewMsgCreateValidator(valAddr1, pk1, coinPos, Description{}, commission1, sdk.OneInt()) + commission1 := types.NewCommissionRates(sdk.ZeroDec(), sdk.ZeroDec(), sdk.ZeroDec()) + msg, err := types.NewMsgCreateValidator(valAddr1, pk1, coinPos, types.Description{}, commission1, sdk.OneInt()) require.NoError(t, err) msgSerialized, err := codec.MarshalAny(cdc, msg) require.NoError(t, err) @@ -45,7 +45,7 @@ func TestMsgDecode(t *testing.T) { var msgUnmarshaled sdk.Msg err = codec.UnmarshalAny(cdc, &msgUnmarshaled, msgSerialized) require.NoError(t, err) - msg2, ok := msgUnmarshaled.(*MsgCreateValidator) + msg2, ok := msgUnmarshaled.(*types.MsgCreateValidator) require.True(t, ok) require.True(t, msg.Value.IsEqual(msg2.Value)) require.True(t, msg.Pubkey.Equal(msg2.Pubkey)) @@ -53,15 +53,15 @@ func TestMsgDecode(t *testing.T) { // test ValidateBasic for MsgCreateValidator func TestMsgCreateValidator(t *testing.T) { - commission1 := NewCommissionRates(sdk.ZeroDec(), sdk.ZeroDec(), sdk.ZeroDec()) - commission2 := NewCommissionRates(sdk.NewDec(5), sdk.NewDec(5), sdk.NewDec(5)) + commission1 := types.NewCommissionRates(sdk.ZeroDec(), sdk.ZeroDec(), sdk.ZeroDec()) + commission2 := types.NewCommissionRates(sdk.NewDec(5), sdk.NewDec(5), sdk.NewDec(5)) tests := []struct { name, moniker, identity, website, securityContact, details string - CommissionRates CommissionRates + CommissionRates types.CommissionRates minSelfDelegation sdk.Int validatorAddr sdk.ValAddress - pubkey crypto.PubKey + pubkey cryptotypes.PubKey bond sdk.Coin expectPass bool }{ @@ -79,8 +79,8 @@ func TestMsgCreateValidator(t *testing.T) { for _, tc := range tests { t.Logf("Test: %s, pk=%t", tc.name, tc.pubkey) - description := NewDescription(tc.moniker, tc.identity, tc.website, tc.securityContact, tc.details) - msg, err := NewMsgCreateValidator(tc.validatorAddr, tc.pubkey, tc.bond, description, tc.CommissionRates, tc.minSelfDelegation) + description := types.NewDescription(tc.moniker, tc.identity, tc.website, tc.securityContact, tc.details) + msg, err := types.NewMsgCreateValidator(tc.validatorAddr, tc.pubkey, tc.bond, description, tc.CommissionRates, tc.minSelfDelegation) require.NoError(t, err) if tc.expectPass { require.Nil(t, msg.ValidateBasic(), "test: %v", tc.name) @@ -106,10 +106,10 @@ func TestMsgEditValidator(t *testing.T) { } for _, tc := range tests { - description := NewDescription(tc.moniker, tc.identity, tc.website, tc.securityContact, tc.details) + description := types.NewDescription(tc.moniker, tc.identity, tc.website, tc.securityContact, tc.details) newRate := sdk.ZeroDec() - msg := NewMsgEditValidator(tc.validatorAddr, description, &newRate, &tc.minSelfDelegation) + msg := types.NewMsgEditValidator(tc.validatorAddr, description, &newRate, &tc.minSelfDelegation) if tc.expectPass { require.Nil(t, msg.ValidateBasic(), "test: %v", tc.name) } else { @@ -136,7 +136,7 @@ func TestMsgDelegate(t *testing.T) { } for _, tc := range tests { - msg := NewMsgDelegate(tc.delegatorAddr, tc.validatorAddr, tc.bond) + msg := types.NewMsgDelegate(tc.delegatorAddr, tc.validatorAddr, tc.bond) if tc.expectPass { require.Nil(t, msg.ValidateBasic(), "test: %v", tc.name) } else { @@ -164,7 +164,7 @@ func TestMsgBeginRedelegate(t *testing.T) { } for _, tc := range tests { - msg := NewMsgBeginRedelegate(tc.delegatorAddr, tc.validatorSrcAddr, tc.validatorDstAddr, tc.amount) + msg := types.NewMsgBeginRedelegate(tc.delegatorAddr, tc.validatorSrcAddr, tc.validatorDstAddr, tc.amount) if tc.expectPass { require.Nil(t, msg.ValidateBasic(), "test: %v", tc.name) } else { @@ -190,7 +190,7 @@ func TestMsgUndelegate(t *testing.T) { } for _, tc := range tests { - msg := NewMsgUndelegate(tc.delegatorAddr, tc.validatorAddr, tc.amount) + msg := types.NewMsgUndelegate(tc.delegatorAddr, tc.validatorAddr, tc.amount) if tc.expectPass { require.Nil(t, msg.ValidateBasic(), "test: %v", tc.name) } else { diff --git a/x/staking/types/params_test.go b/x/staking/types/params_test.go index c18700ef4..05a7ea956 100644 --- a/x/staking/types/params_test.go +++ b/x/staking/types/params_test.go @@ -1,14 +1,15 @@ -package types +package types_test import ( "testing" + "github.com/cosmos/cosmos-sdk/x/staking/types" "github.com/stretchr/testify/require" ) func TestParamsEqual(t *testing.T) { - p1 := DefaultParams() - p2 := DefaultParams() + p1 := types.DefaultParams() + p2 := types.DefaultParams() ok := p1.Equal(p2) require.True(t, ok) diff --git a/x/staking/types/validator.go b/x/staking/types/validator.go index 19e032dba..c99aafd4c 100644 --- a/x/staking/types/validator.go +++ b/x/staking/types/validator.go @@ -8,13 +8,12 @@ import ( "time" abci "github.com/tendermint/tendermint/abci/types" - "github.com/tendermint/tendermint/crypto" - "github.com/tendermint/tendermint/crypto/encoding" - tmtypes "github.com/tendermint/tendermint/types" + tmprotocrypto "github.com/tendermint/tendermint/proto/tendermint/crypto" "gopkg.in/yaml.v2" "github.com/cosmos/cosmos-sdk/codec" codectypes "github.com/cosmos/cosmos-sdk/codec/types" + cryptocodec "github.com/cosmos/cosmos-sdk/crypto/codec" cryptotypes "github.com/cosmos/cosmos-sdk/crypto/types" sdk "github.com/cosmos/cosmos-sdk/types" sdkerrors "github.com/cosmos/cosmos-sdk/types/errors" @@ -40,7 +39,7 @@ var _ ValidatorI = Validator{} // NewValidator constructs a new Validator //nolint:interfacer -func NewValidator(operator sdk.ValAddress, pubKey crypto.PubKey, description Description) (Validator, error) { +func NewValidator(operator sdk.ValAddress, pubKey cryptotypes.PubKey, description Description) (Validator, error) { pkAny, err := codectypes.PackAny(pubKey) if err != nil { return Validator{}, err @@ -78,7 +77,7 @@ func (v Validators) String() (out string) { return strings.TrimSpace(out) } -// ToSDKValidators - convenience function convert []Validators to []sdk.Validators +// ToSDKValidators - convenience function convert []Validator to []sdk.ValidatorI func (v Validators) ToSDKValidators() (validators []ValidatorI) { for _, val := range v { validators = append(validators, val) @@ -87,20 +86,6 @@ func (v Validators) ToSDKValidators() (validators []ValidatorI) { return validators } -// ToTmValidators casts all validators to the corresponding tendermint type. -func (v Validators) ToTmValidators() ([]*tmtypes.Validator, error) { - validators := make([]*tmtypes.Validator, len(v)) - var err error - for i, val := range v { - validators[i], err = val.ToTmValidator() - if err != nil { - return nil, err - } - } - - return validators, nil -} - // Sort Validators sorts validator array in ascending operator address order func (v Validators) Sort() { sort.Sort(v) @@ -273,17 +258,13 @@ func (d Description) EnsureLength() (Description, error) { // ABCIValidatorUpdate returns an abci.ValidatorUpdate from a staking validator type // with the full validator power func (v Validator) ABCIValidatorUpdate() abci.ValidatorUpdate { - consPk, err := v.TmConsPubKey() - if err != nil { - panic(err) - } - pk, err := encoding.PubKeyToProto(consPk) + tmProtoPk, err := v.TmConsPublicKey() if err != nil { panic(err) } return abci.ValidatorUpdate{ - PubKey: pk, + PubKey: tmProtoPk, Power: v.ConsensusPower(), } } @@ -291,30 +272,17 @@ func (v Validator) ABCIValidatorUpdate() abci.ValidatorUpdate { // ABCIValidatorUpdateZero returns an abci.ValidatorUpdate from a staking validator type // with zero power used for validator updates. func (v Validator) ABCIValidatorUpdateZero() abci.ValidatorUpdate { - consPk, err := v.TmConsPubKey() - if err != nil { - panic(err) - } - pk, err := encoding.PubKeyToProto(consPk) + tmProtoPk, err := v.TmConsPublicKey() if err != nil { panic(err) } return abci.ValidatorUpdate{ - PubKey: pk, + PubKey: tmProtoPk, Power: 0, } } -// ToTmValidator casts an SDK validator to a tendermint type Validator. -func (v Validator) ToTmValidator() (*tmtypes.Validator, error) { - consPk, err := v.TmConsPubKey() - if err != nil { - return nil, err - } - return tmtypes.NewValidator(consPk, v.ConsensusPower()), nil -} - // SetInitialCommission attempts to set a validator's initial commission. An // error is returned if the commission is invalid. func (v Validator) SetInitialCommission(commission Commission) (Validator, error) { @@ -379,8 +347,8 @@ func (v Validator) BondedTokens() sdk.Int { return sdk.ZeroInt() } -// get the consensus-engine power -// a reduction of 10^6 from validator tokens is applied +// ConsensusPower gets the consensus-engine power. Aa reduction of 10^6 from +// validator tokens is applied func (v Validator) ConsensusPower() int64 { if v.IsBonded() { return v.PotentialConsensusPower() @@ -389,7 +357,7 @@ func (v Validator) ConsensusPower() int64 { return 0 } -// potential consensus-engine power +// PotentialConsensusPower returns the potential consensus-engine power. func (v Validator) PotentialConsensusPower() int64 { return sdk.TokensToConsensusPower(v.Tokens) } @@ -501,30 +469,39 @@ func (v Validator) GetOperator() sdk.ValAddress { return addr } -// TmConsPubKey casts Validator.ConsensusPubkey to crypto.PubKey -func (v Validator) TmConsPubKey() (crypto.PubKey, error) { +// ConsPubKey returns the validator PubKey as a cryptotypes.PubKey. +func (v Validator) ConsPubKey() (cryptotypes.PubKey, error) { pk, ok := v.ConsensusPubkey.GetCachedValue().(cryptotypes.PubKey) if !ok { - return nil, sdkerrors.Wrapf(sdkerrors.ErrInvalidType, "Expecting crypto.PubKey, got %T", pk) + return nil, sdkerrors.Wrapf(sdkerrors.ErrInvalidType, "expecting cryptotypes.PubKey, got %T", pk) } - // The way things are refactored now, v.ConsensusPubkey is sometimes a TM - // ed25519 pubkey, sometimes our own ed25519 pubkey. This is very ugly and - // inconsistent. - // Luckily, here we coerce it into a TM ed25519 pubkey always, as this - // pubkey will be passed into TM (eg calling encoding.PubKeyToProto). - if intoTmPk, ok := pk.(cryptotypes.IntoTmPubKey); ok { - return intoTmPk.AsTmPubKey(), nil + return pk, nil + +} + +// TmConsPublicKey casts Validator.ConsensusPubkey to tmprotocrypto.PubKey. +func (v Validator) TmConsPublicKey() (tmprotocrypto.PublicKey, error) { + pk, err := v.ConsPubKey() + if err != nil { + return tmprotocrypto.PublicKey{}, err } - return nil, sdkerrors.Wrapf(sdkerrors.ErrInvalidPubKey, "Logic error: ConsensusPubkey must be an SDK key and SDK PubKey types must be convertible to tendermint PubKey; got: %T", pk) + + tmPk, err := cryptocodec.ToTmProtoPublicKey(pk) + if err != nil { + return tmprotocrypto.PublicKey{}, err + } + + return tmPk, nil } // GetConsAddr extracts Consensus key address func (v Validator) GetConsAddr() (sdk.ConsAddress, error) { - pk, err := v.TmConsPubKey() - if err != nil { - return sdk.ConsAddress{}, err + pk, ok := v.ConsensusPubkey.GetCachedValue().(cryptotypes.PubKey) + if !ok { + return nil, sdkerrors.Wrapf(sdkerrors.ErrInvalidType, "expecting cryptotypes.PubKey, got %T", pk) } + return sdk.ConsAddress(pk.Address()), nil } @@ -537,6 +514,6 @@ func (v Validator) GetDelegatorShares() sdk.Dec { return v.DelegatorShares } // UnpackInterfaces implements UnpackInterfacesMessage.UnpackInterfaces func (v Validator) UnpackInterfaces(unpacker codectypes.AnyUnpacker) error { - var pk crypto.PubKey + var pk cryptotypes.PubKey return unpacker.UnpackAny(v.ConsensusPubkey, &pk) } diff --git a/x/staking/types/validator_test.go b/x/staking/types/validator_test.go index 64afc9768..08204215d 100644 --- a/x/staking/types/validator_test.go +++ b/x/staking/types/validator_test.go @@ -1,4 +1,4 @@ -package types +package types_test import ( "math/rand" @@ -7,14 +7,15 @@ import ( "github.com/stretchr/testify/assert" "github.com/stretchr/testify/require" - "github.com/tendermint/tendermint/crypto" - "github.com/tendermint/tendermint/crypto/encoding" tmtypes "github.com/tendermint/tendermint/types" "github.com/cosmos/cosmos-sdk/codec/legacy" + cryptocodec "github.com/cosmos/cosmos-sdk/crypto/codec" "github.com/cosmos/cosmos-sdk/crypto/keys/ed25519" cryptotypes "github.com/cosmos/cosmos-sdk/crypto/types" sdk "github.com/cosmos/cosmos-sdk/types" + "github.com/cosmos/cosmos-sdk/x/staking/teststaking" + "github.com/cosmos/cosmos-sdk/x/staking/types" ) func TestValidatorTestEquivalent(t *testing.T) { @@ -27,19 +28,19 @@ func TestValidatorTestEquivalent(t *testing.T) { } func TestUpdateDescription(t *testing.T) { - d1 := Description{ + d1 := types.Description{ Website: "https://validator.cosmos", Details: "Test validator", } - d2 := Description{ - Moniker: DoNotModifyDesc, - Identity: DoNotModifyDesc, - Website: DoNotModifyDesc, - Details: DoNotModifyDesc, + d2 := types.Description{ + Moniker: types.DoNotModifyDesc, + Identity: types.DoNotModifyDesc, + Website: types.DoNotModifyDesc, + Details: types.DoNotModifyDesc, } - d3 := Description{ + d3 := types.Description{ Moniker: "", Identity: "", Website: "", @@ -58,9 +59,7 @@ func TestUpdateDescription(t *testing.T) { func TestABCIValidatorUpdate(t *testing.T) { validator := newValidator(t, valAddr1, pk1) abciVal := validator.ABCIValidatorUpdate() - consPk, err := validator.TmConsPubKey() - require.NoError(t, err) - pk, err := encoding.PubKeyToProto(consPk) + pk, err := validator.TmConsPublicKey() require.NoError(t, err) require.Equal(t, pk, abciVal.PubKey) require.Equal(t, validator.BondedTokens().Int64(), abciVal.Power) @@ -69,9 +68,7 @@ func TestABCIValidatorUpdate(t *testing.T) { func TestABCIValidatorUpdateZero(t *testing.T) { validator := newValidator(t, valAddr1, pk1) abciVal := validator.ABCIValidatorUpdateZero() - consPk, err := validator.TmConsPubKey() - require.NoError(t, err) - pk, err := encoding.PubKeyToProto(consPk) + pk, err := validator.TmConsPublicKey() require.NoError(t, err) require.Equal(t, pk, abciVal.PubKey) require.Equal(t, int64(0), abciVal.Power) @@ -94,8 +91,8 @@ func TestRemoveTokens(t *testing.T) { require.Equal(t, int64(90), validator.Tokens.Int64()) // update validator to from bonded -> unbonded - validator = validator.UpdateStatus(Unbonded) - require.Equal(t, Unbonded, validator.Status) + validator = validator.UpdateStatus(types.Unbonded) + require.Equal(t, types.Unbonded, validator.Status) validator = validator.RemoveTokens(sdk.NewInt(10)) require.Panics(t, func() { validator.RemoveTokens(sdk.NewInt(-1)) }) @@ -104,7 +101,7 @@ func TestRemoveTokens(t *testing.T) { func TestAddTokensValidatorBonded(t *testing.T) { validator := newValidator(t, valAddr1, pk1) - validator = validator.UpdateStatus(Bonded) + validator = validator.UpdateStatus(types.Bonded) validator, delShares := validator.AddTokensFromDel(sdk.NewInt(10)) assert.True(sdk.DecEq(t, sdk.NewDec(10), delShares)) @@ -114,11 +111,11 @@ func TestAddTokensValidatorBonded(t *testing.T) { func TestAddTokensValidatorUnbonding(t *testing.T) { validator := newValidator(t, valAddr1, pk1) - validator = validator.UpdateStatus(Unbonding) + validator = validator.UpdateStatus(types.Unbonding) validator, delShares := validator.AddTokensFromDel(sdk.NewInt(10)) assert.True(sdk.DecEq(t, sdk.NewDec(10), delShares)) - assert.Equal(t, Unbonding, validator.Status) + assert.Equal(t, types.Unbonding, validator.Status) assert.True(sdk.IntEq(t, sdk.NewInt(10), validator.Tokens)) assert.True(sdk.DecEq(t, sdk.NewDec(10), validator.DelegatorShares)) } @@ -126,21 +123,21 @@ func TestAddTokensValidatorUnbonding(t *testing.T) { func TestAddTokensValidatorUnbonded(t *testing.T) { validator := newValidator(t, valAddr1, pk1) - validator = validator.UpdateStatus(Unbonded) + validator = validator.UpdateStatus(types.Unbonded) validator, delShares := validator.AddTokensFromDel(sdk.NewInt(10)) assert.True(sdk.DecEq(t, sdk.NewDec(10), delShares)) - assert.Equal(t, Unbonded, validator.Status) + assert.Equal(t, types.Unbonded, validator.Status) assert.True(sdk.IntEq(t, sdk.NewInt(10), validator.Tokens)) assert.True(sdk.DecEq(t, sdk.NewDec(10), validator.DelegatorShares)) } // TODO refactor to make simpler like the AddToken tests above func TestRemoveDelShares(t *testing.T) { - valA := Validator{ + valA := types.Validator{ OperatorAddress: valAddr1.String(), ConsensusPubkey: pk1Any, - Status: Bonded, + Status: types.Bonded, Tokens: sdk.NewInt(100), DelegatorShares: sdk.NewDec(100), } @@ -175,20 +172,20 @@ func TestAddTokensFromDel(t *testing.T) { func TestUpdateStatus(t *testing.T) { validator := newValidator(t, valAddr1, pk1) validator, _ = validator.AddTokensFromDel(sdk.NewInt(100)) - require.Equal(t, Unbonded, validator.Status) + require.Equal(t, types.Unbonded, validator.Status) require.Equal(t, int64(100), validator.Tokens.Int64()) // Unbonded to Bonded - validator = validator.UpdateStatus(Bonded) - require.Equal(t, Bonded, validator.Status) + validator = validator.UpdateStatus(types.Bonded) + require.Equal(t, types.Bonded, validator.Status) // Bonded to Unbonding - validator = validator.UpdateStatus(Unbonding) - require.Equal(t, Unbonding, validator.Status) + validator = validator.UpdateStatus(types.Unbonding) + require.Equal(t, types.Unbonding, validator.Status) // Unbonding to Bonded - validator = validator.UpdateStatus(Bonded) - require.Equal(t, Bonded, validator.Status) + validator = validator.UpdateStatus(types.Bonded) + require.Equal(t, types.Bonded, validator.Status) } func TestPossibleOverflow(t *testing.T) { @@ -205,8 +202,8 @@ func TestValidatorMarshalUnmarshalJSON(t *testing.T) { js, err := legacy.Cdc.MarshalJSON(validator) require.NoError(t, err) require.NotEmpty(t, js) - require.Contains(t, string(js), "\"consensus_pubkey\":{\"type\":\"cosmos/PubKeyEd25519\"") - got := &Validator{} + require.Contains(t, string(js), "\"consensus_pubkey\":{\"type\":\"tendermint/PubKeyEd25519\"") + got := &types.Validator{} err = legacy.Cdc.UnmarshalJSON(js, got) assert.NoError(t, err) assert.True(t, validator.Equal(got)) @@ -215,17 +212,17 @@ func TestValidatorMarshalUnmarshalJSON(t *testing.T) { func TestValidatorSetInitialCommission(t *testing.T) { val := newValidator(t, valAddr1, pk1) testCases := []struct { - validator Validator - commission Commission + validator types.Validator + commission types.Commission expectedErr bool }{ - {val, NewCommission(sdk.ZeroDec(), sdk.ZeroDec(), sdk.ZeroDec()), false}, - {val, NewCommission(sdk.ZeroDec(), sdk.NewDecWithPrec(-1, 1), sdk.ZeroDec()), true}, - {val, NewCommission(sdk.ZeroDec(), sdk.NewDec(15000000000), sdk.ZeroDec()), true}, - {val, NewCommission(sdk.NewDecWithPrec(-1, 1), sdk.ZeroDec(), sdk.ZeroDec()), true}, - {val, NewCommission(sdk.NewDecWithPrec(2, 1), sdk.NewDecWithPrec(1, 1), sdk.ZeroDec()), true}, - {val, NewCommission(sdk.ZeroDec(), sdk.ZeroDec(), sdk.NewDecWithPrec(-1, 1)), true}, - {val, NewCommission(sdk.ZeroDec(), sdk.NewDecWithPrec(1, 1), sdk.NewDecWithPrec(2, 1)), true}, + {val, types.NewCommission(sdk.ZeroDec(), sdk.ZeroDec(), sdk.ZeroDec()), false}, + {val, types.NewCommission(sdk.ZeroDec(), sdk.NewDecWithPrec(-1, 1), sdk.ZeroDec()), true}, + {val, types.NewCommission(sdk.ZeroDec(), sdk.NewDec(15000000000), sdk.ZeroDec()), true}, + {val, types.NewCommission(sdk.NewDecWithPrec(-1, 1), sdk.ZeroDec(), sdk.ZeroDec()), true}, + {val, types.NewCommission(sdk.NewDecWithPrec(2, 1), sdk.NewDecWithPrec(1, 1), sdk.ZeroDec()), true}, + {val, types.NewCommission(sdk.ZeroDec(), sdk.ZeroDec(), sdk.NewDecWithPrec(-1, 1)), true}, + {val, types.NewCommission(sdk.ZeroDec(), sdk.NewDecWithPrec(1, 1), sdk.NewDecWithPrec(2, 1)), true}, } for i, tc := range testCases { @@ -248,8 +245,8 @@ func TestValidatorSetInitialCommission(t *testing.T) { // Check that sort will create deterministic ordering of validators func TestValidatorsSortDeterminism(t *testing.T) { - vals := make([]Validator, 10) - sortedVals := make([]Validator, 10) + vals := make([]types.Validator, 10) + sortedVals := make([]types.Validator, 10) // Create random validator slice for i := range vals { @@ -258,7 +255,7 @@ func TestValidatorsSortDeterminism(t *testing.T) { } // Save sorted copy - sort.Sort(Validators(vals)) + sort.Sort(types.Validators(vals)) copy(sortedVals, vals) // Randomly shuffle validators, sort, and check it is equal to original sort @@ -269,20 +266,20 @@ func TestValidatorsSortDeterminism(t *testing.T) { vals[j] = it }) - Validators(vals).Sort() + types.Validators(vals).Sort() require.Equal(t, sortedVals, vals, "Validator sort returned different slices") } } // Check SortTendermint sorts the same as tendermint func TestValidatorsSortTendermint(t *testing.T) { - vals := make([]Validator, 100) + vals := make([]types.Validator, 100) for i := range vals { pk := ed25519.GenPrivKey().PubKey() pk2 := ed25519.GenPrivKey().PubKey() vals[i] = newValidator(t, sdk.ValAddress(pk2.Address()), pk) - vals[i].Status = Bonded + vals[i].Status = types.Bonded vals[i].Tokens = sdk.NewInt(rand.Int63()) } // create some validators with the same power @@ -290,62 +287,64 @@ func TestValidatorsSortTendermint(t *testing.T) { vals[i].Tokens = sdk.NewInt(1000000) } - valz := Validators(vals) + valz := types.Validators(vals) // create expected tendermint validators by converting to tendermint then sorting - expectedVals, err := valz.ToTmValidators() + expectedVals, err := teststaking.ToTmValidators(valz) require.NoError(t, err) sort.Sort(tmtypes.ValidatorsByVotingPower(expectedVals)) // sort in SDK and then convert to tendermint - sort.Sort(ValidatorsByVotingPower(valz)) - actualVals, err := valz.ToTmValidators() + sort.Sort(types.ValidatorsByVotingPower(valz)) + actualVals, err := teststaking.ToTmValidators(valz) require.NoError(t, err) require.Equal(t, expectedVals, actualVals, "sorting in SDK is not the same as sorting in Tendermint") } func TestValidatorToTm(t *testing.T) { - vals := make(Validators, 10) + vals := make(types.Validators, 10) expected := make([]*tmtypes.Validator, 10) for i := range vals { pk := ed25519.GenPrivKey().PubKey() val := newValidator(t, sdk.ValAddress(pk.Address()), pk) - val.Status = Bonded + val.Status = types.Bonded val.Tokens = sdk.NewInt(rand.Int63()) vals[i] = val - expected[i] = tmtypes.NewValidator(pk.(cryptotypes.IntoTmPubKey).AsTmPubKey(), val.ConsensusPower()) + tmPk, err := cryptocodec.ToTmPubKeyInterface(pk) + require.NoError(t, err) + expected[i] = tmtypes.NewValidator(tmPk, val.ConsensusPower()) } - vs, err := vals.ToTmValidators() + vs, err := teststaking.ToTmValidators(vals) require.NoError(t, err) require.Equal(t, expected, vs) } func TestBondStatus(t *testing.T) { - require.False(t, Unbonded == Bonded) - require.False(t, Unbonded == Unbonding) - require.False(t, Bonded == Unbonding) - require.Equal(t, BondStatus(4).String(), "4") - require.Equal(t, BondStatusUnspecified, Unspecified.String()) - require.Equal(t, BondStatusUnbonded, Unbonded.String()) - require.Equal(t, BondStatusBonded, Bonded.String()) - require.Equal(t, BondStatusUnbonding, Unbonding.String()) + require.False(t, types.Unbonded == types.Bonded) + require.False(t, types.Unbonded == types.Unbonding) + require.False(t, types.Bonded == types.Unbonding) + require.Equal(t, types.BondStatus(4).String(), "4") + require.Equal(t, types.BondStatusUnspecified, types.Unspecified.String()) + require.Equal(t, types.BondStatusUnbonded, types.Unbonded.String()) + require.Equal(t, types.BondStatusBonded, types.Bonded.String()) + require.Equal(t, types.BondStatusUnbonding, types.Unbonding.String()) } -func mkValidator(tokens int64, shares sdk.Dec) Validator { - return Validator{ +func mkValidator(tokens int64, shares sdk.Dec) types.Validator { + return types.Validator{ OperatorAddress: valAddr1.String(), ConsensusPubkey: pk1Any, - Status: Bonded, + Status: types.Bonded, Tokens: sdk.NewInt(tokens), DelegatorShares: shares, } } // Creates a new validators and asserts the error check. -func newValidator(t *testing.T, operator sdk.ValAddress, pubKey crypto.PubKey) Validator { - v, err := NewValidator(operator, pubKey, Description{}) +func newValidator(t *testing.T, operator sdk.ValAddress, pubKey cryptotypes.PubKey) types.Validator { + v, err := types.NewValidator(operator, pubKey, types.Description{}) require.NoError(t, err) return v } From 55772aec8ca2c79808e80ed71b6a0340b59473c5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?colin=20axn=C3=A9r?= <25233464+colin-axner@users.noreply.github.com> Date: Mon, 9 Nov 2020 18:12:00 +0100 Subject: [PATCH 13/24] update err to match others (#7857) Co-authored-by: Federico Kunze <31522760+fedekunze@users.noreply.github.com> Co-authored-by: mergify[bot] <37929162+mergify[bot]@users.noreply.github.com> --- x/ibc/light-clients/07-tendermint/types/client_state.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/x/ibc/light-clients/07-tendermint/types/client_state.go b/x/ibc/light-clients/07-tendermint/types/client_state.go index cb6e4630f..4e4104d8d 100644 --- a/x/ibc/light-clients/07-tendermint/types/client_state.go +++ b/x/ibc/light-clients/07-tendermint/types/client_state.go @@ -348,7 +348,7 @@ func (cs ClientState) VerifyPacketCommitment( } if err := merkleProof.VerifyMembership(cs.ProofSpecs, consensusState.GetRoot(), path, commitmentBytes); err != nil { - return sdkerrors.Wrap(clienttypes.ErrFailedPacketCommitmentVerification, err.Error()) + return err } return nil From fe8a891f11dcefe708e43d53549beec808f98687 Mon Sep 17 00:00:00 2001 From: Emmanuel T Odeke Date: Mon, 9 Nov 2020 09:58:13 -0800 Subject: [PATCH 14/24] unknownproto: check result from protowire.ConsumeFieldValue and return an error (#7770) * unknownproto: check result from protowire.ConsumeFieldValue and return error Given that protowire.ConsumeFieldValue returns -1 when it encounters an error, perform a check for n < 0 and return the respectively obtained error with context about the details. Fixes an issue identified from a go-fuzz session, thanks to Ethan Buchman and the IBC auditors from Informal Systems et al. Fixes #7739. * Address AlexanderBez's suggestions * Use require in tests * Add issue #7846 to TODO Co-authored-by: mergify[bot] <37929162+mergify[bot]@users.noreply.github.com> --- codec/unknownproto/regression_test.go | 25 +++++++++++++++++++++++++ codec/unknownproto/unknown_fields.go | 5 +++++ 2 files changed, 30 insertions(+) create mode 100644 codec/unknownproto/regression_test.go diff --git a/codec/unknownproto/regression_test.go b/codec/unknownproto/regression_test.go new file mode 100644 index 000000000..24c4056fb --- /dev/null +++ b/codec/unknownproto/regression_test.go @@ -0,0 +1,25 @@ +package unknownproto_test + +import ( + "encoding/hex" + "io" + "testing" + + "github.com/stretchr/testify/require" + + "github.com/cosmos/cosmos-sdk/simapp" +) + +// Issue #7739: Catch parse errors resulting from unexpected EOF in +// protowire.ConsumeFieldValue. Discovered from fuzzing. +func TestBadBytesPassedIntoDecoder(t *testing.T) { + data, _ := hex.DecodeString("0A9F010A9C200A2D2F6962632E636F72652E636F6E6E656374696F6E2E76312E4D7367436F6E6E656374696F584F75656E496E6974126B0A0D6962637A65726F636C69656E74120B6962637A65726F636F6E6E1A1C0A0C6962636F6E65636C69656E74120A6962636F6E65636F6E6E00002205312E302E302A283235454635364341373935313335453430393336384536444238313130463232413442453035433212080A0612040A0208011A40143342993E25DA936CDDC7BE3D8F603CA6E9661518D536D0C482E18A0154AA096E438A6B9BCADFCFC2F0D689DCCAF55B96399D67A8361B70F5DA13091E2F929") + cfg := simapp.MakeTestEncodingConfig() + decoder := cfg.TxConfig.TxDecoder() + tx, err := decoder(data) + + // TODO: When issue https://github.com/cosmos/cosmos-sdk/issues/7846 + // is addressed, we'll remove this .Contains check. + require.Contains(t, err.Error(), io.ErrUnexpectedEOF.Error()) + require.Nil(t, tx) +} diff --git a/codec/unknownproto/unknown_fields.go b/codec/unknownproto/unknown_fields.go index b2e7a0e06..b9db64296 100644 --- a/codec/unknownproto/unknown_fields.go +++ b/codec/unknownproto/unknown_fields.go @@ -92,6 +92,11 @@ func RejectUnknownFields(bz []byte, msg proto.Message, allowUnknownNonCriticals // Skip over the bytes that store fieldNumber and wireType bytes. bz = bz[m:] n := protowire.ConsumeFieldValue(tagNum, wireType, bz) + if n < 0 { + err = fmt.Errorf("could not consume field value for tagNum: %d, wireType: %q; %w", + tagNum, wireTypeToString(wireType), protowire.ParseError(n)) + return hasUnknownNonCriticals, err + } fieldBytes := bz[:n] bz = bz[n:] From c432e2871bdd3191bb47dfcb2d64b7f6952abaf3 Mon Sep 17 00:00:00 2001 From: Cyrus Goh Date: Mon, 9 Nov 2020 10:26:34 -0800 Subject: [PATCH 15/24] docs: remove v0.40.x from versions --- docs/versions | 1 - 1 file changed, 1 deletion(-) diff --git a/docs/versions b/docs/versions index e55af2fb7..8df09cc78 100644 --- a/docs/versions +++ b/docs/versions @@ -1,3 +1,2 @@ master master -v0.40.x v0.40 launchpad/backports v0.39 \ No newline at end of file From 15b285dd0d707bbf941c535698f3b5bc0b3a84cc Mon Sep 17 00:00:00 2001 From: Amaury Martiny Date: Tue, 10 Nov 2020 14:01:55 +0100 Subject: [PATCH 16/24] Fix creation of local RPC node in clientCtx (#7840) * server: only register the Tx service if the API or gRPC are enabled Only registers the Tx service on an app, if either API or gRPC are enabled. This is because, enabling the service starts a local Tendermint node, which is unnecessary and expensive, if neither of those operations are explicitly enabled. * Fix lint Co-authored-by: Alessio Treglia --- server/start.go | 17 ++++++++++++----- 1 file changed, 12 insertions(+), 5 deletions(-) diff --git a/server/start.go b/server/start.go index 2a2a1af88..b8565a87a 100644 --- a/server/start.go +++ b/server/start.go @@ -252,12 +252,20 @@ func startInProcess(ctx *Context, clientCtx client.Context, appCreator types.App } ctx.Logger.Debug("Initialization: tmNode started") - // Add the tx service to the gRPC router. - app.RegisterTxService(clientCtx) + config := config.GetConfig(ctx.Viper) + + // Add the tx service to the gRPC router. We only need to register this + // service if API or gRPC is enabled, and avoid doing so in the general + // case, because it spawns a new local tendermint RPC client. + if config.API.Enable || config.GRPC.Enable { + clientCtx = clientCtx. + WithClient(local.New(tmNode)) + + app.RegisterTxService(clientCtx) + } var apiSrv *api.Server - config := config.GetConfig(ctx.Viper) if config.API.Enable { genDoc, err := genDocProvider() if err != nil { @@ -266,8 +274,7 @@ func startInProcess(ctx *Context, clientCtx client.Context, appCreator types.App clientCtx := clientCtx. WithHomeDir(home). - WithChainID(genDoc.ChainID). - WithClient(local.New(tmNode)) + WithChainID(genDoc.ChainID) apiSrv = api.New(clientCtx, ctx.Logger.With("module", "api-server")) app.RegisterAPIRoutes(apiSrv, config.API) From fdcb028636c940b94387ad86b83959aab4b92cde Mon Sep 17 00:00:00 2001 From: Aditya Date: Tue, 10 Nov 2020 14:39:09 +0000 Subject: [PATCH 17/24] ibc: proof fixes (#7869) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * change proof proto def * progress fixing tests * complete proof restructure * remove use of KeyPath * improve error msgs * docs and lint * Apply suggestions from code review Co-authored-by: Federico Kunze <31522760+fedekunze@users.noreply.github.com> Co-authored-by: colin axnér <25233464+colin-axner@users.noreply.github.com> * address code review * fix string tests * add ConvertProofs tests * Apply suggestions from code review Co-authored-by: colin axnér <25233464+colin-axner@users.noreply.github.com> Co-authored-by: Federico Kunze <31522760+fedekunze@users.noreply.github.com> Co-authored-by: colin axnér <25233464+colin-axner@users.noreply.github.com> --- proto/ibc/core/commitment/v1/commitment.proto | 38 +- x/ibc/core/03-connection/types/msgs_test.go | 5 +- x/ibc/core/04-channel/keeper/keeper_test.go | 3 + x/ibc/core/04-channel/types/msgs_test.go | 5 +- .../core/23-commitment/types/commitment.pb.go | 524 +------- x/ibc/core/23-commitment/types/key_path.go | 40 - x/ibc/core/23-commitment/types/merkle.go | 187 +-- x/ibc/core/23-commitment/types/merkle_test.go | 58 +- x/ibc/core/23-commitment/types/utils.go | 27 + x/ibc/core/23-commitment/types/utils_test.go | 97 ++ x/ibc/core/client/query.go | 5 +- x/ibc/core/keeper/msg_server_test.go | 3 + .../06-solomachine/types/client_state.go | 22 +- .../07-tendermint/types/client_state.go | 22 +- .../07-tendermint/types/tendermint_test.go | 3 + .../07-tendermint/types/upgrade.go | 2 +- x/ibc/testing/chain.go | 10 +- x/ibc/testing/solomachine.go | 22 +- x/staking/types/staking.pb.go | 1184 +++++++++-------- 19 files changed, 980 insertions(+), 1277 deletions(-) delete mode 100644 x/ibc/core/23-commitment/types/key_path.go create mode 100644 x/ibc/core/23-commitment/types/utils.go create mode 100644 x/ibc/core/23-commitment/types/utils_test.go diff --git a/proto/ibc/core/commitment/v1/commitment.proto b/proto/ibc/core/commitment/v1/commitment.proto index 0ed6be0f2..9e9d22f08 100644 --- a/proto/ibc/core/commitment/v1/commitment.proto +++ b/proto/ibc/core/commitment/v1/commitment.proto @@ -4,7 +4,7 @@ package ibc.core.commitment.v1; option go_package = "github.com/cosmos/cosmos-sdk/x/ibc/core/23-commitment/types"; import "gogoproto/gogo.proto"; -import "tendermint/crypto/proof.proto"; +import "confio/proofs.proto"; // MerkleRoot defines a merkle root hash. // In the Cosmos SDK, the AppHash of a block header becomes the root. @@ -23,42 +23,18 @@ message MerklePrefix { // MerklePath is the path used to verify commitment proofs, which can be an // arbitrary structured object (defined by a commitment type). +// MerklePath is represented from root-to-leaf message MerklePath { option (gogoproto.goproto_stringer) = false; - KeyPath key_path = 1 [(gogoproto.nullable) = false, (gogoproto.moretags) = "yaml:\"key_path\""]; + repeated string key_path = 1 [(gogoproto.moretags) = "yaml:\"key_path\""]; } -// MerkleProof is a wrapper type that contains a merkle proof. +// MerkleProof is a wrapper type over a chain of CommitmentProofs. // It demonstrates membership or non-membership for an element or set of // elements, verifiable in conjunction with a known commitment root. Proofs // should be succinct. +// MerkleProofs are ordered from leaf-to-root message MerkleProof { - tendermint.crypto.ProofOps proof = 1; -} - -// KeyPath defines a slice of keys -message KeyPath { - option (gogoproto.goproto_stringer) = false; - option (gogoproto.goproto_getters) = false; - - repeated Key keys = 1; -} - -// Key defines a proof Key -message Key { - option (gogoproto.goproto_getters) = false; - - bytes name = 1; - KeyEncoding enc = 2; -} - -// KeyEncoding defines the encoding format of a key's bytes. -enum KeyEncoding { - option (gogoproto.goproto_enum_prefix) = false; - - // URL encoding - KEY_ENCODING_URL_UNSPECIFIED = 0 [(gogoproto.enumvalue_customname) = "URL"]; - // Hex encoding - KEY_ENCODING_HEX = 1 [(gogoproto.enumvalue_customname) = "HEX"]; -} + repeated ics23.CommitmentProof proofs = 1; +} \ No newline at end of file diff --git a/x/ibc/core/03-connection/types/msgs_test.go b/x/ibc/core/03-connection/types/msgs_test.go index cfb8ce735..f83963790 100644 --- a/x/ibc/core/03-connection/types/msgs_test.go +++ b/x/ibc/core/03-connection/types/msgs_test.go @@ -62,9 +62,10 @@ func (suite *MsgTestSuite) SetupTest() { Prove: true, }) - merkleProof := commitmenttypes.MerkleProof{Proof: res.ProofOps} + merkleProof, err := commitmenttypes.ConvertProofs(res.ProofOps) + suite.Require().NoError(err) proof, err := app.AppCodec().MarshalBinaryBare(&merkleProof) - suite.NoError(err) + suite.Require().NoError(err) suite.proof = proof diff --git a/x/ibc/core/04-channel/keeper/keeper_test.go b/x/ibc/core/04-channel/keeper/keeper_test.go index 9fcc9e20d..01f7a7584 100644 --- a/x/ibc/core/04-channel/keeper/keeper_test.go +++ b/x/ibc/core/04-channel/keeper/keeper_test.go @@ -30,6 +30,9 @@ func (suite *KeeperTestSuite) SetupTest() { suite.coordinator = ibctesting.NewCoordinator(suite.T(), 2) suite.chainA = suite.coordinator.GetChain(ibctesting.GetChainID(0)) suite.chainB = suite.coordinator.GetChain(ibctesting.GetChainID(1)) + // commit some blocks so that QueryProof returns valid proof (cannot return valid query if height <= 1) + suite.coordinator.CommitNBlocks(suite.chainA, 2) + suite.coordinator.CommitNBlocks(suite.chainB, 2) } // TestSetChannel create clients and connections on both chains. It tests for the non-existence diff --git a/x/ibc/core/04-channel/types/msgs_test.go b/x/ibc/core/04-channel/types/msgs_test.go index 9cf466840..f7004df68 100644 --- a/x/ibc/core/04-channel/types/msgs_test.go +++ b/x/ibc/core/04-channel/types/msgs_test.go @@ -93,9 +93,10 @@ func (suite *TypesTestSuite) SetupTest() { Prove: true, }) - merkleProof := commitmenttypes.MerkleProof{Proof: res.ProofOps} + merkleProof, err := commitmenttypes.ConvertProofs(res.ProofOps) + suite.Require().NoError(err) proof, err := app.AppCodec().MarshalBinaryBare(&merkleProof) - suite.NoError(err) + suite.Require().NoError(err) suite.proof = proof } diff --git a/x/ibc/core/23-commitment/types/commitment.pb.go b/x/ibc/core/23-commitment/types/commitment.pb.go index ac7212711..bb28053e7 100644 --- a/x/ibc/core/23-commitment/types/commitment.pb.go +++ b/x/ibc/core/23-commitment/types/commitment.pb.go @@ -5,9 +5,9 @@ package types import ( fmt "fmt" + _go "github.com/confio/ics23/go" _ "github.com/gogo/protobuf/gogoproto" proto "github.com/gogo/protobuf/proto" - crypto "github.com/tendermint/tendermint/proto/tendermint/crypto" io "io" math "math" math_bits "math/bits" @@ -24,34 +24,6 @@ var _ = math.Inf // proto package needs to be updated. const _ = proto.GoGoProtoPackageIsVersion3 // please upgrade the proto package -// KeyEncoding defines the encoding format of a key's bytes. -type KeyEncoding int32 - -const ( - // URL encoding - URL KeyEncoding = 0 - // Hex encoding - HEX KeyEncoding = 1 -) - -var KeyEncoding_name = map[int32]string{ - 0: "KEY_ENCODING_URL_UNSPECIFIED", - 1: "KEY_ENCODING_HEX", -} - -var KeyEncoding_value = map[string]int32{ - "KEY_ENCODING_URL_UNSPECIFIED": 0, - "KEY_ENCODING_HEX": 1, -} - -func (x KeyEncoding) String() string { - return proto.EnumName(KeyEncoding_name, int32(x)) -} - -func (KeyEncoding) EnumDescriptor() ([]byte, []int) { - return fileDescriptor_7921d88972a41469, []int{0} -} - // MerkleRoot defines a merkle root hash. // In the Cosmos SDK, the AppHash of a block header becomes the root. type MerkleRoot struct { @@ -141,7 +113,7 @@ func (m *MerklePrefix) GetKeyPrefix() []byte { // MerklePath is the path used to verify commitment proofs, which can be an // arbitrary structured object (defined by a commitment type). type MerklePath struct { - KeyPath KeyPath `protobuf:"bytes,1,opt,name=key_path,json=keyPath,proto3" json:"key_path" yaml:"key_path"` + KeyPath []string `protobuf:"bytes,1,rep,name=key_path,json=keyPath,proto3" json:"key_path,omitempty" yaml:"key_path"` } func (m *MerklePath) Reset() { *m = MerklePath{} } @@ -176,19 +148,19 @@ func (m *MerklePath) XXX_DiscardUnknown() { var xxx_messageInfo_MerklePath proto.InternalMessageInfo -func (m *MerklePath) GetKeyPath() KeyPath { +func (m *MerklePath) GetKeyPath() []string { if m != nil { return m.KeyPath } - return KeyPath{} + return nil } -// MerkleProof is a wrapper type that contains a merkle proof. +// MerkleProof is a wrapper type over a chain of CommitmentProofs. // It demonstrates membership or non-membership for an element or set of // elements, verifiable in conjunction with a known commitment root. Proofs // should be succinct. type MerkleProof struct { - Proof *crypto.ProofOps `protobuf:"bytes,1,opt,name=proof,proto3" json:"proof,omitempty"` + Proofs []*_go.CommitmentProof `protobuf:"bytes,1,rep,name=proofs,proto3" json:"proofs,omitempty"` } func (m *MerkleProof) Reset() { *m = MerkleProof{} } @@ -224,97 +196,18 @@ func (m *MerkleProof) XXX_DiscardUnknown() { var xxx_messageInfo_MerkleProof proto.InternalMessageInfo -func (m *MerkleProof) GetProof() *crypto.ProofOps { +func (m *MerkleProof) GetProofs() []*_go.CommitmentProof { if m != nil { - return m.Proof + return m.Proofs } return nil } -// KeyPath defines a slice of keys -type KeyPath struct { - Keys []*Key `protobuf:"bytes,1,rep,name=keys,proto3" json:"keys,omitempty"` -} - -func (m *KeyPath) Reset() { *m = KeyPath{} } -func (*KeyPath) ProtoMessage() {} -func (*KeyPath) Descriptor() ([]byte, []int) { - return fileDescriptor_7921d88972a41469, []int{4} -} -func (m *KeyPath) XXX_Unmarshal(b []byte) error { - return m.Unmarshal(b) -} -func (m *KeyPath) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - if deterministic { - return xxx_messageInfo_KeyPath.Marshal(b, m, deterministic) - } else { - b = b[:cap(b)] - n, err := m.MarshalToSizedBuffer(b) - if err != nil { - return nil, err - } - return b[:n], nil - } -} -func (m *KeyPath) XXX_Merge(src proto.Message) { - xxx_messageInfo_KeyPath.Merge(m, src) -} -func (m *KeyPath) XXX_Size() int { - return m.Size() -} -func (m *KeyPath) XXX_DiscardUnknown() { - xxx_messageInfo_KeyPath.DiscardUnknown(m) -} - -var xxx_messageInfo_KeyPath proto.InternalMessageInfo - -// Key defines a proof Key -type Key struct { - Name []byte `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"` - Enc KeyEncoding `protobuf:"varint,2,opt,name=enc,proto3,enum=ibc.core.commitment.v1.KeyEncoding" json:"enc,omitempty"` -} - -func (m *Key) Reset() { *m = Key{} } -func (m *Key) String() string { return proto.CompactTextString(m) } -func (*Key) ProtoMessage() {} -func (*Key) Descriptor() ([]byte, []int) { - return fileDescriptor_7921d88972a41469, []int{5} -} -func (m *Key) XXX_Unmarshal(b []byte) error { - return m.Unmarshal(b) -} -func (m *Key) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - if deterministic { - return xxx_messageInfo_Key.Marshal(b, m, deterministic) - } else { - b = b[:cap(b)] - n, err := m.MarshalToSizedBuffer(b) - if err != nil { - return nil, err - } - return b[:n], nil - } -} -func (m *Key) XXX_Merge(src proto.Message) { - xxx_messageInfo_Key.Merge(m, src) -} -func (m *Key) XXX_Size() int { - return m.Size() -} -func (m *Key) XXX_DiscardUnknown() { - xxx_messageInfo_Key.DiscardUnknown(m) -} - -var xxx_messageInfo_Key proto.InternalMessageInfo - func init() { - proto.RegisterEnum("ibc.core.commitment.v1.KeyEncoding", KeyEncoding_name, KeyEncoding_value) proto.RegisterType((*MerkleRoot)(nil), "ibc.core.commitment.v1.MerkleRoot") proto.RegisterType((*MerklePrefix)(nil), "ibc.core.commitment.v1.MerklePrefix") proto.RegisterType((*MerklePath)(nil), "ibc.core.commitment.v1.MerklePath") proto.RegisterType((*MerkleProof)(nil), "ibc.core.commitment.v1.MerkleProof") - proto.RegisterType((*KeyPath)(nil), "ibc.core.commitment.v1.KeyPath") - proto.RegisterType((*Key)(nil), "ibc.core.commitment.v1.Key") } func init() { @@ -322,39 +215,28 @@ func init() { } var fileDescriptor_7921d88972a41469 = []byte{ - // 499 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x7c, 0x92, 0x4f, 0x6f, 0xd3, 0x30, - 0x18, 0xc6, 0x13, 0x5a, 0xe8, 0x70, 0x27, 0x28, 0x16, 0x7f, 0xaa, 0xc2, 0x92, 0x2a, 0x48, 0x30, - 0x90, 0x16, 0xab, 0x1d, 0x5c, 0xca, 0x05, 0x75, 0x0d, 0xac, 0xea, 0xe8, 0x2a, 0x4f, 0x45, 0x03, - 0x09, 0x55, 0x69, 0xea, 0x26, 0x51, 0x96, 0x38, 0x4a, 0xcc, 0xb4, 0x7c, 0x83, 0x89, 0x13, 0x47, - 0x2e, 0x48, 0x48, 0x7c, 0x99, 0x1d, 0x77, 0xe4, 0x54, 0xa1, 0xf6, 0x1b, 0xec, 0x13, 0x20, 0xdb, - 0x2d, 0x0b, 0x12, 0x70, 0xca, 0x6b, 0xbd, 0xbf, 0x37, 0xcf, 0xe3, 0xc7, 0x2f, 0x78, 0xec, 0x8f, - 0x1d, 0xe4, 0xd0, 0x84, 0x20, 0x87, 0x86, 0xa1, 0xcf, 0x42, 0x12, 0x31, 0x74, 0xdc, 0xc8, 0x9d, - 0xcc, 0x38, 0xa1, 0x8c, 0xc2, 0xbb, 0xfe, 0xd8, 0x31, 0x39, 0x68, 0xe6, 0x5a, 0xc7, 0x8d, 0xda, - 0x6d, 0x97, 0xba, 0x54, 0x20, 0x88, 0x57, 0x92, 0xae, 0x6d, 0x30, 0x12, 0x4d, 0x48, 0x12, 0xfa, - 0x11, 0x43, 0x4e, 0x92, 0xc5, 0x8c, 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, 0x79, 0x0d, - 0x9f, 0x83, 0x02, 0x89, 0x9c, 0xea, 0x95, 0xba, 0xba, 0x79, 0xa3, 0xf9, 0xf0, 0x3f, 0x3f, 0xb5, - 0x22, 0x87, 0x4e, 0xfc, 0xc8, 0xc5, 0x9c, 0x97, 0xcf, 0xf1, 0xf4, 0x03, 0x28, 0xe7, 0x3a, 0xf0, - 0x09, 0x78, 0xd0, 0xb3, 0xde, 0x8d, 0xac, 0xfe, 0xce, 0x7e, 0xa7, 0xdb, 0x7f, 0x3d, 0x1a, 0xe2, - 0xbd, 0xd1, 0xb0, 0x7f, 0x30, 0xb0, 0x76, 0xba, 0xaf, 0xba, 0x56, 0xa7, 0xa2, 0xd4, 0x4a, 0x9f, - 0xbe, 0xd6, 0x0b, 0x43, 0xbc, 0x07, 0x37, 0x40, 0xe5, 0x0f, 0x74, 0xd7, 0x3a, 0xac, 0xa8, 0xb2, - 0xbd, 0x6b, 0x1d, 0xd6, 0x8a, 0xa7, 0xdf, 0x35, 0xa5, 0x3d, 0x3c, 0x9b, 0x6b, 0xea, 0xf9, 0x5c, - 0x53, 0x7f, 0xce, 0x35, 0xf5, 0xf3, 0x42, 0x53, 0xce, 0x17, 0x9a, 0xf2, 0x63, 0xa1, 0x29, 0xef, - 0x5f, 0xb8, 0x3e, 0xf3, 0x3e, 0x8e, 0xb9, 0x4b, 0xe4, 0xd0, 0x34, 0xa4, 0xe9, 0xf2, 0xb3, 0x95, - 0x4e, 0x02, 0x74, 0x82, 0x7e, 0x2f, 0x71, 0x73, 0x7b, 0x2b, 0xb7, 0xc7, 0x2c, 0x8b, 0x49, 0x3a, - 0xbe, 0x26, 0x76, 0x6e, 0xfb, 0x57, 0x00, 0x00, 0x00, 0xff, 0xff, 0x8a, 0x78, 0x4b, 0x97, 0xeb, - 0x02, 0x00, 0x00, + // 334 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x4c, 0x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 0x62, 0x96, 0xeb, 0x2c, 0xc7, 0xdd, 0x77, 0x1b, 0xfb, 0x32, 0xb2, 0x30, 0x3a, + 0x52, 0x9c, 0x2f, 0x8b, 0x8e, 0xff, 0xba, 0x35, 0xb7, 0xb9, 0x5d, 0x75, 0x8e, 0x4b, 0x15, 0x7c, + 0x19, 0x39, 0xde, 0xff, 0x22, 0xdf, 0x97, 0xd1, 0xa8, 0xf2, 0x51, 0x4c, 0x72, 0x8b, 0xea, 0xfb, + 0x49, 0x00, 0x42, 0x0b, 0xa3, 0xaa, 0x5e, 0x48, 0x95, 0xa8, 0x0f, 0x5a, 0x98, 0x53, 0x31, 0x18, + 0xe2, 0xbb, 0x83, 0x22, 0x8a, 0xf3, 0x76, 0x94, 0xfb, 0xf8, 0xb5, 0xb6, 0xcd, 0xe5, 0xda, 0x36, + 0x7f, 0xd6, 0xb6, 0xf9, 0xbe, 0xb1, 0x8d, 0xe5, 0xc6, 0x36, 0xbe, 0x37, 0xb6, 0xf1, 0x74, 0x33, + 0xe1, 0x32, 0x7a, 0x0d, 0x0a, 0x2d, 0x09, 0x05, 0x91, 0x80, 0xd8, 0x3d, 0x3d, 0xf1, 0x12, 0x93, + 0x05, 0x39, 0x5c, 0x65, 0x30, 0xec, 0x95, 0x0e, 0x23, 0xf3, 0x94, 0x89, 0xa0, 0xaa, 0xe4, 0x1c, + 0xfe, 0x06, 0x00, 0x00, 0xff, 0xff, 0x1b, 0xe7, 0x68, 0xd0, 0xbc, 0x01, 0x00, 0x00, } func (m *MerkleRoot) Marshal() (dAtA []byte, err error) { @@ -437,16 +319,15 @@ func (m *MerklePath) MarshalToSizedBuffer(dAtA []byte) (int, error) { _ = i var l int _ = l - { - size, err := m.KeyPath.MarshalToSizedBuffer(dAtA[:i]) - if err != nil { - return 0, err + if len(m.KeyPath) > 0 { + for iNdEx := len(m.KeyPath) - 1; iNdEx >= 0; iNdEx-- { + i -= len(m.KeyPath[iNdEx]) + copy(dAtA[i:], m.KeyPath[iNdEx]) + i = encodeVarintCommitment(dAtA, i, uint64(len(m.KeyPath[iNdEx]))) + i-- + dAtA[i] = 0xa } - i -= size - i = encodeVarintCommitment(dAtA, i, uint64(size)) } - i-- - dAtA[i] = 0xa return len(dAtA) - i, nil } @@ -470,45 +351,10 @@ func (m *MerkleProof) MarshalToSizedBuffer(dAtA []byte) (int, error) { _ = i var l int _ = l - if m.Proof != nil { - { - size, err := m.Proof.MarshalToSizedBuffer(dAtA[:i]) - if err != nil { - return 0, err - } - i -= size - i = encodeVarintCommitment(dAtA, i, uint64(size)) - } - i-- - dAtA[i] = 0xa - } - return len(dAtA) - i, nil -} - -func (m *KeyPath) Marshal() (dAtA []byte, err error) { - size := m.Size() - dAtA = make([]byte, size) - n, err := m.MarshalToSizedBuffer(dAtA[:size]) - if err != nil { - return nil, err - } - return dAtA[:n], nil -} - -func (m *KeyPath) MarshalTo(dAtA []byte) (int, error) { - size := m.Size() - return m.MarshalToSizedBuffer(dAtA[:size]) -} - -func (m *KeyPath) MarshalToSizedBuffer(dAtA []byte) (int, error) { - i := len(dAtA) - _ = i - var l int - _ = l - if len(m.Keys) > 0 { - for iNdEx := len(m.Keys) - 1; iNdEx >= 0; iNdEx-- { + if len(m.Proofs) > 0 { + for iNdEx := len(m.Proofs) - 1; iNdEx >= 0; iNdEx-- { { - size, err := m.Keys[iNdEx].MarshalToSizedBuffer(dAtA[:i]) + size, err := m.Proofs[iNdEx].MarshalToSizedBuffer(dAtA[:i]) if err != nil { return 0, err } @@ -522,41 +368,6 @@ func (m *KeyPath) MarshalToSizedBuffer(dAtA []byte) (int, error) { return len(dAtA) - i, nil } -func (m *Key) Marshal() (dAtA []byte, err error) { - size := m.Size() - dAtA = make([]byte, size) - n, err := m.MarshalToSizedBuffer(dAtA[:size]) - if err != nil { - return nil, err - } - return dAtA[:n], nil -} - -func (m *Key) MarshalTo(dAtA []byte) (int, error) { - size := m.Size() - return m.MarshalToSizedBuffer(dAtA[:size]) -} - -func (m *Key) MarshalToSizedBuffer(dAtA []byte) (int, error) { - i := len(dAtA) - _ = i - var l int - _ = l - if m.Enc != 0 { - i = encodeVarintCommitment(dAtA, i, uint64(m.Enc)) - i-- - dAtA[i] = 0x10 - } - if len(m.Name) > 0 { - i -= len(m.Name) - copy(dAtA[i:], m.Name) - i = encodeVarintCommitment(dAtA, i, uint64(len(m.Name))) - i-- - dAtA[i] = 0xa - } - return len(dAtA) - i, nil -} - func encodeVarintCommitment(dAtA []byte, offset int, v uint64) int { offset -= sovCommitment(v) base := offset @@ -600,8 +411,12 @@ func (m *MerklePath) Size() (n int) { } var l int _ = l - l = m.KeyPath.Size() - n += 1 + l + sovCommitment(uint64(l)) + if len(m.KeyPath) > 0 { + for _, s := range m.KeyPath { + l = len(s) + n += 1 + l + sovCommitment(uint64(l)) + } + } return n } @@ -611,21 +426,8 @@ func (m *MerkleProof) Size() (n int) { } var l int _ = l - if m.Proof != nil { - l = m.Proof.Size() - n += 1 + l + sovCommitment(uint64(l)) - } - return n -} - -func (m *KeyPath) Size() (n int) { - if m == nil { - return 0 - } - var l int - _ = l - if len(m.Keys) > 0 { - for _, e := range m.Keys { + if len(m.Proofs) > 0 { + for _, e := range m.Proofs { l = e.Size() n += 1 + l + sovCommitment(uint64(l)) } @@ -633,22 +435,6 @@ func (m *KeyPath) Size() (n int) { return n } -func (m *Key) Size() (n int) { - if m == nil { - return 0 - } - var l int - _ = l - l = len(m.Name) - if l > 0 { - n += 1 + l + sovCommitment(uint64(l)) - } - if m.Enc != 0 { - n += 1 + sovCommitment(uint64(m.Enc)) - } - return n -} - func sovCommitment(x uint64) (n int) { return (math_bits.Len64(x|1) + 6) / 7 } @@ -862,7 +648,7 @@ func (m *MerklePath) Unmarshal(dAtA []byte) error { if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field KeyPath", wireType) } - var msglen int + var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowCommitment @@ -872,24 +658,23 @@ func (m *MerklePath) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - msglen |= int(b&0x7F) << shift + stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } - if msglen < 0 { + intStringLen := int(stringLen) + if intStringLen < 0 { return ErrInvalidLengthCommitment } - postIndex := iNdEx + msglen + postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthCommitment } if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.KeyPath.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { - return err - } + m.KeyPath = append(m.KeyPath, string(dAtA[iNdEx:postIndex])) iNdEx = postIndex default: iNdEx = preIndex @@ -946,7 +731,7 @@ func (m *MerkleProof) Unmarshal(dAtA []byte) error { switch fieldNum { case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Proof", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Proofs", wireType) } var msglen int for shift := uint(0); ; shift += 7 { @@ -973,10 +758,8 @@ func (m *MerkleProof) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if m.Proof == nil { - m.Proof = &crypto.ProofOps{} - } - if err := m.Proof.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + m.Proofs = append(m.Proofs, &_go.CommitmentProof{}) + if err := m.Proofs[len(m.Proofs)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -1004,199 +787,6 @@ func (m *MerkleProof) Unmarshal(dAtA []byte) error { } return nil } -func (m *KeyPath) Unmarshal(dAtA []byte) error { - l := len(dAtA) - iNdEx := 0 - for iNdEx < l { - preIndex := iNdEx - var wire uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowCommitment - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - wire |= uint64(b&0x7F) << shift - if b < 0x80 { - break - } - } - fieldNum := int32(wire >> 3) - wireType := int(wire & 0x7) - if wireType == 4 { - return fmt.Errorf("proto: KeyPath: wiretype end group for non-group") - } - if fieldNum <= 0 { - return fmt.Errorf("proto: KeyPath: illegal tag %d (wire type %d)", fieldNum, wire) - } - switch fieldNum { - case 1: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Keys", wireType) - } - var msglen int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowCommitment - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - msglen |= int(b&0x7F) << shift - if b < 0x80 { - break - } - } - if msglen < 0 { - return ErrInvalidLengthCommitment - } - postIndex := iNdEx + msglen - if postIndex < 0 { - return ErrInvalidLengthCommitment - } - if postIndex > l { - return io.ErrUnexpectedEOF - } - m.Keys = append(m.Keys, &Key{}) - if err := m.Keys[len(m.Keys)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { - return err - } - iNdEx = postIndex - default: - iNdEx = preIndex - skippy, err := skipCommitment(dAtA[iNdEx:]) - if err != nil { - return err - } - if skippy < 0 { - return ErrInvalidLengthCommitment - } - if (iNdEx + skippy) < 0 { - return ErrInvalidLengthCommitment - } - if (iNdEx + skippy) > l { - return io.ErrUnexpectedEOF - } - iNdEx += skippy - } - } - - if iNdEx > l { - return io.ErrUnexpectedEOF - } - return nil -} -func (m *Key) Unmarshal(dAtA []byte) error { - l := len(dAtA) - iNdEx := 0 - for iNdEx < l { - preIndex := iNdEx - var wire uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowCommitment - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - wire |= uint64(b&0x7F) << shift - if b < 0x80 { - break - } - } - fieldNum := int32(wire >> 3) - wireType := int(wire & 0x7) - if wireType == 4 { - return fmt.Errorf("proto: Key: wiretype end group for non-group") - } - if fieldNum <= 0 { - return fmt.Errorf("proto: Key: illegal tag %d (wire type %d)", fieldNum, wire) - } - switch fieldNum { - case 1: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Name", wireType) - } - var byteLen int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowCommitment - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - byteLen |= int(b&0x7F) << shift - if b < 0x80 { - break - } - } - if byteLen < 0 { - return ErrInvalidLengthCommitment - } - postIndex := iNdEx + byteLen - if postIndex < 0 { - return ErrInvalidLengthCommitment - } - if postIndex > l { - return io.ErrUnexpectedEOF - } - m.Name = append(m.Name[:0], dAtA[iNdEx:postIndex]...) - if m.Name == nil { - m.Name = []byte{} - } - iNdEx = postIndex - case 2: - if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field Enc", wireType) - } - m.Enc = 0 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowCommitment - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - m.Enc |= KeyEncoding(b&0x7F) << shift - if b < 0x80 { - break - } - } - default: - iNdEx = preIndex - skippy, err := skipCommitment(dAtA[iNdEx:]) - if err != nil { - return err - } - if skippy < 0 { - return ErrInvalidLengthCommitment - } - if (iNdEx + skippy) < 0 { - return ErrInvalidLengthCommitment - } - if (iNdEx + skippy) > l { - return io.ErrUnexpectedEOF - } - iNdEx += skippy - } - } - - if iNdEx > l { - return io.ErrUnexpectedEOF - } - return nil -} func skipCommitment(dAtA []byte) (n int, err error) { l := len(dAtA) iNdEx := 0 diff --git a/x/ibc/core/23-commitment/types/key_path.go b/x/ibc/core/23-commitment/types/key_path.go deleted file mode 100644 index 589406b90..000000000 --- a/x/ibc/core/23-commitment/types/key_path.go +++ /dev/null @@ -1,40 +0,0 @@ -package types - -import ( - fmt "fmt" - "net/url" -) - -// AppendKey appends a new key to a KeyPath -func (pth KeyPath) AppendKey(key []byte, enc KeyEncoding) KeyPath { - pth.Keys = append(pth.Keys, &Key{Name: key, Enc: enc}) - return pth -} - -// String implements the fmt.Stringer interface -func (pth *KeyPath) String() string { - res := "" - for _, key := range pth.Keys { - switch key.Enc { - case URL: - res += "/" + url.PathEscape(string(key.Name)) - case HEX: - res += "/x:" + fmt.Sprintf("%X", key.Name) - default: - panic("unexpected key encoding type") - } - } - return res -} - -// GetKey returns the bytes representation of key at given index -// Passing in a positive index return the key at index in forward order -// from the highest key to the lowest key -// Passing in a negative index will return the key at index in reverse order -// from the lowest key to the highest key. This is the order for proof verification, -// since we prove lowest key first before moving to key of higher subtrees -func (pth *KeyPath) GetKey(i int) []byte { - total := len(pth.Keys) - index := (total + i) % total - return pth.Keys[index].Name -} diff --git a/x/ibc/core/23-commitment/types/merkle.go b/x/ibc/core/23-commitment/types/merkle.go index 87a830e29..fe7d5c302 100644 --- a/x/ibc/core/23-commitment/types/merkle.go +++ b/x/ibc/core/23-commitment/types/merkle.go @@ -2,6 +2,7 @@ package types import ( "bytes" + "fmt" "net/url" ics23 "github.com/confio/ics23/go" @@ -9,7 +10,6 @@ import ( tmcrypto "github.com/tendermint/tendermint/proto/tendermint/crypto" sdkerrors "github.com/cosmos/cosmos-sdk/types/errors" - host "github.com/cosmos/cosmos-sdk/x/ibc/core/24-host" "github.com/cosmos/cosmos-sdk/x/ibc/core/exported" ) @@ -68,51 +68,62 @@ func (mp MerklePrefix) Empty() bool { var _ exported.Path = (*MerklePath)(nil) // NewMerklePath creates a new MerklePath instance -func NewMerklePath(keyPathStr []string) MerklePath { - merkleKeyPath := KeyPath{} - for _, keyStr := range keyPathStr { - merkleKeyPath = merkleKeyPath.AppendKey([]byte(keyStr), URL) - } - +// The keys must be passed in from root-to-leaf order +func NewMerklePath(keyPath ...string) MerklePath { return MerklePath{ - KeyPath: merkleKeyPath, + KeyPath: keyPath, } } // String implements fmt.Stringer. +// This represents the path in the same way the tendermint KeyPath will +// represent a key path. The backslashes partition the key path into +// the respective stores they belong to. func (mp MerklePath) String() string { - return mp.KeyPath.String() + pathStr := "" + for _, k := range mp.KeyPath { + pathStr += "/" + url.PathEscape(k) + } + return pathStr } // Pretty returns the unescaped path of the URL string. +// This function will unescape any backslash within a particular store key. +// This makes the keypath more human-readable while removing information +// about the exact partitions in the key path. func (mp MerklePath) Pretty() string { - path, err := url.PathUnescape(mp.KeyPath.String()) + path, err := url.PathUnescape(mp.String()) if err != nil { panic(err) } return path } -// Empty returns true if the path is empty -func (mp MerklePath) Empty() bool { - return len(mp.KeyPath.Keys) == 0 +// GetKey will return a byte representation of the key +// after URL escaping the key element +func (mp MerklePath) GetKey(i uint64) ([]byte, error) { + if i >= uint64(len(mp.KeyPath)) { + return nil, fmt.Errorf("index out of range. %d (index) >= %d (len)", i, len(mp.KeyPath)) + } + key, err := url.PathUnescape(mp.KeyPath[i]) + if err != nil { + return nil, err + } + return []byte(key), nil } -// ApplyPrefix constructs a new commitment path from the arguments. It interprets -// the path argument in the context of the prefix argument. -// -// CONTRACT: provided path string MUST be a well formated path. See ICS24 for -// reference. -func ApplyPrefix(prefix exported.Prefix, path string) (MerklePath, error) { - err := host.PathValidator(path) - if err != nil { - return MerklePath{}, err - } +// Empty returns true if the path is empty +func (mp MerklePath) Empty() bool { + return len(mp.KeyPath) == 0 +} +// ApplyPrefix constructs a new commitment path from the arguments. It prepends the prefix key +// with the given path. +func ApplyPrefix(prefix exported.Prefix, path MerklePath) (MerklePath, error) { if prefix == nil || prefix.Empty() { return MerklePath{}, sdkerrors.Wrap(ErrInvalidPrefix, "prefix can't be empty") } - return NewMerklePath([]string{string(prefix.Bytes()), path}), nil + return NewMerklePath(append([]string{string(prefix.Bytes())}, path.KeyPath...)...), nil } var _ exported.Proof = (*MerkleProof)(nil) @@ -128,22 +139,17 @@ func (proof MerkleProof) VerifyMembership(specs []*ics23.ProofSpec, root exporte if !ok { return sdkerrors.Wrapf(ErrInvalidProof, "path %v is not of type MerklePath", path) } - if len(mpath.KeyPath.Keys) != len(specs) { + if len(mpath.KeyPath) != len(specs) { return sdkerrors.Wrapf(ErrInvalidProof, "path length %d not same as proof %d", - len(mpath.KeyPath.Keys), len(specs)) + len(mpath.KeyPath), len(specs)) } if len(value) == 0 { return sdkerrors.Wrap(ErrInvalidProof, "empty value in membership proof") } - // Convert Proof to []CommitmentProof - proofs, err := convertProofs(proof) - if err != nil { - return err - } - - // Since every proof in chain is a membership proof we can chain from index 0 - if err := verifyChainedMembershipProof(root.GetHash(), specs, proofs, mpath.KeyPath, value, 0); err != nil { + // Since every proof in chain is a membership proof we can use verifyChainedMembershipProof from index 0 + // to validate entire proof + if err := verifyChainedMembershipProof(root.GetHash(), specs, proof.Proofs, mpath, value, 0); err != nil { return err } return nil @@ -162,31 +168,37 @@ func (proof MerkleProof) VerifyNonMembership(specs []*ics23.ProofSpec, root expo if !ok { return sdkerrors.Wrapf(ErrInvalidProof, "path %v is not of type MerkleProof", path) } - if len(mpath.KeyPath.Keys) != len(specs) { + if len(mpath.KeyPath) != len(specs) { return sdkerrors.Wrapf(ErrInvalidProof, "path length %d not same as proof %d", - len(mpath.KeyPath.Keys), len(specs)) + len(mpath.KeyPath), len(specs)) } - // Convert Proof to []CommitmentProof - proofs, err := convertProofs(proof) - if err != nil { - return err - } + switch proof.Proofs[0].Proof.(type) { + case *ics23.CommitmentProof_Nonexist: + // VerifyNonMembership will verify the absence of key in lowest subtree, and then chain inclusion proofs + // of all subroots up to final root + subroot, err := proof.Proofs[0].Calculate() + if err != nil { + return sdkerrors.Wrapf(ErrInvalidProof, "could not calculate root for proof index 0, merkle tree is likely empty. %v", err) + } + key, err := mpath.GetKey(uint64(len(mpath.KeyPath) - 1)) + if err != nil { + return sdkerrors.Wrapf(ErrInvalidProof, "could not retrieve key bytes for key: %s", mpath.KeyPath[len(mpath.KeyPath)-1]) + } + if ok := ics23.VerifyNonMembership(specs[0], subroot, proof.Proofs[0], key); !ok { + return sdkerrors.Wrapf(ErrInvalidProof, "could not verify absence of key %s. Please ensure that the path is correct.", string(key)) + } - // VerifyNonMembership will verify the absence of key in lowest subtree, and then chain inclusion proofs - // of all subroots up to final root - subroot, err := proofs[0].Calculate() - if err != nil { - sdkerrors.Wrapf(ErrInvalidProof, "could not calculate root for proof index 0. %v", err) - } - key := mpath.KeyPath.GetKey(-1) - if ok := ics23.VerifyNonMembership(specs[0], subroot, proofs[0], key); !ok { - return sdkerrors.Wrapf(ErrInvalidProof, "could not verify absence of key %s", string(key)) - } - - // Verify chained membership proof starting from index 1 with value = subroot - if err := verifyChainedMembershipProof(root.GetHash(), specs, proofs, mpath.KeyPath, subroot, 1); err != nil { - return err + // Verify chained membership proof starting from index 1 with value = subroot + if err := verifyChainedMembershipProof(root.GetHash(), specs, proof.Proofs, mpath, subroot, 1); err != nil { + return err + } + case *ics23.CommitmentProof_Exist: + return sdkerrors.Wrapf(ErrInvalidProof, + "got ExistenceProof in VerifyNonMembership. If this is unexpected, please ensure that proof was queried with the correct key.") + default: + return sdkerrors.Wrapf(ErrInvalidProof, + "expected proof type: %T, got: %T", &ics23.CommitmentProof_Exist{}, proof.Proofs[0].Proof) } return nil } @@ -208,7 +220,7 @@ func (proof MerkleProof) BatchVerifyNonMembership(specs []*ics23.ProofSpec, root // The proofs and specs are passed in from lowest subtree to the highest subtree, but the keys are passed in from highest subtree to lowest. // The index specifies what index to start chaining the membership proofs, this is useful since the lowest proof may not be a membership proof, thus we // will want to start the membership proof chaining from index 1 with value being the lowest subroot -func verifyChainedMembershipProof(root []byte, specs []*ics23.ProofSpec, proofs []*ics23.CommitmentProof, keys KeyPath, value []byte, index int) error { +func verifyChainedMembershipProof(root []byte, specs []*ics23.ProofSpec, proofs []*ics23.CommitmentProof, keys MerklePath, value []byte, index int) error { var ( subroot []byte err error @@ -218,42 +230,45 @@ func verifyChainedMembershipProof(root []byte, specs []*ics23.ProofSpec, proofs // In this case, there may be no intermediate proofs to verify and we just check that lowest proof root equals final root subroot = value for i := index; i < len(proofs); i++ { - subroot, err = proofs[i].Calculate() - if err != nil { - return sdkerrors.Wrapf(ErrInvalidProof, "could not calculate proof root at index %d. %v", i, err) + switch proofs[i].Proof.(type) { + case *ics23.CommitmentProof_Exist: + subroot, err = proofs[i].Calculate() + if err != nil { + return sdkerrors.Wrapf(ErrInvalidProof, "could not calculate proof root at index %d, merkle tree may be empty. %v", i, err) + } + // Since keys are passed in from highest to lowest, we must grab their indices in reverse order + // from the proofs and specs which are lowest to highest + key, err := keys.GetKey(uint64(len(keys.KeyPath) - 1 - i)) + if err != nil { + return sdkerrors.Wrapf(ErrInvalidProof, "could not retrieve key bytes for key %s: %v", keys.KeyPath[len(keys.KeyPath)-1-i], err) + } + + // verify membership of the proof at this index with appropriate key and value + if ok := ics23.VerifyMembership(specs[i], subroot, proofs[i], key, value); !ok { + return sdkerrors.Wrapf(ErrInvalidProof, + "chained membership proof failed to verify membership of value: %X in subroot %X at index %d. Please ensure the path and value are both correct.", + value, subroot, i) + } + // Set value to subroot so that we verify next proof in chain commits to this subroot + value = subroot + case *ics23.CommitmentProof_Nonexist: + return sdkerrors.Wrapf(ErrInvalidProof, + "chained membership proof contains nonexistence proof at index %d. If this is unexpected, please ensure that proof was queried from the height that contained the value in store and was queried with the correct key.", + i) + default: + return sdkerrors.Wrapf(ErrInvalidProof, + "expected proof type: %T, got: %T", &ics23.CommitmentProof_Exist{}, proofs[i].Proof) } - // Since keys are passed in from highest to lowest, we must grab their indices in reverse order - // from the proofs and specs which are lowest to highest - key := keys.GetKey(-1 * (i + 1)) - if ok := ics23.VerifyMembership(specs[i], subroot, proofs[i], key, value); !ok { - return sdkerrors.Wrapf(ErrInvalidProof, "chained membership proof failed to verify membership of value: %X in subroot %X at index %d for proof %v", - value, subroot, i, proofs[i]) - } - // Set value to subroot so that we verify next proof in chain commits to this subroot - value = subroot } // Check that chained proof root equals passed-in root if !bytes.Equal(root, subroot) { - return sdkerrors.Wrapf(ErrInvalidProof, "proof did not commit to expected root: %X, got: %X", root, subroot) + return sdkerrors.Wrapf(ErrInvalidProof, + "proof did not commit to expected root: %X, got: %X. Please ensure proof was submitted with correct proofHeight and to the correct chain.", + root, subroot) } return nil } -// convertProofs converts a MerkleProof into []*ics23.CommitmentProof -func convertProofs(mproof MerkleProof) ([]*ics23.CommitmentProof, error) { - // Unmarshal all proof ops to CommitmentProof - proofs := make([]*ics23.CommitmentProof, len(mproof.Proof.Ops)) - for i, op := range mproof.Proof.Ops { - var p ics23.CommitmentProof - err := p.Unmarshal(op.Data) - if err != nil { - return nil, sdkerrors.Wrapf(ErrInvalidMerkleProof, "could not unmarshal proof op into CommitmentProof at index: %d", i) - } - proofs[i] = &p - } - return proofs, nil -} - // Empty returns true if the root is empty func (proof MerkleProof) Empty() bool { return proto.Equal(&proof, nil) || proto.Equal(&proof, &MerkleProof{}) || proto.Equal(&proof, &tmcrypto.ProofOps{}) @@ -277,10 +292,10 @@ func (proof MerkleProof) validateVerificationArgs(specs []*ics23.ProofSpec, root return sdkerrors.Wrap(ErrInvalidMerkleProof, "root cannot be empty") } - if len(specs) != len(proof.Proof.Ops) { + if len(specs) != len(proof.Proofs) { return sdkerrors.Wrapf(ErrInvalidMerkleProof, "length of specs: %d not equal to length of proof: %d", - len(specs), len(proof.Proof.Ops)) + len(specs), len(proof.Proofs)) } for i, spec := range specs { diff --git a/x/ibc/core/23-commitment/types/merkle_test.go b/x/ibc/core/23-commitment/types/merkle_test.go index 4da9099e8..3c53847fa 100644 --- a/x/ibc/core/23-commitment/types/merkle_test.go +++ b/x/ibc/core/23-commitment/types/merkle_test.go @@ -6,8 +6,6 @@ import ( "github.com/stretchr/testify/require" abci "github.com/tendermint/tendermint/abci/types" - tmcrypto "github.com/tendermint/tendermint/proto/tendermint/crypto" - tmmerkle "github.com/tendermint/tendermint/proto/tendermint/crypto" "github.com/cosmos/cosmos-sdk/x/ibc/core/23-commitment/types" ) @@ -23,9 +21,9 @@ func (suite *MerkleTestSuite) TestVerifyMembership() { }) require.NotNil(suite.T(), res.ProofOps) - proof := types.MerkleProof{ - Proof: res.ProofOps, - } + proof, err := types.ConvertProofs(res.ProofOps) + require.NoError(suite.T(), err) + suite.Require().NoError(proof.ValidateBasic()) suite.Require().Error(types.MerkleProof{}.ValidateBasic()) @@ -49,9 +47,7 @@ func (suite *MerkleTestSuite) TestVerifyMembership() { {"nil root", []byte(nil), []string{suite.storeKey.Name(), "MYKEY"}, []byte("MYVALUE"), func() {}, false}, // invalid proof with nil root {"proof is wrong length", cid.Hash, []string{suite.storeKey.Name(), "MYKEY"}, []byte("MYVALUE"), func() { proof = types.MerkleProof{ - Proof: &tmmerkle.ProofOps{ - Ops: res.ProofOps.Ops[1:], - }, + Proofs: proof.Proofs[1:], } }, false}, // invalid proof with wrong length @@ -63,7 +59,7 @@ func (suite *MerkleTestSuite) TestVerifyMembership() { tc.malleate() root := types.NewMerkleRoot(tc.root) - path := types.NewMerklePath(tc.pathArr) + path := types.NewMerklePath(tc.pathArr...) err := proof.VerifyMembership(types.GetSDKSpecs(), &root, path, tc.value) @@ -91,9 +87,9 @@ func (suite *MerkleTestSuite) TestVerifyNonMembership() { }) require.NotNil(suite.T(), res.ProofOps) - proof := types.MerkleProof{ - Proof: res.ProofOps, - } + proof, err := types.ConvertProofs(res.ProofOps) + require.NoError(suite.T(), err) + suite.Require().NoError(proof.ValidateBasic()) cases := []struct { @@ -114,9 +110,7 @@ func (suite *MerkleTestSuite) TestVerifyNonMembership() { {"nil root", []byte(nil), []string{suite.storeKey.Name(), "MYABSENTKEY"}, func() {}, false}, // invalid proof with nil root {"proof is wrong length", cid.Hash, []string{suite.storeKey.Name(), "MYKEY"}, func() { proof = types.MerkleProof{ - Proof: &tmcrypto.ProofOps{ - Ops: res.ProofOps.Ops[1:], - }, + Proofs: proof.Proofs[1:], } }, false}, // invalid proof with wrong length @@ -129,7 +123,7 @@ func (suite *MerkleTestSuite) TestVerifyNonMembership() { tc.malleate() root := types.NewMerkleRoot(tc.root) - path := types.NewMerklePath(tc.pathArr) + path := types.NewMerklePath(tc.pathArr...) err := proof.VerifyNonMembership(types.GetSDKSpecs(), &root, path) @@ -149,16 +143,30 @@ func TestApplyPrefix(t *testing.T) { prefix := types.NewMerklePrefix([]byte("storePrefixKey")) pathStr := "pathone/pathtwo/paththree/key" + path := types.MerklePath{ + KeyPath: []string{pathStr}, + } - prefixedPath, err := types.ApplyPrefix(prefix, pathStr) - require.Nil(t, err, "valid prefix returns error") + prefixedPath, err := types.ApplyPrefix(prefix, path) + require.NoError(t, err, "valid prefix returns error") require.Equal(t, "/storePrefixKey/"+pathStr, prefixedPath.Pretty(), "Prefixed path incorrect") - require.Equal(t, "/storePrefixKey/pathone%2Fpathtwo%2Fpaththree%2Fkey", prefixedPath.String(), "Prefixed scaped path incorrect") - - // invalid prefix contains non-alphanumeric character - invalidPathStr := "invalid-path/doesitfail?/hopefully" - invalidPath, err := types.ApplyPrefix(prefix, invalidPathStr) - require.NotNil(t, err, "invalid prefix does not returns error") - require.Equal(t, types.MerklePath{}, invalidPath, "invalid prefix returns valid Path on ApplyPrefix") + require.Equal(t, "/storePrefixKey/pathone%2Fpathtwo%2Fpaththree%2Fkey", prefixedPath.String(), "Prefixed escaped path incorrect") +} + +func TestString(t *testing.T) { + path := types.NewMerklePath("rootKey", "storeKey", "path/to/leaf") + + require.Equal(t, "/rootKey/storeKey/path%2Fto%2Fleaf", path.String(), "path String returns unxpected value") + require.Equal(t, "/rootKey/storeKey/path/to/leaf", path.Pretty(), "path's pretty string representation is incorrect") + + onePath := types.NewMerklePath("path/to/leaf") + + require.Equal(t, "/path%2Fto%2Fleaf", onePath.String(), "one element path does not have correct string representation") + require.Equal(t, "/path/to/leaf", onePath.Pretty(), "one element path has incorrect pretty string representation") + + zeroPath := types.NewMerklePath() + + require.Equal(t, "", zeroPath.String(), "zero element path does not have correct string representation") + require.Equal(t, "", zeroPath.Pretty(), "zero element path does not have correct pretty string representation") } diff --git a/x/ibc/core/23-commitment/types/utils.go b/x/ibc/core/23-commitment/types/utils.go new file mode 100644 index 000000000..7d2937f0f --- /dev/null +++ b/x/ibc/core/23-commitment/types/utils.go @@ -0,0 +1,27 @@ +package types + +import ( + ics23 "github.com/confio/ics23/go" + sdkerrors "github.com/cosmos/cosmos-sdk/types/errors" + crypto "github.com/tendermint/tendermint/proto/tendermint/crypto" +) + +// ConvertProofs converts crypto.ProofOps into MerkleProof +func ConvertProofs(tmProof *crypto.ProofOps) (MerkleProof, error) { + if tmProof == nil { + return MerkleProof{}, sdkerrors.Wrapf(ErrInvalidMerkleProof, "tendermint proof is nil") + } + // Unmarshal all proof ops to CommitmentProof + proofs := make([]*ics23.CommitmentProof, len(tmProof.Ops)) + for i, op := range tmProof.Ops { + var p ics23.CommitmentProof + err := p.Unmarshal(op.Data) + if err != nil || p.Proof == nil { + return MerkleProof{}, sdkerrors.Wrapf(ErrInvalidMerkleProof, "could not unmarshal proof op into CommitmentProof at index %d: %v", i, err) + } + proofs[i] = &p + } + return MerkleProof{ + Proofs: proofs, + }, nil +} diff --git a/x/ibc/core/23-commitment/types/utils_test.go b/x/ibc/core/23-commitment/types/utils_test.go new file mode 100644 index 000000000..a4c08d13f --- /dev/null +++ b/x/ibc/core/23-commitment/types/utils_test.go @@ -0,0 +1,97 @@ +package types_test + +import ( + "fmt" + + "github.com/cosmos/cosmos-sdk/x/ibc/core/23-commitment/types" + "github.com/stretchr/testify/require" + abci "github.com/tendermint/tendermint/abci/types" + crypto "github.com/tendermint/tendermint/proto/tendermint/crypto" +) + +func (suite *MerkleTestSuite) TestConvertProofs() { + suite.iavlStore.Set([]byte("MYKEY"), []byte("MYVALUE")) + cid := suite.store.Commit() + + root := types.NewMerkleRoot(cid.Hash) + existsPath := types.NewMerklePath(suite.storeKey.Name(), "MYKEY") + nonexistPath := types.NewMerklePath(suite.storeKey.Name(), "NOTMYKEY") + value := []byte("MYVALUE") + + var proofOps *crypto.ProofOps + testcases := []struct { + name string + malleate func() + keyExists bool + expPass bool + }{ + { + "success for ExistenceProof", + func() { + res := suite.store.Query(abci.RequestQuery{ + Path: fmt.Sprintf("/%s/key", suite.storeKey.Name()), // required path to get key/value+proof + Data: []byte("MYKEY"), + Prove: true, + }) + require.NotNil(suite.T(), res.ProofOps) + + proofOps = res.ProofOps + }, + true, true, + }, + { + "success for NonexistenceProof", + func() { + res := suite.store.Query(abci.RequestQuery{ + Path: fmt.Sprintf("/%s/key", suite.storeKey.Name()), // required path to get key/value+proof + Data: []byte("NOTMYKEY"), + Prove: true, + }) + require.NotNil(suite.T(), res.ProofOps) + + proofOps = res.ProofOps + }, + false, true, + }, + { + "nil proofOps", + func() { + proofOps = nil + }, + true, false, + }, + { + "proof op data is nil", + func() { + res := suite.store.Query(abci.RequestQuery{ + Path: fmt.Sprintf("/%s/key", suite.storeKey.Name()), // required path to get key/value+proof + Data: []byte("MYKEY"), + Prove: true, + }) + require.NotNil(suite.T(), res.ProofOps) + + proofOps = res.ProofOps + proofOps.Ops[0].Data = nil + }, + true, false, + }, + } + + for _, tc := range testcases { + tc.malleate() + + proof, err := types.ConvertProofs(proofOps) + if tc.expPass { + suite.Require().NoError(err, "ConvertProofs unexpectedly returned error for case: %s", tc.name) + if tc.keyExists { + err := proof.VerifyMembership(types.GetSDKSpecs(), &root, existsPath, value) + suite.Require().NoError(err, "converted proof failed to verify membership for case: %s", tc.name) + } else { + err := proof.VerifyNonMembership(types.GetSDKSpecs(), &root, nonexistPath) + suite.Require().NoError(err, "converted proof failed to verify membership for case: %s", tc.name) + } + } else { + suite.Require().Error(err, "ConvertProofs passed on invalid case for case: %s", tc.name) + } + } +} diff --git a/x/ibc/core/client/query.go b/x/ibc/core/client/query.go index 273e25583..dad0c2899 100644 --- a/x/ibc/core/client/query.go +++ b/x/ibc/core/client/query.go @@ -50,8 +50,9 @@ func QueryTendermintProof(clientCtx client.Context, key []byte) ([]byte, []byte, return nil, nil, clienttypes.Height{}, err } - merkleProof := commitmenttypes.MerkleProof{ - Proof: res.ProofOps, + merkleProof, err := commitmenttypes.ConvertProofs(res.ProofOps) + if err != nil { + return nil, nil, clienttypes.Height{}, err } cdc := codec.NewProtoCodec(clientCtx.InterfaceRegistry) diff --git a/x/ibc/core/keeper/msg_server_test.go b/x/ibc/core/keeper/msg_server_test.go index 0bed10ae7..a80426724 100644 --- a/x/ibc/core/keeper/msg_server_test.go +++ b/x/ibc/core/keeper/msg_server_test.go @@ -41,6 +41,9 @@ func (suite *KeeperTestSuite) SetupTest() { suite.chainA = suite.coordinator.GetChain(ibctesting.GetChainID(0)) suite.chainB = suite.coordinator.GetChain(ibctesting.GetChainID(1)) + // commit some blocks so that QueryProof returns valid proof (cannot return valid query if height <= 1) + suite.coordinator.CommitNBlocks(suite.chainA, 2) + suite.coordinator.CommitNBlocks(suite.chainB, 2) } func TestIBCTestSuite(t *testing.T) { diff --git a/x/ibc/light-clients/06-solomachine/types/client_state.go b/x/ibc/light-clients/06-solomachine/types/client_state.go index f23b6824b..583193f3d 100644 --- a/x/ibc/light-clients/06-solomachine/types/client_state.go +++ b/x/ibc/light-clients/06-solomachine/types/client_state.go @@ -100,7 +100,7 @@ func (cs ClientState) VerifyClientState( return err } - clientPrefixedPath := "clients/" + counterpartyClientIdentifier + "/" + host.ClientStatePath() + clientPrefixedPath := commitmenttypes.NewMerklePath("clients/" + counterpartyClientIdentifier + "/" + host.ClientStatePath()) path, err := commitmenttypes.ApplyPrefix(prefix, clientPrefixedPath) if err != nil { return err @@ -138,7 +138,7 @@ func (cs ClientState) VerifyClientConsensusState( return err } - clientPrefixedPath := "clients/" + counterpartyClientIdentifier + "/" + host.ConsensusStatePath(consensusHeight) + clientPrefixedPath := commitmenttypes.NewMerklePath("clients/" + counterpartyClientIdentifier + "/" + host.ConsensusStatePath(consensusHeight)) path, err := commitmenttypes.ApplyPrefix(prefix, clientPrefixedPath) if err != nil { return err @@ -175,7 +175,8 @@ func (cs ClientState) VerifyConnectionState( return err } - path, err := commitmenttypes.ApplyPrefix(prefix, host.ConnectionPath(connectionID)) + connectionPath := commitmenttypes.NewMerklePath(host.ConnectionPath(connectionID)) + path, err := commitmenttypes.ApplyPrefix(prefix, connectionPath) if err != nil { return err } @@ -212,7 +213,8 @@ func (cs ClientState) VerifyChannelState( return err } - path, err := commitmenttypes.ApplyPrefix(prefix, host.ChannelPath(portID, channelID)) + channelPath := commitmenttypes.NewMerklePath(host.ChannelPath(portID, channelID)) + path, err := commitmenttypes.ApplyPrefix(prefix, channelPath) if err != nil { return err } @@ -250,7 +252,8 @@ func (cs ClientState) VerifyPacketCommitment( return err } - path, err := commitmenttypes.ApplyPrefix(prefix, host.PacketCommitmentPath(portID, channelID, packetSequence)) + commitmentPath := commitmenttypes.NewMerklePath(host.PacketCommitmentPath(portID, channelID, packetSequence)) + path, err := commitmenttypes.ApplyPrefix(prefix, commitmentPath) if err != nil { return err } @@ -288,7 +291,8 @@ func (cs ClientState) VerifyPacketAcknowledgement( return err } - path, err := commitmenttypes.ApplyPrefix(prefix, host.PacketAcknowledgementPath(portID, channelID, packetSequence)) + ackPath := commitmenttypes.NewMerklePath(host.PacketAcknowledgementPath(portID, channelID, packetSequence)) + path, err := commitmenttypes.ApplyPrefix(prefix, ackPath) if err != nil { return err } @@ -326,7 +330,8 @@ func (cs ClientState) VerifyPacketReceiptAbsence( return err } - path, err := commitmenttypes.ApplyPrefix(prefix, host.PacketReceiptPath(portID, channelID, packetSequence)) + receiptPath := commitmenttypes.NewMerklePath(host.PacketReceiptPath(portID, channelID, packetSequence)) + path, err := commitmenttypes.ApplyPrefix(prefix, receiptPath) if err != nil { return err } @@ -363,7 +368,8 @@ func (cs ClientState) VerifyNextSequenceRecv( return err } - path, err := commitmenttypes.ApplyPrefix(prefix, host.NextSequenceRecvPath(portID, channelID)) + nextSequenceRecvPath := commitmenttypes.NewMerklePath(host.NextSequenceRecvPath(portID, channelID)) + path, err := commitmenttypes.ApplyPrefix(prefix, nextSequenceRecvPath) if err != nil { return err } diff --git a/x/ibc/light-clients/07-tendermint/types/client_state.go b/x/ibc/light-clients/07-tendermint/types/client_state.go index 4e4104d8d..65d431245 100644 --- a/x/ibc/light-clients/07-tendermint/types/client_state.go +++ b/x/ibc/light-clients/07-tendermint/types/client_state.go @@ -180,7 +180,7 @@ func (cs ClientState) VerifyClientState( return err } - clientPrefixedPath := "clients/" + counterpartyClientIdentifier + "/" + host.ClientStatePath() + clientPrefixedPath := commitmenttypes.NewMerklePath("clients/" + counterpartyClientIdentifier + "/" + host.ClientStatePath()) path, err := commitmenttypes.ApplyPrefix(prefix, clientPrefixedPath) if err != nil { return err @@ -220,7 +220,7 @@ func (cs ClientState) VerifyClientConsensusState( return err } - clientPrefixedPath := "clients/" + counterpartyClientIdentifier + "/" + host.ConsensusStatePath(consensusHeight) + clientPrefixedPath := commitmenttypes.NewMerklePath("clients/" + counterpartyClientIdentifier + "/" + host.ConsensusStatePath(consensusHeight)) path, err := commitmenttypes.ApplyPrefix(prefix, clientPrefixedPath) if err != nil { return err @@ -263,7 +263,8 @@ func (cs ClientState) VerifyConnectionState( return err } - path, err := commitmenttypes.ApplyPrefix(prefix, host.ConnectionPath(connectionID)) + connectionPath := commitmenttypes.NewMerklePath(host.ConnectionPath(connectionID)) + path, err := commitmenttypes.ApplyPrefix(prefix, connectionPath) if err != nil { return err } @@ -302,7 +303,8 @@ func (cs ClientState) VerifyChannelState( return err } - path, err := commitmenttypes.ApplyPrefix(prefix, host.ChannelPath(portID, channelID)) + channelPath := commitmenttypes.NewMerklePath(host.ChannelPath(portID, channelID)) + path, err := commitmenttypes.ApplyPrefix(prefix, channelPath) if err != nil { return err } @@ -342,7 +344,8 @@ func (cs ClientState) VerifyPacketCommitment( return err } - path, err := commitmenttypes.ApplyPrefix(prefix, host.PacketCommitmentPath(portID, channelID, sequence)) + commitmentPath := commitmenttypes.NewMerklePath(host.PacketCommitmentPath(portID, channelID, sequence)) + path, err := commitmenttypes.ApplyPrefix(prefix, commitmentPath) if err != nil { return err } @@ -372,7 +375,8 @@ func (cs ClientState) VerifyPacketAcknowledgement( return err } - path, err := commitmenttypes.ApplyPrefix(prefix, host.PacketAcknowledgementPath(portID, channelID, sequence)) + ackPath := commitmenttypes.NewMerklePath(host.PacketAcknowledgementPath(portID, channelID, sequence)) + path, err := commitmenttypes.ApplyPrefix(prefix, ackPath) if err != nil { return err } @@ -402,7 +406,8 @@ func (cs ClientState) VerifyPacketReceiptAbsence( return err } - path, err := commitmenttypes.ApplyPrefix(prefix, host.PacketReceiptPath(portID, channelID, sequence)) + receiptPath := commitmenttypes.NewMerklePath(host.PacketReceiptPath(portID, channelID, sequence)) + path, err := commitmenttypes.ApplyPrefix(prefix, receiptPath) if err != nil { return err } @@ -431,7 +436,8 @@ func (cs ClientState) VerifyNextSequenceRecv( return err } - path, err := commitmenttypes.ApplyPrefix(prefix, host.NextSequenceRecvPath(portID, channelID)) + nextSequenceRecvPath := commitmenttypes.NewMerklePath(host.NextSequenceRecvPath(portID, channelID)) + path, err := commitmenttypes.ApplyPrefix(prefix, nextSequenceRecvPath) if err != nil { return err } diff --git a/x/ibc/light-clients/07-tendermint/types/tendermint_test.go b/x/ibc/light-clients/07-tendermint/types/tendermint_test.go index 171d33f56..c30a784a5 100644 --- a/x/ibc/light-clients/07-tendermint/types/tendermint_test.go +++ b/x/ibc/light-clients/07-tendermint/types/tendermint_test.go @@ -60,6 +60,9 @@ func (suite *TendermintTestSuite) SetupTest() { suite.coordinator = ibctesting.NewCoordinator(suite.T(), 2) suite.chainA = suite.coordinator.GetChain(ibctesting.GetChainID(0)) suite.chainB = suite.coordinator.GetChain(ibctesting.GetChainID(1)) + // commit some blocks so that QueryProof returns valid proof (cannot return valid query if height <= 1) + suite.coordinator.CommitNBlocks(suite.chainA, 2) + suite.coordinator.CommitNBlocks(suite.chainB, 2) // TODO: deprecate usage in favor of testing package checkTx := false diff --git a/x/ibc/light-clients/07-tendermint/types/upgrade.go b/x/ibc/light-clients/07-tendermint/types/upgrade.go index 3c096f94a..28f02950d 100644 --- a/x/ibc/light-clients/07-tendermint/types/upgrade.go +++ b/x/ibc/light-clients/07-tendermint/types/upgrade.go @@ -117,5 +117,5 @@ func constructUpgradeMerklePath(upgradePath string, upgradeHeight exported.Heigh // append upgradeHeight to last key in merkle path // this will create the IAVL key that is used to store client in upgrade store upgradeKeys[len(upgradeKeys)-1] = fmt.Sprintf("%s/%d", lastKey, upgradeHeight.GetVersionHeight()) - return commitmenttypes.NewMerklePath(upgradeKeys), nil + return commitmenttypes.NewMerklePath(upgradeKeys...), nil } diff --git a/x/ibc/testing/chain.go b/x/ibc/testing/chain.go index c29c111e8..f43c4d267 100644 --- a/x/ibc/testing/chain.go +++ b/x/ibc/testing/chain.go @@ -197,9 +197,8 @@ func (chain *TestChain) QueryProof(key []byte) ([]byte, clienttypes.Height) { Prove: true, }) - merkleProof := commitmenttypes.MerkleProof{ - Proof: res.ProofOps, - } + merkleProof, err := commitmenttypes.ConvertProofs(res.ProofOps) + require.NoError(chain.t, err) proof, err := chain.App.AppCodec().MarshalBinaryBare(&merkleProof) require.NoError(chain.t, err) @@ -222,9 +221,8 @@ func (chain *TestChain) QueryUpgradeProof(key []byte, height uint64) ([]byte, cl Prove: true, }) - merkleProof := commitmenttypes.MerkleProof{ - Proof: res.ProofOps, - } + merkleProof, err := commitmenttypes.ConvertProofs(res.ProofOps) + require.NoError(chain.t, err) proof, err := chain.App.AppCodec().MarshalBinaryBare(&merkleProof) require.NoError(chain.t, err) diff --git a/x/ibc/testing/solomachine.go b/x/ibc/testing/solomachine.go index 6b2508f30..0d3b35811 100644 --- a/x/ibc/testing/solomachine.go +++ b/x/ibc/testing/solomachine.go @@ -251,7 +251,7 @@ func (solo *Solomachine) GenerateSignature(signBytes []byte) []byte { // GetClientStatePath returns the commitment path for the client state. func (solo *Solomachine) GetClientStatePath(counterpartyClientIdentifier string) commitmenttypes.MerklePath { - clientPrefixedPath := "clients/" + counterpartyClientIdentifier + "/" + host.ClientStatePath() + clientPrefixedPath := commitmenttypes.NewMerklePath("clients/" + counterpartyClientIdentifier + "/" + host.ClientStatePath()) path, err := commitmenttypes.ApplyPrefix(prefix, clientPrefixedPath) require.NoError(solo.t, err) @@ -260,7 +260,7 @@ func (solo *Solomachine) GetClientStatePath(counterpartyClientIdentifier string) // GetConsensusStatePath returns the commitment path for the consensus state. func (solo *Solomachine) GetConsensusStatePath(counterpartyClientIdentifier string, consensusHeight exported.Height) commitmenttypes.MerklePath { - clientPrefixedPath := "clients/" + counterpartyClientIdentifier + "/" + host.ConsensusStatePath(consensusHeight) + clientPrefixedPath := commitmenttypes.NewMerklePath("clients/" + counterpartyClientIdentifier + "/" + host.ConsensusStatePath(consensusHeight)) path, err := commitmenttypes.ApplyPrefix(prefix, clientPrefixedPath) require.NoError(solo.t, err) @@ -269,7 +269,8 @@ func (solo *Solomachine) GetConsensusStatePath(counterpartyClientIdentifier stri // GetConnectionStatePath returns the commitment path for the connection state. func (solo *Solomachine) GetConnectionStatePath(connID string) commitmenttypes.MerklePath { - path, err := commitmenttypes.ApplyPrefix(prefix, host.ConnectionPath(connID)) + connectionPath := commitmenttypes.NewMerklePath(host.ConnectionPath(connID)) + path, err := commitmenttypes.ApplyPrefix(prefix, connectionPath) require.NoError(solo.t, err) return path @@ -277,7 +278,8 @@ func (solo *Solomachine) GetConnectionStatePath(connID string) commitmenttypes.M // GetChannelStatePath returns the commitment path for that channel state. func (solo *Solomachine) GetChannelStatePath(portID, channelID string) commitmenttypes.MerklePath { - path, err := commitmenttypes.ApplyPrefix(prefix, host.ChannelPath(portID, channelID)) + channelPath := commitmenttypes.NewMerklePath(host.ChannelPath(portID, channelID)) + path, err := commitmenttypes.ApplyPrefix(prefix, channelPath) require.NoError(solo.t, err) return path @@ -285,7 +287,8 @@ func (solo *Solomachine) GetChannelStatePath(portID, channelID string) commitmen // GetPacketCommitmentPath returns the commitment path for a packet commitment. func (solo *Solomachine) GetPacketCommitmentPath(portID, channelID string) commitmenttypes.MerklePath { - path, err := commitmenttypes.ApplyPrefix(prefix, host.PacketCommitmentPath(portID, channelID, solo.Sequence)) + commitmentPath := commitmenttypes.NewMerklePath(host.PacketCommitmentPath(portID, channelID, solo.Sequence)) + path, err := commitmenttypes.ApplyPrefix(prefix, commitmentPath) require.NoError(solo.t, err) return path @@ -293,7 +296,8 @@ func (solo *Solomachine) GetPacketCommitmentPath(portID, channelID string) commi // GetPacketAcknowledgementPath returns the commitment path for a packet acknowledgement. func (solo *Solomachine) GetPacketAcknowledgementPath(portID, channelID string) commitmenttypes.MerklePath { - path, err := commitmenttypes.ApplyPrefix(prefix, host.PacketAcknowledgementPath(portID, channelID, solo.Sequence)) + ackPath := commitmenttypes.NewMerklePath(host.PacketAcknowledgementPath(portID, channelID, solo.Sequence)) + path, err := commitmenttypes.ApplyPrefix(prefix, ackPath) require.NoError(solo.t, err) return path @@ -302,7 +306,8 @@ func (solo *Solomachine) GetPacketAcknowledgementPath(portID, channelID string) // GetPacketReceiptPath returns the commitment path for a packet receipt // and an absent receipts. func (solo *Solomachine) GetPacketReceiptPath(portID, channelID string) commitmenttypes.MerklePath { - path, err := commitmenttypes.ApplyPrefix(prefix, host.PacketReceiptPath(portID, channelID, solo.Sequence)) + receiptPath := commitmenttypes.NewMerklePath(host.PacketReceiptPath(portID, channelID, solo.Sequence)) + path, err := commitmenttypes.ApplyPrefix(prefix, receiptPath) require.NoError(solo.t, err) return path @@ -310,7 +315,8 @@ func (solo *Solomachine) GetPacketReceiptPath(portID, channelID string) commitme // GetNextSequenceRecvPath returns the commitment path for the next sequence recv counter. func (solo *Solomachine) GetNextSequenceRecvPath(portID, channelID string) commitmenttypes.MerklePath { - path, err := commitmenttypes.ApplyPrefix(prefix, host.NextSequenceRecvPath(portID, channelID)) + nextSequenceRecvPath := commitmenttypes.NewMerklePath(host.NextSequenceRecvPath(portID, channelID)) + path, err := commitmenttypes.ApplyPrefix(prefix, nextSequenceRecvPath) require.NoError(solo.t, err) return path diff --git a/x/staking/types/staking.pb.go b/x/staking/types/staking.pb.go index 865953c9d..102fcea42 100644 --- a/x/staking/types/staking.pb.go +++ b/x/staking/types/staking.pb.go @@ -1216,606 +1216,608 @@ func (this *Pool) Description() (desc *github_com_gogo_protobuf_protoc_gen_gogo_ func StakingDescription() (desc *github_com_gogo_protobuf_protoc_gen_gogo_descriptor.FileDescriptorSet) { d := &github_com_gogo_protobuf_protoc_gen_gogo_descriptor.FileDescriptorSet{} var gzipped = []byte{ - // 9578 bytes of a gzipped FileDescriptorSet + // 9603 bytes of a gzipped FileDescriptorSet 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xec, 0x7d, 0x6d, 0x70, 0x24, 0xd7, 0x71, 0xd8, 0xcd, 0x7e, 0x00, 0xbb, 0x8d, 0x05, 0xb0, 0x78, 0xc0, 0xdd, 0xed, 0x2d, 0x8f, 0x00, 0x38, 0xfc, 0x3a, 0x1e, 0x49, 0x80, 0x3c, 0xf2, 0x8e, 0xe4, 0x9e, 0x44, 0x1a, 0x0b, 0xec, 0xe1, 0xc0, 0xc3, 0x17, 0x07, 0xc0, 0x91, 0xfa, 0x70, 0xb6, 0x06, 0xb3, 0x0f, 0x8b, 0x21, 0x76, 0x67, - 0x86, 0x33, 0xb3, 0x77, 0x07, 0x4a, 0xaa, 0xa2, 0x25, 0x45, 0x91, 0xe8, 0x38, 0x92, 0x2c, 0x97, - 0x23, 0x51, 0x3a, 0x45, 0xb2, 0x9c, 0xc8, 0x91, 0x95, 0xf8, 0x43, 0x8a, 0x12, 0x27, 0xa9, 0x8a, - 0x9c, 0x8a, 0x63, 0x49, 0xa9, 0xb8, 0xa4, 0x8a, 0x2b, 0x71, 0x5c, 0xc9, 0xd9, 0xa1, 0x54, 0x0e, - 0xa3, 0x28, 0xb1, 0x7c, 0x96, 0x13, 0xa7, 0x54, 0xa9, 0xa4, 0xde, 0xd7, 0x7c, 0xed, 0xc7, 0x2c, - 0xa0, 0x3b, 0x49, 0x8e, 0xf3, 0x0b, 0xfb, 0x7a, 0xba, 0xfb, 0x75, 0xf7, 0xeb, 0xd7, 0xaf, 0x5f, - 0xcf, 0x7b, 0x03, 0xf8, 0xf8, 0x79, 0x98, 0xae, 0x9b, 0x66, 0xbd, 0x81, 0x67, 0x2d, 0xdb, 0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0x21, 0x9f, 0x08, 0xc2, 0xd6, - 0x2b, 0x73, 0x9b, 0x95, 0x85, 0x7c, 0x52, 0xd6, 0x60, 0xa2, 0x53, 0x9c, 0xec, 0x38, 0x33, 0x02, - 0x43, 0x9c, 0xe8, 0x32, 0xc4, 0x94, 0x57, 0xdb, 0x10, 0x7f, 0x33, 0x01, 0xe3, 0x1d, 0xd6, 0x8a, - 0x8e, 0x9d, 0x3c, 0x03, 0x69, 0xe6, 0xa2, 0x6c, 0xf5, 0x7c, 0xa0, 0xe3, 0xa2, 0x43, 0x1d, 0xb6, - 0x6d, 0x05, 0xa5, 0x74, 0xc1, 0x0c, 0x22, 0xd9, 0x25, 0x83, 0x20, 0x2c, 0xda, 0x62, 0xfa, 0x4f, - 0xb6, 0xc5, 0x74, 0xb6, 0xec, 0x9d, 0xeb, 0x67, 0xd9, 0xa3, 0xb0, 0x83, 0xc5, 0xf6, 0x74, 0x87, - 0xd8, 0x7e, 0x1e, 0xc6, 0xda, 0x18, 0xf5, 0x1d, 0x63, 0xdf, 0x23, 0x41, 0xa1, 0x9b, 0x71, 0x62, - 0x22, 0x5d, 0x22, 0x14, 0xe9, 0xce, 0x47, 0x2d, 0x78, 0x57, 0xf7, 0x41, 0x68, 0x1b, 0xeb, 0xcf, - 0x4a, 0x70, 0xac, 0x73, 0xa6, 0xd8, 0x51, 0x86, 0xa7, 0x61, 0xa0, 0x89, 0xdd, 0x5d, 0x53, 0x64, - 0x4b, 0xf7, 0x75, 0x58, 0x83, 0xc9, 0xe3, 0xe8, 0x60, 0x73, 0xaa, 0xe0, 0x22, 0x9e, 0xec, 0x96, - 0xee, 0x31, 0x69, 0xda, 0x24, 0xfd, 0x40, 0x02, 0x8e, 0x76, 0x64, 0xde, 0x51, 0xd0, 0x3b, 0x01, - 0x74, 0xc3, 0x6a, 0xb9, 0x2c, 0x23, 0x62, 0x01, 0x36, 0x4b, 0x21, 0x34, 0x78, 0x91, 0xe0, 0xd9, - 0x72, 0xbd, 0xe7,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 0x3f, 0x9b, 0xca, 0xdc, 0x97, 0xbf, 0x5f, 0xfe, - 0x46, 0x02, 0x46, 0xc2, 0x3b, 0x30, 0xf4, 0x26, 0x38, 0x2e, 0xca, 0x25, 0x0e, 0x76, 0xab, 0x57, - 0x75, 0x9b, 0xce, 0xc8, 0xa6, 0xca, 0x56, 0x47, 0xcf, 0x27, 0x26, 0x38, 0xd6, 0x06, 0x76, 0x9f, - 0xd7, 0x6d, 0x32, 0xdf, 0x9a, 0xaa, 0x8b, 0x96, 0x61, 0xca, 0x30, 0xab, 0x8e, 0xab, 0x1a, 0x35, - 0xd5, 0xae, 0x55, 0xfd, 0x42, 0x55, 0x55, 0xd5, 0x34, 0xec, 0x38, 0x26, 0x5b, 0x09, 0x3d, 0x2e, - 0x27, 0x0d, 0x73, 0x83, 0x23, 0xfb, 0x4b, 0xc4, 0x1c, 0x47, 0x8d, 0xf8, 0x6f, 0xb2, 0x9b, 0xff, - 0xde, 0x01, 0xd9, 0xa6, 0x6a, 0x55, 0xb1, 0xe1, 0xda, 0xfb, 0x34, 0xef, 0xce, 0x28, 0x99, 0xa6, - 0x6a, 0x55, 0x48, 0xfb, 0x87, 0xb2, 0xfd, 0x79, 0x36, 0x95, 0xc9, 0xe4, 0xb3, 0xcf, 0xa6, 0x32, - 0xd9, 0x3c, 0xc8, 0xaf, 0x27, 0x21, 0x17, 0xcc, 0xc3, 0xc9, 0xb6, 0x46, 0xa3, 0x4b, 0x96, 0x44, - 0x83, 0xda, 0xdd, 0x3d, 0xb3, 0xf6, 0x99, 0x79, 0xb2, 0x96, 0x95, 0x06, 0x58, 0x76, 0xac, 0x30, - 0x4a, 0x92, 0x47, 0x10, 0x67, 0xc3, 0x2c, 0x1b, 0xc9, 0x28, 0xbc, 0x85, 0x16, 0x61, 0xe0, 0x45, - 0x87, 0xf2, 0x1e, 0xa0, 0xbc, 0xef, 0xe9, 0xcd, 0xfb, 0xd9, 0x0d, 0xca, 0x3c, 0xfb, 0xec, 0x46, - 0x75, 0x75, 0x4d, 0x59, 0x99, 0x5b, 0x56, 0x38, 0x39, 0x3a, 0x01, 0xa9, 0x86, 0xfa, 0xf2, 0x7e, - 0x78, 0xd5, 0xa3, 0xa0, 0x7e, 0x07, 0xe1, 0x04, 0xa4, 0xae, 0x62, 0x75, 0x2f, 0xbc, 0xd6, 0x50, - 0xd0, 0x6d, 0x9c, 0x0c, 0xb3, 0x90, 0xa6, 0xf6, 0x42, 0x00, 0xdc, 0x62, 0xf9, 0x23, 0x28, 0x03, - 0xa9, 0xf9, 0x35, 0x85, 0x4c, 0x88, 0x3c, 0xe4, 0x18, 0xb4, 0xba, 0xbe, 0x54, 0x99, 0xaf, 0xe4, - 0x13, 0xf2, 0x59, 0x18, 0x60, 0x46, 0x20, 0x93, 0xc5, 0x33, 0x43, 0xfe, 0x08, 0x6f, 0x72, 0x1e, - 0x92, 0x78, 0xba, 0xb5, 0x52, 0xae, 0x28, 0xf9, 0x44, 0x78, 0xa8, 0x53, 0xf9, 0xb4, 0xec, 0x40, - 0x2e, 0x98, 0x88, 0xff, 0x70, 0x36, 0xd9, 0x5f, 0x96, 0x60, 0x28, 0x90, 0x58, 0x93, 0x8c, 0x48, - 0x6d, 0x34, 0xcc, 0xab, 0x55, 0xb5, 0xa1, 0xab, 0x0e, 0x77, 0x0d, 0xa0, 0xa0, 0x39, 0x02, 0xe9, - 0x77, 0xe8, 0x7e, 0x48, 0x53, 0x24, 0x9d, 0x1f, 0x90, 0x3f, 0x29, 0x41, 0x3e, 0x9a, 0xd9, 0x46, - 0xc4, 0x94, 0x7e, 0x94, 0x62, 0xca, 0x9f, 0x90, 0x60, 0x24, 0x9c, 0xce, 0x46, 0xc4, 0xbb, 0xeb, - 0x47, 0x2a, 0xde, 0x1f, 0x26, 0x60, 0x38, 0x94, 0xc4, 0xf6, 0x2b, 0xdd, 0x4b, 0x30, 0xa6, 0xd7, - 0x70, 0xd3, 0x32, 0x5d, 0x6c, 0x68, 0xfb, 0xd5, 0x06, 0xb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, - 0x13, 0xe4, 0x82, 0x84, 0x90, 0xf7, 0x6f, 0xc2, 0x2f, 0xff, 0x74, 0x8a, 0x2f, 0x3a, 0xc2, 0x76, - 0xe7, 0x61, 0x90, 0x67, 0x2a, 0xf1, 0xd4, 0x1f, 0xe0, 0x9d, 0x0b, 0x8a, 0xd2, 0x13, 0x90, 0xee, - 0xd3, 0xe0, 0x3f, 0xc3, 0x49, 0x19, 0x7e, 0x69, 0x1e, 0x86, 0x02, 0xd9, 0x49, 0x3c, 0xf9, 0xdf, - 0xe0, 0xe4, 0x41, 0x2a, 0x22, 0x3a, 0xcf, 0x4e, 0xe2, 0x19, 0x7c, 0x50, 0x88, 0xce, 0x29, 0x88, - 0xd9, 0x44, 0x62, 0x12, 0x4f, 0xfd, 0x21, 0x61, 0x75, 0x41, 0x52, 0x7a, 0x06, 0xb2, 0xde, 0x62, - 0x13, 0x4f, 0xff, 0x61, 0x4e, 0xef, 0xd3, 0x10, 0x0b, 0x04, 0x16, 0xbb, 0x78, 0x16, 0x3f, 0x2b, - 0x2c, 0x10, 0xa0, 0x22, 0xd3, 0x28, 0x9a, 0xc0, 0xc4, 0x73, 0xfa, 0x88, 0x98, 0x46, 0x91, 0xfc, - 0x85, 0x8c, 0x26, 0x8d, 0xf9, 0xf1, 0x2c, 0x7e, 0x4e, 0x8c, 0x26, 0xc5, 0x27, 0x62, 0x44, 0x33, - 0x82, 0x78, 0x1e, 0x7f, 0x53, 0x88, 0x11, 0x49, 0x08, 0x4a, 0xeb, 0x80, 0xda, 0xb3, 0x81, 0x78, - 0x7e, 0x1f, 0xe5, 0xfc, 0xc6, 0xda, 0x92, 0x81, 0xd2, 0xf3, 0x70, 0xac, 0x73, 0x26, 0x10, 0xcf, - 0xf5, 0x63, 0xdf, 0x8b, 0xec, 0xdd, 0x82, 0x89, 0x40, 0x69, 0xd3, 0x5f, 0x52, 0x82, 0x59, 0x40, - 0x3c, 0xdb, 0xd7, 0xbe, 0x17, 0x0e, 0xdc, 0xc1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xb6, 0x22, 0x93, 0x58, 0xba, 0xef, 0x62, 0x47, 0x6c, 0xe8, - 0x68, 0x03, 0x3d, 0x2e, 0xd6, 0xd5, 0x64, 0xef, 0x75, 0x95, 0x3b, 0x22, 0x5f, 0x5d, 0x1b, 0x30, - 0x58, 0x26, 0xa1, 0x78, 0x69, 0xc1, 0x13, 0x44, 0xf2, 0x05, 0x41, 0x2b, 0x30, 0x6a, 0xa9, 0xb6, - 0x4b, 0x8f, 0xee, 0xef, 0x52, 0x2d, 0xb8, 0xaf, 0x4f, 0xb5, 0xcf, 0xbc, 0x90, 0xb2, 0xbc, 0x97, - 0x61, 0x2b, 0x08, 0x94, 0xff, 0x28, 0x05, 0x03, 0xdc, 0x18, 0x6f, 0x86, 0x41, 0x6e, 0x56, 0xee, - 0x9d, 0x77, 0xce, 0xb4, 0x2f, 0x4c, 0x33, 0xde, 0x02, 0xc2, 0xf9, 0x09, 0x1a, 0x74, 0x1f, 0x64, - 0xb4, 0x5d, 0x55, 0x37, 0xaa, 0x7a, 0x4d, 0x64, 0xbd, 0xaf, 0xdf, 0x98, 0x1a, 0x9c, 0x27, 0xb0, - 0xa5, 0x05, 0x65, 0x90, 0x3e, 0x5c, 0xaa, 0x91, 0x4c, 0x60, 0x17, 0xeb, 0xf5, 0x5d, 0x97, 0xcf, - 0x30, 0xde, 0x42, 0x4f, 0x42, 0x8a, 0x38, 0x04, 0xbf, 0xd9, 0x55, 0x6c, 0xdb, 0x7b, 0x78, 0x1b, - 0xc0, 0x72, 0x86, 0x74, 0xfc, 0xa1, 0x3f, 0x98, 0x92, 0x14, 0x4a, 0x81, 0xe6, 0x61, 0xb8, 0xa1, - 0x3a, 0x6e, 0x95, 0xae, 0x60, 0xa4, 0xfb, 0x34, 0x65, 0x71, 0xa2, 0xdd, 0x20, 0xdc, 0xb0, 0x5c, - 0xf4, 0x21, 0x42, 0xc5, 0x40, 0x35, 0x74, 0x0a, 0xf2, 0x94, 0x89, 0x66, 0x36, 0x9b, 0xba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77, 0x30, 0x3e, - 0x37, 0x6f, 0x4c, 0x8d, 0xee, 0xab, 0xcd, 0x46, 0x49, 0x16, 0x7c, 0x64, 0x65, 0xb0, 0xa9, 0x5e, - 0x23, 0x22, 0x22, 0x0b, 0x46, 0x09, 0x54, 0xdb, 0x55, 0x8d, 0x3a, 0x66, 0x9d, 0xd0, 0x12, 0x68, - 0xf9, 0xe2, 0x81, 0x3b, 0x39, 0xe6, 0x77, 0x12, 0x60, 0x27, 0x2b, 0xc3, 0x4d, 0xf5, 0xda, 0x3c, - 0x05, 0x90, 0x1e, 0x4b, 0x99, 0x8f, 0x7e, 0x6a, 0xea, 0x08, 0x7d, 0xb9, 0xf0, 0x0d, 0x09, 0xc0, - 0xb7, 0x18, 0x7a, 0x3b, 0xe4, 0x35, 0xaf, 0x45, 0x69, 0x1d, 0x3e, 0x86, 0xf7, 0x77, 0x1b, 0x8b, - 0x88, 0xbd, 0xd9, 0xda, 0xfc, 0xf5, 0x1b, 0x53, 0x92, 0x32, 0xaa, 0x45, 0x86, 0xe2, 0x6d, 0x30, - 0xd4, 0xb2, 0x6a, 0xaa, 0x8b, 0xab, 0x74, 0x1f, 0x97, 0x88, 0x5d, 0xe7, 0x27, 0x09, 0xaf, 0x9b, - 0x37, 0xa6, 0x10, 0x53, 0x2b, 0x40, 0x2c, 0xd3, 0xd5, 0x1f, 0x18, 0x84, 0x10, 0x04, 0x74, 0xfa, - 0xaa, 0x04, 0x43, 0x0b, 0x81, 0x93, 0x5e, 0x05, 0x18, 0x6c, 0x9a, 0x86, 0xbe, 0xc7, 0xfd, 0x31, - 0xab, 0x88, 0x26, 0x2a, 0x42, 0x86, 0x5d, 0xba, 0x73, 0xf7, 0x45, 0x29, 0x54, 0xb4, 0x09, 0xd5, - 0x55, 0xbc, 0xed, 0xe8, 0x62, 0x34, 0x14, 0xd1, 0x44, 0x17, 0x20, 0xef, 0x60, 0xad, 0x65, 0xeb, - 0xee, 0x7e, 0x55, 0x33, 0x0d, 0x57, 0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0xdd, 0x88, 0xa2, 0x3b, 0x67, 0x13, - 0xb1, 0xc6, 0x07, 0x93, 0x50, 0xe8, 0x46, 0x89, 0xe6, 0x61, 0x54, 0xb3, 0x31, 0x05, 0x54, 0x83, - 0x95, 0xbf, 0x72, 0xd1, 0xcf, 0x2c, 0x23, 0x08, 0xb2, 0x32, 0x22, 0x20, 0x7c, 0xf5, 0xa8, 0x03, - 0x49, 0xfb, 0x88, 0xdb, 0x11, 0xac, 0x3e, 0xf3, 0x3c, 0x99, 0x2f, 0x1f, 0xa2, 0x93, 0x30, 0x03, - 0xb6, 0x7e, 0x8c, 0xf8, 0x50, 0xba, 0x80, 0xbc, 0x04, 0xa3, 0xba, 0xa1, 0xbb, 0xba, 0xda, 0xa8, - 0x6e, 0xab, 0x0d, 0xd5, 0xd0, 0x0e, 0x93, 0x35, 0xb3, 0x90, 0xcf, 0xbb, 0x8d, 0xb0, 0x93, 0x95, - 0x11, 0x0e, 0x29, 0x33, 0x00, 0xba, 0x08, 0x83, 0xa2, 0xab, 0xd4, 0xa1, 0xb2, 0x0d, 0x41, 0x1e, - 0x48, 0xf0, 0x7e, 0x26, 0x09, 0x63, 0x0a, 0xae, 0xfd, 0xff, 0xa1, 0x38, 0xd8, 0x50, 0xac, 0x00, - 0xb0, 0xe9, 0x4e, 0x02, 0xec, 0x21, 0x46, 0x83, 0x04, 0x8c, 0x2c, 0xe3, 0xb0, 0xe0, 0xb8, 0x81, - 0xf1, 0xb8, 0x91, 0x80, 0x5c, 0x70, 0x3c, 0xfe, 0x92, 0xae, 0x4a, 0x68, 0xc9, 0x8f, 0x44, 0x29, - 0xfe, 0x8d, 0xd0, 0x2e, 0x91, 0xa8, 0xcd, 0x7b, 0x7b, 0x87, 0xa0, 0xff, 0x91, 0x80, 0x81, 0x75, - 0xd5, 0x56, 0x9b, 0x0e, 0xd2, 0xda, 0x32, 0x4d, 0x51, 0x7e, 0x6c, 0xfb, 0xc0, 0x33, 0xaf, 0x76, - 0xc4, 0x24,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14, 0x3a, 0x0e, 0x9d, 0xc4, 0xca, 0x1f, 0x41, 0xe3, 0x30, 0xba, 0xba, + 0x56, 0xdd, 0x58, 0x5a, 0xa8, 0x54, 0x2b, 0x17, 0x2e, 0x54, 0xe6, 0x37, 0x37, 0x58, 0xdd, 0xc3, + 0xc3, 0xde, 0x0c, 0x4d, 0x70, 0xf9, 0xb5, 0x24, 0x8c, 0x77, 0x90, 0x04, 0xcd, 0xf1, 0x1d, 0x0b, + 0xdb, 0x44, 0x3d, 0xdc, 0x8f, 0xf4, 0x33, 0x24, 0x67, 0x58, 0x57, 0x6d, 0x97, 0x6f, 0x70, 0x1e, + 0x00, 0x62, 0x25, 0xc3, 0xd5, 0x77, 0x74, 0x6c, 0xf3, 0x7a, 0x12, 0xdb, 0xc6, 0x8c, 0xfa, 0x70, + 0x56, 0x52, 0x7a, 0x08, 0x90, 0x65, 0x3a, 0xba, 0xab, 0x5f, 0xc1, 0x55, 0xdd, 0x10, 0xc5, 0x27, + 0xb2, 0xad, 0x49, 0x29, 0x79, 0xd1, 0xb2, 0x64, 0xb8, 0x1e, 0xb6, 0x81, 0xeb, 0x6a, 0x04, 0x9b, + 0x04, 0xf3, 0xa4, 0x92, 0x17, 0x2d, 0x1e, 0xf6, 0x5d, 0x90, 0xab, 0x99, 0x2d, 0x92, 0xeb, 0x31, + 0x3c, 0xb2, 0x76, 0x48, 0xca, 0x10, 0x83, 0x79, 0x28, 0x3c, 0x8b, 0xf7, 0xab, 0x5e, 0x39, 0x65, + 0x88, 0xc1, 0x18, 0xca, 0xfd, 0x30, 0xaa, 0xd6, 0xeb, 0x36, 0x61, 0x2e, 0x18, 0xb1, 0x7d, 0xc9, + 0x88, 0x07, 0xa6, 0x88, 0xc5, 0x67, 0x21, 0x23, 0xec, 0x40, 0x96, 0x6a, 0x62, 0x89, 0xaa, 0xc5, + 0x36, 0xdb, 0x89, 0x53, 0x59, 0x25, 0x63, 0x88, 0xc6, 0xbb, 0x20, 0xa7, 0x3b, 0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xce, 0x9e, 0x7d, 0xf4, + 0x29, 0xe6, 0xed, 0x17, 0x8f, 0x28, 0x02, 0x80, 0x26, 0x21, 0xeb, 0x60, 0xcd, 0x3a, 0x73, 0xf6, + 0xdc, 0xde, 0xa3, 0xcc, 0xbd, 0x2e, 0x1e, 0x51, 0x7c, 0x50, 0x29, 0x43, 0xb4, 0x7e, 0xe3, 0x53, + 0x53, 0x52, 0x39, 0x0d, 0x49, 0xa7, 0xd5, 0xbc, 0xad, 0x3e, 0xf2, 0x5a, 0x1a, 0xa6, 0x83, 0x94, + 0x34, 0x40, 0x5d, 0x51, 0x1b, 0x7a, 0x4d, 0xf5, 0x6f, 0x8a, 0xe7, 0x03, 0x36, 0xa0, 0x18, 0x9d, + 0x4d, 0x50, 0xec, 0x69, 0x49, 0xf9, 0xd7, 0x25, 0xc8, 0x5d, 0x16, 0x9c, 0x37, 0xb0, 0x8b, 0xce, + 0x03, 0x78, 0x3d, 0x89, 0x69, 0x73, 0xc7, 0x4c, 0xb4, 0xaf, 0x19, 0x8f, 0x46, 0x09, 0xa0, 0xa3, + 0x27, 0xa8, 0x23, 0x5a, 0xa6, 0xc3, 0xaf, 0xbf, 0xc4, 0x90, 0x7a, 0xc8, 0xe8, 0x21, 0x40, 0x34, + 0xc2, 0x55, 0xaf, 0x98, 0xae, 0x6e, 0xd4, 0xab, 0x96, 0x79, 0x95, 0x5f, 0x2a, 0x4c, 0x2a, 0x79, + 0xda, 0x72, 0x99, 0x36, 0xac, 0x13, 0x38, 0x11, 0x3a, 0xeb, 0x71, 0x21, 0xab, 0x89, 0x5a, 0xab, + 0xd9, 0xd8, 0x71, 0x78, 0x10, 0x13, 0x8f, 0xe8, 0x3c, 0x0c, 0x5a, 0xad, 0xed, 0xaa, 0x88, 0x18, + 0x43, 0x67, 0x4e, 0x76, 0x9a, 0xff, 0xc2, 0x3f, 0x78, 0x04, 0x18, 0xb0, 0x5a, 0xdb, 0xc4, 0x5b, + 0xee, 0x82, 0x5c, 0x07, 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, 0x10, 0x28, 0xff, 0x61, 0x0a, + 0x06, 0xb8, 0x31, 0xde, 0x0c, 0x83, 0xdc, 0xac, 0xdc, 0x3b, 0xef, 0x9c, 0x69, 0x5f, 0x98, 0x66, + 0xbc, 0x05, 0x84, 0xf3, 0x13, 0x34, 0xe8, 0x3e, 0xc8, 0x68, 0xbb, 0xaa, 0x6e, 0x54, 0xf5, 0x9a, + 0xc8, 0x7a, 0x5f, 0xbf, 0x31, 0x35, 0x38, 0x4f, 0x60, 0x4b, 0x0b, 0xca, 0x20, 0x6d, 0x5c, 0xaa, + 0x91, 0x4c, 0x60, 0x17, 0xeb, 0xf5, 0x5d, 0x97, 0xcf, 0x30, 0xfe, 0x84, 0x9e, 0x84, 0x14, 0x71, + 0x08, 0x7e, 0xb1, 0xab, 0xd8, 0xb6, 0xf7, 0xf0, 0x36, 0x80, 0xe5, 0x0c, 0xe9, 0xf8, 0x43, 0xbf, + 0x3f, 0x25, 0x29, 0x94, 0x02, 0xcd, 0xc3, 0x70, 0x43, 0x75, 0xdc, 0x2a, 0x5d, 0xc1, 0x48, 0xf7, + 0x69, 0xca, 0xe2, 0x44, 0xbb, 0x41, 0xb8, 0x61, 0xb9, 0xe8, 0x43, 0x84, 0x8a, 0x81, 0x6a, 0xe8, + 0x14, 0xe4, 0x29, 0x13, 0xcd, 0x6c, 0x36, 0x75, 0x97, 0xe5, 0x56, 0x03, 0xd4, 0xee, 0x23, 0x04, + 0x3e, 0x4f, 0xc1, 0x34, 0xc3, 0xba, 0x03, 0xb2, 0xf4, 0x2a, 0x09, 0x45, 0x61, 0xc7, 0x26, 0x33, + 0x04, 0x40, 0x1b, 0xef, 0x87, 0x51, 0x3f, 0x3e, 0x32, 0x94, 0x0c, 0xe3, 0xe2, 0x83, 0x29, 0xe2, + 0x23, 0x30, 0x61, 0xe0, 0x6b, 0xf4, 0x20, 0x67, 0x08, 0x3b, 0x4b, 0xb1, 0x11, 0x69, 0xbb, 0x1c, + 0xa6, 0xb8, 0x17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f, + 0x9c, 0x3a, 0x42, 0x5f, 0x2e, 0x7c, 0x43, 0x02, 0xf0, 0x2d, 0x86, 0xde, 0x0e, 0x79, 0xcd, 0x7b, + 0xa2, 0xb4, 0x0e, 0x1f, 0xc3, 0xfb, 0xbb, 0x8d, 0x45, 0xc4, 0xde, 0x6c, 0x6d, 0xfe, 0xfa, 0x8d, + 0x29, 0x49, 0x19, 0xd5, 0x22, 0x43, 0xf1, 0x36, 0x18, 0x6a, 0x59, 0x35, 0xd5, 0xc5, 0x55, 0xba, + 0x8f, 0x4b, 0xc4, 0xae, 0xf3, 0x93, 0x84, 0xd7, 0xcd, 0x1b, 0x53, 0x88, 0xa9, 0x15, 0x20, 0x96, + 0xe9, 0xea, 0x0f, 0x0c, 0x42, 0x08, 0x02, 0x3a, 0x7d, 0x55, 0x82, 0xa1, 0x85, 0xc0, 0x49, 0xaf, + 0x02, 0x0c, 0x36, 0x4d, 0x43, 0xdf, 0xe3, 0xfe, 0x98, 0x55, 0xc4, 0x23, 0x2a, 0x42, 0x86, 0x5d, + 0xba, 0x73, 0xf7, 0x45, 0x29, 0x54, 0x3c, 0x13, 0xaa, 0xab, 0x78, 0xdb, 0xd1, 0xc5, 0x68, 0x28, + 0xe2, 0x11, 0x5d, 0x80, 0xbc, 0x83, 0xb5, 0x96, 0xad, 0xbb, 0xfb, 0x55, 0xcd, 0x34, 0x5c, 0x55, + 0x73, 0xd9, 0xf5, 0xad, 0xf2, 0x1d, 0x37, 0x6f, 0x4c, 0x1d, 0x67, 0xb2, 0x46, 0x31, 0x64, 0x65, + 0x54, 0x80, 0xe6, 0x19, 0x84, 0xf4, 0x50, 0xc3, 0xae, 0xaa, 0x37, 0x9c, 0x02, 0x7b, 0x4f, 0x26, + 0x1e, 0x03, 0xba, 0x7c, 0x6e, 0x30, 0x58, 0xd8, 0xba, 0x00, 0x79, 0xd3, 0xc2, 0x76, 0x28, 0x11, + 0x95, 0xa2, 0x3d, 0x47, 0x31, 0x64, 0x65, 0x54,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f, 0x11, 0x1f, 0x4a, 0x17, + 0x90, 0x97, 0x60, 0x54, 0x37, 0x74, 0x57, 0x57, 0x1b, 0xd5, 0x6d, 0xb5, 0xa1, 0x1a, 0xda, 0x61, + 0xb2, 0x66, 0x16, 0xf2, 0x79, 0xb7, 0x11, 0x76, 0xb2, 0x32, 0xc2, 0x21, 0x65, 0x06, 0x40, 0x17, + 0x61, 0x50, 0x74, 0x95, 0x3a, 0x54, 0xb6, 0x21, 0xc8, 0x03, 0x09, 0xde, 0xcf, 0x24, 0x61, 0x4c, + 0xc1, 0xb5, 0xff, 0x3f, 0x14, 0x07, 0x1b, 0x8a, 0x15, 0x00, 0x36, 0xdd, 0x49, 0x80, 0x3d, 0xc4, + 0x68, 0x90, 0x80, 0x91, 0x65, 0x1c, 0x16, 0x1c, 0x37, 0x30, 0x1e, 0x37, 0x12, 0x90, 0x0b, 0x8e, + 0xc7, 0x5f, 0xd0, 0x55, 0x09, 0x2d, 0xf9, 0x91, 0x28, 0xc5, 0x3f, 0x11, 0xda, 0x25, 0x12, 0xb5, + 0x79, 0x6f, 0xef, 0x10, 0xf4, 0x3f, 0x12, 0x30, 0xb0, 0xae, 0xda, 0x6a, 0xd3, 0x41, 0x5a, 0x5b, + 0xa6, 0x29, 0xca, 0x8f, 0x6d, 0x1f, 0x82, 0xe6, 0xd5, 0x8e, 0x98, 0x44, 0xf3, 0xa3, 0x1d, 0x12, + 0xcd, 0x9f, 0x80, 0x11, 0xb2, 0x1d, 0x0e, 0x1c, 0x61, 0x20, 0xd6, 0x1e, 0x2e, 0x9f, 0xf0, 0xb9, + 0x84, 0xdb, 0xd9, 0x6e, 0xf9, 0x72, 0xf0, 0x0c, 0xc3, 0x10, 0xc1, 0xf0, 0x03, 0x33, 0x21, 0x3f, + 0xe6, 0x6f, 0x4b, 0x03, 0x8d, 0xb2, 0x02, 0x4d, 0xf5, 0x5a, 0x85, 0x3d, 0xa0, 0x65, 0x40, 0xbb, + 0x5e, 0x65, 0xa4, 0x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 0xf3, 0xfe, + 0x2d, 0x0d, 0xbe, 0x66, 0xa9, 0x86, 0x97, 0xef, 0x67, 0x94, 0x93, 0x14, 0x6d, 0x81, 0x62, 0x89, + 0x7f, 0x49, 0x53, 0x11, 0x38, 0xf2, 0xef, 0x25, 0x20, 0x23, 0x58, 0xd3, 0xab, 0x5b, 0xb8, 0x81, + 0x35, 0xd7, 0x14, 0x47, 0x19, 0xbc, 0x67, 0x84, 0x20, 0x59, 0xe7, 0x43, 0x94, 0xbd, 0x78, 0x44, + 0x21, 0x0f, 0x04, 0xe6, 0x5d, 0xa8, 0x23, 0x30, 0xab, 0x45, 0x46, 0x2d, 0x65, 0x99, 0xa2, 0x66, + 0x7a, 0xf1, 0x88, 0x42, 0x9f, 0x50, 0x01, 0x06, 0x88, 0xcb, 0xba, 0xec, 0x8b, 0xc1, 0x04, 0xce, + 0x9f, 0xd1, 0x31, 0x48, 0x5b, 0xaa, 0xab, 0xb1, 0xb3, 0xee, 0xa4, 0x81, 0x3d, 0x92, 0xc0, 0xcc, + 0xbe, 0xd4, 0x10, 0xfd, 0x8f, 0x55, 0xc4, 0x18, 0xec, 0x93, 0x98, 0x44, 0xee, 0x75, 0xd5, 0x75, + 0xb1, 0x6d, 0x10, 0x86, 0x0c, 0x1d, 0x21, 0x48, 0x6d, 0x9b, 0xb5, 0x7d, 0xfe, 0x5f, 0xb4, 0xe8, + 0x6f, 0xfe, 0x6f, 0x7b, 0xa8, 0x3f, 0x54, 0x69, 0x23, 0xfb, 0xe7, 0x81, 0x39, 0x01, 0x2c, 0x13, + 0xa4, 0x0a, 0x8c, 0xab, 0xb5, 0x9a, 0xce, 0xfe, 0xa1, 0x55, 0x75, 0x5b, 0xa7, 0xfb, 0x61, 0x87, + 0xfe, 0x6b, 0xc8, 0x6e, 0x63, 0x81, 0x7c, 0x82, 0x32, 0xc7, 0x2f, 0x67, 0x61, 0xd0, 0x62, 0x42, + 0xc9, 0xe7, 0x61, 0xac, 0x4d, 0x52, 0x22, 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 0xaa, 0x3d, + 0x60, 0x91, 0x2e, 0x62, 0x9c, 0x8e, 0x7c, 0x65, 0x65, 0xa2, 0xd5, 0x29, 0x9b, 0x58, 0x87, 0xe1, + 0xd0, 0x02, 0x56, 0x10, 0xff, 0x71, 0xba, 0xff, 0x1b, 0x16, 0x61, 0x06, 0xa8, 0x08, 0x19, 0x7c, + 0xcd, 0x32, 0x6d, 0x17, 0xd7, 0xe8, 0x91, 0x87, 0x8c, 0xe2, 0x3d, 0xcb, 0xab, 0x80, 0xda, 0x07, + 0x37, 0xfa, 0x1d, 0xd2, 0xac, 0xff, 0x1d, 0xd2, 0x09, 0x48, 0x07, 0xbf, 0xd4, 0xc9, 0x1e, 0xfc, + 0x3a, 0xc5, 0xad, 0x9e, 0xf3, 0xff, 0x37, 0x00, 0x00, 0xff, 0xff, 0x4f, 0xa1, 0x5b, 0x6b, 0x6a, + 0x94, 0x00, 0x00, } r := bytes.NewReader(gzipped) gzipr, err := compress_gzip.NewReader(r) From 300b7393addba8c162cae929db90b083dcf93bd0 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?colin=20axn=C3=A9r?= <25233464+colin-axner@users.noreply.github.com> Date: Tue, 10 Nov 2020 18:05:21 +0100 Subject: [PATCH 18/24] Update IBC host keys + cleanup (#7873) * init changes * cleanup keys and remove redunancdy * revert unintentional changes * KeyChannel -> ChannelKey --- .../transfer/keeper/relay_test.go | 2 +- x/ibc/core/02-client/client/utils/utils.go | 4 +- x/ibc/core/02-client/keeper/grpc_query.go | 2 +- x/ibc/core/02-client/keeper/keeper.go | 18 +- x/ibc/core/02-client/simulation/decoder.go | 4 +- .../core/02-client/simulation/decoder_test.go | 4 +- .../core/03-connection/client/utils/utils.go | 4 +- x/ibc/core/03-connection/keeper/grpc_query.go | 2 +- .../03-connection/keeper/handshake_test.go | 20 +- x/ibc/core/03-connection/keeper/keeper.go | 10 +- .../core/03-connection/keeper/verify_test.go | 12 +- .../core/03-connection/simulation/decoder.go | 4 +- .../03-connection/simulation/decoder_test.go | 4 +- x/ibc/core/04-channel/client/utils/utils.go | 10 +- x/ibc/core/04-channel/keeper/grpc_query.go | 4 +- .../core/04-channel/keeper/handshake_test.go | 8 +- x/ibc/core/04-channel/keeper/keeper.go | 36 ++-- x/ibc/core/04-channel/keeper/packet_test.go | 4 +- x/ibc/core/04-channel/keeper/timeout_test.go | 10 +- x/ibc/core/04-channel/simulation/decoder.go | 2 +- .../04-channel/simulation/decoder_test.go | 12 +- x/ibc/core/24-host/errors.go | 7 +- x/ibc/core/24-host/keys.go | 185 ++++++++++-------- x/ibc/core/24-host/parse.go | 2 +- x/ibc/core/keeper/msg_server_test.go | 32 +-- x/ibc/core/simulation/decoder_test.go | 6 +- x/ibc/core/spec/02_state.md | 14 +- .../06-solomachine/types/client_state.go | 6 +- .../06-solomachine/types/solomachine_test.go | 2 +- .../07-tendermint/types/client_state.go | 4 +- .../07-tendermint/types/client_state_test.go | 12 +- .../07-tendermint/types/store.go | 2 +- .../07-tendermint/types/store_test.go | 4 +- .../09-localhost/types/client_state.go | 16 +- .../09-localhost/types/client_state_test.go | 30 +-- x/ibc/testing/chain.go | 16 +- x/ibc/testing/coordinator.go | 4 +- x/ibc/testing/solomachine.go | 6 +- 38 files changed, 273 insertions(+), 251 deletions(-) diff --git a/x/ibc/applications/transfer/keeper/relay_test.go b/x/ibc/applications/transfer/keeper/relay_test.go index 5bb7993f9..738de9e80 100644 --- a/x/ibc/applications/transfer/keeper/relay_test.go +++ b/x/ibc/applications/transfer/keeper/relay_test.go @@ -109,7 +109,7 @@ func (suite *KeeperTestSuite) TestSendTransfer() { packet := channeltypes.NewPacket(fungibleTokenPacket.GetBytes(), 1, channelB.PortID, channelB.ID, channelA.PortID, channelA.ID, clienttypes.NewHeight(0, 110), 0) // get proof of packet commitment from chainB - packetKey := host.KeyPacketCommitment(packet.GetSourcePort(), packet.GetSourceChannel(), packet.GetSequence()) + packetKey := host.PacketCommitmentKey(packet.GetSourcePort(), packet.GetSourceChannel(), packet.GetSequence()) proof, proofHeight := suite.chainB.QueryProof(packetKey) recvMsg := channeltypes.NewMsgRecvPacket(packet, proof, proofHeight, suite.chainA.SenderAccount.GetAddress()) diff --git a/x/ibc/core/02-client/client/utils/utils.go b/x/ibc/core/02-client/client/utils/utils.go index bcd649ae7..200f6423f 100644 --- a/x/ibc/core/02-client/client/utils/utils.go +++ b/x/ibc/core/02-client/client/utils/utils.go @@ -38,7 +38,7 @@ func QueryClientState( func QueryClientStateABCI( clientCtx client.Context, clientID string, ) (*types.QueryClientStateResponse, error) { - key := host.FullKeyClientPath(clientID, host.KeyClientState()) + key := host.FullClientStateKey(clientID) value, proofBz, proofHeight, err := ibcclient.QueryTendermintProof(clientCtx, key) if err != nil { @@ -91,7 +91,7 @@ func QueryConsensusState( func QueryConsensusStateABCI( clientCtx client.Context, clientID string, height exported.Height, ) (*types.QueryConsensusStateResponse, error) { - key := host.FullKeyClientPath(clientID, host.KeyConsensusState(height)) + key := host.FullConsensusStateKey(clientID, height) value, proofBz, proofHeight, err := ibcclient.QueryTendermintProof(clientCtx, key) if err != nil { diff --git a/x/ibc/core/02-client/keeper/grpc_query.go b/x/ibc/core/02-client/keeper/grpc_query.go index eeb3c10b8..8bb530689 100644 --- a/x/ibc/core/02-client/keeper/grpc_query.go +++ b/x/ibc/core/02-client/keeper/grpc_query.go @@ -152,7 +152,7 @@ func (q Keeper) ConsensusStates(c context.Context, req *types.QueryConsensusStat ctx := sdk.UnwrapSDKContext(c) consensusStates := []types.ConsensusStateWithHeight{} - store := prefix.NewStore(ctx.KVStore(q.storeKey), host.FullKeyClientPath(req.ClientId, []byte(fmt.Sprintf("%s/", host.KeyConsensusStatesPrefix)))) + store := prefix.NewStore(ctx.KVStore(q.storeKey), host.FullClientKey(req.ClientId, []byte(fmt.Sprintf("%s/", host.KeyConsensusStatePrefix)))) pageRes, err := query.Paginate(store, req.Pagination, func(key, value []byte) error { height, err := types.ParseHeight(string(key)) diff --git a/x/ibc/core/02-client/keeper/keeper.go b/x/ibc/core/02-client/keeper/keeper.go index 8af73dd75..7c68499f8 100644 --- a/x/ibc/core/02-client/keeper/keeper.go +++ b/x/ibc/core/02-client/keeper/keeper.go @@ -46,7 +46,7 @@ func (k Keeper) Logger(ctx sdk.Context) log.Logger { // GetClientState gets a particular client from the store func (k Keeper) GetClientState(ctx sdk.Context, clientID string) (exported.ClientState, bool) { store := k.ClientStore(ctx, clientID) - bz := store.Get(host.KeyClientState()) + bz := store.Get(host.ClientStateKey()) if bz == nil { return nil, false } @@ -58,13 +58,13 @@ func (k Keeper) GetClientState(ctx sdk.Context, clientID string) (exported.Clien // SetClientState sets a particular Client to the store func (k Keeper) SetClientState(ctx sdk.Context, clientID string, clientState exported.ClientState) { store := k.ClientStore(ctx, clientID) - store.Set(host.KeyClientState(), k.MustMarshalClientState(clientState)) + store.Set(host.ClientStateKey(), k.MustMarshalClientState(clientState)) } // GetClientConsensusState gets the stored consensus state from a client at a given height. func (k Keeper) GetClientConsensusState(ctx sdk.Context, clientID string, height exported.Height) (exported.ConsensusState, bool) { store := k.ClientStore(ctx, clientID) - bz := store.Get(host.KeyConsensusState(height)) + bz := store.Get(host.ConsensusStateKey(height)) if bz == nil { return nil, false } @@ -77,7 +77,7 @@ func (k Keeper) GetClientConsensusState(ctx sdk.Context, clientID string, height // height func (k Keeper) SetClientConsensusState(ctx sdk.Context, clientID string, height exported.Height, consensusState exported.ConsensusState) { store := k.ClientStore(ctx, clientID) - store.Set(host.KeyConsensusState(height), k.MustMarshalConsensusState(consensusState)) + store.Set(host.ConsensusStateKey(height), k.MustMarshalConsensusState(consensusState)) } // IterateConsensusStates provides an iterator over all stored consensus states. @@ -91,7 +91,7 @@ func (k Keeper) IterateConsensusStates(ctx sdk.Context, cb func(clientID string, for ; iterator.Valid(); iterator.Next() { keySplit := strings.Split(string(iterator.Key()), "/") // consensus key is in the format "clients//consensusStates/" - if len(keySplit) != 4 || keySplit[2] != string(host.KeyConsensusStatesPrefix) { + if len(keySplit) != 4 || keySplit[2] != string(host.KeyConsensusStatePrefix) { continue } clientID := keySplit[1] @@ -144,7 +144,7 @@ func (k Keeper) GetAllConsensusStates(ctx sdk.Context) types.ClientsConsensusSta // client at the given height func (k Keeper) HasClientConsensusState(ctx sdk.Context, clientID string, height exported.Height) bool { store := k.ClientStore(ctx, clientID) - return store.Has(host.KeyConsensusState(height)) + return store.Has(host.ConsensusStateKey(height)) } // GetLatestClientConsensusState gets the latest ConsensusState stored for a given client @@ -266,7 +266,7 @@ func (k Keeper) IterateClients(ctx sdk.Context, cb func(clientID string, cs expo defer iterator.Close() for ; iterator.Valid(); iterator.Next() { keySplit := strings.Split(string(iterator.Key()), "/") - if keySplit[len(keySplit)-1] != "clientState" { + if keySplit[len(keySplit)-1] != host.KeyClientState { continue } clientState := k.MustUnmarshalClientState(iterator.Value()) @@ -291,8 +291,6 @@ func (k Keeper) GetAllClients(ctx sdk.Context) (states []exported.ClientState) { // ClientStore returns isolated prefix store for each client so they can read/write in separate // namespace without being able to read/write other client's data func (k Keeper) ClientStore(ctx sdk.Context, clientID string) sdk.KVStore { - // append here is safe, appends within a function won't cause - // weird side effects when its singlethreaded - clientPrefix := append([]byte("clients/"+clientID), '/') + clientPrefix := []byte(fmt.Sprintf("%s/%s/", host.KeyClientStorePrefix, clientID)) return prefix.NewStore(ctx.KVStore(k.storeKey), clientPrefix) } diff --git a/x/ibc/core/02-client/simulation/decoder.go b/x/ibc/core/02-client/simulation/decoder.go index a5cff11d4..03a803b1b 100644 --- a/x/ibc/core/02-client/simulation/decoder.go +++ b/x/ibc/core/02-client/simulation/decoder.go @@ -22,12 +22,12 @@ type ClientUnmarshaler interface { // Value to the corresponding client type. func NewDecodeStore(cdc ClientUnmarshaler, kvA, kvB kv.Pair) (string, bool) { switch { - case bytes.HasPrefix(kvA.Key, host.KeyClientStorePrefix) && bytes.HasSuffix(kvA.Key, host.KeyClientState()): + case bytes.HasPrefix(kvA.Key, host.KeyClientStorePrefix) && bytes.HasSuffix(kvA.Key, []byte(host.KeyClientState)): clientStateA := cdc.MustUnmarshalClientState(kvA.Value) clientStateB := cdc.MustUnmarshalClientState(kvB.Value) return fmt.Sprintf("ClientState A: %v\nClientState B: %v", clientStateA, clientStateB), true - case bytes.HasPrefix(kvA.Key, host.KeyClientStorePrefix) && bytes.Contains(kvA.Key, []byte("consensusState")): + case bytes.HasPrefix(kvA.Key, host.KeyClientStorePrefix) && bytes.Contains(kvA.Key, []byte(host.KeyConsensusStatePrefix)): consensusStateA := cdc.MustUnmarshalConsensusState(kvA.Value) consensusStateB := cdc.MustUnmarshalConsensusState(kvB.Value) return fmt.Sprintf("ConsensusState A: %v\nConsensusState B: %v", consensusStateA, consensusStateB), true diff --git a/x/ibc/core/02-client/simulation/decoder_test.go b/x/ibc/core/02-client/simulation/decoder_test.go index 6ee442eab..095834ba0 100644 --- a/x/ibc/core/02-client/simulation/decoder_test.go +++ b/x/ibc/core/02-client/simulation/decoder_test.go @@ -32,11 +32,11 @@ func TestDecodeStore(t *testing.T) { kvPairs := kv.Pairs{ Pairs: []kv.Pair{ { - Key: host.FullKeyClientPath(clientID, host.KeyClientState()), + Key: host.FullClientStateKey(clientID), Value: app.IBCKeeper.ClientKeeper.MustMarshalClientState(clientState), }, { - Key: host.FullKeyClientPath(clientID, host.KeyConsensusState(height)), + Key: host.FullConsensusStateKey(clientID, height), Value: app.IBCKeeper.ClientKeeper.MustMarshalConsensusState(consState), }, { diff --git a/x/ibc/core/03-connection/client/utils/utils.go b/x/ibc/core/03-connection/client/utils/utils.go index 955ecfe6b..44283aef8 100644 --- a/x/ibc/core/03-connection/client/utils/utils.go +++ b/x/ibc/core/03-connection/client/utils/utils.go @@ -38,7 +38,7 @@ func QueryConnection( } func queryConnectionABCI(clientCtx client.Context, connectionID string) (*types.QueryConnectionResponse, error) { - key := host.KeyConnection(connectionID) + key := host.ConnectionKey(connectionID) value, proofBz, proofHeight, err := ibcclient.QueryTendermintProof(clientCtx, key) if err != nil { @@ -79,7 +79,7 @@ func QueryClientConnections( } func queryClientConnectionsABCI(clientCtx client.Context, clientID string) (*types.QueryClientConnectionsResponse, error) { - key := host.KeyClientConnections(clientID) + key := host.ClientConnectionsKey(clientID) value, proofBz, proofHeight, err := ibcclient.QueryTendermintProof(clientCtx, key) if err != nil { diff --git a/x/ibc/core/03-connection/keeper/grpc_query.go b/x/ibc/core/03-connection/keeper/grpc_query.go index 1c644e3da..5b34d1e4e 100644 --- a/x/ibc/core/03-connection/keeper/grpc_query.go +++ b/x/ibc/core/03-connection/keeper/grpc_query.go @@ -51,7 +51,7 @@ func (q Keeper) Connections(c context.Context, req *types.QueryConnectionsReques ctx := sdk.UnwrapSDKContext(c) connections := []*types.IdentifiedConnection{} - store := prefix.NewStore(ctx.KVStore(q.storeKey), host.KeyConnectionPrefix) + store := prefix.NewStore(ctx.KVStore(q.storeKey), []byte(host.KeyConnectionPrefix)) pageRes, err := query.Paginate(store, req.Pagination, func(key, value []byte) error { var result types.ConnectionEnd diff --git a/x/ibc/core/03-connection/keeper/handshake_test.go b/x/ibc/core/03-connection/keeper/handshake_test.go index b677b2352..903781086 100644 --- a/x/ibc/core/03-connection/keeper/handshake_test.go +++ b/x/ibc/core/03-connection/keeper/handshake_test.go @@ -306,18 +306,18 @@ func (suite *KeeperTestSuite) TestConnOpenTry() { counterpartyChosenConnectionID = connection.Counterparty.ConnectionId } - connectionKey := host.KeyConnection(connA.ID) + connectionKey := host.ConnectionKey(connA.ID) proofInit, proofHeight := suite.chainA.QueryProof(connectionKey) if consensusHeight.IsZero() { // retrieve consensus state height to provide proof for consensusHeight = counterpartyClient.GetLatestHeight() } - consensusKey := host.FullKeyClientPath(clientA, host.KeyConsensusState(consensusHeight)) + consensusKey := host.FullConsensusStateKey(clientA, consensusHeight) proofConsensus, _ := suite.chainA.QueryProof(consensusKey) // retrieve proof of counterparty clientstate on chainA - clientKey := host.FullKeyClientPath(clientA, host.KeyClientState()) + clientKey := host.FullClientStateKey(clientA) proofClient, _ := suite.chainA.QueryProof(clientKey) err := suite.chainB.App.IBCKeeper.ConnectionKeeper.ConnOpenTry( @@ -661,10 +661,10 @@ func (suite *KeeperTestSuite) TestConnOpenAck() { for _, tc := range testCases { tc := tc suite.Run(tc.msg, func() { - suite.SetupTest() // reset + suite.SetupTest() // reset version = types.ExportedVersionsToProto(types.GetCompatibleVersions())[0] // must be explicitly changed in malleate - consensusHeight = clienttypes.ZeroHeight() // must be explicitly changed in malleate - counterpartyConnectionID = "" // must be explicitly changed in malleate + consensusHeight = clienttypes.ZeroHeight() // must be explicitly changed in malleate + counterpartyConnectionID = "" // must be explicitly changed in malleate tc.malleate() @@ -675,7 +675,7 @@ func (suite *KeeperTestSuite) TestConnOpenAck() { counterpartyConnectionID = connB.ID } - connectionKey := host.KeyConnection(connB.ID) + connectionKey := host.ConnectionKey(connB.ID) proofTry, proofHeight := suite.chainB.QueryProof(connectionKey) if consensusHeight.IsZero() { @@ -683,11 +683,11 @@ func (suite *KeeperTestSuite) TestConnOpenAck() { clientState := suite.chainB.GetClientState(clientB) consensusHeight = clientState.GetLatestHeight() } - consensusKey := host.FullKeyClientPath(clientB, host.KeyConsensusState(consensusHeight)) + consensusKey := host.FullConsensusStateKey(clientB, consensusHeight) proofConsensus, _ := suite.chainB.QueryProof(consensusKey) // retrieve proof of counterparty clientstate on chainA - clientKey := host.FullKeyClientPath(clientB, host.KeyClientState()) + clientKey := host.FullClientStateKey(clientB) proofClient, _ := suite.chainB.QueryProof(clientKey) err := suite.chainA.App.IBCKeeper.ConnectionKeeper.ConnOpenAck( @@ -757,7 +757,7 @@ func (suite *KeeperTestSuite) TestConnOpenConfirm() { connA := suite.chainA.GetFirstTestConnection(clientA, clientB) connB := suite.chainB.GetFirstTestConnection(clientB, clientA) - connectionKey := host.KeyConnection(connA.ID) + connectionKey := host.ConnectionKey(connA.ID) proofAck, proofHeight := suite.chainA.QueryProof(connectionKey) err := suite.chainB.App.IBCKeeper.ConnectionKeeper.ConnOpenConfirm( diff --git a/x/ibc/core/03-connection/keeper/keeper.go b/x/ibc/core/03-connection/keeper/keeper.go index c838b4fa6..dda529587 100644 --- a/x/ibc/core/03-connection/keeper/keeper.go +++ b/x/ibc/core/03-connection/keeper/keeper.go @@ -48,7 +48,7 @@ func (k Keeper) GetCommitmentPrefix() exported.Prefix { // GetConnection returns a connection with a particular identifier func (k Keeper) GetConnection(ctx sdk.Context, connectionID string) (types.ConnectionEnd, bool) { store := ctx.KVStore(k.storeKey) - bz := store.Get(host.KeyConnection(connectionID)) + bz := store.Get(host.ConnectionKey(connectionID)) if bz == nil { return types.ConnectionEnd{}, false } @@ -63,7 +63,7 @@ func (k Keeper) GetConnection(ctx sdk.Context, connectionID string) (types.Conne func (k Keeper) SetConnection(ctx sdk.Context, connectionID string, connection types.ConnectionEnd) { store := ctx.KVStore(k.storeKey) bz := k.cdc.MustMarshalBinaryBare(&connection) - store.Set(host.KeyConnection(connectionID), bz) + store.Set(host.ConnectionKey(connectionID), bz) } // GetTimestampAtHeight returns the timestamp in nanoseconds of the consensus state at the @@ -87,7 +87,7 @@ func (k Keeper) GetTimestampAtHeight(ctx sdk.Context, connection types.Connectio // particular client func (k Keeper) GetClientConnectionPaths(ctx sdk.Context, clientID string) ([]string, bool) { store := ctx.KVStore(k.storeKey) - bz := store.Get(host.KeyClientConnections(clientID)) + bz := store.Get(host.ClientConnectionsKey(clientID)) if bz == nil { return nil, false } @@ -102,7 +102,7 @@ func (k Keeper) SetClientConnectionPaths(ctx sdk.Context, clientID string, paths store := ctx.KVStore(k.storeKey) clientPaths := types.ClientPaths{Paths: paths} bz := k.cdc.MustMarshalBinaryBare(&clientPaths) - store.Set(host.KeyClientConnections(clientID), bz) + store.Set(host.ClientConnectionsKey(clientID), bz) } // GetAllClientConnectionPaths returns all stored clients connection id paths. It @@ -129,7 +129,7 @@ func (k Keeper) GetAllClientConnectionPaths(ctx sdk.Context) []types.ConnectionP // iterator will close and stop. func (k Keeper) IterateConnections(ctx sdk.Context, cb func(types.IdentifiedConnection) bool) { store := ctx.KVStore(k.storeKey) - iterator := sdk.KVStorePrefixIterator(store, host.KeyConnectionPrefix) + iterator := sdk.KVStorePrefixIterator(store, []byte(host.KeyConnectionPrefix)) defer iterator.Close() for ; iterator.Valid(); iterator.Next() { diff --git a/x/ibc/core/03-connection/keeper/verify_test.go b/x/ibc/core/03-connection/keeper/verify_test.go index 7f9705a80..c9db5cc2b 100644 --- a/x/ibc/core/03-connection/keeper/verify_test.go +++ b/x/ibc/core/03-connection/keeper/verify_test.go @@ -178,7 +178,7 @@ func (suite *KeeperTestSuite) TestVerifyConnectionState() { } expectedConnection := suite.chainB.GetConnection(connB) - connectionKey := host.KeyConnection(connB.ID) + connectionKey := host.ConnectionKey(connB.ID) proof, proofHeight := suite.chainB.QueryProof(connectionKey) if tc.changeConnectionState { @@ -227,7 +227,7 @@ func (suite *KeeperTestSuite) TestVerifyChannelState() { connection.ClientId = ibctesting.InvalidID } - channelKey := host.KeyChannel(channelB.PortID, channelB.ID) + channelKey := host.ChannelKey(channelB.PortID, channelB.ID) proof, proofHeight := suite.chainB.QueryProof(channelKey) channel := suite.chainB.GetChannel(channelB) @@ -282,7 +282,7 @@ func (suite *KeeperTestSuite) TestVerifyPacketCommitment() { err := suite.coordinator.SendPacket(suite.chainA, suite.chainB, packet, clientB) suite.Require().NoError(err) - commitmentKey := host.KeyPacketCommitment(packet.GetSourcePort(), packet.GetSourceChannel(), packet.GetSequence()) + commitmentKey := host.PacketCommitmentKey(packet.GetSourcePort(), packet.GetSourceChannel(), packet.GetSequence()) proof, proofHeight := suite.chainA.QueryProof(commitmentKey) if tc.changePacketCommitmentState { @@ -340,7 +340,7 @@ func (suite *KeeperTestSuite) TestVerifyPacketAcknowledgement() { err = suite.coordinator.RecvPacket(suite.chainA, suite.chainB, clientA, packet) suite.Require().NoError(err) - packetAckKey := host.KeyPacketAcknowledgement(packet.GetDestPort(), packet.GetDestChannel(), packet.GetSequence()) + packetAckKey := host.PacketAcknowledgementKey(packet.GetDestPort(), packet.GetDestChannel(), packet.GetSequence()) proof, proofHeight := suite.chainB.QueryProof(packetAckKey) ack := ibcmock.MockAcknowledgement @@ -405,7 +405,7 @@ func (suite *KeeperTestSuite) TestVerifyPacketReceiptAbsence() { suite.coordinator.UpdateClient(suite.chainA, suite.chainB, clientA, ibctesting.Tendermint) } - packetReceiptKey := host.KeyPacketReceipt(packet.GetDestPort(), packet.GetDestChannel(), packet.GetSequence()) + packetReceiptKey := host.PacketReceiptKey(packet.GetDestPort(), packet.GetDestChannel(), packet.GetSequence()) proof, proofHeight := suite.chainB.QueryProof(packetReceiptKey) err = suite.chainA.App.IBCKeeper.ConnectionKeeper.VerifyPacketReceiptAbsence( @@ -459,7 +459,7 @@ func (suite *KeeperTestSuite) TestVerifyNextSequenceRecv() { err = suite.coordinator.RecvPacket(suite.chainA, suite.chainB, clientA, packet) suite.Require().NoError(err) - nextSeqRecvKey := host.KeyNextSequenceRecv(packet.GetDestPort(), packet.GetDestChannel()) + nextSeqRecvKey := host.NextSequenceRecvKey(packet.GetDestPort(), packet.GetDestChannel()) proof, proofHeight := suite.chainB.QueryProof(nextSeqRecvKey) err = suite.chainA.App.IBCKeeper.ConnectionKeeper.VerifyNextSequenceRecv( diff --git a/x/ibc/core/03-connection/simulation/decoder.go b/x/ibc/core/03-connection/simulation/decoder.go index 4b2d3bdf8..ef988a103 100644 --- a/x/ibc/core/03-connection/simulation/decoder.go +++ b/x/ibc/core/03-connection/simulation/decoder.go @@ -14,13 +14,13 @@ import ( // Value to the corresponding connection type. func NewDecodeStore(cdc codec.BinaryMarshaler, kvA, kvB kv.Pair) (string, bool) { switch { - case bytes.HasPrefix(kvA.Key, host.KeyClientStorePrefix) && bytes.HasSuffix(kvA.Key, host.KeyConnectionPrefix): + case bytes.HasPrefix(kvA.Key, host.KeyClientStorePrefix) && bytes.HasSuffix(kvA.Key, []byte(host.KeyConnectionPrefix)): var clientConnectionsA, clientConnectionsB types.ClientPaths cdc.MustUnmarshalBinaryBare(kvA.Value, &clientConnectionsA) cdc.MustUnmarshalBinaryBare(kvB.Value, &clientConnectionsB) return fmt.Sprintf("ClientPaths A: %v\nClientPaths B: %v", clientConnectionsA, clientConnectionsB), true - case bytes.HasPrefix(kvA.Key, host.KeyConnectionPrefix): + case bytes.HasPrefix(kvA.Key, []byte(host.KeyConnectionPrefix)): var connectionA, connectionB types.ConnectionEnd cdc.MustUnmarshalBinaryBare(kvA.Value, &connectionA) cdc.MustUnmarshalBinaryBare(kvB.Value, &connectionB) diff --git a/x/ibc/core/03-connection/simulation/decoder_test.go b/x/ibc/core/03-connection/simulation/decoder_test.go index 7e36b05a7..673bf6400 100644 --- a/x/ibc/core/03-connection/simulation/decoder_test.go +++ b/x/ibc/core/03-connection/simulation/decoder_test.go @@ -31,11 +31,11 @@ func TestDecodeStore(t *testing.T) { kvPairs := kv.Pairs{ Pairs: []kv.Pair{ { - Key: host.KeyClientConnections(connection.ClientId), + Key: host.ClientConnectionsKey(connection.ClientId), Value: cdc.MustMarshalBinaryBare(&paths), }, { - Key: host.KeyConnection(connectionID), + Key: host.ConnectionKey(connectionID), Value: cdc.MustMarshalBinaryBare(&connection), }, { diff --git a/x/ibc/core/04-channel/client/utils/utils.go b/x/ibc/core/04-channel/client/utils/utils.go index a5cae383b..f28ffcf80 100644 --- a/x/ibc/core/04-channel/client/utils/utils.go +++ b/x/ibc/core/04-channel/client/utils/utils.go @@ -35,7 +35,7 @@ func QueryChannel( } func queryChannelABCI(clientCtx client.Context, portID, channelID string) (*types.QueryChannelResponse, error) { - key := host.KeyChannel(portID, channelID) + key := host.ChannelKey(portID, channelID) value, proofBz, proofHeight, err := ibcclient.QueryTendermintProof(clientCtx, key) if err != nil { @@ -176,7 +176,7 @@ func QueryNextSequenceReceive( } func queryNextSequenceRecvABCI(clientCtx client.Context, portID, channelID string) (*types.QueryNextSequenceReceiveResponse, error) { - key := host.KeyNextSequenceRecv(portID, channelID) + key := host.NextSequenceRecvKey(portID, channelID) value, proofBz, proofHeight, err := ibcclient.QueryTendermintProof(clientCtx, key) if err != nil { @@ -217,7 +217,7 @@ func QueryPacketCommitment( func queryPacketCommitmentABCI( clientCtx client.Context, portID, channelID string, sequence uint64, ) (*types.QueryPacketCommitmentResponse, error) { - key := host.KeyPacketCommitment(portID, channelID, sequence) + key := host.PacketCommitmentKey(portID, channelID, sequence) value, proofBz, proofHeight, err := ibcclient.QueryTendermintProof(clientCtx, key) if err != nil { @@ -256,7 +256,7 @@ func QueryPacketReceipt( func queryPacketReceiptABCI( clientCtx client.Context, portID, channelID string, sequence uint64, ) (*types.QueryPacketReceiptResponse, error) { - key := host.KeyPacketReceipt(portID, channelID, sequence) + key := host.PacketReceiptKey(portID, channelID, sequence) value, proofBz, proofHeight, err := ibcclient.QueryTendermintProof(clientCtx, key) if err != nil { @@ -285,7 +285,7 @@ func QueryPacketAcknowledgement(clientCtx client.Context, portID, channelID stri } func queryPacketAcknowledgementABCI(clientCtx client.Context, portID, channelID string, sequence uint64) (*types.QueryPacketAcknowledgementResponse, error) { - key := host.KeyPacketAcknowledgement(portID, channelID, sequence) + key := host.PacketAcknowledgementKey(portID, channelID, sequence) value, proofBz, proofHeight, err := ibcclient.QueryTendermintProof(clientCtx, key) if err != nil { diff --git a/x/ibc/core/04-channel/keeper/grpc_query.go b/x/ibc/core/04-channel/keeper/grpc_query.go index 5e279ee43..355f192d7 100644 --- a/x/ibc/core/04-channel/keeper/grpc_query.go +++ b/x/ibc/core/04-channel/keeper/grpc_query.go @@ -52,7 +52,7 @@ func (q Keeper) Channels(c context.Context, req *types.QueryChannelsRequest) (*t ctx := sdk.UnwrapSDKContext(c) channels := []*types.IdentifiedChannel{} - store := prefix.NewStore(ctx.KVStore(q.storeKey), []byte(host.KeyChannelPrefix)) + store := prefix.NewStore(ctx.KVStore(q.storeKey), []byte(host.KeyChannelEndPrefix)) pageRes, err := query.Paginate(store, req.Pagination, func(key, value []byte) error { var result types.Channel @@ -95,7 +95,7 @@ func (q Keeper) ConnectionChannels(c context.Context, req *types.QueryConnection ctx := sdk.UnwrapSDKContext(c) channels := []*types.IdentifiedChannel{} - store := prefix.NewStore(ctx.KVStore(q.storeKey), []byte(host.KeyChannelPrefix)) + store := prefix.NewStore(ctx.KVStore(q.storeKey), []byte(host.KeyChannelEndPrefix)) pageRes, err := query.Paginate(store, req.Pagination, func(key, value []byte) error { var result types.Channel diff --git a/x/ibc/core/04-channel/keeper/handshake_test.go b/x/ibc/core/04-channel/keeper/handshake_test.go index fe5dc3593..cf391d038 100644 --- a/x/ibc/core/04-channel/keeper/handshake_test.go +++ b/x/ibc/core/04-channel/keeper/handshake_test.go @@ -289,7 +289,7 @@ func (suite *KeeperTestSuite) TestChanOpenTry() { counterpartyChosenChannelID = channel.Counterparty.ChannelId } - channelKey := host.KeyChannel(counterparty.PortId, counterparty.ChannelId) + channelKey := host.ChannelKey(counterparty.PortId, counterparty.ChannelId) proof, proofHeight := suite.chainA.QueryProof(channelKey) cap, err := suite.chainB.App.IBCKeeper.ChannelKeeper.ChanOpenTry( @@ -455,7 +455,7 @@ func (suite *KeeperTestSuite) TestChanOpenAck() { counterpartyChannelID = channelB.ID } - channelKey := host.KeyChannel(channelB.PortID, channelB.ID) + channelKey := host.ChannelKey(channelB.PortID, channelB.ID) proof, proofHeight := suite.chainB.QueryProof(channelKey) err := suite.chainA.App.IBCKeeper.ChannelKeeper.ChanOpenAck( @@ -583,7 +583,7 @@ func (suite *KeeperTestSuite) TestChanOpenConfirm() { channelA := connA.FirstOrNextTestChannel(ibctesting.MockPort) channelB := connB.FirstOrNextTestChannel(ibctesting.MockPort) - channelKey := host.KeyChannel(channelA.PortID, channelA.ID) + channelKey := host.ChannelKey(channelA.PortID, channelA.ID) proof, proofHeight := suite.chainA.QueryProof(channelKey) err := suite.chainB.App.IBCKeeper.ChannelKeeper.ChanOpenConfirm( @@ -784,7 +784,7 @@ func (suite *KeeperTestSuite) TestChanCloseConfirm() { channelA = connA.FirstOrNextTestChannel(ibctesting.MockPort) channelB = connB.FirstOrNextTestChannel(ibctesting.MockPort) - channelKey := host.KeyChannel(channelA.PortID, channelA.ID) + channelKey := host.ChannelKey(channelA.PortID, channelA.ID) proof, proofHeight := suite.chainA.QueryProof(channelKey) err := suite.chainB.App.IBCKeeper.ChannelKeeper.ChanCloseConfirm( diff --git a/x/ibc/core/04-channel/keeper/keeper.go b/x/ibc/core/04-channel/keeper/keeper.go index b3f23ca7f..99aee2c6d 100644 --- a/x/ibc/core/04-channel/keeper/keeper.go +++ b/x/ibc/core/04-channel/keeper/keeper.go @@ -58,7 +58,7 @@ func (k Keeper) Logger(ctx sdk.Context) log.Logger { // GetChannel returns a channel with a particular identifier binded to a specific port func (k Keeper) GetChannel(ctx sdk.Context, portID, channelID string) (types.Channel, bool) { store := ctx.KVStore(k.storeKey) - bz := store.Get(host.KeyChannel(portID, channelID)) + bz := store.Get(host.ChannelKey(portID, channelID)) if bz == nil { return types.Channel{}, false } @@ -72,13 +72,13 @@ func (k Keeper) GetChannel(ctx sdk.Context, portID, channelID string) (types.Cha func (k Keeper) SetChannel(ctx sdk.Context, portID, channelID string, channel types.Channel) { store := ctx.KVStore(k.storeKey) bz := k.cdc.MustMarshalBinaryBare(&channel) - store.Set(host.KeyChannel(portID, channelID), bz) + store.Set(host.ChannelKey(portID, channelID), bz) } // GetNextSequenceSend gets a channel's next send sequence from the store func (k Keeper) GetNextSequenceSend(ctx sdk.Context, portID, channelID string) (uint64, bool) { store := ctx.KVStore(k.storeKey) - bz := store.Get(host.KeyNextSequenceSend(portID, channelID)) + bz := store.Get(host.NextSequenceSendKey(portID, channelID)) if bz == nil { return 0, false } @@ -90,13 +90,13 @@ func (k Keeper) GetNextSequenceSend(ctx sdk.Context, portID, channelID string) ( func (k Keeper) SetNextSequenceSend(ctx sdk.Context, portID, channelID string, sequence uint64) { store := ctx.KVStore(k.storeKey) bz := sdk.Uint64ToBigEndian(sequence) - store.Set(host.KeyNextSequenceSend(portID, channelID), bz) + store.Set(host.NextSequenceSendKey(portID, channelID), bz) } // GetNextSequenceRecv gets a channel's next receive sequence from the store func (k Keeper) GetNextSequenceRecv(ctx sdk.Context, portID, channelID string) (uint64, bool) { store := ctx.KVStore(k.storeKey) - bz := store.Get(host.KeyNextSequenceRecv(portID, channelID)) + bz := store.Get(host.NextSequenceRecvKey(portID, channelID)) if bz == nil { return 0, false } @@ -108,13 +108,13 @@ func (k Keeper) GetNextSequenceRecv(ctx sdk.Context, portID, channelID string) ( func (k Keeper) SetNextSequenceRecv(ctx sdk.Context, portID, channelID string, sequence uint64) { store := ctx.KVStore(k.storeKey) bz := sdk.Uint64ToBigEndian(sequence) - store.Set(host.KeyNextSequenceRecv(portID, channelID), bz) + store.Set(host.NextSequenceRecvKey(portID, channelID), bz) } // GetNextSequenceAck gets a channel's next ack sequence from the store func (k Keeper) GetNextSequenceAck(ctx sdk.Context, portID, channelID string) (uint64, bool) { store := ctx.KVStore(k.storeKey) - bz := store.Get(host.KeyNextSequenceAck(portID, channelID)) + bz := store.Get(host.NextSequenceAckKey(portID, channelID)) if bz == nil { return 0, false } @@ -126,13 +126,13 @@ func (k Keeper) GetNextSequenceAck(ctx sdk.Context, portID, channelID string) (u func (k Keeper) SetNextSequenceAck(ctx sdk.Context, portID, channelID string, sequence uint64) { store := ctx.KVStore(k.storeKey) bz := sdk.Uint64ToBigEndian(sequence) - store.Set(host.KeyNextSequenceAck(portID, channelID), bz) + store.Set(host.NextSequenceAckKey(portID, channelID), bz) } // GetPacketReceipt gets a packet receipt from the store func (k Keeper) GetPacketReceipt(ctx sdk.Context, portID, channelID string, sequence uint64) (string, bool) { store := ctx.KVStore(k.storeKey) - bz := store.Get(host.KeyPacketReceipt(portID, channelID, sequence)) + bz := store.Get(host.PacketReceiptKey(portID, channelID, sequence)) if bz == nil { return "", false } @@ -143,43 +143,43 @@ func (k Keeper) GetPacketReceipt(ctx sdk.Context, portID, channelID string, sequ // SetPacketReceipt sets an empty packet receipt to the store func (k Keeper) SetPacketReceipt(ctx sdk.Context, portID, channelID string, sequence uint64) { store := ctx.KVStore(k.storeKey) - store.Set(host.KeyPacketReceipt(portID, channelID, sequence), []byte("")) + store.Set(host.PacketReceiptKey(portID, channelID, sequence), []byte("")) } // GetPacketCommitment gets the packet commitment hash from the store func (k Keeper) GetPacketCommitment(ctx sdk.Context, portID, channelID string, sequence uint64) []byte { store := ctx.KVStore(k.storeKey) - bz := store.Get(host.KeyPacketCommitment(portID, channelID, sequence)) + bz := store.Get(host.PacketCommitmentKey(portID, channelID, sequence)) return bz } // HasPacketCommitment returns true if the packet commitment exists func (k Keeper) HasPacketCommitment(ctx sdk.Context, portID, channelID string, sequence uint64) bool { store := ctx.KVStore(k.storeKey) - return store.Has(host.KeyPacketCommitment(portID, channelID, sequence)) + return store.Has(host.PacketCommitmentKey(portID, channelID, sequence)) } // SetPacketCommitment sets the packet commitment hash to the store func (k Keeper) SetPacketCommitment(ctx sdk.Context, portID, channelID string, sequence uint64, commitmentHash []byte) { store := ctx.KVStore(k.storeKey) - store.Set(host.KeyPacketCommitment(portID, channelID, sequence), commitmentHash) + store.Set(host.PacketCommitmentKey(portID, channelID, sequence), commitmentHash) } func (k Keeper) deletePacketCommitment(ctx sdk.Context, portID, channelID string, sequence uint64) { store := ctx.KVStore(k.storeKey) - store.Delete(host.KeyPacketCommitment(portID, channelID, sequence)) + store.Delete(host.PacketCommitmentKey(portID, channelID, sequence)) } // SetPacketAcknowledgement sets the packet ack hash to the store func (k Keeper) SetPacketAcknowledgement(ctx sdk.Context, portID, channelID string, sequence uint64, ackHash []byte) { store := ctx.KVStore(k.storeKey) - store.Set(host.KeyPacketAcknowledgement(portID, channelID, sequence), ackHash) + store.Set(host.PacketAcknowledgementKey(portID, channelID, sequence), ackHash) } // GetPacketAcknowledgement gets the packet ack hash from the store func (k Keeper) GetPacketAcknowledgement(ctx sdk.Context, portID, channelID string, sequence uint64) ([]byte, bool) { store := ctx.KVStore(k.storeKey) - bz := store.Get(host.KeyPacketAcknowledgement(portID, channelID, sequence)) + bz := store.Get(host.PacketAcknowledgementKey(portID, channelID, sequence)) if bz == nil { return nil, false } @@ -189,7 +189,7 @@ func (k Keeper) GetPacketAcknowledgement(ctx sdk.Context, portID, channelID stri // HasPacketAcknowledgement check if the packet ack hash is already on the store func (k Keeper) HasPacketAcknowledgement(ctx sdk.Context, portID, channelID string, sequence uint64) bool { store := ctx.KVStore(k.storeKey) - return store.Has(host.KeyPacketAcknowledgement(portID, channelID, sequence)) + return store.Has(host.PacketAcknowledgementKey(portID, channelID, sequence)) } // IteratePacketSequence provides an iterator over all send, receive or ack sequences. @@ -330,7 +330,7 @@ func (k Keeper) GetAllPacketAcks(ctx sdk.Context) (acks []types.PacketState) { // and stop. func (k Keeper) IterateChannels(ctx sdk.Context, cb func(types.IdentifiedChannel) bool) { store := ctx.KVStore(k.storeKey) - iterator := sdk.KVStorePrefixIterator(store, []byte(host.KeyChannelPrefix)) + iterator := sdk.KVStorePrefixIterator(store, []byte(host.KeyChannelEndPrefix)) defer iterator.Close() for ; iterator.Valid(); iterator.Next() { diff --git a/x/ibc/core/04-channel/keeper/packet_test.go b/x/ibc/core/04-channel/keeper/packet_test.go index 3d942ce12..f3624897d 100644 --- a/x/ibc/core/04-channel/keeper/packet_test.go +++ b/x/ibc/core/04-channel/keeper/packet_test.go @@ -345,7 +345,7 @@ func (suite *KeeperTestSuite) TestRecvPacket() { tc.malleate() // get proof of packet commitment from chainA - packetKey := host.KeyPacketCommitment(packet.GetSourcePort(), packet.GetSourceChannel(), packet.GetSequence()) + packetKey := host.PacketCommitmentKey(packet.GetSourcePort(), packet.GetSourceChannel(), packet.GetSequence()) proof, proofHeight := suite.chainA.QueryProof(packetKey) err := suite.chainB.App.IBCKeeper.ChannelKeeper.RecvPacket(suite.chainB.GetContext(), channelCap, packet, proof, proofHeight) @@ -622,7 +622,7 @@ func (suite *KeeperTestSuite) TestAcknowledgePacket() { suite.SetupTest() // reset tc.malleate() - packetKey := host.KeyPacketAcknowledgement(packet.GetDestPort(), packet.GetDestChannel(), packet.GetSequence()) + packetKey := host.PacketAcknowledgementKey(packet.GetDestPort(), packet.GetDestChannel(), packet.GetSequence()) proof, proofHeight := suite.chainB.QueryProof(packetKey) err := suite.chainA.App.IBCKeeper.ChannelKeeper.AcknowledgePacket(suite.chainA.GetContext(), channelCap, packet, ack, proof, proofHeight) diff --git a/x/ibc/core/04-channel/keeper/timeout_test.go b/x/ibc/core/04-channel/keeper/timeout_test.go index 774f9eacf..2ff497582 100644 --- a/x/ibc/core/04-channel/keeper/timeout_test.go +++ b/x/ibc/core/04-channel/keeper/timeout_test.go @@ -125,8 +125,8 @@ func (suite *KeeperTestSuite) TestTimeoutPacket() { nextSeqRecv = 1 // must be explicitly changed tc.malleate() - orderedPacketKey := host.KeyNextSequenceRecv(packet.GetDestPort(), packet.GetDestChannel()) - unorderedPacketKey := host.KeyPacketReceipt(packet.GetDestPort(), packet.GetDestChannel(), packet.GetSequence()) + orderedPacketKey := host.NextSequenceRecvKey(packet.GetDestPort(), packet.GetDestChannel()) + unorderedPacketKey := host.PacketReceiptKey(packet.GetDestPort(), packet.GetDestChannel(), packet.GetSequence()) if ordered { proof, proofHeight = suite.chainB.QueryProof(orderedPacketKey) @@ -326,9 +326,9 @@ func (suite *KeeperTestSuite) TestTimeoutOnClose() { nextSeqRecv = 1 // must be explicitly changed tc.malleate() - channelKey := host.KeyChannel(packet.GetDestPort(), packet.GetDestChannel()) - unorderedPacketKey := host.KeyPacketReceipt(packet.GetDestPort(), packet.GetDestChannel(), packet.GetSequence()) - orderedPacketKey := host.KeyNextSequenceRecv(packet.GetDestPort(), packet.GetDestChannel()) + channelKey := host.ChannelKey(packet.GetDestPort(), packet.GetDestChannel()) + unorderedPacketKey := host.PacketReceiptKey(packet.GetDestPort(), packet.GetDestChannel(), packet.GetSequence()) + orderedPacketKey := host.NextSequenceRecvKey(packet.GetDestPort(), packet.GetDestChannel()) proofClosed, proofHeight := suite.chainB.QueryProof(channelKey) diff --git a/x/ibc/core/04-channel/simulation/decoder.go b/x/ibc/core/04-channel/simulation/decoder.go index 006bc08e9..809976cc0 100644 --- a/x/ibc/core/04-channel/simulation/decoder.go +++ b/x/ibc/core/04-channel/simulation/decoder.go @@ -15,7 +15,7 @@ import ( // Value to the corresponding channel type. func NewDecodeStore(cdc codec.BinaryMarshaler, kvA, kvB kv.Pair) (string, bool) { switch { - case bytes.HasPrefix(kvA.Key, []byte(host.KeyChannelPrefix)): + case bytes.HasPrefix(kvA.Key, []byte(host.KeyChannelEndPrefix)): var channelA, channelB types.Channel cdc.MustUnmarshalBinaryBare(kvA.Value, &channelA) cdc.MustUnmarshalBinaryBare(kvB.Value, &channelB) diff --git a/x/ibc/core/04-channel/simulation/decoder_test.go b/x/ibc/core/04-channel/simulation/decoder_test.go index 2d61a8f9a..5f2ba2f5e 100644 --- a/x/ibc/core/04-channel/simulation/decoder_test.go +++ b/x/ibc/core/04-channel/simulation/decoder_test.go @@ -31,27 +31,27 @@ func TestDecodeStore(t *testing.T) { kvPairs := kv.Pairs{ Pairs: []kv.Pair{ { - Key: host.KeyChannel(portID, channelID), + Key: host.ChannelKey(portID, channelID), Value: cdc.MustMarshalBinaryBare(&channel), }, { - Key: host.KeyNextSequenceSend(portID, channelID), + Key: host.NextSequenceSendKey(portID, channelID), Value: sdk.Uint64ToBigEndian(1), }, { - Key: host.KeyNextSequenceRecv(portID, channelID), + Key: host.NextSequenceRecvKey(portID, channelID), Value: sdk.Uint64ToBigEndian(1), }, { - Key: host.KeyNextSequenceAck(portID, channelID), + Key: host.NextSequenceAckKey(portID, channelID), Value: sdk.Uint64ToBigEndian(1), }, { - Key: host.KeyPacketCommitment(portID, channelID, 1), + Key: host.PacketCommitmentKey(portID, channelID, 1), Value: bz, }, { - Key: host.KeyPacketAcknowledgement(portID, channelID, 1), + Key: host.PacketAcknowledgementKey(portID, channelID, 1), Value: bz, }, { diff --git a/x/ibc/core/24-host/errors.go b/x/ibc/core/24-host/errors.go index 3ec901625..fe8129bde 100644 --- a/x/ibc/core/24-host/errors.go +++ b/x/ibc/core/24-host/errors.go @@ -9,8 +9,7 @@ const SubModuleName = "host" // IBC client sentinel errors var ( - ErrInvalidID = sdkerrors.Register(SubModuleName, 2, "invalid identifier") - ErrInvalidPath = sdkerrors.Register(SubModuleName, 3, "invalid path") - ErrInvalidPacket = sdkerrors.Register(SubModuleName, 4, "invalid packet") - ErrInvalidVersion = sdkerrors.Register(SubModuleName, 5, "invalid version") + ErrInvalidID = sdkerrors.Register(SubModuleName, 2, "invalid identifier") + ErrInvalidPath = sdkerrors.Register(SubModuleName, 3, "invalid path") + ErrInvalidPacket = sdkerrors.Register(SubModuleName, 4, "invalid packet") ) diff --git a/x/ibc/core/24-host/keys.go b/x/ibc/core/24-host/keys.go index 3a51a13db..51d293957 100644 --- a/x/ibc/core/24-host/keys.go +++ b/x/ibc/core/24-host/keys.go @@ -22,14 +22,18 @@ const ( // KVStore key prefixes for IBC var ( - KeyClientStorePrefix = []byte("clients") - KeyConsensusStatesPrefix = []byte("consensusStates") - KeyConnectionPrefix = []byte("connections") + KeyClientStorePrefix = []byte("clients") ) // KVStore key prefixes for IBC const ( - KeyChannelPrefix = "channelEnds" + KeyClientState = "clientState" + KeyConsensusStatePrefix = "consensusStates" + KeyConnectionPrefix = "connections" + KeyChannelEndPrefix = "channelEnds" + KeyChannelPrefix = "channels" + KeyPortPrefix = "ports" + KeySequencePrefix = "sequences" KeyChannelCapabilityPrefix = "capabilities" KeyNextSeqSendPrefix = "nextSequenceSend" KeyNextSeqRecvPrefix = "nextSequenceRecv" @@ -42,38 +46,57 @@ const ( // FullClientPath returns the full path of a specific client path in the format: // "clients/{clientID}/{path}" as a string. func FullClientPath(clientID string, path string) string { - return string(FullKeyClientPath(clientID, []byte(path))) + return fmt.Sprintf("%s/%s/%s", KeyClientStorePrefix, clientID, path) } -// FullKeyClientPath returns the full path of specific client path in the format: +// FullClientKey returns the full path of specific client path in the format: // "clients/{clientID}/{path}" as a byte array. -func FullKeyClientPath(clientID string, path []byte) []byte { - return append(KeyClientStorePrefix, append([]byte("/"+clientID+"/"), path...)...) +func FullClientKey(clientID string, path []byte) []byte { + return []byte(FullClientPath(clientID, string(path))) } // ICS02 // The following paths are the keys to the store as defined in https://github.com/cosmos/ics/tree/master/spec/ics-002-client-semantics#path-space -// ClientStatePath takes an Identifier and returns a Path under which to store a +// FullClientStatePath takes a client identifier and returns a Path under which to store a // particular client state -func ClientStatePath() string { - return "clientState" +func FullClientStatePath(clientID string) string { + return FullClientPath(clientID, KeyClientState) } -// ConsensusStatePath takes an Identifier and returns a Path under which to +// FullClientStateKey takes a client identifier and returns a Key under which to store a +// particular client state. +func FullClientStateKey(clientID string) []byte { + return FullClientKey(clientID, []byte(KeyClientState)) +} + +// ClientStateKey returns a store key under which a particular client state is stored +// in a client prefixed store +func ClientStateKey() []byte { + return []byte(KeyClientState) +} + +// FullConsensusStatePath takes a client identifier and returns a Path under which to // store the consensus state of a client. +func FullConsensusStatePath(clientID string, height exported.Height) string { + return FullClientPath(clientID, fmt.Sprintf("%s/%s", KeyConsensusStatePrefix, height)) +} + +// FullConsensusStateKey returns the store key for the consensus state of a particular +// client. +func FullConsensusStateKey(clientID string, height exported.Height) []byte { + return []byte(FullConsensusStatePath(clientID, height)) +} + +// ConsensusStatePath returns the suffix store key for the consensus state at a +// particular height stored in a client prefixed store. func ConsensusStatePath(height exported.Height) string { - return fmt.Sprintf("%s/%s", KeyConsensusStatesPrefix, height) + return fmt.Sprintf("%s/%s", KeyConsensusStatePrefix, height) } -// KeyClientState returns the store key for a particular client state -func KeyClientState() []byte { - return []byte(ClientStatePath()) -} - -// KeyConsensusState returns the store key for the consensus state of a particular -// client -func KeyConsensusState(height exported.Height) []byte { +// ConsensusStateKey returns the store key for a the consensus state of a particular +// client stored in a client prefixed store. +func ConsensusStateKey(height exported.Height) []byte { return []byte(ConsensusStatePath(height)) } @@ -82,7 +105,12 @@ func KeyConsensusState(height exported.Height) []byte { // ClientConnectionsPath defines a reverse mapping from clients to a set of connections func ClientConnectionsPath(clientID string) string { - return fmt.Sprintf("%s/%s/connections", KeyClientStorePrefix, clientID) + return FullClientPath(clientID, KeyConnectionPrefix) +} + +// ClientConnectionsKey returns the store key for the connections of a given client +func ClientConnectionsKey(clientID string) []byte { + return []byte(ClientConnectionsPath(clientID)) } // ConnectionPath defines the path under which connection paths are stored @@ -90,13 +118,8 @@ func ConnectionPath(connectionID string) string { return fmt.Sprintf("%s/%s", KeyConnectionPrefix, connectionID) } -// KeyClientConnections returns the store key for the connections of a given client -func KeyClientConnections(clientID string) []byte { - return []byte(ClientConnectionsPath(clientID)) -} - -// KeyConnection returns the store key for a particular connection -func KeyConnection(connectionID string) []byte { +// ConnectionKey returns the store key for a particular connection +func ConnectionKey(connectionID string) []byte { return []byte(ConnectionPath(connectionID)) } @@ -105,98 +128,102 @@ func KeyConnection(connectionID string) []byte { // ChannelPath defines the path under which channels are stored func ChannelPath(portID, channelID string) string { - return fmt.Sprintf("%s/", KeyChannelPrefix) + channelPath(portID, channelID) + return fmt.Sprintf("%s/%s", KeyChannelEndPrefix, channelPath(portID, channelID)) +} + +// ChannelKey returns the store key for a particular channel +func ChannelKey(portID, channelID string) []byte { + return []byte(ChannelPath(portID, channelID)) } // ChannelCapabilityPath defines the path under which capability keys associated // with a channel are stored func ChannelCapabilityPath(portID, channelID string) string { - return fmt.Sprintf("%s/", KeyChannelCapabilityPrefix) + channelPath(portID, channelID) + "/key" + return fmt.Sprintf("%s/%s", KeyChannelCapabilityPrefix, channelPath(portID, channelID)) } // NextSequenceSendPath defines the next send sequence counter store path func NextSequenceSendPath(portID, channelID string) string { - return fmt.Sprintf("%s/", KeyNextSeqSendPrefix) + channelPath(portID, channelID) + return fmt.Sprintf("%s/%s", KeyNextSeqSendPrefix, channelPath(portID, channelID)) } -// NextSequenceRecvPath defines the next receive sequence counter store path +// NextSequenceSendKey returns the store key for the send sequence of a particular +// channel binded to a specific port. +func NextSequenceSendKey(portID, channelID string) []byte { + return []byte(NextSequenceSendPath(portID, channelID)) +} + +// NextSequenceRecvPath defines the next receive sequence counter store path. func NextSequenceRecvPath(portID, channelID string) string { - return fmt.Sprintf("%s/", KeyNextSeqRecvPrefix) + channelPath(portID, channelID) + return fmt.Sprintf("%s/%s", KeyNextSeqRecvPrefix, channelPath(portID, channelID)) +} + +// NextSequenceRecvKey returns the store key for the receive sequence of a particular +// channel binded to a specific port +func NextSequenceRecvKey(portID, channelID string) []byte { + return []byte(NextSequenceRecvPath(portID, channelID)) } // NextSequenceAckPath defines the next acknowledgement sequence counter store path func NextSequenceAckPath(portID, channelID string) string { - return fmt.Sprintf("%s/", KeyNextSeqAckPrefix) + channelPath(portID, channelID) + return fmt.Sprintf("%s/%s", KeyNextSeqAckPrefix, channelPath(portID, channelID)) +} + +// NextSequenceAckKey returns the store key for the acknowledgement sequence of +// a particular channel binded to a specific port. +func NextSequenceAckKey(portID, channelID string) []byte { + return []byte(NextSequenceAckPath(portID, channelID)) } // PacketCommitmentPath defines the commitments to packet data fields store path func PacketCommitmentPath(portID, channelID string, sequence uint64) string { - return fmt.Sprintf("%s/", KeyPacketCommitmentPrefix) + channelPath(portID, channelID) + fmt.Sprintf("/packets/%d", sequence) + return fmt.Sprintf("%s/%s/%s", KeyPacketCommitmentPrefix, channelPath(portID, channelID), sequencePath(sequence)) +} + +// PacketCommitmentKey returns the store key of under which a packet commitment +// is stored +func PacketCommitmentKey(portID, channelID string, sequence uint64) []byte { + return []byte(PacketCommitmentPath(portID, channelID, sequence)) } // PacketCommitmentPrefixPath defines the prefix for commitments to packet data fields store path. func PacketCommitmentPrefixPath(portID, channelID string) string { - return fmt.Sprintf("%s/", KeyPacketCommitmentPrefix) + channelPath(portID, channelID) + return fmt.Sprintf("%s/%s/%s", KeyPacketCommitmentPrefix, channelPath(portID, channelID), KeySequencePrefix) } // PacketAcknowledgementPath defines the packet acknowledgement store path func PacketAcknowledgementPath(portID, channelID string, sequence uint64) string { - return fmt.Sprintf("%s/", KeyPacketAckPrefix) + channelPath(portID, channelID) + fmt.Sprintf("/acknowledgements/%d", sequence) + return fmt.Sprintf("%s/%s/%s", KeyPacketAckPrefix, channelPath(portID, channelID), sequencePath(sequence)) +} + +// PacketAcknowledgementKey returns the store key of under which a packet +// acknowledgement is stored +func PacketAcknowledgementKey(portID, channelID string, sequence uint64) []byte { + return []byte(PacketAcknowledgementPath(portID, channelID, sequence)) } // PacketAcknowledgementPrefixPath defines the prefix for commitments to packet data fields store path. func PacketAcknowledgementPrefixPath(portID, channelID string) string { - return fmt.Sprintf("%s/", KeyPacketAckPrefix) + channelPath(portID, channelID) + return fmt.Sprintf("%s/%s/%s", KeyPacketAckPrefix, channelPath(portID, channelID), KeySequencePrefix) } // PacketReceiptPath defines the packet receipt store path func PacketReceiptPath(portID, channelID string, sequence uint64) string { - return fmt.Sprintf("%s/", KeyPacketReceiptPrefix) + channelPath(portID, channelID) + fmt.Sprintf("/receipts/%d", sequence) + return fmt.Sprintf("%s/%s/%s", KeyPacketReceiptPrefix, channelPath(portID, channelID), sequencePath(sequence)) } -// KeyChannel returns the store key for a particular channel -func KeyChannel(portID, channelID string) []byte { - return []byte(ChannelPath(portID, channelID)) -} - -// KeyNextSequenceSend returns the store key for the send sequence of a particular -// channel binded to a specific port -func KeyNextSequenceSend(portID, channelID string) []byte { - return []byte(NextSequenceSendPath(portID, channelID)) -} - -// KeyNextSequenceRecv returns the store key for the receive sequence of a particular -// channel binded to a specific port -func KeyNextSequenceRecv(portID, channelID string) []byte { - return []byte(NextSequenceRecvPath(portID, channelID)) -} - -// KeyNextSequenceAck returns the store key for the acknowledgement sequence of -// a particular channel binded to a specific port. -func KeyNextSequenceAck(portID, channelID string) []byte { - return []byte(NextSequenceAckPath(portID, channelID)) -} - -// KeyPacketCommitment returns the store key of under which a packet commitment -// is stored -func KeyPacketCommitment(portID, channelID string, sequence uint64) []byte { - return []byte(PacketCommitmentPath(portID, channelID, sequence)) -} - -// KeyPacketAcknowledgement returns the store key of under which a packet -// acknowledgement is stored -func KeyPacketAcknowledgement(portID, channelID string, sequence uint64) []byte { - return []byte(PacketAcknowledgementPath(portID, channelID, sequence)) -} - -// KeyPacketReceipt returns the store key of under which a packet +// PacketReceiptKey returns the store key of under which a packet // receipt is stored -func KeyPacketReceipt(portID, channelID string, sequence uint64) []byte { +func PacketReceiptKey(portID, channelID string, sequence uint64) []byte { return []byte(PacketReceiptPath(portID, channelID, sequence)) } func channelPath(portID, channelID string) string { - return fmt.Sprintf("ports/%s/channels/%s", portID, channelID) + return fmt.Sprintf("%s/%s/%s/%s", KeyPortPrefix, portID, KeyChannelPrefix, channelID) +} + +func sequencePath(sequence uint64) string { + return fmt.Sprintf("%s/%d", KeySequencePrefix, sequence) } // ICS05 @@ -204,5 +231,5 @@ func channelPath(portID, channelID string) string { // PortPath defines the path under which ports paths are stored on the capability module func PortPath(portID string) string { - return fmt.Sprintf("ports/%s", portID) + return fmt.Sprintf("%s/%s", KeyPortPrefix, portID) } diff --git a/x/ibc/core/24-host/parse.go b/x/ibc/core/24-host/parse.go index 7200c4ff0..7e6301a39 100644 --- a/x/ibc/core/24-host/parse.go +++ b/x/ibc/core/24-host/parse.go @@ -25,7 +25,7 @@ func ParseChannelPath(path string) (string, string, error) { return "", "", sdkerrors.Wrapf(ErrInvalidPath, "cannot parse channel path %s", path) } - if split[1] != "ports" || split[3] != "channels" { + if split[1] != KeyPortPrefix || split[3] != KeyChannelPrefix { return "", "", sdkerrors.Wrapf(ErrInvalidPath, "cannot parse channel path %s", path) } diff --git a/x/ibc/core/keeper/msg_server_test.go b/x/ibc/core/keeper/msg_server_test.go index a80426724..5c4aa466a 100644 --- a/x/ibc/core/keeper/msg_server_test.go +++ b/x/ibc/core/keeper/msg_server_test.go @@ -142,7 +142,7 @@ func (suite *KeeperTestSuite) TestHandleRecvPacket() { tc.malleate() // get proof of packet commitment from chainA - packetKey := host.KeyPacketCommitment(packet.GetSourcePort(), packet.GetSourceChannel(), packet.GetSequence()) + packetKey := host.PacketCommitmentKey(packet.GetSourcePort(), packet.GetSourceChannel(), packet.GetSequence()) proof, proofHeight := suite.chainA.QueryProof(packetKey) msg := channeltypes.NewMsgRecvPacket(packet, proof, proofHeight, suite.chainB.SenderAccount.GetAddress()) @@ -281,7 +281,7 @@ func (suite *KeeperTestSuite) TestHandleAcknowledgePacket() { tc.malleate() - packetKey := host.KeyPacketAcknowledgement(packet.GetDestPort(), packet.GetDestChannel(), packet.GetSequence()) + packetKey := host.PacketAcknowledgementKey(packet.GetDestPort(), packet.GetDestChannel(), packet.GetSequence()) proof, proofHeight := suite.chainB.QueryProof(packetKey) msg := channeltypes.NewMsgAcknowledgement(packet, ibcmock.MockAcknowledgement, proof, proofHeight, suite.chainA.SenderAccount.GetAddress()) @@ -333,7 +333,7 @@ func (suite *KeeperTestSuite) TestHandleTimeoutPacket() { // need to update chainA client to prove missing ack suite.coordinator.UpdateClient(suite.chainA, suite.chainB, clientA, ibctesting.Tendermint) - packetKey = host.KeyNextSequenceRecv(packet.GetDestPort(), packet.GetDestChannel()) + packetKey = host.NextSequenceRecvKey(packet.GetDestPort(), packet.GetDestChannel()) }, true}, {"success: UNORDERED", func() { clientA, clientB, _, _, channelA, channelB := suite.coordinator.Setup(suite.chainA, suite.chainB, channeltypes.UNORDERED) @@ -346,7 +346,7 @@ func (suite *KeeperTestSuite) TestHandleTimeoutPacket() { // need to update chainA client to prove missing ack suite.coordinator.UpdateClient(suite.chainA, suite.chainB, clientA, ibctesting.Tendermint) - packetKey = host.KeyPacketReceipt(packet.GetDestPort(), packet.GetDestChannel(), packet.GetSequence()) + packetKey = host.PacketReceiptKey(packet.GetDestPort(), packet.GetDestChannel(), packet.GetSequence()) }, true}, {"success: UNORDERED timeout out of order packet", func() { // setup uses an UNORDERED channel @@ -363,7 +363,7 @@ func (suite *KeeperTestSuite) TestHandleTimeoutPacket() { } suite.coordinator.UpdateClient(suite.chainA, suite.chainB, clientA, ibctesting.Tendermint) - packetKey = host.KeyPacketReceipt(packet.GetDestPort(), packet.GetDestChannel(), packet.GetSequence()) + packetKey = host.PacketReceiptKey(packet.GetDestPort(), packet.GetDestChannel(), packet.GetSequence()) }, true}, {"success: ORDERED timeout out of order packet", func() { clientA, clientB, _, _, channelA, channelB := suite.coordinator.Setup(suite.chainA, suite.chainB, channeltypes.ORDERED) @@ -379,19 +379,19 @@ func (suite *KeeperTestSuite) TestHandleTimeoutPacket() { } suite.coordinator.UpdateClient(suite.chainA, suite.chainB, clientA, ibctesting.Tendermint) - packetKey = host.KeyNextSequenceRecv(packet.GetDestPort(), packet.GetDestChannel()) + packetKey = host.NextSequenceRecvKey(packet.GetDestPort(), packet.GetDestChannel()) }, true}, {"channel does not exist", func() { // any non-nil value of packet is valid suite.Require().NotNil(packet) - packetKey = host.KeyNextSequenceRecv(packet.GetDestPort(), packet.GetDestChannel()) + packetKey = host.NextSequenceRecvKey(packet.GetDestPort(), packet.GetDestChannel()) }, false}, {"UNORDERED: packet not sent", func() { _, _, _, _, channelA, channelB := suite.coordinator.Setup(suite.chainA, suite.chainB, channeltypes.UNORDERED) packet = channeltypes.NewPacket(ibctesting.MockCommitment, 1, channelA.PortID, channelA.ID, channelB.PortID, channelB.ID, timeoutHeight, 0) - packetKey = host.KeyPacketReceipt(packet.GetDestPort(), packet.GetDestChannel(), packet.GetSequence()) + packetKey = host.PacketReceiptKey(packet.GetDestPort(), packet.GetDestChannel(), packet.GetSequence()) }, false}, } @@ -460,7 +460,7 @@ func (suite *KeeperTestSuite) TestHandleTimeoutOnClosePacket() { // need to update chainA client to prove missing ack suite.coordinator.UpdateClient(suite.chainA, suite.chainB, clientA, ibctesting.Tendermint) - packetKey = host.KeyNextSequenceRecv(packet.GetDestPort(), packet.GetDestChannel()) + packetKey = host.NextSequenceRecvKey(packet.GetDestPort(), packet.GetDestChannel()) // close counterparty channel suite.coordinator.SetChannelClosed(suite.chainB, suite.chainA, counterpartyChannel) @@ -481,7 +481,7 @@ func (suite *KeeperTestSuite) TestHandleTimeoutOnClosePacket() { // need to update chainA client to prove missing ack suite.coordinator.UpdateClient(suite.chainA, suite.chainB, clientA, ibctesting.Tendermint) - packetKey = host.KeyPacketReceipt(packet.GetDestPort(), packet.GetDestChannel(), packet.GetSequence()) + packetKey = host.PacketReceiptKey(packet.GetDestPort(), packet.GetDestChannel(), packet.GetSequence()) // close counterparty channel suite.coordinator.SetChannelClosed(suite.chainB, suite.chainA, counterpartyChannel) @@ -506,7 +506,7 @@ func (suite *KeeperTestSuite) TestHandleTimeoutOnClosePacket() { } suite.coordinator.UpdateClient(suite.chainA, suite.chainB, clientA, ibctesting.Tendermint) - packetKey = host.KeyPacketReceipt(packet.GetDestPort(), packet.GetDestChannel(), packet.GetSequence()) + packetKey = host.PacketReceiptKey(packet.GetDestPort(), packet.GetDestChannel(), packet.GetSequence()) // close counterparty channel suite.coordinator.SetChannelClosed(suite.chainB, suite.chainA, counterpartyChannel) @@ -530,7 +530,7 @@ func (suite *KeeperTestSuite) TestHandleTimeoutOnClosePacket() { } suite.coordinator.UpdateClient(suite.chainA, suite.chainB, clientA, ibctesting.Tendermint) - packetKey = host.KeyNextSequenceRecv(packet.GetDestPort(), packet.GetDestChannel()) + packetKey = host.NextSequenceRecvKey(packet.GetDestPort(), packet.GetDestChannel()) // close counterparty channel suite.coordinator.SetChannelClosed(suite.chainB, suite.chainA, counterpartyChannel) @@ -539,12 +539,12 @@ func (suite *KeeperTestSuite) TestHandleTimeoutOnClosePacket() { // any non-nil value of packet is valid suite.Require().NotNil(packet) - packetKey = host.KeyNextSequenceRecv(packet.GetDestPort(), packet.GetDestChannel()) + packetKey = host.NextSequenceRecvKey(packet.GetDestPort(), packet.GetDestChannel()) }, false}, {"UNORDERED: packet not sent", func() { clientA, _, _, _, channelA, channelB := suite.coordinator.Setup(suite.chainA, suite.chainB, channeltypes.UNORDERED) packet = channeltypes.NewPacket(ibctesting.MockCommitment, 1, channelA.PortID, channelA.ID, channelB.PortID, channelB.ID, timeoutHeight, 0) - packetKey = host.KeyPacketAcknowledgement(packet.GetDestPort(), packet.GetDestChannel(), packet.GetSequence()) + packetKey = host.PacketAcknowledgementKey(packet.GetDestPort(), packet.GetDestChannel(), packet.GetSequence()) counterpartyChannel = ibctesting.TestChannel{ PortID: channelB.PortID, ID: channelB.ID, @@ -570,7 +570,7 @@ func (suite *KeeperTestSuite) TestHandleTimeoutOnClosePacket() { // need to update chainA client to prove missing ack suite.coordinator.UpdateClient(suite.chainA, suite.chainB, clientA, ibctesting.Tendermint) - packetKey = host.KeyNextSequenceRecv(packet.GetDestPort(), packet.GetDestChannel()) + packetKey = host.NextSequenceRecvKey(packet.GetDestPort(), packet.GetDestChannel()) }, false}, } @@ -584,7 +584,7 @@ func (suite *KeeperTestSuite) TestHandleTimeoutOnClosePacket() { proof, proofHeight := suite.chainB.QueryProof(packetKey) - channelKey := host.KeyChannel(counterpartyChannel.PortID, counterpartyChannel.ID) + channelKey := host.ChannelKey(counterpartyChannel.PortID, counterpartyChannel.ID) proofClosed, _ := suite.chainB.QueryProof(channelKey) msg := channeltypes.NewMsgTimeoutOnClose(packet, 1, proof, proofClosed, proofHeight, suite.chainA.SenderAccount.GetAddress()) diff --git a/x/ibc/core/simulation/decoder_test.go b/x/ibc/core/simulation/decoder_test.go index d14a9f28c..095157274 100644 --- a/x/ibc/core/simulation/decoder_test.go +++ b/x/ibc/core/simulation/decoder_test.go @@ -40,15 +40,15 @@ func TestDecodeStore(t *testing.T) { kvPairs := kv.Pairs{ Pairs: []kv.Pair{ { - Key: host.FullKeyClientPath(clientID, host.KeyClientState()), + Key: host.FullClientStateKey(clientID), Value: app.IBCKeeper.ClientKeeper.MustMarshalClientState(clientState), }, { - Key: host.KeyConnection(connectionID), + Key: host.ConnectionKey(connectionID), Value: app.IBCKeeper.Codec().MustMarshalBinaryBare(&connection), }, { - Key: host.KeyChannel(portID, channelID), + Key: host.ChannelKey(portID, channelID), Value: app.IBCKeeper.Codec().MustMarshalBinaryBare(&channel), }, { diff --git a/x/ibc/core/spec/02_state.md b/x/ibc/core/spec/02_state.md index 5df09a097..54eb41bc4 100644 --- a/x/ibc/core/spec/02_state.md +++ b/x/ibc/core/spec/02_state.md @@ -16,10 +16,10 @@ The client type is not stored since it can be obtained through the client state. | "0/" | "connections/{identifier}" | ConnectionEnd | | "0/" | "ports/{identifier}" | CapabilityKey | | "0/" | "channelEnds/ports/{identifier}/channels/{identifier}" | ChannelEnd | -| "0/" | "capabilities/ports/{identifier}/channels/{identifier}/key" | CapabilityKey | -| "0/" | "seqSends/ports/{identifier}/channels/{identifier}/nextSequenceSend" | uint64 | -| "0/" | "seqRecvs/ports/{identifier}/channels/{identifier}/nextSequenceRecv" | uint64 | -| "0/" | "seqAcks/ports/{identifier}/channels/{identifier}/nextSequenceAck" | uint64 | -| "0/" | "commitments/ports/{identifier}/channels/{identifier}/packets/{sequence}" | bytes | -| "0/" | "receipts/ports/{identifier}/channels/{identifier}/receipts/{sequence}" | bytes | -| "0/" | "acks/ports/{identifier}/channels/{identifier}/acknowledgements/{sequence}" | bytes | +| "0/" | "capabilities/ports/{identifier}/channels/{identifier}" | CapabilityKey | +| "0/" | "nextSequenceSend/ports/{identifier}/channels/{identifier}" | uint64 | +| "0/" | "nextSequenceRecv/ports/{identifier}/channels/{identifier}" | uint64 | +| "0/" | "nextSequenceAck/ports/{identifier}/channels/{identifier}" | uint64 | +| "0/" | "commitments/ports/{identifier}/channels/{identifier}/sequences/{sequence}" | bytes | +| "0/" | "receipts/ports/{identifier}/channels/{identifier}/sequences/{sequence}" | bytes | +| "0/" | "acks/ports/{identifier}/channels/{identifier}/sequences/{sequence}" | bytes | diff --git a/x/ibc/light-clients/06-solomachine/types/client_state.go b/x/ibc/light-clients/06-solomachine/types/client_state.go index 583193f3d..5e9fe014a 100644 --- a/x/ibc/light-clients/06-solomachine/types/client_state.go +++ b/x/ibc/light-clients/06-solomachine/types/client_state.go @@ -100,7 +100,7 @@ func (cs ClientState) VerifyClientState( return err } - clientPrefixedPath := commitmenttypes.NewMerklePath("clients/" + counterpartyClientIdentifier + "/" + host.ClientStatePath()) + clientPrefixedPath := commitmenttypes.NewMerklePath(host.FullClientStatePath(counterpartyClientIdentifier)) path, err := commitmenttypes.ApplyPrefix(prefix, clientPrefixedPath) if err != nil { return err @@ -138,7 +138,7 @@ func (cs ClientState) VerifyClientConsensusState( return err } - clientPrefixedPath := commitmenttypes.NewMerklePath("clients/" + counterpartyClientIdentifier + "/" + host.ConsensusStatePath(consensusHeight)) + clientPrefixedPath := commitmenttypes.NewMerklePath(host.FullConsensusStatePath(counterpartyClientIdentifier, consensusHeight)) path, err := commitmenttypes.ApplyPrefix(prefix, clientPrefixedPath) if err != nil { return err @@ -460,5 +460,5 @@ func produceVerificationArgs( // sets the client state to the store func setClientState(store sdk.KVStore, cdc codec.BinaryMarshaler, clientState exported.ClientState) { bz := clienttypes.MustMarshalClientState(cdc, clientState) - store.Set(host.KeyClientState(), bz) + store.Set([]byte(host.KeyClientState), bz) } diff --git a/x/ibc/light-clients/06-solomachine/types/solomachine_test.go b/x/ibc/light-clients/06-solomachine/types/solomachine_test.go index ee236a9e8..53f5c4a48 100644 --- a/x/ibc/light-clients/06-solomachine/types/solomachine_test.go +++ b/x/ibc/light-clients/06-solomachine/types/solomachine_test.go @@ -49,7 +49,7 @@ func TestSoloMachineTestSuite(t *testing.T) { } func (suite *SoloMachineTestSuite) GetSequenceFromStore() uint64 { - bz := suite.store.Get(host.KeyClientState()) + bz := suite.store.Get(host.ClientStateKey()) suite.Require().NotNil(bz) var clientState exported.ClientState diff --git a/x/ibc/light-clients/07-tendermint/types/client_state.go b/x/ibc/light-clients/07-tendermint/types/client_state.go index 65d431245..3940d44b7 100644 --- a/x/ibc/light-clients/07-tendermint/types/client_state.go +++ b/x/ibc/light-clients/07-tendermint/types/client_state.go @@ -180,7 +180,7 @@ func (cs ClientState) VerifyClientState( return err } - clientPrefixedPath := commitmenttypes.NewMerklePath("clients/" + counterpartyClientIdentifier + "/" + host.ClientStatePath()) + clientPrefixedPath := commitmenttypes.NewMerklePath(host.FullClientStatePath(counterpartyClientIdentifier)) path, err := commitmenttypes.ApplyPrefix(prefix, clientPrefixedPath) if err != nil { return err @@ -220,7 +220,7 @@ func (cs ClientState) VerifyClientConsensusState( return err } - clientPrefixedPath := commitmenttypes.NewMerklePath("clients/" + counterpartyClientIdentifier + "/" + host.ConsensusStatePath(consensusHeight)) + clientPrefixedPath := commitmenttypes.NewMerklePath(host.FullConsensusStatePath(counterpartyClientIdentifier, consensusHeight)) path, err := commitmenttypes.ApplyPrefix(prefix, clientPrefixedPath) if err != nil { return err diff --git a/x/ibc/light-clients/07-tendermint/types/client_state_test.go b/x/ibc/light-clients/07-tendermint/types/client_state_test.go index 4f8204466..90ff6767f 100644 --- a/x/ibc/light-clients/07-tendermint/types/client_state_test.go +++ b/x/ibc/light-clients/07-tendermint/types/client_state_test.go @@ -230,7 +230,7 @@ func (suite *TendermintTestSuite) TestVerifyConnectionState() { prefix = suite.chainB.GetPrefix() // make connection proof - connectionKey := host.KeyConnection(connB.ID) + connectionKey := host.ConnectionKey(connB.ID) proof, proofHeight = suite.chainB.QueryProof(connectionKey) tc.malleate() // make changes as necessary @@ -308,7 +308,7 @@ func (suite *TendermintTestSuite) TestVerifyChannelState() { prefix = suite.chainB.GetPrefix() // make channel proof - channelKey := host.KeyChannel(channelB.PortID, channelB.ID) + channelKey := host.ChannelKey(channelB.PortID, channelB.ID) proof, proofHeight = suite.chainB.QueryProof(channelKey) tc.malleate() // make changes as necessary @@ -389,7 +389,7 @@ func (suite *TendermintTestSuite) TestVerifyPacketCommitment() { prefix = suite.chainB.GetPrefix() // make packet commitment proof - packetKey := host.KeyPacketCommitment(packet.GetSourcePort(), packet.GetSourceChannel(), packet.GetSequence()) + packetKey := host.PacketCommitmentKey(packet.GetSourcePort(), packet.GetSourceChannel(), packet.GetSequence()) proof, proofHeight = suite.chainB.QueryProof(packetKey) tc.malleate() // make changes as necessary @@ -477,7 +477,7 @@ func (suite *TendermintTestSuite) TestVerifyPacketAcknowledgement() { prefix = suite.chainB.GetPrefix() // make packet acknowledgement proof - acknowledgementKey := host.KeyPacketAcknowledgement(packet.GetDestPort(), packet.GetDestChannel(), packet.GetSequence()) + acknowledgementKey := host.PacketAcknowledgementKey(packet.GetDestPort(), packet.GetDestChannel(), packet.GetSequence()) proof, proofHeight = suite.chainB.QueryProof(acknowledgementKey) tc.malleate() // make changes as necessary @@ -564,7 +564,7 @@ func (suite *TendermintTestSuite) TestVerifyPacketReceiptAbsence() { prefix = suite.chainB.GetPrefix() // make packet receipt absence proof - receiptKey := host.KeyPacketReceipt(packet.GetDestPort(), packet.GetDestChannel(), packet.GetSequence()) + receiptKey := host.PacketReceiptKey(packet.GetDestPort(), packet.GetDestChannel(), packet.GetSequence()) proof, proofHeight = suite.chainB.QueryProof(receiptKey) tc.malleate() // make changes as necessary @@ -655,7 +655,7 @@ func (suite *TendermintTestSuite) TestVerifyNextSeqRecv() { prefix = suite.chainB.GetPrefix() // make next seq recv proof - nextSeqRecvKey := host.KeyNextSequenceRecv(packet.GetDestPort(), packet.GetDestChannel()) + nextSeqRecvKey := host.NextSequenceRecvKey(packet.GetDestPort(), packet.GetDestChannel()) proof, proofHeight = suite.chainB.QueryProof(nextSeqRecvKey) tc.malleate() // make changes as necessary diff --git a/x/ibc/light-clients/07-tendermint/types/store.go b/x/ibc/light-clients/07-tendermint/types/store.go index 096d79833..50f8d2a1d 100644 --- a/x/ibc/light-clients/07-tendermint/types/store.go +++ b/x/ibc/light-clients/07-tendermint/types/store.go @@ -12,7 +12,7 @@ import ( // GetConsensusState retrieves the consensus state from the client prefixed // store. An error is returned if the consensus state does not exist. func GetConsensusState(store sdk.KVStore, cdc codec.BinaryMarshaler, height exported.Height) (*ConsensusState, error) { - bz := store.Get(host.KeyConsensusState(height)) + bz := store.Get(host.ConsensusStateKey(height)) if bz == nil { return nil, sdkerrors.Wrapf( clienttypes.ErrConsensusStateNotFound, diff --git a/x/ibc/light-clients/07-tendermint/types/store_test.go b/x/ibc/light-clients/07-tendermint/types/store_test.go index 91cb973ca..3bb267b0f 100644 --- a/x/ibc/light-clients/07-tendermint/types/store_test.go +++ b/x/ibc/light-clients/07-tendermint/types/store_test.go @@ -34,7 +34,7 @@ func (suite *TendermintTestSuite) TestGetConsensusState() { // marshal an empty client state and set as consensus state store := suite.chainA.App.IBCKeeper.ClientKeeper.ClientStore(suite.chainA.GetContext(), clientA) clientStateBz := suite.chainA.App.IBCKeeper.ClientKeeper.MustMarshalClientState(&types.ClientState{}) - store.Set(host.KeyConsensusState(height), clientStateBz) + store.Set(host.ConsensusStateKey(height), clientStateBz) }, false, }, { @@ -42,7 +42,7 @@ func (suite *TendermintTestSuite) TestGetConsensusState() { // marshal and set solomachine consensus state store := suite.chainA.App.IBCKeeper.ClientKeeper.ClientStore(suite.chainA.GetContext(), clientA) consensusStateBz := suite.chainA.App.IBCKeeper.ClientKeeper.MustMarshalConsensusState(&solomachinetypes.ConsensusState{}) - store.Set(host.KeyConsensusState(height), consensusStateBz) + store.Set(host.ConsensusStateKey(height), consensusStateBz) }, false, }, } diff --git a/x/ibc/light-clients/09-localhost/types/client_state.go b/x/ibc/light-clients/09-localhost/types/client_state.go index fa4223fc9..eb6931147 100644 --- a/x/ibc/light-clients/09-localhost/types/client_state.go +++ b/x/ibc/light-clients/09-localhost/types/client_state.go @@ -115,8 +115,8 @@ func (cs ClientState) VerifyClientState( store sdk.KVStore, cdc codec.BinaryMarshaler, _ exported.Height, _ exported.Prefix, _ string, _ []byte, clientState exported.ClientState, ) error { - path := host.KeyClientState() - bz := store.Get(path) + path := host.KeyClientState + bz := store.Get([]byte(path)) if bz == nil { return sdkerrors.Wrapf(clienttypes.ErrFailedClientStateVerification, "not found for path: %s", path) @@ -154,7 +154,7 @@ func (cs ClientState) VerifyConnectionState( connectionID string, connectionEnd exported.ConnectionI, ) error { - path := host.KeyConnection(connectionID) + path := host.ConnectionKey(connectionID) bz := store.Get(path) if bz == nil { return sdkerrors.Wrapf(clienttypes.ErrFailedConnectionStateVerification, "not found for path %s", path) @@ -188,7 +188,7 @@ func (cs ClientState) VerifyChannelState( channelID string, channel exported.ChannelI, ) error { - path := host.KeyChannel(portID, channelID) + path := host.ChannelKey(portID, channelID) bz := store.Get(path) if bz == nil { return sdkerrors.Wrapf(clienttypes.ErrFailedChannelStateVerification, "not found for path %s", path) @@ -223,7 +223,7 @@ func (cs ClientState) VerifyPacketCommitment( sequence uint64, commitmentBytes []byte, ) error { - path := host.KeyPacketCommitment(portID, channelID, sequence) + path := host.PacketCommitmentKey(portID, channelID, sequence) data := store.Get(path) if len(data) == 0 { @@ -253,7 +253,7 @@ func (cs ClientState) VerifyPacketAcknowledgement( sequence uint64, acknowledgement []byte, ) error { - path := host.KeyPacketAcknowledgement(portID, channelID, sequence) + path := host.PacketAcknowledgementKey(portID, channelID, sequence) data := store.Get(path) if len(data) == 0 { @@ -283,7 +283,7 @@ func (cs ClientState) VerifyPacketReceiptAbsence( channelID string, sequence uint64, ) error { - path := host.KeyPacketReceipt(portID, channelID, sequence) + path := host.PacketReceiptKey(portID, channelID, sequence) data := store.Get(path) if data != nil { @@ -305,7 +305,7 @@ func (cs ClientState) VerifyNextSequenceRecv( channelID string, nextSequenceRecv uint64, ) error { - path := host.KeyNextSequenceRecv(portID, channelID) + path := host.NextSequenceRecvKey(portID, channelID) data := store.Get(path) if len(data) == 0 { diff --git a/x/ibc/light-clients/09-localhost/types/client_state_test.go b/x/ibc/light-clients/09-localhost/types/client_state_test.go index f56cec5d7..a4443867d 100644 --- a/x/ibc/light-clients/09-localhost/types/client_state_test.go +++ b/x/ibc/light-clients/09-localhost/types/client_state_test.go @@ -66,7 +66,7 @@ func (suite *LocalhostTestSuite) TestVerifyClientState() { clientState: clientState, malleate: func() { bz := clienttypes.MustMarshalClientState(suite.cdc, clientState) - suite.store.Set(host.KeyClientState(), bz) + suite.store.Set(host.ClientStateKey(), bz) }, counterparty: clientState, expPass: true, @@ -76,7 +76,7 @@ func (suite *LocalhostTestSuite) TestVerifyClientState() { clientState: clientState, malleate: func() { bz := clienttypes.MustMarshalClientState(suite.cdc, clientState) - suite.store.Set(host.KeyClientState(), bz) + suite.store.Set(host.ClientStateKey(), bz) }, counterparty: invalidClient, expPass: false, @@ -161,7 +161,7 @@ func (suite *LocalhostTestSuite) TestVerifyConnectionState() { malleate: func() { bz, err := suite.cdc.MarshalBinaryBare(&conn1) suite.Require().NoError(err) - suite.store.Set(host.KeyConnection(testConnectionID), bz) + suite.store.Set(host.ConnectionKey(testConnectionID), bz) }, connection: conn1, expPass: true, @@ -177,7 +177,7 @@ func (suite *LocalhostTestSuite) TestVerifyConnectionState() { name: "proof verification failed: unmarshal error", clientState: types.NewClientState("chainID", clientHeight), malleate: func() { - suite.store.Set(host.KeyConnection(testConnectionID), []byte("connection")) + suite.store.Set(host.ConnectionKey(testConnectionID), []byte("connection")) }, connection: conn1, expPass: false, @@ -188,7 +188,7 @@ func (suite *LocalhostTestSuite) TestVerifyConnectionState() { malleate: func() { bz, err := suite.cdc.MarshalBinaryBare(&conn2) suite.Require().NoError(err) - suite.store.Set(host.KeyConnection(testConnectionID), bz) + suite.store.Set(host.ConnectionKey(testConnectionID), bz) }, connection: conn1, expPass: false, @@ -233,7 +233,7 @@ func (suite *LocalhostTestSuite) TestVerifyChannelState() { malleate: func() { bz, err := suite.cdc.MarshalBinaryBare(&ch1) suite.Require().NoError(err) - suite.store.Set(host.KeyChannel(testPortID, testChannelID), bz) + suite.store.Set(host.ChannelKey(testPortID, testChannelID), bz) }, channel: ch1, expPass: true, @@ -249,7 +249,7 @@ func (suite *LocalhostTestSuite) TestVerifyChannelState() { name: "proof verification failed: unmarshal failed", clientState: types.NewClientState("chainID", clientHeight), malleate: func() { - suite.store.Set(host.KeyChannel(testPortID, testChannelID), []byte("channel")) + suite.store.Set(host.ChannelKey(testPortID, testChannelID), []byte("channel")) }, channel: ch1, @@ -261,7 +261,7 @@ func (suite *LocalhostTestSuite) TestVerifyChannelState() { malleate: func() { bz, err := suite.cdc.MarshalBinaryBare(&ch2) suite.Require().NoError(err) - suite.store.Set(host.KeyChannel(testPortID, testChannelID), bz) + suite.store.Set(host.ChannelKey(testPortID, testChannelID), bz) }, channel: ch1, @@ -302,7 +302,7 @@ func (suite *LocalhostTestSuite) TestVerifyPacketCommitment() { clientState: types.NewClientState("chainID", clientHeight), malleate: func() { suite.store.Set( - host.KeyPacketCommitment(testPortID, testChannelID, testSequence), []byte("commitment"), + host.PacketCommitmentKey(testPortID, testChannelID, testSequence), []byte("commitment"), ) }, commitment: []byte("commitment"), @@ -313,7 +313,7 @@ func (suite *LocalhostTestSuite) TestVerifyPacketCommitment() { clientState: types.NewClientState("chainID", clientHeight), malleate: func() { suite.store.Set( - host.KeyPacketCommitment(testPortID, testChannelID, testSequence), []byte("different"), + host.PacketCommitmentKey(testPortID, testChannelID, testSequence), []byte("different"), ) }, commitment: []byte("commitment"), @@ -361,7 +361,7 @@ func (suite *LocalhostTestSuite) TestVerifyPacketAcknowledgement() { clientState: types.NewClientState("chainID", clientHeight), malleate: func() { suite.store.Set( - host.KeyPacketAcknowledgement(testPortID, testChannelID, testSequence), []byte("acknowledgement"), + host.PacketAcknowledgementKey(testPortID, testChannelID, testSequence), []byte("acknowledgement"), ) }, ack: []byte("acknowledgement"), @@ -372,7 +372,7 @@ func (suite *LocalhostTestSuite) TestVerifyPacketAcknowledgement() { clientState: types.NewClientState("chainID", clientHeight), malleate: func() { suite.store.Set( - host.KeyPacketAcknowledgement(testPortID, testChannelID, testSequence), []byte("different"), + host.PacketAcknowledgementKey(testPortID, testChannelID, testSequence), []byte("different"), ) }, ack: []byte("acknowledgement"), @@ -416,7 +416,7 @@ func (suite *LocalhostTestSuite) TestVerifyPacketReceiptAbsence() { suite.Require().NoError(err, "receipt absence failed") - suite.store.Set(host.KeyPacketReceipt(testPortID, testChannelID, testSequence), []byte("receipt")) + suite.store.Set(host.PacketReceiptKey(testPortID, testChannelID, testSequence), []byte("receipt")) err = clientState.VerifyPacketReceiptAbsence( suite.store, suite.cdc, clientHeight, nil, nil, testPortID, testChannelID, testSequence, @@ -439,7 +439,7 @@ func (suite *LocalhostTestSuite) TestVerifyNextSeqRecv() { clientState: types.NewClientState("chainID", clientHeight), malleate: func() { suite.store.Set( - host.KeyNextSequenceRecv(testPortID, testChannelID), + host.NextSequenceRecvKey(testPortID, testChannelID), sdk.Uint64ToBigEndian(nextSeqRecv), ) }, @@ -451,7 +451,7 @@ func (suite *LocalhostTestSuite) TestVerifyNextSeqRecv() { clientState: types.NewClientState("chainID", clientHeight), malleate: func() { suite.store.Set( - host.KeyNextSequenceRecv(testPortID, testChannelID), + host.NextSequenceRecvKey(testPortID, testChannelID), sdk.Uint64ToBigEndian(3), ) }, diff --git a/x/ibc/testing/chain.go b/x/ibc/testing/chain.go index f43c4d267..5886695ef 100644 --- a/x/ibc/testing/chain.go +++ b/x/ibc/testing/chain.go @@ -242,7 +242,7 @@ func (chain *TestChain) QueryClientStateProof(clientID string) (exported.ClientS clientState, found := chain.App.IBCKeeper.ClientKeeper.GetClientState(chain.GetContext(), clientID) require.True(chain.t, found) - clientKey := host.FullKeyClientPath(clientID, host.KeyClientState()) + clientKey := host.FullClientStateKey(clientID) proofClient, _ := chain.QueryProof(clientKey) return clientState, proofClient @@ -254,7 +254,7 @@ func (chain *TestChain) QueryConsensusStateProof(clientID string) ([]byte, clien clientState := chain.GetClientState(clientID) consensusHeight := clientState.GetLatestHeight().(clienttypes.Height) - consensusKey := host.FullKeyClientPath(clientID, host.KeyConsensusState(consensusHeight)) + consensusKey := host.FullConsensusStateKey(clientID, consensusHeight) proofConsensus, _ := chain.QueryProof(consensusKey) return proofConsensus, consensusHeight @@ -645,7 +645,7 @@ func (chain *TestChain) ConnectionOpenTry( ) error { counterpartyClient, proofClient := counterparty.QueryClientStateProof(counterpartyConnection.ClientID) - connectionKey := host.KeyConnection(counterpartyConnection.ID) + connectionKey := host.ConnectionKey(counterpartyConnection.ID) proofInit, proofHeight := counterparty.QueryProof(connectionKey) proofConsensus, consensusHeight := counterparty.QueryConsensusStateProof(counterpartyConnection.ClientID) @@ -668,7 +668,7 @@ func (chain *TestChain) ConnectionOpenAck( ) error { counterpartyClient, proofClient := counterparty.QueryClientStateProof(counterpartyConnection.ClientID) - connectionKey := host.KeyConnection(counterpartyConnection.ID) + connectionKey := host.ConnectionKey(counterpartyConnection.ID) proofTry, proofHeight := counterparty.QueryProof(connectionKey) proofConsensus, consensusHeight := counterparty.QueryConsensusStateProof(counterpartyConnection.ClientID) @@ -688,7 +688,7 @@ func (chain *TestChain) ConnectionOpenConfirm( counterparty *TestChain, connection, counterpartyConnection *TestConnection, ) error { - connectionKey := host.KeyConnection(counterpartyConnection.ID) + connectionKey := host.ConnectionKey(counterpartyConnection.ID) proof, height := counterparty.QueryProof(connectionKey) msg := connectiontypes.NewMsgConnectionOpenConfirm( @@ -788,7 +788,7 @@ func (chain *TestChain) ChanOpenTry( order channeltypes.Order, connectionID string, ) error { - proof, height := counterparty.QueryProof(host.KeyChannel(counterpartyCh.PortID, counterpartyCh.ID)) + proof, height := counterparty.QueryProof(host.ChannelKey(counterpartyCh.PortID, counterpartyCh.ID)) msg := channeltypes.NewMsgChannelOpenTry( ch.PortID, ch.ID, ch.ID, // testing doesn't use flexible selection @@ -806,7 +806,7 @@ func (chain *TestChain) ChanOpenAck( counterparty *TestChain, ch, counterpartyCh TestChannel, ) error { - proof, height := counterparty.QueryProof(host.KeyChannel(counterpartyCh.PortID, counterpartyCh.ID)) + proof, height := counterparty.QueryProof(host.ChannelKey(counterpartyCh.PortID, counterpartyCh.ID)) msg := channeltypes.NewMsgChannelOpenAck( ch.PortID, ch.ID, @@ -822,7 +822,7 @@ func (chain *TestChain) ChanOpenConfirm( counterparty *TestChain, ch, counterpartyCh TestChannel, ) error { - proof, height := counterparty.QueryProof(host.KeyChannel(counterpartyCh.PortID, counterpartyCh.ID)) + proof, height := counterparty.QueryProof(host.ChannelKey(counterpartyCh.PortID, counterpartyCh.ID)) msg := channeltypes.NewMsgChannelOpenConfirm( ch.PortID, ch.ID, diff --git a/x/ibc/testing/coordinator.go b/x/ibc/testing/coordinator.go index 7ead436ab..ce5c8607f 100644 --- a/x/ibc/testing/coordinator.go +++ b/x/ibc/testing/coordinator.go @@ -238,7 +238,7 @@ func (coord *Coordinator) RecvPacket( packet channeltypes.Packet, ) error { // get proof of packet commitment on source - packetKey := host.KeyPacketCommitment(packet.GetSourcePort(), packet.GetSourceChannel(), packet.GetSequence()) + packetKey := host.PacketCommitmentKey(packet.GetSourcePort(), packet.GetSourceChannel(), packet.GetSequence()) proof, proofHeight := source.QueryProof(packetKey) recvMsg := channeltypes.NewMsgRecvPacket(packet, proof, proofHeight, counterparty.SenderAccount.GetAddress()) @@ -277,7 +277,7 @@ func (coord *Coordinator) AcknowledgePacket( packet channeltypes.Packet, ack []byte, ) error { // get proof of acknowledgement on counterparty - packetKey := host.KeyPacketAcknowledgement(packet.GetDestPort(), packet.GetDestChannel(), packet.GetSequence()) + packetKey := host.PacketAcknowledgementKey(packet.GetDestPort(), packet.GetDestChannel(), packet.GetSequence()) proof, proofHeight := counterparty.QueryProof(packetKey) ackMsg := channeltypes.NewMsgAcknowledgement(packet, ack, proof, proofHeight, source.SenderAccount.GetAddress()) diff --git a/x/ibc/testing/solomachine.go b/x/ibc/testing/solomachine.go index 0d3b35811..03fe887b8 100644 --- a/x/ibc/testing/solomachine.go +++ b/x/ibc/testing/solomachine.go @@ -251,8 +251,7 @@ func (solo *Solomachine) GenerateSignature(signBytes []byte) []byte { // GetClientStatePath returns the commitment path for the client state. func (solo *Solomachine) GetClientStatePath(counterpartyClientIdentifier string) commitmenttypes.MerklePath { - clientPrefixedPath := commitmenttypes.NewMerklePath("clients/" + counterpartyClientIdentifier + "/" + host.ClientStatePath()) - path, err := commitmenttypes.ApplyPrefix(prefix, clientPrefixedPath) + path, err := commitmenttypes.ApplyPrefix(prefix, commitmenttypes.NewMerklePath(host.FullClientStatePath(counterpartyClientIdentifier))) require.NoError(solo.t, err) return path @@ -260,8 +259,7 @@ func (solo *Solomachine) GetClientStatePath(counterpartyClientIdentifier string) // GetConsensusStatePath returns the commitment path for the consensus state. func (solo *Solomachine) GetConsensusStatePath(counterpartyClientIdentifier string, consensusHeight exported.Height) commitmenttypes.MerklePath { - clientPrefixedPath := commitmenttypes.NewMerklePath("clients/" + counterpartyClientIdentifier + "/" + host.ConsensusStatePath(consensusHeight)) - path, err := commitmenttypes.ApplyPrefix(prefix, clientPrefixedPath) + path, err := commitmenttypes.ApplyPrefix(prefix, commitmenttypes.NewMerklePath(host.FullConsensusStatePath(counterpartyClientIdentifier, consensusHeight))) require.NoError(solo.t, err) return path From bcdd6ee15c08a742c346a6cf7e8fc80ae17c75b0 Mon Sep 17 00:00:00 2001 From: Federico Kunze <31522760+fedekunze@users.noreply.github.com> Date: Tue, 10 Nov 2020 18:50:53 +0100 Subject: [PATCH 19/24] ibc: fix grpc gateway routes (#7881) --- client/docs/swagger-ui/swagger.yaml | 50 ++--- .../ibc/applications/transfer/v1/query.proto | 6 +- proto/ibc/core/channel/v1/query.proto | 26 +-- proto/ibc/core/client/v1/query.proto | 8 +- proto/ibc/core/connection/v1/query.proto | 10 +- x/ibc/applications/transfer/types/query.pb.go | 69 ++++--- .../transfer/types/query.pb.gw.go | 6 +- x/ibc/core/02-client/types/query.pb.go | 96 ++++----- x/ibc/core/02-client/types/query.pb.gw.go | 8 +- x/ibc/core/03-connection/types/query.pb.go | 114 +++++------ x/ibc/core/03-connection/types/query.pb.gw.go | 10 +- x/ibc/core/04-channel/types/query.pb.go | 188 +++++++++--------- x/ibc/core/04-channel/types/query.pb.gw.go | 26 +-- .../core/23-commitment/types/commitment.pb.go | 2 + 14 files changed, 310 insertions(+), 309 deletions(-) diff --git a/client/docs/swagger-ui/swagger.yaml b/client/docs/swagger-ui/swagger.yaml index 06500d754..f8a2cccb9 100644 --- a/client/docs/swagger-ui/swagger.yaml +++ b/client/docs/swagger-ui/swagger.yaml @@ -15760,7 +15760,7 @@ paths: } tags: - Query - /ibc/channel/v1beta1/channels: + /ibc/core/channel/v1beta1/channels: get: summary: Channels queries all the IBC channels of a chain. operationId: Channels @@ -16146,7 +16146,7 @@ paths: type: boolean tags: - Query - '/ibc/channel/v1beta1/channels/{channel_id}/ports/{port_id}': + '/ibc/core/channel/v1beta1/channels/{channel_id}/ports/{port_id}': get: summary: Channel queries an IBC Channel. operationId: Channel @@ -16471,7 +16471,7 @@ paths: type: string tags: - Query - '/ibc/channel/v1beta1/channels/{channel_id}/ports/{port_id}/client_state': + '/ibc/core/channel/v1beta1/channels/{channel_id}/ports/{port_id}/client_state': get: summary: >- ChannelClientState queries for the client state for the channel @@ -16909,7 +16909,7 @@ paths: type: string tags: - Query - '/ibc/channel/v1beta1/channels/{channel_id}/ports/{port_id}/consensus_state/version/{version_number}/height/{version_height}': + '/ibc/core/channel/v1beta1/channels/{channel_id}/ports/{port_id}/consensus_state/version/{version_number}/height/{version_height}': get: summary: |- ChannelConsensusState queries for the consensus state for the channel @@ -17344,7 +17344,7 @@ paths: format: uint64 tags: - Query - '/ibc/channel/v1beta1/channels/{channel_id}/ports/{port_id}/next_sequence': + '/ibc/core/channel/v1beta1/channels/{channel_id}/ports/{port_id}/next_sequence': get: summary: >- NextSequenceReceive returns the next receive sequence for a given @@ -17596,7 +17596,7 @@ paths: type: string tags: - Query - '/ibc/channel/v1beta1/channels/{channel_id}/ports/{port_id}/packet_acknowledgements': + '/ibc/core/channel/v1beta1/channels/{channel_id}/ports/{port_id}/packet_acknowledgements': get: summary: >- PacketAcknowledgements returns all the packet acknowledgements @@ -17945,7 +17945,7 @@ paths: type: boolean tags: - Query - '/ibc/channel/v1beta1/channels/{channel_id}/ports/{port_id}/packet_acks/{sequence}': + '/ibc/core/channel/v1beta1/channels/{channel_id}/ports/{port_id}/packet_acks/{sequence}': get: summary: PacketAcknowledgement queries a stored packet acknowledgement hash. operationId: PacketAcknowledgement @@ -18205,7 +18205,7 @@ paths: format: uint64 tags: - Query - '/ibc/channel/v1beta1/channels/{channel_id}/ports/{port_id}/packet_commitments': + '/ibc/core/channel/v1beta1/channels/{channel_id}/ports/{port_id}/packet_commitments': get: summary: |- PacketCommitments returns all the packet commitments hashes associated @@ -18552,7 +18552,7 @@ paths: type: boolean tags: - Query - '/ibc/channel/v1beta1/channels/{channel_id}/ports/{port_id}/packet_commitments/{packet_ack_sequences}/unreceived_acks': + '/ibc/core/channel/v1beta1/channels/{channel_id}/ports/{port_id}/packet_commitments/{packet_ack_sequences}/unreceived_acks': get: summary: >- UnreceivedAcks returns all the unreceived IBC acknowledgements @@ -18814,7 +18814,7 @@ paths: minItems: 1 tags: - Query - '/ibc/channel/v1beta1/channels/{channel_id}/ports/{port_id}/packet_commitments/{packet_commitment_sequences}/unreceived_packets': + '/ibc/core/channel/v1beta1/channels/{channel_id}/ports/{port_id}/packet_commitments/{packet_commitment_sequences}/unreceived_packets': get: summary: >- UnreceivedPackets returns all the unreceived IBC packets associated with @@ -19076,7 +19076,7 @@ paths: minItems: 1 tags: - Query - '/ibc/channel/v1beta1/channels/{channel_id}/ports/{port_id}/packet_commitments/{sequence}': + '/ibc/core/channel/v1beta1/channels/{channel_id}/ports/{port_id}/packet_commitments/{sequence}': get: summary: PacketCommitment queries a stored packet commitment hash. operationId: PacketCommitment @@ -19337,7 +19337,7 @@ paths: format: uint64 tags: - Query - '/ibc/channel/v1beta1/channels/{channel_id}/ports/{port_id}/packet_receipts/{sequence}': + '/ibc/core/channel/v1beta1/channels/{channel_id}/ports/{port_id}/packet_receipts/{sequence}': get: summary: >- PacketReceipt queries if a given packet sequence has been received on @@ -19599,7 +19599,7 @@ paths: format: uint64 tags: - Query - '/ibc/channel/v1beta1/connections/{connection}/channels': + '/ibc/core/channel/v1beta1/connections/{connection}/channels': get: summary: |- ConnectionChannels queries all the channels associated with a connection @@ -19992,7 +19992,7 @@ paths: type: boolean tags: - Query - /ibc/client/v1beta1/client_states: + /ibc/core/client/v1beta1/client_states: get: summary: ClientStates queries all the IBC light clients of a chain. operationId: ClientStates @@ -20465,7 +20465,7 @@ paths: type: boolean tags: - Query - '/ibc/client/v1beta1/client_states/{client_id}': + '/ibc/core/client/v1beta1/client_states/{client_id}': get: summary: ClientState queries an IBC light client. operationId: ClientState @@ -20883,7 +20883,7 @@ paths: type: string tags: - Query - '/ibc/client/v1beta1/consensus_states/{client_id}': + '/ibc/core/client/v1beta1/consensus_states/{client_id}': get: summary: |- ConsensusStates queries all the consensus state associated with a given @@ -21383,7 +21383,7 @@ paths: type: boolean tags: - Query - '/ibc/client/v1beta1/consensus_states/{client_id}/version/{version_number}/height/{version_height}': + '/ibc/core/client/v1beta1/consensus_states/{client_id}/version/{version_number}/height/{version_height}': get: summary: >- ConsensusState queries a consensus state associated with a client state @@ -21825,7 +21825,7 @@ paths: type: boolean tags: - Query - '/ibc/connection/v1beta1/client_connections/{client_id}': + '/ibc/core/connection/v1beta1/client_connections/{client_id}': get: summary: |- ClientConnections queries the connection paths associated with a client @@ -22073,7 +22073,7 @@ paths: type: string tags: - Query - /ibc/connection/v1beta1/connections: + /ibc/core/connection/v1beta1/connections: get: summary: Connections queries all the IBC connections of a chain. operationId: Connections @@ -22457,7 +22457,7 @@ paths: type: boolean tags: - Query - '/ibc/connection/v1beta1/connections/{connection_id}': + '/ibc/core/connection/v1beta1/connections/{connection_id}': get: summary: Connection queries an IBC connection end. operationId: Connection @@ -22777,7 +22777,7 @@ paths: type: string tags: - Query - '/ibc/connection/v1beta1/connections/{connection_id}/client_state': + '/ibc/core/connection/v1beta1/connections/{connection_id}/client_state': get: summary: |- ConnectionClientState queries the client state associated with the @@ -23208,7 +23208,7 @@ paths: type: string tags: - Query - '/ibc/connection/v1beta1/connections/{connection_id}/consensus_state/version/{version_number}/height/{version_height}': + '/ibc/core/connection/v1beta1/connections/{connection_id}/consensus_state/version/{version_number}/height/{version_height}': get: summary: |- ConnectionConsensusState queries the consensus state associated with the @@ -23636,7 +23636,7 @@ paths: format: uint64 tags: - Query - /ibc_transfer/v1beta1/denom_traces: + /ibc/applications/transfer/v1beta1/denom_traces: get: summary: DenomTraces queries all denomination traces. operationId: DenomTraces @@ -23761,7 +23761,7 @@ paths: type: boolean tags: - Query - '/ibc_transfer/v1beta1/denom_traces/{hash}': + '/ibc/applications/transfer/v1beta1/denom_traces/{hash}': get: summary: DenomTrace queries a denomination trace information. operationId: DenomTrace @@ -23822,7 +23822,7 @@ paths: type: string tags: - Query - /ibc_transfer/v1beta1/params: + /ibc/applications/transfer/v1beta1/params: get: summary: Params queries all parameters of the ibc-transfer module. operationId: IBCTransferParams diff --git a/proto/ibc/applications/transfer/v1/query.proto b/proto/ibc/applications/transfer/v1/query.proto index 98dd02f75..e9cbd02a3 100644 --- a/proto/ibc/applications/transfer/v1/query.proto +++ b/proto/ibc/applications/transfer/v1/query.proto @@ -12,17 +12,17 @@ option go_package = "github.com/cosmos/cosmos-sdk/x/ibc/applications/transfer/ty service Query { // DenomTrace queries a denomination trace information. rpc DenomTrace(QueryDenomTraceRequest) returns (QueryDenomTraceResponse) { - option (google.api.http).get = "/ibc_transfer/v1beta1/denom_traces/{hash}"; + option (google.api.http).get = "/ibc/applications/transfer/v1beta1/denom_traces/{hash}"; } // DenomTraces queries all denomination traces. rpc DenomTraces(QueryDenomTracesRequest) returns (QueryDenomTracesResponse) { - option (google.api.http).get = "/ibc_transfer/v1beta1/denom_traces"; + option (google.api.http).get = "/ibc/applications/transfer/v1beta1/denom_traces"; } // Params queries all parameters of the ibc-transfer module. rpc Params(QueryParamsRequest) returns (QueryParamsResponse) { - option (google.api.http).get = "/ibc_transfer/v1beta1/params"; + option (google.api.http).get = "/ibc/applications/transfer/v1beta1/params"; } } diff --git a/proto/ibc/core/channel/v1/query.proto b/proto/ibc/core/channel/v1/query.proto index dcff04f7f..90d2adaea 100644 --- a/proto/ibc/core/channel/v1/query.proto +++ b/proto/ibc/core/channel/v1/query.proto @@ -14,79 +14,79 @@ option go_package = "github.com/cosmos/cosmos-sdk/x/ibc/core/04-channel/types"; service Query { // Channel queries an IBC Channel. rpc Channel(QueryChannelRequest) returns (QueryChannelResponse) { - option (google.api.http).get = "/ibc/channel/v1beta1/channels/{channel_id}/ports/{port_id}"; + option (google.api.http).get = "/ibc/core/channel/v1beta1/channels/{channel_id}/ports/{port_id}"; } // Channels queries all the IBC channels of a chain. rpc Channels(QueryChannelsRequest) returns (QueryChannelsResponse) { - option (google.api.http).get = "/ibc/channel/v1beta1/channels"; + option (google.api.http).get = "/ibc/core/channel/v1beta1/channels"; } // ConnectionChannels queries all the channels associated with a connection // end. rpc ConnectionChannels(QueryConnectionChannelsRequest) returns (QueryConnectionChannelsResponse) { - option (google.api.http).get = "/ibc/channel/v1beta1/connections/{connection}/channels"; + option (google.api.http).get = "/ibc/core/channel/v1beta1/connections/{connection}/channels"; } // ChannelClientState queries for the client state for the channel associated // with the provided channel identifiers. rpc ChannelClientState(QueryChannelClientStateRequest) returns (QueryChannelClientStateResponse) { - option (google.api.http).get = "/ibc/channel/v1beta1/channels/{channel_id}/ports/{port_id}/client_state"; + option (google.api.http).get = "/ibc/core/channel/v1beta1/channels/{channel_id}/ports/{port_id}/client_state"; } // ChannelConsensusState queries for the consensus state for the channel // associated with the provided channel identifiers. rpc ChannelConsensusState(QueryChannelConsensusStateRequest) returns (QueryChannelConsensusStateResponse) { - option (google.api.http).get = "/ibc/channel/v1beta1/channels/{channel_id}/ports/{port_id}/consensus_state/version/" + option (google.api.http).get = "/ibc/core/channel/v1beta1/channels/{channel_id}/ports/{port_id}/consensus_state/version/" "{version_number}/height/{version_height}"; } // PacketCommitment queries a stored packet commitment hash. rpc PacketCommitment(QueryPacketCommitmentRequest) returns (QueryPacketCommitmentResponse) { option (google.api.http).get = - "/ibc/channel/v1beta1/channels/{channel_id}/ports/{port_id}/packet_commitments/{sequence}"; + "/ibc/core/channel/v1beta1/channels/{channel_id}/ports/{port_id}/packet_commitments/{sequence}"; } // PacketCommitments returns all the packet commitments hashes associated // with a channel. rpc PacketCommitments(QueryPacketCommitmentsRequest) returns (QueryPacketCommitmentsResponse) { - option (google.api.http).get = "/ibc/channel/v1beta1/channels/{channel_id}/ports/{port_id}/packet_commitments"; + option (google.api.http).get = "/ibc/core/channel/v1beta1/channels/{channel_id}/ports/{port_id}/packet_commitments"; } // PacketReceipt queries if a given packet sequence has been received on the queried chain rpc PacketReceipt(QueryPacketReceiptRequest) returns (QueryPacketReceiptResponse) { - option (google.api.http).get = "/ibc/channel/v1beta1/channels/{channel_id}/ports/{port_id}/packet_receipts/{sequence}"; + option (google.api.http).get = "/ibc/core/channel/v1beta1/channels/{channel_id}/ports/{port_id}/packet_receipts/{sequence}"; } // PacketAcknowledgement queries a stored packet acknowledgement hash. rpc PacketAcknowledgement(QueryPacketAcknowledgementRequest) returns (QueryPacketAcknowledgementResponse) { - option (google.api.http).get = "/ibc/channel/v1beta1/channels/{channel_id}/ports/{port_id}/packet_acks/{sequence}"; + option (google.api.http).get = "/ibc/core/channel/v1beta1/channels/{channel_id}/ports/{port_id}/packet_acks/{sequence}"; } // PacketAcknowledgements returns all the packet acknowledgements associated // with a channel. rpc PacketAcknowledgements(QueryPacketAcknowledgementsRequest) returns (QueryPacketAcknowledgementsResponse) { - option (google.api.http).get = "/ibc/channel/v1beta1/channels/{channel_id}/ports/{port_id}/packet_acknowledgements"; + option (google.api.http).get = "/ibc/core/channel/v1beta1/channels/{channel_id}/ports/{port_id}/packet_acknowledgements"; } // UnreceivedPackets returns all the unreceived IBC packets associated with a // channel and sequences. rpc UnreceivedPackets(QueryUnreceivedPacketsRequest) returns (QueryUnreceivedPacketsResponse) { - option (google.api.http).get = "/ibc/channel/v1beta1/channels/{channel_id}/ports/{port_id}/packet_commitments/" + option (google.api.http).get = "/ibc/core/channel/v1beta1/channels/{channel_id}/ports/{port_id}/packet_commitments/" "{packet_commitment_sequences}/unreceived_packets"; } // UnreceivedAcks returns all the unreceived IBC acknowledgements associated with a // channel and sequences. rpc UnreceivedAcks(QueryUnreceivedAcksRequest) returns (QueryUnreceivedAcksResponse) { - option (google.api.http).get = "/ibc/channel/v1beta1/channels/{channel_id}/ports/{port_id}/packet_commitments/" + option (google.api.http).get = "/ibc/core/channel/v1beta1/channels/{channel_id}/ports/{port_id}/packet_commitments/" "{packet_ack_sequences}/unreceived_acks"; } // NextSequenceReceive returns the next receive sequence for a given channel. rpc NextSequenceReceive(QueryNextSequenceReceiveRequest) returns (QueryNextSequenceReceiveResponse) { - option (google.api.http).get = "/ibc/channel/v1beta1/channels/{channel_id}/ports/{port_id}/next_sequence"; + option (google.api.http).get = "/ibc/core/channel/v1beta1/channels/{channel_id}/ports/{port_id}/next_sequence"; } } diff --git a/proto/ibc/core/client/v1/query.proto b/proto/ibc/core/client/v1/query.proto index a40fed843..db580a260 100644 --- a/proto/ibc/core/client/v1/query.proto +++ b/proto/ibc/core/client/v1/query.proto @@ -13,25 +13,25 @@ option go_package = "github.com/cosmos/cosmos-sdk/x/ibc/core/02-client/types"; service Query { // ClientState queries an IBC light client. rpc ClientState(QueryClientStateRequest) returns (QueryClientStateResponse) { - option (google.api.http).get = "/ibc/client/v1beta1/client_states/{client_id}"; + option (google.api.http).get = "/ibc/core/client/v1beta1/client_states/{client_id}"; } // ClientStates queries all the IBC light clients of a chain. rpc ClientStates(QueryClientStatesRequest) returns (QueryClientStatesResponse) { - option (google.api.http).get = "/ibc/client/v1beta1/client_states"; + option (google.api.http).get = "/ibc/core/client/v1beta1/client_states"; } // ConsensusState queries a consensus state associated with a client state at // a given height. rpc ConsensusState(QueryConsensusStateRequest) returns (QueryConsensusStateResponse) { - option (google.api.http).get = "/ibc/client/v1beta1/consensus_states/{client_id}/version/{version_number}/" + option (google.api.http).get = "/ibc/core/client/v1beta1/consensus_states/{client_id}/version/{version_number}/" "height/{version_height}"; } // ConsensusStates queries all the consensus state associated with a given // client. rpc ConsensusStates(QueryConsensusStatesRequest) returns (QueryConsensusStatesResponse) { - option (google.api.http).get = "/ibc/client/v1beta1/consensus_states/{client_id}"; + option (google.api.http).get = "/ibc/core/client/v1beta1/consensus_states/{client_id}"; } } diff --git a/proto/ibc/core/connection/v1/query.proto b/proto/ibc/core/connection/v1/query.proto index c2666ee28..9e5b06880 100644 --- a/proto/ibc/core/connection/v1/query.proto +++ b/proto/ibc/core/connection/v1/query.proto @@ -14,30 +14,30 @@ option go_package = "github.com/cosmos/cosmos-sdk/x/ibc/core/03-connection/types service Query { // Connection queries an IBC connection end. rpc Connection(QueryConnectionRequest) returns (QueryConnectionResponse) { - option (google.api.http).get = "/ibc/connection/v1beta1/connections/{connection_id}"; + option (google.api.http).get = "/ibc/core/connection/v1beta1/connections/{connection_id}"; } // Connections queries all the IBC connections of a chain. rpc Connections(QueryConnectionsRequest) returns (QueryConnectionsResponse) { - option (google.api.http).get = "/ibc/connection/v1beta1/connections"; + option (google.api.http).get = "/ibc/core/connection/v1beta1/connections"; } // ClientConnections queries the connection paths associated with a client // state. rpc ClientConnections(QueryClientConnectionsRequest) returns (QueryClientConnectionsResponse) { - option (google.api.http).get = "/ibc/connection/v1beta1/client_connections/{client_id}"; + option (google.api.http).get = "/ibc/core/connection/v1beta1/client_connections/{client_id}"; } // ConnectionClientState queries the client state associated with the // connection. rpc ConnectionClientState(QueryConnectionClientStateRequest) returns (QueryConnectionClientStateResponse) { - option (google.api.http).get = "/ibc/connection/v1beta1/connections/{connection_id}/client_state"; + option (google.api.http).get = "/ibc/core/connection/v1beta1/connections/{connection_id}/client_state"; } // ConnectionConsensusState queries the consensus state associated with the // connection. rpc ConnectionConsensusState(QueryConnectionConsensusStateRequest) returns (QueryConnectionConsensusStateResponse) { - option (google.api.http).get = "/ibc/connection/v1beta1/connections/{connection_id}/consensus_state/" + option (google.api.http).get = "/ibc/core/connection/v1beta1/connections/{connection_id}/consensus_state/" "version/{version_number}/height/{version_height}"; } } diff --git a/x/ibc/applications/transfer/types/query.pb.go b/x/ibc/applications/transfer/types/query.pb.go index 27e155632..ee069d350 100644 --- a/x/ibc/applications/transfer/types/query.pb.go +++ b/x/ibc/applications/transfer/types/query.pb.go @@ -324,41 +324,40 @@ func init() { } var fileDescriptor_a638e2800a01538c = []byte{ - // 532 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x94, 0x54, 0x4f, 0x6f, 0xd3, 0x30, - 0x14, 0xaf, 0x37, 0xa8, 0xc4, 0x2b, 0xe2, 0x60, 0x26, 0xa8, 0xa2, 0x2a, 0x9b, 0xa2, 0x0a, 0xca, - 0x06, 0x36, 0x19, 0x7f, 0x4e, 0x88, 0xc3, 0x84, 0x40, 0xdc, 0x46, 0xe1, 0x80, 0xe0, 0x30, 0x39, - 0xa9, 0x49, 0x23, 0xd6, 0x38, 0x8b, 0xdd, 0x8a, 0x09, 0x71, 0xe1, 0x13, 0x20, 0xed, 0x4b, 0x20, - 0xc4, 0x87, 0xe0, 0xb8, 0xe3, 0x24, 0x2e, 0x9c, 0x00, 0xb5, 0x7c, 0x07, 0xae, 0x28, 0xb6, 0xb3, - 0xa6, 0xea, 0xe8, 0x96, 0x53, 0xad, 0xd7, 0xf7, 0x7b, 0xbf, 0x3f, 0xcf, 0x31, 0x74, 0xe2, 0x20, - 0xa4, 0x2c, 0x4d, 0x77, 0xe3, 0x90, 0xa9, 0x58, 0x24, 0x92, 0xaa, 0x8c, 0x25, 0xf2, 0x0d, 0xcf, - 0xe8, 0xc8, 0xa7, 0x7b, 0x43, 0x9e, 0xed, 0x93, 0x34, 0x13, 0x4a, 0xe0, 0x56, 0x1c, 0x84, 0xa4, - 0xdc, 0x49, 0x8a, 0x4e, 0x32, 0xf2, 0x9d, 0x95, 0x48, 0x44, 0x42, 0x37, 0xd2, 0xfc, 0x64, 0x30, - 0xce, 0x7a, 0x28, 0xe4, 0x40, 0x48, 0x1a, 0x30, 0xc9, 0xcd, 0x30, 0x3a, 0xf2, 0x03, 0xae, 0x98, - 0x4f, 0x53, 0x16, 0xc5, 0x89, 0x1e, 0x64, 0x7b, 0x37, 0x16, 0x2a, 0x39, 0xe6, 0x32, 0xcd, 0xad, - 0x48, 0x88, 0x68, 0x97, 0x53, 0x96, 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ef, 0x32, 0x9c, 0xd7, - 0x53, 0xf1, 0x57, 0x04, 0x30, 0x75, 0x8a, 0xef, 0x2e, 0x1e, 0x73, 0xf2, 0xcd, 0x72, 0xee, 0x55, - 0x44, 0x19, 0x0f, 0x9e, 0xff, 0xf1, 0xfb, 0x9f, 0x83, 0xa5, 0x0d, 0x7c, 0x83, 0xc6, 0x41, 0xb8, - 0x53, 0xba, 0xf1, 0xe6, 0x2b, 0x29, 0xaf, 0x8c, 0xbe, 0xcf, 0xaf, 0xeb, 0x07, 0xfc, 0x19, 0x41, - 0xa3, 0xb4, 0x61, 0x5c, 0x8d, 0xb9, 0x08, 0xd5, 0xb9, 0x5f, 0x15, 0x66, 0x15, 0xaf, 0x6b, 0xc5, - 0x6d, 0xec, 0x9d, 0xae, 0x18, 0x1f, 0x20, 0xa8, 0x9b, 0xd8, 0xf1, 0xed, 0x33, 0xd0, 0xcd, 0x6c, - 0xdd, 0xf1, 0x2b, 0x20, 0xac, 0xb6, 0xb6, 0xd6, 0xe6, 0xe2, 0xd6, 0xc9, 0xda, 0xcc, 0xe6, 0xb7, - 0x5e, 0x1e, 0x8e, 0x5d, 0x74, 0x34, 0x76, 0xd1, 0xef, 0xb1, 0x8b, 0x3e, 0x4d, 0xdc, 0xda, 0xd1, - 0xc4, 0xad, 0xfd, 0x98, 0xb8, 0xb5, 0x57, 0x0f, 0xa3, 0x58, 0xf5, 0x87, 0x01, 0x09, 0xc5, 0x80, - 0xda, 0xa7, 0xcb, 0xfc, 0xdc, 0x92, 0xbd, 0xb7, 0xf4, 0x1d, 0xfd, 0xff, 0x13, 0xa5, 0xf6, 0x53, - 0x2e, 0x83, 0xba, 0x7e, 0x7f, 0xee, 0xfc, 0x0b, 0x00, 0x00, 0xff, 0xff, 0x19, 0x46, 0xdf, 0x94, - 0x56, 0x05, 0x00, 0x00, + // 528 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x94, 0x54, 0x3f, 0x6f, 0xd3, 0x40, + 0x14, 0xcf, 0x95, 0x12, 0x89, 0x17, 0xc4, 0x70, 0x54, 0x10, 0x59, 0x95, 0x5b, 0x59, 0x08, 0x02, + 0x85, 0x3b, 0x5c, 0xa0, 0x30, 0xa0, 0x0e, 0x15, 0x02, 0xb1, 0x95, 0xc0, 0x80, 0x60, 0x40, 0x67, + 0xe7, 0x70, 0x2c, 0x1a, 0x9f, 0xeb, 0xbb, 0x44, 0x54, 0x88, 0x85, 0x4f, 0x80, 0xc4, 0x8e, 0x98, + 0xd9, 0x19, 0xd8, 0x18, 0x3b, 0x56, 0x62, 0x61, 0x02, 0x94, 0xf0, 0x41, 0x90, 0xef, 0xce, 0x8d, + 0xa3, 0x20, 0x13, 0x4f, 0x39, 0x5d, 0xde, 0xef, 0xfd, 0xfe, 0xbc, 0xe7, 0x83, 0x4e, 0x1c, 0x84, + 0x94, 0xa5, 0xe9, 0x5e, 0x1c, 0x32, 0x15, 0x8b, 0x44, 0x52, 0x95, 0xb1, 0x44, 0xbe, 0xe4, 0x19, + 0x1d, 0xf9, 0x74, 0x7f, 0xc8, 0xb3, 0x03, 0x92, 0x66, 0x42, 0x09, 0xbc, 0x1a, 0x07, 0x21, 0x29, + 0x57, 0x92, 0xa2, 0x92, 0x8c, 0x7c, 0x67, 0x25, 0x12, 0x91, 0xd0, 0x85, 0x34, 0x3f, 0x19, 0x8c, + 0x73, 0x25, 0x14, 0x72, 0x20, 0x24, 0x0d, 0x98, 0xe4, 0xa6, 0x19, 0x1d, 0xf9, 0x01, 0x57, 0xcc, + 0xa7, 0x29, 0x8b, 0xe2, 0x44, 0x37, 0xb2, 0xb5, 0x1b, 0x95, 0x4a, 0x8e, 0xb9, 0x4c, 0xf1, 0x6a, + 0x24, 0x44, 0xb4, 0xc7, 0x29, 0x4b, 0x63, 0xca, 0x92, 0x44, 0x28, 0x2b, 0x49, 0xff, 0xeb, 0x5d, + 0x85, 0x73, 0x8f, 0x72, 0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, 0xff, 0xde, 0x2c, 0xe7, 0x56, + 0x4d, 0x94, 0xf1, 0xe0, 0x6d, 0xbf, 0xfb, 0xfe, 0xe7, 0xc3, 0xd2, 0x1d, 0xbc, 0x45, 0xab, 0xd6, + 0xdf, 0x7c, 0x32, 0xe5, 0xf9, 0xd1, 0x37, 0xf9, 0xee, 0xbe, 0xc5, 0x5f, 0x10, 0xb4, 0x4a, 0xe3, + 0xc6, 0xf5, 0x64, 0x14, 0x09, 0x3b, 0x5b, 0x75, 0x61, 0x56, 0xfe, 0x6d, 0x2d, 0xdf, 0xc7, 0xb4, + 0xa6, 0x7c, 0xfc, 0x09, 0x41, 0xd3, 0x0c, 0x04, 0x5f, 0x5f, 0x80, 0x7b, 0x66, 0x1f, 0x1c, 0xbf, + 0x06, 0xc2, 0x0a, 0xf5, 0xb5, 0xd0, 0x0d, 0x7c, 0x79, 0x01, 0xa1, 0x66, 0x41, 0x76, 0x9e, 0x1e, + 0x8e, 0x5d, 0x74, 0x34, 0x76, 0xd1, 0xef, 0xb1, 0x8b, 0xde, 0x4f, 0xdc, 0xc6, 0xd1, 0xc4, 0x6d, + 0xfc, 0x98, 0xb8, 0x8d, 0x67, 0xdb, 0x51, 0xac, 0xfa, 0xc3, 0x80, 0x84, 0x62, 0x40, 0xed, 0x0b, + 0x67, 0x7e, 0xae, 0xc9, 0xde, 0x2b, 0xfa, 0xba, 0x82, 0x42, 0x1d, 0xa4, 0x5c, 0x06, 0x4d, 0xfd, + 0x4c, 0xdd, 0xf8, 0x1b, 0x00, 0x00, 0xff, 0xff, 0xb2, 0x7f, 0xfe, 0xbd, 0x7d, 0x05, 0x00, 0x00, } // Reference imports to suppress errors if they are not otherwise used. diff --git a/x/ibc/applications/transfer/types/query.pb.gw.go b/x/ibc/applications/transfer/types/query.pb.gw.go index 0e1dfd25c..99a7f1906 100644 --- a/x/ibc/applications/transfer/types/query.pb.gw.go +++ b/x/ibc/applications/transfer/types/query.pb.gw.go @@ -310,11 +310,11 @@ func RegisterQueryHandlerClient(ctx context.Context, mux *runtime.ServeMux, clie } var ( - pattern_Query_DenomTrace_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 1, 0, 4, 1, 5, 3}, []string{"ibc_transfer", "v1beta1", "denom_traces", "hash"}, "", runtime.AssumeColonVerbOpt(true))) + pattern_Query_DenomTrace_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3, 2, 4, 1, 0, 4, 1, 5, 5}, []string{"ibc", "applications", "transfer", "v1beta1", "denom_traces", "hash"}, "", runtime.AssumeColonVerbOpt(true))) - pattern_Query_DenomTraces_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2}, []string{"ibc_transfer", "v1beta1", "denom_traces"}, "", runtime.AssumeColonVerbOpt(true))) + pattern_Query_DenomTraces_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3, 2, 4}, []string{"ibc", "applications", "transfer", "v1beta1", "denom_traces"}, "", runtime.AssumeColonVerbOpt(true))) - pattern_Query_Params_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2}, []string{"ibc_transfer", "v1beta1", "params"}, "", runtime.AssumeColonVerbOpt(true))) + pattern_Query_Params_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3, 2, 4}, []string{"ibc", "applications", "transfer", "v1beta1", "params"}, "", runtime.AssumeColonVerbOpt(true))) ) var ( diff --git a/x/ibc/core/02-client/types/query.pb.go b/x/ibc/core/02-client/types/query.pb.go index fb91ead13..3e250c9ea 100644 --- a/x/ibc/core/02-client/types/query.pb.go +++ b/x/ibc/core/02-client/types/query.pb.go @@ -514,54 +514,54 @@ func init() { func init() { proto.RegisterFile("ibc/core/client/v1/query.proto", fileDescriptor_dc42cdfd1d52d76e) } var fileDescriptor_dc42cdfd1d52d76e = []byte{ - // 747 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xb4, 0x56, 0x4f, 0x4f, 0x13, 0x41, - 0x14, 0xef, 0xf0, 0xc7, 0xc0, 0xb4, 0x80, 0x99, 0x90, 0x58, 0x16, 0x52, 0x6a, 0x89, 0x5a, 0x94, - 0xce, 0xd0, 0x1a, 0xc5, 0x8b, 0x07, 0x21, 0x41, 0xb9, 0x10, 0x59, 0x0f, 0x26, 0x26, 0x86, 0xec, - 0x6e, 0x87, 0xed, 0x44, 0xd8, 0x29, 0x9d, 0x69, 0x23, 0x21, 0x5c, 0xf8, 0x04, 0x26, 0x26, 0x5e, - 0xfd, 0x02, 0x86, 0x93, 0x89, 0xdf, 0xc0, 0x70, 0x24, 0x7a, 0xf1, 0x60, 0x8c, 0x01, 0x3f, 0x88, - 0xe9, 0xcc, 0x2c, 0xdd, 0x85, 0x25, 0xac, 0x46, 0x4f, 0x3b, 0xf3, 0xfe, 0xfe, 0xde, 0xef, 0xbd, - 0x79, 0x59, 0x58, 0x60, 0xae, 0x47, 0x3c, 0xde, 0xa2, 0xc4, 0xdb, 0x64, 0x34, 0x90, 0xa4, 0x53, - 0x25, 0xdb, 0x6d, 0xda, 0xda, 0xc1, 0xcd, 0x16, 0x97, 0x1c, 0x21, 0xe6, 0x7a, 0xb8, 0xab, 0xc7, - 0x5a, 0x8f, 0x3b, 0x55, 0xeb, 0xb6, 0xc7, 0xc5, 0x16, 0x17, 0xc4, 0x75, 0x04, 0xd5, 0xc6, 0xa4, - 0x53, 0x75, 0xa9, 0x74, 0xaa, 0xa4, 0xe9, 0xf8, 0x2c, 0x70, 0x24, 0xe3, 0x81, 0xf6, 0xb7, 0xa6, - 0x13, 0xe2, 0x9b, 0x48, 0xda, 0x60, 0xc2, 0xe7, 0xdc, 0xdf, 0xa4, 0x44, 0xdd, 0xdc, 0xf6, 0x06, - 0x71, 0x02, 0x93, 0xdb, 0x9a, 0x32, 0x2a, 0x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xbf, - 0x9c, 0xad, 0xcd, 0x26, 0xd5, 0xb1, 0x52, 0xa7, 0x81, 0x64, 0x1b, 0x8c, 0xd6, 0xa3, 0xfc, 0xe6, - 0x22, 0x5c, 0x09, 0xf4, 0x38, 0x86, 0xba, 0x4f, 0xa1, 0xbe, 0x75, 0x29, 0x6a, 0x0d, 0x26, 0x06, - 0xfb, 0x03, 0x80, 0x96, 0x86, 0xdd, 0x55, 0x05, 0xa2, 0x2d, 0x52, 0xcf, 0x01, 0xba, 0x01, 0x47, - 0x3b, 0xb4, 0x25, 0x18, 0x0f, 0xd6, 0x83, 0xf6, 0x96, 0x4b, 0x5b, 0x0a, 0xc8, 0x80, 0x3d, 0x62, - 0xa4, 0xab, 0x4a, 0x18, 0x35, 0x8b, 0x34, 0xb1, 0x67, 0xa6, 0x9b, 0x84, 0x66, 0xe0, 0xc8, 0x66, - 0xb7, 0x36, 0x19, 0x5a, 0x0d, 0x14, 0x41, 0x79, 0xc8, 0xce, 0x69, 0xa1, 0xe9, 0xe4, 0x27, 0x00, - 0x27, 0x13, 0xe1, 0x1a, 0x9e, 0x1f, 0xc2, 0x31, 0x2f, 0xd4, 0xa4, 0x18, 0xc0, 0x51, 0x2f, 0x16, - 0xe6, 0x7f, 0xce, 0xe0, 0x7e, 0x32, 0x72, 0x91, 0x8a, 0xe9, 0xe5, 0x84, 0x76, 0xff, 0xcd, 0x90, - 0x7e, 0x06, 0x70, 0x2a, 0x19, 0x84, 0xe1, 0xef, 0x25, 0xbc, 0x7a, 0x86, 0xbf, 0x70, 0x54, 0xe7, - 0x92, 0xca, 0x8d, 0x87, 0x79, 0xce, 0x64, 0x23, 0x46, 0xc0, 0x58, 0x9c, 0xde, 0x7f, 0x37, 0xb6, - 0xb5, 0x2f, 0x83, 0x70, 0x50, 0x15, 0x82, 0xde, 0x03, 0x98, 0x8d, 0xbc, 0x13, 0x74, 0x27, 0x09, - 0xe7, 0x05, 0x6b, 0xce, 0x9a, 0x4b, 0x67, 0xac, 0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- 0x00, 0xff, 0xff, 0x09, 0x8e, 0x83, 0x3d, 0xbb, 0x08, 0x00, 0x00, + // 746 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xb4, 0x56, 0x4d, 0x6b, 0x13, 0x4f, + 0x18, 0xcf, 0xf4, 0xe5, 0x4f, 0x3b, 0x49, 0xdb, 0x3f, 0x43, 0xc1, 0x74, 0x5b, 0xb6, 0x21, 0x62, + 0x8d, 0xda, 0xce, 0x34, 0xf1, 0xa5, 0x20, 0xf4, 0x60, 0x0b, 0xd5, 0x5e, 0x8a, 0x5d, 0x0f, 0x82, + 0x20, 0x65, 0x77, 0x33, 0xd9, 0x2c, 0xb6, 0x3b, 0x69, 0x66, 0x12, 0x2c, 0xa5, 0x97, 0x7e, 0x02, + 0xc1, 0xa3, 0x57, 0x8f, 0xe2, 0x45, 0xc1, 0x6f, 0x20, 0x3d, 0x16, 0xbc, 0x78, 0x12, 0x6d, 0xc5, + 0xcf, 0x21, 0x3b, 0x33, 0xdb, 0xec, 0x36, 0x5b, 0x5c, 0x8a, 0x9e, 0xb2, 0xfb, 0xbc, 0xfe, 0x9e, + 0xdf, 0xef, 0xd9, 0x87, 0x40, 0xd3, 0x77, 0x5c, 0xe2, 0xb2, 0x36, 0x25, 0xee, 0xb6, 0x4f, 0x03, + 0x41, 0xba, 0x55, 0xb2, 0xdb, 0xa1, 0xed, 0x3d, 0xdc, 0x6a, 0x33, 0xc1, 0x10, 0xf2, 0x1d, 0x17, + 0x87, 0x7e, 0xac, 0xfc, 0xb8, 0x5b, 0x35, 0x6e, 0xba, 0x8c, 0xef, 0x30, 0x4e, 0x1c, 0x9b, 0x53, + 0x15, 0x4c, 0xba, 0x55, 0x87, 0x0a, 0xbb, 0x4a, 0x5a, 0xb6, 0xe7, 0x07, 0xb6, 0xf0, 0x59, 0xa0, + 0xf2, 0x8d, 0xd9, 0x94, 0xfa, 0xba, 0x92, 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56, 0x2c, + 0xb3, 0xfc, 0x11, 0xc0, 0xa9, 0x94, 0x26, 0x9a, 0x95, 0x0d, 0x38, 0x16, 0x67, 0x85, 0x17, 0x41, + 0x69, 0xb0, 0x92, 0xaf, 0xdd, 0x48, 0x9b, 0x63, 0xbd, 0x4e, 0x03, 0xe1, 0x37, 0x7c, 0x5a, 0x8f, + 0xf3, 0x5b, 0x88, 0x71, 0xc5, 0xd1, 0xc3, 0x04, 0xea, 0x01, 0x89, 0xfa, 0xfa, 0x1f, 0x51, 0x2b, + 0x30, 0x09, 0xd8, 0xef, 0x00, 0x34, 0x14, 0xec, 0xd0, 0x15, 0xf0, 0x0e, 0xcf, 0xbc, 0x07, 0xe8, + 0x1a, 0x1c, 0xef, 0xd2, 0x36, 0xf7, 0x59, 0xb0, 0x15, 0x74, 0x76, 0x1c, 0xda, 0x96, 0x40, 0x86, + 0xac, 0x31, 0x6d, 0xdd, 0x90, 0xc6, 0x78, 0x58, 0x4c, 0xc4, 0x5e, 0x98, 0x12, 0x09, 0x5d, 0x85, + 0x63, 0xdb, 0xe1, 0x6c, 0x22, 0x8a, 0x1a, 0x2a, 0x81, 0xca, 0x88, 0x55, 0x50, 0x46, 0xad, 0xe4, + 0x27, 0x00, 0xa7, 0x53, 0xe1, 0x6a, 0x9e, 0x97, 0xe1, 0x84, 0x1b, 0x79, 0x32, 0x2c, 0xe0, 0xb8, + 0x9b, 0x28, 0xf3, 0x2f, 0x77, 0xf0, 0x30, 0x1d, 0x39, 0xcf, 0xc4, 0xf4, 0x5a, 0x8a, 0xdc, 0x97, + 0x59, 0xd2, 0xcf, 0x00, 0xce, 0xa4, 0x83, 0xd0, 0xfc, 0x3d, 0x87, 0xff, 0x9f, 0xe3, 0x2f, 0x5a, + 0xd5, 0xf9, 0xb4, 0x71, 0x93, 0x65, 0x9e, 0xfa, 0xa2, 0x99, 0x20, 0x60, 0x22, 0x49, 0xef, 0xdf, + 0x5b, 0xdb, 0xda, 0xaf, 0x61, 0x38, 0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 0x8b, 0xb5, + 0x05, 0xdd, 0x51, 0xec, 0xb5, 0x28, 0x77, 0xfe, 0x93, 0x27, 0xf0, 0xf6, 0xef, 0x00, 0x00, 0x00, + 0xff, 0xff, 0x71, 0x1f, 0x83, 0xc2, 0xcf, 0x08, 0x00, 0x00, } // Reference imports to suppress errors if they are not otherwise used. diff --git a/x/ibc/core/02-client/types/query.pb.gw.go b/x/ibc/core/02-client/types/query.pb.gw.go index 935c305d6..4d1cce836 100644 --- a/x/ibc/core/02-client/types/query.pb.gw.go +++ b/x/ibc/core/02-client/types/query.pb.gw.go @@ -520,13 +520,13 @@ func RegisterQueryHandlerClient(ctx context.Context, mux *runtime.ServeMux, clie } var ( - pattern_Query_ClientState_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3, 1, 0, 4, 1, 5, 4}, []string{"ibc", "client", "v1beta1", "client_states", "client_id"}, "", runtime.AssumeColonVerbOpt(true))) + pattern_Query_ClientState_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3, 2, 4, 1, 0, 4, 1, 5, 5}, []string{"ibc", "core", "client", "v1beta1", "client_states", "client_id"}, "", runtime.AssumeColonVerbOpt(true))) - pattern_Query_ClientStates_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3}, []string{"ibc", "client", "v1beta1", "client_states"}, "", runtime.AssumeColonVerbOpt(true))) + pattern_Query_ClientStates_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3, 2, 4}, []string{"ibc", "core", "client", "v1beta1", "client_states"}, "", runtime.AssumeColonVerbOpt(true))) - pattern_Query_ConsensusState_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3, 1, 0, 4, 1, 5, 4, 2, 5, 1, 0, 4, 1, 5, 6, 2, 7, 1, 0, 4, 1, 5, 8}, []string{"ibc", "client", "v1beta1", "consensus_states", "client_id", "version", "version_number", "height", "version_height"}, "", runtime.AssumeColonVerbOpt(true))) + pattern_Query_ConsensusState_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3, 2, 4, 1, 0, 4, 1, 5, 5, 2, 6, 1, 0, 4, 1, 5, 7, 2, 8, 1, 0, 4, 1, 5, 9}, []string{"ibc", "core", "client", "v1beta1", "consensus_states", "client_id", "version", "version_number", "height", "version_height"}, "", runtime.AssumeColonVerbOpt(true))) - pattern_Query_ConsensusStates_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3, 1, 0, 4, 1, 5, 4}, []string{"ibc", "client", "v1beta1", "consensus_states", "client_id"}, "", runtime.AssumeColonVerbOpt(true))) + pattern_Query_ConsensusStates_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3, 2, 4, 1, 0, 4, 1, 5, 5}, []string{"ibc", "core", "client", "v1beta1", "consensus_states", "client_id"}, "", runtime.AssumeColonVerbOpt(true))) ) var ( diff --git a/x/ibc/core/03-connection/types/query.pb.go b/x/ibc/core/03-connection/types/query.pb.go index 3007ac05b..5c3a2bcb2 100644 --- a/x/ibc/core/03-connection/types/query.pb.go +++ b/x/ibc/core/03-connection/types/query.pb.go @@ -635,63 +635,63 @@ func init() { } var fileDescriptor_cd8d529f8c7cd06b = []byte{ - // 891 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xb4, 0x56, 0xc1, 0x4f, 0x2b, 0x45, - 0x18, 0xef, 0x14, 0xde, 0xcb, 0x63, 0xca, 0x7b, 0xea, 0xa4, 0x0f, 0xea, 0xaa, 0x05, 0x17, 0x2b, - 0xa0, 0x32, 0x43, 0x21, 0x10, 0x04, 0x6a, 0xb4, 0x04, 0x85, 0x0b, 0xc1, 0x35, 0x5e, 0xbc, 0x90, - 0xdd, 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 0x68, 0x7b, 0x58, 0x88, 0x49, 0xfe, - 0xa5, 0x95, 0x46, 0xac, 0x96, 0x1c, 0xbf, 0xe5, 0x1c, 0x5b, 0x28, 0x18, 0x89, 0x63, 0xdc, 0x81, - 0x88, 0x34, 0x33, 0x72, 0x16, 0xb7, 0xc4, 0x0e, 0x11, 0x96, 0x11, 0xc5, 0xc5, 0x7b, 0xa7, 0xfc, - 0xe5, 0x79, 0x37, 0x0f, 0x2e, 0xba, 0x79, 0xf0, 0x57, 0x37, 0x0f, 0x7e, 0xb8, 0xce, 0xa7, 0x2e, - 0xae, 0xf3, 0xa9, 0xcb, 0xeb, 0x7c, 0xea, 0xab, 0x2d, 0xc7, 0x0d, 0xaa, 0x4d, 0x0b, 0xdb, 0xac, - 0x46, 0xe4, 0x3f, 0x5f, 0xf1, 0xb3, 0xe4, 0x57, 0xbe, 0x26, 0xdf, 0x90, 0x9b, 0x3f, 0xb0, 0xcb, - 0xab, 0x4b, 0x0a, 0xea, 0xa0, 0x5d, 0xa7, 0xbe, 0xf5, 0x94, 0x7b, 0xdf, 0xea, 0x7f, 0x01, 0x00, - 0x00, 0xff, 0xff, 0x3b, 0x66, 0x6e, 0x99, 0x86, 0x0b, 0x00, 0x00, + // 887 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xb4, 0x56, 0x41, 0x4f, 0x33, 0x45, + 0x18, 0xee, 0x14, 0xbe, 0x2f, 0x1f, 0x53, 0x40, 0x9d, 0x14, 0xa8, 0xab, 0x16, 0x5c, 0x45, 0x0a, + 0x91, 0x19, 0x0a, 0xd1, 0x20, 0xd0, 0x44, 0x21, 0x88, 0x1c, 0x24, 0xb8, 0xc6, 0x8b, 0x17, 0xb2, + 0xbb, 0x1d, 0xb6, 0x1b, 0xe9, 0x4e, 0xe9, 0x6e, 0x1b, 0x1b, 0xd2, 0x83, 0xfe, 0x02, 0x13, 0x8f, + 0xde, 0x3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x46, 0x67, 0x1a, 0xf7, 0x26, 0x22, 0x6d, + 0x8e, 0x5c, 0xc4, 0xcd, 0xb2, 0x4d, 0x84, 0x99, 0x44, 0x71, 0xf1, 0xde, 0xde, 0xfd, 0xea, 0xaa, + 0x93, 0x07, 0xd7, 0x9d, 0x3c, 0xf8, 0xbb, 0x93, 0x07, 0x3f, 0xdc, 0xe6, 0x53, 0xd7, 0xb7, 0xf9, + 0xd4, 0x9f, 0xb7, 0xf9, 0xd4, 0xd7, 0xdb, 0x8e, 0x1b, 0x54, 0x1a, 0x16, 0xb6, 0x59, 0x95, 0xc8, + 0xff, 0xc4, 0xe2, 0x67, 0xd5, 0x2f, 0x7f, 0x43, 0xbe, 0x8d, 0x20, 0xaf, 0x6d, 0xac, 0x2a, 0xa8, + 0x83, 0x56, 0x8d, 0xfa, 0xd6, 0x73, 0xee, 0x8a, 0x1b, 0xff, 0x07, 0x00, 0x00, 0xff, 0xff, 0x91, + 0x3b, 0x2c, 0x79, 0xa0, 0x0b, 0x00, 0x00, } // Reference imports to suppress errors if they are not otherwise used. diff --git a/x/ibc/core/03-connection/types/query.pb.gw.go b/x/ibc/core/03-connection/types/query.pb.gw.go index 57b8ab492..1d7151ad5 100644 --- a/x/ibc/core/03-connection/types/query.pb.gw.go +++ b/x/ibc/core/03-connection/types/query.pb.gw.go @@ -578,15 +578,15 @@ func RegisterQueryHandlerClient(ctx context.Context, mux *runtime.ServeMux, clie } var ( - pattern_Query_Connection_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3, 1, 0, 4, 1, 5, 4}, []string{"ibc", "connection", "v1beta1", "connections", "connection_id"}, "", runtime.AssumeColonVerbOpt(true))) + pattern_Query_Connection_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3, 2, 4, 1, 0, 4, 1, 5, 5}, []string{"ibc", "core", "connection", "v1beta1", "connections", "connection_id"}, "", runtime.AssumeColonVerbOpt(true))) - pattern_Query_Connections_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3}, []string{"ibc", "connection", "v1beta1", "connections"}, "", runtime.AssumeColonVerbOpt(true))) + pattern_Query_Connections_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3, 2, 4}, []string{"ibc", "core", "connection", "v1beta1", "connections"}, "", runtime.AssumeColonVerbOpt(true))) - pattern_Query_ClientConnections_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3, 1, 0, 4, 1, 5, 4}, []string{"ibc", "connection", "v1beta1", "client_connections", "client_id"}, "", runtime.AssumeColonVerbOpt(true))) + pattern_Query_ClientConnections_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3, 2, 4, 1, 0, 4, 1, 5, 5}, []string{"ibc", "core", "connection", "v1beta1", "client_connections", "client_id"}, "", runtime.AssumeColonVerbOpt(true))) - pattern_Query_ConnectionClientState_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3, 1, 0, 4, 1, 5, 4, 2, 5}, []string{"ibc", "connection", "v1beta1", "connections", "connection_id", "client_state"}, "", runtime.AssumeColonVerbOpt(true))) + pattern_Query_ConnectionClientState_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3, 2, 4, 1, 0, 4, 1, 5, 5, 2, 6}, []string{"ibc", "core", "connection", "v1beta1", "connections", "connection_id", "client_state"}, "", runtime.AssumeColonVerbOpt(true))) - pattern_Query_ConnectionConsensusState_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3, 1, 0, 4, 1, 5, 4, 2, 5, 2, 6, 1, 0, 4, 1, 5, 7, 2, 8, 1, 0, 4, 1, 5, 9}, []string{"ibc", "connection", "v1beta1", "connections", "connection_id", "consensus_state", "version", "version_number", "height", "version_height"}, "", runtime.AssumeColonVerbOpt(true))) + pattern_Query_ConnectionConsensusState_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3, 2, 4, 1, 0, 4, 1, 5, 5, 2, 6, 2, 7, 1, 0, 4, 1, 5, 8, 2, 9, 1, 0, 4, 1, 5, 10}, []string{"ibc", "core", "connection", "v1beta1", "connections", "connection_id", "consensus_state", "version", "version_number", "height", "version_height"}, "", runtime.AssumeColonVerbOpt(true))) ) var ( diff --git a/x/ibc/core/04-channel/types/query.pb.go b/x/ibc/core/04-channel/types/query.pb.go index d66ace711..7015a2acf 100644 --- a/x/ibc/core/04-channel/types/query.pb.go +++ b/x/ibc/core/04-channel/types/query.pb.go @@ -1699,100 +1699,100 @@ func init() { func init() { proto.RegisterFile("ibc/core/channel/v1/query.proto", fileDescriptor_1034a1e9abc4cca1) } var fileDescriptor_1034a1e9abc4cca1 = []byte{ - // 1488 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xdc, 0x59, 0xcf, 0x6f, 0x13, 0xc7, - 0x17, 0xcf, 0x38, 0x01, 0x92, 0xc7, 0xef, 0x49, 0x02, 0x61, 0x09, 0x4e, 0xf0, 0x57, 0x7c, 0x1b, - 0x90, 0xd8, 0x21, 0x81, 0xd2, 0xa8, 0x6a, 0x91, 0x48, 0xa4, 0x42, 0xaa, 0xf2, 0x6b, 0x29, 0x2a, - 0x20, 0xb5, 0xee, 0x7a, 0x3d, 0x38, 0xab, 0x24, 0xbb, 0xc6, 0xbb, 0x36, 0x41, 0xa9, 0xab, 0xaa, - 0x95, 0x80, 0x53, 0x55, 0x89, 0x43, 0xa5, 0x5e, 0x2a, 0x55, 0xbd, 0x70, 0xec, 0x5f, 0xd0, 0x2b, - 0xb7, 0x22, 0xd1, 0x43, 0x25, 0x24, 0x5a, 0x91, 0x4a, 0xf4, 0xda, 0x4b, 0xcf, 0xd5, 0xce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b, 0x48, 0x07, 0x1f, 0xa1, 0xed, - 0xdd, 0x78, 0xfa, 0x2b, 0x81, 0xc1, 0x98, 0x0e, 0x97, 0xa6, 0xb4, 0x00, 0xc9, 0xcd, 0xb6, 0xf2, - 0x66, 0x9b, 0x56, 0x28, 0xc1, 0x55, 0x21, 0xc1, 0xfb, 0xf4, 0x62, 0x07, 0x12, 0x44, 0xfa, 0xf0, - 0x19, 0xed, 0xe9, 0xab, 0x2c, 0x79, 0xf6, 0x2a, 0x4b, 0xfe, 0x78, 0x95, 0x25, 0xdf, 0xac, 0x66, - 0x7b, 0x9e, 0xad, 0x66, 0x7b, 0x7e, 0x5b, 0xcd, 0xf6, 0xdc, 0x9e, 0x2e, 0x99, 0xee, 0x7c, 0xb5, - 0xa0, 0x1a, 0xf6, 0x12, 0xc3, 0x7f, 0xe8, 0xc9, 0x3f, 0x27, 0x9d, 0xe2, 0x02, 0x5b, 0x66, 0xc1, - 0x3f, 0xee, 0x4e, 0x9d, 0x39, 0xe9, 0x23, 0x71, 0xef, 0x97, 0xb9, 0x53, 0xd8, 0x2e, 0x7e, 0x7f, - 0x3d, 0xfd, 0x6f, 0x00, 0x00, 0x00, 0xff, 0xff, 0x07, 0x22, 0x97, 0x6e, 0x5f, 0x1c, 0x00, 0x00, + // 1487 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xdc, 0x59, 0xdf, 0x6b, 0x14, 0xd7, + 0x17, 0xcf, 0xdd, 0x44, 0x4d, 0x8e, 0xbf, 0x6f, 0x12, 0x8d, 0x63, 0x5c, 0xe3, 0x7e, 0xbf, 0x6d, + 0xa3, 0xe0, 0x5c, 0x13, 0xad, 0x15, 0x8a, 0x2d, 0x31, 0x50, 0x1b, 0x50, 0x6b, 0x47, 0x6d, 0x55, + 0x5a, 0x97, 0xd9, 0xd9, 0xeb, 0x66, 0x48, 0x32, 0xb3, 0xee, 0xcc, 0xc6, 0x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 0xb9, 0xe6, 0x75, 0x93, 0x97, 0x7d, 0x5d, 0x02, + 0x3f, 0x7a, 0x3a, 0x86, 0x32, 0x27, 0x50, 0xbe, 0xb2, 0x2a, 0x4a, 0x09, 0x20, 0x0a, 0x93, 0x9e, + 0x80, 0x8d, 0x6d, 0xaa, 0x88, 0xf6, 0x85, 0x4f, 0x09, 0xe4, 0x25, 0x41, 0xdb, 0xb2, 0xb8, 0xe1, + 0x45, 0x6b, 0xd6, 0x32, 0x0f, 0x60, 0x04, 0x2f, 0xf1, 0x28, 0x45, 0x56, 0x9a, 0xb4, 0xce, 0x3d, + 0xb7, 0xd6, 0xcf, 0x08, 0xec, 0x4f, 0x85, 0xf2, 0xdf, 0x52, 0xfd, 0xb2, 0x2f, 0xba, 0xc4, 0x34, + 0x2d, 0xac, 0x2f, 0xb8, 0xba, 0xcb, 0x3b, 0x2d, 0xde, 0xdf, 0x03, 0x11, 0x13, 0x42, 0xa3, 0x88, + 0x3a, 0xec, 0x36, 0x03, 0x7d, 0x8a, 0x12, 0x6a, 0xd1, 0xf1, 0x4c, 0xb0, 0x52, 0x0e, 0x26, 0x11, + 0x89, 0x48, 0x1a, 0x89, 0x39, 0x6c, 0x26, 0x2d, 0x77, 0xb3, 0xe4, 0xef, 0x11, 0x38, 0x10, 0x63, + 0xe8, 0x71, 0xb2, 0x9c, 0xba, 0xb3, 0x1e, 0xfa, 0xd1, 0x97, 0x60, 0xdb, 0x22, 0xaf, 0x39, 0xa6, + 0x6d, 0x15, 0xad, 0xfa, 0x42, 0x89, 0xd7, 0x04, 0xc8, 0x3e, 0x6d, 0x2b, 0xae, 0x9e, 0x13, 0x8b, + 0x51, 0x33, 0xe4, 0xd2, 0x17, 0x33, 0x43, 0xac, 0xbf, 0x11, 0x28, 0x64, 0x61, 0xc5, 0x84, 0x9c, + 0x84, 0xed, 0x86, 0xff, 0x26, 0x96, 0x88, 0x21, 0x55, 0x7e, 0x17, 0xa8, 0xfe, 0x77, 0x81, 0x3a, + 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81, 0x06, 0xab, 0x07, 0xb0, 0x8a, 0x55, 0x24, + 0xfe, 0x0f, 0x81, 0x6d, 0xf1, 0xab, 0x2f, 0x65, 0x6b, 0xe1, 0x15, 0xb9, 0xac, 0x2b, 0x47, 0xd6, + 0xee, 0x80, 0x2a, 0x7c, 0x2c, 0x55, 0x58, 0xa1, 0xcb, 0x5d, 0xd4, 0x20, 0x36, 0x01, 0xc4, 0xc8, + 0x7b, 0x25, 0x40, 0x7f, 0x25, 0x30, 0x98, 0x70, 0x43, 0xa6, 0x19, 0x77, 0x86, 0xf4, 0xcb, 0xba, + 0xf2, 0x6a, 0x9b, 0x5e, 0x28, 0xc4, 0x25, 0xa1, 0xc3, 0x3b, 0xf4, 0x6c, 0xa7, 0x3a, 0xc4, 0x2e, + 0xf3, 0xa7, 0xb4, 0xfb, 0x4f, 0xf2, 0xe4, 0xc1, 0x93, 0x3c, 0x79, 0xfc, 0x24, 0x4f, 0xbe, 0x78, + 0x9a, 0xef, 0x79, 0xf0, 0x34, 0xdf, 0xf3, 0xf0, 0x69, 0xbe, 0xe7, 0xea, 0x89, 0x8a, 0xe9, 0xce, + 0xd6, 0x4b, 0xaa, 0x61, 0x2f, 0x30, 0xfc, 0xaf, 0xa0, 0xfc, 0x73, 0xd8, 0x29, 0xcf, 0xb1, 0xa5, + 0x10, 0xc6, 0x91, 0x63, 0x87, 0x7d, 0x24, 0xee, 0x72, 0x95, 0x3b, 0xa5, 0x8d, 0xe2, 0x47, 0xdc, + 0xa3, 0xff, 0x06, 0x00, 0x00, 0xff, 0xff, 0x48, 0x61, 0x15, 0x26, 0xa4, 0x1c, 0x00, 0x00, } // Reference imports to suppress errors if they are not otherwise used. diff --git a/x/ibc/core/04-channel/types/query.pb.gw.go b/x/ibc/core/04-channel/types/query.pb.gw.go index a2ae71d96..270aa3db9 100644 --- a/x/ibc/core/04-channel/types/query.pb.gw.go +++ b/x/ibc/core/04-channel/types/query.pb.gw.go @@ -1736,31 +1736,31 @@ func RegisterQueryHandlerClient(ctx context.Context, mux *runtime.ServeMux, clie } var ( - pattern_Query_Channel_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3, 1, 0, 4, 1, 5, 4, 2, 5, 1, 0, 4, 1, 5, 6}, []string{"ibc", "channel", "v1beta1", "channels", "channel_id", "ports", "port_id"}, "", runtime.AssumeColonVerbOpt(true))) + pattern_Query_Channel_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3, 2, 4, 1, 0, 4, 1, 5, 5, 2, 6, 1, 0, 4, 1, 5, 7}, []string{"ibc", "core", "channel", "v1beta1", "channels", "channel_id", "ports", "port_id"}, "", runtime.AssumeColonVerbOpt(true))) - pattern_Query_Channels_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3}, []string{"ibc", "channel", "v1beta1", "channels"}, "", runtime.AssumeColonVerbOpt(true))) + pattern_Query_Channels_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3, 2, 4}, []string{"ibc", "core", "channel", "v1beta1", "channels"}, "", runtime.AssumeColonVerbOpt(true))) - pattern_Query_ConnectionChannels_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3, 1, 0, 4, 1, 5, 4, 2, 5}, []string{"ibc", "channel", "v1beta1", "connections", "connection", "channels"}, "", runtime.AssumeColonVerbOpt(true))) + pattern_Query_ConnectionChannels_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3, 2, 4, 1, 0, 4, 1, 5, 5, 2, 6}, []string{"ibc", "core", "channel", "v1beta1", "connections", "connection", "channels"}, "", runtime.AssumeColonVerbOpt(true))) - pattern_Query_ChannelClientState_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3, 1, 0, 4, 1, 5, 4, 2, 5, 1, 0, 4, 1, 5, 6, 2, 7}, []string{"ibc", "channel", "v1beta1", "channels", "channel_id", "ports", "port_id", "client_state"}, "", runtime.AssumeColonVerbOpt(true))) + pattern_Query_ChannelClientState_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3, 2, 4, 1, 0, 4, 1, 5, 5, 2, 6, 1, 0, 4, 1, 5, 7, 2, 8}, []string{"ibc", "core", "channel", "v1beta1", "channels", "channel_id", "ports", "port_id", "client_state"}, "", runtime.AssumeColonVerbOpt(true))) - pattern_Query_ChannelConsensusState_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3, 1, 0, 4, 1, 5, 4, 2, 5, 1, 0, 4, 1, 5, 6, 2, 7, 2, 8, 1, 0, 4, 1, 5, 9, 2, 10, 1, 0, 4, 1, 5, 11}, []string{"ibc", "channel", "v1beta1", "channels", "channel_id", "ports", "port_id", "consensus_state", "version", "version_number", "height", "version_height"}, "", runtime.AssumeColonVerbOpt(true))) + pattern_Query_ChannelConsensusState_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3, 2, 4, 1, 0, 4, 1, 5, 5, 2, 6, 1, 0, 4, 1, 5, 7, 2, 8, 2, 9, 1, 0, 4, 1, 5, 10, 2, 11, 1, 0, 4, 1, 5, 12}, []string{"ibc", "core", "channel", "v1beta1", "channels", "channel_id", "ports", "port_id", "consensus_state", "version", "version_number", "height", "version_height"}, "", runtime.AssumeColonVerbOpt(true))) - pattern_Query_PacketCommitment_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3, 1, 0, 4, 1, 5, 4, 2, 5, 1, 0, 4, 1, 5, 6, 2, 7, 1, 0, 4, 1, 5, 8}, []string{"ibc", "channel", "v1beta1", "channels", "channel_id", "ports", "port_id", "packet_commitments", "sequence"}, "", runtime.AssumeColonVerbOpt(true))) + pattern_Query_PacketCommitment_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3, 2, 4, 1, 0, 4, 1, 5, 5, 2, 6, 1, 0, 4, 1, 5, 7, 2, 8, 1, 0, 4, 1, 5, 9}, []string{"ibc", "core", "channel", "v1beta1", "channels", "channel_id", "ports", "port_id", "packet_commitments", "sequence"}, "", runtime.AssumeColonVerbOpt(true))) - pattern_Query_PacketCommitments_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3, 1, 0, 4, 1, 5, 4, 2, 5, 1, 0, 4, 1, 5, 6, 2, 7}, []string{"ibc", "channel", "v1beta1", "channels", "channel_id", "ports", "port_id", "packet_commitments"}, "", runtime.AssumeColonVerbOpt(true))) + pattern_Query_PacketCommitments_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3, 2, 4, 1, 0, 4, 1, 5, 5, 2, 6, 1, 0, 4, 1, 5, 7, 2, 8}, []string{"ibc", "core", "channel", "v1beta1", "channels", "channel_id", "ports", "port_id", "packet_commitments"}, "", runtime.AssumeColonVerbOpt(true))) - pattern_Query_PacketReceipt_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3, 1, 0, 4, 1, 5, 4, 2, 5, 1, 0, 4, 1, 5, 6, 2, 7, 1, 0, 4, 1, 5, 8}, []string{"ibc", "channel", "v1beta1", "channels", "channel_id", "ports", "port_id", "packet_receipts", "sequence"}, "", runtime.AssumeColonVerbOpt(true))) + pattern_Query_PacketReceipt_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3, 2, 4, 1, 0, 4, 1, 5, 5, 2, 6, 1, 0, 4, 1, 5, 7, 2, 8, 1, 0, 4, 1, 5, 9}, []string{"ibc", "core", "channel", "v1beta1", "channels", "channel_id", "ports", "port_id", "packet_receipts", "sequence"}, "", runtime.AssumeColonVerbOpt(true))) - pattern_Query_PacketAcknowledgement_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3, 1, 0, 4, 1, 5, 4, 2, 5, 1, 0, 4, 1, 5, 6, 2, 7, 1, 0, 4, 1, 5, 8}, []string{"ibc", "channel", "v1beta1", "channels", "channel_id", "ports", "port_id", "packet_acks", "sequence"}, "", runtime.AssumeColonVerbOpt(true))) + pattern_Query_PacketAcknowledgement_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3, 2, 4, 1, 0, 4, 1, 5, 5, 2, 6, 1, 0, 4, 1, 5, 7, 2, 8, 1, 0, 4, 1, 5, 9}, []string{"ibc", "core", "channel", "v1beta1", "channels", "channel_id", "ports", "port_id", "packet_acks", "sequence"}, "", runtime.AssumeColonVerbOpt(true))) - pattern_Query_PacketAcknowledgements_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3, 1, 0, 4, 1, 5, 4, 2, 5, 1, 0, 4, 1, 5, 6, 2, 7}, []string{"ibc", "channel", "v1beta1", "channels", "channel_id", "ports", "port_id", "packet_acknowledgements"}, "", runtime.AssumeColonVerbOpt(true))) + pattern_Query_PacketAcknowledgements_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3, 2, 4, 1, 0, 4, 1, 5, 5, 2, 6, 1, 0, 4, 1, 5, 7, 2, 8}, []string{"ibc", "core", "channel", "v1beta1", "channels", "channel_id", "ports", "port_id", "packet_acknowledgements"}, "", runtime.AssumeColonVerbOpt(true))) - pattern_Query_UnreceivedPackets_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3, 1, 0, 4, 1, 5, 4, 2, 5, 1, 0, 4, 1, 5, 6, 2, 7, 1, 0, 4, 1, 5, 8, 2, 9}, []string{"ibc", "channel", "v1beta1", "channels", "channel_id", "ports", "port_id", "packet_commitments", "packet_commitment_sequences", "unreceived_packets"}, "", runtime.AssumeColonVerbOpt(true))) + pattern_Query_UnreceivedPackets_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3, 2, 4, 1, 0, 4, 1, 5, 5, 2, 6, 1, 0, 4, 1, 5, 7, 2, 8, 1, 0, 4, 1, 5, 9, 2, 10}, []string{"ibc", "core", "channel", "v1beta1", "channels", "channel_id", "ports", "port_id", "packet_commitments", "packet_commitment_sequences", "unreceived_packets"}, "", runtime.AssumeColonVerbOpt(true))) - pattern_Query_UnreceivedAcks_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3, 1, 0, 4, 1, 5, 4, 2, 5, 1, 0, 4, 1, 5, 6, 2, 7, 1, 0, 4, 1, 5, 8, 2, 9}, []string{"ibc", "channel", "v1beta1", "channels", "channel_id", "ports", "port_id", "packet_commitments", "packet_ack_sequences", "unreceived_acks"}, "", runtime.AssumeColonVerbOpt(true))) + pattern_Query_UnreceivedAcks_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3, 2, 4, 1, 0, 4, 1, 5, 5, 2, 6, 1, 0, 4, 1, 5, 7, 2, 8, 1, 0, 4, 1, 5, 9, 2, 10}, []string{"ibc", "core", "channel", "v1beta1", "channels", "channel_id", "ports", "port_id", "packet_commitments", "packet_ack_sequences", "unreceived_acks"}, "", runtime.AssumeColonVerbOpt(true))) - pattern_Query_NextSequenceReceive_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3, 1, 0, 4, 1, 5, 4, 2, 5, 1, 0, 4, 1, 5, 6, 2, 7}, []string{"ibc", "channel", "v1beta1", "channels", "channel_id", "ports", "port_id", "next_sequence"}, "", runtime.AssumeColonVerbOpt(true))) + pattern_Query_NextSequenceReceive_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3, 2, 4, 1, 0, 4, 1, 5, 5, 2, 6, 1, 0, 4, 1, 5, 7, 2, 8}, []string{"ibc", "core", "channel", "v1beta1", "channels", "channel_id", "ports", "port_id", "next_sequence"}, "", runtime.AssumeColonVerbOpt(true))) ) var ( diff --git a/x/ibc/core/23-commitment/types/commitment.pb.go b/x/ibc/core/23-commitment/types/commitment.pb.go index bb28053e7..9634e2573 100644 --- a/x/ibc/core/23-commitment/types/commitment.pb.go +++ b/x/ibc/core/23-commitment/types/commitment.pb.go @@ -112,6 +112,7 @@ func (m *MerklePrefix) GetKeyPrefix() []byte { // MerklePath is the path used to verify commitment proofs, which can be an // arbitrary structured object (defined by a commitment type). +// MerklePath is represented from root-to-leaf type MerklePath struct { KeyPath []string `protobuf:"bytes,1,rep,name=key_path,json=keyPath,proto3" json:"key_path,omitempty" yaml:"key_path"` } @@ -159,6 +160,7 @@ func (m *MerklePath) GetKeyPath() []string { // It demonstrates membership or non-membership for an element or set of // elements, verifiable in conjunction with a known commitment root. Proofs // should be succinct. +// MerkleProofs are ordered from leaf-to-root type MerkleProof struct { Proofs []*_go.CommitmentProof `protobuf:"bytes,1,rep,name=proofs,proto3" json:"proofs,omitempty"` } From 0bd46574f431d8281e71cad2f166973bb558f7c3 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?colin=20axn=C3=A9r?= <25233464+colin-axner@users.noreply.github.com> Date: Tue, 10 Nov 2020 21:37:10 +0100 Subject: [PATCH 20/24] fix mismatched solomachine signature data type verification (#7882) * fix mismatched signature data type verification * update godoc Co-authored-by: Federico Kunze <31522760+fedekunze@users.noreply.github.com> --- .../06-solomachine/types/proof.go | 30 ++++----- .../06-solomachine/types/proof_test.go | 62 +++++++++++++++++++ 2 files changed, 78 insertions(+), 14 deletions(-) diff --git a/x/ibc/light-clients/06-solomachine/types/proof.go b/x/ibc/light-clients/06-solomachine/types/proof.go index c6f4c8b48..6c2e0b842 100644 --- a/x/ibc/light-clients/06-solomachine/types/proof.go +++ b/x/ibc/light-clients/06-solomachine/types/proof.go @@ -15,32 +15,34 @@ import ( // VerifySignature verifies if the the provided public key generated the signature // over the given data. Single and Multi signature public keys are supported. -// The type of the signature data determines how the public key is used to -// verify the signature. An error is returned if signature verification fails -// or an invalid SignatureData type is provided. +// The signature data type must correspond to the public key type. An error is +// returned if signature verification fails or an invalid SignatureData type is +// provided. func VerifySignature(pubKey cryptotypes.PubKey, signBytes []byte, sigData signing.SignatureData) error { - switch data := sigData.(type) { - case *signing.SingleSignatureData: - if !pubKey.VerifySignature(signBytes, data.Signature) { - return ErrSignatureVerificationFailed - } - - case *signing.MultiSignatureData: - multiPK, ok := pubKey.(multisig.PubKey) + switch pubKey := pubKey.(type) { + case multisig.PubKey: + data, ok := sigData.(*signing.MultiSignatureData) if !ok { - return sdkerrors.Wrapf(ErrSignatureVerificationFailed, "invalid pubkey type: expected %T, got %T", (multisig.PubKey)(nil), pubKey) + return sdkerrors.Wrapf(ErrSignatureVerificationFailed, "invalid signature data type, expected %T, got %T", (*signing.MultiSignatureData)(nil), data) } // The function supplied fulfills the VerifyMultisignature interface. No special // adjustments need to be made to the sign bytes based on the sign mode. - if err := multiPK.VerifyMultisignature(func(signing.SignMode) ([]byte, error) { + if err := pubKey.VerifyMultisignature(func(signing.SignMode) ([]byte, error) { return signBytes, nil }, data); err != nil { return err } default: - return sdkerrors.Wrapf(ErrSignatureVerificationFailed, "unsupported signature data type %T", data) + data, ok := sigData.(*signing.SingleSignatureData) + if !ok { + return sdkerrors.Wrapf(ErrSignatureVerificationFailed, "invalid signature data type, expected %T, got %T", (*signing.SingleSignatureData)(nil), data) + } + + if !pubKey.VerifySignature(signBytes, data.Signature) { + return ErrSignatureVerificationFailed + } } return nil diff --git a/x/ibc/light-clients/06-solomachine/types/proof_test.go b/x/ibc/light-clients/06-solomachine/types/proof_test.go index 5ecd9c4c5..e2ba679a5 100644 --- a/x/ibc/light-clients/06-solomachine/types/proof_test.go +++ b/x/ibc/light-clients/06-solomachine/types/proof_test.go @@ -1,10 +1,72 @@ package types_test import ( + cryptotypes "github.com/cosmos/cosmos-sdk/crypto/types" + "github.com/cosmos/cosmos-sdk/types/tx/signing" "github.com/cosmos/cosmos-sdk/x/ibc/light-clients/06-solomachine/types" + solomachinetypes "github.com/cosmos/cosmos-sdk/x/ibc/light-clients/06-solomachine/types" ibctesting "github.com/cosmos/cosmos-sdk/x/ibc/testing" ) +func (suite *SoloMachineTestSuite) TestVerifySignature() { + cdc := suite.chainA.App.AppCodec() + signBytes := []byte("sign bytes") + + singleSignature := suite.solomachine.GenerateSignature(signBytes) + singleSigData, err := solomachinetypes.UnmarshalSignatureData(cdc, singleSignature) + suite.Require().NoError(err) + + multiSignature := suite.solomachineMulti.GenerateSignature(signBytes) + multiSigData, err := solomachinetypes.UnmarshalSignatureData(cdc, multiSignature) + suite.Require().NoError(err) + + testCases := []struct { + name string + publicKey cryptotypes.PubKey + sigData signing.SignatureData + expPass bool + }{ + { + "single signature with regular public key", + suite.solomachine.PublicKey, + singleSigData, + true, + }, + { + "multi signature with multisig public key", + suite.solomachineMulti.PublicKey, + multiSigData, + true, + }, + { + "single signature with multisig public key", + suite.solomachineMulti.PublicKey, + singleSigData, + false, + }, + { + "multi signature with regular public key", + suite.solomachine.PublicKey, + multiSigData, + false, + }, + } + + for _, tc := range testCases { + tc := tc + + suite.Run(tc.name, func() { + err := solomachinetypes.VerifySignature(tc.publicKey, signBytes, tc.sigData) + + if tc.expPass { + suite.Require().NoError(err) + } else { + suite.Require().Error(err) + } + }) + } +} + func (suite *SoloMachineTestSuite) TestClientStateSignBytes() { cdc := suite.chainA.App.AppCodec() From 116d0460fc329b6d96b615782c8d3f57e30aa505 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?colin=20axn=C3=A9r?= <25233464+colin-axner@users.noreply.github.com> Date: Wed, 11 Nov 2020 11:09:57 +0100 Subject: [PATCH 21/24] solo machine GetPubKey returns an error instead of panicing (#7883) * solo machine public key now returns an error instead of panicing * apply @fedekunze review suggestions Co-authored-by: Federico Kunze <31522760+fedekunze@users.noreply.github.com> --- .../06-solomachine/types/client_state.go | 70 ++++++++++--------- .../06-solomachine/types/consensus_state.go | 20 ++++-- .../06-solomachine/types/header.go | 19 +++-- .../types/misbehaviour_handle.go | 7 +- .../types/misbehaviour_handle_test.go | 10 +++ .../06-solomachine/types/proposal_handle.go | 12 +++- .../types/proposal_handle_test.go | 9 ++- .../06-solomachine/types/update.go | 7 +- .../06-solomachine/types/update_test.go | 10 +++ 9 files changed, 116 insertions(+), 48 deletions(-) diff --git a/x/ibc/light-clients/06-solomachine/types/client_state.go b/x/ibc/light-clients/06-solomachine/types/client_state.go index 5e9fe014a..05ed359ba 100644 --- a/x/ibc/light-clients/06-solomachine/types/client_state.go +++ b/x/ibc/light-clients/06-solomachine/types/client_state.go @@ -4,6 +4,7 @@ import ( ics23 "github.com/confio/ics23/go" "github.com/cosmos/cosmos-sdk/codec" + cryptotypes "github.com/cosmos/cosmos-sdk/crypto/types" sdk "github.com/cosmos/cosmos-sdk/types" sdkerrors "github.com/cosmos/cosmos-sdk/types/errors" "github.com/cosmos/cosmos-sdk/types/tx/signing" @@ -95,7 +96,7 @@ func (cs ClientState) VerifyClientState( proof []byte, clientState exported.ClientState, ) error { - sigData, timestamp, sequence, err := produceVerificationArgs(cdc, cs, height, prefix, proof) + publicKey, sigData, timestamp, sequence, err := produceVerificationArgs(cdc, cs, height, prefix, proof) if err != nil { return err } @@ -111,7 +112,7 @@ func (cs ClientState) VerifyClientState( return err } - if err := VerifySignature(cs.ConsensusState.GetPubKey(), signBz, sigData); err != nil { + if err := VerifySignature(publicKey, signBz, sigData); err != nil { return err } @@ -133,7 +134,7 @@ func (cs ClientState) VerifyClientConsensusState( proof []byte, consensusState exported.ConsensusState, ) error { - sigData, timestamp, sequence, err := produceVerificationArgs(cdc, cs, height, prefix, proof) + publicKey, sigData, timestamp, sequence, err := produceVerificationArgs(cdc, cs, height, prefix, proof) if err != nil { return err } @@ -149,7 +150,7 @@ func (cs ClientState) VerifyClientConsensusState( return err } - if err := VerifySignature(cs.ConsensusState.GetPubKey(), signBz, sigData); err != nil { + if err := VerifySignature(publicKey, signBz, sigData); err != nil { return err } @@ -170,7 +171,7 @@ func (cs ClientState) VerifyConnectionState( connectionID string, connectionEnd exported.ConnectionI, ) error { - sigData, timestamp, sequence, err := produceVerificationArgs(cdc, cs, height, prefix, proof) + publicKey, sigData, timestamp, sequence, err := produceVerificationArgs(cdc, cs, height, prefix, proof) if err != nil { return err } @@ -186,7 +187,7 @@ func (cs ClientState) VerifyConnectionState( return err } - if err := VerifySignature(cs.ConsensusState.GetPubKey(), signBz, sigData); err != nil { + if err := VerifySignature(publicKey, signBz, sigData); err != nil { return err } @@ -208,7 +209,7 @@ func (cs ClientState) VerifyChannelState( channelID string, channel exported.ChannelI, ) error { - sigData, timestamp, sequence, err := produceVerificationArgs(cdc, cs, height, prefix, proof) + publicKey, sigData, timestamp, sequence, err := produceVerificationArgs(cdc, cs, height, prefix, proof) if err != nil { return err } @@ -224,7 +225,7 @@ func (cs ClientState) VerifyChannelState( return err } - if err := VerifySignature(cs.ConsensusState.GetPubKey(), signBz, sigData); err != nil { + if err := VerifySignature(publicKey, signBz, sigData); err != nil { return err } @@ -247,7 +248,7 @@ func (cs ClientState) VerifyPacketCommitment( packetSequence uint64, commitmentBytes []byte, ) error { - sigData, timestamp, sequence, err := produceVerificationArgs(cdc, cs, height, prefix, proof) + publicKey, sigData, timestamp, sequence, err := produceVerificationArgs(cdc, cs, height, prefix, proof) if err != nil { return err } @@ -263,7 +264,7 @@ func (cs ClientState) VerifyPacketCommitment( return err } - if err := VerifySignature(cs.ConsensusState.GetPubKey(), signBz, sigData); err != nil { + if err := VerifySignature(publicKey, signBz, sigData); err != nil { return err } @@ -286,7 +287,7 @@ func (cs ClientState) VerifyPacketAcknowledgement( packetSequence uint64, acknowledgement []byte, ) error { - sigData, timestamp, sequence, err := produceVerificationArgs(cdc, cs, height, prefix, proof) + publicKey, sigData, timestamp, sequence, err := produceVerificationArgs(cdc, cs, height, prefix, proof) if err != nil { return err } @@ -302,7 +303,7 @@ func (cs ClientState) VerifyPacketAcknowledgement( return err } - if err := VerifySignature(cs.ConsensusState.GetPubKey(), signBz, sigData); err != nil { + if err := VerifySignature(publicKey, signBz, sigData); err != nil { return err } @@ -325,7 +326,7 @@ func (cs ClientState) VerifyPacketReceiptAbsence( channelID string, packetSequence uint64, ) error { - sigData, timestamp, sequence, err := produceVerificationArgs(cdc, cs, height, prefix, proof) + publicKey, sigData, timestamp, sequence, err := produceVerificationArgs(cdc, cs, height, prefix, proof) if err != nil { return err } @@ -341,7 +342,7 @@ func (cs ClientState) VerifyPacketReceiptAbsence( return err } - if err := VerifySignature(cs.ConsensusState.GetPubKey(), signBz, sigData); err != nil { + if err := VerifySignature(publicKey, signBz, sigData); err != nil { return err } @@ -363,7 +364,7 @@ func (cs ClientState) VerifyNextSequenceRecv( channelID string, nextSequenceRecv uint64, ) error { - sigData, timestamp, sequence, err := produceVerificationArgs(cdc, cs, height, prefix, proof) + publicKey, sigData, timestamp, sequence, err := produceVerificationArgs(cdc, cs, height, prefix, proof) if err != nil { return err } @@ -379,7 +380,7 @@ func (cs ClientState) VerifyNextSequenceRecv( return err } - if err := VerifySignature(cs.ConsensusState.GetPubKey(), signBz, sigData); err != nil { + if err := VerifySignature(publicKey, signBz, sigData); err != nil { return err } @@ -390,71 +391,76 @@ func (cs ClientState) VerifyNextSequenceRecv( } // produceVerificationArgs perfoms the basic checks on the arguments that are -// shared between the verification functions and returns the unmarshalled -// proof representing the signature and timestamp along with the solo-machine sequence -// encoded in the proofHeight. +// shared between the verification functions and returns the public key of the +// consensus state, the unmarshalled proof representing the signature and timestamp +// along with the solo-machine sequence encoded in the proofHeight. func produceVerificationArgs( cdc codec.BinaryMarshaler, cs ClientState, height exported.Height, prefix exported.Prefix, proof []byte, -) (signing.SignatureData, uint64, uint64, error) { +) (cryptotypes.PubKey, signing.SignatureData, uint64, uint64, error) { if version := height.GetVersionNumber(); version != 0 { - return nil, 0, 0, sdkerrors.Wrapf(sdkerrors.ErrInvalidHeight, "version must be 0 for solomachine, got version-number: %d", version) + return nil, nil, 0, 0, sdkerrors.Wrapf(sdkerrors.ErrInvalidHeight, "version must be 0 for solomachine, got version-number: %d", version) } // sequence is encoded in the version height of height struct sequence := height.GetVersionHeight() if cs.IsFrozen() { - return nil, 0, 0, clienttypes.ErrClientFrozen + return nil, nil, 0, 0, clienttypes.ErrClientFrozen } if prefix == nil { - return nil, 0, 0, sdkerrors.Wrap(commitmenttypes.ErrInvalidPrefix, "prefix cannot be empty") + return nil, nil, 0, 0, sdkerrors.Wrap(commitmenttypes.ErrInvalidPrefix, "prefix cannot be empty") } _, ok := prefix.(commitmenttypes.MerklePrefix) if !ok { - return nil, 0, 0, sdkerrors.Wrapf(commitmenttypes.ErrInvalidPrefix, "invalid prefix type %T, expected MerklePrefix", prefix) + return nil, nil, 0, 0, sdkerrors.Wrapf(commitmenttypes.ErrInvalidPrefix, "invalid prefix type %T, expected MerklePrefix", prefix) } if proof == nil { - return nil, 0, 0, sdkerrors.Wrap(ErrInvalidProof, "proof cannot be empty") + return nil, nil, 0, 0, sdkerrors.Wrap(ErrInvalidProof, "proof cannot be empty") } timestampedSigData := &TimestampedSignatureData{} if err := cdc.UnmarshalBinaryBare(proof, timestampedSigData); err != nil { - return nil, 0, 0, sdkerrors.Wrapf(err, "failed to unmarshal proof into type %T", timestampedSigData) + return nil, nil, 0, 0, sdkerrors.Wrapf(err, "failed to unmarshal proof into type %T", timestampedSigData) } timestamp := timestampedSigData.Timestamp if len(timestampedSigData.SignatureData) == 0 { - return nil, 0, 0, sdkerrors.Wrap(ErrInvalidProof, "signature data cannot be empty") + return nil, nil, 0, 0, sdkerrors.Wrap(ErrInvalidProof, "signature data cannot be empty") } sigData, err := UnmarshalSignatureData(cdc, timestampedSigData.SignatureData) if err != nil { - return nil, 0, 0, err + return nil, nil, 0, 0, err } if cs.ConsensusState == nil { - return nil, 0, 0, sdkerrors.Wrap(clienttypes.ErrInvalidConsensus, "consensus state cannot be empty") + return nil, nil, 0, 0, sdkerrors.Wrap(clienttypes.ErrInvalidConsensus, "consensus state cannot be empty") } latestSequence := cs.GetLatestHeight().GetVersionHeight() if latestSequence != sequence { - return nil, 0, 0, sdkerrors.Wrapf( + return nil, nil, 0, 0, sdkerrors.Wrapf( sdkerrors.ErrInvalidHeight, "client state sequence != proof sequence (%d != %d)", latestSequence, sequence, ) } if cs.ConsensusState.GetTimestamp() > timestamp { - return nil, 0, 0, sdkerrors.Wrapf(ErrInvalidProof, "the consensus state timestamp is greater than the signature timestamp (%d >= %d)", cs.ConsensusState.GetTimestamp(), timestamp) + return nil, nil, 0, 0, sdkerrors.Wrapf(ErrInvalidProof, "the consensus state timestamp is greater than the signature timestamp (%d >= %d)", cs.ConsensusState.GetTimestamp(), timestamp) } - return sigData, timestamp, sequence, nil + publicKey, err := cs.ConsensusState.GetPubKey() + if err != nil { + return nil, nil, 0, 0, err + } + + return publicKey, sigData, timestamp, sequence, nil } // sets the client state to the store diff --git a/x/ibc/light-clients/06-solomachine/types/consensus_state.go b/x/ibc/light-clients/06-solomachine/types/consensus_state.go index 2b637a7ad..cebd399ff 100644 --- a/x/ibc/light-clients/06-solomachine/types/consensus_state.go +++ b/x/ibc/light-clients/06-solomachine/types/consensus_state.go @@ -27,13 +27,19 @@ func (cs ConsensusState) GetRoot() exported.Root { } // GetPubKey unmarshals the public key into a cryptotypes.PubKey type. -func (cs ConsensusState) GetPubKey() cryptotypes.PubKey { - publicKey, ok := cs.PublicKey.GetCachedValue().(cryptotypes.PubKey) - if !ok { - panic("ConsensusState PublicKey is not cryptotypes.PubKey") +// An error is returned if the public key is nil or the cached value +// is not a PubKey. +func (cs ConsensusState) GetPubKey() (cryptotypes.PubKey, error) { + if cs.PublicKey == nil { + return nil, sdkerrors.Wrap(clienttypes.ErrInvalidConsensus, "consensus state PublicKey cannot be nil") } - return publicKey + publicKey, ok := cs.PublicKey.GetCachedValue().(cryptotypes.PubKey) + if !ok { + return nil, sdkerrors.Wrap(clienttypes.ErrInvalidConsensus, "consensus state PublicKey is not cryptotypes.PubKey") + } + + return publicKey, nil } // ValidateBasic defines basic validation for the solo machine consensus state. @@ -44,7 +50,9 @@ func (cs ConsensusState) ValidateBasic() error { if cs.Diversifier != "" && strings.TrimSpace(cs.Diversifier) == "" { return sdkerrors.Wrap(clienttypes.ErrInvalidConsensus, "diversifier cannot contain only spaces") } - if cs.PublicKey == nil || cs.GetPubKey() == nil || len(cs.GetPubKey().Bytes()) == 0 { + + publicKey, err := cs.GetPubKey() + if err != nil || publicKey == nil || len(publicKey.Bytes()) == 0 { return sdkerrors.Wrap(clienttypes.ErrInvalidConsensus, "public key cannot be empty") } diff --git a/x/ibc/light-clients/06-solomachine/types/header.go b/x/ibc/light-clients/06-solomachine/types/header.go index e833a7020..cb2b55b4f 100644 --- a/x/ibc/light-clients/06-solomachine/types/header.go +++ b/x/ibc/light-clients/06-solomachine/types/header.go @@ -24,13 +24,19 @@ func (h Header) GetHeight() exported.Height { } // GetPubKey unmarshals the new public key into a cryptotypes.PubKey type. -func (h Header) GetPubKey() cryptotypes.PubKey { - publicKey, ok := h.NewPublicKey.GetCachedValue().(cryptotypes.PubKey) - if !ok { - panic("Header NewPublicKey is not cryptotypes.PubKey") +// An error is returned if the new public key is nil or the cached value +// is not a PubKey. +func (h Header) GetPubKey() (cryptotypes.PubKey, error) { + if h.NewPublicKey == nil { + return nil, sdkerrors.Wrap(ErrInvalidHeader, "header NewPublicKey cannot be nil") } - return publicKey + publicKey, ok := h.NewPublicKey.GetCachedValue().(cryptotypes.PubKey) + if !ok { + return nil, sdkerrors.Wrap(ErrInvalidHeader, "header NewPublicKey is not cryptotypes.PubKey") + } + + return publicKey, nil } // ValidateBasic ensures that the sequence, signature and public key have all @@ -52,7 +58,8 @@ func (h Header) ValidateBasic() error { return sdkerrors.Wrap(clienttypes.ErrInvalidHeader, "signature cannot be empty") } - if h.NewPublicKey == nil || h.GetPubKey() == nil || len(h.GetPubKey().Bytes()) == 0 { + newPublicKey, err := h.GetPubKey() + if err != nil || newPublicKey == nil || len(newPublicKey.Bytes()) == 0 { return sdkerrors.Wrap(clienttypes.ErrInvalidHeader, "new public key cannot be empty") } diff --git a/x/ibc/light-clients/06-solomachine/types/misbehaviour_handle.go b/x/ibc/light-clients/06-solomachine/types/misbehaviour_handle.go index 2fcbe75c7..721b84f82 100644 --- a/x/ibc/light-clients/06-solomachine/types/misbehaviour_handle.go +++ b/x/ibc/light-clients/06-solomachine/types/misbehaviour_handle.go @@ -79,7 +79,12 @@ func verifySignatureAndData(cdc codec.BinaryMarshaler, clientState ClientState, return err } - if err := VerifySignature(clientState.ConsensusState.GetPubKey(), data, sigData); err != nil { + publicKey, err := clientState.ConsensusState.GetPubKey() + if err != nil { + return err + } + + if err := VerifySignature(publicKey, data, sigData); err != nil { return err } diff --git a/x/ibc/light-clients/06-solomachine/types/misbehaviour_handle_test.go b/x/ibc/light-clients/06-solomachine/types/misbehaviour_handle_test.go index fd5871adc..f247ed233 100644 --- a/x/ibc/light-clients/06-solomachine/types/misbehaviour_handle_test.go +++ b/x/ibc/light-clients/06-solomachine/types/misbehaviour_handle_test.go @@ -241,6 +241,16 @@ func (suite *SoloMachineTestSuite) TestCheckMisbehaviourAndUpdateState() { }, false, }, + { + "consensus state pubkey is nil", + func() { + cs := solomachine.ClientState() + cs.ConsensusState.PublicKey = nil + clientState = cs + misbehaviour = solomachine.CreateMisbehaviour() + }, + false, + }, } for _, tc := range testCases { diff --git a/x/ibc/light-clients/06-solomachine/types/proposal_handle.go b/x/ibc/light-clients/06-solomachine/types/proposal_handle.go index f715ebb4c..b55e612b3 100644 --- a/x/ibc/light-clients/06-solomachine/types/proposal_handle.go +++ b/x/ibc/light-clients/06-solomachine/types/proposal_handle.go @@ -33,7 +33,17 @@ func (cs ClientState) CheckProposedHeaderAndUpdateState( ) } - if reflect.DeepEqual(cs.ConsensusState.GetPubKey(), smHeader.GetPubKey()) { + consensusPublicKey, err := cs.ConsensusState.GetPubKey() + if err != nil { + return nil, nil, sdkerrors.Wrap(err, "failed to get consensus public key") + } + + headerPublicKey, err := smHeader.GetPubKey() + if err != nil { + return nil, nil, sdkerrors.Wrap(err, "failed to get header public key") + } + + if reflect.DeepEqual(consensusPublicKey, headerPublicKey) { return nil, nil, sdkerrors.Wrapf( clienttypes.ErrInvalidHeader, "new public key in header equals current public key", ) diff --git a/x/ibc/light-clients/06-solomachine/types/proposal_handle_test.go b/x/ibc/light-clients/06-solomachine/types/proposal_handle_test.go index c36e252d4..86d5c78dc 100644 --- a/x/ibc/light-clients/06-solomachine/types/proposal_handle_test.go +++ b/x/ibc/light-clients/06-solomachine/types/proposal_handle_test.go @@ -69,7 +69,14 @@ func (suite *SoloMachineTestSuite) TestCheckProposedHeaderAndUpdateState() { suite.Require().True(ok) suite.Require().Equal(cs.(*types.ClientState).ConsensusState, consState) - suite.Require().Equal(smHeader.GetPubKey(), smConsState.GetPubKey()) + + headerPubKey, err := smHeader.GetPubKey() + suite.Require().NoError(err) + + consStatePubKey, err := smConsState.GetPubKey() + suite.Require().NoError(err) + + suite.Require().Equal(headerPubKey, consStatePubKey) suite.Require().Equal(smHeader.NewDiversifier, smConsState.Diversifier) suite.Require().Equal(smHeader.Timestamp, smConsState.Timestamp) suite.Require().Equal(smHeader.GetHeight().GetVersionHeight(), cs.(*types.ClientState).Sequence) diff --git a/x/ibc/light-clients/06-solomachine/types/update.go b/x/ibc/light-clients/06-solomachine/types/update.go index 4deb8833d..4cf31fd98 100644 --- a/x/ibc/light-clients/06-solomachine/types/update.go +++ b/x/ibc/light-clients/06-solomachine/types/update.go @@ -62,7 +62,12 @@ func checkHeader(cdc codec.BinaryMarshaler, clientState *ClientState, header *He return err } - if err := VerifySignature(clientState.ConsensusState.GetPubKey(), data, sigData); err != nil { + publicKey, err := clientState.ConsensusState.GetPubKey() + if err != nil { + return err + } + + if err := VerifySignature(publicKey, data, sigData); err != nil { return sdkerrors.Wrap(ErrInvalidHeader, err.Error()) } diff --git a/x/ibc/light-clients/06-solomachine/types/update_test.go b/x/ibc/light-clients/06-solomachine/types/update_test.go index a58b00dc4..74a29017b 100644 --- a/x/ibc/light-clients/06-solomachine/types/update_test.go +++ b/x/ibc/light-clients/06-solomachine/types/update_test.go @@ -143,6 +143,16 @@ func (suite *SoloMachineTestSuite) TestCheckHeaderAndUpdateState() { }, false, }, + { + "consensus state public key is nil", + func() { + cs := solomachine.ClientState() + cs.ConsensusState.PublicKey = nil + clientState = cs + header = solomachine.CreateHeader() + }, + false, + }, } for _, tc := range testCases { From 136f3ade88930e1645fcf350a75cccfdcbc4d246 Mon Sep 17 00:00:00 2001 From: Federico Kunze <31522760+fedekunze@users.noreply.github.com> Date: Wed, 11 Nov 2020 12:07:29 +0100 Subject: [PATCH 22/24] ibc: client params allowlist (#7855) * ibc: client params allowlist * genesis and gRPC * client * lint * spec * fixes * validate localhost client * move client types back to exported * update genesis * sort clients by id --- proto/ibc/core/client/v1/client.proto | 91 +- proto/ibc/core/client/v1/genesis.proto | 8 +- proto/ibc/core/client/v1/query.proto | 19 +- proto/ibc/core/client/v1/tx.proto | 93 + simapp/app.go | 3 +- x/ibc/applications/transfer/client/cli/cli.go | 1 + .../applications/transfer/client/cli/query.go | 4 +- x/ibc/applications/transfer/handler_test.go | 3 +- .../transfer/keeper/relay_test.go | 19 +- x/ibc/applications/transfer/module_test.go | 7 +- x/ibc/core/02-client/client/cli/cli.go | 1 + x/ibc/core/02-client/client/cli/query.go | 27 + x/ibc/core/02-client/genesis.go | 11 + x/ibc/core/02-client/keeper/client.go | 8 + x/ibc/core/02-client/keeper/client_test.go | 10 +- x/ibc/core/02-client/keeper/grpc_query.go | 17 +- .../core/02-client/keeper/grpc_query_test.go | 24 +- x/ibc/core/02-client/keeper/keeper.go | 16 +- x/ibc/core/02-client/keeper/keeper_test.go | 34 +- x/ibc/core/02-client/keeper/params.go | 23 + x/ibc/core/02-client/keeper/params_test.go | 17 + x/ibc/core/02-client/keeper/proposal_test.go | 6 +- x/ibc/core/02-client/proposal_handler_test.go | 3 +- x/ibc/core/02-client/types/client.go | 21 + x/ibc/core/02-client/types/client.pb.go | 2234 ++--------------- x/ibc/core/02-client/types/client_test.go | 3 +- x/ibc/core/02-client/types/genesis.go | 13 +- x/ibc/core/02-client/types/genesis.pb.go | 107 +- x/ibc/core/02-client/types/genesis_test.go | 137 +- x/ibc/core/02-client/types/params.go | 71 + x/ibc/core/02-client/types/params_test.go | 29 + x/ibc/core/02-client/types/query.pb.go | 452 +++- x/ibc/core/02-client/types/query.pb.gw.go | 62 + x/ibc/core/02-client/types/tx.pb.go | 2128 ++++++++++++++++ .../03-connection/keeper/grpc_query_test.go | 12 +- .../03-connection/keeper/handshake_test.go | 118 +- .../core/03-connection/keeper/keeper_test.go | 13 +- .../core/03-connection/keeper/verify_test.go | 14 +- .../core/04-channel/keeper/grpc_query_test.go | 6 +- .../core/04-channel/keeper/handshake_test.go | 66 +- x/ibc/core/04-channel/keeper/keeper_test.go | 3 +- x/ibc/core/04-channel/keeper/packet_test.go | 10 +- x/ibc/core/04-channel/keeper/timeout_test.go | 26 +- x/ibc/core/exported/client.go | 8 +- x/ibc/core/genesis_test.go | 7 +- x/ibc/core/keeper/grpc_query.go | 5 + x/ibc/core/keeper/keeper.go | 6 +- x/ibc/core/keeper/msg_server_test.go | 24 +- x/ibc/core/spec/07_params.md | 21 + x/ibc/core/spec/README.md | 1 + .../06-solomachine/types/client_state.go | 5 +- .../06-solomachine/types/client_state_test.go | 4 +- .../06-solomachine/types/consensus_state.go | 2 +- .../types/consensus_state_test.go | 3 +- .../06-solomachine/types/header.go | 2 +- .../06-solomachine/types/header_test.go | 3 +- .../06-solomachine/types/misbehaviour.go | 2 +- .../06-solomachine/types/misbehaviour_test.go | 3 +- .../06-solomachine/types/solomachine_test.go | 2 +- .../07-tendermint/types/client_state.go | 5 +- .../07-tendermint/types/client_state_test.go | 4 +- .../07-tendermint/types/consensus_state.go | 2 +- .../types/consensus_state_test.go | 9 +- .../07-tendermint/types/header.go | 2 +- .../07-tendermint/types/header_test.go | 3 +- .../07-tendermint/types/misbehaviour.go | 3 +- .../07-tendermint/types/misbehaviour_test.go | 3 +- .../types/proposal_handle_test.go | 7 +- .../07-tendermint/types/upgrade_test.go | 22 +- x/ibc/testing/chain.go | 11 +- x/ibc/testing/coordinator.go | 36 +- x/staking/types/staking.pb.go | 1184 +++++---- 72 files changed, 4291 insertions(+), 3068 deletions(-) create mode 100644 proto/ibc/core/client/v1/tx.proto create mode 100644 x/ibc/core/02-client/keeper/params.go create mode 100644 x/ibc/core/02-client/keeper/params_test.go create mode 100644 x/ibc/core/02-client/types/params.go create mode 100644 x/ibc/core/02-client/types/params_test.go create mode 100644 x/ibc/core/02-client/types/tx.pb.go create mode 100644 x/ibc/core/spec/07_params.md diff --git a/proto/ibc/core/client/v1/client.proto b/proto/ibc/core/client/v1/client.proto index 118318c24..a5d2b0f19 100644 --- a/proto/ibc/core/client/v1/client.proto +++ b/proto/ibc/core/client/v1/client.proto @@ -6,91 +6,6 @@ option go_package = "github.com/cosmos/cosmos-sdk/x/ibc/core/02-client/types"; import "gogoproto/gogo.proto"; import "google/protobuf/any.proto"; -// Msg defines the ibc/client Msg service. -service Msg { - // CreateClient defines a rpc handler method for MsgCreateClient. - rpc CreateClient(MsgCreateClient) returns (MsgCreateClientResponse); - - // UpdateClient defines a rpc handler method for MsgUpdateClient. - rpc UpdateClient(MsgUpdateClient) returns (MsgUpdateClientResponse); - - // UpgradeClient defines a rpc handler method for MsgUpgradeClient. - rpc UpgradeClient(MsgUpgradeClient) returns (MsgUpgradeClientResponse); - - // SubmitMisbehaviour defines a rpc handler method for MsgSubmitMisbehaviour. - rpc SubmitMisbehaviour(MsgSubmitMisbehaviour) returns (MsgSubmitMisbehaviourResponse); -} - -// MsgCreateClient defines a message to create an IBC client -message MsgCreateClient { - option (gogoproto.equal) = false; - option (gogoproto.goproto_getters) = false; - - // client unique identifier - string client_id = 1 [(gogoproto.moretags) = "yaml:\"client_id\""]; - // light client state - google.protobuf.Any client_state = 2 [(gogoproto.moretags) = "yaml:\"client_state\""]; - // consensus state associated with the client that corresponds to a given - // height. - google.protobuf.Any consensus_state = 3 [(gogoproto.moretags) = "yaml:\"consensus_state\""]; - // signer address - string signer = 4; -} - -// MsgCreateClientResponse defines the Msg/CreateClient response type. -message MsgCreateClientResponse { } - -// MsgUpdateClient defines an sdk.Msg to update a IBC client state using -// the given header. -message MsgUpdateClient { - option (gogoproto.equal) = false; - option (gogoproto.goproto_getters) = false; - - // client unique identifier - string client_id = 1 [(gogoproto.moretags) = "yaml:\"client_id\""]; - // header to update the light client - google.protobuf.Any header = 2; - // signer address - string signer = 3; -} - -// MsgUpdateClientResponse defines the Msg/UpdateClient response type. -message MsgUpdateClientResponse { } - -// MsgUpgradeClient defines an sdk.Msg to upgrade an IBC client to a new client state -message MsgUpgradeClient { - // client unique identifier - string client_id = 1 [(gogoproto.moretags) = "yaml:\"client_id\""]; - // upgraded client state - google.protobuf.Any client_state = 2 [(gogoproto.moretags) = "yaml:\"client_state\""]; - // height at which old chain halts and upgrades (i.e last block executed) - Height upgrade_height = 3 [(gogoproto.moretags) = "yaml:\"upgrade_height\""]; - // proof that old chain committed to new client - bytes proof_upgrade = 4 [(gogoproto.moretags) = "yaml:\"proof_upgrade\""]; - // signer address - string signer = 5; -} - -// MsgUpgradeClientResponse defines the Msg/UpgradeClient response type. -message MsgUpgradeClientResponse { } - -// MsgSubmitMisbehaviour defines an sdk.Msg type that submits Evidence for -// light client misbehaviour. -message MsgSubmitMisbehaviour { - option (gogoproto.equal) = false; - option (gogoproto.goproto_getters) = false; - - // client unique identifier - string client_id = 1 [(gogoproto.moretags) = "yaml:\"client_id\""]; - // misbehaviour used for freezing the light client - google.protobuf.Any misbehaviour = 2; - // signer address - string signer = 3; -} - -// MsgSubmitMisbehaviourResponse defines the Msg/SubmitMisbehaviour response type. -message MsgSubmitMisbehaviourResponse { } - // IdentifiedClientState defines a client state with an additional client // identifier field. message IdentifiedClientState { @@ -151,3 +66,9 @@ message Height { // the height within the given version uint64 version_height = 2 [(gogoproto.moretags) = "yaml:\"version_height\""]; } + +// Params defines the set of IBC light client parameters. +message Params { + // allowed_clients defines the list of allowed client state types. + repeated string allowed_clients = 1 [(gogoproto.moretags) = "yaml:\"allowed_clients\""]; +} diff --git a/proto/ibc/core/client/v1/genesis.proto b/proto/ibc/core/client/v1/genesis.proto index 1041ca944..110140e23 100644 --- a/proto/ibc/core/client/v1/genesis.proto +++ b/proto/ibc/core/client/v1/genesis.proto @@ -9,13 +9,17 @@ import "gogoproto/gogo.proto"; // GenesisState defines the ibc client submodule's genesis state. message GenesisState { // client states with their corresponding identifiers - repeated IdentifiedClientState clients = 1 [(gogoproto.nullable) = false]; + repeated IdentifiedClientState clients = 1 [ + (gogoproto.nullable) = false, + (gogoproto.castrepeated) = "IdentifiedClientStates" + ]; // consensus states from each client repeated ClientConsensusStates clients_consensus = 2 [ (gogoproto.nullable) = false, (gogoproto.castrepeated) = "ClientsConsensusStates", (gogoproto.moretags) = "yaml:\"clients_consensus\"" ]; + Params params = 3 [ (gogoproto.nullable) = false]; // create localhost on initialization - bool create_localhost = 3 [(gogoproto.moretags) = "yaml:\"create_localhost\""]; + bool create_localhost = 4 [(gogoproto.moretags) = "yaml:\"create_localhost\""]; } diff --git a/proto/ibc/core/client/v1/query.proto b/proto/ibc/core/client/v1/query.proto index db580a260..038b97bc4 100644 --- a/proto/ibc/core/client/v1/query.proto +++ b/proto/ibc/core/client/v1/query.proto @@ -33,6 +33,11 @@ service Query { rpc ConsensusStates(QueryConsensusStatesRequest) returns (QueryConsensusStatesResponse) { option (google.api.http).get = "/ibc/core/client/v1beta1/consensus_states/{client_id}"; } + + // ClientParams queries all parameters of the ibc client. + rpc ClientParams(QueryClientParamsRequest) returns (QueryClientParamsResponse) { + option (google.api.http).get = "/ibc/client/v1beta1/params"; + } } // QueryClientStateRequest is the request type for the Query/ClientState RPC @@ -65,7 +70,10 @@ message QueryClientStatesRequest { // method. message QueryClientStatesResponse { // list of stored ClientStates of the chain. - repeated IdentifiedClientState client_states = 1; + repeated IdentifiedClientState client_states = 1 [ + (gogoproto.nullable) = false, + (gogoproto.castrepeated) = "IdentifiedClientStates" + ]; // pagination response cosmos.base.query.v1beta1.PageResponse pagination = 2; } @@ -113,3 +121,12 @@ message QueryConsensusStatesResponse { // pagination response cosmos.base.query.v1beta1.PageResponse pagination = 2; } + +// QueryClientParamsRequest is the request type for the Query/ClientParams RPC method. +message QueryClientParamsRequest {} + +// QueryClientParamsResponse is the response type for the Query/ClientParams RPC method. +message QueryClientParamsResponse { + // params defines the parameters of the module. + Params params = 1; +} diff --git a/proto/ibc/core/client/v1/tx.proto b/proto/ibc/core/client/v1/tx.proto new file mode 100644 index 000000000..efe843cba --- /dev/null +++ b/proto/ibc/core/client/v1/tx.proto @@ -0,0 +1,93 @@ +syntax = "proto3"; +package ibc.core.client.v1; + +option go_package = "github.com/cosmos/cosmos-sdk/x/ibc/core/02-client/types"; + +import "gogoproto/gogo.proto"; +import "google/protobuf/any.proto"; +import "ibc/core/client/v1/client.proto"; + +// Msg defines the ibc/client Msg service. +service Msg { + // CreateClient defines a rpc handler method for MsgCreateClient. + rpc CreateClient(MsgCreateClient) returns (MsgCreateClientResponse); + + // UpdateClient defines a rpc handler method for MsgUpdateClient. + rpc UpdateClient(MsgUpdateClient) returns (MsgUpdateClientResponse); + + // UpgradeClient defines a rpc handler method for MsgUpgradeClient. + rpc UpgradeClient(MsgUpgradeClient) returns (MsgUpgradeClientResponse); + + // SubmitMisbehaviour defines a rpc handler method for MsgSubmitMisbehaviour. + rpc SubmitMisbehaviour(MsgSubmitMisbehaviour) returns (MsgSubmitMisbehaviourResponse); +} + +// MsgCreateClient defines a message to create an IBC client +message MsgCreateClient { + option (gogoproto.equal) = false; + option (gogoproto.goproto_getters) = false; + + // client unique identifier + string client_id = 1 [(gogoproto.moretags) = "yaml:\"client_id\""]; + // light client state + google.protobuf.Any client_state = 2 [(gogoproto.moretags) = "yaml:\"client_state\""]; + // consensus state associated with the client that corresponds to a given + // height. + google.protobuf.Any consensus_state = 3 [(gogoproto.moretags) = "yaml:\"consensus_state\""]; + // signer address + string signer = 4; +} + +// MsgCreateClientResponse defines the Msg/CreateClient response type. +message MsgCreateClientResponse { } + +// MsgUpdateClient defines an sdk.Msg to update a IBC client state using +// the given header. +message MsgUpdateClient { + option (gogoproto.equal) = false; + option (gogoproto.goproto_getters) = false; + + // client unique identifier + string client_id = 1 [(gogoproto.moretags) = "yaml:\"client_id\""]; + // header to update the light client + google.protobuf.Any header = 2; + // signer address + string signer = 3; +} + +// MsgUpdateClientResponse defines the Msg/UpdateClient response type. +message MsgUpdateClientResponse { } + +// MsgUpgradeClient defines an sdk.Msg to upgrade an IBC client to a new client state +message MsgUpgradeClient { + // client unique identifier + string client_id = 1 [(gogoproto.moretags) = "yaml:\"client_id\""]; + // upgraded client state + google.protobuf.Any client_state = 2 [(gogoproto.moretags) = "yaml:\"client_state\""]; + // height at which old chain halts and upgrades (i.e last block executed) + Height upgrade_height = 3 [(gogoproto.moretags) = "yaml:\"upgrade_height\""]; + // proof that old chain committed to new client + bytes proof_upgrade = 4 [(gogoproto.moretags) = "yaml:\"proof_upgrade\""]; + // signer address + string signer = 5; +} + +// MsgUpgradeClientResponse defines the Msg/UpgradeClient response type. +message MsgUpgradeClientResponse { } + +// MsgSubmitMisbehaviour defines an sdk.Msg type that submits Evidence for +// light client misbehaviour. +message MsgSubmitMisbehaviour { + option (gogoproto.equal) = false; + option (gogoproto.goproto_getters) = false; + + // client unique identifier + string client_id = 1 [(gogoproto.moretags) = "yaml:\"client_id\""]; + // misbehaviour used for freezing the light client + google.protobuf.Any misbehaviour = 2; + // signer address + string signer = 3; +} + +// MsgSubmitMisbehaviourResponse defines the Msg/SubmitMisbehaviour response type. +message MsgSubmitMisbehaviourResponse { } diff --git a/simapp/app.go b/simapp/app.go index a8c9e584b..8aaa00732 100644 --- a/simapp/app.go +++ b/simapp/app.go @@ -279,7 +279,7 @@ func NewSimApp( // Create IBC Keeper app.IBCKeeper = ibckeeper.NewKeeper( - appCodec, keys[ibchost.StoreKey], app.StakingKeeper, scopedIBCKeeper, + appCodec, keys[ibchost.StoreKey], app.GetSubspace(ibchost.ModuleName), app.StakingKeeper, scopedIBCKeeper, ) // register the proposal types @@ -609,6 +609,7 @@ func initParamsKeeper(appCodec codec.BinaryMarshaler, legacyAmino *codec.LegacyA paramsKeeper.Subspace(govtypes.ModuleName).WithKeyTable(govtypes.ParamKeyTable()) paramsKeeper.Subspace(crisistypes.ModuleName) paramsKeeper.Subspace(ibctransfertypes.ModuleName) + paramsKeeper.Subspace(ibchost.ModuleName) return paramsKeeper } diff --git a/x/ibc/applications/transfer/client/cli/cli.go b/x/ibc/applications/transfer/client/cli/cli.go index 9686afaa1..d3ca8341e 100644 --- a/x/ibc/applications/transfer/client/cli/cli.go +++ b/x/ibc/applications/transfer/client/cli/cli.go @@ -18,6 +18,7 @@ func GetQueryCmd() *cobra.Command { queryCmd.AddCommand( GetCmdQueryDenomTrace(), GetCmdQueryDenomTraces(), + GetCmdParams(), ) return queryCmd diff --git a/x/ibc/applications/transfer/client/cli/query.go b/x/ibc/applications/transfer/client/cli/query.go index c0953d7ca..3d158ed59 100644 --- a/x/ibc/applications/transfer/client/cli/query.go +++ b/x/ibc/applications/transfer/client/cli/query.go @@ -86,8 +86,8 @@ func GetCmdQueryDenomTraces() *cobra.Command { return cmd } -// QueryParamsCmd returns the command handler for ibc-transfer parameter querying. -func QueryParamsCmd() *cobra.Command { +// GetCmdParams returns the command handler for ibc-transfer parameter querying. +func GetCmdParams() *cobra.Command { cmd := &cobra.Command{ Use: "params", Short: "Query the current ibc-transfer parameters", diff --git a/x/ibc/applications/transfer/handler_test.go b/x/ibc/applications/transfer/handler_test.go index fd6b686fe..b1ee24f2e 100644 --- a/x/ibc/applications/transfer/handler_test.go +++ b/x/ibc/applications/transfer/handler_test.go @@ -9,6 +9,7 @@ import ( "github.com/cosmos/cosmos-sdk/x/ibc/applications/transfer/types" clienttypes "github.com/cosmos/cosmos-sdk/x/ibc/core/02-client/types" channeltypes "github.com/cosmos/cosmos-sdk/x/ibc/core/04-channel/types" + "github.com/cosmos/cosmos-sdk/x/ibc/core/exported" ibctesting "github.com/cosmos/cosmos-sdk/x/ibc/testing" ) @@ -31,7 +32,7 @@ func (suite *TransferTestSuite) SetupTest() { // constructs a send from chainA to chainB on the established channel/connection // and sends the same coin back from chainB to chainA. func (suite *TransferTestSuite) TestHandleMsgTransfer() { - clientA, clientB, connA, connB := suite.coordinator.SetupClientConnections(suite.chainA, suite.chainB, ibctesting.Tendermint) + clientA, clientB, connA, connB := suite.coordinator.SetupClientConnections(suite.chainA, suite.chainB, exported.Tendermint) channelA, channelB := suite.coordinator.CreateTransferChannels(suite.chainA, suite.chainB, connA, connB, channeltypes.UNORDERED) originalBalance := suite.chainA.App.BankKeeper.GetBalance(suite.chainA.GetContext(), suite.chainA.SenderAccount.GetAddress(), sdk.DefaultBondDenom) timeoutHeight := clienttypes.NewHeight(0, 110) diff --git a/x/ibc/applications/transfer/keeper/relay_test.go b/x/ibc/applications/transfer/keeper/relay_test.go index 738de9e80..7878c5935 100644 --- a/x/ibc/applications/transfer/keeper/relay_test.go +++ b/x/ibc/applications/transfer/keeper/relay_test.go @@ -8,6 +8,7 @@ import ( clienttypes "github.com/cosmos/cosmos-sdk/x/ibc/core/02-client/types" channeltypes "github.com/cosmos/cosmos-sdk/x/ibc/core/04-channel/types" host "github.com/cosmos/cosmos-sdk/x/ibc/core/24-host" + "github.com/cosmos/cosmos-sdk/x/ibc/core/exported" ibctesting "github.com/cosmos/cosmos-sdk/x/ibc/testing" ) @@ -28,28 +29,28 @@ func (suite *KeeperTestSuite) TestSendTransfer() { }{ {"successful transfer from source chain", func() { - _, _, connA, connB := suite.coordinator.SetupClientConnections(suite.chainA, suite.chainB, ibctesting.Tendermint) + _, _, connA, connB := suite.coordinator.SetupClientConnections(suite.chainA, suite.chainB, exported.Tendermint) channelA, channelB = suite.coordinator.CreateTransferChannels(suite.chainA, suite.chainB, connA, connB, channeltypes.UNORDERED) amount = sdk.NewCoin(sdk.DefaultBondDenom, sdk.NewInt(100)) }, true, true}, {"successful transfer with coin from counterparty chain", func() { // send coin from chainA back to chainB - _, _, connA, connB := suite.coordinator.SetupClientConnections(suite.chainA, suite.chainB, ibctesting.Tendermint) + _, _, connA, connB := suite.coordinator.SetupClientConnections(suite.chainA, suite.chainB, exported.Tendermint) channelA, channelB = suite.coordinator.CreateTransferChannels(suite.chainA, suite.chainB, connA, connB, channeltypes.UNORDERED) amount = types.GetTransferCoin(channelA.PortID, channelA.ID, sdk.DefaultBondDenom, 100) }, false, true}, {"source channel not found", func() { // channel references wrong ID - _, _, connA, connB := suite.coordinator.SetupClientConnections(suite.chainA, suite.chainB, ibctesting.Tendermint) + _, _, connA, connB := suite.coordinator.SetupClientConnections(suite.chainA, suite.chainB, exported.Tendermint) channelA, channelB = suite.coordinator.CreateTransferChannels(suite.chainA, suite.chainB, connA, connB, channeltypes.UNORDERED) channelA.ID = ibctesting.InvalidID amount = sdk.NewCoin(sdk.DefaultBondDenom, sdk.NewInt(100)) }, true, false}, {"next seq send not found", func() { - _, _, connA, connB := suite.coordinator.SetupClientConnections(suite.chainA, suite.chainB, ibctesting.Tendermint) + _, _, connA, connB := suite.coordinator.SetupClientConnections(suite.chainA, suite.chainB, exported.Tendermint) channelA = connA.NextTestChannel(ibctesting.TransferPort) channelB = connB.NextTestChannel(ibctesting.TransferPort) // manually create channel so next seq send is never set @@ -66,20 +67,20 @@ func (suite *KeeperTestSuite) TestSendTransfer() { // - source chain {"send coin failed", func() { - _, _, connA, connB := suite.coordinator.SetupClientConnections(suite.chainA, suite.chainB, ibctesting.Tendermint) + _, _, connA, connB := suite.coordinator.SetupClientConnections(suite.chainA, suite.chainB, exported.Tendermint) channelA, channelB = suite.coordinator.CreateTransferChannels(suite.chainA, suite.chainB, connA, connB, channeltypes.UNORDERED) amount = sdk.NewCoin("randomdenom", sdk.NewInt(100)) }, true, false}, // - receiving chain {"send from module account failed", func() { - _, _, connA, connB := suite.coordinator.SetupClientConnections(suite.chainA, suite.chainB, ibctesting.Tendermint) + _, _, connA, connB := suite.coordinator.SetupClientConnections(suite.chainA, suite.chainB, exported.Tendermint) channelA, channelB = suite.coordinator.CreateTransferChannels(suite.chainA, suite.chainB, connA, connB, channeltypes.UNORDERED) amount = types.GetTransferCoin(channelA.PortID, channelA.ID, " randomdenom", 100) }, false, false}, {"channel capability not found", func() { - _, _, connA, connB := suite.coordinator.SetupClientConnections(suite.chainA, suite.chainB, ibctesting.Tendermint) + _, _, connA, connB := suite.coordinator.SetupClientConnections(suite.chainA, suite.chainB, exported.Tendermint) channelA, channelB = suite.coordinator.CreateTransferChannels(suite.chainA, suite.chainB, connA, connB, channeltypes.UNORDERED) cap := suite.chainA.GetChannelCapability(channelA.PortID, channelA.ID) @@ -177,7 +178,7 @@ func (suite *KeeperTestSuite) TestOnRecvPacket() { suite.Run(fmt.Sprintf("Case %s", tc.msg), func() { suite.SetupTest() // reset - clientA, clientB, connA, connB := suite.coordinator.SetupClientConnections(suite.chainA, suite.chainB, ibctesting.Tendermint) + clientA, clientB, connA, connB := suite.coordinator.SetupClientConnections(suite.chainA, suite.chainB, exported.Tendermint) channelA, channelB = suite.coordinator.CreateTransferChannels(suite.chainA, suite.chainB, connA, connB, channeltypes.UNORDERED) receiver = suite.chainB.SenderAccount.GetAddress().String() // must be explicitly changed in malleate @@ -365,7 +366,7 @@ func (suite *KeeperTestSuite) TestOnTimeoutPacket() { suite.Run(fmt.Sprintf("Case %s", tc.msg), func() { suite.SetupTest() // reset - _, _, connA, connB := suite.coordinator.SetupClientConnections(suite.chainA, suite.chainB, ibctesting.Tendermint) + _, _, connA, connB := suite.coordinator.SetupClientConnections(suite.chainA, suite.chainB, exported.Tendermint) channelA, channelB = suite.coordinator.CreateTransferChannels(suite.chainA, suite.chainB, connA, connB, channeltypes.UNORDERED) amount = sdk.NewInt(100) // must be explicitly changed sender = suite.chainA.SenderAccount.GetAddress().String() diff --git a/x/ibc/applications/transfer/module_test.go b/x/ibc/applications/transfer/module_test.go index 7f3cec0bd..b0d0fd10e 100644 --- a/x/ibc/applications/transfer/module_test.go +++ b/x/ibc/applications/transfer/module_test.go @@ -5,6 +5,7 @@ import ( "github.com/cosmos/cosmos-sdk/x/ibc/applications/transfer/types" channeltypes "github.com/cosmos/cosmos-sdk/x/ibc/core/04-channel/types" host "github.com/cosmos/cosmos-sdk/x/ibc/core/24-host" + "github.com/cosmos/cosmos-sdk/x/ibc/core/exported" ibctesting "github.com/cosmos/cosmos-sdk/x/ibc/testing" ) @@ -54,7 +55,7 @@ func (suite *TransferTestSuite) TestOnChanOpenInit() { suite.Run(tc.name, func() { suite.SetupTest() // reset - _, _, connA, _ = suite.coordinator.SetupClientConnections(suite.chainA, suite.chainB, ibctesting.Tendermint) + _, _, connA, _ = suite.coordinator.SetupClientConnections(suite.chainA, suite.chainB, exported.Tendermint) testChannel = connA.NextTestChannel(ibctesting.TransferPort) counterparty := channeltypes.NewCounterparty(testChannel.PortID, testChannel.ID) channel = &channeltypes.Channel{ @@ -142,7 +143,7 @@ func (suite *TransferTestSuite) TestOnChanOpenTry() { suite.Run(tc.name, func() { suite.SetupTest() // reset - _, _, connA, _ = suite.coordinator.SetupClientConnections(suite.chainA, suite.chainB, ibctesting.Tendermint) + _, _, connA, _ = suite.coordinator.SetupClientConnections(suite.chainA, suite.chainB, exported.Tendermint) testChannel = connA.NextTestChannel(ibctesting.TransferPort) counterparty := channeltypes.NewCounterparty(testChannel.PortID, testChannel.ID) channel = &channeltypes.Channel{ @@ -208,7 +209,7 @@ func (suite *TransferTestSuite) TestOnChanOpenAck() { suite.Run(tc.name, func() { suite.SetupTest() // reset - _, _, connA, _ = suite.coordinator.SetupClientConnections(suite.chainA, suite.chainB, ibctesting.Tendermint) + _, _, connA, _ = suite.coordinator.SetupClientConnections(suite.chainA, suite.chainB, exported.Tendermint) testChannel = connA.NextTestChannel(ibctesting.TransferPort) counterpartyVersion = types.Version diff --git a/x/ibc/core/02-client/client/cli/cli.go b/x/ibc/core/02-client/client/cli/cli.go index 32aafc82c..375d8f636 100644 --- a/x/ibc/core/02-client/client/cli/cli.go +++ b/x/ibc/core/02-client/client/cli/cli.go @@ -24,6 +24,7 @@ func GetQueryCmd() *cobra.Command { GetCmdQueryConsensusState(), GetCmdQueryHeader(), GetCmdNodeConsensusState(), + GetCmdParams(), ) return queryCmd diff --git a/x/ibc/core/02-client/client/cli/query.go b/x/ibc/core/02-client/client/cli/query.go index 9d4ad4c19..0140cb785 100644 --- a/x/ibc/core/02-client/client/cli/query.go +++ b/x/ibc/core/02-client/client/cli/query.go @@ -250,3 +250,30 @@ func GetCmdNodeConsensusState() *cobra.Command { return cmd } + +// GetCmdParams returns the command handler for ibc client parameter querying. +func GetCmdParams() *cobra.Command { + cmd := &cobra.Command{ + Use: "params", + Short: "Query the current ibc client parameters", + Long: "Query the current ibc client parameters", + Args: cobra.NoArgs, + Example: fmt.Sprintf("%s query %s %s params", version.AppName, host.ModuleName, types.SubModuleName), + RunE: func(cmd *cobra.Command, _ []string) error { + clientCtx := client.GetClientContextFromCmd(cmd) + clientCtx, err := client.ReadQueryCommandFlags(clientCtx, cmd.Flags()) + if err != nil { + return err + } + + queryClient := types.NewQueryClient(clientCtx) + + res, _ := queryClient.ClientParams(context.Background(), &types.QueryClientParamsRequest{}) + return clientCtx.PrintOutput(res.Params) + }, + } + + flags.AddQueryFlagsToCmd(cmd) + + return cmd +} diff --git a/x/ibc/core/02-client/genesis.go b/x/ibc/core/02-client/genesis.go index cda4f7ed7..988e297c1 100644 --- a/x/ibc/core/02-client/genesis.go +++ b/x/ibc/core/02-client/genesis.go @@ -13,12 +13,18 @@ import ( // InitGenesis initializes the ibc client submodule's state from a provided genesis // state. func InitGenesis(ctx sdk.Context, k keeper.Keeper, gs types.GenesisState) { + k.SetParams(ctx, gs.Params) + for _, client := range gs.Clients { cs, ok := client.ClientState.GetCachedValue().(exported.ClientState) if !ok { panic("invalid client state") } + if !gs.Params.IsAllowedClient(cs.ClientType()) { + panic(fmt.Sprintf("client state type %s is not registered on the allowlist", cs.ClientType())) + } + k.SetClientState(ctx, client.ClientId, cs) } @@ -49,6 +55,10 @@ func InitGenesis(ctx sdk.Context, k keeper.Keeper, gs types.GenesisState) { ctx.ChainID(), types.NewHeight(version, uint64(ctx.BlockHeight())), ) + if err := clientState.Validate(); err != nil { + panic(err) + } + if err := k.CreateClient(ctx, exported.Localhost, clientState, nil); err != nil { panic(err) } @@ -61,6 +71,7 @@ func ExportGenesis(ctx sdk.Context, k keeper.Keeper) types.GenesisState { return types.GenesisState{ Clients: k.GetAllGenesisClients(ctx), ClientsConsensus: k.GetAllConsensusStates(ctx), + Params: k.GetParams(ctx), CreateLocalhost: false, } } diff --git a/x/ibc/core/02-client/keeper/client.go b/x/ibc/core/02-client/keeper/client.go index 49e9c62c8..83ecedc53 100644 --- a/x/ibc/core/02-client/keeper/client.go +++ b/x/ibc/core/02-client/keeper/client.go @@ -17,6 +17,14 @@ import ( func (k Keeper) CreateClient( ctx sdk.Context, clientID string, clientState exported.ClientState, consensusState exported.ConsensusState, ) error { + params := k.GetParams(ctx) + if !params.IsAllowedClient(clientState.ClientType()) { + return sdkerrors.Wrapf( + types.ErrInvalidClientType, + "client state type %s is not registered in the allowlist", clientState.ClientType(), + ) + } + _, found := k.GetClientState(ctx, clientID) if found { return sdkerrors.Wrapf(types.ErrClientExists, "cannot create client with ID %s", clientID) diff --git a/x/ibc/core/02-client/keeper/client_test.go b/x/ibc/core/02-client/keeper/client_test.go index 30528b88c..0c700f907 100644 --- a/x/ibc/core/02-client/keeper/client_test.go +++ b/x/ibc/core/02-client/keeper/client_test.go @@ -261,7 +261,7 @@ func (suite *KeeperTestSuite) TestUpgradeClient() { // commit upgrade store changes and update clients suite.coordinator.CommitBlock(suite.chainB) - err := suite.coordinator.UpdateClient(suite.chainA, suite.chainB, clientA, ibctesting.Tendermint) + err := suite.coordinator.UpdateClient(suite.chainA, suite.chainB, clientA, exported.Tendermint) suite.Require().NoError(err) cs, found := suite.chainA.App.IBCKeeper.ClientKeeper.GetClientState(suite.chainA.GetContext(), clientA) @@ -286,7 +286,7 @@ func (suite *KeeperTestSuite) TestUpgradeClient() { // commit upgrade store changes and update clients suite.coordinator.CommitBlock(suite.chainB) - err := suite.coordinator.UpdateClient(suite.chainA, suite.chainB, clientA, ibctesting.Tendermint) + err := suite.coordinator.UpdateClient(suite.chainA, suite.chainB, clientA, exported.Tendermint) suite.Require().NoError(err) cs, found := suite.chainA.App.IBCKeeper.ClientKeeper.GetClientState(suite.chainA.GetContext(), clientA) @@ -313,7 +313,7 @@ func (suite *KeeperTestSuite) TestUpgradeClient() { // commit upgrade store changes and update clients suite.coordinator.CommitBlock(suite.chainB) - err := suite.coordinator.UpdateClient(suite.chainA, suite.chainB, clientA, ibctesting.Tendermint) + err := suite.coordinator.UpdateClient(suite.chainA, suite.chainB, clientA, exported.Tendermint) suite.Require().NoError(err) cs, found := suite.chainA.App.IBCKeeper.ClientKeeper.GetClientState(suite.chainA.GetContext(), clientA) @@ -345,7 +345,7 @@ func (suite *KeeperTestSuite) TestUpgradeClient() { upgradedClient = ibctmtypes.NewClientState("wrongchainID", ibctmtypes.DefaultTrustLevel, trustingPeriod, ubdPeriod, maxClockDrift, newClientHeight, ibctesting.DefaultConsensusParams, commitmenttypes.GetSDKSpecs(), ibctesting.UpgradePath, true, true) suite.coordinator.CommitBlock(suite.chainB) - err := suite.coordinator.UpdateClient(suite.chainA, suite.chainB, clientA, ibctesting.Tendermint) + err := suite.coordinator.UpdateClient(suite.chainA, suite.chainB, clientA, exported.Tendermint) suite.Require().NoError(err) cs, found := suite.chainA.App.IBCKeeper.ClientKeeper.GetClientState(suite.chainA.GetContext(), clientA) @@ -359,7 +359,7 @@ func (suite *KeeperTestSuite) TestUpgradeClient() { for _, tc := range testCases { tc := tc - clientA, _ = suite.coordinator.SetupClients(suite.chainA, suite.chainB, ibctesting.Tendermint) + clientA, _ = suite.coordinator.SetupClients(suite.chainA, suite.chainB, exported.Tendermint) tc.setup() diff --git a/x/ibc/core/02-client/keeper/grpc_query.go b/x/ibc/core/02-client/keeper/grpc_query.go index 8bb530689..9f4bb6c80 100644 --- a/x/ibc/core/02-client/keeper/grpc_query.go +++ b/x/ibc/core/02-client/keeper/grpc_query.go @@ -3,6 +3,7 @@ package keeper import ( "context" "fmt" + "sort" "strings" "google.golang.org/grpc/codes" @@ -58,7 +59,7 @@ func (q Keeper) ClientStates(c context.Context, req *types.QueryClientStatesRequ ctx := sdk.UnwrapSDKContext(c) - clientStates := []*types.IdentifiedClientState{} + clientStates := types.IdentifiedClientStates{} store := prefix.NewStore(ctx.KVStore(q.storeKey), host.KeyClientStorePrefix) pageRes, err := query.Paginate(store, req.Pagination, func(key, value []byte) error { @@ -78,7 +79,7 @@ func (q Keeper) ClientStates(c context.Context, req *types.QueryClientStatesRequ } identifiedClient := types.NewIdentifiedClientState(clientID, clientState) - clientStates = append(clientStates, &identifiedClient) + clientStates = append(clientStates, identifiedClient) return nil }) @@ -86,6 +87,8 @@ func (q Keeper) ClientStates(c context.Context, req *types.QueryClientStatesRequ return nil, err } + sort.Sort(clientStates) + return &types.QueryClientStatesResponse{ ClientStates: clientStates, Pagination: pageRes, @@ -178,3 +181,13 @@ func (q Keeper) ConsensusStates(c context.Context, req *types.QueryConsensusStat Pagination: pageRes, }, nil } + +// ClientParams implements the Query/ClientParams gRPC method +func (q Keeper) ClientParams(c context.Context, _ *types.QueryClientParamsRequest) (*types.QueryClientParamsResponse, error) { + ctx := sdk.UnwrapSDKContext(c) + params := q.GetParams(ctx) + + return &types.QueryClientParamsResponse{ + Params: ¶ms, + }, nil +} diff --git a/x/ibc/core/02-client/keeper/grpc_query_test.go b/x/ibc/core/02-client/keeper/grpc_query_test.go index b99d290f8..d111f540a 100644 --- a/x/ibc/core/02-client/keeper/grpc_query_test.go +++ b/x/ibc/core/02-client/keeper/grpc_query_test.go @@ -82,7 +82,7 @@ func (suite *KeeperTestSuite) TestQueryClientState() { func (suite *KeeperTestSuite) TestQueryClientStates() { var ( req *types.QueryClientStatesRequest - expClientStates = []*types.IdentifiedClientState(nil) + expClientStates = types.IdentifiedClientStates{} ) testCases := []struct { @@ -112,8 +112,8 @@ func (suite *KeeperTestSuite) TestQueryClientStates() { { "success", func() { - clientA1, _ := suite.coordinator.SetupClients(suite.chainA, suite.chainB, ibctesting.Tendermint) - clientA2, _ := suite.coordinator.CreateClient(suite.chainA, suite.chainB, ibctesting.Tendermint) + clientA1, _ := suite.coordinator.SetupClients(suite.chainA, suite.chainB, exported.Tendermint) + clientA2, _ := suite.coordinator.CreateClient(suite.chainA, suite.chainB, exported.Tendermint) clientStateA1 := suite.chainA.GetClientState(clientA1) clientStateA2 := suite.chainA.GetClientState(clientA2) @@ -122,7 +122,7 @@ func (suite *KeeperTestSuite) TestQueryClientStates() { idcs2 := types.NewIdentifiedClientState(clientA2, clientStateA2) // order is sorted by client id, localhost is last - expClientStates = []*types.IdentifiedClientState{&idcs, &idcs2} + expClientStates = types.IdentifiedClientStates{idcs, idcs2}.Sort() req = &types.QueryClientStatesRequest{ Pagination: &query.PageRequest{ Limit: 7, @@ -144,7 +144,7 @@ func (suite *KeeperTestSuite) TestQueryClientStates() { // always add localhost which is created by default in init genesis localhostClientState := suite.chainA.GetClientState(exported.Localhost) identifiedLocalhost := types.NewIdentifiedClientState(exported.Localhost, localhostClientState) - expClientStates = append(expClientStates, &identifiedLocalhost) + expClientStates = append(expClientStates, identifiedLocalhost) ctx := sdk.WrapSDKContext(suite.chainA.GetContext()) @@ -153,12 +153,7 @@ func (suite *KeeperTestSuite) TestQueryClientStates() { if tc.expPass { suite.Require().NoError(err) suite.Require().NotNil(res) - suite.Require().Equal(len(expClientStates), len(res.ClientStates)) - for i := range expClientStates { - suite.Require().Equal(expClientStates[i].ClientId, res.ClientStates[i].ClientId) - suite.Require().NotNil(res.ClientStates[i].ClientState) - suite.Require().Equal(expClientStates[i].ClientState, res.ClientStates[i].ClientState) - } + suite.Require().Equal(expClientStates.Sort(), res.ClientStates) } else { suite.Require().Error(err) } @@ -364,3 +359,10 @@ func (suite *KeeperTestSuite) TestQueryConsensusStates() { }) } } + +func (suite *KeeperTestSuite) TestQueryParams() { + ctx := sdk.WrapSDKContext(suite.chainA.GetContext()) + expParams := types.DefaultParams() + res, _ := suite.queryClient.ClientParams(ctx, &types.QueryClientParamsRequest{}) + suite.Require().Equal(&expParams, res.Params) +} diff --git a/x/ibc/core/02-client/keeper/keeper.go b/x/ibc/core/02-client/keeper/keeper.go index 7c68499f8..96632fc17 100644 --- a/x/ibc/core/02-client/keeper/keeper.go +++ b/x/ibc/core/02-client/keeper/keeper.go @@ -18,6 +18,7 @@ import ( host "github.com/cosmos/cosmos-sdk/x/ibc/core/24-host" "github.com/cosmos/cosmos-sdk/x/ibc/core/exported" ibctmtypes "github.com/cosmos/cosmos-sdk/x/ibc/light-clients/07-tendermint/types" + paramtypes "github.com/cosmos/cosmos-sdk/x/params/types" upgradetypes "github.com/cosmos/cosmos-sdk/x/upgrade/types" ) @@ -26,14 +27,21 @@ import ( type Keeper struct { storeKey sdk.StoreKey cdc codec.BinaryMarshaler + paramSpace paramtypes.Subspace stakingKeeper types.StakingKeeper } // NewKeeper creates a new NewKeeper instance -func NewKeeper(cdc codec.BinaryMarshaler, key sdk.StoreKey, sk types.StakingKeeper) Keeper { +func NewKeeper(cdc codec.BinaryMarshaler, key sdk.StoreKey, paramSpace paramtypes.Subspace, sk types.StakingKeeper) Keeper { + // set KeyTable if it has not already been set + if !paramSpace.HasKeyTable() { + paramSpace = paramSpace.WithKeyTable(types.ParamKeyTable()) + } + return Keeper{ storeKey: key, cdc: cdc, + paramSpace: paramSpace, stakingKeeper: sk, } } @@ -107,12 +115,14 @@ func (k Keeper) IterateConsensusStates(ctx sdk.Context, cb func(clientID string, } // GetAllGenesisClients returns all the clients in state with their client ids returned as IdentifiedClientState -func (k Keeper) GetAllGenesisClients(ctx sdk.Context) (genClients []types.IdentifiedClientState) { +func (k Keeper) GetAllGenesisClients(ctx sdk.Context) types.IdentifiedClientStates { + var genClients types.IdentifiedClientStates k.IterateClients(ctx, func(clientID string, cs exported.ClientState) bool { genClients = append(genClients, types.NewIdentifiedClientState(clientID, cs)) return false }) - return + + return genClients.Sort() } // GetAllConsensusStates returns all stored client consensus states. diff --git a/x/ibc/core/02-client/keeper/keeper_test.go b/x/ibc/core/02-client/keeper/keeper_test.go index d5e162b09..1f2c09ac5 100644 --- a/x/ibc/core/02-client/keeper/keeper_test.go +++ b/x/ibc/core/02-client/keeper/keeper_test.go @@ -243,30 +243,6 @@ func (suite *KeeperTestSuite) TestValidateSelfClient() { } } -func (suite KeeperTestSuite) TestGetAllClients() { - clientIDs := []string{ - testClientID2, testClientID3, testClientID, - } - expClients := []exported.ClientState{ - ibctmtypes.NewClientState(testChainID, ibctmtypes.DefaultTrustLevel, trustingPeriod, ubdPeriod, maxClockDrift, types.ZeroHeight(), ibctesting.DefaultConsensusParams, commitmenttypes.GetSDKSpecs(), ibctesting.UpgradePath, false, false), - ibctmtypes.NewClientState(testChainID, ibctmtypes.DefaultTrustLevel, trustingPeriod, ubdPeriod, maxClockDrift, types.ZeroHeight(), ibctesting.DefaultConsensusParams, commitmenttypes.GetSDKSpecs(), ibctesting.UpgradePath, false, false), - ibctmtypes.NewClientState(testChainID, ibctmtypes.DefaultTrustLevel, trustingPeriod, ubdPeriod, maxClockDrift, types.ZeroHeight(), ibctesting.DefaultConsensusParams, commitmenttypes.GetSDKSpecs(), ibctesting.UpgradePath, false, false), - } - - for i := range expClients { - suite.chainA.App.IBCKeeper.ClientKeeper.SetClientState(suite.chainA.GetContext(), clientIDs[i], expClients[i]) - } - - // add localhost client - localHostClient, found := suite.chainA.App.IBCKeeper.ClientKeeper.GetClientState(suite.chainA.GetContext(), exported.Localhost) - suite.Require().True(found) - expClients = append(expClients, localHostClient) - - clients := suite.chainA.App.IBCKeeper.ClientKeeper.GetAllClients(suite.chainA.GetContext()) - suite.Require().Len(clients, len(expClients)) - suite.Require().Equal(expClients, clients) -} - func (suite KeeperTestSuite) TestGetAllGenesisClients() { clientIDs := []string{ testClientID2, testClientID3, testClientID, @@ -277,7 +253,7 @@ func (suite KeeperTestSuite) TestGetAllGenesisClients() { ibctmtypes.NewClientState(testChainID, ibctmtypes.DefaultTrustLevel, trustingPeriod, ubdPeriod, maxClockDrift, types.ZeroHeight(), ibctesting.DefaultConsensusParams, commitmenttypes.GetSDKSpecs(), ibctesting.UpgradePath, false, false), } - expGenClients := make([]types.IdentifiedClientState, len(expClients)) + expGenClients := make(types.IdentifiedClientStates, len(expClients)) for i := range expClients { suite.chainA.App.IBCKeeper.ClientKeeper.SetClientState(suite.chainA.GetContext(), clientIDs[i], expClients[i]) @@ -291,7 +267,7 @@ func (suite KeeperTestSuite) TestGetAllGenesisClients() { genClients := suite.chainA.App.IBCKeeper.ClientKeeper.GetAllGenesisClients(suite.chainA.GetContext()) - suite.Require().Equal(expGenClients, genClients) + suite.Require().Equal(expGenClients.Sort(), genClients) } func (suite KeeperTestSuite) TestGetConsensusState() { @@ -347,7 +323,7 @@ func (suite KeeperTestSuite) TestConsensusStateHelpers() { // 2 clients in total are created on chainA. The first client is updated so it contains an initial consensus state // and a consensus state at the update height. func (suite KeeperTestSuite) TestGetAllConsensusStates() { - clientA, _ := suite.coordinator.SetupClients(suite.chainA, suite.chainB, ibctesting.Tendermint) + clientA, _ := suite.coordinator.SetupClients(suite.chainA, suite.chainB, exported.Tendermint) clientState := suite.chainA.GetClientState(clientA) expConsensusHeight0 := clientState.GetLatestHeight() @@ -355,7 +331,7 @@ func (suite KeeperTestSuite) TestGetAllConsensusStates() { suite.Require().True(ok) // update client to create a second consensus state - err := suite.coordinator.UpdateClient(suite.chainA, suite.chainB, clientA, ibctesting.Tendermint) + err := suite.coordinator.UpdateClient(suite.chainA, suite.chainB, clientA, exported.Tendermint) suite.Require().NoError(err) clientState = suite.chainA.GetClientState(clientA) @@ -370,7 +346,7 @@ func (suite KeeperTestSuite) TestGetAllConsensusStates() { } // create second client on chainA - clientA2, _ := suite.coordinator.SetupClients(suite.chainA, suite.chainB, ibctesting.Tendermint) + clientA2, _ := suite.coordinator.SetupClients(suite.chainA, suite.chainB, exported.Tendermint) clientState = suite.chainA.GetClientState(clientA2) expConsensusHeight2 := clientState.GetLatestHeight() diff --git a/x/ibc/core/02-client/keeper/params.go b/x/ibc/core/02-client/keeper/params.go new file mode 100644 index 000000000..04f4a2563 --- /dev/null +++ b/x/ibc/core/02-client/keeper/params.go @@ -0,0 +1,23 @@ +package keeper + +import ( + sdk "github.com/cosmos/cosmos-sdk/types" + "github.com/cosmos/cosmos-sdk/x/ibc/core/02-client/types" +) + +// GetAllowedClients retrieves the receive enabled boolean from the paramstore +func (k Keeper) GetAllowedClients(ctx sdk.Context) []string { + var res []string + k.paramSpace.Get(ctx, types.KeyAllowedClients, &res) + return res +} + +// GetParams returns the total set of ibc-transfer parameters. +func (k Keeper) GetParams(ctx sdk.Context) types.Params { + return types.NewParams(k.GetAllowedClients(ctx)...) +} + +// SetParams sets the total set of ibc-transfer parameters. +func (k Keeper) SetParams(ctx sdk.Context, params types.Params) { + k.paramSpace.SetParamSet(ctx, ¶ms) +} diff --git a/x/ibc/core/02-client/keeper/params_test.go b/x/ibc/core/02-client/keeper/params_test.go new file mode 100644 index 000000000..9df085971 --- /dev/null +++ b/x/ibc/core/02-client/keeper/params_test.go @@ -0,0 +1,17 @@ +package keeper_test + +import ( + "github.com/cosmos/cosmos-sdk/x/ibc/core/02-client/types" +) + +func (suite *KeeperTestSuite) TestParams() { + expParams := types.DefaultParams() + + params := suite.chainA.App.IBCKeeper.ClientKeeper.GetParams(suite.chainA.GetContext()) + suite.Require().Equal(expParams, params) + + expParams.AllowedClients = []string{} + suite.chainA.App.IBCKeeper.ClientKeeper.SetParams(suite.chainA.GetContext(), expParams) + params = suite.chainA.App.IBCKeeper.ClientKeeper.GetParams(suite.chainA.GetContext()) + suite.Require().Empty(expParams.AllowedClients) +} diff --git a/x/ibc/core/02-client/keeper/proposal_test.go b/x/ibc/core/02-client/keeper/proposal_test.go index ea5cd372f..ada205402 100644 --- a/x/ibc/core/02-client/keeper/proposal_test.go +++ b/x/ibc/core/02-client/keeper/proposal_test.go @@ -21,7 +21,7 @@ func (suite *KeeperTestSuite) TestClientUpdateProposal() { }{ { "valid update client proposal", func() { - clientA, _ := suite.coordinator.SetupClients(suite.chainA, suite.chainB, ibctesting.Tendermint) + clientA, _ := suite.coordinator.SetupClients(suite.chainA, suite.chainB, exported.Tendermint) clientState := suite.chainA.GetClientState(clientA) tmClientState, ok := clientState.(*ibctmtypes.ClientState) @@ -58,14 +58,14 @@ func (suite *KeeperTestSuite) TestClientUpdateProposal() { }, { "cannot unpack header, header is nil", func() { - clientA, _ := suite.coordinator.SetupClients(suite.chainA, suite.chainB, ibctesting.Tendermint) + clientA, _ := suite.coordinator.SetupClients(suite.chainA, suite.chainB, exported.Tendermint) content = &clienttypes.ClientUpdateProposal{ibctesting.Title, ibctesting.Description, clientA, nil} }, false, }, { "update fails", func() { header := &ibctmtypes.Header{} - clientA, _ := suite.coordinator.SetupClients(suite.chainA, suite.chainB, ibctesting.Tendermint) + clientA, _ := suite.coordinator.SetupClients(suite.chainA, suite.chainB, exported.Tendermint) content, err = clienttypes.NewClientUpdateProposal(ibctesting.Title, ibctesting.Description, clientA, header) suite.Require().NoError(err) }, false, diff --git a/x/ibc/core/02-client/proposal_handler_test.go b/x/ibc/core/02-client/proposal_handler_test.go index 839dd2e53..91c1451b7 100644 --- a/x/ibc/core/02-client/proposal_handler_test.go +++ b/x/ibc/core/02-client/proposal_handler_test.go @@ -6,6 +6,7 @@ import ( govtypes "github.com/cosmos/cosmos-sdk/x/gov/types" client "github.com/cosmos/cosmos-sdk/x/ibc/core/02-client" clienttypes "github.com/cosmos/cosmos-sdk/x/ibc/core/02-client/types" + "github.com/cosmos/cosmos-sdk/x/ibc/core/exported" ibctmtypes "github.com/cosmos/cosmos-sdk/x/ibc/light-clients/07-tendermint/types" ibctesting "github.com/cosmos/cosmos-sdk/x/ibc/testing" ) @@ -23,7 +24,7 @@ func (suite *ClientTestSuite) TestNewClientUpdateProposalHandler() { }{ { "valid update client proposal", func() { - clientA, _ := suite.coordinator.SetupClients(suite.chainA, suite.chainB, ibctesting.Tendermint) + clientA, _ := suite.coordinator.SetupClients(suite.chainA, suite.chainB, exported.Tendermint) clientState := suite.chainA.GetClientState(clientA) tmClientState, ok := clientState.(*ibctmtypes.ClientState) diff --git a/x/ibc/core/02-client/types/client.go b/x/ibc/core/02-client/types/client.go index 99fe98e19..305b07cec 100644 --- a/x/ibc/core/02-client/types/client.go +++ b/x/ibc/core/02-client/types/client.go @@ -2,6 +2,7 @@ package types import ( "fmt" + "sort" proto "github.com/gogo/protobuf/proto" @@ -37,6 +38,26 @@ func (ics IdentifiedClientState) UnpackInterfaces(unpacker codectypes.AnyUnpacke return unpacker.UnpackAny(ics.ClientState, new(exported.ClientState)) } +var _ sort.Interface = IdentifiedClientStates{} + +// IdentifiedClientStates defines a slice of ClientConsensusStates that supports the sort interface +type IdentifiedClientStates []IdentifiedClientState + +// Len implements sort.Interface +func (ics IdentifiedClientStates) Len() int { return len(ics) } + +// Less implements sort.Interface +func (ics IdentifiedClientStates) Less(i, j int) bool { return ics[i].ClientId < ics[j].ClientId } + +// Swap implements sort.Interface +func (ics IdentifiedClientStates) Swap(i, j int) { ics[i], ics[j] = ics[j], ics[i] } + +// Sort is a helper function to sort the set of IdentifiedClientStates in place +func (ics IdentifiedClientStates) Sort() IdentifiedClientStates { + sort.Sort(ics) + return ics +} + // NewConsensusStateWithHeight creates a new ConsensusStateWithHeight instance func NewConsensusStateWithHeight(height Height, consensusState exported.ConsensusState) ConsensusStateWithHeight { msg, ok := consensusState.(proto.Message) diff --git a/x/ibc/core/02-client/types/client.pb.go b/x/ibc/core/02-client/types/client.pb.go index aa9bd5c3d..95fc58c33 100644 --- a/x/ibc/core/02-client/types/client.pb.go +++ b/x/ibc/core/02-client/types/client.pb.go @@ -4,15 +4,10 @@ package types import ( - context "context" fmt "fmt" types "github.com/cosmos/cosmos-sdk/codec/types" _ "github.com/gogo/protobuf/gogoproto" - grpc1 "github.com/gogo/protobuf/grpc" proto "github.com/gogo/protobuf/proto" - grpc "google.golang.org/grpc" - codes "google.golang.org/grpc/codes" - status "google.golang.org/grpc/status" io "io" math "math" math_bits "math/bits" @@ -29,370 +24,6 @@ var _ = math.Inf // proto package needs to be updated. const _ = proto.GoGoProtoPackageIsVersion3 // please upgrade the proto package -// MsgCreateClient defines a message to create an IBC client -type MsgCreateClient struct { - // client unique identifier - ClientId string `protobuf:"bytes,1,opt,name=client_id,json=clientId,proto3" json:"client_id,omitempty" yaml:"client_id"` - // light client state - ClientState *types.Any `protobuf:"bytes,2,opt,name=client_state,json=clientState,proto3" json:"client_state,omitempty" yaml:"client_state"` - // consensus state associated with the client that corresponds to a given - // height. - ConsensusState *types.Any `protobuf:"bytes,3,opt,name=consensus_state,json=consensusState,proto3" json:"consensus_state,omitempty" yaml:"consensus_state"` - // signer address - Signer string `protobuf:"bytes,4,opt,name=signer,proto3" json:"signer,omitempty"` -} - -func (m *MsgCreateClient) Reset() { *m = MsgCreateClient{} } -func (m *MsgCreateClient) String() string { return proto.CompactTextString(m) } -func (*MsgCreateClient) ProtoMessage() {} -func (*MsgCreateClient) Descriptor() ([]byte, []int) { - return fileDescriptor_b6bc4c8185546947, []int{0} -} -func (m *MsgCreateClient) XXX_Unmarshal(b []byte) error { - return m.Unmarshal(b) -} -func (m *MsgCreateClient) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - if deterministic { - return xxx_messageInfo_MsgCreateClient.Marshal(b, m, deterministic) - } else { - b = b[:cap(b)] - n, err := m.MarshalToSizedBuffer(b) - if err != nil { - return nil, err - } - return b[:n], nil - } -} -func (m *MsgCreateClient) XXX_Merge(src proto.Message) { - xxx_messageInfo_MsgCreateClient.Merge(m, src) -} -func (m *MsgCreateClient) XXX_Size() int { - return m.Size() -} -func (m *MsgCreateClient) XXX_DiscardUnknown() { - xxx_messageInfo_MsgCreateClient.DiscardUnknown(m) -} - -var xxx_messageInfo_MsgCreateClient proto.InternalMessageInfo - -// MsgCreateClientResponse defines the Msg/CreateClient response type. -type MsgCreateClientResponse struct { -} - -func (m *MsgCreateClientResponse) Reset() { *m = MsgCreateClientResponse{} } -func (m *MsgCreateClientResponse) String() string { return proto.CompactTextString(m) } -func (*MsgCreateClientResponse) ProtoMessage() {} -func (*MsgCreateClientResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_b6bc4c8185546947, []int{1} -} -func (m *MsgCreateClientResponse) XXX_Unmarshal(b []byte) error { - return m.Unmarshal(b) -} -func (m *MsgCreateClientResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - if deterministic { - return xxx_messageInfo_MsgCreateClientResponse.Marshal(b, m, deterministic) - } else { - b = b[:cap(b)] - n, err := m.MarshalToSizedBuffer(b) - if err != nil { - return nil, err - } - return b[:n], nil - } -} -func (m *MsgCreateClientResponse) XXX_Merge(src proto.Message) { - xxx_messageInfo_MsgCreateClientResponse.Merge(m, src) -} -func (m *MsgCreateClientResponse) XXX_Size() int { - return m.Size() -} -func (m *MsgCreateClientResponse) XXX_DiscardUnknown() { - xxx_messageInfo_MsgCreateClientResponse.DiscardUnknown(m) -} - -var xxx_messageInfo_MsgCreateClientResponse proto.InternalMessageInfo - -// MsgUpdateClient defines an sdk.Msg to update a IBC client state using -// the given header. -type MsgUpdateClient struct { - // client unique identifier - ClientId string `protobuf:"bytes,1,opt,name=client_id,json=clientId,proto3" json:"client_id,omitempty" yaml:"client_id"` - // header to update the light client - Header *types.Any `protobuf:"bytes,2,opt,name=header,proto3" json:"header,omitempty"` - // signer address - Signer string `protobuf:"bytes,3,opt,name=signer,proto3" json:"signer,omitempty"` -} - -func (m *MsgUpdateClient) Reset() { *m = MsgUpdateClient{} } -func (m *MsgUpdateClient) String() string { return proto.CompactTextString(m) } -func (*MsgUpdateClient) ProtoMessage() {} -func (*MsgUpdateClient) Descriptor() ([]byte, []int) { - return fileDescriptor_b6bc4c8185546947, []int{2} -} -func (m *MsgUpdateClient) XXX_Unmarshal(b []byte) error { - return m.Unmarshal(b) -} -func (m *MsgUpdateClient) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - if deterministic { - return xxx_messageInfo_MsgUpdateClient.Marshal(b, m, deterministic) - } else { - b = b[:cap(b)] - n, err := m.MarshalToSizedBuffer(b) - if err != nil { - return nil, err - } - return b[:n], nil - } -} -func (m *MsgUpdateClient) XXX_Merge(src proto.Message) { - xxx_messageInfo_MsgUpdateClient.Merge(m, src) -} -func (m *MsgUpdateClient) XXX_Size() int { - return m.Size() -} -func (m *MsgUpdateClient) XXX_DiscardUnknown() { - xxx_messageInfo_MsgUpdateClient.DiscardUnknown(m) -} - -var xxx_messageInfo_MsgUpdateClient proto.InternalMessageInfo - -// MsgUpdateClientResponse defines the Msg/UpdateClient response type. -type MsgUpdateClientResponse struct { -} - -func (m *MsgUpdateClientResponse) Reset() { *m = MsgUpdateClientResponse{} } -func (m *MsgUpdateClientResponse) String() string { return proto.CompactTextString(m) } -func (*MsgUpdateClientResponse) ProtoMessage() {} -func (*MsgUpdateClientResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_b6bc4c8185546947, []int{3} -} -func (m *MsgUpdateClientResponse) XXX_Unmarshal(b []byte) error { - return m.Unmarshal(b) -} -func (m *MsgUpdateClientResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - if deterministic { - return xxx_messageInfo_MsgUpdateClientResponse.Marshal(b, m, deterministic) - } else { - b = b[:cap(b)] - n, err := m.MarshalToSizedBuffer(b) - if err != nil { - return nil, err - } - return b[:n], nil - } -} -func (m *MsgUpdateClientResponse) XXX_Merge(src proto.Message) { - xxx_messageInfo_MsgUpdateClientResponse.Merge(m, src) -} -func (m *MsgUpdateClientResponse) XXX_Size() int { - return m.Size() -} -func (m *MsgUpdateClientResponse) XXX_DiscardUnknown() { - xxx_messageInfo_MsgUpdateClientResponse.DiscardUnknown(m) -} - -var xxx_messageInfo_MsgUpdateClientResponse proto.InternalMessageInfo - -// MsgUpgradeClient defines an sdk.Msg to upgrade an IBC client to a new client state -type MsgUpgradeClient struct { - // client unique identifier - ClientId string `protobuf:"bytes,1,opt,name=client_id,json=clientId,proto3" json:"client_id,omitempty" yaml:"client_id"` - // upgraded client state - ClientState *types.Any `protobuf:"bytes,2,opt,name=client_state,json=clientState,proto3" json:"client_state,omitempty" yaml:"client_state"` - // height at which old chain halts and upgrades (i.e last block executed) - UpgradeHeight *Height `protobuf:"bytes,3,opt,name=upgrade_height,json=upgradeHeight,proto3" json:"upgrade_height,omitempty" yaml:"upgrade_height"` - // proof that old chain committed to new client - ProofUpgrade []byte `protobuf:"bytes,4,opt,name=proof_upgrade,json=proofUpgrade,proto3" json:"proof_upgrade,omitempty" yaml:"proof_upgrade"` - // signer address - Signer string `protobuf:"bytes,5,opt,name=signer,proto3" json:"signer,omitempty"` -} - -func (m *MsgUpgradeClient) Reset() { *m = MsgUpgradeClient{} } -func (m *MsgUpgradeClient) String() string { return proto.CompactTextString(m) } -func (*MsgUpgradeClient) ProtoMessage() {} -func (*MsgUpgradeClient) Descriptor() ([]byte, []int) { - return fileDescriptor_b6bc4c8185546947, []int{4} -} -func (m *MsgUpgradeClient) XXX_Unmarshal(b []byte) error { - return m.Unmarshal(b) -} -func (m *MsgUpgradeClient) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - if deterministic { - return xxx_messageInfo_MsgUpgradeClient.Marshal(b, m, deterministic) - } else { - b = b[:cap(b)] - n, err := m.MarshalToSizedBuffer(b) - if err != nil { - return nil, err - } - return b[:n], nil - } -} -func (m *MsgUpgradeClient) XXX_Merge(src proto.Message) { - xxx_messageInfo_MsgUpgradeClient.Merge(m, src) -} -func (m *MsgUpgradeClient) XXX_Size() int { - return m.Size() -} -func (m *MsgUpgradeClient) XXX_DiscardUnknown() { - xxx_messageInfo_MsgUpgradeClient.DiscardUnknown(m) -} - -var xxx_messageInfo_MsgUpgradeClient proto.InternalMessageInfo - -func (m *MsgUpgradeClient) GetClientId() string { - if m != nil { - return m.ClientId - } - return "" -} - -func (m *MsgUpgradeClient) GetClientState() *types.Any { - if m != nil { - return m.ClientState - } - return nil -} - -func (m *MsgUpgradeClient) GetUpgradeHeight() *Height { - if m != nil { - return m.UpgradeHeight - } - return nil -} - -func (m *MsgUpgradeClient) GetProofUpgrade() []byte { - if m != nil { - return m.ProofUpgrade - } - return nil -} - -func (m *MsgUpgradeClient) GetSigner() string { - if m != nil { - return m.Signer - } - return "" -} - -// MsgUpgradeClientResponse defines the Msg/UpgradeClient response type. -type MsgUpgradeClientResponse struct { -} - -func (m *MsgUpgradeClientResponse) Reset() { *m = MsgUpgradeClientResponse{} } -func (m *MsgUpgradeClientResponse) String() string { return proto.CompactTextString(m) } -func (*MsgUpgradeClientResponse) ProtoMessage() {} -func (*MsgUpgradeClientResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_b6bc4c8185546947, []int{5} -} -func (m *MsgUpgradeClientResponse) XXX_Unmarshal(b []byte) error { - return m.Unmarshal(b) -} -func (m *MsgUpgradeClientResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - if deterministic { - return xxx_messageInfo_MsgUpgradeClientResponse.Marshal(b, m, deterministic) - } else { - b = b[:cap(b)] - n, err := m.MarshalToSizedBuffer(b) - if err != nil { - return nil, err - } - return b[:n], nil - } -} -func (m *MsgUpgradeClientResponse) XXX_Merge(src proto.Message) { - xxx_messageInfo_MsgUpgradeClientResponse.Merge(m, src) -} -func (m *MsgUpgradeClientResponse) XXX_Size() int { - return m.Size() -} -func (m *MsgUpgradeClientResponse) XXX_DiscardUnknown() { - xxx_messageInfo_MsgUpgradeClientResponse.DiscardUnknown(m) -} - -var xxx_messageInfo_MsgUpgradeClientResponse proto.InternalMessageInfo - -// MsgSubmitMisbehaviour defines an sdk.Msg type that submits Evidence for -// light client misbehaviour. -type MsgSubmitMisbehaviour struct { - // client unique identifier - ClientId string `protobuf:"bytes,1,opt,name=client_id,json=clientId,proto3" json:"client_id,omitempty" yaml:"client_id"` - // misbehaviour used for freezing the light client - Misbehaviour *types.Any `protobuf:"bytes,2,opt,name=misbehaviour,proto3" json:"misbehaviour,omitempty"` - // signer address - Signer string `protobuf:"bytes,3,opt,name=signer,proto3" json:"signer,omitempty"` -} - -func (m *MsgSubmitMisbehaviour) Reset() { *m = MsgSubmitMisbehaviour{} } -func (m *MsgSubmitMisbehaviour) String() string { return proto.CompactTextString(m) } -func (*MsgSubmitMisbehaviour) ProtoMessage() {} -func (*MsgSubmitMisbehaviour) Descriptor() ([]byte, []int) { - return fileDescriptor_b6bc4c8185546947, []int{6} -} -func (m *MsgSubmitMisbehaviour) XXX_Unmarshal(b []byte) error { - return m.Unmarshal(b) -} -func (m *MsgSubmitMisbehaviour) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - if deterministic { - return xxx_messageInfo_MsgSubmitMisbehaviour.Marshal(b, m, deterministic) - } else { - b = b[:cap(b)] - n, err := m.MarshalToSizedBuffer(b) - if err != nil { - return nil, err - } - return b[:n], nil - } -} -func (m *MsgSubmitMisbehaviour) XXX_Merge(src proto.Message) { - xxx_messageInfo_MsgSubmitMisbehaviour.Merge(m, src) -} -func (m *MsgSubmitMisbehaviour) XXX_Size() int { - return m.Size() -} -func (m *MsgSubmitMisbehaviour) XXX_DiscardUnknown() { - xxx_messageInfo_MsgSubmitMisbehaviour.DiscardUnknown(m) -} - -var xxx_messageInfo_MsgSubmitMisbehaviour proto.InternalMessageInfo - -// MsgSubmitMisbehaviourResponse defines the Msg/SubmitMisbehaviour response type. -type MsgSubmitMisbehaviourResponse struct { -} - -func (m *MsgSubmitMisbehaviourResponse) Reset() { *m = MsgSubmitMisbehaviourResponse{} } -func (m *MsgSubmitMisbehaviourResponse) String() string { return proto.CompactTextString(m) } -func (*MsgSubmitMisbehaviourResponse) ProtoMessage() {} -func (*MsgSubmitMisbehaviourResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_b6bc4c8185546947, []int{7} -} -func (m *MsgSubmitMisbehaviourResponse) XXX_Unmarshal(b []byte) error { - return m.Unmarshal(b) -} -func (m *MsgSubmitMisbehaviourResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - if deterministic { - return xxx_messageInfo_MsgSubmitMisbehaviourResponse.Marshal(b, m, deterministic) - } else { - b = b[:cap(b)] - n, err := m.MarshalToSizedBuffer(b) - if err != nil { - return nil, err - } - return b[:n], nil - } -} -func (m *MsgSubmitMisbehaviourResponse) XXX_Merge(src proto.Message) { - xxx_messageInfo_MsgSubmitMisbehaviourResponse.Merge(m, src) -} -func (m *MsgSubmitMisbehaviourResponse) XXX_Size() int { - return m.Size() -} -func (m *MsgSubmitMisbehaviourResponse) XXX_DiscardUnknown() { - xxx_messageInfo_MsgSubmitMisbehaviourResponse.DiscardUnknown(m) -} - -var xxx_messageInfo_MsgSubmitMisbehaviourResponse proto.InternalMessageInfo - // IdentifiedClientState defines a client state with an additional client // identifier field. type IdentifiedClientState struct { @@ -406,7 +37,7 @@ func (m *IdentifiedClientState) Reset() { *m = IdentifiedClientState{} } func (m *IdentifiedClientState) String() string { return proto.CompactTextString(m) } func (*IdentifiedClientState) ProtoMessage() {} func (*IdentifiedClientState) Descriptor() ([]byte, []int) { - return fileDescriptor_b6bc4c8185546947, []int{8} + return fileDescriptor_b6bc4c8185546947, []int{0} } func (m *IdentifiedClientState) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -461,7 +92,7 @@ func (m *ConsensusStateWithHeight) Reset() { *m = ConsensusStateWithHeig func (m *ConsensusStateWithHeight) String() string { return proto.CompactTextString(m) } func (*ConsensusStateWithHeight) ProtoMessage() {} func (*ConsensusStateWithHeight) Descriptor() ([]byte, []int) { - return fileDescriptor_b6bc4c8185546947, []int{9} + return fileDescriptor_b6bc4c8185546947, []int{1} } func (m *ConsensusStateWithHeight) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -517,7 +148,7 @@ func (m *ClientConsensusStates) Reset() { *m = ClientConsensusStates{} } func (m *ClientConsensusStates) String() string { return proto.CompactTextString(m) } func (*ClientConsensusStates) ProtoMessage() {} func (*ClientConsensusStates) Descriptor() ([]byte, []int) { - return fileDescriptor_b6bc4c8185546947, []int{10} + return fileDescriptor_b6bc4c8185546947, []int{2} } func (m *ClientConsensusStates) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -578,7 +209,7 @@ func (m *ClientUpdateProposal) Reset() { *m = ClientUpdateProposal{} } func (m *ClientUpdateProposal) String() string { return proto.CompactTextString(m) } func (*ClientUpdateProposal) ProtoMessage() {} func (*ClientUpdateProposal) Descriptor() ([]byte, []int) { - return fileDescriptor_b6bc4c8185546947, []int{11} + return fileDescriptor_b6bc4c8185546947, []int{3} } func (m *ClientUpdateProposal) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -626,7 +257,7 @@ type Height struct { func (m *Height) Reset() { *m = Height{} } func (*Height) ProtoMessage() {} func (*Height) Descriptor() ([]byte, []int) { - return fileDescriptor_b6bc4c8185546947, []int{12} + return fileDescriptor_b6bc4c8185546947, []int{4} } func (m *Height) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -655,593 +286,102 @@ func (m *Height) XXX_DiscardUnknown() { var xxx_messageInfo_Height proto.InternalMessageInfo +// Params defines the set of IBC light client parameters. +type Params struct { + // allowed_clients defines the list of allowed client state types. + AllowedClients []string `protobuf:"bytes,1,rep,name=allowed_clients,json=allowedClients,proto3" json:"allowed_clients,omitempty" yaml:"allowed_clients"` +} + +func (m *Params) Reset() { *m = Params{} } +func (m *Params) String() string { return proto.CompactTextString(m) } +func (*Params) ProtoMessage() {} +func (*Params) Descriptor() ([]byte, []int) { + return fileDescriptor_b6bc4c8185546947, []int{5} +} +func (m *Params) XXX_Unmarshal(b []byte) error { + return m.Unmarshal(b) +} +func (m *Params) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { + if deterministic { + return xxx_messageInfo_Params.Marshal(b, m, deterministic) + } else { + b = b[:cap(b)] + n, err := m.MarshalToSizedBuffer(b) + if err != nil { + return nil, err + } + return b[:n], nil + } +} +func (m *Params) XXX_Merge(src proto.Message) { + xxx_messageInfo_Params.Merge(m, src) +} +func (m *Params) XXX_Size() int { + return m.Size() +} +func (m *Params) XXX_DiscardUnknown() { + xxx_messageInfo_Params.DiscardUnknown(m) +} + +var xxx_messageInfo_Params proto.InternalMessageInfo + +func (m *Params) GetAllowedClients() []string { + if m != nil { + return m.AllowedClients + } + return nil +} + func init() { - proto.RegisterType((*MsgCreateClient)(nil), "ibc.core.client.v1.MsgCreateClient") - proto.RegisterType((*MsgCreateClientResponse)(nil), "ibc.core.client.v1.MsgCreateClientResponse") - proto.RegisterType((*MsgUpdateClient)(nil), "ibc.core.client.v1.MsgUpdateClient") - proto.RegisterType((*MsgUpdateClientResponse)(nil), "ibc.core.client.v1.MsgUpdateClientResponse") - proto.RegisterType((*MsgUpgradeClient)(nil), "ibc.core.client.v1.MsgUpgradeClient") - proto.RegisterType((*MsgUpgradeClientResponse)(nil), "ibc.core.client.v1.MsgUpgradeClientResponse") - proto.RegisterType((*MsgSubmitMisbehaviour)(nil), "ibc.core.client.v1.MsgSubmitMisbehaviour") - proto.RegisterType((*MsgSubmitMisbehaviourResponse)(nil), "ibc.core.client.v1.MsgSubmitMisbehaviourResponse") proto.RegisterType((*IdentifiedClientState)(nil), "ibc.core.client.v1.IdentifiedClientState") proto.RegisterType((*ConsensusStateWithHeight)(nil), "ibc.core.client.v1.ConsensusStateWithHeight") proto.RegisterType((*ClientConsensusStates)(nil), "ibc.core.client.v1.ClientConsensusStates") proto.RegisterType((*ClientUpdateProposal)(nil), "ibc.core.client.v1.ClientUpdateProposal") proto.RegisterType((*Height)(nil), "ibc.core.client.v1.Height") + proto.RegisterType((*Params)(nil), "ibc.core.client.v1.Params") } func init() { proto.RegisterFile("ibc/core/client/v1/client.proto", fileDescriptor_b6bc4c8185546947) } var fileDescriptor_b6bc4c8185546947 = []byte{ - // 827 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xcc, 0x56, 0x3f, 0x6f, 0x1a, 0x49, - 0x14, 0x67, 0x01, 0x23, 0x7b, 0x00, 0xdb, 0xda, 0x03, 0x1b, 0xaf, 0x74, 0x2c, 0x9a, 0xbb, 0xc2, - 0xa7, 0xb3, 0x77, 0x0f, 0xae, 0x38, 0xcb, 0xd2, 0x49, 0x77, 0xd0, 0x9c, 0x0b, 0x4e, 0xbe, 0xb5, - 0x4e, 0xf9, 0xa3, 0x48, 0x64, 0xff, 0x8c, 0x97, 0x51, 0x60, 0x07, 0xed, 0x2c, 0xc8, 0x7c, 0x83, - 0x94, 0x91, 0x12, 0x45, 0x29, 0x52, 0x58, 0x29, 0x52, 0xa6, 0xcb, 0x37, 0x48, 0xe1, 0x22, 0x85, - 0xcb, 0x54, 0x28, 0xb2, 0x9b, 0xd4, 0x7c, 0x82, 0x68, 0x77, 0xc6, 0xab, 0x5d, 0x0c, 0x98, 0x38, - 0x8d, 0x2b, 0xf6, 0xbd, 0xf9, 0xcd, 0xef, 0xbd, 0xf7, 0x9b, 0x37, 0x6f, 0x00, 0x32, 0x36, 0x4c, - 0xd5, 0x24, 0x2e, 0x52, 0xcd, 0x0e, 0x46, 0x8e, 0xa7, 0x0e, 0xaa, 0xfc, 0x4b, 0xe9, 0xb9, 0xc4, - 0x23, 0xa2, 0x88, 0x0d, 0x53, 0xf1, 0x01, 0x0a, 0x77, 0x0f, 0xaa, 0x52, 0xc1, 0x26, 0x36, 0x09, - 0x96, 0x55, 0xff, 0x8b, 0x21, 0xa5, 0x2d, 0x9b, 0x10, 0xbb, 0x83, 0xd4, 0xc0, 0x32, 0xfa, 0xc7, - 0xaa, 0xee, 0x0c, 0xd9, 0x12, 0x7c, 0x9e, 0x04, 0x6b, 0x4d, 0x6a, 0x37, 0x5c, 0xa4, 0x7b, 0xa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c, - 0x91, 0xf9, 0x79, 0xe6, 0xee, 0x08, 0x4a, 0xda, 0x59, 0x04, 0x15, 0x06, 0x71, 0x81, 0x38, 0x65, - 0xbc, 0xfe, 0x32, 0x83, 0xe3, 0x3a, 0x54, 0xaa, 0x2e, 0x0c, 0xbd, 0x8a, 0x59, 0xff, 0xef, 0xec, - 0xa2, 0x2c, 0x9c, 0x5f, 0x94, 0x85, 0xcf, 0x17, 0x65, 0xe1, 0xd9, 0x65, 0x39, 0x71, 0x7e, 0x59, - 0x4e, 0x7c, 0xba, 0x2c, 0x27, 0x1e, 0xfe, 0x61, 0x63, 0xaf, 0xdd, 0x37, 0x14, 0x93, 0x74, 0x55, - 0x93, 0xd0, 0x2e, 0xa1, 0xfc, 0x67, 0x97, 0x5a, 0x4f, 0xd4, 0x13, 0x35, 0xfc, 0x0f, 0xf7, 0x5b, - 0x6d, 0x97, 0xff, 0x8d, 0xf3, 0x86, 0x3d, 0x44, 0x8d, 0x4c, 0xd0, 0xac, 0xbf, 0x7f, 0x0d, 0x00, - 0x00, 0xff, 0xff, 0x06, 0xa7, 0xa2, 0x16, 0xe6, 0x09, 0x00, 0x00, -} - -// Reference imports to suppress errors if they are not otherwise used. -var _ context.Context -var _ grpc.ClientConn - -// This is a compile-time assertion to ensure that this generated file -// is compatible with the grpc package it is being compiled against. -const _ = grpc.SupportPackageIsVersion4 - -// MsgClient is the client API for Msg service. -// -// For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream. -type MsgClient interface { - // CreateClient defines a rpc handler method for MsgCreateClient. - CreateClient(ctx context.Context, in *MsgCreateClient, opts ...grpc.CallOption) (*MsgCreateClientResponse, error) - // UpdateClient defines a rpc handler method for MsgUpdateClient. - UpdateClient(ctx context.Context, in *MsgUpdateClient, opts ...grpc.CallOption) (*MsgUpdateClientResponse, error) - // UpgradeClient defines a rpc handler method for MsgUpgradeClient. - UpgradeClient(ctx context.Context, in *MsgUpgradeClient, opts ...grpc.CallOption) (*MsgUpgradeClientResponse, error) - // SubmitMisbehaviour defines a rpc handler method for MsgSubmitMisbehaviour. - SubmitMisbehaviour(ctx context.Context, in *MsgSubmitMisbehaviour, opts ...grpc.CallOption) (*MsgSubmitMisbehaviourResponse, error) -} - -type msgClient struct { - cc grpc1.ClientConn -} - -func NewMsgClient(cc grpc1.ClientConn) MsgClient { - return &msgClient{cc} -} - -func (c *msgClient) CreateClient(ctx context.Context, in *MsgCreateClient, opts ...grpc.CallOption) (*MsgCreateClientResponse, error) { - out := new(MsgCreateClientResponse) - err := c.cc.Invoke(ctx, "/ibc.core.client.v1.Msg/CreateClient", in, out, opts...) - if err != nil { - return nil, err - } - return out, nil -} - -func (c *msgClient) UpdateClient(ctx context.Context, in *MsgUpdateClient, opts ...grpc.CallOption) (*MsgUpdateClientResponse, error) { - out := new(MsgUpdateClientResponse) - err := c.cc.Invoke(ctx, "/ibc.core.client.v1.Msg/UpdateClient", in, out, opts...) - if err != nil { - return nil, err - } - return out, nil -} - -func (c *msgClient) UpgradeClient(ctx context.Context, in *MsgUpgradeClient, opts ...grpc.CallOption) (*MsgUpgradeClientResponse, error) { - out := new(MsgUpgradeClientResponse) - err := c.cc.Invoke(ctx, "/ibc.core.client.v1.Msg/UpgradeClient", in, out, opts...) - if err != nil { - return nil, err - } - return out, nil -} - -func (c *msgClient) SubmitMisbehaviour(ctx context.Context, in *MsgSubmitMisbehaviour, opts ...grpc.CallOption) (*MsgSubmitMisbehaviourResponse, error) { - out := new(MsgSubmitMisbehaviourResponse) - err := c.cc.Invoke(ctx, "/ibc.core.client.v1.Msg/SubmitMisbehaviour", in, out, opts...) - if err != nil { - return nil, err - } - return out, nil -} - -// MsgServer is the server API for Msg service. -type MsgServer interface { - // CreateClient defines a rpc handler method for MsgCreateClient. - CreateClient(context.Context, *MsgCreateClient) (*MsgCreateClientResponse, error) - // UpdateClient defines a rpc handler method for MsgUpdateClient. - UpdateClient(context.Context, *MsgUpdateClient) (*MsgUpdateClientResponse, error) - // UpgradeClient defines a rpc handler method for MsgUpgradeClient. - UpgradeClient(context.Context, *MsgUpgradeClient) (*MsgUpgradeClientResponse, error) - // SubmitMisbehaviour defines a rpc handler method for MsgSubmitMisbehaviour. - SubmitMisbehaviour(context.Context, *MsgSubmitMisbehaviour) (*MsgSubmitMisbehaviourResponse, error) -} - -// UnimplementedMsgServer can be embedded to have forward compatible implementations. -type UnimplementedMsgServer struct { -} - -func (*UnimplementedMsgServer) CreateClient(ctx context.Context, req *MsgCreateClient) (*MsgCreateClientResponse, error) { - return nil, status.Errorf(codes.Unimplemented, "method CreateClient not implemented") -} -func (*UnimplementedMsgServer) UpdateClient(ctx context.Context, req *MsgUpdateClient) (*MsgUpdateClientResponse, error) { - return nil, status.Errorf(codes.Unimplemented, "method UpdateClient not implemented") -} -func (*UnimplementedMsgServer) UpgradeClient(ctx context.Context, req *MsgUpgradeClient) (*MsgUpgradeClientResponse, error) { - return nil, status.Errorf(codes.Unimplemented, "method UpgradeClient not implemented") -} -func (*UnimplementedMsgServer) SubmitMisbehaviour(ctx context.Context, req *MsgSubmitMisbehaviour) (*MsgSubmitMisbehaviourResponse, error) { - return nil, status.Errorf(codes.Unimplemented, "method SubmitMisbehaviour not implemented") -} - -func RegisterMsgServer(s grpc1.Server, srv MsgServer) { - s.RegisterService(&_Msg_serviceDesc, srv) -} - -func _Msg_CreateClient_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { - in := new(MsgCreateClient) - if err := dec(in); err != nil { - return nil, err - } - if interceptor == nil { - return srv.(MsgServer).CreateClient(ctx, in) - } - info := &grpc.UnaryServerInfo{ - Server: srv, - FullMethod: "/ibc.core.client.v1.Msg/CreateClient", - } - handler := func(ctx context.Context, req interface{}) (interface{}, error) { - return srv.(MsgServer).CreateClient(ctx, req.(*MsgCreateClient)) - } - return interceptor(ctx, in, info, handler) -} - -func _Msg_UpdateClient_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { - in := new(MsgUpdateClient) - if err := dec(in); err != nil { - return nil, err - } - if interceptor == nil { - return srv.(MsgServer).UpdateClient(ctx, in) - } - info := &grpc.UnaryServerInfo{ - Server: srv, - FullMethod: "/ibc.core.client.v1.Msg/UpdateClient", - } - handler := func(ctx context.Context, req interface{}) (interface{}, error) { - return srv.(MsgServer).UpdateClient(ctx, req.(*MsgUpdateClient)) - } - return interceptor(ctx, in, info, handler) -} - -func _Msg_UpgradeClient_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { - in := new(MsgUpgradeClient) - if err := dec(in); err != nil { - return nil, err - } - if interceptor == nil { - return srv.(MsgServer).UpgradeClient(ctx, in) - } - info := &grpc.UnaryServerInfo{ - Server: srv, - FullMethod: "/ibc.core.client.v1.Msg/UpgradeClient", - } - handler := func(ctx context.Context, req interface{}) (interface{}, error) { - return srv.(MsgServer).UpgradeClient(ctx, req.(*MsgUpgradeClient)) - } - return interceptor(ctx, in, info, handler) -} - -func _Msg_SubmitMisbehaviour_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { - in := new(MsgSubmitMisbehaviour) - if err := dec(in); err != nil { - return nil, err - } - if interceptor == nil { - return srv.(MsgServer).SubmitMisbehaviour(ctx, in) - } - info := &grpc.UnaryServerInfo{ - Server: srv, - FullMethod: "/ibc.core.client.v1.Msg/SubmitMisbehaviour", - } - handler := func(ctx context.Context, req interface{}) (interface{}, error) { - return srv.(MsgServer).SubmitMisbehaviour(ctx, req.(*MsgSubmitMisbehaviour)) - } - return interceptor(ctx, in, info, handler) -} - -var _Msg_serviceDesc = grpc.ServiceDesc{ - ServiceName: "ibc.core.client.v1.Msg", - HandlerType: (*MsgServer)(nil), - Methods: []grpc.MethodDesc{ - { - MethodName: "CreateClient", - Handler: _Msg_CreateClient_Handler, - }, - { - MethodName: "UpdateClient", - Handler: _Msg_UpdateClient_Handler, - }, - { - MethodName: "UpgradeClient", - Handler: _Msg_UpgradeClient_Handler, - }, - { - MethodName: "SubmitMisbehaviour", - Handler: _Msg_SubmitMisbehaviour_Handler, - }, - }, - Streams: []grpc.StreamDesc{}, - Metadata: "ibc/core/client/v1/client.proto", -} - -func (m *MsgCreateClient) Marshal() (dAtA []byte, err error) { - size := m.Size() - dAtA = make([]byte, size) - n, err := m.MarshalToSizedBuffer(dAtA[:size]) - if err != nil { - return nil, err - } - return dAtA[:n], nil -} - -func (m *MsgCreateClient) MarshalTo(dAtA []byte) (int, error) { - size := m.Size() - return m.MarshalToSizedBuffer(dAtA[:size]) -} - -func (m *MsgCreateClient) MarshalToSizedBuffer(dAtA []byte) (int, error) { - i := len(dAtA) - _ = i - var l int - _ = l - if len(m.Signer) > 0 { - i -= len(m.Signer) - copy(dAtA[i:], m.Signer) - i = encodeVarintClient(dAtA, i, uint64(len(m.Signer))) - i-- - dAtA[i] = 0x22 - } - if m.ConsensusState != nil { - { - size, err := m.ConsensusState.MarshalToSizedBuffer(dAtA[:i]) - if err != nil { - return 0, err - } - i -= size - i = encodeVarintClient(dAtA, i, uint64(size)) - } - i-- - dAtA[i] = 0x1a - } - if m.ClientState != nil { - { - size, err := m.ClientState.MarshalToSizedBuffer(dAtA[:i]) - if err != nil { - return 0, err - } - i -= size - i = encodeVarintClient(dAtA, i, uint64(size)) - } - i-- - dAtA[i] = 0x12 - } - if len(m.ClientId) > 0 { - i -= len(m.ClientId) - copy(dAtA[i:], m.ClientId) - i = encodeVarintClient(dAtA, i, uint64(len(m.ClientId))) - i-- - dAtA[i] = 0xa - } - return len(dAtA) - i, nil -} - -func (m *MsgCreateClientResponse) Marshal() (dAtA []byte, err error) { - size := m.Size() - dAtA = make([]byte, size) - n, err := m.MarshalToSizedBuffer(dAtA[:size]) - if err != nil { - return nil, err - } - return dAtA[:n], nil -} - -func (m *MsgCreateClientResponse) MarshalTo(dAtA []byte) (int, error) { - size := m.Size() - return m.MarshalToSizedBuffer(dAtA[:size]) -} - -func (m *MsgCreateClientResponse) MarshalToSizedBuffer(dAtA []byte) (int, error) { - i := len(dAtA) - _ = i - var l int - _ = l - return len(dAtA) - i, nil -} - -func (m *MsgUpdateClient) Marshal() (dAtA []byte, err error) { - size := m.Size() - dAtA = make([]byte, size) - n, err := m.MarshalToSizedBuffer(dAtA[:size]) - if err != nil { - return nil, err - } - return dAtA[:n], nil -} - -func (m *MsgUpdateClient) MarshalTo(dAtA []byte) (int, error) { - size := m.Size() - return m.MarshalToSizedBuffer(dAtA[:size]) -} - -func (m *MsgUpdateClient) MarshalToSizedBuffer(dAtA []byte) (int, error) { - i := len(dAtA) - _ = i - var l int - _ = l - if len(m.Signer) > 0 { - i -= len(m.Signer) - copy(dAtA[i:], m.Signer) - i = encodeVarintClient(dAtA, i, uint64(len(m.Signer))) - i-- - dAtA[i] = 0x1a - } - if m.Header != nil { - { - size, err := m.Header.MarshalToSizedBuffer(dAtA[:i]) - if err != nil { - return 0, err - } - i -= size - i = encodeVarintClient(dAtA, i, uint64(size)) - } - i-- - dAtA[i] = 0x12 - } - if len(m.ClientId) > 0 { - i -= len(m.ClientId) - copy(dAtA[i:], m.ClientId) - i = encodeVarintClient(dAtA, i, uint64(len(m.ClientId))) - i-- - dAtA[i] = 0xa - } - return len(dAtA) - i, nil -} - -func (m *MsgUpdateClientResponse) Marshal() (dAtA []byte, err error) { - size := m.Size() - dAtA = make([]byte, size) - n, err := m.MarshalToSizedBuffer(dAtA[:size]) - if err != nil { - return nil, err - } - return dAtA[:n], nil -} - -func (m *MsgUpdateClientResponse) MarshalTo(dAtA []byte) (int, error) { - size := m.Size() - return m.MarshalToSizedBuffer(dAtA[:size]) -} - -func (m *MsgUpdateClientResponse) MarshalToSizedBuffer(dAtA []byte) (int, error) { - i := len(dAtA) - _ = i - var l int - _ = l - return len(dAtA) - i, nil -} - -func (m *MsgUpgradeClient) Marshal() (dAtA []byte, err error) { - size := m.Size() - dAtA = make([]byte, size) - n, err := m.MarshalToSizedBuffer(dAtA[:size]) - if err != nil { - return nil, err - } - return dAtA[:n], nil -} - -func (m *MsgUpgradeClient) MarshalTo(dAtA []byte) (int, error) { - size := m.Size() - return m.MarshalToSizedBuffer(dAtA[:size]) -} - -func (m *MsgUpgradeClient) MarshalToSizedBuffer(dAtA []byte) (int, error) { - i := len(dAtA) - _ = i - var l int - _ = l - if len(m.Signer) > 0 { - i -= len(m.Signer) - copy(dAtA[i:], m.Signer) - i = encodeVarintClient(dAtA, i, uint64(len(m.Signer))) - i-- - dAtA[i] = 0x2a - } - if len(m.ProofUpgrade) > 0 { - i -= len(m.ProofUpgrade) - copy(dAtA[i:], m.ProofUpgrade) - i = encodeVarintClient(dAtA, i, uint64(len(m.ProofUpgrade))) - i-- - dAtA[i] = 0x22 - } - if m.UpgradeHeight != nil { - { - size, err := m.UpgradeHeight.MarshalToSizedBuffer(dAtA[:i]) - if err != nil { - return 0, err - } - i -= size - i = encodeVarintClient(dAtA, i, uint64(size)) - } - i-- - dAtA[i] = 0x1a - } - if m.ClientState != nil { - { - size, err := m.ClientState.MarshalToSizedBuffer(dAtA[:i]) - if err != nil { - return 0, err - } - i -= size - i = encodeVarintClient(dAtA, i, uint64(size)) - } - i-- - dAtA[i] = 0x12 - } - if len(m.ClientId) > 0 { - i -= len(m.ClientId) - copy(dAtA[i:], m.ClientId) - i = encodeVarintClient(dAtA, i, uint64(len(m.ClientId))) - i-- - dAtA[i] = 0xa - } - return len(dAtA) - i, nil -} - -func (m *MsgUpgradeClientResponse) Marshal() (dAtA []byte, err error) { - size := m.Size() - dAtA = make([]byte, size) - n, err := m.MarshalToSizedBuffer(dAtA[:size]) - if err != nil { - return nil, err - } - return dAtA[:n], nil -} - -func (m *MsgUpgradeClientResponse) MarshalTo(dAtA []byte) (int, error) { - size := m.Size() - return m.MarshalToSizedBuffer(dAtA[:size]) -} - -func (m *MsgUpgradeClientResponse) MarshalToSizedBuffer(dAtA []byte) (int, error) { - i := len(dAtA) - _ = i - var l int - _ = l - return len(dAtA) - i, nil -} - -func (m *MsgSubmitMisbehaviour) Marshal() (dAtA []byte, err error) { - size := m.Size() - dAtA = make([]byte, size) - n, err := m.MarshalToSizedBuffer(dAtA[:size]) - if err != nil { - return nil, err - } - return dAtA[:n], nil -} - -func (m *MsgSubmitMisbehaviour) MarshalTo(dAtA []byte) (int, error) { - size := m.Size() - return m.MarshalToSizedBuffer(dAtA[:size]) -} - -func (m *MsgSubmitMisbehaviour) MarshalToSizedBuffer(dAtA []byte) (int, error) { - i := len(dAtA) - _ = i - var l int - _ = l - if len(m.Signer) > 0 { - i -= len(m.Signer) - copy(dAtA[i:], m.Signer) - i = encodeVarintClient(dAtA, i, uint64(len(m.Signer))) - i-- - dAtA[i] = 0x1a - } - if m.Misbehaviour != nil { - { - size, err := m.Misbehaviour.MarshalToSizedBuffer(dAtA[:i]) - if err != nil { - return 0, err - } - i -= size - i = encodeVarintClient(dAtA, i, uint64(size)) - } - i-- - dAtA[i] = 0x12 - } - if len(m.ClientId) > 0 { - i -= len(m.ClientId) - copy(dAtA[i:], m.ClientId) - i = encodeVarintClient(dAtA, i, uint64(len(m.ClientId))) - i-- - dAtA[i] = 0xa - } - return len(dAtA) - i, nil -} - -func (m *MsgSubmitMisbehaviourResponse) Marshal() (dAtA []byte, err error) { - size := m.Size() - dAtA = make([]byte, size) - n, err := m.MarshalToSizedBuffer(dAtA[:size]) - if err != nil { - return nil, err - } - return dAtA[:n], nil -} - -func (m *MsgSubmitMisbehaviourResponse) MarshalTo(dAtA []byte) (int, error) { - size := m.Size() - return m.MarshalToSizedBuffer(dAtA[:size]) -} - -func (m *MsgSubmitMisbehaviourResponse) MarshalToSizedBuffer(dAtA []byte) (int, error) { - i := len(dAtA) - _ = i - var l int - _ = l - return len(dAtA) - i, nil + // 579 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x9c, 0x54, 0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, 0x31, 0xc5, + 0xcc, 0x2d, 0x67, 0xb6, 0x3e, 0xf8, 0x1d, 0x00, 0x00, 0xff, 0xff, 0x91, 0xd2, 0x2f, 0x3f, 0x78, + 0x04, 0x00, 0x00, } func (m *IdentifiedClientState) Marshal() (dAtA []byte, err error) { @@ -1464,6 +604,38 @@ func (m *Height) MarshalToSizedBuffer(dAtA []byte) (int, error) { return len(dAtA) - i, nil } +func (m *Params) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalToSizedBuffer(dAtA[:size]) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *Params) MarshalTo(dAtA []byte) (int, error) { + size := m.Size() + return m.MarshalToSizedBuffer(dAtA[:size]) +} + +func (m *Params) MarshalToSizedBuffer(dAtA []byte) (int, error) { + i := len(dAtA) + _ = i + var l int + _ = l + if len(m.AllowedClients) > 0 { + for iNdEx := len(m.AllowedClients) - 1; iNdEx >= 0; iNdEx-- { + i -= len(m.AllowedClients[iNdEx]) + copy(dAtA[i:], m.AllowedClients[iNdEx]) + i = encodeVarintClient(dAtA, i, uint64(len(m.AllowedClients[iNdEx]))) + i-- + dAtA[i] = 0xa + } + } + return len(dAtA) - i, nil +} + func encodeVarintClient(dAtA []byte, offset int, v uint64) int { offset -= sovClient(v) base := offset @@ -1475,138 +647,6 @@ func encodeVarintClient(dAtA []byte, offset int, v uint64) int { dAtA[offset] = uint8(v) return base } -func (m *MsgCreateClient) Size() (n int) { - if m == nil { - return 0 - } - var l int - _ = l - l = len(m.ClientId) - if l > 0 { - n += 1 + l + sovClient(uint64(l)) - } - if m.ClientState != nil { - l = m.ClientState.Size() - n += 1 + l + sovClient(uint64(l)) - } - if m.ConsensusState != nil { - l = m.ConsensusState.Size() - n += 1 + l + sovClient(uint64(l)) - } - l = len(m.Signer) - if l > 0 { - n += 1 + l + sovClient(uint64(l)) - } - return n -} - -func (m *MsgCreateClientResponse) Size() (n int) { - if m == nil { - return 0 - } - var l int - _ = l - return n -} - -func (m *MsgUpdateClient) Size() (n int) { - if m == nil { - return 0 - } - var l int - _ = l - l = len(m.ClientId) - if l > 0 { - n += 1 + l + sovClient(uint64(l)) - } - if m.Header != nil { - l = m.Header.Size() - n += 1 + l + sovClient(uint64(l)) - } - l = len(m.Signer) - if l > 0 { - n += 1 + l + sovClient(uint64(l)) - } - return n -} - -func (m *MsgUpdateClientResponse) Size() (n int) { - if m == nil { - return 0 - } - var l int - _ = l - return n -} - -func (m *MsgUpgradeClient) Size() (n int) { - if m == nil { - return 0 - } - var l int - _ = l - l = len(m.ClientId) - if l > 0 { - n += 1 + l + sovClient(uint64(l)) - } - if m.ClientState != nil { - l = m.ClientState.Size() - n += 1 + l + sovClient(uint64(l)) - } - if m.UpgradeHeight != nil { - l = m.UpgradeHeight.Size() - n += 1 + l + sovClient(uint64(l)) - } - l = len(m.ProofUpgrade) - if l > 0 { - n += 1 + l + sovClient(uint64(l)) - } - l = len(m.Signer) - if l > 0 { - n += 1 + l + sovClient(uint64(l)) - } - return n -} - -func (m *MsgUpgradeClientResponse) Size() (n int) { - if m == nil { - return 0 - } - var l int - _ = l - return n -} - -func (m *MsgSubmitMisbehaviour) Size() (n int) { - if m == nil { - return 0 - } - var l int - _ = l - l = len(m.ClientId) - if l > 0 { - n += 1 + l + sovClient(uint64(l)) - } - if m.Misbehaviour != nil { - l = m.Misbehaviour.Size() - n += 1 + l + sovClient(uint64(l)) - } - l = len(m.Signer) - if l > 0 { - n += 1 + l + sovClient(uint64(l)) - } - return n -} - -func (m *MsgSubmitMisbehaviourResponse) Size() (n int) { - if m == nil { - return 0 - } - var l int - _ = l - return n -} - func (m *IdentifiedClientState) Size() (n int) { if m == nil { return 0 @@ -1698,942 +738,27 @@ func (m *Height) Size() (n int) { return n } +func (m *Params) Size() (n int) { + if m == nil { + return 0 + } + var l int + _ = l + if len(m.AllowedClients) > 0 { + for _, s := range m.AllowedClients { + l = len(s) + n += 1 + l + sovClient(uint64(l)) + } + } + return n +} + func sovClient(x uint64) (n int) { return (math_bits.Len64(x|1) + 6) / 7 } func sozClient(x uint64) (n int) { return sovClient(uint64((x << 1) ^ uint64((int64(x) >> 63)))) } -func (m *MsgCreateClient) Unmarshal(dAtA []byte) error { - l := len(dAtA) - iNdEx := 0 - for iNdEx < l { - preIndex := iNdEx - var wire uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowClient - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - wire |= uint64(b&0x7F) << shift - if b < 0x80 { - break - } - } - fieldNum := int32(wire >> 3) - wireType := int(wire & 0x7) - if wireType == 4 { - return fmt.Errorf("proto: MsgCreateClient: wiretype end group for non-group") - } - if fieldNum <= 0 { - return fmt.Errorf("proto: MsgCreateClient: illegal tag %d (wire type %d)", fieldNum, wire) - } - switch fieldNum { - case 1: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field ClientId", wireType) - } - var stringLen uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowClient - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - stringLen |= uint64(b&0x7F) << shift - if b < 0x80 { - break - } - } - intStringLen := int(stringLen) - if intStringLen < 0 { - return ErrInvalidLengthClient - } - postIndex := iNdEx + intStringLen - if postIndex < 0 { - return ErrInvalidLengthClient - } - if postIndex > l { - return io.ErrUnexpectedEOF - } - m.ClientId = string(dAtA[iNdEx:postIndex]) - iNdEx = postIndex - case 2: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field ClientState", wireType) - } - var msglen int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowClient - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - msglen |= int(b&0x7F) << shift - if b < 0x80 { - break - } - } - if msglen < 0 { - return ErrInvalidLengthClient - } - postIndex := iNdEx + msglen - if postIndex < 0 { - return ErrInvalidLengthClient - } - if postIndex > l { - return io.ErrUnexpectedEOF - } - if m.ClientState == nil { - m.ClientState = &types.Any{} - } - if err := m.ClientState.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { - return err - } - iNdEx = postIndex - case 3: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field ConsensusState", wireType) - } - var msglen int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowClient - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - msglen |= int(b&0x7F) << shift - if b < 0x80 { - break - } - } - if msglen < 0 { - return ErrInvalidLengthClient - } - postIndex := iNdEx + msglen - if postIndex < 0 { - return ErrInvalidLengthClient - } - if postIndex > l { - return io.ErrUnexpectedEOF - } - if m.ConsensusState == nil { - m.ConsensusState = &types.Any{} - } - if err := m.ConsensusState.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { - return err - } - iNdEx = postIndex - case 4: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Signer", wireType) - } - var stringLen uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowClient - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - stringLen |= uint64(b&0x7F) << shift - if b < 0x80 { - break - } - } - intStringLen := int(stringLen) - if intStringLen < 0 { - return ErrInvalidLengthClient - } - postIndex := iNdEx + intStringLen - if postIndex < 0 { - return ErrInvalidLengthClient - } - if postIndex > l { - return io.ErrUnexpectedEOF - } - m.Signer = string(dAtA[iNdEx:postIndex]) - iNdEx = postIndex - default: - iNdEx = preIndex - skippy, err := skipClient(dAtA[iNdEx:]) - if err != nil { - return err - } - if skippy < 0 { - return ErrInvalidLengthClient - } - if (iNdEx + skippy) < 0 { - return ErrInvalidLengthClient - } - if (iNdEx + skippy) > l { - return io.ErrUnexpectedEOF - } - iNdEx += skippy - } - } - - if iNdEx > l { - return io.ErrUnexpectedEOF - } - return nil -} -func (m *MsgCreateClientResponse) Unmarshal(dAtA []byte) error { - l := len(dAtA) - iNdEx := 0 - for iNdEx < l { - preIndex := iNdEx - var wire uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowClient - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - wire |= uint64(b&0x7F) << shift - if b < 0x80 { - break - } - } - fieldNum := int32(wire >> 3) - wireType := int(wire & 0x7) - if wireType == 4 { - return fmt.Errorf("proto: MsgCreateClientResponse: wiretype end group for non-group") - } - if fieldNum <= 0 { - return fmt.Errorf("proto: MsgCreateClientResponse: illegal tag %d (wire type %d)", fieldNum, wire) - } - switch fieldNum { - default: - iNdEx = preIndex - skippy, err := skipClient(dAtA[iNdEx:]) - if err != nil { - return err - } - if skippy < 0 { - return ErrInvalidLengthClient - } - if (iNdEx + skippy) < 0 { - return ErrInvalidLengthClient - } - if (iNdEx + skippy) > l { - return io.ErrUnexpectedEOF - } - iNdEx += skippy - } - } - - if iNdEx > l { - return io.ErrUnexpectedEOF - } - return nil -} -func (m *MsgUpdateClient) Unmarshal(dAtA []byte) error { - l := len(dAtA) - iNdEx := 0 - for iNdEx < l { - preIndex := iNdEx - var wire uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowClient - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - wire |= uint64(b&0x7F) << shift - if b < 0x80 { - break - } - } - fieldNum := int32(wire >> 3) - wireType := int(wire & 0x7) - if wireType == 4 { - return fmt.Errorf("proto: MsgUpdateClient: wiretype end group for non-group") - } - if fieldNum <= 0 { - return fmt.Errorf("proto: MsgUpdateClient: illegal tag %d (wire type %d)", fieldNum, wire) - } - switch fieldNum { - case 1: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field ClientId", wireType) - } - var stringLen uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowClient - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - stringLen |= uint64(b&0x7F) << shift - if b < 0x80 { - break - } - } - intStringLen := int(stringLen) - if intStringLen < 0 { - return ErrInvalidLengthClient - } - postIndex := iNdEx + intStringLen - if postIndex < 0 { - return ErrInvalidLengthClient - } - if postIndex > l { - return io.ErrUnexpectedEOF - } - m.ClientId = string(dAtA[iNdEx:postIndex]) - iNdEx = postIndex - case 2: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Header", wireType) - } - var msglen int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowClient - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - msglen |= int(b&0x7F) << shift - if b < 0x80 { - break - } - } - if msglen < 0 { - return ErrInvalidLengthClient - } - postIndex := iNdEx + msglen - if postIndex < 0 { - return ErrInvalidLengthClient - } - if postIndex > l { - return io.ErrUnexpectedEOF - } - if m.Header == nil { - m.Header = &types.Any{} - } - if err := m.Header.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { - return err - } - iNdEx = postIndex - case 3: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Signer", wireType) - } - var stringLen uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowClient - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - stringLen |= uint64(b&0x7F) << shift - if b < 0x80 { - break - } - } - intStringLen := int(stringLen) - if intStringLen < 0 { - return ErrInvalidLengthClient - } - postIndex := iNdEx + intStringLen - if postIndex < 0 { - return ErrInvalidLengthClient - } - if postIndex > l { - return io.ErrUnexpectedEOF - } - m.Signer = string(dAtA[iNdEx:postIndex]) - iNdEx = postIndex - default: - iNdEx = preIndex - skippy, err := skipClient(dAtA[iNdEx:]) - if err != nil { - return err - } - if skippy < 0 { - return ErrInvalidLengthClient - } - if (iNdEx + skippy) < 0 { - return ErrInvalidLengthClient - } - if (iNdEx + skippy) > l { - return io.ErrUnexpectedEOF - } - iNdEx += skippy - } - } - - if iNdEx > l { - return io.ErrUnexpectedEOF - } - return nil -} -func (m *MsgUpdateClientResponse) Unmarshal(dAtA []byte) error { - l := len(dAtA) - iNdEx := 0 - for iNdEx < l { - preIndex := iNdEx - var wire uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowClient - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - wire |= uint64(b&0x7F) << shift - if b < 0x80 { - break - } - } - fieldNum := int32(wire >> 3) - wireType := int(wire & 0x7) - if wireType == 4 { - return fmt.Errorf("proto: MsgUpdateClientResponse: wiretype end group for non-group") - } - if fieldNum <= 0 { - return fmt.Errorf("proto: MsgUpdateClientResponse: illegal tag %d (wire type %d)", fieldNum, wire) - } - switch fieldNum { - default: - iNdEx = preIndex - skippy, err := skipClient(dAtA[iNdEx:]) - if err != nil { - return err - } - if skippy < 0 { - return ErrInvalidLengthClient - } - if (iNdEx + skippy) < 0 { - return ErrInvalidLengthClient - } - if (iNdEx + skippy) > l { - return io.ErrUnexpectedEOF - } - iNdEx += skippy - } - } - - if iNdEx > l { - return io.ErrUnexpectedEOF - } - return nil -} -func (m *MsgUpgradeClient) Unmarshal(dAtA []byte) error { - l := len(dAtA) - iNdEx := 0 - for iNdEx < l { - preIndex := iNdEx - var wire uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowClient - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - wire |= uint64(b&0x7F) << shift - if b < 0x80 { - break - } - } - fieldNum := int32(wire >> 3) - wireType := int(wire & 0x7) - if wireType == 4 { - return fmt.Errorf("proto: MsgUpgradeClient: wiretype end group for non-group") - } - if fieldNum <= 0 { - return fmt.Errorf("proto: MsgUpgradeClient: illegal tag %d (wire type %d)", fieldNum, wire) - } - switch fieldNum { - case 1: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field ClientId", wireType) - } - var stringLen uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowClient - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - stringLen |= uint64(b&0x7F) << shift - if b < 0x80 { - break - } - } - intStringLen := int(stringLen) - if intStringLen < 0 { - return ErrInvalidLengthClient - } - postIndex := iNdEx + intStringLen - if postIndex < 0 { - return ErrInvalidLengthClient - } - if postIndex > l { - return io.ErrUnexpectedEOF - } - m.ClientId = string(dAtA[iNdEx:postIndex]) - iNdEx = postIndex - case 2: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field ClientState", wireType) - } - var msglen int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowClient - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - msglen |= int(b&0x7F) << shift - if b < 0x80 { - break - } - } - if msglen < 0 { - return ErrInvalidLengthClient - } - postIndex := iNdEx + msglen - if postIndex < 0 { - return ErrInvalidLengthClient - } - if postIndex > l { - return io.ErrUnexpectedEOF - } - if m.ClientState == nil { - m.ClientState = &types.Any{} - } - if err := m.ClientState.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { - return err - } - iNdEx = postIndex - case 3: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field UpgradeHeight", wireType) - } - var msglen int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowClient - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - msglen |= int(b&0x7F) << shift - if b < 0x80 { - break - } - } - if msglen < 0 { - return ErrInvalidLengthClient - } - postIndex := iNdEx + msglen - if postIndex < 0 { - return ErrInvalidLengthClient - } - if postIndex > l { - return io.ErrUnexpectedEOF - } - if m.UpgradeHeight == nil { - m.UpgradeHeight = &Height{} - } - if err := m.UpgradeHeight.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { - return err - } - iNdEx = postIndex - case 4: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field ProofUpgrade", wireType) - } - var byteLen int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowClient - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - byteLen |= int(b&0x7F) << shift - if b < 0x80 { - break - } - } - if byteLen < 0 { - return ErrInvalidLengthClient - } - postIndex := iNdEx + byteLen - if postIndex < 0 { - return ErrInvalidLengthClient - } - if postIndex > l { - return io.ErrUnexpectedEOF - } - m.ProofUpgrade = append(m.ProofUpgrade[:0], dAtA[iNdEx:postIndex]...) - if m.ProofUpgrade == nil { - m.ProofUpgrade = []byte{} - } - iNdEx = postIndex - case 5: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Signer", wireType) - } - var stringLen uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowClient - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - stringLen |= uint64(b&0x7F) << shift - if b < 0x80 { - break - } - } - intStringLen := int(stringLen) - if intStringLen < 0 { - return ErrInvalidLengthClient - } - postIndex := iNdEx + intStringLen - if postIndex < 0 { - return ErrInvalidLengthClient - } - if postIndex > l { - return io.ErrUnexpectedEOF - } - m.Signer = string(dAtA[iNdEx:postIndex]) - iNdEx = postIndex - default: - iNdEx = preIndex - skippy, err := skipClient(dAtA[iNdEx:]) - if err != nil { - return err - } - if skippy < 0 { - return ErrInvalidLengthClient - } - if (iNdEx + skippy) < 0 { - return ErrInvalidLengthClient - } - if (iNdEx + skippy) > l { - return io.ErrUnexpectedEOF - } - iNdEx += skippy - } - } - - if iNdEx > l { - return io.ErrUnexpectedEOF - } - return nil -} -func (m *MsgUpgradeClientResponse) Unmarshal(dAtA []byte) error { - l := len(dAtA) - iNdEx := 0 - for iNdEx < l { - preIndex := iNdEx - var wire uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowClient - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - wire |= uint64(b&0x7F) << shift - if b < 0x80 { - break - } - } - fieldNum := int32(wire >> 3) - wireType := int(wire & 0x7) - if wireType == 4 { - return fmt.Errorf("proto: MsgUpgradeClientResponse: wiretype end group for non-group") - } - if fieldNum <= 0 { - return fmt.Errorf("proto: MsgUpgradeClientResponse: illegal tag %d (wire type %d)", fieldNum, wire) - } - switch fieldNum { - default: - iNdEx = preIndex - skippy, err := skipClient(dAtA[iNdEx:]) - if err != nil { - return err - } - if skippy < 0 { - return ErrInvalidLengthClient - } - if (iNdEx + skippy) < 0 { - return ErrInvalidLengthClient - } - if (iNdEx + skippy) > l { - return io.ErrUnexpectedEOF - } - iNdEx += skippy - } - } - - if iNdEx > l { - return io.ErrUnexpectedEOF - } - return nil -} -func (m *MsgSubmitMisbehaviour) Unmarshal(dAtA []byte) error { - l := len(dAtA) - iNdEx := 0 - for iNdEx < l { - preIndex := iNdEx - var wire uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowClient - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - wire |= uint64(b&0x7F) << shift - if b < 0x80 { - break - } - } - fieldNum := int32(wire >> 3) - wireType := int(wire & 0x7) - if wireType == 4 { - return fmt.Errorf("proto: MsgSubmitMisbehaviour: wiretype end group for non-group") - } - if fieldNum <= 0 { - return fmt.Errorf("proto: MsgSubmitMisbehaviour: illegal tag %d (wire type %d)", fieldNum, wire) - } - switch fieldNum { - case 1: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field ClientId", wireType) - } - var stringLen uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowClient - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - stringLen |= uint64(b&0x7F) << shift - if b < 0x80 { - break - } - } - intStringLen := int(stringLen) - if intStringLen < 0 { - return ErrInvalidLengthClient - } - postIndex := iNdEx + intStringLen - if postIndex < 0 { - return ErrInvalidLengthClient - } - if postIndex > l { - return io.ErrUnexpectedEOF - } - m.ClientId = string(dAtA[iNdEx:postIndex]) - iNdEx = postIndex - case 2: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Misbehaviour", wireType) - } - var msglen int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowClient - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - msglen |= int(b&0x7F) << shift - if b < 0x80 { - break - } - } - if msglen < 0 { - return ErrInvalidLengthClient - } - postIndex := iNdEx + msglen - if postIndex < 0 { - return ErrInvalidLengthClient - } - if postIndex > l { - return io.ErrUnexpectedEOF - } - if m.Misbehaviour == nil { - m.Misbehaviour = &types.Any{} - } - if err := m.Misbehaviour.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { - return err - } - iNdEx = postIndex - case 3: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Signer", wireType) - } - var stringLen uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowClient - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - stringLen |= uint64(b&0x7F) << shift - if b < 0x80 { - break - } - } - intStringLen := int(stringLen) - if intStringLen < 0 { - return ErrInvalidLengthClient - } - postIndex := iNdEx + intStringLen - if postIndex < 0 { - return ErrInvalidLengthClient - } - if postIndex > l { - return io.ErrUnexpectedEOF - } - m.Signer = string(dAtA[iNdEx:postIndex]) - iNdEx = postIndex - default: - iNdEx = preIndex - skippy, err := skipClient(dAtA[iNdEx:]) - if err != nil { - return err - } - if skippy < 0 { - return ErrInvalidLengthClient - } - if (iNdEx + skippy) < 0 { - return ErrInvalidLengthClient - } - if (iNdEx + skippy) > l { - return io.ErrUnexpectedEOF - } - iNdEx += skippy - } - } - - if iNdEx > l { - return io.ErrUnexpectedEOF - } - return nil -} -func (m *MsgSubmitMisbehaviourResponse) Unmarshal(dAtA []byte) error { - l := len(dAtA) - iNdEx := 0 - for iNdEx < l { - preIndex := iNdEx - var wire uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowClient - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - wire |= uint64(b&0x7F) << shift - if b < 0x80 { - break - } - } - fieldNum := int32(wire >> 3) - wireType := int(wire & 0x7) - if wireType == 4 { - return fmt.Errorf("proto: MsgSubmitMisbehaviourResponse: wiretype end group for non-group") - } - if fieldNum <= 0 { - return fmt.Errorf("proto: MsgSubmitMisbehaviourResponse: illegal tag %d (wire type %d)", fieldNum, wire) - } - switch fieldNum { - default: - iNdEx = preIndex - skippy, err := skipClient(dAtA[iNdEx:]) - if err != nil { - return err - } - if skippy < 0 { - return ErrInvalidLengthClient - } - if (iNdEx + skippy) < 0 { - return ErrInvalidLengthClient - } - if (iNdEx + skippy) > l { - return io.ErrUnexpectedEOF - } - iNdEx += skippy - } - } - - if iNdEx > l { - return io.ErrUnexpectedEOF - } - return nil -} func (m *IdentifiedClientState) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 @@ -3272,6 +1397,91 @@ func (m *Height) Unmarshal(dAtA []byte) error { } return nil } +func (m *Params) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowClient + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: Params: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: Params: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field AllowedClients", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowClient + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthClient + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return ErrInvalidLengthClient + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.AllowedClients = append(m.AllowedClients, string(dAtA[iNdEx:postIndex])) + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipClient(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthClient + } + if (iNdEx + skippy) < 0 { + return ErrInvalidLengthClient + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} func skipClient(dAtA []byte) (n int, err error) { l := len(dAtA) iNdEx := 0 diff --git a/x/ibc/core/02-client/types/client_test.go b/x/ibc/core/02-client/types/client_test.go index 3028980b8..409ab5305 100644 --- a/x/ibc/core/02-client/types/client_test.go +++ b/x/ibc/core/02-client/types/client_test.go @@ -2,6 +2,7 @@ package types_test import ( "github.com/cosmos/cosmos-sdk/x/ibc/core/02-client/types" + "github.com/cosmos/cosmos-sdk/x/ibc/core/exported" ibctesting "github.com/cosmos/cosmos-sdk/x/ibc/testing" ) @@ -22,7 +23,7 @@ func (suite *TypesTestSuite) TestMarshalConsensusStateWithHeight() { }, { "tendermint client", func() { - clientA, _ := suite.coordinator.SetupClients(suite.chainA, suite.chainB, ibctesting.Tendermint) + clientA, _ := suite.coordinator.SetupClients(suite.chainA, suite.chainB, exported.Tendermint) clientState := suite.chainA.GetClientState(clientA) consensusState, ok := suite.chainA.GetConsensusState(clientA, clientState.GetLatestHeight()) suite.Require().True(ok) diff --git a/x/ibc/core/02-client/types/genesis.go b/x/ibc/core/02-client/types/genesis.go index c9be22f82..fc3ba12d1 100644 --- a/x/ibc/core/02-client/types/genesis.go +++ b/x/ibc/core/02-client/types/genesis.go @@ -66,11 +66,13 @@ func (ccs ClientConsensusStates) UnpackInterfaces(unpacker codectypes.AnyUnpacke // NewGenesisState creates a GenesisState instance. func NewGenesisState( - clients []IdentifiedClientState, clientsConsensus ClientsConsensusStates, createLocalhost bool, + clients []IdentifiedClientState, clientsConsensus ClientsConsensusStates, + params Params, createLocalhost bool, ) GenesisState { return GenesisState{ Clients: clients, ClientsConsensus: clientsConsensus, + Params: params, CreateLocalhost: createLocalhost, } } @@ -80,6 +82,7 @@ func DefaultGenesisState() GenesisState { return GenesisState{ Clients: []IdentifiedClientState{}, ClientsConsensus: ClientsConsensusStates{}, + Params: DefaultParams(), CreateLocalhost: false, } } @@ -133,5 +136,13 @@ func (gs GenesisState) Validate() error { } } + if err := gs.Params.Validate(); err != nil { + return err + } + + if gs.CreateLocalhost && !gs.Params.IsAllowedClient(exported.Localhost) { + return fmt.Errorf("localhost client is not registered on the allowlist") + } + return nil } diff --git a/x/ibc/core/02-client/types/genesis.pb.go b/x/ibc/core/02-client/types/genesis.pb.go index 8d16b4519..4c72edfe5 100644 --- a/x/ibc/core/02-client/types/genesis.pb.go +++ b/x/ibc/core/02-client/types/genesis.pb.go @@ -26,11 +26,12 @@ const _ = proto.GoGoProtoPackageIsVersion3 // please upgrade the proto package // GenesisState defines the ibc client submodule's genesis state. type GenesisState struct { // client states with their corresponding identifiers - Clients []IdentifiedClientState `protobuf:"bytes,1,rep,name=clients,proto3" json:"clients"` + Clients IdentifiedClientStates `protobuf:"bytes,1,rep,name=clients,proto3,castrepeated=IdentifiedClientStates" json:"clients"` // consensus states from each client ClientsConsensus ClientsConsensusStates `protobuf:"bytes,2,rep,name=clients_consensus,json=clientsConsensus,proto3,castrepeated=ClientsConsensusStates" json:"clients_consensus" yaml:"clients_consensus"` + Params Params `protobuf:"bytes,3,opt,name=params,proto3" json:"params"` // create localhost on initialization - CreateLocalhost bool `protobuf:"varint,3,opt,name=create_localhost,json=createLocalhost,proto3" json:"create_localhost,omitempty" yaml:"create_localhost"` + CreateLocalhost bool `protobuf:"varint,4,opt,name=create_localhost,json=createLocalhost,proto3" json:"create_localhost,omitempty" yaml:"create_localhost"` } func (m *GenesisState) Reset() { *m = GenesisState{} } @@ -66,7 +67,7 @@ func (m *GenesisState) XXX_DiscardUnknown() { var xxx_messageInfo_GenesisState proto.InternalMessageInfo -func (m *GenesisState) GetClients() []IdentifiedClientState { +func (m *GenesisState) GetClients() IdentifiedClientStates { if m != nil { return m.Clients } @@ -80,6 +81,13 @@ func (m *GenesisState) GetClientsConsensus() ClientsConsensusStates { return nil } +func (m *GenesisState) GetParams() Params { + if m != nil { + return m.Params + } + return Params{} +} + func (m *GenesisState) GetCreateLocalhost() bool { if m != nil { return m.CreateLocalhost @@ -94,28 +102,30 @@ func init() { func init() { proto.RegisterFile("ibc/core/client/v1/genesis.proto", fileDescriptor_bcd0c0f1f2e6a91a) } var fileDescriptor_bcd0c0f1f2e6a91a = []byte{ - // 328 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe2, 0x52, 0xc8, 0x4c, 0x4a, 0xd6, - 0x4f, 0xce, 0x2f, 0x4a, 0xd5, 0x4f, 0xce, 0xc9, 0x4c, 0xcd, 0x2b, 0xd1, 0x2f, 0x33, 0xd4, 0x4f, - 0x4f, 0xcd, 0x4b, 0x2d, 0xce, 0x2c, 0xd6, 0x2b, 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x1c, 0x4e, - 0xd2, 0x9f, 0xee, 0xc9, 0x8b, 0x43, 0xed, 0x40, 0x53, 0xa1, 0x14, 0xc4, 0x0f, 0x11, 0xf2, 0x81, - 0x89, 0x38, 0x05, 0x9e, 0x78, 0x24, 0xc7, 0x78, 0xe1, 0x91, 0x1c, 0xe3, 0x83, 0x47, 0x72, 0x8c, - 0x13, 0x1e, 0xcb, 0x31, 0x5c, 0x78, 0x2c, 0xc7, 0x70, 0xe3, 0xb1, 0x1c, 0x43, 0x94, 0x79, 0x7a, - 0x66, 0x49, 0x46, 0x69, 0x92, 0x5e, 0x72, 0x7e, 0xae, 0x7e, 0x72, 0x7e, 0x71, 0x6e, 0x7e, 0x31, - 0x94, 0xd2, 0x2d, 0x4e, 0xc9, 0xd6, 0xaf, 0xd0, 0x87, 0x47, 0x94, 0x81, 0x91, 0x2e, 0x34, 0xae, - 0x4a, 0x2a, 0x0b, 0x52, 0x8b, 0x93, 0xd8, 0xc0, 0x51, 0x62, 0x0c, 0x08, 0x00, 0x00, 0xff, 0xff, - 0x5b, 0xe3, 0x61, 0x24, 0x01, 0x02, 0x00, 0x00, + // 362 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x74, 0x91, 0xc1, 0x4e, 0xea, 0x40, + 0x14, 0x86, 0xdb, 0x0b, 0xe1, 0xde, 0x94, 0x9b, 0x88, 0x8d, 0xd1, 0x06, 0x93, 0xb6, 0xe9, 0x0a, + 0x17, 0xcc, 0x08, 0x2e, 0x34, 0x2c, 0x4b, 0xa2, 0x31, 0x71, 0xa1, 0x75, 0xe7, 0x86, 0xb4, 0xc3, + 0x58, 0x26, 0xb6, 0x1d, 0xd2, 0x33, 0x10, 0x79, 0x05, 0x57, 0xc6, 0xc7, 0xf0, 0x49, 0x58, 0xb2, + 0x74, 0x85, 0x06, 0xde, 0x80, 0x27, 0x30, 0xed, 0x14, 0x17, 0x80, 0xab, 0x39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92, 0x52, 0x5f, 0xd0, 0x5e, 0xc4, 0x89, 0x1f, 0x0d, 0x38, 0x08, 0xa3, 0x6c, + 0xab, 0x8d, 0x7f, 0xee, 0xf1, 0x6a, 0x6e, 0x1d, 0x15, 0xdb, 0x6d, 0x38, 0x1c, 0x6f, 0x4f, 0x4a, + 0x37, 0x6b, 0xc5, 0xbd, 0x9b, 0x2e, 0x4c, 0x75, 0xb6, 0x30, 0xd5, 0xaf, 0x85, 0xa9, 0xbe, 0x2e, + 0x4d, 0x65, 0xb6, 0x34, 0x95, 0x8f, 0xa5, 0xa9, 0x3c, 0x9c, 0x87, 0x4c, 0x0c, 0x46, 0x01, 0x22, + 0x3c, 0xc6, 0x84, 0x43, 0xcc, 0xa1, 0x78, 0x9a, 0xd0, 0x7f, 0xc2, 0xcf, 0xf8, 0xe7, 0xf8, 0xa7, + 0xed, 0x66, 0x71, 0x7f, 0x31, 0x19, 0x52, 0x08, 0x2a, 0xf9, 0x99, 0xcf, 0xbe, 0x03, 0x00, 0x00, + 0xff, 0xff, 0x8d, 0xa4, 0x74, 0xd6, 0x55, 0x02, 0x00, 0x00, } func (m *GenesisState) Marshal() (dAtA []byte, err error) { @@ -146,8 +156,18 @@ func (m *GenesisState) MarshalToSizedBuffer(dAtA []byte) (int, error) { dAtA[i] = 0 } i-- - dAtA[i] = 0x18 + dAtA[i] = 0x20 } + { + size, err := m.Params.MarshalToSizedBuffer(dAtA[:i]) + if err != nil { + return 0, err + } + i -= size + i = encodeVarintGenesis(dAtA, i, uint64(size)) + } + i-- + dAtA[i] = 0x1a if len(m.ClientsConsensus) > 0 { for iNdEx := len(m.ClientsConsensus) - 1; iNdEx >= 0; iNdEx-- { { @@ -208,6 +228,8 @@ func (m *GenesisState) Size() (n int) { n += 1 + l + sovGenesis(uint64(l)) } } + l = m.Params.Size() + n += 1 + l + sovGenesis(uint64(l)) if m.CreateLocalhost { n += 2 } @@ -318,6 +340,39 @@ func (m *GenesisState) Unmarshal(dAtA []byte) error { } iNdEx = postIndex case 3: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Params", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenesis + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenesis + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return ErrInvalidLengthGenesis + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.Params.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 4: if wireType != 0 { return fmt.Errorf("proto: wrong wireType = %d for field CreateLocalhost", wireType) } diff --git a/x/ibc/core/02-client/types/genesis_test.go b/x/ibc/core/02-client/types/genesis_test.go index 41d88edae..296bceb12 100644 --- a/x/ibc/core/02-client/types/genesis_test.go +++ b/x/ibc/core/02-client/types/genesis_test.go @@ -28,7 +28,7 @@ var clientHeight = types.NewHeight(0, 10) func (suite *TypesTestSuite) TestMarshalGenesisState() { cdc := suite.chainA.App.AppCodec() clientA, _, _, _, _, _ := suite.coordinator.Setup(suite.chainA, suite.chainB, channeltypes.ORDERED) - suite.coordinator.UpdateClient(suite.chainA, suite.chainB, clientA, ibctesting.Tendermint) + suite.coordinator.UpdateClient(suite.chainA, suite.chainB, clientA, exported.Tendermint) genesis := client.ExportGenesis(suite.chainA.GetContext(), suite.chainA.App.IBCKeeper.ClientKeeper) @@ -65,7 +65,7 @@ func (suite *TypesTestSuite) TestValidateGenesis() { expPass: true, }, { - name: "valid genesis", + name: "valid custom genesis", genState: types.NewGenesisState( []types.IdentifiedClientState{ types.NewIdentifiedClientState( @@ -88,7 +88,8 @@ func (suite *TypesTestSuite) TestValidateGenesis() { }, ), }, - true, + types.NewParams(exported.Tendermint), + false, ), expPass: true, }, @@ -116,7 +117,8 @@ func (suite *TypesTestSuite) TestValidateGenesis() { }, ), }, - true, + types.NewParams(exported.Tendermint), + false, ), expPass: false, }, @@ -130,12 +132,13 @@ func (suite *TypesTestSuite) TestValidateGenesis() { types.NewIdentifiedClientState(exported.Localhost, localhosttypes.NewClientState("chaindID", types.ZeroHeight())), }, nil, - true, + types.NewParams(exported.Tendermint), + false, ), expPass: false, }, { - name: "invalid consensus state", + name: "invalid consensus state client id", genState: types.NewGenesisState( []types.IdentifiedClientState{ types.NewIdentifiedClientState( @@ -158,12 +161,13 @@ func (suite *TypesTestSuite) TestValidateGenesis() { }, ), }, - true, + types.NewParams(exported.Tendermint), + false, ), expPass: false, }, { - name: "invalid consensus state", + name: "invalid consensus state height", genState: types.NewGenesisState( []types.IdentifiedClientState{ types.NewIdentifiedClientState( @@ -186,6 +190,123 @@ func (suite *TypesTestSuite) TestValidateGenesis() { }, ), }, + types.NewParams(exported.Tendermint), + false, + ), + expPass: false, + }, + { + name: "invalid consensus state", + genState: types.NewGenesisState( + []types.IdentifiedClientState{ + types.NewIdentifiedClientState( + clientID, ibctmtypes.NewClientState(chainID, ibctmtypes.DefaultTrustLevel, ibctesting.TrustingPeriod, ibctesting.UnbondingPeriod, ibctesting.MaxClockDrift, clientHeight, ibctesting.DefaultConsensusParams, commitmenttypes.GetSDKSpecs(), ibctesting.UpgradePath, false, false), + ), + types.NewIdentifiedClientState( + exported.Localhost, localhosttypes.NewClientState("chaindID", clientHeight), + ), + }, + []types.ClientConsensusStates{ + types.NewClientConsensusStates( + clientID, + []types.ConsensusStateWithHeight{ + types.NewConsensusStateWithHeight( + types.NewHeight(0, 1), + ibctmtypes.NewConsensusState( + time.Time{}, commitmenttypes.NewMerkleRoot(header.Header.GetAppHash()), header.Header.NextValidatorsHash, + ), + ), + }, + ), + }, + types.NewParams(exported.Tendermint), + false, + ), + expPass: false, + }, + { + name: "invalid params", + genState: types.NewGenesisState( + []types.IdentifiedClientState{ + types.NewIdentifiedClientState( + clientID, ibctmtypes.NewClientState(chainID, ibctesting.DefaultTrustLevel, ibctesting.TrustingPeriod, ibctesting.UnbondingPeriod, ibctesting.MaxClockDrift, clientHeight, ibctesting.DefaultConsensusParams, commitmenttypes.GetSDKSpecs(), ibctesting.UpgradePath, false, false), + ), + types.NewIdentifiedClientState( + exported.Localhost, localhosttypes.NewClientState("chainID", clientHeight), + ), + }, + []types.ClientConsensusStates{ + types.NewClientConsensusStates( + clientID, + []types.ConsensusStateWithHeight{ + types.NewConsensusStateWithHeight( + header.GetHeight().(types.Height), + ibctmtypes.NewConsensusState( + header.GetTime(), commitmenttypes.NewMerkleRoot(header.Header.GetAppHash()), header.Header.NextValidatorsHash, + ), + ), + }, + ), + }, + types.NewParams(" "), + false, + ), + expPass: false, + }, + { + name: "invalid param", + genState: types.NewGenesisState( + []types.IdentifiedClientState{ + types.NewIdentifiedClientState( + clientID, ibctmtypes.NewClientState(chainID, ibctesting.DefaultTrustLevel, ibctesting.TrustingPeriod, ibctesting.UnbondingPeriod, ibctesting.MaxClockDrift, clientHeight, ibctesting.DefaultConsensusParams, commitmenttypes.GetSDKSpecs(), ibctesting.UpgradePath, false, false), + ), + types.NewIdentifiedClientState( + exported.Localhost, localhosttypes.NewClientState("chainID", clientHeight), + ), + }, + []types.ClientConsensusStates{ + types.NewClientConsensusStates( + clientID, + []types.ConsensusStateWithHeight{ + types.NewConsensusStateWithHeight( + header.GetHeight().(types.Height), + ibctmtypes.NewConsensusState( + header.GetTime(), commitmenttypes.NewMerkleRoot(header.Header.GetAppHash()), header.Header.NextValidatorsHash, + ), + ), + }, + ), + }, + types.NewParams(" "), + true, + ), + expPass: false, + }, + { + name: "localhost client not registered on allowlist", + genState: types.NewGenesisState( + []types.IdentifiedClientState{ + types.NewIdentifiedClientState( + clientID, ibctmtypes.NewClientState(chainID, ibctesting.DefaultTrustLevel, ibctesting.TrustingPeriod, ibctesting.UnbondingPeriod, ibctesting.MaxClockDrift, clientHeight, ibctesting.DefaultConsensusParams, commitmenttypes.GetSDKSpecs(), ibctesting.UpgradePath, false, false), + ), + types.NewIdentifiedClientState( + exported.Localhost, localhosttypes.NewClientState("chainID", clientHeight), + ), + }, + []types.ClientConsensusStates{ + types.NewClientConsensusStates( + clientID, + []types.ConsensusStateWithHeight{ + types.NewConsensusStateWithHeight( + header.GetHeight().(types.Height), + ibctmtypes.NewConsensusState( + header.GetTime(), commitmenttypes.NewMerkleRoot(header.Header.GetAppHash()), header.Header.NextValidatorsHash, + ), + ), + }, + ), + }, + types.NewParams(exported.Tendermint), true, ), expPass: false, diff --git a/x/ibc/core/02-client/types/params.go b/x/ibc/core/02-client/types/params.go new file mode 100644 index 000000000..6477e3f6f --- /dev/null +++ b/x/ibc/core/02-client/types/params.go @@ -0,0 +1,71 @@ +package types + +import ( + "fmt" + "strings" + + "github.com/cosmos/cosmos-sdk/x/ibc/core/exported" + paramtypes "github.com/cosmos/cosmos-sdk/x/params/types" +) + +var ( + // DefaultAllowedClients are "06-solomachine" and "07-tendermint" + DefaultAllowedClients = []string{exported.Solomachine, exported.Tendermint} + + // KeyAllowedClients is store's key for AllowedClients Params + KeyAllowedClients = []byte("AllowedClients") +) + +// ParamKeyTable type declaration for parameters +func ParamKeyTable() paramtypes.KeyTable { + return paramtypes.NewKeyTable().RegisterParamSet(&Params{}) +} + +// NewParams creates a new parameter configuration for the ibc transfer module +func NewParams(allowedClients ...string) Params { + return Params{ + AllowedClients: allowedClients, + } +} + +// DefaultParams is the default parameter configuration for the ibc-transfer module +func DefaultParams() Params { + return NewParams(DefaultAllowedClients...) +} + +// Validate all ibc-transfer module parameters +func (p Params) Validate() error { + return validateClients(p.AllowedClients) +} + +// ParamSetPairs implements params.ParamSet +func (p *Params) ParamSetPairs() paramtypes.ParamSetPairs { + return paramtypes.ParamSetPairs{ + paramtypes.NewParamSetPair(KeyAllowedClients, p.AllowedClients, validateClients), + } +} + +// IsAllowedClient checks if the given client type is registered on the allowlist. +func (p Params) IsAllowedClient(clientType string) bool { + for _, allowedClient := range p.AllowedClients { + if allowedClient == clientType { + return true + } + } + return false +} + +func validateClients(i interface{}) error { + clients, ok := i.([]string) + if !ok { + return fmt.Errorf("invalid parameter type: %T", i) + } + + for i, clientType := range clients { + if strings.TrimSpace(clientType) == "" { + return fmt.Errorf("client type %d cannot be blank", i) + } + } + + return nil +} diff --git a/x/ibc/core/02-client/types/params_test.go b/x/ibc/core/02-client/types/params_test.go new file mode 100644 index 000000000..9484e48b4 --- /dev/null +++ b/x/ibc/core/02-client/types/params_test.go @@ -0,0 +1,29 @@ +package types + +import ( + "testing" + + "github.com/cosmos/cosmos-sdk/x/ibc/core/exported" + "github.com/stretchr/testify/require" +) + +func TestValidateParams(t *testing.T) { + testCases := []struct { + name string + params Params + expPass bool + }{ + {"default params", DefaultParams(), true}, + {"custom params", NewParams(exported.Tendermint), true}, + {"blank client", NewParams(" "), false}, + } + + for _, tc := range testCases { + err := tc.params.Validate() + if tc.expPass { + require.NoError(t, err, tc.name) + } else { + require.Error(t, err, tc.name) + } + } +} diff --git a/x/ibc/core/02-client/types/query.pb.go b/x/ibc/core/02-client/types/query.pb.go index 3e250c9ea..755d40180 100644 --- a/x/ibc/core/02-client/types/query.pb.go +++ b/x/ibc/core/02-client/types/query.pb.go @@ -195,7 +195,7 @@ func (m *QueryClientStatesRequest) GetPagination() *query.PageRequest { // method. type QueryClientStatesResponse struct { // list of stored ClientStates of the chain. - ClientStates []*IdentifiedClientState `protobuf:"bytes,1,rep,name=client_states,json=clientStates,proto3" json:"client_states,omitempty"` + ClientStates IdentifiedClientStates `protobuf:"bytes,1,rep,name=client_states,json=clientStates,proto3,castrepeated=IdentifiedClientStates" json:"client_states"` // pagination response Pagination *query.PageResponse `protobuf:"bytes,2,opt,name=pagination,proto3" json:"pagination,omitempty"` } @@ -233,7 +233,7 @@ func (m *QueryClientStatesResponse) XXX_DiscardUnknown() { var xxx_messageInfo_QueryClientStatesResponse proto.InternalMessageInfo -func (m *QueryClientStatesResponse) GetClientStates() []*IdentifiedClientState { +func (m *QueryClientStatesResponse) GetClientStates() IdentifiedClientStates { if m != nil { return m.ClientStates } @@ -500,6 +500,89 @@ func (m *QueryConsensusStatesResponse) GetPagination() *query.PageResponse { return nil } +// QueryClientParamsRequest is the request type for the Query/ClientParams RPC method. +type QueryClientParamsRequest struct { +} + +func (m *QueryClientParamsRequest) Reset() { *m = QueryClientParamsRequest{} } +func (m *QueryClientParamsRequest) String() string { return proto.CompactTextString(m) } +func (*QueryClientParamsRequest) ProtoMessage() {} +func (*QueryClientParamsRequest) Descriptor() ([]byte, []int) { + return fileDescriptor_dc42cdfd1d52d76e, []int{8} +} +func (m *QueryClientParamsRequest) XXX_Unmarshal(b []byte) error { + return m.Unmarshal(b) +} +func (m *QueryClientParamsRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { + if deterministic { + return xxx_messageInfo_QueryClientParamsRequest.Marshal(b, m, deterministic) + } else { + b = b[:cap(b)] + n, err := m.MarshalToSizedBuffer(b) + if err != nil { + return nil, err + } + return b[:n], nil + } +} +func (m *QueryClientParamsRequest) XXX_Merge(src proto.Message) { + xxx_messageInfo_QueryClientParamsRequest.Merge(m, src) +} +func (m *QueryClientParamsRequest) XXX_Size() int { + return m.Size() +} +func (m *QueryClientParamsRequest) XXX_DiscardUnknown() { + xxx_messageInfo_QueryClientParamsRequest.DiscardUnknown(m) +} + +var xxx_messageInfo_QueryClientParamsRequest proto.InternalMessageInfo + +// QueryClientParamsResponse is the response type for the Query/ClientParams RPC method. +type QueryClientParamsResponse struct { + // params defines the parameters of the module. + Params *Params `protobuf:"bytes,1,opt,name=params,proto3" json:"params,omitempty"` +} + +func (m *QueryClientParamsResponse) Reset() { *m = QueryClientParamsResponse{} } +func (m *QueryClientParamsResponse) String() string { return proto.CompactTextString(m) } +func (*QueryClientParamsResponse) ProtoMessage() {} +func (*QueryClientParamsResponse) Descriptor() ([]byte, []int) { + return fileDescriptor_dc42cdfd1d52d76e, []int{9} +} +func (m *QueryClientParamsResponse) XXX_Unmarshal(b []byte) error { + return m.Unmarshal(b) +} +func (m *QueryClientParamsResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { + if deterministic { + return xxx_messageInfo_QueryClientParamsResponse.Marshal(b, m, deterministic) + } else { + b = b[:cap(b)] + n, err := m.MarshalToSizedBuffer(b) + if err != nil { + return nil, err + } + return b[:n], nil + } +} +func (m *QueryClientParamsResponse) XXX_Merge(src proto.Message) { + xxx_messageInfo_QueryClientParamsResponse.Merge(m, src) +} +func (m *QueryClientParamsResponse) XXX_Size() int { + return m.Size() +} +func (m *QueryClientParamsResponse) XXX_DiscardUnknown() { + xxx_messageInfo_QueryClientParamsResponse.DiscardUnknown(m) +} + +var xxx_messageInfo_QueryClientParamsResponse proto.InternalMessageInfo + +func (m *QueryClientParamsResponse) GetParams() *Params { + if m != nil { + return m.Params + } + return nil +} + func init() { proto.RegisterType((*QueryClientStateRequest)(nil), "ibc.core.client.v1.QueryClientStateRequest") proto.RegisterType((*QueryClientStateResponse)(nil), "ibc.core.client.v1.QueryClientStateResponse") @@ -509,59 +592,66 @@ func init() { proto.RegisterType((*QueryConsensusStateResponse)(nil), "ibc.core.client.v1.QueryConsensusStateResponse") proto.RegisterType((*QueryConsensusStatesRequest)(nil), "ibc.core.client.v1.QueryConsensusStatesRequest") proto.RegisterType((*QueryConsensusStatesResponse)(nil), "ibc.core.client.v1.QueryConsensusStatesResponse") + proto.RegisterType((*QueryClientParamsRequest)(nil), "ibc.core.client.v1.QueryClientParamsRequest") + proto.RegisterType((*QueryClientParamsResponse)(nil), "ibc.core.client.v1.QueryClientParamsResponse") } func init() { proto.RegisterFile("ibc/core/client/v1/query.proto", fileDescriptor_dc42cdfd1d52d76e) } var fileDescriptor_dc42cdfd1d52d76e = []byte{ - // 746 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xb4, 0x56, 0x4d, 0x6b, 0x13, 0x4f, - 0x18, 0xcf, 0xf4, 0xe5, 0x4f, 0x3b, 0x49, 0x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x1b, 0x27, 0xfb, 0x67, - 0x82, 0x1e, 0xa0, 0x37, 0x00, 0x16, 0xe2, 0x97, 0x01, 0x65, 0x6a, 0x1d, 0x6d, 0x87, 0xb1, 0x90, - 0x31, 0x5a, 0x23, 0xc5, 0x12, 0x69, 0x05, 0xcd, 0x65, 0x43, 0x8a, 0x7e, 0x00, 0x38, 0x9e, 0xd4, - 0x12, 0xe1, 0x8b, 0x3b, 0xa6, 0x5d, 0x0a, 0x83, 0x64, 0x8e, 0xd7, 0x18, 0x03, 0x89, 0xb1, 0x89, - 0x1a, 0x17, 0x63, 0x3c, 0xb7, 0x89, 0x71, 0x42, 0x89, 0x3e, 0x1e, 0x64, 0x3f, 0x79, 0x82, 0x0e, - 0x88, 0xfa, 0x48, 0x7b, 0x76, 0xf5, 0x7e, 0x80, 0x3e, 0x00, 0x38, 0x71, 0x6e, 0xed, 0x51, 0x56, - 0xd0, 0x67, 0x3a, 0x2c, 0x66, 0x4f, 0xd0, 0x63, 0x2e, 0xcb, 0x31, 0x97, 0xd0, 0xdd, 0x4b, 0x8d, - 0xb9, 0xb2, 0x79, 0x74, 0x62, 0x82, 0xe3, 0x13, 0x13, 0x7c, 0x3f, 0x31, 0xc1, 0xab, 0x53, 0x33, - 0x77, 0x7c, 0x6a, 0xe6, 0xbe, 0x9e, 0x9a, 0xb9, 0x67, 0x4b, 0x9e, 0x2f, 0x9a, 0x1d, 0x07, 0xbb, - 0x6c, 0x87, 0xe8, 0x3f, 0x19, 0xea, 0x67, 0x81, 0xd7, 0x5f, 0x90, 0x97, 0xbd, 0x76, 0x8b, 0xb5, - 0x05, 0xdd, 0x51, 0xec, 0xb5, 0x28, 0x77, 0xfe, 0x93, 0x27, 0xf0, 0xf6, 0xef, 0x00, 0x00, 0x00, - 0xff, 0xff, 0x71, 0x1f, 0x83, 0xc2, 0xcf, 0x08, 0x00, 0x00, + // 823 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00,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34, 0x0c, 0x01, 0x76, 0x16, 0x69, 0x12, 0x6c, 0x12, 0xa7, 0x5c, 0xbd, 0xd5, 0xad, + 0xa3, 0x13, 0x1d, 0x1c, 0x9f, 0xe8, 0xe0, 0xf3, 0x89, 0x0e, 0x9e, 0x9c, 0xea, 0xb9, 0xe3, 0x53, + 0x3d, 0xf7, 0xe1, 0x54, 0xcf, 0xdd, 0x5f, 0x76, 0xbd, 0xa0, 0xd1, 0xb1, 0xb1, 0xc3, 0x9a, 0x44, + 0xfd, 0x07, 0x93, 0x3f, 0x8b, 0xbc, 0xf6, 0x90, 0x3c, 0xea, 0x09, 0xb0, 0x54, 0x5d, 0x54, 0xb5, + 0x83, 0xbd, 0x16, 0xe5, 0xf6, 0x88, 0xf8, 0x02, 0xfc, 0xfb, 0x3d, 0x00, 0x00, 0xff, 0xff, 0xca, + 0xdc, 0xd5, 0x38, 0xee, 0x09, 0x00, 0x00, } // Reference imports to suppress errors if they are not otherwise used. @@ -586,6 +676,8 @@ type QueryClient interface { // ConsensusStates queries all the consensus state associated with a given // client. ConsensusStates(ctx context.Context, in *QueryConsensusStatesRequest, opts ...grpc.CallOption) (*QueryConsensusStatesResponse, error) + // ClientParams queries all parameters of the ibc client. + ClientParams(ctx context.Context, in *QueryClientParamsRequest, opts ...grpc.CallOption) (*QueryClientParamsResponse, error) } type queryClient struct { @@ -632,6 +724,15 @@ func (c *queryClient) ConsensusStates(ctx context.Context, in *QueryConsensusSta return out, nil } +func (c *queryClient) ClientParams(ctx context.Context, in *QueryClientParamsRequest, opts ...grpc.CallOption) (*QueryClientParamsResponse, error) { + out := new(QueryClientParamsResponse) + err := c.cc.Invoke(ctx, "/ibc.core.client.v1.Query/ClientParams", in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + // QueryServer is the server API for Query service. type QueryServer interface { // ClientState queries an IBC light client. @@ -644,6 +745,8 @@ type QueryServer interface { // ConsensusStates queries all the consensus state associated with a given // client. ConsensusStates(context.Context, *QueryConsensusStatesRequest) (*QueryConsensusStatesResponse, error) + // ClientParams queries all parameters of the ibc client. + ClientParams(context.Context, *QueryClientParamsRequest) (*QueryClientParamsResponse, error) } // UnimplementedQueryServer can be embedded to have forward compatible implementations. @@ -662,6 +765,9 @@ func (*UnimplementedQueryServer) ConsensusState(ctx context.Context, req *QueryC func (*UnimplementedQueryServer) ConsensusStates(ctx context.Context, req *QueryConsensusStatesRequest) (*QueryConsensusStatesResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method ConsensusStates not implemented") } +func (*UnimplementedQueryServer) ClientParams(ctx context.Context, req *QueryClientParamsRequest) (*QueryClientParamsResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method ClientParams not implemented") +} func RegisterQueryServer(s grpc1.Server, srv QueryServer) { s.RegisterService(&_Query_serviceDesc, srv) @@ -739,6 +845,24 @@ func _Query_ConsensusStates_Handler(srv interface{}, ctx context.Context, dec fu return interceptor(ctx, in, info, handler) } +func _Query_ClientParams_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(QueryClientParamsRequest) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(QueryServer).ClientParams(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: "/ibc.core.client.v1.Query/ClientParams", + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(QueryServer).ClientParams(ctx, req.(*QueryClientParamsRequest)) + } + return interceptor(ctx, in, info, handler) +} + var _Query_serviceDesc = grpc.ServiceDesc{ ServiceName: "ibc.core.client.v1.Query", HandlerType: (*QueryServer)(nil), @@ -759,6 +883,10 @@ var _Query_serviceDesc = grpc.ServiceDesc{ MethodName: "ConsensusStates", Handler: _Query_ConsensusStates_Handler, }, + { + MethodName: "ClientParams", + Handler: _Query_ClientParams_Handler, + }, }, Streams: []grpc.StreamDesc{}, Metadata: "ibc/core/client/v1/query.proto", @@ -1123,6 +1251,64 @@ func (m *QueryConsensusStatesResponse) MarshalToSizedBuffer(dAtA []byte) (int, e return len(dAtA) - i, nil } +func (m *QueryClientParamsRequest) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalToSizedBuffer(dAtA[:size]) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *QueryClientParamsRequest) MarshalTo(dAtA []byte) (int, error) { + size := m.Size() + return m.MarshalToSizedBuffer(dAtA[:size]) +} + +func (m *QueryClientParamsRequest) MarshalToSizedBuffer(dAtA []byte) (int, error) { + i := len(dAtA) + _ = i + var l int + _ = l + return len(dAtA) - i, nil +} + +func (m *QueryClientParamsResponse) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalToSizedBuffer(dAtA[:size]) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *QueryClientParamsResponse) MarshalTo(dAtA []byte) (int, error) { + size := m.Size() + return m.MarshalToSizedBuffer(dAtA[:size]) +} + +func (m *QueryClientParamsResponse) MarshalToSizedBuffer(dAtA []byte) (int, error) { + i := len(dAtA) + _ = i + var l int + _ = l + if m.Params != nil { + { + size, err := m.Params.MarshalToSizedBuffer(dAtA[:i]) + if err != nil { + return 0, err + } + i -= size + i = encodeVarintQuery(dAtA, i, uint64(size)) + } + i-- + dAtA[i] = 0xa + } + return len(dAtA) - i, nil +} + func encodeVarintQuery(dAtA []byte, offset int, v uint64) int { offset -= sovQuery(v) base := offset @@ -1275,6 +1461,28 @@ func (m *QueryConsensusStatesResponse) Size() (n int) { return n } +func (m *QueryClientParamsRequest) Size() (n int) { + if m == nil { + return 0 + } + var l int + _ = l + return n +} + +func (m *QueryClientParamsResponse) Size() (n int) { + if m == nil { + return 0 + } + var l int + _ = l + if m.Params != nil { + l = m.Params.Size() + n += 1 + l + sovQuery(uint64(l)) + } + return n +} + func sovQuery(x uint64) (n int) { return (math_bits.Len64(x|1) + 6) / 7 } @@ -1669,7 +1877,7 @@ func (m *QueryClientStatesResponse) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.ClientStates = append(m.ClientStates, &IdentifiedClientState{}) + m.ClientStates = append(m.ClientStates, IdentifiedClientState{}) if err := m.ClientStates[len(m.ClientStates)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } @@ -2277,6 +2485,148 @@ func (m *QueryConsensusStatesResponse) Unmarshal(dAtA []byte) error { } return nil } +func (m *QueryClientParamsRequest) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowQuery + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: QueryClientParamsRequest: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: QueryClientParamsRequest: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + default: + iNdEx = preIndex + skippy, err := skipQuery(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthQuery + } + if (iNdEx + skippy) < 0 { + return ErrInvalidLengthQuery + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *QueryClientParamsResponse) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowQuery + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: QueryClientParamsResponse: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: QueryClientParamsResponse: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Params", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowQuery + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthQuery + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return ErrInvalidLengthQuery + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + if m.Params == nil { + m.Params = &Params{} + } + if err := m.Params.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipQuery(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthQuery + } + if (iNdEx + skippy) < 0 { + return ErrInvalidLengthQuery + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} func skipQuery(dAtA []byte) (n int, err error) { l := len(dAtA) iNdEx := 0 diff --git a/x/ibc/core/02-client/types/query.pb.gw.go b/x/ibc/core/02-client/types/query.pb.gw.go index 4d1cce836..77b3df69a 100644 --- a/x/ibc/core/02-client/types/query.pb.gw.go +++ b/x/ibc/core/02-client/types/query.pb.gw.go @@ -309,6 +309,24 @@ func local_request_Query_ConsensusStates_0(ctx context.Context, marshaler runtim } +func request_Query_ClientParams_0(ctx context.Context, marshaler runtime.Marshaler, client QueryClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq QueryClientParamsRequest + var metadata runtime.ServerMetadata + + msg, err := client.ClientParams(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) + return msg, metadata, err + +} + +func local_request_Query_ClientParams_0(ctx context.Context, marshaler runtime.Marshaler, server QueryServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { + var protoReq QueryClientParamsRequest + var metadata runtime.ServerMetadata + + msg, err := server.ClientParams(ctx, &protoReq) + return msg, metadata, err + +} + // RegisterQueryHandlerServer registers the http handlers for service Query to "mux". // UnaryRPC :call QueryServer directly. // StreamingRPC :currently unsupported pending https://github.com/grpc/grpc-go/issues/906. @@ -395,6 +413,26 @@ func RegisterQueryHandlerServer(ctx context.Context, mux *runtime.ServeMux, serv }) + mux.Handle("GET", pattern_Query_ClientParams_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := local_request_Query_ClientParams_0(rctx, inboundMarshaler, server, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_Query_ClientParams_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + + }) + return nil } @@ -516,6 +554,26 @@ func RegisterQueryHandlerClient(ctx context.Context, mux *runtime.ServeMux, clie }) + mux.Handle("GET", pattern_Query_ClientParams_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + rctx, err := runtime.AnnotateContext(ctx, mux, req) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := request_Query_ClientParams_0(rctx, inboundMarshaler, client, req, pathParams) + ctx = runtime.NewServerMetadataContext(ctx, md) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + + forward_Query_ClientParams_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) + + }) + return nil } @@ -527,6 +585,8 @@ var ( pattern_Query_ConsensusState_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3, 2, 4, 1, 0, 4, 1, 5, 5, 2, 6, 1, 0, 4, 1, 5, 7, 2, 8, 1, 0, 4, 1, 5, 9}, []string{"ibc", "core", "client", "v1beta1", "consensus_states", "client_id", "version", "version_number", "height", "version_height"}, "", runtime.AssumeColonVerbOpt(true))) pattern_Query_ConsensusStates_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3, 2, 4, 1, 0, 4, 1, 5, 5}, []string{"ibc", "core", "client", "v1beta1", "consensus_states", "client_id"}, "", runtime.AssumeColonVerbOpt(true))) + + pattern_Query_ClientParams_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3}, []string{"ibc", "client", "v1beta1", "params"}, "", runtime.AssumeColonVerbOpt(true))) ) var ( @@ -537,4 +597,6 @@ var ( forward_Query_ConsensusState_0 = runtime.ForwardResponseMessage forward_Query_ConsensusStates_0 = runtime.ForwardResponseMessage + + forward_Query_ClientParams_0 = runtime.ForwardResponseMessage ) diff --git a/x/ibc/core/02-client/types/tx.pb.go b/x/ibc/core/02-client/types/tx.pb.go new file mode 100644 index 000000000..4b637e5ba --- /dev/null +++ b/x/ibc/core/02-client/types/tx.pb.go @@ -0,0 +1,2128 @@ +// Code generated by protoc-gen-gogo. DO NOT EDIT. +// source: ibc/core/client/v1/tx.proto + +package types + +import ( + context "context" + fmt "fmt" + types "github.com/cosmos/cosmos-sdk/codec/types" + _ "github.com/gogo/protobuf/gogoproto" + grpc1 "github.com/gogo/protobuf/grpc" + proto "github.com/gogo/protobuf/proto" + grpc "google.golang.org/grpc" + codes "google.golang.org/grpc/codes" + status "google.golang.org/grpc/status" + io "io" + math "math" + math_bits "math/bits" +) + +// Reference imports to suppress errors if they are not otherwise used. +var _ = proto.Marshal +var _ = fmt.Errorf +var _ = math.Inf + +// This is a compile-time assertion to ensure that this generated file +// is compatible with the proto package it is being compiled against. +// A compilation error at this line likely means your copy of the +// proto package needs to be updated. +const _ = proto.GoGoProtoPackageIsVersion3 // please upgrade the proto package + +// MsgCreateClient defines a message to create an IBC client +type MsgCreateClient struct { + // client unique identifier + ClientId string `protobuf:"bytes,1,opt,name=client_id,json=clientId,proto3" json:"client_id,omitempty" yaml:"client_id"` + // light client state + ClientState *types.Any `protobuf:"bytes,2,opt,name=client_state,json=clientState,proto3" json:"client_state,omitempty" yaml:"client_state"` + // consensus state associated with the client that corresponds to a given + // height. + ConsensusState *types.Any `protobuf:"bytes,3,opt,name=consensus_state,json=consensusState,proto3" json:"consensus_state,omitempty" yaml:"consensus_state"` + // signer address + Signer string `protobuf:"bytes,4,opt,name=signer,proto3" json:"signer,omitempty"` +} + +func (m *MsgCreateClient) Reset() { *m = MsgCreateClient{} } +func (m *MsgCreateClient) String() string { return proto.CompactTextString(m) } +func (*MsgCreateClient) ProtoMessage() {} +func (*MsgCreateClient) Descriptor() ([]byte, []int) { + return fileDescriptor_cb5dc4651eb49a04, []int{0} +} +func (m *MsgCreateClient) XXX_Unmarshal(b []byte) error { + return m.Unmarshal(b) +} +func (m *MsgCreateClient) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { + if deterministic { + return xxx_messageInfo_MsgCreateClient.Marshal(b, m, deterministic) + } else { + b = b[:cap(b)] + n, err := m.MarshalToSizedBuffer(b) + if err != nil { + return nil, err + } + return b[:n], nil + } +} +func (m *MsgCreateClient) XXX_Merge(src proto.Message) { + xxx_messageInfo_MsgCreateClient.Merge(m, src) +} +func (m *MsgCreateClient) XXX_Size() int { + return m.Size() +} +func (m *MsgCreateClient) XXX_DiscardUnknown() { + xxx_messageInfo_MsgCreateClient.DiscardUnknown(m) +} + +var xxx_messageInfo_MsgCreateClient proto.InternalMessageInfo + +// MsgCreateClientResponse defines the Msg/CreateClient response type. +type MsgCreateClientResponse struct { +} + +func (m *MsgCreateClientResponse) Reset() { *m = MsgCreateClientResponse{} } +func (m *MsgCreateClientResponse) String() string { return proto.CompactTextString(m) } +func (*MsgCreateClientResponse) ProtoMessage() {} +func (*MsgCreateClientResponse) Descriptor() ([]byte, []int) { + return fileDescriptor_cb5dc4651eb49a04, []int{1} +} +func (m *MsgCreateClientResponse) XXX_Unmarshal(b []byte) error { + return m.Unmarshal(b) +} +func (m *MsgCreateClientResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { + if deterministic { + return xxx_messageInfo_MsgCreateClientResponse.Marshal(b, m, deterministic) + } else { + b = b[:cap(b)] + n, err := m.MarshalToSizedBuffer(b) + if err != nil { + return nil, err + } + return b[:n], nil + } +} +func (m *MsgCreateClientResponse) XXX_Merge(src proto.Message) { + xxx_messageInfo_MsgCreateClientResponse.Merge(m, src) +} +func (m *MsgCreateClientResponse) XXX_Size() int { + return m.Size() +} +func (m *MsgCreateClientResponse) XXX_DiscardUnknown() { + xxx_messageInfo_MsgCreateClientResponse.DiscardUnknown(m) +} + +var xxx_messageInfo_MsgCreateClientResponse proto.InternalMessageInfo + +// MsgUpdateClient defines an sdk.Msg to update a IBC client state using +// the given header. +type MsgUpdateClient struct { + // client unique identifier + ClientId string `protobuf:"bytes,1,opt,name=client_id,json=clientId,proto3" json:"client_id,omitempty" yaml:"client_id"` + // header to update the light client + Header *types.Any `protobuf:"bytes,2,opt,name=header,proto3" json:"header,omitempty"` + // signer address + Signer string `protobuf:"bytes,3,opt,name=signer,proto3" json:"signer,omitempty"` +} + +func (m *MsgUpdateClient) Reset() { *m = MsgUpdateClient{} } +func (m *MsgUpdateClient) String() string { return proto.CompactTextString(m) } +func (*MsgUpdateClient) ProtoMessage() {} +func (*MsgUpdateClient) Descriptor() ([]byte, []int) { + return fileDescriptor_cb5dc4651eb49a04, []int{2} +} +func (m *MsgUpdateClient) XXX_Unmarshal(b []byte) error { + return m.Unmarshal(b) +} +func (m *MsgUpdateClient) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { + if deterministic { + return xxx_messageInfo_MsgUpdateClient.Marshal(b, m, deterministic) + } else { + b = b[:cap(b)] + n, err := m.MarshalToSizedBuffer(b) + if err != nil { + return nil, err + } + return b[:n], nil + } +} +func (m *MsgUpdateClient) XXX_Merge(src proto.Message) { + xxx_messageInfo_MsgUpdateClient.Merge(m, src) +} +func (m *MsgUpdateClient) XXX_Size() int { + return m.Size() +} +func (m *MsgUpdateClient) XXX_DiscardUnknown() { + xxx_messageInfo_MsgUpdateClient.DiscardUnknown(m) +} + +var xxx_messageInfo_MsgUpdateClient proto.InternalMessageInfo + +// MsgUpdateClientResponse defines the Msg/UpdateClient response type. +type MsgUpdateClientResponse struct { +} + +func (m *MsgUpdateClientResponse) Reset() { *m = MsgUpdateClientResponse{} } +func (m *MsgUpdateClientResponse) String() string { return proto.CompactTextString(m) } +func (*MsgUpdateClientResponse) ProtoMessage() {} +func (*MsgUpdateClientResponse) Descriptor() ([]byte, []int) { + return fileDescriptor_cb5dc4651eb49a04, []int{3} +} +func (m *MsgUpdateClientResponse) XXX_Unmarshal(b []byte) error { + return m.Unmarshal(b) +} +func (m *MsgUpdateClientResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { + if deterministic { + return xxx_messageInfo_MsgUpdateClientResponse.Marshal(b, m, deterministic) + } else { + b = b[:cap(b)] + n, err := m.MarshalToSizedBuffer(b) + if err != nil { + return nil, err + } + return b[:n], nil + } +} +func (m *MsgUpdateClientResponse) XXX_Merge(src proto.Message) { + xxx_messageInfo_MsgUpdateClientResponse.Merge(m, src) +} +func (m *MsgUpdateClientResponse) XXX_Size() int { + return m.Size() +} +func (m *MsgUpdateClientResponse) XXX_DiscardUnknown() { + xxx_messageInfo_MsgUpdateClientResponse.DiscardUnknown(m) +} + +var xxx_messageInfo_MsgUpdateClientResponse proto.InternalMessageInfo + +// MsgUpgradeClient defines an sdk.Msg to upgrade an IBC client to a new client state +type MsgUpgradeClient struct { + // client unique identifier + ClientId string `protobuf:"bytes,1,opt,name=client_id,json=clientId,proto3" json:"client_id,omitempty" yaml:"client_id"` + // upgraded client state + ClientState *types.Any `protobuf:"bytes,2,opt,name=client_state,json=clientState,proto3" json:"client_state,omitempty" yaml:"client_state"` + // height at which old chain halts and upgrades (i.e last block executed) + UpgradeHeight *Height `protobuf:"bytes,3,opt,name=upgrade_height,json=upgradeHeight,proto3" json:"upgrade_height,omitempty" yaml:"upgrade_height"` + // proof that old chain committed to new client + ProofUpgrade []byte `protobuf:"bytes,4,opt,name=proof_upgrade,json=proofUpgrade,proto3" json:"proof_upgrade,omitempty" yaml:"proof_upgrade"` + // signer address + Signer string `protobuf:"bytes,5,opt,name=signer,proto3" json:"signer,omitempty"` +} + +func (m *MsgUpgradeClient) Reset() { *m = MsgUpgradeClient{} } +func (m *MsgUpgradeClient) String() string { return proto.CompactTextString(m) } +func (*MsgUpgradeClient) ProtoMessage() {} +func (*MsgUpgradeClient) Descriptor() ([]byte, []int) { + return fileDescriptor_cb5dc4651eb49a04, []int{4} +} +func (m *MsgUpgradeClient) XXX_Unmarshal(b []byte) error { + return m.Unmarshal(b) +} +func (m *MsgUpgradeClient) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { + if deterministic { + return xxx_messageInfo_MsgUpgradeClient.Marshal(b, m, deterministic) + } else { + b = b[:cap(b)] + n, err := m.MarshalToSizedBuffer(b) + if err != nil { + return nil, err + } + return b[:n], nil + } +} +func (m *MsgUpgradeClient) XXX_Merge(src proto.Message) { + xxx_messageInfo_MsgUpgradeClient.Merge(m, src) +} +func (m *MsgUpgradeClient) XXX_Size() int { + return m.Size() +} +func (m *MsgUpgradeClient) XXX_DiscardUnknown() { + xxx_messageInfo_MsgUpgradeClient.DiscardUnknown(m) +} + +var xxx_messageInfo_MsgUpgradeClient proto.InternalMessageInfo + +func (m *MsgUpgradeClient) GetClientId() string { + if m != nil { + return m.ClientId + } + return "" +} + +func (m *MsgUpgradeClient) GetClientState() *types.Any { + if m != nil { + return m.ClientState + } + return nil +} + +func (m *MsgUpgradeClient) GetUpgradeHeight() *Height { + if m != nil { + return m.UpgradeHeight + } + return nil +} + +func (m *MsgUpgradeClient) GetProofUpgrade() []byte { + if m != nil { + return m.ProofUpgrade + } + return nil +} + +func (m *MsgUpgradeClient) GetSigner() string { + if m != nil { + return m.Signer + } + return "" +} + +// MsgUpgradeClientResponse defines the Msg/UpgradeClient response type. +type MsgUpgradeClientResponse struct { +} + +func (m *MsgUpgradeClientResponse) Reset() { *m = MsgUpgradeClientResponse{} } +func (m *MsgUpgradeClientResponse) String() string { return proto.CompactTextString(m) } +func (*MsgUpgradeClientResponse) ProtoMessage() {} +func (*MsgUpgradeClientResponse) Descriptor() ([]byte, []int) { + return fileDescriptor_cb5dc4651eb49a04, []int{5} +} +func (m *MsgUpgradeClientResponse) XXX_Unmarshal(b []byte) error { + return m.Unmarshal(b) +} +func (m *MsgUpgradeClientResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { + if deterministic { + return xxx_messageInfo_MsgUpgradeClientResponse.Marshal(b, m, deterministic) + } else { + b = b[:cap(b)] + n, err := m.MarshalToSizedBuffer(b) + if err != nil { + return nil, err + } + return b[:n], nil + } +} +func (m *MsgUpgradeClientResponse) XXX_Merge(src proto.Message) { + xxx_messageInfo_MsgUpgradeClientResponse.Merge(m, src) +} +func (m *MsgUpgradeClientResponse) XXX_Size() int { + return m.Size() +} +func (m *MsgUpgradeClientResponse) XXX_DiscardUnknown() { + xxx_messageInfo_MsgUpgradeClientResponse.DiscardUnknown(m) +} + +var xxx_messageInfo_MsgUpgradeClientResponse proto.InternalMessageInfo + +// MsgSubmitMisbehaviour defines an sdk.Msg type that submits Evidence for +// light client misbehaviour. +type MsgSubmitMisbehaviour struct { + // client unique identifier + ClientId string `protobuf:"bytes,1,opt,name=client_id,json=clientId,proto3" json:"client_id,omitempty" yaml:"client_id"` + // misbehaviour used for freezing the light client + Misbehaviour *types.Any `protobuf:"bytes,2,opt,name=misbehaviour,proto3" json:"misbehaviour,omitempty"` + // signer address + Signer string `protobuf:"bytes,3,opt,name=signer,proto3" json:"signer,omitempty"` +} + +func (m *MsgSubmitMisbehaviour) Reset() { *m = MsgSubmitMisbehaviour{} } +func (m *MsgSubmitMisbehaviour) String() string { return proto.CompactTextString(m) } +func (*MsgSubmitMisbehaviour) ProtoMessage() {} +func (*MsgSubmitMisbehaviour) Descriptor() ([]byte, []int) { + return fileDescriptor_cb5dc4651eb49a04, []int{6} +} +func (m *MsgSubmitMisbehaviour) XXX_Unmarshal(b []byte) error { + return m.Unmarshal(b) +} +func (m *MsgSubmitMisbehaviour) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { + if deterministic { + return xxx_messageInfo_MsgSubmitMisbehaviour.Marshal(b, m, deterministic) + } else { + b = b[:cap(b)] + n, err := m.MarshalToSizedBuffer(b) + if err != nil { + return nil, err + } + return b[:n], nil + } +} +func (m *MsgSubmitMisbehaviour) XXX_Merge(src proto.Message) { + xxx_messageInfo_MsgSubmitMisbehaviour.Merge(m, src) +} +func (m *MsgSubmitMisbehaviour) XXX_Size() int { + return m.Size() +} +func (m *MsgSubmitMisbehaviour) XXX_DiscardUnknown() { + xxx_messageInfo_MsgSubmitMisbehaviour.DiscardUnknown(m) +} + +var xxx_messageInfo_MsgSubmitMisbehaviour proto.InternalMessageInfo + +// MsgSubmitMisbehaviourResponse defines the Msg/SubmitMisbehaviour response type. +type MsgSubmitMisbehaviourResponse struct { +} + +func (m *MsgSubmitMisbehaviourResponse) Reset() { *m = MsgSubmitMisbehaviourResponse{} } +func (m *MsgSubmitMisbehaviourResponse) String() string { return proto.CompactTextString(m) } +func (*MsgSubmitMisbehaviourResponse) ProtoMessage() {} +func (*MsgSubmitMisbehaviourResponse) Descriptor() ([]byte, []int) { + return fileDescriptor_cb5dc4651eb49a04, []int{7} +} +func (m *MsgSubmitMisbehaviourResponse) XXX_Unmarshal(b []byte) error { + return m.Unmarshal(b) +} +func (m *MsgSubmitMisbehaviourResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { + if deterministic { + return xxx_messageInfo_MsgSubmitMisbehaviourResponse.Marshal(b, m, deterministic) + } else { + b = b[:cap(b)] + n, err := m.MarshalToSizedBuffer(b) + if err != nil { + return nil, err + } + return b[:n], nil + } +} +func (m *MsgSubmitMisbehaviourResponse) XXX_Merge(src proto.Message) { + xxx_messageInfo_MsgSubmitMisbehaviourResponse.Merge(m, src) +} +func (m *MsgSubmitMisbehaviourResponse) XXX_Size() int { + return m.Size() +} +func (m *MsgSubmitMisbehaviourResponse) XXX_DiscardUnknown() { + xxx_messageInfo_MsgSubmitMisbehaviourResponse.DiscardUnknown(m) +} + +var xxx_messageInfo_MsgSubmitMisbehaviourResponse proto.InternalMessageInfo + +func init() { + proto.RegisterType((*MsgCreateClient)(nil), "ibc.core.client.v1.MsgCreateClient") + proto.RegisterType((*MsgCreateClientResponse)(nil), "ibc.core.client.v1.MsgCreateClientResponse") + proto.RegisterType((*MsgUpdateClient)(nil), "ibc.core.client.v1.MsgUpdateClient") + proto.RegisterType((*MsgUpdateClientResponse)(nil), "ibc.core.client.v1.MsgUpdateClientResponse") + proto.RegisterType((*MsgUpgradeClient)(nil), "ibc.core.client.v1.MsgUpgradeClient") + proto.RegisterType((*MsgUpgradeClientResponse)(nil), "ibc.core.client.v1.MsgUpgradeClientResponse") + proto.RegisterType((*MsgSubmitMisbehaviour)(nil), "ibc.core.client.v1.MsgSubmitMisbehaviour") + proto.RegisterType((*MsgSubmitMisbehaviourResponse)(nil), "ibc.core.client.v1.MsgSubmitMisbehaviourResponse") +} + +func init() { proto.RegisterFile("ibc/core/client/v1/tx.proto", fileDescriptor_cb5dc4651eb49a04) } + +var fileDescriptor_cb5dc4651eb49a04 = []byte{ + // 608 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xcc, 0x55, 0x3f, 0x6f, 0xd3, 0x40, + 0x14, 0x8f, 0x1b, 0x88, 0xda, 0x6b, 0xd2, 0x56, 0x26, 0x6d, 0x13, 0x23, 0xec, 0xca, 0x30, 0x14, + 0xd1, 0xda, 0x24, 0x0c, 0xa0, 0x4a, 0x0c, 0xa4, 0x0b, 0x0c, 0x91, 0xc0, 0x15, 0x03, 0x08, 0x29, + 0xf8, 0xcf, 0xf5, 0x62, 0x91, 0xf8, 0x22, 0xdf, 0x39, 0x6a, 0xbe, 0x01, 0x23, 0x12, 0x7c, 0x80, + 0x8a, 0x81, 0xcf, 0xc2, 0xc0, 0xd0, 0x91, 0x29, 0x42, 0xc9, 0xc2, 0x9c, 0x4f, 0x80, 0x7c, 0x77, + 0xb1, 0xec, 0x34, 0x89, 0x22, 0x58, 0x98, 0xe2, 0x77, 0xef, 0xf7, 0x7e, 0xef, 0xe7, 0xdf, 0x7b, + 0x17, 0x83, 0xdb, 0xbe, 0xe3, 0x9a, 0x2e, 0x0e, 0xa1, 0xe9, 0x76, 0x7c, 0x18, 0x50, 0xb3, 0x5f, + 0x33, 0xe9, 0x85, 0xd1, 0x0b, 0x31, 0xc5, 0xb2, 0xec, 0x3b, 0xae, 0x11, 0x27, 0x0d, 0x9e, 0x34, + 0xfa, 0x35, 0xa5, 0x8c, 0x30, 0xc2, 0x2c, 0x6d, 0xc6, 0x4f, 0x1c, 0xa9, 0x54, 0x11, 0xc6, 0xa8, + 0x03, 0x4d, 0x16, 0x39, 0xd1, 0xb9, 0x69, 0x07, 0x03, 0x91, 0xd2, 0xe6, 0x74, 0x10, 0x74, 0x0c, + 0xa0, 0x7f, 0x5e, 0x03, 0xdb, 0x4d, 0x82, 0x4e, 0x43, 0x68, 0x53, 0x78, 0xca, 0x32, 0x72, 0x0d,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0x8a, 0x71, 0x7d, 0xf7, 0x8d, 0xe7, 0x0c, 0xd1, 0xa8, + 0x4e, 0x86, 0xda, 0x2e, 0x67, 0xce, 0xd6, 0xea, 0x56, 0x49, 0x1c, 0x70, 0xa4, 0xfc, 0x14, 0x94, + 0x7a, 0x21, 0xc6, 0xe7, 0x2d, 0x71, 0xcc, 0xa6, 0x5d, 0x6c, 0x54, 0x26, 0x43, 0xad, 0xcc, 0x09, + 0x32, 0x69, 0xdd, 0x2a, 0xb2, 0x58, 0xf8, 0x94, 0xf2, 0xfc, 0x66, 0xda, 0x73, 0x5d, 0x01, 0x95, + 0x59, 0x37, 0x13, 0xab, 0xbf, 0x49, 0x60, 0xb7, 0x49, 0xd0, 0x59, 0xe4, 0x74, 0x7d, 0xda, 0xf4, + 0x89, 0x03, 0xdb, 0x76, 0xdf, 0xc7, 0x51, 0xf8, 0x37, 0x7e, 0x3f, 0x01, 0xc5, 0x6e, 0x8a, 0x62, + 0xe9, 0xa2, 0x64, 0x90, 0x2b, 0xac, 0x8b, 0x06, 0xee, 0xcc, 0xd5, 0x39, 0x7d, 0x93, 0xfa, 0xd7, + 0x3c, 0xc8, 0x37, 0x09, 0x92, 0xdf, 0x83, 0x62, 0xe6, 0xbf, 0xe1, 0xee, 0xbc, 0xd1, 0xcc, 0xdc, + 0x15, 0xe5, 0xc1, 0x0a, 0xa0, 0x69, 0xa7, 0xb8, 0x43, 0xe6, 0x32, 0x2d, 0xea, 0x90, 0x06, 0x2d, + 0xec, 0x30, 0xef, 0x02, 0xc8, 0x2e, 0x28, 0x65, 0x97, 0xff, 0xde, 0xc2, 0xea, 0x14, 0x4a, 0x39, + 0x5a, 0x05, 0x95, 0x34, 0x09, 0x81, 0x3c, 0x67, 0xec, 0xf7, 0x17, 0x70, 0x5c, 0x87, 0x2a, 0xb5, + 0x95, 0xa1, 0xd3, 0x9e, 0x8d, 0x57, 0xdf, 0x47, 0xaa, 0x74, 0x35, 0x52, 0xa5, 0x5f, 0x23, 0x55, + 0xfa, 0x34, 0x56, 0x73, 0x57, 0x63, 0x35, 0xf7, 0x73, 0xac, 0xe6, 0xde, 0x3e, 0x46, 0x3e, 0x6d, + 0x47, 0x8e, 0xe1, 0xe2, 0xae, 0xe9, 0x62, 0xd2, 0xc5, 0x44, 0xfc, 0x1c, 0x13, 0xef, 0x83, 0x79, + 0x61, 0x26, 0x9f, 0x85, 0x87, 0xf5, 0x63, 0xf1, 0x65, 0xa0, 0x83, 0x1e, 0x24, 0x4e, 0x81, 0xad, + 0xd5, 0xa3, 0x3f, 0x01, 0x00, 0x00, 0xff, 0xff, 0xb1, 0x03, 0x55, 0x1e, 0x9b, 0x06, 0x00, 0x00, +} + +// Reference imports to suppress errors if they are not otherwise used. +var _ context.Context +var _ grpc.ClientConn + +// This is a compile-time assertion to ensure that this generated file +// is compatible with the grpc package it is being compiled against. +const _ = grpc.SupportPackageIsVersion4 + +// MsgClient is the client API for Msg service. +// +// For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream. +type MsgClient interface { + // CreateClient defines a rpc handler method for MsgCreateClient. + CreateClient(ctx context.Context, in *MsgCreateClient, opts ...grpc.CallOption) (*MsgCreateClientResponse, error) + // UpdateClient defines a rpc handler method for MsgUpdateClient. + UpdateClient(ctx context.Context, in *MsgUpdateClient, opts ...grpc.CallOption) (*MsgUpdateClientResponse, error) + // UpgradeClient defines a rpc handler method for MsgUpgradeClient. + UpgradeClient(ctx context.Context, in *MsgUpgradeClient, opts ...grpc.CallOption) (*MsgUpgradeClientResponse, error) + // SubmitMisbehaviour defines a rpc handler method for MsgSubmitMisbehaviour. + SubmitMisbehaviour(ctx context.Context, in *MsgSubmitMisbehaviour, opts ...grpc.CallOption) (*MsgSubmitMisbehaviourResponse, error) +} + +type msgClient struct { + cc grpc1.ClientConn +} + +func NewMsgClient(cc grpc1.ClientConn) MsgClient { + return &msgClient{cc} +} + +func (c *msgClient) CreateClient(ctx context.Context, in *MsgCreateClient, opts ...grpc.CallOption) (*MsgCreateClientResponse, error) { + out := new(MsgCreateClientResponse) + err := c.cc.Invoke(ctx, "/ibc.core.client.v1.Msg/CreateClient", in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + +func (c *msgClient) UpdateClient(ctx context.Context, in *MsgUpdateClient, opts ...grpc.CallOption) (*MsgUpdateClientResponse, error) { + out := new(MsgUpdateClientResponse) + err := c.cc.Invoke(ctx, "/ibc.core.client.v1.Msg/UpdateClient", in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + +func (c *msgClient) UpgradeClient(ctx context.Context, in *MsgUpgradeClient, opts ...grpc.CallOption) (*MsgUpgradeClientResponse, error) { + out := new(MsgUpgradeClientResponse) + err := c.cc.Invoke(ctx, "/ibc.core.client.v1.Msg/UpgradeClient", in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + +func (c *msgClient) SubmitMisbehaviour(ctx context.Context, in *MsgSubmitMisbehaviour, opts ...grpc.CallOption) (*MsgSubmitMisbehaviourResponse, error) { + out := new(MsgSubmitMisbehaviourResponse) + err := c.cc.Invoke(ctx, "/ibc.core.client.v1.Msg/SubmitMisbehaviour", in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + +// MsgServer is the server API for Msg service. +type MsgServer interface { + // CreateClient defines a rpc handler method for MsgCreateClient. + CreateClient(context.Context, *MsgCreateClient) (*MsgCreateClientResponse, error) + // UpdateClient defines a rpc handler method for MsgUpdateClient. + UpdateClient(context.Context, *MsgUpdateClient) (*MsgUpdateClientResponse, error) + // UpgradeClient defines a rpc handler method for MsgUpgradeClient. + UpgradeClient(context.Context, *MsgUpgradeClient) (*MsgUpgradeClientResponse, error) + // SubmitMisbehaviour defines a rpc handler method for MsgSubmitMisbehaviour. + SubmitMisbehaviour(context.Context, *MsgSubmitMisbehaviour) (*MsgSubmitMisbehaviourResponse, error) +} + +// UnimplementedMsgServer can be embedded to have forward compatible implementations. +type UnimplementedMsgServer struct { +} + +func (*UnimplementedMsgServer) CreateClient(ctx context.Context, req *MsgCreateClient) (*MsgCreateClientResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method CreateClient not implemented") +} +func (*UnimplementedMsgServer) UpdateClient(ctx context.Context, req *MsgUpdateClient) (*MsgUpdateClientResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method UpdateClient not implemented") +} +func (*UnimplementedMsgServer) UpgradeClient(ctx context.Context, req *MsgUpgradeClient) (*MsgUpgradeClientResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method UpgradeClient not implemented") +} +func (*UnimplementedMsgServer) SubmitMisbehaviour(ctx context.Context, req *MsgSubmitMisbehaviour) (*MsgSubmitMisbehaviourResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method SubmitMisbehaviour not implemented") +} + +func RegisterMsgServer(s grpc1.Server, srv MsgServer) { + s.RegisterService(&_Msg_serviceDesc, srv) +} + +func _Msg_CreateClient_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(MsgCreateClient) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(MsgServer).CreateClient(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: "/ibc.core.client.v1.Msg/CreateClient", + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(MsgServer).CreateClient(ctx, req.(*MsgCreateClient)) + } + return interceptor(ctx, in, info, handler) +} + +func _Msg_UpdateClient_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(MsgUpdateClient) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(MsgServer).UpdateClient(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: "/ibc.core.client.v1.Msg/UpdateClient", + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(MsgServer).UpdateClient(ctx, req.(*MsgUpdateClient)) + } + return interceptor(ctx, in, info, handler) +} + +func _Msg_UpgradeClient_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(MsgUpgradeClient) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(MsgServer).UpgradeClient(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: "/ibc.core.client.v1.Msg/UpgradeClient", + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(MsgServer).UpgradeClient(ctx, req.(*MsgUpgradeClient)) + } + return interceptor(ctx, in, info, handler) +} + +func _Msg_SubmitMisbehaviour_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(MsgSubmitMisbehaviour) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(MsgServer).SubmitMisbehaviour(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: "/ibc.core.client.v1.Msg/SubmitMisbehaviour", + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(MsgServer).SubmitMisbehaviour(ctx, req.(*MsgSubmitMisbehaviour)) + } + return interceptor(ctx, in, info, handler) +} + +var _Msg_serviceDesc = grpc.ServiceDesc{ + ServiceName: "ibc.core.client.v1.Msg", + HandlerType: (*MsgServer)(nil), + Methods: []grpc.MethodDesc{ + { + MethodName: "CreateClient", + Handler: _Msg_CreateClient_Handler, + }, + { + MethodName: "UpdateClient", + Handler: _Msg_UpdateClient_Handler, + }, + { + MethodName: "UpgradeClient", + Handler: _Msg_UpgradeClient_Handler, + }, + { + MethodName: "SubmitMisbehaviour", + Handler: _Msg_SubmitMisbehaviour_Handler, + }, + }, + Streams: []grpc.StreamDesc{}, + Metadata: "ibc/core/client/v1/tx.proto", +} + +func (m *MsgCreateClient) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalToSizedBuffer(dAtA[:size]) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *MsgCreateClient) MarshalTo(dAtA []byte) (int, error) { + size := m.Size() + return m.MarshalToSizedBuffer(dAtA[:size]) +} + +func (m *MsgCreateClient) MarshalToSizedBuffer(dAtA []byte) (int, error) { + i := len(dAtA) + _ = i + var l int + _ = l + if len(m.Signer) > 0 { + i -= len(m.Signer) + copy(dAtA[i:], m.Signer) + i = encodeVarintTx(dAtA, i, uint64(len(m.Signer))) + i-- + dAtA[i] = 0x22 + } + if m.ConsensusState != nil { + { + size, err := m.ConsensusState.MarshalToSizedBuffer(dAtA[:i]) + if err != nil { + return 0, err + } + i -= size + i = encodeVarintTx(dAtA, i, uint64(size)) + } + i-- + dAtA[i] = 0x1a + } + if m.ClientState != nil { + { + size, err := m.ClientState.MarshalToSizedBuffer(dAtA[:i]) + if err != nil { + return 0, err + } + i -= size + i = encodeVarintTx(dAtA, i, uint64(size)) + } + i-- + dAtA[i] = 0x12 + } + if len(m.ClientId) > 0 { + i -= len(m.ClientId) + copy(dAtA[i:], m.ClientId) + i = encodeVarintTx(dAtA, i, uint64(len(m.ClientId))) + i-- + dAtA[i] = 0xa + } + return len(dAtA) - i, nil +} + +func (m *MsgCreateClientResponse) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalToSizedBuffer(dAtA[:size]) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *MsgCreateClientResponse) MarshalTo(dAtA []byte) (int, error) { + size := m.Size() + return m.MarshalToSizedBuffer(dAtA[:size]) +} + +func (m *MsgCreateClientResponse) MarshalToSizedBuffer(dAtA []byte) (int, error) { + i := len(dAtA) + _ = i + var l int + _ = l + return len(dAtA) - i, nil +} + +func (m *MsgUpdateClient) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalToSizedBuffer(dAtA[:size]) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *MsgUpdateClient) MarshalTo(dAtA []byte) (int, error) { + size := m.Size() + return m.MarshalToSizedBuffer(dAtA[:size]) +} + +func (m *MsgUpdateClient) MarshalToSizedBuffer(dAtA []byte) (int, error) { + i := len(dAtA) + _ = i + var l int + _ = l + if len(m.Signer) > 0 { + i -= len(m.Signer) + copy(dAtA[i:], m.Signer) + i = encodeVarintTx(dAtA, i, uint64(len(m.Signer))) + i-- + dAtA[i] = 0x1a + } + if m.Header != nil { + { + size, err := m.Header.MarshalToSizedBuffer(dAtA[:i]) + if err != nil { + return 0, err + } + i -= size + i = encodeVarintTx(dAtA, i, uint64(size)) + } + i-- + dAtA[i] = 0x12 + } + if len(m.ClientId) > 0 { + i -= len(m.ClientId) + copy(dAtA[i:], m.ClientId) + i = encodeVarintTx(dAtA, i, uint64(len(m.ClientId))) + i-- + dAtA[i] = 0xa + } + return len(dAtA) - i, nil +} + +func (m *MsgUpdateClientResponse) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalToSizedBuffer(dAtA[:size]) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *MsgUpdateClientResponse) MarshalTo(dAtA []byte) (int, error) { + size := m.Size() + return m.MarshalToSizedBuffer(dAtA[:size]) +} + +func (m *MsgUpdateClientResponse) MarshalToSizedBuffer(dAtA []byte) (int, error) { + i := len(dAtA) + _ = i + var l int + _ = l + return len(dAtA) - i, nil +} + +func (m *MsgUpgradeClient) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalToSizedBuffer(dAtA[:size]) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *MsgUpgradeClient) MarshalTo(dAtA []byte) (int, error) { + size := m.Size() + return m.MarshalToSizedBuffer(dAtA[:size]) +} + +func (m *MsgUpgradeClient) MarshalToSizedBuffer(dAtA []byte) (int, error) { + i := len(dAtA) + _ = i + var l int + _ = l + if len(m.Signer) > 0 { + i -= len(m.Signer) + copy(dAtA[i:], m.Signer) + i = encodeVarintTx(dAtA, i, uint64(len(m.Signer))) + i-- + dAtA[i] = 0x2a + } + if len(m.ProofUpgrade) > 0 { + i -= len(m.ProofUpgrade) + copy(dAtA[i:], m.ProofUpgrade) + i = encodeVarintTx(dAtA, i, uint64(len(m.ProofUpgrade))) + i-- + dAtA[i] = 0x22 + } + if m.UpgradeHeight != nil { + { + size, err := m.UpgradeHeight.MarshalToSizedBuffer(dAtA[:i]) + if err != nil { + return 0, err + } + i -= size + i = encodeVarintTx(dAtA, i, uint64(size)) + } + i-- + dAtA[i] = 0x1a + } + if m.ClientState != nil { + { + size, err := m.ClientState.MarshalToSizedBuffer(dAtA[:i]) + if err != nil { + return 0, err + } + i -= size + i = encodeVarintTx(dAtA, i, uint64(size)) + } + i-- + dAtA[i] = 0x12 + } + if len(m.ClientId) > 0 { + i -= len(m.ClientId) + copy(dAtA[i:], m.ClientId) + i = encodeVarintTx(dAtA, i, uint64(len(m.ClientId))) + i-- + dAtA[i] = 0xa + } + return len(dAtA) - i, nil +} + +func (m *MsgUpgradeClientResponse) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalToSizedBuffer(dAtA[:size]) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *MsgUpgradeClientResponse) MarshalTo(dAtA []byte) (int, error) { + size := m.Size() + return m.MarshalToSizedBuffer(dAtA[:size]) +} + +func (m *MsgUpgradeClientResponse) MarshalToSizedBuffer(dAtA []byte) (int, error) { + i := len(dAtA) + _ = i + var l int + _ = l + return len(dAtA) - i, nil +} + +func (m *MsgSubmitMisbehaviour) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalToSizedBuffer(dAtA[:size]) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *MsgSubmitMisbehaviour) MarshalTo(dAtA []byte) (int, error) { + size := m.Size() + return m.MarshalToSizedBuffer(dAtA[:size]) +} + +func (m *MsgSubmitMisbehaviour) MarshalToSizedBuffer(dAtA []byte) (int, error) { + i := len(dAtA) + _ = i + var l int + _ = l + if len(m.Signer) > 0 { + i -= len(m.Signer) + copy(dAtA[i:], m.Signer) + i = encodeVarintTx(dAtA, i, uint64(len(m.Signer))) + i-- + dAtA[i] = 0x1a + } + if m.Misbehaviour != nil { + { + size, err := m.Misbehaviour.MarshalToSizedBuffer(dAtA[:i]) + if err != nil { + return 0, err + } + i -= size + i = encodeVarintTx(dAtA, i, uint64(size)) + } + i-- + dAtA[i] = 0x12 + } + if len(m.ClientId) > 0 { + i -= len(m.ClientId) + copy(dAtA[i:], m.ClientId) + i = encodeVarintTx(dAtA, i, uint64(len(m.ClientId))) + i-- + dAtA[i] = 0xa + } + return len(dAtA) - i, nil +} + +func (m *MsgSubmitMisbehaviourResponse) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalToSizedBuffer(dAtA[:size]) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *MsgSubmitMisbehaviourResponse) MarshalTo(dAtA []byte) (int, error) { + size := m.Size() + return m.MarshalToSizedBuffer(dAtA[:size]) +} + +func (m *MsgSubmitMisbehaviourResponse) MarshalToSizedBuffer(dAtA []byte) (int, error) { + i := len(dAtA) + _ = i + var l int + _ = l + return len(dAtA) - i, nil +} + +func encodeVarintTx(dAtA []byte, offset int, v uint64) int { + offset -= sovTx(v) + base := offset + for v >= 1<<7 { + dAtA[offset] = uint8(v&0x7f | 0x80) + v >>= 7 + offset++ + } + dAtA[offset] = uint8(v) + return base +} +func (m *MsgCreateClient) Size() (n int) { + if m == nil { + return 0 + } + var l int + _ = l + l = len(m.ClientId) + if l > 0 { + n += 1 + l + sovTx(uint64(l)) + } + if m.ClientState != nil { + l = m.ClientState.Size() + n += 1 + l + sovTx(uint64(l)) + } + if m.ConsensusState != nil { + l = m.ConsensusState.Size() + n += 1 + l + sovTx(uint64(l)) + } + l = len(m.Signer) + if l > 0 { + n += 1 + l + sovTx(uint64(l)) + } + return n +} + +func (m *MsgCreateClientResponse) Size() (n int) { + if m == nil { + return 0 + } + var l int + _ = l + return n +} + +func (m *MsgUpdateClient) Size() (n int) { + if m == nil { + return 0 + } + var l int + _ = l + l = len(m.ClientId) + if l > 0 { + n += 1 + l + sovTx(uint64(l)) + } + if m.Header != nil { + l = m.Header.Size() + n += 1 + l + sovTx(uint64(l)) + } + l = len(m.Signer) + if l > 0 { + n += 1 + l + sovTx(uint64(l)) + } + return n +} + +func (m *MsgUpdateClientResponse) Size() (n int) { + if m == nil { + return 0 + } + var l int + _ = l + return n +} + +func (m *MsgUpgradeClient) Size() (n int) { + if m == nil { + return 0 + } + var l int + _ = l + l = len(m.ClientId) + if l > 0 { + n += 1 + l + sovTx(uint64(l)) + } + if m.ClientState != nil { + l = m.ClientState.Size() + n += 1 + l + sovTx(uint64(l)) + } + if m.UpgradeHeight != nil { + l = m.UpgradeHeight.Size() + n += 1 + l + sovTx(uint64(l)) + } + l = len(m.ProofUpgrade) + if l > 0 { + n += 1 + l + sovTx(uint64(l)) + } + l = len(m.Signer) + if l > 0 { + n += 1 + l + sovTx(uint64(l)) + } + return n +} + +func (m *MsgUpgradeClientResponse) Size() (n int) { + if m == nil { + return 0 + } + var l int + _ = l + return n +} + +func (m *MsgSubmitMisbehaviour) Size() (n int) { + if m == nil { + return 0 + } + var l int + _ = l + l = len(m.ClientId) + if l > 0 { + n += 1 + l + sovTx(uint64(l)) + } + if m.Misbehaviour != nil { + l = m.Misbehaviour.Size() + n += 1 + l + sovTx(uint64(l)) + } + l = len(m.Signer) + if l > 0 { + n += 1 + l + sovTx(uint64(l)) + } + return n +} + +func (m *MsgSubmitMisbehaviourResponse) Size() (n int) { + if m == nil { + return 0 + } + var l int + _ = l + return n +} + +func sovTx(x uint64) (n int) { + return (math_bits.Len64(x|1) + 6) / 7 +} +func sozTx(x uint64) (n int) { + return sovTx(uint64((x << 1) ^ uint64((int64(x) >> 63)))) +} +func (m *MsgCreateClient) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowTx + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: MsgCreateClient: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: MsgCreateClient: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field ClientId", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowTx + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthTx + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return ErrInvalidLengthTx + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.ClientId = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field ClientState", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowTx + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthTx + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return ErrInvalidLengthTx + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + if m.ClientState == nil { + m.ClientState = &types.Any{} + } + if err := m.ClientState.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 3: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field ConsensusState", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowTx + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthTx + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return ErrInvalidLengthTx + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + if m.ConsensusState == nil { + m.ConsensusState = &types.Any{} + } + if err := m.ConsensusState.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 4: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Signer", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowTx + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthTx + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return ErrInvalidLengthTx + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Signer = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipTx(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthTx + } + if (iNdEx + skippy) < 0 { + return ErrInvalidLengthTx + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *MsgCreateClientResponse) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowTx + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: MsgCreateClientResponse: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: MsgCreateClientResponse: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + default: + iNdEx = preIndex + skippy, err := skipTx(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthTx + } + if (iNdEx + skippy) < 0 { + return ErrInvalidLengthTx + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *MsgUpdateClient) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowTx + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: MsgUpdateClient: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: MsgUpdateClient: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field ClientId", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowTx + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthTx + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return ErrInvalidLengthTx + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.ClientId = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Header", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowTx + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthTx + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return ErrInvalidLengthTx + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + if m.Header == nil { + m.Header = &types.Any{} + } + if err := m.Header.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 3: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Signer", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowTx + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthTx + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return ErrInvalidLengthTx + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Signer = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipTx(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthTx + } + if (iNdEx + skippy) < 0 { + return ErrInvalidLengthTx + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *MsgUpdateClientResponse) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowTx + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: MsgUpdateClientResponse: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: MsgUpdateClientResponse: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + default: + iNdEx = preIndex + skippy, err := skipTx(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthTx + } + if (iNdEx + skippy) < 0 { + return ErrInvalidLengthTx + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *MsgUpgradeClient) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowTx + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: MsgUpgradeClient: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: MsgUpgradeClient: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field ClientId", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowTx + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthTx + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return ErrInvalidLengthTx + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.ClientId = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field ClientState", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowTx + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthTx + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return ErrInvalidLengthTx + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + if m.ClientState == nil { + m.ClientState = &types.Any{} + } + if err := m.ClientState.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 3: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field UpgradeHeight", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowTx + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthTx + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return ErrInvalidLengthTx + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + if m.UpgradeHeight == nil { + m.UpgradeHeight = &Height{} + } + if err := m.UpgradeHeight.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 4: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field ProofUpgrade", wireType) + } + var byteLen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowTx + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + byteLen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if byteLen < 0 { + return ErrInvalidLengthTx + } + postIndex := iNdEx + byteLen + if postIndex < 0 { + return ErrInvalidLengthTx + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.ProofUpgrade = append(m.ProofUpgrade[:0], dAtA[iNdEx:postIndex]...) + if m.ProofUpgrade == nil { + m.ProofUpgrade = []byte{} + } + iNdEx = postIndex + case 5: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Signer", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowTx + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthTx + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return ErrInvalidLengthTx + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Signer = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipTx(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthTx + } + if (iNdEx + skippy) < 0 { + return ErrInvalidLengthTx + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *MsgUpgradeClientResponse) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowTx + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: MsgUpgradeClientResponse: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: MsgUpgradeClientResponse: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + default: + iNdEx = preIndex + skippy, err := skipTx(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthTx + } + if (iNdEx + skippy) < 0 { + return ErrInvalidLengthTx + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *MsgSubmitMisbehaviour) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowTx + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: MsgSubmitMisbehaviour: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: MsgSubmitMisbehaviour: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field ClientId", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowTx + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthTx + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return ErrInvalidLengthTx + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.ClientId = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Misbehaviour", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowTx + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthTx + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return ErrInvalidLengthTx + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + if m.Misbehaviour == nil { + m.Misbehaviour = &types.Any{} + } + if err := m.Misbehaviour.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 3: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Signer", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowTx + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthTx + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return ErrInvalidLengthTx + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Signer = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipTx(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthTx + } + if (iNdEx + skippy) < 0 { + return ErrInvalidLengthTx + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *MsgSubmitMisbehaviourResponse) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowTx + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: MsgSubmitMisbehaviourResponse: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: MsgSubmitMisbehaviourResponse: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + default: + iNdEx = preIndex + skippy, err := skipTx(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthTx + } + if (iNdEx + skippy) < 0 { + return ErrInvalidLengthTx + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func skipTx(dAtA []byte) (n int, err error) { + l := len(dAtA) + iNdEx := 0 + depth := 0 + for iNdEx < l { + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return 0, ErrIntOverflowTx + } + if iNdEx >= l { + return 0, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + wireType := int(wire & 0x7) + switch wireType { + case 0: + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return 0, ErrIntOverflowTx + } + if iNdEx >= l { + return 0, io.ErrUnexpectedEOF + } + iNdEx++ + if dAtA[iNdEx-1] < 0x80 { + break + } + } + case 1: + iNdEx += 8 + case 2: + var length int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return 0, ErrIntOverflowTx + } + if iNdEx >= l { + return 0, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + length |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if length < 0 { + return 0, ErrInvalidLengthTx + } + iNdEx += length + case 3: + depth++ + case 4: + if depth == 0 { + return 0, ErrUnexpectedEndOfGroupTx + } + depth-- + case 5: + iNdEx += 4 + default: + return 0, fmt.Errorf("proto: illegal wireType %d", wireType) + } + if iNdEx < 0 { + return 0, ErrInvalidLengthTx + } + if depth == 0 { + return iNdEx, nil + } + } + return 0, io.ErrUnexpectedEOF +} + +var ( + ErrInvalidLengthTx = fmt.Errorf("proto: negative length found during unmarshaling") + ErrIntOverflowTx = fmt.Errorf("proto: integer overflow") + ErrUnexpectedEndOfGroupTx = fmt.Errorf("proto: unexpected end of group") +) diff --git a/x/ibc/core/03-connection/keeper/grpc_query_test.go b/x/ibc/core/03-connection/keeper/grpc_query_test.go index 5a8122e27..7e27b5af1 100644 --- a/x/ibc/core/03-connection/keeper/grpc_query_test.go +++ b/x/ibc/core/03-connection/keeper/grpc_query_test.go @@ -47,7 +47,7 @@ func (suite *KeeperTestSuite) TestQueryConnection() { { "success", func() { - clientA, clientB := suite.coordinator.SetupClients(suite.chainA, suite.chainB, ibctesting.Tendermint) + clientA, clientB := suite.coordinator.SetupClients(suite.chainA, suite.chainB, exported.Tendermint) connA := suite.chainA.GetFirstTestConnection(clientA, clientB) connB := suite.chainB.GetFirstTestConnection(clientB, clientA) @@ -111,11 +111,11 @@ func (suite *KeeperTestSuite) TestQueryConnections() { { "success", func() { - clientA, clientB, connA0, connB0 := suite.coordinator.SetupClientConnections(suite.chainA, suite.chainB, ibctesting.Tendermint) + clientA, clientB, connA0, connB0 := suite.coordinator.SetupClientConnections(suite.chainA, suite.chainB, exported.Tendermint) connA1, connB1, err := suite.coordinator.ConnOpenInit(suite.chainA, suite.chainB, clientA, clientB) suite.Require().NoError(err) - clientA1, clientB1, connA2, connB2 := suite.coordinator.SetupClientConnections(suite.chainA, suite.chainB, ibctesting.Tendermint) + clientA1, clientB1, connA2, connB2 := suite.coordinator.SetupClientConnections(suite.chainA, suite.chainB, exported.Tendermint) counterparty1 := types.NewCounterparty(clientB, connB0.ID, suite.chainB.GetPrefix()) counterparty2 := types.NewCounterparty(clientB, connB1.ID, suite.chainB.GetPrefix()) @@ -197,7 +197,7 @@ func (suite *KeeperTestSuite) TestQueryClientConnections() { { "success", func() { - clientA, clientB, connA0, _ := suite.coordinator.SetupClientConnections(suite.chainA, suite.chainB, ibctesting.Tendermint) + clientA, clientB, connA0, _ := suite.coordinator.SetupClientConnections(suite.chainA, suite.chainB, exported.Tendermint) connA1, _ := suite.coordinator.CreateConnection(suite.chainA, suite.chainB, clientA, clientB) expPaths = []string{connA0.ID, connA1.ID} suite.chainA.App.IBCKeeper.ConnectionKeeper.SetClientConnectionPaths(suite.chainA.GetContext(), clientA, expPaths) @@ -282,7 +282,7 @@ func (suite *KeeperTestSuite) TestQueryConnectionClientState() { { "success", func() { - clientA, _, connA, _ := suite.coordinator.SetupClientConnections(suite.chainA, suite.chainB, ibctesting.Tendermint) + clientA, _, connA, _ := suite.coordinator.SetupClientConnections(suite.chainA, suite.chainB, exported.Tendermint) expClientState := suite.chainA.GetClientState(clientA) expIdentifiedClientState = clienttypes.NewIdentifiedClientState(clientA, expClientState) @@ -371,7 +371,7 @@ func (suite *KeeperTestSuite) TestQueryConnectionConsensusState() { { "success", func() { - clientA, _, connA, _ := suite.coordinator.SetupClientConnections(suite.chainA, suite.chainB, ibctesting.Tendermint) + clientA, _, connA, _ := suite.coordinator.SetupClientConnections(suite.chainA, suite.chainB, exported.Tendermint) clientState := suite.chainA.GetClientState(clientA) expConsensusState, _ = suite.chainA.GetConsensusState(clientA, clientState.GetLatestHeight()) diff --git a/x/ibc/core/03-connection/keeper/handshake_test.go b/x/ibc/core/03-connection/keeper/handshake_test.go index 903781086..74ccbf7cb 100644 --- a/x/ibc/core/03-connection/keeper/handshake_test.go +++ b/x/ibc/core/03-connection/keeper/handshake_test.go @@ -27,26 +27,26 @@ func (suite *KeeperTestSuite) TestConnOpenInit() { expPass bool }{ {"success", func() { - clientA, clientB = suite.coordinator.SetupClients(suite.chainA, suite.chainB, ibctesting.Tendermint) + clientA, clientB = suite.coordinator.SetupClients(suite.chainA, suite.chainB, exported.Tendermint) }, true}, {"success with empty counterparty identifier", func() { - clientA, clientB = suite.coordinator.SetupClients(suite.chainA, suite.chainB, ibctesting.Tendermint) + clientA, clientB = suite.coordinator.SetupClients(suite.chainA, suite.chainB, exported.Tendermint) emptyConnBID = true }, true}, {"success with non empty version", func() { - clientA, clientB = suite.coordinator.SetupClients(suite.chainA, suite.chainB, ibctesting.Tendermint) + clientA, clientB = suite.coordinator.SetupClients(suite.chainA, suite.chainB, exported.Tendermint) version = types.ExportedVersionsToProto(types.GetCompatibleVersions())[0] }, true}, {"connection already exists", func() { - clientA, clientB, _, _ = suite.coordinator.SetupClientConnections(suite.chainA, suite.chainB, ibctesting.Tendermint) + clientA, clientB, _, _ = suite.coordinator.SetupClientConnections(suite.chainA, suite.chainB, exported.Tendermint) }, false}, {"invalid version", func() { - clientA, clientB = suite.coordinator.SetupClients(suite.chainA, suite.chainB, ibctesting.Tendermint) + clientA, clientB = suite.coordinator.SetupClients(suite.chainA, suite.chainB, exported.Tendermint) version = &types.Version{} }, false}, {"couldn't add connection to client", func() { // swap client identifiers to result in client that does not exist - clientB, clientA = suite.coordinator.SetupClients(suite.chainA, suite.chainB, ibctesting.Tendermint) + clientB, clientA = suite.coordinator.SetupClients(suite.chainA, suite.chainB, exported.Tendermint) }, false}, } @@ -94,7 +94,7 @@ func (suite *KeeperTestSuite) TestConnOpenTry() { expPass bool }{ {"success", func() { - clientA, clientB = suite.coordinator.SetupClients(suite.chainA, suite.chainB, ibctesting.Tendermint) + clientA, clientB = suite.coordinator.SetupClients(suite.chainA, suite.chainB, exported.Tendermint) _, _, err := suite.coordinator.ConnOpenInit(suite.chainA, suite.chainB, clientA, clientB) suite.Require().NoError(err) @@ -102,7 +102,7 @@ func (suite *KeeperTestSuite) TestConnOpenTry() { counterpartyClient = suite.chainA.GetClientState(clientA) }, true}, {"success with empty counterpartyChosenConnectionID", func() { - clientA, clientB = suite.coordinator.SetupClients(suite.chainA, suite.chainB, ibctesting.Tendermint) + clientA, clientB = suite.coordinator.SetupClients(suite.chainA, suite.chainB, exported.Tendermint) connA, _, err := suite.coordinator.ConnOpenInit(suite.chainA, suite.chainB, clientA, clientB) suite.Require().NoError(err) @@ -114,17 +114,17 @@ func (suite *KeeperTestSuite) TestConnOpenTry() { suite.chainA.App.IBCKeeper.ConnectionKeeper.SetConnection(suite.chainA.GetContext(), connA.ID, connection) - err = suite.coordinator.UpdateClient(suite.chainA, suite.chainB, clientA, ibctesting.Tendermint) + err = suite.coordinator.UpdateClient(suite.chainA, suite.chainB, clientA, exported.Tendermint) suite.Require().NoError(err) - err = suite.coordinator.UpdateClient(suite.chainB, suite.chainA, clientB, ibctesting.Tendermint) + err = suite.coordinator.UpdateClient(suite.chainB, suite.chainA, clientB, exported.Tendermint) suite.Require().NoError(err) // retrieve client state of chainA to pass as counterpartyClient counterpartyClient = suite.chainA.GetClientState(clientA) }, true}, {"counterpartyChosenConnectionID does not match desiredConnectionID", func() { - clientA, clientB = suite.coordinator.SetupClients(suite.chainA, suite.chainB, ibctesting.Tendermint) + clientA, clientB = suite.coordinator.SetupClients(suite.chainA, suite.chainB, exported.Tendermint) connA, _, err := suite.coordinator.ConnOpenInit(suite.chainA, suite.chainB, clientA, clientB) suite.Require().NoError(err) @@ -136,17 +136,17 @@ func (suite *KeeperTestSuite) TestConnOpenTry() { suite.chainA.App.IBCKeeper.ConnectionKeeper.SetConnection(suite.chainA.GetContext(), connA.ID, connection) - err = suite.coordinator.UpdateClient(suite.chainA, suite.chainB, clientA, ibctesting.Tendermint) + err = suite.coordinator.UpdateClient(suite.chainA, suite.chainB, clientA, exported.Tendermint) suite.Require().NoError(err) - err = suite.coordinator.UpdateClient(suite.chainB, suite.chainA, clientB, ibctesting.Tendermint) + err = suite.coordinator.UpdateClient(suite.chainB, suite.chainA, clientB, exported.Tendermint) suite.Require().NoError(err) // retrieve client state of chainA to pass as counterpartyClient counterpartyClient = suite.chainA.GetClientState(clientA) }, false}, {"invalid counterparty client", func() { - clientA, clientB = suite.coordinator.SetupClients(suite.chainA, suite.chainB, ibctesting.Tendermint) + clientA, clientB = suite.coordinator.SetupClients(suite.chainA, suite.chainB, exported.Tendermint) _, _, err := suite.coordinator.ConnOpenInit(suite.chainA, suite.chainB, clientA, clientB) suite.Require().NoError(err) @@ -161,7 +161,7 @@ func (suite *KeeperTestSuite) TestConnOpenTry() { suite.chainA.App.IBCKeeper.ClientKeeper.SetClientState(suite.chainA.GetContext(), clientA, tmClient) }, false}, {"consensus height >= latest height", func() { - clientA, clientB = suite.coordinator.SetupClients(suite.chainA, suite.chainB, ibctesting.Tendermint) + clientA, clientB = suite.coordinator.SetupClients(suite.chainA, suite.chainB, exported.Tendermint) _, _, err := suite.coordinator.ConnOpenInit(suite.chainA, suite.chainB, clientA, clientB) suite.Require().NoError(err) @@ -171,7 +171,7 @@ func (suite *KeeperTestSuite) TestConnOpenTry() { consensusHeight = clienttypes.GetSelfHeight(suite.chainB.GetContext()) }, false}, {"self consensus state not found", func() { - clientA, clientB = suite.coordinator.SetupClients(suite.chainA, suite.chainB, ibctesting.Tendermint) + clientA, clientB = suite.coordinator.SetupClients(suite.chainA, suite.chainB, exported.Tendermint) _, _, err := suite.coordinator.ConnOpenInit(suite.chainA, suite.chainB, clientA, clientB) suite.Require().NoError(err) @@ -181,7 +181,7 @@ func (suite *KeeperTestSuite) TestConnOpenTry() { consensusHeight = clienttypes.NewHeight(0, 1) }, false}, {"counterparty versions is empty", func() { - clientA, clientB = suite.coordinator.SetupClients(suite.chainA, suite.chainB, ibctesting.Tendermint) + clientA, clientB = suite.coordinator.SetupClients(suite.chainA, suite.chainB, exported.Tendermint) _, _, err := suite.coordinator.ConnOpenInit(suite.chainA, suite.chainB, clientA, clientB) suite.Require().NoError(err) @@ -191,7 +191,7 @@ func (suite *KeeperTestSuite) TestConnOpenTry() { versions = nil }, false}, {"counterparty versions don't have a match", func() { - clientA, clientB = suite.coordinator.SetupClients(suite.chainA, suite.chainB, ibctesting.Tendermint) + clientA, clientB = suite.coordinator.SetupClients(suite.chainA, suite.chainB, exported.Tendermint) _, _, err := suite.coordinator.ConnOpenInit(suite.chainA, suite.chainB, clientA, clientB) suite.Require().NoError(err) @@ -202,14 +202,14 @@ func (suite *KeeperTestSuite) TestConnOpenTry() { versions = []exported.Version{version} }, false}, {"connection state verification failed", func() { - clientA, clientB = suite.coordinator.SetupClients(suite.chainA, suite.chainB, ibctesting.Tendermint) + clientA, clientB = suite.coordinator.SetupClients(suite.chainA, suite.chainB, exported.Tendermint) // chainA connection not created // retrieve client state of chainA to pass as counterpartyClient counterpartyClient = suite.chainA.GetClientState(clientA) }, false}, {"client state verification failed", func() { - clientA, clientB = suite.coordinator.SetupClients(suite.chainA, suite.chainB, ibctesting.Tendermint) + clientA, clientB = suite.coordinator.SetupClients(suite.chainA, suite.chainB, exported.Tendermint) _, _, err := suite.coordinator.ConnOpenInit(suite.chainA, suite.chainB, clientA, clientB) suite.Require().NoError(err) @@ -222,7 +222,7 @@ func (suite *KeeperTestSuite) TestConnOpenTry() { tmClient.LatestHeight = tmClient.LatestHeight.Increment() }, false}, {"consensus state verification failed", func() { - clientA, clientB = suite.coordinator.SetupClients(suite.chainA, suite.chainB, ibctesting.Tendermint) + clientA, clientB = suite.coordinator.SetupClients(suite.chainA, suite.chainB, exported.Tendermint) // retrieve client state of chainA to pass as counterpartyClient counterpartyClient = suite.chainA.GetClientState(clientA) @@ -241,7 +241,7 @@ func (suite *KeeperTestSuite) TestConnOpenTry() { suite.Require().NoError(err) }, false}, {"invalid previous connection is in TRYOPEN", func() { - clientA, clientB = suite.coordinator.SetupClients(suite.chainA, suite.chainB, ibctesting.Tendermint) + clientA, clientB = suite.coordinator.SetupClients(suite.chainA, suite.chainB, exported.Tendermint) // open init chainA connA, connB, err := suite.coordinator.ConnOpenInit(suite.chainA, suite.chainB, clientA, clientB) @@ -251,14 +251,14 @@ func (suite *KeeperTestSuite) TestConnOpenTry() { err = suite.coordinator.ConnOpenTry(suite.chainB, suite.chainA, connB, connA) suite.Require().NoError(err) - err = suite.coordinator.UpdateClient(suite.chainB, suite.chainA, clientB, ibctesting.Tendermint) + err = suite.coordinator.UpdateClient(suite.chainB, suite.chainA, clientB, exported.Tendermint) suite.Require().NoError(err) // retrieve client state of chainA to pass as counterpartyClient counterpartyClient = suite.chainA.GetClientState(clientA) }, false}, {"invalid previous connection has invalid versions", func() { - clientA, clientB = suite.coordinator.SetupClients(suite.chainA, suite.chainB, ibctesting.Tendermint) + clientA, clientB = suite.coordinator.SetupClients(suite.chainA, suite.chainB, exported.Tendermint) // open init chainA connA, connB, err := suite.coordinator.ConnOpenInit(suite.chainA, suite.chainB, clientA, clientB) @@ -277,7 +277,7 @@ func (suite *KeeperTestSuite) TestConnOpenTry() { suite.chainB.App.IBCKeeper.ConnectionKeeper.SetConnection(suite.chainB.GetContext(), connB.ID, connection) - err = suite.coordinator.UpdateClient(suite.chainB, suite.chainA, clientB, ibctesting.Tendermint) + err = suite.coordinator.UpdateClient(suite.chainB, suite.chainA, clientB, exported.Tendermint) suite.Require().NoError(err) // retrieve client state of chainA to pass as counterpartyClient @@ -353,7 +353,7 @@ func (suite *KeeperTestSuite) TestConnOpenAck() { expPass bool }{ {"success", func() { - clientA, clientB = suite.coordinator.SetupClients(suite.chainA, suite.chainB, ibctesting.Tendermint) + clientA, clientB = suite.coordinator.SetupClients(suite.chainA, suite.chainB, exported.Tendermint) connA, connB, err := suite.coordinator.ConnOpenInit(suite.chainA, suite.chainB, clientA, clientB) suite.Require().NoError(err) @@ -364,7 +364,7 @@ func (suite *KeeperTestSuite) TestConnOpenAck() { counterpartyClient = suite.chainB.GetClientState(clientB) }, true}, {"success with empty stored counterparty connection ID", func() { - clientA, clientB = suite.coordinator.SetupClients(suite.chainA, suite.chainB, ibctesting.Tendermint) + clientA, clientB = suite.coordinator.SetupClients(suite.chainA, suite.chainB, exported.Tendermint) connA, connB, err := suite.coordinator.ConnOpenInit(suite.chainA, suite.chainB, clientA, clientB) suite.Require().NoError(err) @@ -381,10 +381,10 @@ func (suite *KeeperTestSuite) TestConnOpenAck() { suite.chainA.App.IBCKeeper.ConnectionKeeper.SetConnection(suite.chainA.GetContext(), connA.ID, connection) - err = suite.coordinator.UpdateClient(suite.chainB, suite.chainA, clientB, ibctesting.Tendermint) + err = suite.coordinator.UpdateClient(suite.chainB, suite.chainA, clientB, exported.Tendermint) suite.Require().NoError(err) - err = suite.coordinator.UpdateClient(suite.chainA, suite.chainB, clientA, ibctesting.Tendermint) + err = suite.coordinator.UpdateClient(suite.chainA, suite.chainB, clientA, exported.Tendermint) suite.Require().NoError(err) // retrieve client state of chainB to pass as counterpartyClient @@ -392,7 +392,7 @@ func (suite *KeeperTestSuite) TestConnOpenAck() { }, true}, {"success from tryopen", func() { // chainA is in TRYOPEN, chainB is in TRYOPEN - clientA, clientB = suite.coordinator.SetupClients(suite.chainA, suite.chainB, ibctesting.Tendermint) + clientA, clientB = suite.coordinator.SetupClients(suite.chainA, suite.chainB, exported.Tendermint) connB, connA, err := suite.coordinator.ConnOpenInit(suite.chainB, suite.chainA, clientB, clientA) suite.Require().NoError(err) @@ -404,16 +404,16 @@ func (suite *KeeperTestSuite) TestConnOpenAck() { connection.State = types.TRYOPEN suite.chainB.App.IBCKeeper.ConnectionKeeper.SetConnection(suite.chainB.GetContext(), connB.ID, connection) // update clientB so state change is committed - suite.coordinator.UpdateClient(suite.chainB, suite.chainA, clientB, ibctesting.Tendermint) + suite.coordinator.UpdateClient(suite.chainB, suite.chainA, clientB, exported.Tendermint) - suite.coordinator.UpdateClient(suite.chainA, suite.chainB, clientA, ibctesting.Tendermint) + suite.coordinator.UpdateClient(suite.chainA, suite.chainB, clientA, exported.Tendermint) // retrieve client state of chainB to pass as counterpartyClient counterpartyClient = suite.chainB.GetClientState(clientB) }, true}, {"success from tryopen with empty stored connection id", func() { // chainA is in TRYOPEN, chainB is in TRYOPEN - clientA, clientB = suite.coordinator.SetupClients(suite.chainA, suite.chainB, ibctesting.Tendermint) + clientA, clientB = suite.coordinator.SetupClients(suite.chainA, suite.chainB, exported.Tendermint) connB, connA, err := suite.coordinator.ConnOpenInit(suite.chainB, suite.chainA, clientB, clientA) suite.Require().NoError(err) @@ -435,15 +435,15 @@ func (suite *KeeperTestSuite) TestConnOpenAck() { suite.chainA.App.IBCKeeper.ConnectionKeeper.SetConnection(suite.chainA.GetContext(), connA.ID, connection) // update clientB so state change is committed - suite.coordinator.UpdateClient(suite.chainB, suite.chainA, clientB, ibctesting.Tendermint) + suite.coordinator.UpdateClient(suite.chainB, suite.chainA, clientB, exported.Tendermint) - suite.coordinator.UpdateClient(suite.chainA, suite.chainB, clientA, ibctesting.Tendermint) + suite.coordinator.UpdateClient(suite.chainA, suite.chainB, clientA, exported.Tendermint) // retrieve client state of chainB to pass as counterpartyClient counterpartyClient = suite.chainB.GetClientState(clientB) }, true}, {"invalid counterparty client", func() { - clientA, clientB = suite.coordinator.SetupClients(suite.chainA, suite.chainB, ibctesting.Tendermint) + clientA, clientB = suite.coordinator.SetupClients(suite.chainA, suite.chainB, exported.Tendermint) connA, connB, err := suite.coordinator.ConnOpenInit(suite.chainA, suite.chainB, clientA, clientB) suite.Require().NoError(err) @@ -461,7 +461,7 @@ func (suite *KeeperTestSuite) TestConnOpenAck() { suite.Require().NoError(err) }, false}, {"consensus height >= latest height", func() { - clientA, clientB = suite.coordinator.SetupClients(suite.chainA, suite.chainB, ibctesting.Tendermint) + clientA, clientB = suite.coordinator.SetupClients(suite.chainA, suite.chainB, exported.Tendermint) connA, connB, err := suite.coordinator.ConnOpenInit(suite.chainA, suite.chainB, clientA, clientB) suite.Require().NoError(err) @@ -475,13 +475,13 @@ func (suite *KeeperTestSuite) TestConnOpenAck() { }, false}, {"connection not found", func() { // connections are never created - clientA, clientB = suite.coordinator.SetupClients(suite.chainA, suite.chainB, ibctesting.Tendermint) + clientA, clientB = suite.coordinator.SetupClients(suite.chainA, suite.chainB, exported.Tendermint) // retrieve client state of chainB to pass as counterpartyClient counterpartyClient = suite.chainB.GetClientState(clientB) }, false}, {"invalid counterparty connection ID", func() { - clientA, clientB = suite.coordinator.SetupClients(suite.chainA, suite.chainB, ibctesting.Tendermint) + clientA, clientB = suite.coordinator.SetupClients(suite.chainA, suite.chainB, exported.Tendermint) connA, connB, err := suite.coordinator.ConnOpenInit(suite.chainA, suite.chainB, clientA, clientB) suite.Require().NoError(err) @@ -499,15 +499,15 @@ func (suite *KeeperTestSuite) TestConnOpenAck() { suite.chainA.App.IBCKeeper.ConnectionKeeper.SetConnection(suite.chainA.GetContext(), connA.ID, connection) - err = suite.coordinator.UpdateClient(suite.chainA, suite.chainB, clientA, ibctesting.Tendermint) + err = suite.coordinator.UpdateClient(suite.chainA, suite.chainB, clientA, exported.Tendermint) suite.Require().NoError(err) - err = suite.coordinator.UpdateClient(suite.chainB, suite.chainA, clientB, ibctesting.Tendermint) + err = suite.coordinator.UpdateClient(suite.chainB, suite.chainA, clientB, exported.Tendermint) suite.Require().NoError(err) }, false}, {"connection state is not INIT", func() { // connection state is already OPEN on chainA - clientA, clientB = suite.coordinator.SetupClients(suite.chainA, suite.chainB, ibctesting.Tendermint) + clientA, clientB = suite.coordinator.SetupClients(suite.chainA, suite.chainB, exported.Tendermint) connA, connB, err := suite.coordinator.ConnOpenInit(suite.chainA, suite.chainB, clientA, clientB) suite.Require().NoError(err) @@ -522,7 +522,7 @@ func (suite *KeeperTestSuite) TestConnOpenAck() { }, false}, {"connection is in INIT but the proposed version is invalid", func() { // chainA is in INIT, chainB is in TRYOPEN - clientA, clientB = suite.coordinator.SetupClients(suite.chainA, suite.chainB, ibctesting.Tendermint) + clientA, clientB = suite.coordinator.SetupClients(suite.chainA, suite.chainB, exported.Tendermint) connA, connB, err := suite.coordinator.ConnOpenInit(suite.chainA, suite.chainB, clientA, clientB) suite.Require().NoError(err) @@ -536,7 +536,7 @@ func (suite *KeeperTestSuite) TestConnOpenAck() { }, false}, {"connection is in TRYOPEN but the set version in the connection is invalid", func() { // chainA is in TRYOPEN, chainB is in TRYOPEN - clientA, clientB = suite.coordinator.SetupClients(suite.chainA, suite.chainB, ibctesting.Tendermint) + clientA, clientB = suite.coordinator.SetupClients(suite.chainA, suite.chainB, exported.Tendermint) connB, connA, err := suite.coordinator.ConnOpenInit(suite.chainB, suite.chainA, clientB, clientA) suite.Require().NoError(err) @@ -549,8 +549,8 @@ func (suite *KeeperTestSuite) TestConnOpenAck() { suite.chainB.App.IBCKeeper.ConnectionKeeper.SetConnection(suite.chainB.GetContext(), connB.ID, connection) // update clientB so state change is committed - suite.coordinator.UpdateClient(suite.chainB, suite.chainA, clientB, ibctesting.Tendermint) - suite.coordinator.UpdateClient(suite.chainA, suite.chainB, clientA, ibctesting.Tendermint) + suite.coordinator.UpdateClient(suite.chainB, suite.chainA, clientB, exported.Tendermint) + suite.coordinator.UpdateClient(suite.chainA, suite.chainB, clientA, exported.Tendermint) // retrieve client state of chainB to pass as counterpartyClient counterpartyClient = suite.chainB.GetClientState(clientB) @@ -558,7 +558,7 @@ func (suite *KeeperTestSuite) TestConnOpenAck() { version = types.NewVersion("2.0", nil) }, false}, {"incompatible IBC versions", func() { - clientA, clientB = suite.coordinator.SetupClients(suite.chainA, suite.chainB, ibctesting.Tendermint) + clientA, clientB = suite.coordinator.SetupClients(suite.chainA, suite.chainB, exported.Tendermint) connA, connB, err := suite.coordinator.ConnOpenInit(suite.chainA, suite.chainB, clientA, clientB) suite.Require().NoError(err) @@ -572,7 +572,7 @@ func (suite *KeeperTestSuite) TestConnOpenAck() { version = types.NewVersion("2.0", nil) }, false}, {"empty version", func() { - clientA, clientB = suite.coordinator.SetupClients(suite.chainA, suite.chainB, ibctesting.Tendermint) + clientA, clientB = suite.coordinator.SetupClients(suite.chainA, suite.chainB, exported.Tendermint) connA, connB, err := suite.coordinator.ConnOpenInit(suite.chainA, suite.chainB, clientA, clientB) suite.Require().NoError(err) @@ -585,7 +585,7 @@ func (suite *KeeperTestSuite) TestConnOpenAck() { version = &types.Version{} }, false}, {"feature set verification failed - unsupported feature", func() { - clientA, clientB = suite.coordinator.SetupClients(suite.chainA, suite.chainB, ibctesting.Tendermint) + clientA, clientB = suite.coordinator.SetupClients(suite.chainA, suite.chainB, exported.Tendermint) connA, connB, err := suite.coordinator.ConnOpenInit(suite.chainA, suite.chainB, clientA, clientB) suite.Require().NoError(err) @@ -598,7 +598,7 @@ func (suite *KeeperTestSuite) TestConnOpenAck() { version = types.NewVersion(types.DefaultIBCVersionIdentifier, []string{"ORDER_ORDERED", "ORDER_UNORDERED", "ORDER_DAG"}) }, false}, {"self consensus state not found", func() { - clientA, clientB = suite.coordinator.SetupClients(suite.chainA, suite.chainB, ibctesting.Tendermint) + clientA, clientB = suite.coordinator.SetupClients(suite.chainA, suite.chainB, exported.Tendermint) connA, connB, err := suite.coordinator.ConnOpenInit(suite.chainA, suite.chainB, clientA, clientB) suite.Require().NoError(err) @@ -612,7 +612,7 @@ func (suite *KeeperTestSuite) TestConnOpenAck() { }, false}, {"connection state verification failed", func() { // chainB connection is not in INIT - clientA, clientB = suite.coordinator.SetupClients(suite.chainA, suite.chainB, ibctesting.Tendermint) + clientA, clientB = suite.coordinator.SetupClients(suite.chainA, suite.chainB, exported.Tendermint) _, _, err := suite.coordinator.ConnOpenInit(suite.chainA, suite.chainB, clientA, clientB) suite.Require().NoError(err) @@ -620,7 +620,7 @@ func (suite *KeeperTestSuite) TestConnOpenAck() { counterpartyClient = suite.chainB.GetClientState(clientB) }, false}, {"client state verification failed", func() { - clientA, clientB = suite.coordinator.SetupClients(suite.chainA, suite.chainB, ibctesting.Tendermint) + clientA, clientB = suite.coordinator.SetupClients(suite.chainA, suite.chainB, exported.Tendermint) connA, connB, err := suite.coordinator.ConnOpenInit(suite.chainA, suite.chainB, clientA, clientB) suite.Require().NoError(err) @@ -636,7 +636,7 @@ func (suite *KeeperTestSuite) TestConnOpenAck() { suite.Require().NoError(err) }, false}, {"consensus state verification failed", func() { - clientA, clientB = suite.coordinator.SetupClients(suite.chainA, suite.chainB, ibctesting.Tendermint) + clientA, clientB = suite.coordinator.SetupClients(suite.chainA, suite.chainB, exported.Tendermint) connA, connB, err := suite.coordinator.ConnOpenInit(suite.chainA, suite.chainB, clientA, clientB) suite.Require().NoError(err) @@ -717,7 +717,7 @@ func (suite *KeeperTestSuite) TestConnOpenConfirm() { expPass bool }{ {"success", func() { - clientA, clientB = suite.coordinator.SetupClients(suite.chainA, suite.chainB, ibctesting.Tendermint) + clientA, clientB = suite.coordinator.SetupClients(suite.chainA, suite.chainB, exported.Tendermint) connA, connB, err := suite.coordinator.ConnOpenInit(suite.chainA, suite.chainB, clientA, clientB) suite.Require().NoError(err) @@ -729,15 +729,15 @@ func (suite *KeeperTestSuite) TestConnOpenConfirm() { }, true}, {"connection not found", func() { // connections are never created - clientA, clientB = suite.coordinator.SetupClients(suite.chainA, suite.chainB, ibctesting.Tendermint) + clientA, clientB = suite.coordinator.SetupClients(suite.chainA, suite.chainB, exported.Tendermint) }, false}, {"chain B's connection state is not TRYOPEN", func() { // connections are OPEN - clientA, clientB, _, _ = suite.coordinator.SetupClientConnections(suite.chainA, suite.chainB, ibctesting.Tendermint) + clientA, clientB, _, _ = suite.coordinator.SetupClientConnections(suite.chainA, suite.chainB, exported.Tendermint) }, false}, {"connection state verification failed", func() { // chainA is in INIT - clientA, clientB = suite.coordinator.SetupClients(suite.chainA, suite.chainB, ibctesting.Tendermint) + clientA, clientB = suite.coordinator.SetupClients(suite.chainA, suite.chainB, exported.Tendermint) connA, connB, err := suite.coordinator.ConnOpenInit(suite.chainA, suite.chainB, clientA, clientB) suite.Require().NoError(err) @@ -779,7 +779,7 @@ func (suite *KeeperTestSuite) TestConnOpenConfirm() { // package. func (suite *KeeperTestSuite) TestConsensusParamsValidation() { // invalid client state in ConnOpenTry - clientA, clientB := suite.coordinator.SetupClients(suite.chainA, suite.chainB, ibctesting.Tendermint) + clientA, clientB := suite.coordinator.SetupClients(suite.chainA, suite.chainB, exported.Tendermint) connA, connB, err := suite.coordinator.ConnOpenInit(suite.chainA, suite.chainB, clientA, clientB) suite.Require().NoError(err) @@ -804,7 +804,7 @@ func (suite *KeeperTestSuite) TestConsensusParamsValidation() { suite.SetupTest() // reset // invalid client state in ConnOpenAck - clientA, clientB = suite.coordinator.SetupClients(suite.chainA, suite.chainB, ibctesting.Tendermint) + clientA, clientB = suite.coordinator.SetupClients(suite.chainA, suite.chainB, exported.Tendermint) connA, connB, err = suite.coordinator.ConnOpenInit(suite.chainA, suite.chainB, clientA, clientB) suite.Require().NoError(err) diff --git a/x/ibc/core/03-connection/keeper/keeper_test.go b/x/ibc/core/03-connection/keeper/keeper_test.go index 3ae867a5a..cf8f44717 100644 --- a/x/ibc/core/03-connection/keeper/keeper_test.go +++ b/x/ibc/core/03-connection/keeper/keeper_test.go @@ -7,6 +7,7 @@ import ( "github.com/stretchr/testify/suite" "github.com/cosmos/cosmos-sdk/x/ibc/core/03-connection/types" + "github.com/cosmos/cosmos-sdk/x/ibc/core/exported" ibctesting "github.com/cosmos/cosmos-sdk/x/ibc/testing" ) @@ -31,7 +32,7 @@ func TestKeeperTestSuite(t *testing.T) { } func (suite *KeeperTestSuite) TestSetAndGetConnection() { - clientA, clientB := suite.coordinator.SetupClients(suite.chainA, suite.chainB, ibctesting.Tendermint) + clientA, clientB := suite.coordinator.SetupClients(suite.chainA, suite.chainB, exported.Tendermint) connA := suite.chainA.GetFirstTestConnection(clientA, clientB) _, existed := suite.chainA.App.IBCKeeper.ConnectionKeeper.GetConnection(suite.chainA.GetContext(), connA.ID) suite.Require().False(existed) @@ -42,7 +43,7 @@ func (suite *KeeperTestSuite) TestSetAndGetConnection() { } func (suite *KeeperTestSuite) TestSetAndGetClientConnectionPaths() { - clientA, _ := suite.coordinator.SetupClients(suite.chainA, suite.chainB, ibctesting.Tendermint) + clientA, _ := suite.coordinator.SetupClients(suite.chainA, suite.chainB, exported.Tendermint) _, existed := suite.chainA.App.IBCKeeper.ConnectionKeeper.GetClientConnectionPaths(suite.chainA.GetContext(), clientA) suite.False(existed) @@ -55,7 +56,7 @@ func (suite *KeeperTestSuite) TestSetAndGetClientConnectionPaths() { // create 2 connections: A0 - B0, A1 - B1 func (suite KeeperTestSuite) TestGetAllConnections() { - clientA, clientB, connA0, connB0 := suite.coordinator.SetupClientConnections(suite.chainA, suite.chainB, ibctesting.Tendermint) + clientA, clientB, connA0, connB0 := suite.coordinator.SetupClientConnections(suite.chainA, suite.chainB, exported.Tendermint) connA1, connB1 := suite.coordinator.CreateConnection(suite.chainA, suite.chainB, clientA, clientB) counterpartyB0 := types.NewCounterparty(clientB, connB0.ID, suite.chainB.GetPrefix()) // connection B0 @@ -77,8 +78,8 @@ func (suite KeeperTestSuite) TestGetAllConnections() { // the test creates 2 clients clientA0 and clientA1. clientA0 has a single // connection and clientA1 has 2 connections. func (suite KeeperTestSuite) TestGetAllClientConnectionPaths() { - clientA0, _, connA0, _ := suite.coordinator.SetupClientConnections(suite.chainA, suite.chainB, ibctesting.Tendermint) - clientA1, clientB1, connA1, _ := suite.coordinator.SetupClientConnections(suite.chainA, suite.chainB, ibctesting.Tendermint) + clientA0, _, connA0, _ := suite.coordinator.SetupClientConnections(suite.chainA, suite.chainB, exported.Tendermint) + clientA1, clientB1, connA1, _ := suite.coordinator.SetupClientConnections(suite.chainA, suite.chainB, exported.Tendermint) connA2, _ := suite.coordinator.CreateConnection(suite.chainA, suite.chainB, clientA1, clientB1) expPaths := []types.ConnectionPaths{ @@ -102,7 +103,7 @@ func (suite *KeeperTestSuite) TestGetTimestampAtHeight() { expPass bool }{ {"verification success", func() { - _, _, connA, _ := suite.coordinator.SetupClientConnections(suite.chainA, suite.chainB, ibctesting.Tendermint) + _, _, connA, _ := suite.coordinator.SetupClientConnections(suite.chainA, suite.chainB, exported.Tendermint) connection = suite.chainA.GetConnection(connA) }, true}, {"consensus state not found", func() { diff --git a/x/ibc/core/03-connection/keeper/verify_test.go b/x/ibc/core/03-connection/keeper/verify_test.go index c9db5cc2b..ace373e12 100644 --- a/x/ibc/core/03-connection/keeper/verify_test.go +++ b/x/ibc/core/03-connection/keeper/verify_test.go @@ -38,7 +38,7 @@ func (suite *KeeperTestSuite) TestVerifyClientState() { suite.Run(tc.msg, func() { suite.SetupTest() // reset - _, clientB, connA, _ := suite.coordinator.SetupClientConnections(suite.chainA, suite.chainB, ibctesting.Tendermint) + _, clientB, connA, _ := suite.coordinator.SetupClientConnections(suite.chainA, suite.chainB, exported.Tendermint) counterpartyClient, clientProof := suite.chainB.QueryClientStateProof(clientB) proofHeight := clienttypes.NewHeight(0, uint64(suite.chainB.GetContext().BlockHeight()-1)) @@ -83,20 +83,20 @@ func (suite *KeeperTestSuite) TestVerifyClientConsensusState() { expPass bool }{ {"verification success", func() { - _, _, connA, connB = suite.coordinator.SetupClientConnections(suite.chainA, suite.chainB, ibctesting.Tendermint) + _, _, connA, connB = suite.coordinator.SetupClientConnections(suite.chainA, suite.chainB, exported.Tendermint) }, true}, {"client state not found", func() { - _, _, connA, connB = suite.coordinator.SetupClientConnections(suite.chainA, suite.chainB, ibctesting.Tendermint) + _, _, connA, connB = suite.coordinator.SetupClientConnections(suite.chainA, suite.chainB, exported.Tendermint) changeClientID = true }, false}, {"consensus state not found", func() { - _, _, connA, connB = suite.coordinator.SetupClientConnections(suite.chainA, suite.chainB, ibctesting.Tendermint) + _, _, connA, connB = suite.coordinator.SetupClientConnections(suite.chainA, suite.chainB, exported.Tendermint) heightDiff = 5 }, false}, {"verification failed", func() { - _, _, connA, connB = suite.coordinator.SetupClientConnections(suite.chainA, suite.chainB, ibctesting.Tendermint) + _, _, connA, connB = suite.coordinator.SetupClientConnections(suite.chainA, suite.chainB, exported.Tendermint) clientB := connB.ClientID clientState := suite.chainB.GetClientState(clientB) @@ -170,7 +170,7 @@ func (suite *KeeperTestSuite) TestVerifyConnectionState() { suite.Run(tc.msg, func() { suite.SetupTest() // reset - _, _, connA, connB := suite.coordinator.SetupClientConnections(suite.chainA, suite.chainB, ibctesting.Tendermint) + _, _, connA, connB := suite.coordinator.SetupClientConnections(suite.chainA, suite.chainB, exported.Tendermint) connection := suite.chainA.GetConnection(connA) if tc.changeClientID { @@ -402,7 +402,7 @@ func (suite *KeeperTestSuite) TestVerifyPacketReceiptAbsence() { } else { // need to update height to prove absence suite.coordinator.CommitBlock(suite.chainA, suite.chainB) - suite.coordinator.UpdateClient(suite.chainA, suite.chainB, clientA, ibctesting.Tendermint) + suite.coordinator.UpdateClient(suite.chainA, suite.chainB, clientA, exported.Tendermint) } packetReceiptKey := host.PacketReceiptKey(packet.GetDestPort(), packet.GetDestChannel(), packet.GetSequence()) diff --git a/x/ibc/core/04-channel/keeper/grpc_query_test.go b/x/ibc/core/04-channel/keeper/grpc_query_test.go index 031b89cc1..9e96d2b2f 100644 --- a/x/ibc/core/04-channel/keeper/grpc_query_test.go +++ b/x/ibc/core/04-channel/keeper/grpc_query_test.go @@ -62,7 +62,7 @@ func (suite *KeeperTestSuite) TestQueryChannel() { { "success", func() { - _, _, connA, connB := suite.coordinator.SetupClientConnections(suite.chainA, suite.chainB, ibctesting.Tendermint) + _, _, connA, connB := suite.coordinator.SetupClientConnections(suite.chainA, suite.chainB, exported.Tendermint) // init channel channelA, _, err := suite.coordinator.ChanOpenInit(suite.chainA, suite.chainB, connA, connB, ibctesting.MockPort, ibctesting.MockPort, types.ORDERED) suite.Require().NoError(err) @@ -377,7 +377,7 @@ func (suite *KeeperTestSuite) TestQueryChannelClientState() { { "success", func() { - clientA, _, connA, connB := suite.coordinator.SetupClientConnections(suite.chainA, suite.chainB, ibctesting.Tendermint) + clientA, _, connA, connB := suite.coordinator.SetupClientConnections(suite.chainA, suite.chainB, exported.Tendermint) // init channel channelA, _, err := suite.coordinator.ChanOpenInit(suite.chainA, suite.chainB, connA, connB, ibctesting.MockPort, ibctesting.MockPort, types.ORDERED) suite.Require().NoError(err) @@ -505,7 +505,7 @@ func (suite *KeeperTestSuite) TestQueryChannelConsensusState() { { "success", func() { - clientA, _, connA, connB := suite.coordinator.SetupClientConnections(suite.chainA, suite.chainB, ibctesting.Tendermint) + clientA, _, connA, connB := suite.coordinator.SetupClientConnections(suite.chainA, suite.chainB, exported.Tendermint) // init channel channelA, _, err := suite.coordinator.ChanOpenInit(suite.chainA, suite.chainB, connA, connB, ibctesting.MockPort, ibctesting.MockPort, types.ORDERED) suite.Require().NoError(err) diff --git a/x/ibc/core/04-channel/keeper/handshake_test.go b/x/ibc/core/04-channel/keeper/handshake_test.go index cf391d038..857bba57d 100644 --- a/x/ibc/core/04-channel/keeper/handshake_test.go +++ b/x/ibc/core/04-channel/keeper/handshake_test.go @@ -32,7 +32,7 @@ func (suite *KeeperTestSuite) TestChanOpenInit() { testCases := []testCase{ {"success", func() { - _, _, connA, connB = suite.coordinator.SetupClientConnections(suite.chainA, suite.chainB, ibctesting.Tendermint) + _, _, connA, connB = suite.coordinator.SetupClientConnections(suite.chainA, suite.chainB, exported.Tendermint) features = []string{"ORDER_ORDERED", "ORDER_UNORDERED"} suite.chainA.CreatePortCapability(connA.NextTestChannel(ibctesting.MockPort).PortID) portCap = suite.chainA.GetPortCapability(connA.NextTestChannel(ibctesting.MockPort).PortID) @@ -46,12 +46,12 @@ func (suite *KeeperTestSuite) TestChanOpenInit() { suite.Require().NotNil(connB) }, false}, {"capability is incorrect", func() { - _, _, connA, connB = suite.coordinator.SetupClientConnections(suite.chainA, suite.chainB, ibctesting.Tendermint) + _, _, connA, connB = suite.coordinator.SetupClientConnections(suite.chainA, suite.chainB, exported.Tendermint) features = []string{"ORDER_ORDERED", "ORDER_UNORDERED"} portCap = capabilitytypes.NewCapability(3) }, false}, {"connection version not negotiated", func() { - _, _, connA, connB = suite.coordinator.SetupClientConnections(suite.chainA, suite.chainB, ibctesting.Tendermint) + _, _, connA, connB = suite.coordinator.SetupClientConnections(suite.chainA, suite.chainB, exported.Tendermint) // modify connA versions conn := suite.chainA.GetConnection(connA) @@ -68,7 +68,7 @@ func (suite *KeeperTestSuite) TestChanOpenInit() { portCap = suite.chainA.GetPortCapability(connA.NextTestChannel(ibctesting.MockPort).PortID) }, false}, {"connection does not support ORDERED channels", func() { - _, _, connA, connB = suite.coordinator.SetupClientConnections(suite.chainA, suite.chainB, ibctesting.Tendermint) + _, _, connA, connB = suite.coordinator.SetupClientConnections(suite.chainA, suite.chainB, exported.Tendermint) // modify connA versions to only support UNORDERED channels conn := suite.chainA.GetConnection(connA) @@ -145,21 +145,21 @@ func (suite *KeeperTestSuite) TestChanOpenTry() { testCases := []testCase{ {"success", func() { - _, _, connA, connB = suite.coordinator.SetupClientConnections(suite.chainA, suite.chainB, ibctesting.Tendermint) + _, _, connA, connB = suite.coordinator.SetupClientConnections(suite.chainA, suite.chainB, exported.Tendermint) suite.coordinator.ChanOpenInit(suite.chainA, suite.chainB, connA, connB, ibctesting.MockPort, ibctesting.MockPort, types.ORDERED) suite.chainB.CreatePortCapability(connB.NextTestChannel(ibctesting.MockPort).PortID) portCap = suite.chainB.GetPortCapability(connB.NextTestChannel(ibctesting.MockPort).PortID) }, true}, {"success with crossing hello", func() { - _, _, connA, connB = suite.coordinator.SetupClientConnections(suite.chainA, suite.chainB, ibctesting.Tendermint) + _, _, connA, connB = suite.coordinator.SetupClientConnections(suite.chainA, suite.chainB, exported.Tendermint) suite.coordinator.ChanOpenInitOnBothChains(suite.chainA, suite.chainB, connA, connB, ibctesting.MockPort, ibctesting.MockPort, types.ORDERED) portCap = suite.chainB.GetPortCapability(connB.NextTestChannel(ibctesting.MockPort).PortID) }, true}, {"success with empty counterparty chosen channel id", func() { var clientA, clientB string - clientA, clientB, connA, connB = suite.coordinator.SetupClientConnections(suite.chainA, suite.chainB, ibctesting.Tendermint) + clientA, clientB, connA, connB = suite.coordinator.SetupClientConnections(suite.chainA, suite.chainB, exported.Tendermint) channelA, _, err := suite.coordinator.ChanOpenInit(suite.chainA, suite.chainB, connA, connB, ibctesting.MockPort, ibctesting.MockPort, types.ORDERED) suite.Require().NoError(err) @@ -168,17 +168,17 @@ func (suite *KeeperTestSuite) TestChanOpenTry() { channel.Counterparty.ChannelId = "" suite.chainA.App.IBCKeeper.ChannelKeeper.SetChannel(suite.chainA.GetContext(), channelA.PortID, channelA.ID, channel) - err = suite.coordinator.UpdateClient(suite.chainA, suite.chainB, clientA, ibctesting.Tendermint) + err = suite.coordinator.UpdateClient(suite.chainA, suite.chainB, clientA, exported.Tendermint) suite.Require().NoError(err) - err = suite.coordinator.UpdateClient(suite.chainB, suite.chainA, clientB, ibctesting.Tendermint) + err = suite.coordinator.UpdateClient(suite.chainB, suite.chainA, clientB, exported.Tendermint) suite.Require().NoError(err) suite.chainB.CreatePortCapability(connB.NextTestChannel(ibctesting.MockPort).PortID) portCap = suite.chainB.GetPortCapability(connB.NextTestChannel(ibctesting.MockPort).PortID) }, true}, {"previous channel with invalid state", func() { - _, _, connA, connB = suite.coordinator.SetupClientConnections(suite.chainA, suite.chainB, ibctesting.Tendermint) + _, _, connA, connB = suite.coordinator.SetupClientConnections(suite.chainA, suite.chainB, exported.Tendermint) // make previous channel have wrong ordering suite.coordinator.ChanOpenInit(suite.chainB, suite.chainA, connB, connA, ibctesting.MockPort, ibctesting.MockPort, types.UNORDERED) @@ -193,7 +193,7 @@ func (suite *KeeperTestSuite) TestChanOpenTry() { portCap = suite.chainB.GetPortCapability(connB.FirstOrNextTestChannel(ibctesting.MockPort).PortID) }, false}, {"connection is not OPEN", func() { - clientA, clientB := suite.coordinator.SetupClients(suite.chainA, suite.chainB, ibctesting.Tendermint) + clientA, clientB := suite.coordinator.SetupClients(suite.chainA, suite.chainB, exported.Tendermint) // pass capability check suite.chainB.CreatePortCapability(connB.FirstOrNextTestChannel(ibctesting.MockPort).PortID) portCap = suite.chainB.GetPortCapability(connB.FirstOrNextTestChannel(ibctesting.MockPort).PortID) @@ -203,7 +203,7 @@ func (suite *KeeperTestSuite) TestChanOpenTry() { suite.Require().NoError(err) }, false}, {"consensus state not found", func() { - _, _, connA, connB = suite.coordinator.SetupClientConnections(suite.chainA, suite.chainB, ibctesting.Tendermint) + _, _, connA, connB = suite.coordinator.SetupClientConnections(suite.chainA, suite.chainB, exported.Tendermint) suite.coordinator.ChanOpenInit(suite.chainA, suite.chainB, connA, connB, ibctesting.MockPort, ibctesting.MockPort, types.ORDERED) suite.chainB.CreatePortCapability(connB.NextTestChannel(ibctesting.MockPort).PortID) @@ -212,7 +212,7 @@ func (suite *KeeperTestSuite) TestChanOpenTry() { heightDiff = 3 // consensus state doesn't exist at this height }, false}, {"counterparty chosen channel id does not match desired channel id", func() { - _, _, connA, connB = suite.coordinator.SetupClientConnections(suite.chainA, suite.chainB, ibctesting.Tendermint) + _, _, connA, connB = suite.coordinator.SetupClientConnections(suite.chainA, suite.chainB, exported.Tendermint) channelA, _, err := suite.coordinator.ChanOpenInit(suite.chainA, suite.chainB, connA, connB, ibctesting.MockPort, ibctesting.MockPort, types.ORDERED) suite.Require().NoError(err) @@ -226,17 +226,17 @@ func (suite *KeeperTestSuite) TestChanOpenTry() { }, false}, {"channel verification failed", func() { // not creating a channel on chainA will result in an invalid proof of existence - _, _, connA, connB = suite.coordinator.SetupClientConnections(suite.chainA, suite.chainB, ibctesting.Tendermint) + _, _, connA, connB = suite.coordinator.SetupClientConnections(suite.chainA, suite.chainB, exported.Tendermint) portCap = suite.chainB.GetPortCapability(connB.NextTestChannel(ibctesting.MockPort).PortID) }, false}, {"port capability not found", func() { - _, _, connA, connB = suite.coordinator.SetupClientConnections(suite.chainA, suite.chainB, ibctesting.Tendermint) + _, _, connA, connB = suite.coordinator.SetupClientConnections(suite.chainA, suite.chainB, exported.Tendermint) suite.coordinator.ChanOpenInit(suite.chainA, suite.chainB, connA, connB, ibctesting.MockPort, ibctesting.MockPort, types.ORDERED) portCap = capabilitytypes.NewCapability(3) }, false}, {"connection version not negotiated", func() { - _, _, connA, connB = suite.coordinator.SetupClientConnections(suite.chainA, suite.chainB, ibctesting.Tendermint) + _, _, connA, connB = suite.coordinator.SetupClientConnections(suite.chainA, suite.chainB, exported.Tendermint) suite.coordinator.ChanOpenInit(suite.chainA, suite.chainB, connA, connB, ibctesting.MockPort, ibctesting.MockPort, types.ORDERED) // modify connB versions @@ -253,7 +253,7 @@ func (suite *KeeperTestSuite) TestChanOpenTry() { portCap = suite.chainB.GetPortCapability(connB.NextTestChannel(ibctesting.MockPort).PortID) }, false}, {"connection does not support ORDERED channels", func() { - _, _, connA, connB = suite.coordinator.SetupClientConnections(suite.chainA, suite.chainB, ibctesting.Tendermint) + _, _, connA, connB = suite.coordinator.SetupClientConnections(suite.chainA, suite.chainB, exported.Tendermint) suite.coordinator.ChanOpenInit(suite.chainA, suite.chainB, connA, connB, ibctesting.MockPort, ibctesting.MockPort, types.ORDERED) // modify connA versions to only support UNORDERED channels @@ -329,7 +329,7 @@ func (suite *KeeperTestSuite) TestChanOpenAck() { testCases := []testCase{ {"success", func() { - _, _, connA, connB = suite.coordinator.SetupClientConnections(suite.chainA, suite.chainB, ibctesting.Tendermint) + _, _, connA, connB = suite.coordinator.SetupClientConnections(suite.chainA, suite.chainB, exported.Tendermint) channelA, channelB, err := suite.coordinator.ChanOpenInit(suite.chainA, suite.chainB, connA, connB, ibctesting.MockPort, ibctesting.MockPort, types.ORDERED) suite.Require().NoError(err) @@ -339,7 +339,7 @@ func (suite *KeeperTestSuite) TestChanOpenAck() { channelCap = suite.chainA.GetChannelCapability(channelA.PortID, channelA.ID) }, true}, {"success with empty stored counterparty channel ID", func() { - _, _, connA, connB = suite.coordinator.SetupClientConnections(suite.chainA, suite.chainB, ibctesting.Tendermint) + _, _, connA, connB = suite.coordinator.SetupClientConnections(suite.chainA, suite.chainB, exported.Tendermint) channelA, channelB, err := suite.coordinator.ChanOpenInit(suite.chainA, suite.chainB, connA, connB, ibctesting.MockPort, ibctesting.MockPort, types.ORDERED) suite.Require().NoError(err) @@ -365,7 +365,7 @@ func (suite *KeeperTestSuite) TestChanOpenAck() { channelCap = suite.chainA.GetChannelCapability(channelA.PortID, channelA.ID) }, false}, {"connection not found", func() { - _, _, connA, connB = suite.coordinator.SetupClientConnections(suite.chainA, suite.chainB, ibctesting.Tendermint) + _, _, connA, connB = suite.coordinator.SetupClientConnections(suite.chainA, suite.chainB, exported.Tendermint) channelA, channelB, err := suite.coordinator.ChanOpenInit(suite.chainA, suite.chainB, connA, connB, ibctesting.MockPort, ibctesting.MockPort, types.ORDERED) suite.Require().NoError(err) @@ -380,7 +380,7 @@ func (suite *KeeperTestSuite) TestChanOpenAck() { suite.chainA.App.IBCKeeper.ChannelKeeper.SetChannel(suite.chainA.GetContext(), channelA.PortID, channelA.ID, channel) }, false}, {"connection is not OPEN", func() { - clientA, clientB := suite.coordinator.SetupClients(suite.chainA, suite.chainB, ibctesting.Tendermint) + clientA, clientB := suite.coordinator.SetupClients(suite.chainA, suite.chainB, exported.Tendermint) var err error connA, connB, err = suite.coordinator.ConnOpenInit(suite.chainA, suite.chainB, clientA, clientB) @@ -394,7 +394,7 @@ func (suite *KeeperTestSuite) TestChanOpenAck() { channelCap = suite.chainA.GetChannelCapability(channelA.PortID, channelA.ID) }, false}, {"consensus state not found", func() { - _, _, connA, connB = suite.coordinator.SetupClientConnections(suite.chainA, suite.chainB, ibctesting.Tendermint) + _, _, connA, connB = suite.coordinator.SetupClientConnections(suite.chainA, suite.chainB, exported.Tendermint) channelA, channelB, err := suite.coordinator.ChanOpenInit(suite.chainA, suite.chainB, connA, connB, ibctesting.MockPort, ibctesting.MockPort, types.ORDERED) suite.Require().NoError(err) @@ -406,7 +406,7 @@ func (suite *KeeperTestSuite) TestChanOpenAck() { heightDiff = 3 // consensus state doesn't exist at this height }, false}, {"invalid counterparty channel identifier", func() { - _, _, connA, connB = suite.coordinator.SetupClientConnections(suite.chainA, suite.chainB, ibctesting.Tendermint) + _, _, connA, connB = suite.coordinator.SetupClientConnections(suite.chainA, suite.chainB, exported.Tendermint) channelA, channelB, err := suite.coordinator.ChanOpenInit(suite.chainA, suite.chainB, connA, connB, ibctesting.MockPort, ibctesting.MockPort, types.ORDERED) suite.Require().NoError(err) @@ -419,7 +419,7 @@ func (suite *KeeperTestSuite) TestChanOpenAck() { }, false}, {"channel verification failed", func() { // chainB is INIT, chainA in TRYOPEN - _, _, connA, connB = suite.coordinator.SetupClientConnections(suite.chainA, suite.chainB, ibctesting.Tendermint) + _, _, connA, connB = suite.coordinator.SetupClientConnections(suite.chainA, suite.chainB, exported.Tendermint) channelB, channelA, err := suite.coordinator.ChanOpenInit(suite.chainB, suite.chainA, connB, connA, ibctesting.MockPort, ibctesting.MockPort, types.ORDERED) suite.Require().NoError(err) @@ -429,7 +429,7 @@ func (suite *KeeperTestSuite) TestChanOpenAck() { channelCap = suite.chainA.GetChannelCapability(channelA.PortID, channelA.ID) }, false}, {"channel capability not found", func() { - _, _, connA, connB = suite.coordinator.SetupClientConnections(suite.chainA, suite.chainB, ibctesting.Tendermint) + _, _, connA, connB = suite.coordinator.SetupClientConnections(suite.chainA, suite.chainB, exported.Tendermint) channelA, channelB, err := suite.coordinator.ChanOpenInit(suite.chainA, suite.chainB, connA, connB, ibctesting.MockPort, ibctesting.MockPort, types.ORDERED) suite.Require().NoError(err) @@ -484,7 +484,7 @@ func (suite *KeeperTestSuite) TestChanOpenConfirm() { ) testCases := []testCase{ {"success", func() { - _, _, connA, connB = suite.coordinator.SetupClientConnections(suite.chainA, suite.chainB, ibctesting.Tendermint) + _, _, connA, connB = suite.coordinator.SetupClientConnections(suite.chainA, suite.chainB, exported.Tendermint) channelA, channelB, err := suite.coordinator.ChanOpenInit(suite.chainA, suite.chainB, connA, connB, ibctesting.MockPort, ibctesting.MockPort, types.ORDERED) suite.Require().NoError(err) @@ -504,7 +504,7 @@ func (suite *KeeperTestSuite) TestChanOpenConfirm() { channelCap = suite.chainB.GetChannelCapability(channelB.PortID, channelB.ID) }, false}, {"connection not found", func() { - _, _, connA, connB = suite.coordinator.SetupClientConnections(suite.chainA, suite.chainB, ibctesting.Tendermint) + _, _, connA, connB = suite.coordinator.SetupClientConnections(suite.chainA, suite.chainB, exported.Tendermint) channelA, channelB, err := suite.coordinator.ChanOpenInit(suite.chainA, suite.chainB, connA, connB, ibctesting.MockPort, ibctesting.MockPort, types.ORDERED) suite.Require().NoError(err) @@ -522,7 +522,7 @@ func (suite *KeeperTestSuite) TestChanOpenConfirm() { suite.chainB.App.IBCKeeper.ChannelKeeper.SetChannel(suite.chainB.GetContext(), channelB.PortID, channelB.ID, channel) }, false}, {"connection is not OPEN", func() { - clientA, clientB := suite.coordinator.SetupClients(suite.chainA, suite.chainB, ibctesting.Tendermint) + clientA, clientB := suite.coordinator.SetupClients(suite.chainA, suite.chainB, exported.Tendermint) var err error connA, connB, err = suite.coordinator.ConnOpenInit(suite.chainB, suite.chainA, clientB, clientA) @@ -532,7 +532,7 @@ func (suite *KeeperTestSuite) TestChanOpenConfirm() { channelCap = suite.chainB.GetChannelCapability(channelB.PortID, channelB.ID) }, false}, {"consensus state not found", func() { - _, _, connA, connB = suite.coordinator.SetupClientConnections(suite.chainA, suite.chainB, ibctesting.Tendermint) + _, _, connA, connB = suite.coordinator.SetupClientConnections(suite.chainA, suite.chainB, exported.Tendermint) channelA, channelB, err := suite.coordinator.ChanOpenInit(suite.chainA, suite.chainB, connA, connB, ibctesting.MockPort, ibctesting.MockPort, types.ORDERED) suite.Require().NoError(err) @@ -548,7 +548,7 @@ func (suite *KeeperTestSuite) TestChanOpenConfirm() { }, false}, {"channel verification failed", func() { // chainA is INIT, chainB in TRYOPEN - _, _, connA, connB = suite.coordinator.SetupClientConnections(suite.chainA, suite.chainB, ibctesting.Tendermint) + _, _, connA, connB = suite.coordinator.SetupClientConnections(suite.chainA, suite.chainB, exported.Tendermint) channelA, channelB, err := suite.coordinator.ChanOpenInit(suite.chainA, suite.chainB, connA, connB, ibctesting.MockPort, ibctesting.MockPort, types.ORDERED) suite.Require().NoError(err) @@ -558,7 +558,7 @@ func (suite *KeeperTestSuite) TestChanOpenConfirm() { channelCap = suite.chainB.GetChannelCapability(channelB.PortID, channelB.ID) }, false}, {"channel capability not found", func() { - _, _, connA, connB = suite.coordinator.SetupClientConnections(suite.chainA, suite.chainB, ibctesting.Tendermint) + _, _, connA, connB = suite.coordinator.SetupClientConnections(suite.chainA, suite.chainB, exported.Tendermint) channelA, channelB, err := suite.coordinator.ChanOpenInit(suite.chainA, suite.chainB, connA, connB, ibctesting.MockPort, ibctesting.MockPort, types.ORDERED) suite.Require().NoError(err) @@ -645,7 +645,7 @@ func (suite *KeeperTestSuite) TestChanCloseInit() { suite.chainA.App.IBCKeeper.ChannelKeeper.SetChannel(suite.chainA.GetContext(), channelA.PortID, channelA.ID, channel) }, false}, {"connection is not OPEN", func() { - clientA, clientB := suite.coordinator.SetupClients(suite.chainA, suite.chainB, ibctesting.Tendermint) + clientA, clientB := suite.coordinator.SetupClients(suite.chainA, suite.chainB, exported.Tendermint) var err error connA, connB, err = suite.coordinator.ConnOpenInit(suite.chainA, suite.chainB, clientA, clientB) @@ -734,7 +734,7 @@ func (suite *KeeperTestSuite) TestChanCloseConfirm() { suite.chainB.App.IBCKeeper.ChannelKeeper.SetChannel(suite.chainB.GetContext(), channelB.PortID, channelB.ID, channel) }, false}, {"connection is not OPEN", func() { - clientA, clientB := suite.coordinator.SetupClients(suite.chainA, suite.chainB, ibctesting.Tendermint) + clientA, clientB := suite.coordinator.SetupClients(suite.chainA, suite.chainB, exported.Tendermint) var err error connB, connA, err = suite.coordinator.ConnOpenInit(suite.chainB, suite.chainA, clientB, clientA) diff --git a/x/ibc/core/04-channel/keeper/keeper_test.go b/x/ibc/core/04-channel/keeper/keeper_test.go index 01f7a7584..d1ea3de5d 100644 --- a/x/ibc/core/04-channel/keeper/keeper_test.go +++ b/x/ibc/core/04-channel/keeper/keeper_test.go @@ -6,6 +6,7 @@ import ( "github.com/stretchr/testify/suite" "github.com/cosmos/cosmos-sdk/x/ibc/core/04-channel/types" + "github.com/cosmos/cosmos-sdk/x/ibc/core/exported" ibctesting "github.com/cosmos/cosmos-sdk/x/ibc/testing" ) @@ -39,7 +40,7 @@ func (suite *KeeperTestSuite) SetupTest() { // and existence of a channel in INIT on chainA. func (suite *KeeperTestSuite) TestSetChannel() { // create client and connections on both chains - _, _, connA, connB := suite.coordinator.SetupClientConnections(suite.chainA, suite.chainB, ibctesting.Tendermint) + _, _, connA, connB := suite.coordinator.SetupClientConnections(suite.chainA, suite.chainB, exported.Tendermint) // check for channel to be created on chainB channelA := connA.NextTestChannel(ibctesting.MockPort) diff --git a/x/ibc/core/04-channel/keeper/packet_test.go b/x/ibc/core/04-channel/keeper/packet_test.go index f3624897d..f04b6ac10 100644 --- a/x/ibc/core/04-channel/keeper/packet_test.go +++ b/x/ibc/core/04-channel/keeper/packet_test.go @@ -130,7 +130,7 @@ func (suite *KeeperTestSuite) TestSendPacket() { channelCap = suite.chainA.GetChannelCapability(channelA.PortID, channelA.ID) }, false}, {"next sequence send not found", func() { - _, _, connA, connB := suite.coordinator.SetupClientConnections(suite.chainA, suite.chainB, ibctesting.Tendermint) + _, _, connA, connB := suite.coordinator.SetupClientConnections(suite.chainA, suite.chainB, exported.Tendermint) channelA := connA.NextTestChannel(ibctesting.TransferPort) channelB := connB.NextTestChannel(ibctesting.TransferPort) packet = types.NewPacket(validPacketData, 1, channelA.PortID, channelA.ID, channelB.PortID, channelB.ID, timeoutHeight, disabledTimeoutTimestamp) @@ -276,7 +276,7 @@ func (suite *KeeperTestSuite) TestRecvPacket() { channelCap = suite.chainB.GetChannelCapability(channelB.PortID, channelB.ID) }, false}, {"connection not OPEN", func() { - clientA, clientB := suite.coordinator.SetupClients(suite.chainA, suite.chainB, ibctesting.Tendermint) + clientA, clientB := suite.coordinator.SetupClients(suite.chainA, suite.chainB, exported.Tendermint) // connection on chainB is in INIT connB, connA, err := suite.coordinator.ConnOpenInit(suite.chainB, suite.chainA, clientB, clientA) suite.Require().NoError(err) @@ -304,7 +304,7 @@ func (suite *KeeperTestSuite) TestRecvPacket() { channelCap = suite.chainB.GetChannelCapability(channelB.PortID, channelB.ID) }, false}, {"next receive sequence is not found", func() { - _, _, connA, connB := suite.coordinator.SetupClientConnections(suite.chainA, suite.chainB, ibctesting.Tendermint) + _, _, connA, connB := suite.coordinator.SetupClientConnections(suite.chainA, suite.chainB, exported.Tendermint) channelA := connA.NextTestChannel(ibctesting.TransferPort) channelB := connB.NextTestChannel(ibctesting.TransferPort) @@ -548,7 +548,7 @@ func (suite *KeeperTestSuite) TestAcknowledgePacket() { channelCap = suite.chainA.GetChannelCapability(channelA.PortID, channelA.ID) }, false}, {"connection not OPEN", func() { - clientA, clientB := suite.coordinator.SetupClients(suite.chainA, suite.chainB, ibctesting.Tendermint) + clientA, clientB := suite.coordinator.SetupClients(suite.chainA, suite.chainB, exported.Tendermint) // connection on chainA is in INIT connA, connB, err := suite.coordinator.ConnOpenInit(suite.chainA, suite.chainB, clientA, clientB) suite.Require().NoError(err) @@ -581,7 +581,7 @@ func (suite *KeeperTestSuite) TestAcknowledgePacket() { channelCap = suite.chainA.GetChannelCapability(channelA.PortID, channelA.ID) }, false}, {"next ack sequence not found", func() { - _, _, connA, connB := suite.coordinator.SetupClientConnections(suite.chainA, suite.chainB, ibctesting.Tendermint) + _, _, connA, connB := suite.coordinator.SetupClientConnections(suite.chainA, suite.chainB, exported.Tendermint) channelA := connA.NextTestChannel(ibctesting.TransferPort) channelB := connB.NextTestChannel(ibctesting.TransferPort) packet = types.NewPacket(validPacketData, 1, channelA.PortID, channelA.ID, channelB.PortID, channelB.ID, timeoutHeight, disabledTimeoutTimestamp) diff --git a/x/ibc/core/04-channel/keeper/timeout_test.go b/x/ibc/core/04-channel/keeper/timeout_test.go index 2ff497582..640452e88 100644 --- a/x/ibc/core/04-channel/keeper/timeout_test.go +++ b/x/ibc/core/04-channel/keeper/timeout_test.go @@ -29,7 +29,7 @@ func (suite *KeeperTestSuite) TestTimeoutPacket() { packet = types.NewPacket(validPacketData, 1, channelA.PortID, channelA.ID, channelB.PortID, channelB.ID, clienttypes.GetSelfHeight(suite.chainB.GetContext()), uint64(suite.chainB.GetContext().BlockTime().UnixNano())) suite.coordinator.SendPacket(suite.chainA, suite.chainB, packet, clientB) // need to update chainA's client representing chainB to prove missing ack - suite.coordinator.UpdateClient(suite.chainA, suite.chainB, clientA, ibctesting.Tendermint) + suite.coordinator.UpdateClient(suite.chainA, suite.chainB, clientA, exported.Tendermint) }, true}, {"success: UNORDERED", func() { ordered = false @@ -38,7 +38,7 @@ func (suite *KeeperTestSuite) TestTimeoutPacket() { packet = types.NewPacket(validPacketData, 1, channelA.PortID, channelA.ID, channelB.PortID, channelB.ID, clienttypes.GetSelfHeight(suite.chainB.GetContext()), disabledTimeoutTimestamp) suite.coordinator.SendPacket(suite.chainA, suite.chainB, packet, clientB) // need to update chainA's client representing chainB to prove missing ack - suite.coordinator.UpdateClient(suite.chainA, suite.chainB, clientA, ibctesting.Tendermint) + suite.coordinator.UpdateClient(suite.chainA, suite.chainB, clientA, exported.Tendermint) }, true}, {"channel not found", func() { // use wrong channel naming @@ -77,7 +77,7 @@ func (suite *KeeperTestSuite) TestTimeoutPacket() { clientA, clientB, _, _, channelA, channelB := suite.coordinator.Setup(suite.chainA, suite.chainB, types.ORDERED) packet = types.NewPacket(validPacketData, 1, channelA.PortID, channelA.ID, channelB.PortID, channelB.ID, timeoutHeight, disabledTimeoutTimestamp) suite.coordinator.SendPacket(suite.chainA, suite.chainB, packet, clientB) - suite.coordinator.UpdateClient(suite.chainA, suite.chainB, clientA, ibctesting.Tendermint) + suite.coordinator.UpdateClient(suite.chainA, suite.chainB, clientA, exported.Tendermint) }, false}, {"packet already received ", func() { ordered = true @@ -86,12 +86,12 @@ func (suite *KeeperTestSuite) TestTimeoutPacket() { clientA, clientB, _, _, channelA, channelB := suite.coordinator.Setup(suite.chainA, suite.chainB, types.ORDERED) packet = types.NewPacket(validPacketData, 1, channelA.PortID, channelA.ID, channelB.PortID, channelB.ID, timeoutHeight, uint64(suite.chainB.GetContext().BlockTime().UnixNano())) suite.coordinator.SendPacket(suite.chainA, suite.chainB, packet, clientB) - suite.coordinator.UpdateClient(suite.chainA, suite.chainB, clientA, ibctesting.Tendermint) + suite.coordinator.UpdateClient(suite.chainA, suite.chainB, clientA, exported.Tendermint) }, false}, {"packet hasn't been sent", func() { clientA, _, _, _, channelA, channelB := suite.coordinator.Setup(suite.chainA, suite.chainB, types.ORDERED) packet = types.NewPacket(validPacketData, 1, channelA.PortID, channelA.ID, channelB.PortID, channelB.ID, timeoutHeight, uint64(suite.chainB.GetContext().BlockTime().UnixNano())) - suite.coordinator.UpdateClient(suite.chainA, suite.chainB, clientA, ibctesting.Tendermint) + suite.coordinator.UpdateClient(suite.chainA, suite.chainB, clientA, exported.Tendermint) }, false}, {"next seq receive verification failed", func() { // set ordered to false resulting in wrong proof provided @@ -100,7 +100,7 @@ func (suite *KeeperTestSuite) TestTimeoutPacket() { clientA, clientB, _, _, channelA, channelB := suite.coordinator.Setup(suite.chainA, suite.chainB, types.ORDERED) packet = types.NewPacket(validPacketData, 1, channelA.PortID, channelA.ID, channelB.PortID, channelB.ID, clienttypes.GetSelfHeight(suite.chainB.GetContext()), disabledTimeoutTimestamp) suite.coordinator.SendPacket(suite.chainA, suite.chainB, packet, clientB) - suite.coordinator.UpdateClient(suite.chainA, suite.chainB, clientA, ibctesting.Tendermint) + suite.coordinator.UpdateClient(suite.chainA, suite.chainB, clientA, exported.Tendermint) }, false}, {"packet ack verification failed", func() { // set ordered to true resulting in wrong proof provided @@ -109,7 +109,7 @@ func (suite *KeeperTestSuite) TestTimeoutPacket() { clientA, clientB, _, _, channelA, channelB := suite.coordinator.Setup(suite.chainA, suite.chainB, types.UNORDERED) packet = types.NewPacket(validPacketData, 1, channelA.PortID, channelA.ID, channelB.PortID, channelB.ID, clienttypes.GetSelfHeight(suite.chainB.GetContext()), disabledTimeoutTimestamp) suite.coordinator.SendPacket(suite.chainA, suite.chainB, packet, clientB) - suite.coordinator.UpdateClient(suite.chainA, suite.chainB, clientA, ibctesting.Tendermint) + suite.coordinator.UpdateClient(suite.chainA, suite.chainB, clientA, exported.Tendermint) }, false}, } @@ -213,7 +213,7 @@ func (suite *KeeperTestSuite) TestTimeoutOnClose() { suite.coordinator.SendPacket(suite.chainA, suite.chainB, packet, clientB) suite.coordinator.SetChannelClosed(suite.chainB, suite.chainA, channelB) // need to update chainA's client representing chainB to prove missing ack - suite.coordinator.UpdateClient(suite.chainA, suite.chainB, clientA, ibctesting.Tendermint) + suite.coordinator.UpdateClient(suite.chainA, suite.chainB, clientA, exported.Tendermint) chanCap = suite.chainA.GetChannelCapability(channelA.PortID, channelA.ID) }, true}, @@ -224,7 +224,7 @@ func (suite *KeeperTestSuite) TestTimeoutOnClose() { suite.coordinator.SendPacket(suite.chainA, suite.chainB, packet, clientB) suite.coordinator.SetChannelClosed(suite.chainB, suite.chainA, channelB) // need to update chainA's client representing chainB to prove missing ack - suite.coordinator.UpdateClient(suite.chainA, suite.chainB, clientA, ibctesting.Tendermint) + suite.coordinator.UpdateClient(suite.chainA, suite.chainB, clientA, exported.Tendermint) chanCap = suite.chainA.GetChannelCapability(channelA.PortID, channelA.ID) }, true}, @@ -273,7 +273,7 @@ func (suite *KeeperTestSuite) TestTimeoutOnClose() { suite.coordinator.SendPacket(suite.chainA, suite.chainB, packet, clientB) suite.coordinator.SetChannelClosed(suite.chainB, suite.chainA, channelB) // need to update chainA's client representing chainB to prove missing ack - suite.coordinator.UpdateClient(suite.chainA, suite.chainB, clientA, ibctesting.Tendermint) + suite.coordinator.UpdateClient(suite.chainA, suite.chainB, clientA, exported.Tendermint) chanCap = suite.chainA.GetChannelCapability(channelA.PortID, channelA.ID) }, false}, @@ -291,7 +291,7 @@ func (suite *KeeperTestSuite) TestTimeoutOnClose() { packet = types.NewPacket(validPacketData, 1, channelA.PortID, channelA.ID, channelB.PortID, channelB.ID, clienttypes.GetSelfHeight(suite.chainB.GetContext()), uint64(suite.chainB.GetContext().BlockTime().UnixNano())) suite.coordinator.SendPacket(suite.chainA, suite.chainB, packet, clientB) suite.coordinator.SetChannelClosed(suite.chainB, suite.chainA, channelB) - suite.coordinator.UpdateClient(suite.chainA, suite.chainB, clientA, ibctesting.Tendermint) + suite.coordinator.UpdateClient(suite.chainA, suite.chainB, clientA, exported.Tendermint) chanCap = suite.chainA.GetChannelCapability(channelA.PortID, channelA.ID) }, false}, {"packet ack verification failed", func() { @@ -301,7 +301,7 @@ func (suite *KeeperTestSuite) TestTimeoutOnClose() { packet = types.NewPacket(validPacketData, 1, channelA.PortID, channelA.ID, channelB.PortID, channelB.ID, clienttypes.GetSelfHeight(suite.chainB.GetContext()), disabledTimeoutTimestamp) suite.coordinator.SendPacket(suite.chainA, suite.chainB, packet, clientB) suite.coordinator.SetChannelClosed(suite.chainB, suite.chainA, channelB) - suite.coordinator.UpdateClient(suite.chainA, suite.chainB, clientA, ibctesting.Tendermint) + suite.coordinator.UpdateClient(suite.chainA, suite.chainB, clientA, exported.Tendermint) chanCap = suite.chainA.GetChannelCapability(channelA.PortID, channelA.ID) }, false}, {"channel capability not found", func() { @@ -311,7 +311,7 @@ func (suite *KeeperTestSuite) TestTimeoutOnClose() { suite.coordinator.SendPacket(suite.chainA, suite.chainB, packet, clientB) suite.coordinator.SetChannelClosed(suite.chainB, suite.chainA, channelB) // need to update chainA's client representing chainB to prove missing ack - suite.coordinator.UpdateClient(suite.chainA, suite.chainB, clientA, ibctesting.Tendermint) + suite.coordinator.UpdateClient(suite.chainA, suite.chainB, clientA, exported.Tendermint) chanCap = capabilitytypes.NewCapability(100) }, false}, diff --git a/x/ibc/core/exported/client.go b/x/ibc/core/exported/client.go index e5b38a059..8c7e89b33 100644 --- a/x/ibc/core/exported/client.go +++ b/x/ibc/core/exported/client.go @@ -12,9 +12,15 @@ const ( // TypeClientMisbehaviour is the shared evidence misbehaviour type TypeClientMisbehaviour string = "client_misbehaviour" + // Solomachine is used to indicate that the light client is a solo machine. + Solomachine string = "06-solomachine" + + // Tendermint is used to indicate that the client uses the Tendermint Consensus Algorithm. + Tendermint string = "07-tendermint" + // Localhost is the client type for a localhost client. It is also used as the clientID // for the localhost client. - Localhost string = "localhost" + Localhost string = "09-localhost" ) // ClientState defines the required common functions for light clients. diff --git a/x/ibc/core/genesis_test.go b/x/ibc/core/genesis_test.go index d4cf1ec3a..5290c4789 100644 --- a/x/ibc/core/genesis_test.go +++ b/x/ibc/core/genesis_test.go @@ -96,6 +96,7 @@ func (suite *IBCTestSuite) TestValidateGenesis() { }, ), }, + clienttypes.NewParams(exported.Tendermint, exported.Localhost), true, ), ConnectionGenesis: connectiontypes.NewGenesisState( @@ -150,6 +151,7 @@ func (suite *IBCTestSuite) TestValidateGenesis() { ), }, nil, + clienttypes.NewParams(exported.Tendermint), false, ), ConnectionGenesis: connectiontypes.DefaultGenesisState(), @@ -233,6 +235,7 @@ func (suite *IBCTestSuite) TestInitGenesis() { }, ), }, + clienttypes.NewParams(exported.Tendermint, exported.Localhost), true, ), ConnectionGenesis: connectiontypes.NewGenesisState( @@ -295,8 +298,8 @@ func (suite *IBCTestSuite) TestExportGenesis() { // creates clients suite.coordinator.Setup(suite.chainA, suite.chainB, channeltypes.UNORDERED) // create extra clients - suite.coordinator.CreateClient(suite.chainA, suite.chainB, ibctesting.Tendermint) - suite.coordinator.CreateClient(suite.chainA, suite.chainB, ibctesting.Tendermint) + suite.coordinator.CreateClient(suite.chainA, suite.chainB, exported.Tendermint) + suite.coordinator.CreateClient(suite.chainA, suite.chainB, exported.Tendermint) }, }, } diff --git a/x/ibc/core/keeper/grpc_query.go b/x/ibc/core/keeper/grpc_query.go index e7dbe2610..f406d2e86 100644 --- a/x/ibc/core/keeper/grpc_query.go +++ b/x/ibc/core/keeper/grpc_query.go @@ -28,6 +28,11 @@ func (q Keeper) ConsensusStates(c context.Context, req *clienttypes.QueryConsens return q.ClientKeeper.ConsensusStates(c, req) } +// ClientParams implements the IBC QueryServer interface +func (q Keeper) ClientParams(c context.Context, req *clienttypes.QueryClientParamsRequest) (*clienttypes.QueryClientParamsResponse, error) { + return q.ClientKeeper.ClientParams(c, req) +} + // Connection implements the IBC QueryServer interface func (q Keeper) Connection(c context.Context, req *connectiontypes.QueryConnectionRequest) (*connectiontypes.QueryConnectionResponse, error) { return q.ConnectionKeeper.Connection(c, req) diff --git a/x/ibc/core/keeper/keeper.go b/x/ibc/core/keeper/keeper.go index e9b7a0f1e..5f9abc382 100644 --- a/x/ibc/core/keeper/keeper.go +++ b/x/ibc/core/keeper/keeper.go @@ -11,6 +11,7 @@ import ( portkeeper "github.com/cosmos/cosmos-sdk/x/ibc/core/05-port/keeper" porttypes "github.com/cosmos/cosmos-sdk/x/ibc/core/05-port/types" "github.com/cosmos/cosmos-sdk/x/ibc/core/types" + paramtypes "github.com/cosmos/cosmos-sdk/x/params/types" ) var _ types.QueryServer = (*Keeper)(nil) @@ -31,9 +32,10 @@ type Keeper struct { // NewKeeper creates a new ibc Keeper func NewKeeper( - cdc codec.BinaryMarshaler, key sdk.StoreKey, stakingKeeper clienttypes.StakingKeeper, scopedKeeper capabilitykeeper.ScopedKeeper, + cdc codec.BinaryMarshaler, key sdk.StoreKey, paramSpace paramtypes.Subspace, + stakingKeeper clienttypes.StakingKeeper, scopedKeeper capabilitykeeper.ScopedKeeper, ) *Keeper { - clientKeeper := clientkeeper.NewKeeper(cdc, key, stakingKeeper) + clientKeeper := clientkeeper.NewKeeper(cdc, key, paramSpace, stakingKeeper) connectionKeeper := connectionkeeper.NewKeeper(cdc, key, clientKeeper) portKeeper := portkeeper.NewKeeper(scopedKeeper) channelKeeper := channelkeeper.NewKeeper(cdc, key, clientKeeper, connectionKeeper, portKeeper, scopedKeeper) diff --git a/x/ibc/core/keeper/msg_server_test.go b/x/ibc/core/keeper/msg_server_test.go index 5c4aa466a..497a806ca 100644 --- a/x/ibc/core/keeper/msg_server_test.go +++ b/x/ibc/core/keeper/msg_server_test.go @@ -331,7 +331,7 @@ func (suite *KeeperTestSuite) TestHandleTimeoutPacket() { suite.Require().NoError(err) // need to update chainA client to prove missing ack - suite.coordinator.UpdateClient(suite.chainA, suite.chainB, clientA, ibctesting.Tendermint) + suite.coordinator.UpdateClient(suite.chainA, suite.chainB, clientA, exported.Tendermint) packetKey = host.NextSequenceRecvKey(packet.GetDestPort(), packet.GetDestChannel()) }, true}, @@ -344,7 +344,7 @@ func (suite *KeeperTestSuite) TestHandleTimeoutPacket() { suite.Require().NoError(err) // need to update chainA client to prove missing ack - suite.coordinator.UpdateClient(suite.chainA, suite.chainB, clientA, ibctesting.Tendermint) + suite.coordinator.UpdateClient(suite.chainA, suite.chainB, clientA, exported.Tendermint) packetKey = host.PacketReceiptKey(packet.GetDestPort(), packet.GetDestChannel(), packet.GetSequence()) }, true}, @@ -362,7 +362,7 @@ func (suite *KeeperTestSuite) TestHandleTimeoutPacket() { suite.Require().NoError(err) } - suite.coordinator.UpdateClient(suite.chainA, suite.chainB, clientA, ibctesting.Tendermint) + suite.coordinator.UpdateClient(suite.chainA, suite.chainB, clientA, exported.Tendermint) packetKey = host.PacketReceiptKey(packet.GetDestPort(), packet.GetDestChannel(), packet.GetSequence()) }, true}, {"success: ORDERED timeout out of order packet", func() { @@ -378,7 +378,7 @@ func (suite *KeeperTestSuite) TestHandleTimeoutPacket() { suite.Require().NoError(err) } - suite.coordinator.UpdateClient(suite.chainA, suite.chainB, clientA, ibctesting.Tendermint) + suite.coordinator.UpdateClient(suite.chainA, suite.chainB, clientA, exported.Tendermint) packetKey = host.NextSequenceRecvKey(packet.GetDestPort(), packet.GetDestChannel()) }, true}, @@ -458,7 +458,7 @@ func (suite *KeeperTestSuite) TestHandleTimeoutOnClosePacket() { suite.Require().NoError(err) // need to update chainA client to prove missing ack - suite.coordinator.UpdateClient(suite.chainA, suite.chainB, clientA, ibctesting.Tendermint) + suite.coordinator.UpdateClient(suite.chainA, suite.chainB, clientA, exported.Tendermint) packetKey = host.NextSequenceRecvKey(packet.GetDestPort(), packet.GetDestChannel()) @@ -479,7 +479,7 @@ func (suite *KeeperTestSuite) TestHandleTimeoutOnClosePacket() { suite.Require().NoError(err) // need to update chainA client to prove missing ack - suite.coordinator.UpdateClient(suite.chainA, suite.chainB, clientA, ibctesting.Tendermint) + suite.coordinator.UpdateClient(suite.chainA, suite.chainB, clientA, exported.Tendermint) packetKey = host.PacketReceiptKey(packet.GetDestPort(), packet.GetDestChannel(), packet.GetSequence()) @@ -505,7 +505,7 @@ func (suite *KeeperTestSuite) TestHandleTimeoutOnClosePacket() { suite.Require().NoError(err) } - suite.coordinator.UpdateClient(suite.chainA, suite.chainB, clientA, ibctesting.Tendermint) + suite.coordinator.UpdateClient(suite.chainA, suite.chainB, clientA, exported.Tendermint) packetKey = host.PacketReceiptKey(packet.GetDestPort(), packet.GetDestChannel(), packet.GetSequence()) // close counterparty channel @@ -529,7 +529,7 @@ func (suite *KeeperTestSuite) TestHandleTimeoutOnClosePacket() { suite.Require().NoError(err) } - suite.coordinator.UpdateClient(suite.chainA, suite.chainB, clientA, ibctesting.Tendermint) + suite.coordinator.UpdateClient(suite.chainA, suite.chainB, clientA, exported.Tendermint) packetKey = host.NextSequenceRecvKey(packet.GetDestPort(), packet.GetDestChannel()) // close counterparty channel @@ -568,7 +568,7 @@ func (suite *KeeperTestSuite) TestHandleTimeoutOnClosePacket() { suite.Require().NoError(err) // need to update chainA client to prove missing ack - suite.coordinator.UpdateClient(suite.chainA, suite.chainB, clientA, ibctesting.Tendermint) + suite.coordinator.UpdateClient(suite.chainA, suite.chainB, clientA, exported.Tendermint) packetKey = host.NextSequenceRecvKey(packet.GetDestPort(), packet.GetDestChannel()) }, false}, @@ -639,7 +639,7 @@ func (suite *KeeperTestSuite) TestUpgradeClient() { // commit upgrade store changes and update clients suite.coordinator.CommitBlock(suite.chainB) - err := suite.coordinator.UpdateClient(suite.chainA, suite.chainB, clientA, ibctesting.Tendermint) + err := suite.coordinator.UpdateClient(suite.chainA, suite.chainB, clientA, exported.Tendermint) suite.Require().NoError(err) cs, found := suite.chainA.App.IBCKeeper.ClientKeeper.GetClientState(suite.chainA.GetContext(), clientA) @@ -689,7 +689,7 @@ func (suite *KeeperTestSuite) TestUpgradeClient() { // commit upgrade store changes and update clients suite.coordinator.CommitBlock(suite.chainB) - err := suite.coordinator.UpdateClient(suite.chainA, suite.chainB, clientA, ibctesting.Tendermint) + err := suite.coordinator.UpdateClient(suite.chainA, suite.chainB, clientA, exported.Tendermint) suite.Require().NoError(err) msg, err = clienttypes.NewMsgUpgradeClient(clientA, upgradedClient, upgradeHeight, nil, suite.chainA.SenderAccount.GetAddress()) @@ -701,7 +701,7 @@ func (suite *KeeperTestSuite) TestUpgradeClient() { for _, tc := range cases { tc := tc - clientA, _ = suite.coordinator.SetupClients(suite.chainA, suite.chainB, ibctesting.Tendermint) + clientA, _ = suite.coordinator.SetupClients(suite.chainA, suite.chainB, exported.Tendermint) tc.setup() diff --git a/x/ibc/core/spec/07_params.md b/x/ibc/core/spec/07_params.md new file mode 100644 index 000000000..67e79ef81 --- /dev/null +++ b/x/ibc/core/spec/07_params.md @@ -0,0 +1,21 @@ + + +# Parameters + +## Clients + +The ibc clients contain the following parameters: + +| Key | Type | Default Value | +|------------------|------|---------------| +| `AllowedClients` | []string | `"06-solomachine","07-tendermint"` | + +### AllowedClients + +The allowed clients parameter defines an allowlist of client types supported by the chain. A client +that is not registered on this list will fail upon creation or on genesis validation. Note that, +since the client type is an arbitrary string, chains they must not register two light clients which +return the same value for the `ClientType()` function, otherwise the allowlist check can be +bypassed. diff --git a/x/ibc/core/spec/README.md b/x/ibc/core/spec/README.md index 0ae00bbcd..f6de9749b 100644 --- a/x/ibc/core/spec/README.md +++ b/x/ibc/core/spec/README.md @@ -23,3 +23,4 @@ For the general specification please refer to the [Interchain Standards](https:/ 4. **[Messages](04_messages.md)** 5. **[Callbacks](05_callbacks.md)** 6. **[Events](06_events.md)** +7. **[Params](07_params.md)** diff --git a/x/ibc/light-clients/06-solomachine/types/client_state.go b/x/ibc/light-clients/06-solomachine/types/client_state.go index 05ed359ba..34cb91964 100644 --- a/x/ibc/light-clients/06-solomachine/types/client_state.go +++ b/x/ibc/light-clients/06-solomachine/types/client_state.go @@ -16,9 +16,6 @@ import ( var _ exported.ClientState = (*ClientState)(nil) -// SoloMachine is used to indicate that the light client is a solo machine. -const SoloMachine string = "Solo Machine" - // NewClientState creates a new ClientState instance. func NewClientState(latestSequence uint64, consensusState *ConsensusState, allowUpdateAfterProposal bool) *ClientState { return &ClientState{ @@ -31,7 +28,7 @@ func NewClientState(latestSequence uint64, consensusState *ConsensusState, allow // ClientType is Solo Machine. func (cs ClientState) ClientType() string { - return SoloMachine + return exported.Solomachine } // GetLatestHeight returns the latest sequence number. diff --git a/x/ibc/light-clients/06-solomachine/types/client_state_test.go b/x/ibc/light-clients/06-solomachine/types/client_state_test.go index f2daca5ae..597adff34 100644 --- a/x/ibc/light-clients/06-solomachine/types/client_state_test.go +++ b/x/ibc/light-clients/06-solomachine/types/client_state_test.go @@ -82,7 +82,7 @@ func (suite *SoloMachineTestSuite) TestClientStateValidateBasic() { func (suite *SoloMachineTestSuite) TestVerifyClientState() { // create client for tendermint so we can use client state for verification - clientA, _ := suite.coordinator.SetupClients(suite.chainA, suite.chainB, ibctesting.Tendermint) + clientA, _ := suite.coordinator.SetupClients(suite.chainA, suite.chainB, exported.Tendermint) clientState := suite.chainA.GetClientState(clientA) path := suite.solomachine.GetClientStatePath(counterpartyClientIdentifier) @@ -208,7 +208,7 @@ func (suite *SoloMachineTestSuite) TestVerifyClientState() { func (suite *SoloMachineTestSuite) TestVerifyClientConsensusState() { // create client for tendermint so we can use consensus state for verification - clientA, _ := suite.coordinator.SetupClients(suite.chainA, suite.chainB, ibctesting.Tendermint) + clientA, _ := suite.coordinator.SetupClients(suite.chainA, suite.chainB, exported.Tendermint) clientState := suite.chainA.GetClientState(clientA) consensusState, found := suite.chainA.GetConsensusState(clientA, clientState.GetLatestHeight()) suite.Require().True(found) diff --git a/x/ibc/light-clients/06-solomachine/types/consensus_state.go b/x/ibc/light-clients/06-solomachine/types/consensus_state.go index cebd399ff..1cc95caf0 100644 --- a/x/ibc/light-clients/06-solomachine/types/consensus_state.go +++ b/x/ibc/light-clients/06-solomachine/types/consensus_state.go @@ -13,7 +13,7 @@ var _ exported.ConsensusState = ConsensusState{} // ClientType returns Solo Machine type. func (ConsensusState) ClientType() string { - return SoloMachine + return exported.Solomachine } // GetTimestamp returns zero. diff --git a/x/ibc/light-clients/06-solomachine/types/consensus_state_test.go b/x/ibc/light-clients/06-solomachine/types/consensus_state_test.go index 820e81246..e0c22f959 100644 --- a/x/ibc/light-clients/06-solomachine/types/consensus_state_test.go +++ b/x/ibc/light-clients/06-solomachine/types/consensus_state_test.go @@ -1,6 +1,7 @@ package types_test import ( + "github.com/cosmos/cosmos-sdk/x/ibc/core/exported" "github.com/cosmos/cosmos-sdk/x/ibc/light-clients/06-solomachine/types" ibctesting "github.com/cosmos/cosmos-sdk/x/ibc/testing" ) @@ -8,7 +9,7 @@ import ( func (suite *SoloMachineTestSuite) TestConsensusState() { consensusState := suite.solomachine.ConsensusState() - suite.Require().Equal(types.SoloMachine, consensusState.ClientType()) + suite.Require().Equal(exported.Solomachine, consensusState.ClientType()) suite.Require().Equal(suite.solomachine.Time, consensusState.GetTimestamp()) suite.Require().Nil(consensusState.GetRoot()) } diff --git a/x/ibc/light-clients/06-solomachine/types/header.go b/x/ibc/light-clients/06-solomachine/types/header.go index cb2b55b4f..dc43cee4f 100644 --- a/x/ibc/light-clients/06-solomachine/types/header.go +++ b/x/ibc/light-clients/06-solomachine/types/header.go @@ -13,7 +13,7 @@ var _ exported.Header = Header{} // ClientType defines that the Header is a Solo Machine. func (Header) ClientType() string { - return SoloMachine + return exported.Solomachine } // GetHeight returns the current sequence number as the height. diff --git a/x/ibc/light-clients/06-solomachine/types/header_test.go b/x/ibc/light-clients/06-solomachine/types/header_test.go index e456f9e96..a5ca45e8a 100644 --- a/x/ibc/light-clients/06-solomachine/types/header_test.go +++ b/x/ibc/light-clients/06-solomachine/types/header_test.go @@ -1,6 +1,7 @@ package types_test import ( + "github.com/cosmos/cosmos-sdk/x/ibc/core/exported" "github.com/cosmos/cosmos-sdk/x/ibc/light-clients/06-solomachine/types" ibctesting "github.com/cosmos/cosmos-sdk/x/ibc/testing" ) @@ -78,7 +79,7 @@ func (suite *SoloMachineTestSuite) TestHeaderValidateBasic() { }, } - suite.Require().Equal(types.SoloMachine, header.ClientType()) + suite.Require().Equal(exported.Solomachine, header.ClientType()) for _, tc := range cases { tc := tc diff --git a/x/ibc/light-clients/06-solomachine/types/misbehaviour.go b/x/ibc/light-clients/06-solomachine/types/misbehaviour.go index 1f97f323c..66ee6d939 100644 --- a/x/ibc/light-clients/06-solomachine/types/misbehaviour.go +++ b/x/ibc/light-clients/06-solomachine/types/misbehaviour.go @@ -17,7 +17,7 @@ var ( // ClientType is a Solo Machine light client. func (misbehaviour Misbehaviour) ClientType() string { - return SoloMachine + return exported.Solomachine } // GetClientID returns the ID of the client that committed a misbehaviour. diff --git a/x/ibc/light-clients/06-solomachine/types/misbehaviour_test.go b/x/ibc/light-clients/06-solomachine/types/misbehaviour_test.go index 311dc8d8c..a976186ea 100644 --- a/x/ibc/light-clients/06-solomachine/types/misbehaviour_test.go +++ b/x/ibc/light-clients/06-solomachine/types/misbehaviour_test.go @@ -1,6 +1,7 @@ package types_test import ( + "github.com/cosmos/cosmos-sdk/x/ibc/core/exported" "github.com/cosmos/cosmos-sdk/x/ibc/light-clients/06-solomachine/types" ibctesting "github.com/cosmos/cosmos-sdk/x/ibc/testing" ) @@ -8,7 +9,7 @@ import ( func (suite *SoloMachineTestSuite) TestMisbehaviour() { misbehaviour := suite.solomachine.CreateMisbehaviour() - suite.Require().Equal(types.SoloMachine, misbehaviour.ClientType()) + suite.Require().Equal(exported.Solomachine, misbehaviour.ClientType()) suite.Require().Equal(suite.solomachine.ClientID, misbehaviour.GetClientID()) suite.Require().Equal(uint64(0), misbehaviour.GetHeight().GetVersionNumber()) suite.Require().Equal(suite.solomachine.Sequence, misbehaviour.GetHeight().GetVersionHeight()) diff --git a/x/ibc/light-clients/06-solomachine/types/solomachine_test.go b/x/ibc/light-clients/06-solomachine/types/solomachine_test.go index 53f5c4a48..b3b647d82 100644 --- a/x/ibc/light-clients/06-solomachine/types/solomachine_test.go +++ b/x/ibc/light-clients/06-solomachine/types/solomachine_test.go @@ -41,7 +41,7 @@ func (suite *SoloMachineTestSuite) SetupTest() { suite.solomachine = ibctesting.NewSolomachine(suite.T(), suite.chainA.Codec, "solomachinesingle", "testing", 1) suite.solomachineMulti = ibctesting.NewSolomachine(suite.T(), suite.chainA.Codec, "solomachinemulti", "testing", 4) - suite.store = suite.chainA.App.IBCKeeper.ClientKeeper.ClientStore(suite.chainA.GetContext(), types.SoloMachine) + suite.store = suite.chainA.App.IBCKeeper.ClientKeeper.ClientStore(suite.chainA.GetContext(), exported.Solomachine) } func TestSoloMachineTestSuite(t *testing.T) { diff --git a/x/ibc/light-clients/07-tendermint/types/client_state.go b/x/ibc/light-clients/07-tendermint/types/client_state.go index 3940d44b7..680730446 100644 --- a/x/ibc/light-clients/07-tendermint/types/client_state.go +++ b/x/ibc/light-clients/07-tendermint/types/client_state.go @@ -22,9 +22,6 @@ import ( var _ exported.ClientState = (*ClientState)(nil) -// Tendermint is used to indicate that the client uses the Tendermint Consensus Algorithm. -const Tendermint string = "Tendermint" - // NewClientState creates a new ClientState instance func NewClientState( chainID string, trustLevel Fraction, @@ -55,7 +52,7 @@ func (cs ClientState) GetChainID() string { // ClientType is tendermint. func (cs ClientState) ClientType() string { - return Tendermint + return exported.Tendermint } // GetLatestHeight returns latest block height. diff --git a/x/ibc/light-clients/07-tendermint/types/client_state_test.go b/x/ibc/light-clients/07-tendermint/types/client_state_test.go index 90ff6767f..dc662da8f 100644 --- a/x/ibc/light-clients/07-tendermint/types/client_state_test.go +++ b/x/ibc/light-clients/07-tendermint/types/client_state_test.go @@ -554,7 +554,7 @@ func (suite *TendermintTestSuite) TestVerifyPacketReceiptAbsence() { suite.Require().NoError(err) // need to update chainA's client representing chainB to prove missing ack - suite.coordinator.UpdateClient(suite.chainA, suite.chainB, clientA, ibctesting.Tendermint) + suite.coordinator.UpdateClient(suite.chainA, suite.chainB, clientA, exported.Tendermint) var ok bool clientStateI := suite.chainA.GetClientState(clientA) @@ -645,7 +645,7 @@ func (suite *TendermintTestSuite) TestVerifyNextSeqRecv() { suite.Require().NoError(err) // need to update chainA's client representing chainB - suite.coordinator.UpdateClient(suite.chainA, suite.chainB, clientA, ibctesting.Tendermint) + suite.coordinator.UpdateClient(suite.chainA, suite.chainB, clientA, exported.Tendermint) var ok bool clientStateI := suite.chainA.GetClientState(clientA) diff --git a/x/ibc/light-clients/07-tendermint/types/consensus_state.go b/x/ibc/light-clients/07-tendermint/types/consensus_state.go index 0a8981281..d55bc1130 100644 --- a/x/ibc/light-clients/07-tendermint/types/consensus_state.go +++ b/x/ibc/light-clients/07-tendermint/types/consensus_state.go @@ -26,7 +26,7 @@ func NewConsensusState( // ClientType returns Tendermint func (ConsensusState) ClientType() string { - return Tendermint + return exported.Tendermint } // GetRoot returns the commitment Root for the specific diff --git a/x/ibc/light-clients/07-tendermint/types/consensus_state_test.go b/x/ibc/light-clients/07-tendermint/types/consensus_state_test.go index a3a8b154a..313815d0c 100644 --- a/x/ibc/light-clients/07-tendermint/types/consensus_state_test.go +++ b/x/ibc/light-clients/07-tendermint/types/consensus_state_test.go @@ -4,6 +4,7 @@ import ( "time" commitmenttypes "github.com/cosmos/cosmos-sdk/x/ibc/core/23-commitment/types" + "github.com/cosmos/cosmos-sdk/x/ibc/core/exported" "github.com/cosmos/cosmos-sdk/x/ibc/light-clients/07-tendermint/types" ) @@ -54,13 +55,15 @@ func (suite *TendermintTestSuite) TestConsensusStateValidateBasic() { for i, tc := range testCases { tc := tc - suite.Require().Equal(tc.consensusState.ClientType(), types.Tendermint) + // check just to increase coverage + suite.Require().Equal(exported.Tendermint, tc.consensusState.ClientType()) suite.Require().Equal(tc.consensusState.GetRoot(), tc.consensusState.Root) + err := tc.consensusState.ValidateBasic() if tc.expectPass { - suite.Require().NoError(tc.consensusState.ValidateBasic(), "valid test case %d failed: %s", i, tc.msg) + suite.Require().NoError(err, "valid test case %d failed: %s", i, tc.msg) } else { - suite.Require().Error(tc.consensusState.ValidateBasic(), "invalid test case %d passed: %s", i, tc.msg) + suite.Require().Error(err, "invalid test case %d passed: %s", i, tc.msg) } } } diff --git a/x/ibc/light-clients/07-tendermint/types/header.go b/x/ibc/light-clients/07-tendermint/types/header.go index 86e166caf..e128abea1 100644 --- a/x/ibc/light-clients/07-tendermint/types/header.go +++ b/x/ibc/light-clients/07-tendermint/types/header.go @@ -25,7 +25,7 @@ func (h Header) ConsensusState() *ConsensusState { // ClientType defines that the Header is a Tendermint consensus algorithm func (h Header) ClientType() string { - return Tendermint + return exported.Tendermint } // GetHeight returns the current height. It returns 0 if the tendermint diff --git a/x/ibc/light-clients/07-tendermint/types/header_test.go b/x/ibc/light-clients/07-tendermint/types/header_test.go index 235e1f758..cda3047be 100644 --- a/x/ibc/light-clients/07-tendermint/types/header_test.go +++ b/x/ibc/light-clients/07-tendermint/types/header_test.go @@ -6,6 +6,7 @@ import ( tmprotocrypto "github.com/tendermint/tendermint/proto/tendermint/crypto" clienttypes "github.com/cosmos/cosmos-sdk/x/ibc/core/02-client/types" + "github.com/cosmos/cosmos-sdk/x/ibc/core/exported" "github.com/cosmos/cosmos-sdk/x/ibc/light-clients/07-tendermint/types" ) @@ -63,7 +64,7 @@ func (suite *TendermintTestSuite) TestHeaderValidateBasic() { }, false}, } - suite.Require().Equal(types.Tendermint, suite.header.ClientType()) + suite.Require().Equal(exported.Tendermint, suite.header.ClientType()) for _, tc := range testCases { tc := tc diff --git a/x/ibc/light-clients/07-tendermint/types/misbehaviour.go b/x/ibc/light-clients/07-tendermint/types/misbehaviour.go index b1277110a..c090ecb0b 100644 --- a/x/ibc/light-clients/07-tendermint/types/misbehaviour.go +++ b/x/ibc/light-clients/07-tendermint/types/misbehaviour.go @@ -27,12 +27,11 @@ func NewMisbehaviour(clientID, chainID string, header1, header2 *Header) *Misbeh Header1: header1, Header2: header2, } - } // ClientType is Tendermint light client func (misbehaviour Misbehaviour) ClientType() string { - return Tendermint + return exported.Tendermint } // GetClientID returns the ID of the client that committed a misbehaviour. diff --git a/x/ibc/light-clients/07-tendermint/types/misbehaviour_test.go b/x/ibc/light-clients/07-tendermint/types/misbehaviour_test.go index 6f70c4b71..9d7cddff5 100644 --- a/x/ibc/light-clients/07-tendermint/types/misbehaviour_test.go +++ b/x/ibc/light-clients/07-tendermint/types/misbehaviour_test.go @@ -8,6 +8,7 @@ import ( tmtypes "github.com/tendermint/tendermint/types" clienttypes "github.com/cosmos/cosmos-sdk/x/ibc/core/02-client/types" + "github.com/cosmos/cosmos-sdk/x/ibc/core/exported" "github.com/cosmos/cosmos-sdk/x/ibc/light-clients/07-tendermint/types" ibctesting "github.com/cosmos/cosmos-sdk/x/ibc/testing" ibctestingmock "github.com/cosmos/cosmos-sdk/x/ibc/testing/mock" @@ -24,7 +25,7 @@ func (suite *TendermintTestSuite) TestMisbehaviour() { ClientId: clientID, } - suite.Require().Equal(types.Tendermint, misbehaviour.ClientType()) + suite.Require().Equal(exported.Tendermint, misbehaviour.ClientType()) suite.Require().Equal(clientID, misbehaviour.GetClientID()) suite.Require().Equal(height, misbehaviour.GetHeight()) } diff --git a/x/ibc/light-clients/07-tendermint/types/proposal_handle_test.go b/x/ibc/light-clients/07-tendermint/types/proposal_handle_test.go index 33c10854e..062a29a0d 100644 --- a/x/ibc/light-clients/07-tendermint/types/proposal_handle_test.go +++ b/x/ibc/light-clients/07-tendermint/types/proposal_handle_test.go @@ -2,6 +2,7 @@ package types_test import ( clienttypes "github.com/cosmos/cosmos-sdk/x/ibc/core/02-client/types" + "github.com/cosmos/cosmos-sdk/x/ibc/core/exported" "github.com/cosmos/cosmos-sdk/x/ibc/light-clients/07-tendermint/types" ibctesting "github.com/cosmos/cosmos-sdk/x/ibc/testing" ) @@ -12,7 +13,7 @@ var ( // sanity checks func (suite *TendermintTestSuite) TestCheckProposedHeaderAndUpdateStateBasic() { - clientA, _ := suite.coordinator.SetupClients(suite.chainA, suite.chainB, ibctesting.Tendermint) + clientA, _ := suite.coordinator.SetupClients(suite.chainA, suite.chainB, exported.Tendermint) clientState := suite.chainA.GetClientState(clientA).(*types.ClientState) clientStore := suite.chainA.App.IBCKeeper.ClientKeeper.ClientStore(suite.chainA.GetContext(), clientA) @@ -201,7 +202,7 @@ func (suite *TendermintTestSuite) TestCheckProposedHeaderAndUpdateState() { suite.SetupTest() // reset // construct client state based on test case parameters - clientA, _ := suite.coordinator.SetupClients(suite.chainA, suite.chainB, ibctesting.Tendermint) + clientA, _ := suite.coordinator.SetupClients(suite.chainA, suite.chainB, exported.Tendermint) clientState := suite.chainA.GetClientState(clientA).(*types.ClientState) clientState.AllowUpdateAfterExpiry = tc.AllowUpdateAfterExpiry clientState.AllowUpdateAfterMisbehaviour = tc.AllowUpdateAfterMisbehaviour @@ -319,7 +320,7 @@ func (suite *TendermintTestSuite) TestCheckProposedHeader() { suite.Run(tc.name, func() { suite.SetupTest() // reset - clientA, _ = suite.coordinator.SetupClients(suite.chainA, suite.chainB, ibctesting.Tendermint) + clientA, _ = suite.coordinator.SetupClients(suite.chainA, suite.chainB, exported.Tendermint) clientState = suite.chainA.GetClientState(clientA).(*types.ClientState) clientState.AllowUpdateAfterExpiry = true clientState.AllowUpdateAfterMisbehaviour = false diff --git a/x/ibc/light-clients/07-tendermint/types/upgrade_test.go b/x/ibc/light-clients/07-tendermint/types/upgrade_test.go index f5debb01a..bb2108508 100644 --- a/x/ibc/light-clients/07-tendermint/types/upgrade_test.go +++ b/x/ibc/light-clients/07-tendermint/types/upgrade_test.go @@ -37,7 +37,7 @@ func (suite *TendermintTestSuite) TestVerifyUpgrade() { // commit upgrade store changes and update clients suite.coordinator.CommitBlock(suite.chainB) - err := suite.coordinator.UpdateClient(suite.chainA, suite.chainB, clientA, ibctesting.Tendermint) + err := suite.coordinator.UpdateClient(suite.chainA, suite.chainB, clientA, exported.Tendermint) suite.Require().NoError(err) cs, found := suite.chainA.App.IBCKeeper.ClientKeeper.GetClientState(suite.chainA.GetContext(), clientA) @@ -63,7 +63,7 @@ func (suite *TendermintTestSuite) TestVerifyUpgrade() { upgradedClient = types.NewClientState("newChainId", types.DefaultTrustLevel, ubdPeriod, ubdPeriod+trustingPeriod, maxClockDrift+5, newClientHeight, ibctesting.DefaultConsensusParams, commitmenttypes.GetSDKSpecs(), upgradePath, true, false) suite.coordinator.CommitBlock(suite.chainB) - err := suite.coordinator.UpdateClient(suite.chainA, suite.chainB, clientA, ibctesting.Tendermint) + err := suite.coordinator.UpdateClient(suite.chainA, suite.chainB, clientA, exported.Tendermint) suite.Require().NoError(err) cs, found := suite.chainA.App.IBCKeeper.ClientKeeper.GetClientState(suite.chainA.GetContext(), clientA) @@ -93,7 +93,7 @@ func (suite *TendermintTestSuite) TestVerifyUpgrade() { // commit upgrade store changes and update clients suite.coordinator.CommitBlock(suite.chainB) - err := suite.coordinator.UpdateClient(suite.chainA, suite.chainB, clientA, ibctesting.Tendermint) + err := suite.coordinator.UpdateClient(suite.chainA, suite.chainB, clientA, exported.Tendermint) suite.Require().NoError(err) cs, found := suite.chainA.App.IBCKeeper.ClientKeeper.GetClientState(suite.chainA.GetContext(), clientA) @@ -119,7 +119,7 @@ func (suite *TendermintTestSuite) TestVerifyUpgrade() { upgradedClient = types.NewClientState("wrongchainID", types.DefaultTrustLevel, trustingPeriod, ubdPeriod, maxClockDrift, newClientHeight, ibctesting.DefaultConsensusParams, commitmenttypes.GetSDKSpecs(), upgradePath, true, true) suite.coordinator.CommitBlock(suite.chainB) - err := suite.coordinator.UpdateClient(suite.chainA, suite.chainB, clientA, ibctesting.Tendermint) + err := suite.coordinator.UpdateClient(suite.chainA, suite.chainB, clientA, exported.Tendermint) suite.Require().NoError(err) cs, found := suite.chainA.App.IBCKeeper.ClientKeeper.GetClientState(suite.chainA.GetContext(), clientA) @@ -141,7 +141,7 @@ func (suite *TendermintTestSuite) TestVerifyUpgrade() { upgradedClient = types.NewClientState("newChainId", types.DefaultTrustLevel, ubdPeriod, ubdPeriod+trustingPeriod, maxClockDrift+5, upgradeHeight, ibctesting.DefaultConsensusParams, commitmenttypes.GetSDKSpecs(), upgradePath, true, false) suite.coordinator.CommitBlock(suite.chainB) - err := suite.coordinator.UpdateClient(suite.chainA, suite.chainB, clientA, ibctesting.Tendermint) + err := suite.coordinator.UpdateClient(suite.chainA, suite.chainB, clientA, exported.Tendermint) suite.Require().NoError(err) cs, found := suite.chainA.App.IBCKeeper.ClientKeeper.GetClientState(suite.chainA.GetContext(), clientA) @@ -198,7 +198,7 @@ func (suite *TendermintTestSuite) TestVerifyUpgrade() { // commit upgrade store changes and update clients suite.coordinator.CommitBlock(suite.chainB) - err := suite.coordinator.UpdateClient(suite.chainA, suite.chainB, clientA, ibctesting.Tendermint) + err := suite.coordinator.UpdateClient(suite.chainA, suite.chainB, clientA, exported.Tendermint) suite.Require().NoError(err) cs, found := suite.chainA.App.IBCKeeper.ClientKeeper.GetClientState(suite.chainA.GetContext(), clientA) @@ -228,7 +228,7 @@ func (suite *TendermintTestSuite) TestVerifyUpgrade() { // commit upgrade store changes and update clients suite.coordinator.CommitBlock(suite.chainB) - err := suite.coordinator.UpdateClient(suite.chainA, suite.chainB, clientA, ibctesting.Tendermint) + err := suite.coordinator.UpdateClient(suite.chainA, suite.chainB, clientA, exported.Tendermint) suite.Require().NoError(err) cs, found := suite.chainA.App.IBCKeeper.ClientKeeper.GetClientState(suite.chainA.GetContext(), clientA) @@ -258,7 +258,7 @@ func (suite *TendermintTestSuite) TestVerifyUpgrade() { // commit upgrade store changes and update clients suite.coordinator.CommitBlock(suite.chainB) - err := suite.coordinator.UpdateClient(suite.chainA, suite.chainB, clientA, ibctesting.Tendermint) + err := suite.coordinator.UpdateClient(suite.chainA, suite.chainB, clientA, exported.Tendermint) suite.Require().NoError(err) cs, found := suite.chainA.App.IBCKeeper.ClientKeeper.GetClientState(suite.chainA.GetContext(), clientA) @@ -283,7 +283,7 @@ func (suite *TendermintTestSuite) TestVerifyUpgrade() { // commit upgrade store changes and update clients suite.coordinator.CommitBlock(suite.chainB) - err := suite.coordinator.UpdateClient(suite.chainA, suite.chainB, clientA, ibctesting.Tendermint) + err := suite.coordinator.UpdateClient(suite.chainA, suite.chainB, clientA, exported.Tendermint) suite.Require().NoError(err) cs, found := suite.chainA.App.IBCKeeper.ClientKeeper.GetClientState(suite.chainA.GetContext(), clientA) @@ -304,7 +304,7 @@ func (suite *TendermintTestSuite) TestVerifyUpgrade() { // commit upgrade store changes and update clients suite.coordinator.CommitBlock(suite.chainB) - err := suite.coordinator.UpdateClient(suite.chainA, suite.chainB, clientA, ibctesting.Tendermint) + err := suite.coordinator.UpdateClient(suite.chainA, suite.chainB, clientA, exported.Tendermint) suite.Require().NoError(err) // expire chainB's client @@ -325,7 +325,7 @@ func (suite *TendermintTestSuite) TestVerifyUpgrade() { // reset suite suite.SetupTest() - clientA, _ = suite.coordinator.SetupClients(suite.chainA, suite.chainB, ibctesting.Tendermint) + clientA, _ = suite.coordinator.SetupClients(suite.chainA, suite.chainB, exported.Tendermint) tc.setup() diff --git a/x/ibc/testing/chain.go b/x/ibc/testing/chain.go index 5886695ef..bba056f45 100644 --- a/x/ibc/testing/chain.go +++ b/x/ibc/testing/chain.go @@ -33,7 +33,6 @@ import ( host "github.com/cosmos/cosmos-sdk/x/ibc/core/24-host" "github.com/cosmos/cosmos-sdk/x/ibc/core/exported" "github.com/cosmos/cosmos-sdk/x/ibc/core/types" - solomachinetypes "github.com/cosmos/cosmos-sdk/x/ibc/light-clients/06-solomachine/types" ibctmtypes "github.com/cosmos/cosmos-sdk/x/ibc/light-clients/07-tendermint/types" "github.com/cosmos/cosmos-sdk/x/ibc/testing/mock" "github.com/cosmos/cosmos-sdk/x/staking/teststaking" @@ -41,10 +40,6 @@ import ( ) const ( - // client types - Tendermint = ibctmtypes.Tendermint - SoloMachine = solomachinetypes.SoloMachine - // Default params constants used to create a TM client TrustingPeriod time.Duration = time.Hour * 24 * 7 * 2 UnbondingPeriod time.Duration = time.Hour * 24 * 7 * 3 @@ -432,7 +427,7 @@ func (chain *TestChain) ConstructMsgCreateClient(counterparty *TestChain, client ) switch clientType { - case Tendermint: + case exported.Tendermint: height := counterparty.LastHeader.GetHeight().(clienttypes.Height) clientState = ibctmtypes.NewClientState( counterparty.ChainID, DefaultTrustLevel, TrustingPeriod, UnbondingPeriod, MaxClockDrift, @@ -440,7 +435,7 @@ func (chain *TestChain) ConstructMsgCreateClient(counterparty *TestChain, client UpgradePath, false, false, ) consensusState = counterparty.LastHeader.ConsensusState() - case SoloMachine: + case exported.Solomachine: solo := NewSolomachine(chain.t, chain.Codec, clientID, "", 1) clientState = solo.ClientState() consensusState = solo.ConsensusState() @@ -459,7 +454,7 @@ func (chain *TestChain) ConstructMsgCreateClient(counterparty *TestChain, client // client will be created on the (target) chain. func (chain *TestChain) CreateTMClient(counterparty *TestChain, clientID string) error { // construct MsgCreateClient using counterparty - msg := chain.ConstructMsgCreateClient(counterparty, clientID, Tendermint) + msg := chain.ConstructMsgCreateClient(counterparty, clientID, exported.Tendermint) return chain.sendMsgs(msg) } diff --git a/x/ibc/testing/coordinator.go b/x/ibc/testing/coordinator.go index ce5c8607f..b1c6e99d3 100644 --- a/x/ibc/testing/coordinator.go +++ b/x/ibc/testing/coordinator.go @@ -49,7 +49,7 @@ func NewCoordinator(t *testing.T, n int) *Coordinator { func (coord *Coordinator) Setup( chainA, chainB *TestChain, order channeltypes.Order, ) (string, string, *TestConnection, *TestConnection, TestChannel, TestChannel) { - clientA, clientB, connA, connB := coord.SetupClientConnections(chainA, chainB, Tendermint) + clientA, clientB, connA, connB := coord.SetupClientConnections(chainA, chainB, exported.Tendermint) // channels can also be referenced through the returned connections channelA, channelB := coord.CreateMockChannels(chainA, chainB, connA, connB, order) @@ -98,7 +98,7 @@ func (coord *Coordinator) CreateClient( clientID = source.NewClientID(counterparty.ChainID) switch clientType { - case Tendermint: + case exported.Tendermint: err = source.CreateTMClient(counterparty, clientID) default: @@ -123,7 +123,7 @@ func (coord *Coordinator) UpdateClient( coord.CommitBlock(source, counterparty) switch clientType { - case Tendermint: + case exported.Tendermint: err = source.UpdateTMClient(counterparty, clientID) default: @@ -226,7 +226,7 @@ func (coord *Coordinator) SendPacket( // update source client on counterparty connection return coord.UpdateClient( counterparty, source, - counterpartyClientID, Tendermint, + counterpartyClientID, exported.Tendermint, ) } @@ -262,7 +262,7 @@ func (coord *Coordinator) WriteAcknowledgement( // update source client on counterparty connection return coord.UpdateClient( counterparty, source, - counterpartyClientID, Tendermint, + counterpartyClientID, exported.Tendermint, ) } @@ -327,7 +327,7 @@ func (coord *Coordinator) SendMsgs(source, counterparty *TestChain, counterparty // update source client on counterparty connection return coord.UpdateClient( counterparty, source, - counterpartyClientID, Tendermint, + counterpartyClientID, exported.Tendermint, ) } @@ -386,7 +386,7 @@ func (coord *Coordinator) ConnOpenInit( // update source client on counterparty connection if err := coord.UpdateClient( counterparty, source, - counterpartyClientID, Tendermint, + counterpartyClientID, exported.Tendermint, ); err != nil { return sourceConnection, counterpartyConnection, err } @@ -409,7 +409,7 @@ func (coord *Coordinator) ConnOpenTry( // update source client on counterparty connection return coord.UpdateClient( counterparty, source, - counterpartyConnection.ClientID, Tendermint, + counterpartyConnection.ClientID, exported.Tendermint, ) } @@ -428,7 +428,7 @@ func (coord *Coordinator) ConnOpenAck( // update source client on counterparty connection return coord.UpdateClient( counterparty, source, - counterpartyConnection.ClientID, Tendermint, + counterpartyConnection.ClientID, exported.Tendermint, ) } @@ -446,7 +446,7 @@ func (coord *Coordinator) ConnOpenConfirm( // update source client on counterparty connection return coord.UpdateClient( counterparty, source, - counterpartyConnection.ClientID, Tendermint, + counterpartyConnection.ClientID, exported.Tendermint, ) } @@ -478,7 +478,7 @@ func (coord *Coordinator) ChanOpenInit( // update source client on counterparty connection if err := coord.UpdateClient( counterparty, source, - counterpartyConnection.ClientID, Tendermint, + counterpartyConnection.ClientID, exported.Tendermint, ); err != nil { return sourceChannel, counterpartyChannel, err } @@ -518,7 +518,7 @@ func (coord *Coordinator) ChanOpenInitOnBothChains( // update counterparty client on source connection if err := coord.UpdateClient( source, counterparty, - connection.ClientID, Tendermint, + connection.ClientID, exported.Tendermint, ); err != nil { return sourceChannel, counterpartyChannel, err } @@ -526,7 +526,7 @@ func (coord *Coordinator) ChanOpenInitOnBothChains( // update source client on counterparty connection if err := coord.UpdateClient( counterparty, source, - counterpartyConnection.ClientID, Tendermint, + counterpartyConnection.ClientID, exported.Tendermint, ); err != nil { return sourceChannel, counterpartyChannel, err } @@ -552,7 +552,7 @@ func (coord *Coordinator) ChanOpenTry( // update source client on counterparty connection return coord.UpdateClient( counterparty, source, - connection.CounterpartyClientID, Tendermint, + connection.CounterpartyClientID, exported.Tendermint, ) } @@ -571,7 +571,7 @@ func (coord *Coordinator) ChanOpenAck( // update source client on counterparty connection return coord.UpdateClient( counterparty, source, - sourceChannel.CounterpartyClientID, Tendermint, + sourceChannel.CounterpartyClientID, exported.Tendermint, ) } @@ -590,7 +590,7 @@ func (coord *Coordinator) ChanOpenConfirm( // update source client on counterparty connection return coord.UpdateClient( counterparty, source, - sourceChannel.CounterpartyClientID, Tendermint, + sourceChannel.CounterpartyClientID, exported.Tendermint, ) } @@ -611,7 +611,7 @@ func (coord *Coordinator) ChanCloseInit( // update source client on counterparty connection return coord.UpdateClient( counterparty, source, - channel.CounterpartyClientID, Tendermint, + channel.CounterpartyClientID, exported.Tendermint, ) } @@ -630,6 +630,6 @@ func (coord *Coordinator) SetChannelClosed( // update source client on counterparty connection return coord.UpdateClient( counterparty, source, - testChannel.CounterpartyClientID, Tendermint, + testChannel.CounterpartyClientID, exported.Tendermint, ) } diff --git a/x/staking/types/staking.pb.go b/x/staking/types/staking.pb.go index 102fcea42..865953c9d 100644 --- a/x/staking/types/staking.pb.go +++ b/x/staking/types/staking.pb.go @@ -1216,608 +1216,606 @@ func (this *Pool) Description() (desc *github_com_gogo_protobuf_protoc_gen_gogo_ func StakingDescription() (desc *github_com_gogo_protobuf_protoc_gen_gogo_descriptor.FileDescriptorSet) { d := &github_com_gogo_protobuf_protoc_gen_gogo_descriptor.FileDescriptorSet{} var gzipped = []byte{ - // 9603 bytes of a gzipped FileDescriptorSet + // 9578 bytes of a gzipped FileDescriptorSet 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xec, 0x7d, 0x6d, 0x70, 0x24, 0xd7, 0x71, 0xd8, 0xcd, 0x7e, 0x00, 0xbb, 0x8d, 0x05, 0xb0, 0x78, 0xc0, 0xdd, 0xed, 0x2d, 0x8f, 0x00, 0x38, 0xfc, 0x3a, 0x1e, 0x49, 0x80, 0x3c, 0xf2, 0x8e, 0xe4, 0x9e, 0x44, 0x1a, 0x0b, 0xec, 0xe1, 0xc0, 0xc3, 0x17, 0x07, 0xc0, 0x91, 0xfa, 0x70, 0xb6, 0x06, 0xb3, 0x0f, 0x8b, 0x21, 0x76, 0x67, - 0x86, 0x33, 0xb3, 0x77, 0x07, 0x4a, 0xaa, 0xa2, 0x25, 0x45, 0x91, 0xe8, 0x38, 0x92, 0x22, 0x97, - 0x23, 0xd1, 0x3a, 0x45, 0xb2, 0x9c, 0xc8, 0x91, 0x95, 0xf8, 0x43, 0x8a, 0x12, 0x27, 0xa9, 0x8a, - 0x94, 0xc4, 0xb1, 0xa4, 0x54, 0x5c, 0x52, 0xc5, 0x95, 0x38, 0xae, 0xe4, 0xec, 0x50, 0x2a, 0x87, - 0x51, 0x94, 0x58, 0x3e, 0xcb, 0x89, 0x53, 0xaa, 0x54, 0x52, 0xef, 0x6b, 0xbe, 0xf6, 0x63, 0x16, - 0xd0, 0x9d, 0x24, 0xc7, 0xf9, 0x85, 0x9d, 0x7e, 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, 0x5f, 0x27, 0xdb, 0x1f, 0x8d, 0xae, 0x58, 0x12, 0x8d, 0x69, 0x77, 0xf7, 0xcc, 0xee, 0x67, - 0xe6, 0xc9, 0x52, 0x56, 0x1a, 0x60, 0xc9, 0xb1, 0xc2, 0x28, 0x49, 0x1a, 0x41, 0x9c, 0x0d, 0xb3, - 0x64, 0x24, 0xa3, 0xf0, 0x27, 0xb4, 0x08, 0x03, 0x2f, 0x3a, 0x94, 0xf7, 0x00, 0xe5, 0x7d, 0x4f, - 0x6f, 0xde, 0xcf, 0x6e, 0x50, 0xe6, 0xd9, 0x67, 0x37, 0xaa, 0xab, 0x6b, 0xca, 0xca, 0xdc, 0xb2, - 0xc2, 0xc9, 0xd1, 0x09, 0x48, 0x35, 0xd4, 0x97, 0xf7, 0xc3, 0x8b, 0x1e, 0x05, 0xf5, 0x3b, 0x08, - 0x27, 0x20, 0x75, 0x15, 0xab, 0x7b, 0xe1, 0xa5, 0x86, 0x82, 0x6e, 0xe3, 0x64, 0x98, 0x85, 0x34, - 0xb5, 0x17, 0x02, 0xe0, 0x16, 0xcb, 0x1f, 0x41, 0x19, 0x48, 0xcd, 0xaf, 0x29, 0x64, 0x42, 0xe4, - 0x21, 0xc7, 0xa0, 0xd5, 0xf5, 0xa5, 0xca, 0x7c, 0x25, 0x9f, 0x90, 0xcf, 0xc2, 0x00, 0x33, 0x02, - 0x99, 0x2c, 0x9e, 0x19, 0xf2, 0x47, 0xf8, 0x23, 0xe7, 0x21, 0x89, 0xd6, 0xad, 0x95, 0x72, 0x45, - 0xc9, 0x27, 0xc2, 0x43, 0x9d, 0xca, 0xa7, 0x65, 0x07, 0x72, 0xc1, 0x3c, 0xfc, 0x87, 0xb3, 0x19, - 0xff, 0x92, 0x04, 0x43, 0x81, 0xbc, 0x9a, 0x24, 0x44, 0x6a, 0xa3, 0x61, 0x5e, 0xad, 0xaa, 0x0d, - 0x5d, 0x75, 0xb8, 0x6b, 0x00, 0x05, 0xcd, 0x11, 0x48, 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- 0x56, 0x52, 0x7a, 0x08, 0x90, 0x65, 0x3a, 0xba, 0xab, 0x5f, 0xc1, 0x55, 0xdd, 0x10, 0xc5, 0x27, - 0xb2, 0xad, 0x49, 0x29, 0x79, 0xd1, 0xb2, 0x64, 0xb8, 0x1e, 0xb6, 0x81, 0xeb, 0x6a, 0x04, 0x9b, - 0x04, 0xf3, 0xa4, 0x92, 0x17, 0x2d, 0x1e, 0xf6, 0x5d, 0x90, 0xab, 0x99, 0x2d, 0x92, 0xeb, 0x31, - 0x3c, 0xb2, 0x76, 0x48, 0xca, 0x10, 0x83, 0x79, 0x28, 0x3c, 0x8b, 0xf7, 0xab, 0x5e, 0x39, 0x65, - 0x88, 0xc1, 0x18, 0xca, 0xfd, 0x30, 0xaa, 0xd6, 0xeb, 0x36, 0x61, 0x2e, 0x18, 0xb1, 0x7d, 0xc9, - 0x88, 0x07, 0xa6, 0x88, 0xc5, 0x67, 0x21, 0x23, 0xec, 0x40, 0x96, 0x6a, 0x62, 0x89, 0xaa, 0xc5, - 0x36, 0xdb, 0x89, 0x53, 0x59, 0x25, 0x63, 0x88, 0xc6, 0xbb, 0x20, 0xa7, 0x3b, 0x55, 0xbf, 0x88, - 0x9f, 0x98, 0x4e, 0x9c, 0xca, 0x28, 0x43, 0xba, 0xe3, 0x15, 0x40, 0xe5, 0xcf, 0x24, 0x60, 0x24, - 0xfc, 0x12, 0x02, 0x2d, 0x40, 0xa6, 0x61, 0x6a, 0x2a, 0x75, 0x2d, 0xf6, 0x06, 0xec, 0x54, 0xcc, - 0x7b, 0x8b, 0x99, 0x65, 0x8e, 0xaf, 0x78, 0x94, 0xc5, 0xdf, 0x96, 0x20, 0x23, 0xc0, 0xe8, 0x18, - 0xa4, 0x2c, 0xd5, 0xdd, 0xa5, 0xec, 0xd2, 0xe5, 0x44, 0x5e, 0x52, 0xe8, 0x33, 0x81, 0x3b, 0x96, - 0x6a, 0x50, 0x17, 0xe0, 0x70, 0xf2, 0x4c, 0xc6, 0xb5,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d, 0xcf, 0xcf, 0x43, 0x39, 0x4f, 0xe9, 0x02, 0x0c, 0x87, 0x12, 0x9e, - 0x78, 0x56, 0xef, 0xe5, 0xac, 0x72, 0xc1, 0x7c, 0xa7, 0x74, 0x16, 0x52, 0x24, 0x79, 0x89, 0x27, - 0xff, 0xcb, 0x9c, 0x9c, 0xa2, 0x97, 0xde, 0x0c, 0x19, 0x91, 0xb4, 0xc4, 0x93, 0xbe, 0x8f, 0x93, - 0x7a, 0x24, 0x84, 0x5c, 0x24, 0x2c, 0xf1, 0xe4, 0x7f, 0x45, 0x90, 0x0b, 0x12, 0x42, 0xde, 0xbf, - 0x09, 0xbf, 0xf4, 0xd3, 0x29, 0xbe, 0xe8, 0x08, 0xdb, 0x9d, 0x87, 0x41, 0x9e, 0xa9, 0xc4, 0x53, - 0x7f, 0x80, 0x77, 0x2e, 0x28, 0x4a, 0x4f, 0x40, 0xba, 0x4f, 0x83, 0xff, 0x0c, 0x27, 0x65, 0xf8, - 0xa5, 0x79, 0x18, 0x0a, 0x64, 0x27, 0xf1, 0xe4, 0x7f, 0x8d, 0x93, 0x07, 0xa9, 0x88, 0xe8, 0x3c, - 0x3b, 0x89, 0x67, 0xf0, 0x41, 0x21, 0x3a, 0xa7, 0x20, 0x66, 0x13, 0x89, 0x49, 0x3c, 0xf5, 0x87, - 0x84, 0xd5, 0x05, 0x49, 0xe9, 0x19, 0xc8, 0x7a, 0x8b, 0x4d, 0x3c, 0xfd, 0x87, 0x39, 0xbd, 0x4f, - 0x43, 0x2c, 0x10, 0x58, 0xec, 0xe2, 0x59, 0xfc, 0x75, 0x61, 0x81, 0x00, 0x15, 0x99, 0x46, 0xd1, - 0x04, 0x26, 0x9e, 0xd3, 0x47, 0xc4, 0x34, 0x8a, 0xe4, 0x2f, 0x64, 0x34, 0x69, 0xcc, 0x8f, 0x67, - 0xf1, 0xb3, 0x62, 0x34, 0x29, 0x3e, 0x11, 0x23, 0x9a, 0x11, 0xc4, 0xf3, 0xf8, 0x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82, 0xa1, 0x85, 0xc0, 0x49, 0xaf, - 0x02, 0x0c, 0x36, 0x4d, 0x43, 0xdf, 0xe3, 0xfe, 0x98, 0x55, 0xc4, 0x23, 0x2a, 0x42, 0x86, 0x5d, - 0xba, 0x73, 0xf7, 0x45, 0x29, 0x54, 0x3c, 0x13, 0xaa, 0xab, 0x78, 0xdb, 0xd1, 0xc5, 0x68, 0x28, - 0xe2, 0x11, 0x5d, 0x80, 0xbc, 0x83, 0xb5, 0x96, 0xad, 0xbb, 0xfb, 0x55, 0xcd, 0x34, 0x5c, 0x55, - 0x73, 0xd9, 0xf5, 0xad, 0xf2, 0x1d, 0x37, 0x6f, 0x4c, 0x1d, 0x67, 0xb2, 0x46, 0x31, 0x64, 0x65, - 0x54, 0x80, 0xe6, 0x19, 0x84, 0xf4, 0x50, 0xc3, 0xae, 0xaa, 0x37, 0x9c, 0x02, 0x7b, 0x4f, 0x26, - 0x1e, 0x03, 0xba, 0x7c, 0x6e, 0x30, 0x58, 0xd8, 0xba, 0x00, 0x79, 0xd3, 0xc2, 0x76, 0x28, 0x11, - 0x95, 0xa2, 0x3d, 0x47, 0x31, 0x64, 0x65, 0x54, 0x80, 0x44, 0x92, 0xea, 0x92, 0x61, 0x16, 0x1b, - 0x45, 0xab, 0xb5, 0xed, 0xd7, 0xc3, 0x26, 0xda, 0x46, 0x63, 0xce, 0xd8, 0x2f, 0x3f, 0xe6, 0x73, - 0x8f, 0xd2, 0xc9, 0x5f, 0xfb, 0xc2, 0xc3, 0x13, 0xdc, 0x35, 0xfc, 0xfa, 0xd4, 0x25, 0xbc, 0x4f, - 0x86, 0x9f, 0xa3, 0xae, 0x53, 0x4c, 0x92, 0x76, 0xbe, 0xa8, 0xea, 0x0d, 0x71, 0x0d, 0x59, 0xe1, - 0x4f, 0xa8, 0x04, 0x03, 0x8e, 0xab, 0xba, 0x2d, 0x87, 0x7f, 0x1c, 0x4c, 0xee, 0xe6, 0x6a, 0x65, - 0xd3, 0xa8, 0x6d, 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xa5, 0xfc, 0x67, 0x12, 0x80, 0xef, 0xb3, 0x3f, 0x9e, 0x2e, 0x46, 0x42, 0x39, 0x0f, 0xbc, 0xc9, - 0x43, 0xa5, 0x6a, 0x9c, 0x3a, 0x62, 0xcf, 0x9f, 0x4e, 0xc0, 0xf8, 0x96, 0x88, 0x3c, 0x3f, 0xf6, - 0x36, 0x58, 0x87, 0x41, 0x6c, 0xb8, 0xb6, 0x4e, 0x8d, 0x40, 0x46, 0xfb, 0x91, 0x6e, 0xa3, 0xdd, - 0x41, 0x27, 0xfa, 0xb1, 0x1b, 0x51, 0x74, 0xe7, 0x6c, 0x22, 0xd6, 0xf8, 0x60, 0x12, 0x0a, 0xdd, - 0x28, 0xd1, 0x3c, 0x8c, 0x6a, 0x36, 0xa6, 0x80, 0x6a, 0xb0, 0xf2, 0x57, 0x2e, 0xfa, 0x99, 0x65, - 0x04, 0x41, 0x56, 0x46, 0x04, 0x84, 0xaf, 0x1e, 0x75, 0x20, 0x69, 0x1f, 0x71, 0x3b, 0x82, 0xd5, - 0x67, 0x9e, 0x27, 0xf3, 0xe5, 0x43, 0x74, 0x12, 0x66, 0xc0, 0xd6, 0x8f, 0x11, 0x1f, 0x4a, 0x17, - 0x90, 0x97, 0x60, 0x54, 0x37, 0x74, 0x57, 0x57, 0x1b, 0xd5, 0x6d, 0xb5, 0xa1, 0x1a, 0xda, 0x61, - 0xb2, 0x66, 0x16, 0xf2, 0x79, 0xb7, 0x11, 0x76, 0xb2, 0x32, 0xc2, 0x21, 0x65, 0x06, 0x40, 0x17, - 0x61, 0x50, 0x74, 0x95, 0x3a, 0x54, 0xb6, 0x21, 0xc8, 0x03, 0x09, 0xde, 0xcf, 0x24, 0x61, 0x4c, - 0xc1, 0xb5, 0xff, 0x3f, 0x14, 0x07, 0x1b, 0x8a, 0x15, 0x00, 0x36, 0xdd, 0x49, 0x80, 0x3d, 0xc4, - 0x68, 0x90, 0x80, 0x91, 0x65, 0x1c, 0x16, 0x1c, 0x37, 0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, 0x66, 0x6a, 0x19, 0xee, 0x26, 0x81, 0xc8, 0xcf, 0x40, 0x8e, 0xf5, 0xc7, - 0xad, 0x7f, 0x02, 0x32, 0xf4, 0x9c, 0xb3, 0xdf, 0xeb, 0x20, 0x79, 0xbe, 0xc4, 0x6e, 0x8a, 0x31, - 0x2e, 0xac, 0x63, 0xf6, 0x50, 0x2e, 0x77, 0x35, 0xe5, 0xa9, 0xf8, 0x8c, 0x80, 0x19, 0xca, 0x33, - 0xe3, 0x6f, 0xa6, 0xe1, 0x28, 0xdf, 0x7f, 0xa8, 0x96, 0x3e, 0xbb, 0xeb, 0xba, 0xe2, 0x36, 0x33, - 0xf0, 0x10, 0xa0, 0x5a, 0xba, 0xbc, 0x0f, 0xa9, 0x8b, 0xae, 0x6b, 0xa1, 0xd3, 0x90, 0xb6, 0x5b, - 0x0d, 0x2c, 0x5e, 0xc5, 0x78, 0xa9, 0xa4, 0x6a, 0xe9, 0x33, 0x04, 0x41, 0x69, 0x35, 0xb0, 0xc2, - 0x50, 0x50, 0x05, 0xa6, 0x76, 0x5a, 0x8d, 0xc6, 0x7e, 0xb5, 0x86, 0xe9, 0x3f, 0xd5, 0xf3, 0xfe, - 0x2d, 0x0d, 0xbe, 0x66, 0xa9, 0x86, 0x97, 0xef, 0x67, 0x94, 0x93, 0x14, 0x6d, 0x81, 0x62, 0x89, - 0x7f, 0x49, 0x53, 0x11, 0x38, 0xf2, 0xef, 0x25, 0x20, 0x23, 0x58, 0xd3, 0xab, 0x5b, 0xb8, 0x81, - 0x35, 0xd7, 0x14, 0x47, 0x19, 0xbc, 0x67, 0x84, 0x20, 0x59, 0xe7, 0x43, 0x94, 0xbd, 0x78, 0x44, - 0x21, 0x0f, 0x04, 0xe6, 0x5d, 0xa8, 0x23, 0x30, 0xab, 0x45, 0x46, 0x2d, 0x65, 0x99, 0xa2, 0x66, - 0x7a, 0xf1, 0x88, 0x42, 0x9f, 0x50, 0x01, 0x06, 0x88, 0xcb, 0xba, 0xec, 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0xff, 0x4f, 0xa1, 0x5b, 0x6b, 0x6a, - 0x94, 0x00, 0x00, + 0x06, 0x1d, 0x6c, 0x5f, 0xd1, 0x35, 0x5c, 0x18, 0xa0, 0x0c, 0xee, 0x6f, 0x63, 0xb0, 0xc1, 0x9e, + 0x47, 0x79, 0x08, 0x3a, 0x34, 0x0f, 0x59, 0x7c, 0xcd, 0xc5, 0x86, 0xa3, 0x9b, 0x46, 0x61, 0x90, + 0x32, 0xb9, 0xb7, 0xc3, 0x28, 0xe2, 0x46, 0x2d, 0xca, 0xc2, 0xa7, 0x43, 0xe7, 0x60, 0xd0, 0xb4, + 0x5c, 0xdd, 0x34, 0x9c, 0x42, 0x66, 0x5a, 0x3a, 0x35, 0x74, 0xe6, 0x64, 0x47, 0x47, 0x58, 0x63, + 0x38, 0x8a, 0x40, 0x46, 0x4b, 0x90, 0x77, 0xcc, 0x96, 0xad, 0xe1, 0xaa, 0x66, 0xd6, 0x70, 0x55, + 0x37, 0x76, 0xcc, 0x42, 0x96, 0x32, 0x98, 0x6a, 0x57, 0x84, 0x22, 0xce, 0x9b, 0x35, 0xbc, 0x64, + 0xec, 0x98, 0xca, 0x88, 0x13, 0x6a, 0xa3, 0x63, 0x30, 0xe0, 0xec, 0x1b, 0xae, 0x7a, 0xad, 0x90, + 0xa3, 0x1e, 0xc2, 0x5b, 0xf2, 0x6f, 0x0c, 0xc0, 0x68, 0x3f, 0x2e, 0x76, 0x1e, 0xd2, 0x3b, 0x44, + 0xcb, 0x42, 0xe2, 0x20, 0x36, 0x60, 0x34, 0x61, 0x23, 0x0e, 0x1c, 0xd2, 0x88, 0x73, 0x30, 0x64, + 0x60, 0xc7, 0xc5, 0x35, 0xe6, 0x11, 0xc9, 0x3e, 0x7d, 0x0a, 0x18, 0x51, 0xbb, 0x4b, 0xa5, 0x0e, + 0xe5, 0x52, 0x2f, 0xc0, 0xa8, 0x27, 0x52, 0xd5, 0x56, 0x8d, 0xba, 0xf0, 0xcd, 0xd9, 0x38, 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 0x57, 0x5e, 0x49, 0xc8, 0x1f, 0x1d, 0x80, 0x89, 0x4e, 0x73, + 0xa6, 0xe3, 0xf4, 0x3d, 0x06, 0x03, 0x46, 0xab, 0xb9, 0x8d, 0x6d, 0x6a, 0xa4, 0xb4, 0xc2, 0x5b, + 0x68, 0x0e, 0xd2, 0x0d, 0x75, 0x1b, 0x37, 0x0a, 0xa9, 0x69, 0xe9, 0xd4, 0xc8, 0x99, 0x07, 0xfb, + 0x9a, 0x95, 0x33, 0xcb, 0x84, 0x44, 0x61, 0x94, 0xe8, 0x69, 0x48, 0xf1, 0x10, 0x4d, 0x38, 0x9c, + 0xee, 0x8f, 0x03, 0x99, 0x4b, 0x0a, 0xa5, 0x43, 0x77, 0x40, 0x96, 0xfc, 0x65, 0xbe, 0x31, 0x40, + 0x65, 0xce, 0x10, 0x00, 0xf1, 0x0b, 0x54, 0x84, 0x0c, 0x9d, 0x26, 0x35, 0x2c, 0x96, 0x36, 0xaf, + 0x4d, 0x1c, 0xab, 0x86, 0x77, 0xd4, 0x56, 0xc3, 0xad, 0x5e, 0x51, 0x1b, 0x2d, 0x4c, 0x1d, 0x3e, + 0xab, 0xe4, 0x38, 0xf0, 0x32, 0x81, 0xa1, 0x29, 0x18, 0x62, 0xb3, 0x4a, 0x37, 0x6a, 0xf8, 0x1a, + 0x8d, 0x9e, 0x69, 0x85, 0x4d, 0xb4, 0x25, 0x02, 0x21, 0xdd, 0xbf, 0xe8, 0x98, 0x86, 0x70, 0x4d, + 0xda, 0x05, 0x01, 0xd0, 0xee, 0x9f, 0x88, 0x06, 0xee, 0x3b, 0x3b, 0xab, 0x17, 0xf5, 0x29, 0xf9, + 0x4b, 0x09, 0x48, 0xd1, 0x78, 0x31, 0x0a, 0x43, 0x9b, 0x6f, 0x59, 0xaf, 0x54, 0x17, 0xd6, 0xb6, + 0xca, 0xcb, 0x95, 0xbc, 0x84, 0x46, 0x00, 0x28, 0xe0, 0xc2, 0xf2, 0xda, 0xdc, 0x66, 0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, 0xe1, 0x56, 0x1d, 0xd7, 0xc6, + 0x6a, 0x53, 0x37, 0xea, 0x74, 0x05, 0xc9, 0x94, 0xd2, 0x3b, 0x6a, 0xc3, 0xc1, 0xca, 0x28, 0x7b, + 0xbc, 0x21, 0x9e, 0x12, 0x0a, 0xea, 0x40, 0x76, 0x80, 0x62, 0x20, 0x44, 0xc1, 0x1e, 0x7b, 0x14, + 0xf2, 0xcf, 0x66, 0x61, 0x28, 0x90, 0x57, 0xa3, 0xbb, 0x20, 0xf7, 0xa2, 0x7a, 0x45, 0xad, 0x8a, + 0xbd, 0x12, 0xb3, 0xc4, 0x10, 0x81, 0xad, 0xf3, 0xfd, 0xd2, 0x23, 0x30, 0x41, 0x51, 0xcc, 0x96, + 0x8b, 0xed, 0xaa, 0xd6, 0x50, 0x1d, 0x87, 0x1a, 0x2d, 0x43, 0x51, 0x11, 0x79, 0xb6, 0x46, 0x1e, + 0xcd, 0x8b, 0x27, 0xe8, 0x2c, 0x8c, 0x53, 0x8a, 0x66, 0xab, 0xe1, 0xea, 0x56, 0x03, 0x57, 0xc9, + 0xee, 0xcd, 0xa1, 0x2b, 0x89, 0x27, 0xd9, 0x18, 0xc1, 0x58, 0xe1, 0x08, 0x44, 0x22, 0x07, 0x2d, + 0xc0, 0x9d, 0x94, 0xac, 0x8e, 0x0d, 0x6c, 0xab, 0x2e, 0xae, 0xe2, 0x97, 0x5a, 0x6a, 0xc3, 0xa9, + 0xaa, 0x46, 0xad, 0xba, 0xab, 0x3a, 0xbb, 0x85, 0x09, 0xc2, 0xa0, 0x9c, 0x28, 0x48, 0xca, 0x09, + 0x82, 0xb8, 0xc8, 0xf1, 0x2a, 0x14, 0x6d, 0xce, 0xa8, 0x5d, 0x54, 0x9d, 0x5d, 0x54, 0x82, 0x63, + 0x94, 0x8b, 0xe3, 0xda, 0xba, 0x51, 0xaf, 0x6a, 0xbb, 0x58, 0xdb, 0xab, 0xb6, 0xdc, 0x9d, 0x27, + 0x0b, 0x77, 0x04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75, 0x9b, 0xce, 0xc8, 0xa6, 0xca, 0x56, 0x47, 0xcf, 0x27, 0x26, 0x38, 0xd6, 0x06, 0x76, 0x9f, + 0xd7, 0x6d, 0x32, 0xdf, 0x9a, 0xaa, 0x8b, 0x96, 0x61, 0xca, 0x30, 0xab, 0x8e, 0xab, 0x1a, 0x35, + 0xd5, 0xae, 0x55, 0xfd, 0x42, 0x55, 0x55, 0xd5, 0x34, 0xec, 0x38, 0x26, 0x5b, 0x09, 0x3d, 0x2e, + 0x27, 0x0d, 0x73, 0x83, 0x23, 0xfb, 0x4b, 0xc4, 0x1c, 0x47, 0x8d, 0xf8, 0x6f, 0xb2, 0x9b, 0xff, + 0xde, 0x01, 0xd9, 0xa6, 0x6a, 0x55, 0xb1, 0xe1, 0xda, 0xfb, 0x34, 0xef, 0xce, 0x28, 0x99, 0xa6, + 0x6a, 0x55, 0x48, 0xfb, 0x87, 0xb2, 0xfd, 0x79, 0x36, 0x95, 0xc9, 0xe4, 0xb3, 0xcf, 0xa6, 0x32, + 0xd9, 0x3c, 0xc8, 0xaf, 0x27, 0x21, 0x17, 0xcc, 0xc3, 0xc9, 0xb6, 0x46, 0xa3, 0x4b, 0x96, 0x44, + 0x83, 0xda, 0xdd, 0x3d, 0xb3, 0xf6, 0x99, 0x79, 0xb2, 0x96, 0x95, 0x06, 0x58, 0x76, 0xac, 0x30, + 0x4a, 0x92, 0x47, 0x10, 0x67, 0xc3, 0x2c, 0x1b, 0xc9, 0x28, 0xbc, 0x85, 0x16, 0x61, 0xe0, 0x45, + 0x87, 0xf2, 0x1e, 0xa0, 0xbc, 0xef, 0xe9, 0xcd, 0xfb, 0xd9, 0x0d, 0xca, 0x3c, 0xfb, 0xec, 0x46, + 0x75, 0x75, 0x4d, 0x59, 0x99, 0x5b, 0x56, 0x38, 0x39, 0x3a, 0x01, 0xa9, 0x86, 0xfa, 0xf2, 0x7e, + 0x78, 0xd5, 0xa3, 0xa0, 0x7e, 0x07, 0xe1, 0x04, 0xa4, 0xae, 0x62, 0x75, 0x2f, 0xbc, 0xd6, 0x50, + 0xd0, 0x6d, 0x9c, 0x0c, 0xb3, 0x90, 0xa6, 0xf6, 0x42, 0x00, 0xdc, 0x62, 0xf9, 0x23, 0x28, 0x03, + 0xa9, 0xf9, 0x35, 0x85, 0x4c, 0x88, 0x3c, 0xe4, 0x18, 0xb4, 0xba, 0xbe, 0x54, 0x99, 0xaf, 0xe4, + 0x13, 0xf2, 0x59, 0x18, 0x60, 0x46, 0x20, 0x93, 0xc5, 0x33, 0x43, 0xfe, 0x08, 0x6f, 0x72, 0x1e, + 0x92, 0x78, 0xba, 0xb5, 0x52, 0xae, 0x28, 0xf9, 0x44, 0x78, 0xa8, 0x53, 0xf9, 0xb4, 0xec, 0x40, + 0x2e, 0x98, 0x88, 0xff, 0x70, 0x36, 0xd9, 0x5f, 0x96, 0x60, 0x28, 0x90, 0x58, 0x93, 0x8c, 0x48, + 0x6d, 0x34, 0xcc, 0xab, 0x55, 0xb5, 0xa1, 0xab, 0x0e, 0x77, 0x0d, 0xa0, 0xa0, 0x39, 0x02, 0xe9, + 0x77, 0xe8, 0x7e, 0x48, 0x53, 0x24, 0x9d, 0x1f, 0x90, 0x3f, 0x29, 0x41, 0x3e, 0x9a, 0xd9, 0x46, + 0xc4, 0x94, 0x7e, 0x94, 0x62, 0xca, 0x9f, 0x90, 0x60, 0x24, 0x9c, 0xce, 0x46, 0xc4, 0xbb, 0xeb, + 0x47, 0x2a, 0xde, 0x1f, 0x26, 0x60, 0x38, 0x94, 0xc4, 0xf6, 0x2b, 0xdd, 0x4b, 0x30, 0xa6, 0xd7, + 0x70, 0xd3, 0x32, 0x5d, 0x6c, 0x68, 0xfb, 0xd5, 0x06, 0xbe, 0x82, 0x1b, 0x05, 0x99, 0x06, 0x8d, + 0xd9, 0xde, 0x69, 0xf2, 0xcc, 0x92, 0x4f, 0xb7, 0x4c, 0xc8, 0x4a, 0xe3, 0x4b, 0x0b, 0x95, 0x95, + 0xf5, 0x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0x30, + 0x58, 0x26, 0xa1, 0x78, 0x69, 0xc1, 0x13, 0x44, 0xf2, 0x05, 0x41, 0x2b, 0x30, 0x6a, 0xa9, 0xb6, + 0x4b, 0x8f, 0xee, 0xef, 0x52, 0x2d, 0xb8, 0xaf, 0x4f, 0xb5, 0xcf, 0xbc, 0x90, 0xb2, 0xbc, 0x97, + 0x61, 0x2b, 0x08, 0x94, 0xff, 0x28, 0x05, 0x03, 0xdc, 0x18, 0x6f, 0x86, 0x41, 0x6e, 0x56, 0xee, + 0x9d, 0x77, 0xce, 0xb4, 0x2f, 0x4c, 0x33, 0xde, 0x02, 0xc2, 0xf9, 0x09, 0x1a, 0x74, 0x1f, 0x64, + 0xb4, 0x5d, 0x55, 0x37, 0xaa, 0x7a, 0x4d, 0x64, 0xbd, 0xaf, 0xdf, 0x98, 0x1a, 0x9c, 0x27, 0xb0, + 0xa5, 0x05, 0x65, 0x90, 0x3e, 0x5c, 0xaa, 0x91, 0x4c, 0x60, 0x17, 0xeb, 0xf5, 0x5d, 0x97, 0xcf, + 0x30, 0xde, 0x42, 0x4f, 0x42, 0x8a, 0x38, 0x04, 0xbf, 0xd9, 0x55, 0x6c, 0xdb, 0x7b, 0x78, 0x1b, + 0xc0, 0x72, 0x86, 0x74, 0xfc, 0xa1, 0x3f, 0x98, 0x92, 0x14, 0x4a, 0x81, 0xe6, 0x61, 0xb8, 0xa1, + 0x3a, 0x6e, 0x95, 0xae, 0x60, 0xa4, 0xfb, 0x34, 0x65, 0x71, 0xa2, 0xdd, 0x20, 0xdc, 0xb0, 0x5c, + 0xf4, 0x21, 0x42, 0xc5, 0x40, 0x35, 0x74, 0x0a, 0xf2, 0x94, 0x89, 0x66, 0x36, 0x9b, 0xba, 0xcb, + 0x72, 0xab, 0x01, 0x6a, 0xf7, 0x11, 0x02, 0x9f, 0xa7, 0x60, 0x9a, 0x61, 0xdd, 0x01, 0x59, 0x7a, + 0x95, 0x84, 0xa2, 0xb0, 0x63, 0x93, 0x19, 0x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x54, 0xdb, 0x55, 0x8d, 0x3a, 0x66, 0x9d, 0xd0, 0x12, 0x68, + 0xf9, 0xe2, 0x81, 0x3b, 0x39, 0xe6, 0x77, 0x12, 0x60, 0x27, 0x2b, 0xc3, 0x4d, 0xf5, 0xda, 0x3c, + 0x05, 0x90, 0x1e, 0x4b, 0x99, 0x8f, 0x7e, 0x6a, 0xea, 0x08, 0x7d, 0xb9, 0xf0, 0x0d, 0x09, 0xc0, + 0xb7, 0x18, 0x7a, 0x3b, 0xe4, 0x35, 0xaf, 0x45, 0x69, 0x1d, 0x3e, 0x86, 0xf7, 0x77, 0x1b, 0x8b, + 0x88, 0xbd, 0xd9, 0xda, 0xfc, 0xf5, 0x1b, 0x53, 0x92, 0x32, 0xaa, 0x45, 0x86, 0xe2, 0x6d, 0x30, + 0xd4, 0xb2, 0x6a, 0xaa, 0x8b, 0xab, 0x74, 0x1f, 0x97, 0x88, 0x5d, 0xe7, 0x27, 0x09, 0xaf, 0x9b, + 0x37, 0xa6, 0x10, 0x53, 0x2b, 0x40, 0x2c, 0xd3, 0xd5, 0x1f, 0x18, 0x84, 0x10, 0x04, 0x74, 0xfa, + 0xaa, 0x04, 0x43, 0x0b, 0x81, 0x93, 0x5e, 0x05, 0x18, 0x6c, 0x9a, 0x86, 0xbe, 0xc7, 0xfd, 0x31, + 0xab, 0x88, 0x26, 0x2a, 0x42, 0x86, 0x5d, 0xba, 0x73, 0xf7, 0x45, 0x29, 0x54, 0xb4, 0x09, 0xd5, + 0x55, 0xbc, 0xed, 0xe8, 0x62, 0x34, 0x14, 0xd1, 0x44, 0x17, 0x20, 0xef, 0x60, 0xad, 0x65, 0xeb, + 0xee, 0x7e, 0x55, 0x33, 0x0d, 0x57, 0xd5, 0x5c, 0x76, 0x7d, 0xab, 0x7c, 0xc7, 0xcd, 0x1b, 0x53, + 0xc7, 0x99, 0xac, 0x51, 0x0c, 0x59, 0x19, 0x15, 0xa0, 0x79, 0x06, 0x21, 0x3d, 0xd4, 0xb0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x2c, 0x5e, 0xc5, 0x78, 0xa9, 0xa4, 0x6a, 0xe9, 0x33, + 0x04, 0x41, 0x69, 0x35, 0xb0, 0xc2, 0x50, 0x50, 0x05, 0xa6, 0x76, 0x5a, 0x8d, 0xc6, 0x7e, 0xb5, + 0x86, 0xe9, 0x3f, 0xcb, 0xf3, 0xfe, 0x2f, 0x0d, 0xbe, 0x66, 0xa9, 0x86, 0x97, 0xef, 0x67, 0x94, + 0x93, 0x14, 0x6d, 0x81, 0x62, 0x89, 0xff, 0x49, 0x53, 0x11, 0x38, 0xf2, 0xef, 0x27, 0x20, 0x23, + 0x58, 0xd3, 0xab, 0x5b, 0xb8, 0x81, 0x35, 0xd7, 0x14, 0x47, 0x19, 0xbc, 0x36, 0x42, 0x90, 0xac, + 0xf3, 0x21, 0xca, 0x5e, 0x3c, 0xa2, 0x90, 0x06, 0x81, 0x79, 0x17, 0xea, 0x08, 0xcc, 0x6a, 0x91, + 0x51, 0x4b, 0x59, 0xa6, 0xa8, 0x99, 0x5e, 0x3c, 0xa2, 0xd0, 0x16, 0x2a, 0xc0, 0x00, 0x71, 0x59, + 0x97, 0x7d, 0x31, 0x98, 0xc0, 0x79, 0x1b, 0x1d, 0x83, 0xb4, 0xa5, 0xba, 0x1a, 0x3b, 0xeb, 0x4e, + 0x1e, 0xb0, 0x26, 0x09, 0xcc, 0xec, 0x4b, 0x0d, 0xd1, 0xff, 0x44, 0x45, 0x8c, 0xc1, 0x3e, 0x89, + 0x49, 0xe4, 0x5e, 0x57, 0x5d, 0x17, 0xdb, 0x06, 0x61, 0xc8, 0xd0, 0x11, 0x82, 0xd4, 0xb6, 0x59, + 0xdb, 0xe7, 0xff, 0x1d, 0x8b, 0xfe, 0xe6, 0xff, 0xb7, 0x87, 0xfa, 0x43, 0x95, 0x3e, 0x64, 0xff, + 0x14, 0x30, 0x27, 0x80, 0x65, 0x82, 0x54, 0x81, 0x71, 0xb5, 0x56, 0xd3, 0x89, 0x57, 0xab, 0x8d, + 0xea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e, 0xfe, 0x59, 0x18, 0x0a, + 0x44, 0xfa, 0x42, 0x3a, 0xe6, 0x9a, 0x69, 0xb4, 0x88, 0x16, 0x24, 0x46, 0xef, 0x93, 0xe0, 0x68, + 0xc7, 0x45, 0x90, 0xfe, 0xaf, 0xda, 0x03, 0x16, 0xe9, 0x22, 0xc6, 0xe9, 0xc8, 0x57, 0x56, 0x26, + 0x5a, 0x9d, 0xb2, 0x89, 0x75, 0x18, 0x0e, 0x2d, 0x60, 0x05, 0xf1, 0x1f, 0xa7, 0xfb, 0xbf, 0x61, + 0x11, 0x66, 0x80, 0x8a, 0x90, 0xc1, 0xd7, 0x2c, 0xd3, 0x76, 0x71, 0x8d, 0x1e, 0x79, 0xc8, 0x28, + 0x5e, 0x5b, 0x5e, 0x05, 0xd4, 0x3e, 0xb8, 0xd1, 0xef, 0x90, 0x66, 0xfd, 0xef, 0x90, 0x4e, 0x40, + 0x3a, 0xf8, 0xa5, 0x4e, 0xd6, 0xf0, 0xeb, 0x14, 0xb7, 0x7a, 0xce, 0xff, 0xdf, 0x00, 0x00, 0x00, + 0xff, 0xff, 0x01, 0xf6, 0xec, 0xd9, 0x42, 0x94, 0x00, 0x00, } r := bytes.NewReader(gzipped) gzipr, err := compress_gzip.NewReader(r) From e564d7f5cc9ccf24bfb90a40dcb077cb3623bf1b Mon Sep 17 00:00:00 2001 From: Alessio Treglia Date: Wed, 11 Nov 2020 12:46:11 +0000 Subject: [PATCH 23/24] cosmovisor: tests -> test suites (#7887) --- cosmovisor/args_test.go | 69 ++++++------ cosmovisor/process_test.go | 142 +++++++++++------------ cosmovisor/scanner_test.go | 24 ++-- cosmovisor/upgrade.go | 6 +- cosmovisor/upgrade_test.go | 223 +++++++++++++++++-------------------- 5 files changed, 229 insertions(+), 235 deletions(-) diff --git a/cosmovisor/args_test.go b/cosmovisor/args_test.go index c36faacaf..9e0ce3bb0 100644 --- a/cosmovisor/args_test.go +++ b/cosmovisor/args_test.go @@ -5,10 +5,18 @@ import ( "path/filepath" "testing" - "github.com/stretchr/testify/assert" + "github.com/stretchr/testify/suite" ) -func TestConfigPaths(t *testing.T) { +type argsTestSuite struct { + suite.Suite +} + +func TestArgsTestSuite(t *testing.T) { + suite.Run(t, new(argsTestSuite)) +} + +func (s *argsTestSuite) TestConfigPaths() { cases := map[string]struct { cfg Config upgradeName string @@ -32,23 +40,21 @@ func TestConfigPaths(t *testing.T) { }, } - for name, tc := range cases { - t.Run(name, func(t *testing.T) { - assert.Equal(t, tc.cfg.Root(), filepath.FromSlash(tc.expectRoot)) - assert.Equal(t, tc.cfg.GenesisBin(), filepath.FromSlash(tc.expectGenesis)) - assert.Equal(t, tc.cfg.UpgradeBin(tc.upgradeName), filepath.FromSlash(tc.expectUpgrade)) - }) + for _, tc := range cases { + s.Require().Equal(tc.cfg.Root(), filepath.FromSlash(tc.expectRoot)) + s.Require().Equal(tc.cfg.GenesisBin(), filepath.FromSlash(tc.expectGenesis)) + s.Require().Equal(tc.cfg.UpgradeBin(tc.upgradeName), filepath.FromSlash(tc.expectUpgrade)) } } // Test validate -func TestValidate(t *testing.T) { +func (s *argsTestSuite) TestValidate() { relPath := filepath.Join("testdata", "validate") absPath, err := filepath.Abs(relPath) - assert.NoError(t, err) + s.Require().NoError(err) testdata, err := filepath.Abs("testdata") - assert.NoError(t, err) + s.Require().NoError(err) cases := map[string]struct { cfg Config @@ -84,28 +90,25 @@ func TestValidate(t *testing.T) { }, } - for name, tc := range cases { - t.Run(name, func(t *testing.T) { - err := tc.cfg.validate() - if tc.valid { - assert.NoError(t, err) - } else { - assert.Error(t, err) - } - }) + for _, tc := range cases { + err := tc.cfg.validate() + if tc.valid { + s.Require().NoError(err) + } else { + s.Require().Error(err) + } } } -func TestEnsureBin(t *testing.T) { +func (s *argsTestSuite) TestEnsureBin() { relPath := filepath.Join("testdata", "validate") absPath, err := filepath.Abs(relPath) - assert.NoError(t, err) + s.Require().NoError(err) cfg := Config{Home: absPath, Name: "dummyd"} - assert.NoError(t, cfg.validate()) + s.Require().NoError(cfg.validate()) - err = EnsureBinary(cfg.GenesisBin()) - assert.NoError(t, err) + s.Require().NoError(EnsureBinary(cfg.GenesisBin())) cases := map[string]struct { upgrade string @@ -117,14 +120,12 @@ func TestEnsureBin(t *testing.T) { "no directory": {"foobarbaz", false}, } - for name, tc := range cases { - t.Run(name, func(t *testing.T) { - err := EnsureBinary(cfg.UpgradeBin(tc.upgrade)) - if tc.hasBin { - assert.NoError(t, err) - } else { - assert.Error(t, err) - } - }) + for _, tc := range cases { + err := EnsureBinary(cfg.UpgradeBin(tc.upgrade)) + if tc.hasBin { + s.Require().NoError(err) + } else { + s.Require().Error(err) + } } } diff --git a/cosmovisor/process_test.go b/cosmovisor/process_test.go index a8068f49c..6dc964f21 100644 --- a/cosmovisor/process_test.go +++ b/cosmovisor/process_test.go @@ -1,110 +1,114 @@ // +build linux -package cosmovisor +package cosmovisor_test import ( "bytes" - "os" "testing" - "github.com/stretchr/testify/assert" - "github.com/stretchr/testify/require" + "github.com/stretchr/testify/suite" + + "github.com/cosmos/cosmos-sdk/cosmovisor" ) -// TestLaunchProcess will try running the script a few times and watch upgrades work properly -// and args are passed through -func TestLaunchProcess(t *testing.T) { - home, err := copyTestData("validate") - cfg := &Config{Home: home, Name: "dummyd"} - require.NoError(t, err) - defer os.RemoveAll(home) +type processTestSuite struct { + suite.Suite +} - // should run the genesis binary and produce expected output - var stdout, stderr bytes.Buffer - currentBin, err := cfg.CurrentBin() - require.NoError(t, err) - - require.Equal(t, cfg.GenesisBin(), currentBin) - - args := []string{"foo", "bar", "1234"} - doUpgrade, err := LaunchProcess(cfg, args, &stdout, &stderr) - require.NoError(t, err) - assert.True(t, doUpgrade) - assert.Equal(t, "", stderr.String()) - assert.Equal(t, "Genesis foo bar 1234\nUPGRADE \"chain2\" NEEDED at height: 49: {}\n", stdout.String()) - - // ensure this is upgraded now and produces new output - - currentBin, err = cfg.CurrentBin() - require.NoError(t, err) - require.Equal(t, cfg.UpgradeBin("chain2"), currentBin) - args = []string{"second", "run", "--verbose"} - stdout.Reset() - stderr.Reset() - doUpgrade, err = LaunchProcess(cfg, args, &stdout, &stderr) - require.NoError(t, err) - assert.False(t, doUpgrade) - assert.Equal(t, "", stderr.String()) - assert.Equal(t, "Chain 2 is live!\nArgs: second run --verbose\nFinished successfully\n", stdout.String()) - - // ended without other upgrade - require.Equal(t, cfg.UpgradeBin("chain2"), currentBin) +func TestProcessTestSuite(t *testing.T) { + suite.Run(t, new(processTestSuite)) } // TestLaunchProcess will try running the script a few times and watch upgrades work properly // and args are passed through -func TestLaunchProcessWithDownloads(t *testing.T) { +func (s *processTestSuite) TestLaunchProcess() { + home := copyTestData(s.T(), "validate") + cfg := &cosmovisor.Config{Home: home, Name: "dummyd"} + + // should run the genesis binary and produce expected output + var stdout, stderr bytes.Buffer + currentBin, err := cfg.CurrentBin() + s.Require().NoError(err) + + s.Require().Equal(cfg.GenesisBin(), currentBin) + + args := []string{"foo", "bar", "1234"} + doUpgrade, err := cosmovisor.LaunchProcess(cfg, args, &stdout, &stderr) + s.Require().NoError(err) + s.Require().True(doUpgrade) + s.Require().Equal("", stderr.String()) + s.Require().Equal("Genesis foo bar 1234\nUPGRADE \"chain2\" NEEDED at height: 49: {}\n", stdout.String()) + + // ensure this is upgraded now and produces new output + + currentBin, err = cfg.CurrentBin() + s.Require().NoError(err) + s.Require().Equal(cfg.UpgradeBin("chain2"), currentBin) + args = []string{"second", "run", "--verbose"} + stdout.Reset() + stderr.Reset() + doUpgrade, err = cosmovisor.LaunchProcess(cfg, args, &stdout, &stderr) + s.Require().NoError(err) + s.Require().False(doUpgrade) + s.Require().Equal("", stderr.String()) + s.Require().Equal("Chain 2 is live!\nArgs: second run --verbose\nFinished successfully\n", stdout.String()) + + // ended without other upgrade + s.Require().Equal(cfg.UpgradeBin("chain2"), currentBin) +} + +// TestLaunchProcess will try running the script a few times and watch upgrades work properly +// and args are passed through +func (s *processTestSuite) TestLaunchProcessWithDownloads() { // this is a fun path // genesis -> "chain2" = zip_binary // zip_binary -> "chain3" = ref_zipped -> zip_directory // zip_directory no upgrade - home, err := copyTestData("download") - cfg := &Config{Home: home, Name: "autod", AllowDownloadBinaries: true} - require.NoError(t, err) - defer os.RemoveAll(home) + home := copyTestData(s.T(), "download") + cfg := &cosmovisor.Config{Home: home, Name: "autod", AllowDownloadBinaries: true} // should run the genesis binary and produce expected output var stdout, stderr bytes.Buffer currentBin, err := cfg.CurrentBin() - require.NoError(t, err) + s.Require().NoError(err) - require.Equal(t, cfg.GenesisBin(), currentBin) + s.Require().Equal(cfg.GenesisBin(), currentBin) args := []string{"some", "args"} - doUpgrade, err := LaunchProcess(cfg, args, &stdout, &stderr) - require.NoError(t, err) - assert.True(t, doUpgrade) - assert.Equal(t, "", stderr.String()) - assert.Equal(t, "Preparing auto-download some args\n"+`ERROR: UPGRADE "chain2" NEEDED at height: 49: {"binaries":{"linux/amd64":"https://github.com/cosmos/cosmos-sdk/raw/51249cb93130810033408934454841c98423ed4b/cosmovisor/testdata/repo/zip_binary/autod.zip?checksum=sha256:dc48829b4126ae95bc0db316c66d4e9da5f3db95e212665b6080638cca77e998"}} module=main`+"\n", stdout.String()) + doUpgrade, err := cosmovisor.LaunchProcess(cfg, args, &stdout, &stderr) + s.Require().NoError(err) + s.Require().True(doUpgrade) + s.Require().Equal("", stderr.String()) + s.Require().Equal("Preparing auto-download some args\n"+`ERROR: UPGRADE "chain2" NEEDED at height: 49: {"binaries":{"linux/amd64":"https://github.com/cosmos/cosmos-sdk/raw/51249cb93130810033408934454841c98423ed4b/cosmovisor/testdata/repo/zip_binary/autod.zip?checksum=sha256:dc48829b4126ae95bc0db316c66d4e9da5f3db95e212665b6080638cca77e998"}} module=main`+"\n", stdout.String()) // ensure this is upgraded now and produces new output currentBin, err = cfg.CurrentBin() - require.NoError(t, err) - require.Equal(t, cfg.UpgradeBin("chain2"), currentBin) + s.Require().NoError(err) + s.Require().Equal(cfg.UpgradeBin("chain2"), currentBin) args = []string{"run", "--fast"} stdout.Reset() stderr.Reset() - doUpgrade, err = LaunchProcess(cfg, args, &stdout, &stderr) - require.NoError(t, err) - assert.True(t, doUpgrade) - assert.Equal(t, "", stderr.String()) - assert.Equal(t, "Chain 2 from zipped binary link to referral\nArgs: run --fast\n"+`ERROR: UPGRADE "chain3" NEEDED at height: 936: https://github.com/cosmos/cosmos-sdk/raw/0eae1a50612b8bf803336d35055896fbddaa1ddd/cosmovisor/testdata/repo/ref_zipped?checksum=sha256:0a428575de718ed3cf0771c9687eefaf6f19359977eca4d94a0abd0e11ef8e64 module=main`+"\n", stdout.String()) + doUpgrade, err = cosmovisor.LaunchProcess(cfg, args, &stdout, &stderr) + s.Require().NoError(err) + s.Require().True(doUpgrade) + s.Require().Equal("", stderr.String()) + s.Require().Equal("Chain 2 from zipped binary link to referral\nArgs: run --fast\n"+`ERROR: UPGRADE "chain3" NEEDED at height: 936: https://github.com/cosmos/cosmos-sdk/raw/0eae1a50612b8bf803336d35055896fbddaa1ddd/cosmovisor/testdata/repo/ref_zipped?checksum=sha256:0a428575de718ed3cf0771c9687eefaf6f19359977eca4d94a0abd0e11ef8e64 module=main`+"\n", stdout.String()) // ended with one more upgrade currentBin, err = cfg.CurrentBin() - require.NoError(t, err) - require.Equal(t, cfg.UpgradeBin("chain3"), currentBin) + s.Require().NoError(err) + s.Require().Equal(cfg.UpgradeBin("chain3"), currentBin) // make sure this is the proper binary now.... args = []string{"end", "--halt"} stdout.Reset() stderr.Reset() - doUpgrade, err = LaunchProcess(cfg, args, &stdout, &stderr) - require.NoError(t, err) - assert.False(t, doUpgrade) - assert.Equal(t, "", stderr.String()) - assert.Equal(t, "Chain 2 from zipped directory\nArgs: end --halt\n", stdout.String()) + doUpgrade, err = cosmovisor.LaunchProcess(cfg, args, &stdout, &stderr) + s.Require().NoError(err) + s.Require().False(doUpgrade) + s.Require().Equal("", stderr.String()) + s.Require().Equal("Chain 2 from zipped directory\nArgs: end --halt\n", stdout.String()) // and this doesn't upgrade currentBin, err = cfg.CurrentBin() - require.NoError(t, err) - require.Equal(t, cfg.UpgradeBin("chain3"), currentBin) + s.Require().NoError(err) + s.Require().Equal(cfg.UpgradeBin("chain3"), currentBin) } diff --git a/cosmovisor/scanner_test.go b/cosmovisor/scanner_test.go index a207006fe..9e42410c7 100644 --- a/cosmovisor/scanner_test.go +++ b/cosmovisor/scanner_test.go @@ -1,17 +1,19 @@ -package cosmovisor +package cosmovisor_test import ( "bufio" "io" "testing" - "github.com/stretchr/testify/assert" + "github.com/cosmos/cosmos-sdk/cosmovisor" + + "github.com/stretchr/testify/require" ) func TestWaitForInfo(t *testing.T) { cases := map[string]struct { write []string - expectUpgrade *UpgradeInfo + expectUpgrade *cosmovisor.UpgradeInfo expectErr bool }{ "no match": { @@ -19,14 +21,14 @@ func TestWaitForInfo(t *testing.T) { }, "match name with no info": { write: []string{"first line\n", `UPGRADE "myname" NEEDED at height: 123: `, "\nnext line\n"}, - expectUpgrade: &UpgradeInfo{ + expectUpgrade: &cosmovisor.UpgradeInfo{ Name: "myname", Info: "", }, }, "match name with info": { write: []string{"first line\n", `UPGRADE "take2" NEEDED at height: 123: DownloadData here!`, "\nnext line\n"}, - expectUpgrade: &UpgradeInfo{ + expectUpgrade: &cosmovisor.UpgradeInfo{ Name: "take2", Info: "DownloadData", }, @@ -42,20 +44,20 @@ func TestWaitForInfo(t *testing.T) { go func() { for _, line := range tc.write { n, err := w.Write([]byte(line)) - assert.NoError(t, err) - assert.Equal(t, len(line), n) + require.NoError(t, err) + require.Equal(t, len(line), n) } w.Close() }() // now scan the info - info, err := WaitForUpdate(scan) + info, err := cosmovisor.WaitForUpdate(scan) if tc.expectErr { - assert.Error(t, err) + require.Error(t, err) return } - assert.NoError(t, err) - assert.Equal(t, tc.expectUpgrade, info) + require.NoError(t, err) + require.Equal(t, tc.expectUpgrade, info) }) } } diff --git a/cosmovisor/upgrade.go b/cosmovisor/upgrade.go index 38b6c9f81..3057597f7 100644 --- a/cosmovisor/upgrade.go +++ b/cosmovisor/upgrade.go @@ -119,12 +119,12 @@ func GetDownloadURL(info *UpgradeInfo) (string, error) { var config UpgradeConfig if err := json.Unmarshal([]byte(doc), &config); err == nil { - url, ok := config.Binaries[osArch()] + url, ok := config.Binaries[OSArch()] if !ok { url, ok = config.Binaries["any"] } if !ok { - return "", fmt.Errorf("cannot find binary for os/arch: neither %s, nor any", osArch()) + return "", fmt.Errorf("cannot find binary for os/arch: neither %s, nor any", OSArch()) } return url, nil @@ -133,7 +133,7 @@ func GetDownloadURL(info *UpgradeInfo) (string, error) { return "", errors.New("upgrade info doesn't contain binary map") } -func osArch() string { +func OSArch() string { return fmt.Sprintf("%s/%s", runtime.GOOS, runtime.GOARCH) } diff --git a/cosmovisor/upgrade_test.go b/cosmovisor/upgrade_test.go index 3e628bb7f..2123df8e4 100644 --- a/cosmovisor/upgrade_test.go +++ b/cosmovisor/upgrade_test.go @@ -1,139 +1,138 @@ // +build linux -package cosmovisor +package cosmovisor_test import ( "fmt" - "io/ioutil" "os" "path/filepath" "strings" "testing" - copy2 "github.com/otiai10/copy" + "github.com/stretchr/testify/suite" - "github.com/stretchr/testify/assert" + "github.com/otiai10/copy" "github.com/stretchr/testify/require" + + "github.com/cosmos/cosmos-sdk/cosmovisor" ) -func TestCurrentBin(t *testing.T) { - home, err := copyTestData("validate") - require.NoError(t, err) - defer os.RemoveAll(home) +type upgradeTestSuite struct { + suite.Suite +} - cfg := Config{Home: home, Name: "dummyd"} +func TestUpgradeTestSuite(t *testing.T) { + suite.Run(t, new(upgradeTestSuite)) +} + +func (s *upgradeTestSuite) TestCurrentBin() { + home := copyTestData(s.T(), "validate") + cfg := cosmovisor.Config{Home: home, Name: "dummyd"} currentBin, err := cfg.CurrentBin() - require.NoError(t, err) + s.Require().NoError(err) - assert.Equal(t, cfg.GenesisBin(), currentBin) + s.Require().Equal(cfg.GenesisBin(), currentBin) // ensure we cannot set this to an invalid value for _, name := range []string{"missing", "nobin", "noexec"} { - err = cfg.SetCurrentUpgrade(name) - require.Error(t, err, name) + s.Require().Error(cfg.SetCurrentUpgrade(name), name) currentBin, err := cfg.CurrentBin() - require.NoError(t, err) + s.Require().NoError(err) - assert.Equal(t, cfg.GenesisBin(), currentBin, name) + s.Require().Equal(cfg.GenesisBin(), currentBin, name) } // try a few times to make sure this can be reproduced for _, upgrade := range []string{"chain2", "chain3", "chain2"} { // now set it to a valid upgrade and make sure CurrentBin is now set properly err = cfg.SetCurrentUpgrade(upgrade) - require.NoError(t, err) + s.Require().NoError(err) // we should see current point to the new upgrade dir currentBin, err := cfg.CurrentBin() - require.NoError(t, err) + s.Require().NoError(err) - assert.Equal(t, cfg.UpgradeBin(upgrade), currentBin) + s.Require().Equal(cfg.UpgradeBin(upgrade), currentBin) } } -func TestCurrentAlwaysSymlinkToDirectory(t *testing.T) { - home, err := copyTestData("validate") - require.NoError(t, err) - defer os.RemoveAll(home) - - cfg := Config{Home: home, Name: "dummyd"} +func (s *upgradeTestSuite) TestCurrentAlwaysSymlinkToDirectory() { + home := copyTestData(s.T(), "validate") + cfg := cosmovisor.Config{Home: home, Name: "dummyd"} currentBin, err := cfg.CurrentBin() - require.NoError(t, err) - assert.Equal(t, cfg.GenesisBin(), currentBin) - assertCurrentLink(t, cfg, "genesis") + s.Require().NoError(err) + s.Require().Equal(cfg.GenesisBin(), currentBin) + s.assertCurrentLink(cfg, "genesis") err = cfg.SetCurrentUpgrade("chain2") - require.NoError(t, err) + s.Require().NoError(err) currentBin, err = cfg.CurrentBin() - require.NoError(t, err) - assert.Equal(t, cfg.UpgradeBin("chain2"), currentBin) - assertCurrentLink(t, cfg, filepath.Join("upgrades", "chain2")) + s.Require().NoError(err) + s.Require().Equal(cfg.UpgradeBin("chain2"), currentBin) + s.assertCurrentLink(cfg, filepath.Join("upgrades", "chain2")) } -func assertCurrentLink(t *testing.T, cfg Config, target string) { - link := filepath.Join(cfg.Root(), currentLink) +func (s *upgradeTestSuite) assertCurrentLink(cfg cosmovisor.Config, target string) { + link := filepath.Join(cfg.Root(), "current") // ensure this is a symlink info, err := os.Lstat(link) - require.NoError(t, err) - require.Equal(t, os.ModeSymlink, info.Mode()&os.ModeSymlink) + s.Require().NoError(err) + s.Require().Equal(os.ModeSymlink, info.Mode()&os.ModeSymlink) dest, err := os.Readlink(link) - require.NoError(t, err) + s.Require().NoError(err) expected := filepath.Join(cfg.Root(), target) - require.Equal(t, expected, dest) + s.Require().Equal(expected, dest) } // TODO: test with download (and test all download functions) -func TestDoUpgradeNoDownloadUrl(t *testing.T) { - home, err := copyTestData("validate") - require.NoError(t, err) - defer os.RemoveAll(home) - - cfg := &Config{Home: home, Name: "dummyd", AllowDownloadBinaries: true} +func (s *upgradeTestSuite) TestDoUpgradeNoDownloadUrl() { + home := copyTestData(s.T(), "validate") + cfg := &cosmovisor.Config{Home: home, Name: "dummyd", AllowDownloadBinaries: true} currentBin, err := cfg.CurrentBin() - require.NoError(t, err) + s.Require().NoError(err) - assert.Equal(t, cfg.GenesisBin(), currentBin) + s.Require().Equal(cfg.GenesisBin(), currentBin) // do upgrade ignores bad files for _, name := range []string{"missing", "nobin", "noexec"} { - info := &UpgradeInfo{Name: name} - err = DoUpgrade(cfg, info) - require.Error(t, err, name) + info := &cosmovisor.UpgradeInfo{Name: name} + err = cosmovisor.DoUpgrade(cfg, info) + s.Require().Error(err, name) currentBin, err := cfg.CurrentBin() - require.NoError(t, err) - assert.Equal(t, cfg.GenesisBin(), currentBin, name) + s.Require().NoError(err) + s.Require().Equal(cfg.GenesisBin(), currentBin, name) } // make sure it updates a few times for _, upgrade := range []string{"chain2", "chain3"} { // now set it to a valid upgrade and make sure CurrentBin is now set properly - info := &UpgradeInfo{Name: upgrade} - err = DoUpgrade(cfg, info) - require.NoError(t, err) + info := &cosmovisor.UpgradeInfo{Name: upgrade} + err = cosmovisor.DoUpgrade(cfg, info) + s.Require().NoError(err) // we should see current point to the new upgrade dir upgradeBin := cfg.UpgradeBin(upgrade) currentBin, err := cfg.CurrentBin() - require.NoError(t, err) + s.Require().NoError(err) - assert.Equal(t, upgradeBin, currentBin) + s.Require().Equal(upgradeBin, currentBin) } } -func TestOsArch(t *testing.T) { +func (s *upgradeTestSuite) TestOsArch() { // all download tests will fail if we are not on linux... - assert.Equal(t, "linux/amd64", osArch()) + s.Require().Equal("linux/amd64", cosmovisor.OSArch()) } -func TestGetDownloadURL(t *testing.T) { +func (s *upgradeTestSuite) TestGetDownloadURL() { // all download tests will fail if we are not on linux... ref, err := filepath.Abs(filepath.FromSlash("./testdata/repo/ref_zipped")) - require.NoError(t, err) + s.Require().NoError(err) badref, err := filepath.Abs(filepath.FromSlash("./testdata/repo/zip_binary/autod.zip")) - require.NoError(t, err) + s.Require().NoError(err) cases := map[string]struct { info string @@ -173,20 +172,18 @@ func TestGetDownloadURL(t *testing.T) { }, } - for name, tc := range cases { - t.Run(name, func(t *testing.T) { - url, err := GetDownloadURL(&UpgradeInfo{Info: tc.info}) - if tc.isErr { - assert.Error(t, err) - } else { - assert.NoError(t, err) - assert.Equal(t, tc.url, url) - } - }) + for _, tc := range cases { + url, err := cosmovisor.GetDownloadURL(&cosmovisor.UpgradeInfo{Info: tc.info}) + if tc.isErr { + s.Require().Error(err) + } else { + s.Require().NoError(err) + s.Require().Equal(tc.url, url) + } } } -func TestDownloadBinary(t *testing.T) { +func (s *upgradeTestSuite) TestDownloadBinary() { cases := map[string]struct { url string canDownload bool @@ -228,65 +225,55 @@ func TestDownloadBinary(t *testing.T) { }, } - for name, tc := range cases { - t.Run(name, func(t *testing.T) { - // make temp dir - home, err := copyTestData("download") - require.NoError(t, err) - defer os.RemoveAll(home) + for _, tc := range cases { + var err error + // make temp dir + home := copyTestData(s.T(), "download") - cfg := &Config{ - Home: home, - Name: "autod", - AllowDownloadBinaries: true, - } + cfg := &cosmovisor.Config{ + Home: home, + Name: "autod", + AllowDownloadBinaries: true, + } - // if we have a relative path, make it absolute, but don't change eg. https://... urls - url := tc.url - if strings.HasPrefix(url, "./") { - url, err = filepath.Abs(url) - require.NoError(t, err) - } + // if we have a relative path, make it absolute, but don't change eg. https://... urls + url := tc.url + if strings.HasPrefix(url, "./") { + url, err = filepath.Abs(url) + s.Require().NoError(err) + } - upgrade := "amazonas" - info := &UpgradeInfo{ - Name: upgrade, - Info: fmt.Sprintf(`{"binaries":{"%s": "%s"}}`, osArch(), url), - } + upgrade := "amazonas" + info := &cosmovisor.UpgradeInfo{ + Name: upgrade, + Info: fmt.Sprintf(`{"binaries":{"%s": "%s"}}`, cosmovisor.OSArch(), url), + } - err = DownloadBinary(cfg, info) - if !tc.canDownload { - assert.Error(t, err) - return - } - require.NoError(t, err) + err = cosmovisor.DownloadBinary(cfg, info) + if !tc.canDownload { + s.Require().Error(err) + return + } + s.Require().NoError(err) - err = EnsureBinary(cfg.UpgradeBin(upgrade)) - if tc.validBinary { - require.NoError(t, err) - } else { - require.Error(t, err) - } - }) + err = cosmovisor.EnsureBinary(cfg.UpgradeBin(upgrade)) + if tc.validBinary { + s.Require().NoError(err) + } else { + s.Require().Error(err) + } } } // copyTestData will make a tempdir and then // "cp -r" a subdirectory under testdata there // returns the directory (which can now be used as Config.Home) and modified safely -func copyTestData(subdir string) (string, error) { - tmpdir, err := ioutil.TempDir("", "upgrade-manager-test") - if err != nil { - return "", fmt.Errorf("couldn't create temporary directory: %w", err) - } +func copyTestData(t *testing.T, subdir string) string { + t.Helper() - src := filepath.Join("testdata", subdir) + tmpdir := t.TempDir() - err = copy2.Copy(src, tmpdir) - if err != nil { - os.RemoveAll(tmpdir) - return "", fmt.Errorf("couldn't copy files: %w", err) - } + require.NoError(t, copy.Copy(filepath.Join("testdata", subdir), tmpdir)) - return tmpdir, nil + return tmpdir } From 76ffdccb03b63ba6cc9bf43b4dfc6b32f8e5eb2c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?colin=20axn=C3=A9r?= <25233464+colin-axner@users.noreply.github.com> Date: Wed, 11 Nov 2020 16:52:11 +0100 Subject: [PATCH 24/24] IBC Fraction for trust level changed to uints (#7892) * fraction uses uint now * Update proto/ibc/lightclients/tendermint/v1/tendermint.proto Co-authored-by: Federico Kunze <31522760+fedekunze@users.noreply.github.com> --- .../tendermint/v1/tendermint.proto | 6 +++--- .../07-tendermint/client/cli/tx.go | 4 ++-- .../07-tendermint/types/fraction.go | 8 ++++---- .../07-tendermint/types/tendermint.pb.go | 18 +++++++++--------- 4 files changed, 18 insertions(+), 18 deletions(-) diff --git a/proto/ibc/lightclients/tendermint/v1/tendermint.proto b/proto/ibc/lightclients/tendermint/v1/tendermint.proto index c592a9b5d..a6076b6cf 100644 --- a/proto/ibc/lightclients/tendermint/v1/tendermint.proto +++ b/proto/ibc/lightclients/tendermint/v1/tendermint.proto @@ -106,8 +106,8 @@ message Header { .tendermint.types.ValidatorSet trusted_validators = 4 [(gogoproto.moretags) = "yaml:\"trusted_validators\""]; } -// Fraction defines the protobuf message type for tmmath.Fraction +// Fraction defines the protobuf message type for tmmath.Fraction that only supports positive values. message Fraction { - int64 numerator = 1; - int64 denominator = 2; + uint64 numerator = 1; + uint64 denominator = 2; } diff --git a/x/ibc/light-clients/07-tendermint/client/cli/tx.go b/x/ibc/light-clients/07-tendermint/client/cli/tx.go index 54c0ac01b..4bfe74328 100644 --- a/x/ibc/light-clients/07-tendermint/client/cli/tx.go +++ b/x/ibc/light-clients/07-tendermint/client/cli/tx.go @@ -290,12 +290,12 @@ func parseFraction(fraction string) (types.Fraction, error) { return types.Fraction{}, fmt.Errorf("fraction must have format 'numerator/denominator' got %s", fraction) } - numerator, err := strconv.ParseInt(fr[0], 10, 64) + numerator, err := strconv.ParseUint(fr[0], 10, 64) if err != nil { return types.Fraction{}, fmt.Errorf("invalid trust-level numerator: %w", err) } - denominator, err := strconv.ParseInt(fr[1], 10, 64) + denominator, err := strconv.ParseUint(fr[1], 10, 64) if err != nil { return types.Fraction{}, fmt.Errorf("invalid trust-level denominator: %w", err) } diff --git a/x/ibc/light-clients/07-tendermint/types/fraction.go b/x/ibc/light-clients/07-tendermint/types/fraction.go index e445f19ba..a8d827414 100644 --- a/x/ibc/light-clients/07-tendermint/types/fraction.go +++ b/x/ibc/light-clients/07-tendermint/types/fraction.go @@ -11,15 +11,15 @@ var DefaultTrustLevel = NewFractionFromTm(light.DefaultTrustLevel) // NewFractionFromTm returns a new Fraction instance from a tmmath.Fraction func NewFractionFromTm(f tmmath.Fraction) Fraction { return Fraction{ - Numerator: f.Numerator, - Denominator: f.Denominator, + Numerator: uint64(f.Numerator), + Denominator: uint64(f.Denominator), } } // ToTendermint converts Fraction to tmmath.Fraction func (f Fraction) ToTendermint() tmmath.Fraction { return tmmath.Fraction{ - Numerator: f.Numerator, - Denominator: f.Denominator, + Numerator: int64(f.Numerator), + Denominator: int64(f.Denominator), } } diff --git a/x/ibc/light-clients/07-tendermint/types/tendermint.pb.go b/x/ibc/light-clients/07-tendermint/types/tendermint.pb.go index f4b26ae3c..bd7306503 100644 --- a/x/ibc/light-clients/07-tendermint/types/tendermint.pb.go +++ b/x/ibc/light-clients/07-tendermint/types/tendermint.pb.go @@ -256,8 +256,8 @@ func (m *Header) GetTrustedValidators() *types3.ValidatorSet { // Fraction defines the protobuf message type for tmmath.Fraction type Fraction struct { - Numerator int64 `protobuf:"varint,1,opt,name=numerator,proto3" json:"numerator,omitempty"` - Denominator int64 `protobuf:"varint,2,opt,name=denominator,proto3" json:"denominator,omitempty"` + Numerator uint64 `protobuf:"varint,1,opt,name=numerator,proto3" json:"numerator,omitempty"` + Denominator uint64 `protobuf:"varint,2,opt,name=denominator,proto3" json:"denominator,omitempty"` } func (m *Fraction) Reset() { *m = Fraction{} } @@ -293,14 +293,14 @@ func (m *Fraction) XXX_DiscardUnknown() { var xxx_messageInfo_Fraction proto.InternalMessageInfo -func (m *Fraction) GetNumerator() int64 { +func (m *Fraction) GetNumerator() uint64 { if m != nil { return m.Numerator } return 0 } -func (m *Fraction) GetDenominator() int64 { +func (m *Fraction) GetDenominator() uint64 { if m != nil { return m.Denominator } @@ -386,13 +386,13 @@ var fileDescriptor_c6d6cf2b288949be = []byte{ 0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e, 0x75, 0x0a, 0x00, 0x00, } func (m *ClientState) Marshal() (dAtA []byte, err error) { @@ -1889,7 +1889,7 @@ func (m *Fraction) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - m.Numerator |= int64(b&0x7F) << shift + m.Numerator |= uint64(b&0x7F) << shift if b < 0x80 { break } @@ -1908,7 +1908,7 @@ func (m *Fraction) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - m.Denominator |= int64(b&0x7F) << shift + m.Denominator |= uint64(b&0x7F) << shift if b < 0x80 { break }