From e65480838a1ded147ef53d35fa3bd9709a61226f Mon Sep 17 00:00:00 2001
From: pinosu <95283998+pinosu@users.noreply.github.com>
Date: Thu, 28 Sep 2023 10:49:44 +0200
Subject: [PATCH] Add msg update contract label (#1640)
* Add msg update contract label
* fix tests
---
docs/proto/proto-docs.md | 32 +
proto/cosmwasm/wasm/v1/tx.proto | 25 +-
x/wasm/client/cli/new_tx.go | 28 +
x/wasm/client/cli/tx.go | 1 +
x/wasm/keeper/keeper.go | 20 +
x/wasm/keeper/keeper_test.go | 63 ++
x/wasm/keeper/msg_server.go | 23 +
x/wasm/keeper/msg_server_integration_test.go | 83 +++
x/wasm/types/codec.go | 2 +
x/wasm/types/events.go | 2 +
x/wasm/types/tx.go | 29 +
x/wasm/types/tx.pb.go | 647 ++++++++++++++++---
x/wasm/types/tx_test.go | 68 ++
13 files changed, 914 insertions(+), 109 deletions(-)
diff --git a/docs/proto/proto-docs.md b/docs/proto/proto-docs.md
index dd995a0c18..e7e57fa619 100644
--- a/docs/proto/proto-docs.md
+++ b/docs/proto/proto-docs.md
@@ -112,6 +112,8 @@
- [MsgUnpinCodesResponse](#cosmwasm.wasm.v1.MsgUnpinCodesResponse)
- [MsgUpdateAdmin](#cosmwasm.wasm.v1.MsgUpdateAdmin)
- [MsgUpdateAdminResponse](#cosmwasm.wasm.v1.MsgUpdateAdminResponse)
+ - [MsgUpdateContractLabel](#cosmwasm.wasm.v1.MsgUpdateContractLabel)
+ - [MsgUpdateContractLabelResponse](#cosmwasm.wasm.v1.MsgUpdateContractLabelResponse)
- [MsgUpdateInstantiateConfig](#cosmwasm.wasm.v1.MsgUpdateInstantiateConfig)
- [MsgUpdateInstantiateConfigResponse](#cosmwasm.wasm.v1.MsgUpdateInstantiateConfigResponse)
- [MsgUpdateParams](#cosmwasm.wasm.v1.MsgUpdateParams)
@@ -1845,6 +1847,33 @@ MsgUpdateAdminResponse returns empty data
+
+
+### MsgUpdateContractLabel
+MsgUpdateContractLabel sets a new label for a smart contract
+
+
+| Field | Type | Label | Description |
+| ----- | ---- | ----- | ----------- |
+| `sender` | [string](#string) | | Sender is the that actor that signed the messages |
+| `new_label` | [string](#string) | | NewLabel string to be set |
+| `contract` | [string](#string) | | Contract is the address of the smart contract |
+
+
+
+
+
+
+
+
+### MsgUpdateContractLabelResponse
+MsgUpdateContractLabelResponse returns empty data
+
+
+
+
+
+
### MsgUpdateInstantiateConfig
@@ -1946,6 +1975,9 @@ Since: 0.40 | |
| `StoreAndMigrateContract` | [MsgStoreAndMigrateContract](#cosmwasm.wasm.v1.MsgStoreAndMigrateContract) | [MsgStoreAndMigrateContractResponse](#cosmwasm.wasm.v1.MsgStoreAndMigrateContractResponse) | StoreAndMigrateContract defines a governance operation for storing and migrating the contract. The authority is defined in the keeper.
Since: 0.42 | |
+| `UpdateContractLabel` | [MsgUpdateContractLabel](#cosmwasm.wasm.v1.MsgUpdateContractLabel) | [MsgUpdateContractLabelResponse](#cosmwasm.wasm.v1.MsgUpdateContractLabelResponse) | UpdateContractLabel sets a new label for a smart contract
+
+Since: 0.43 | |
diff --git a/proto/cosmwasm/wasm/v1/tx.proto b/proto/cosmwasm/wasm/v1/tx.proto
index 98798fe321..199ca37640 100644
--- a/proto/cosmwasm/wasm/v1/tx.proto
+++ b/proto/cosmwasm/wasm/v1/tx.proto
@@ -29,7 +29,7 @@ service Msg {
rpc ExecuteContract(MsgExecuteContract) returns (MsgExecuteContractResponse);
// Migrate runs a code upgrade/ downgrade for a smart contract
rpc MigrateContract(MsgMigrateContract) returns (MsgMigrateContractResponse);
- // UpdateAdmin sets a new admin for a smart contract
+ // UpdateAdmin sets a new admin for a smart contract
rpc UpdateAdmin(MsgUpdateAdmin) returns (MsgUpdateAdminResponse);
// ClearAdmin removes any admin stored for a smart contract
rpc ClearAdmin(MsgClearAdmin) returns (MsgClearAdminResponse);
@@ -78,6 +78,11 @@ service Msg {
// Since: 0.42
rpc StoreAndMigrateContract(MsgStoreAndMigrateContract)
returns (MsgStoreAndMigrateContractResponse);
+ // UpdateContractLabel sets a new label for a smart contract
+ //
+ // Since: 0.43
+ rpc UpdateContractLabel(MsgUpdateContractLabel)
+ returns (MsgUpdateContractLabelResponse);
}
// MsgStoreCode submit Wasm code to the system
@@ -472,4 +477,20 @@ message MsgStoreAndMigrateContractResponse {
bytes checksum = 2;
// Data contains bytes to returned from the contract
bytes data = 3;
-}
\ No newline at end of file
+}
+
+// MsgUpdateContractLabel sets a new label for a smart contract
+message MsgUpdateContractLabel {
+ option (amino.name) = "wasm/MsgUpdateContractLabel";
+ option (cosmos.msg.v1.signer) = "sender";
+
+ // Sender is the that actor that signed the messages
+ string sender = 1 [ (cosmos_proto.scalar) = "cosmos.AddressString" ];
+ // NewLabel string to be set
+ string new_label = 2;
+ // Contract is the address of the smart contract
+ string contract = 3 [ (cosmos_proto.scalar) = "cosmos.AddressString" ];
+}
+
+// MsgUpdateContractLabelResponse returns empty data
+message MsgUpdateContractLabelResponse {}
\ No newline at end of file
diff --git a/x/wasm/client/cli/new_tx.go b/x/wasm/client/cli/new_tx.go
index 18b5e3517c..5d54602aa3 100644
--- a/x/wasm/client/cli/new_tx.go
+++ b/x/wasm/client/cli/new_tx.go
@@ -157,3 +157,31 @@ func UpdateInstantiateConfigCmd() *cobra.Command {
flags.AddTxFlagsToCmd(cmd)
return cmd
}
+
+// UpdateContractLabelCmd sets an new label for a contract
+func UpdateContractLabelCmd() *cobra.Command {
+ cmd := &cobra.Command{
+ Use: "set-contract-label [contract_addr_bech32] [new_label]",
+ Short: "Set new label for a contract",
+ Args: cobra.ExactArgs(2),
+ RunE: func(cmd *cobra.Command, args []string) error {
+ clientCtx, err := client.GetClientTxContext(cmd)
+ if err != nil {
+ return err
+ }
+
+ msg := types.MsgUpdateContractLabel{
+ Sender: clientCtx.GetFromAddress().String(),
+ Contract: args[0],
+ NewLabel: args[1],
+ }
+ if err = msg.ValidateBasic(); err != nil {
+ return err
+ }
+ return tx.GenerateOrBroadcastTxCLI(clientCtx, cmd.Flags(), &msg)
+ },
+ SilenceUsage: true,
+ }
+ flags.AddTxFlagsToCmd(cmd)
+ return cmd
+}
diff --git a/x/wasm/client/cli/tx.go b/x/wasm/client/cli/tx.go
index ec8bd5f569..af5e355d7c 100644
--- a/x/wasm/client/cli/tx.go
+++ b/x/wasm/client/cli/tx.go
@@ -71,6 +71,7 @@ func GetTxCmd() *cobra.Command {
GrantCmd(),
UpdateInstantiateConfigCmd(),
SubmitProposalCmd(),
+ UpdateContractLabelCmd(),
)
return txCmd
}
diff --git a/x/wasm/keeper/keeper.go b/x/wasm/keeper/keeper.go
index 43c72ad9f0..925a7fd6df 100644
--- a/x/wasm/keeper/keeper.go
+++ b/x/wasm/keeper/keeper.go
@@ -653,6 +653,26 @@ func (k Keeper) setContractAdmin(ctx context.Context, contractAddress, caller, n
return nil
}
+func (k Keeper) setContractLabel(ctx context.Context, contractAddress, caller sdk.AccAddress, newLabel string, authZ types.AuthorizationPolicy) error {
+ sdkCtx := sdk.UnwrapSDKContext(ctx)
+ contractInfo := k.GetContractInfo(sdkCtx, contractAddress)
+ if contractInfo == nil {
+ return errorsmod.Wrap(sdkerrors.ErrInvalidRequest, "unknown contract")
+ }
+ if !authZ.CanModifyContract(contractInfo.AdminAddr(), caller) {
+ return errorsmod.Wrap(sdkerrors.ErrUnauthorized, "can not modify contract")
+ }
+ contractInfo.Label = newLabel
+ k.mustStoreContractInfo(sdkCtx, contractAddress, contractInfo)
+ sdkCtx.EventManager().EmitEvent(sdk.NewEvent(
+ types.EventTypeUpdateContractLabel,
+ sdk.NewAttribute(types.AttributeKeyContractAddr, contractAddress.String()),
+ sdk.NewAttribute(types.AttributeKeyNewLabel, newLabel),
+ ))
+
+ return nil
+}
+
func (k Keeper) appendToContractHistory(ctx context.Context, contractAddr sdk.AccAddress, newEntries ...types.ContractCodeHistoryEntry) error {
store := k.storeService.OpenKVStore(ctx)
// find last element position
diff --git a/x/wasm/keeper/keeper_test.go b/x/wasm/keeper/keeper_test.go
index 2ec02394a1..dfb7e3e45c 100644
--- a/x/wasm/keeper/keeper_test.go
+++ b/x/wasm/keeper/keeper_test.go
@@ -2489,6 +2489,69 @@ func TestGasConsumed(t *testing.T) {
}
}
+func TestSetContractLabel(t *testing.T) {
+ parentCtx, keepers := CreateTestInput(t, false, AvailableCapabilities)
+ k := keepers.WasmKeeper
+ example := InstantiateReflectExampleContract(t, parentCtx, keepers)
+
+ specs := map[string]struct {
+ newLabel string
+ caller sdk.AccAddress
+ policy types.AuthorizationPolicy
+ contract sdk.AccAddress
+ expErr bool
+ }{
+ "update label - default policy": {
+ newLabel: "new label",
+ caller: example.CreatorAddr,
+ policy: DefaultAuthorizationPolicy{},
+ contract: example.Contract,
+ },
+ "update label - gov policy": {
+ newLabel: "new label",
+ policy: GovAuthorizationPolicy{},
+ caller: RandomAccountAddress(t),
+ contract: example.Contract,
+ },
+ "update label - unauthorized": {
+ newLabel: "new label",
+ caller: RandomAccountAddress(t),
+ policy: DefaultAuthorizationPolicy{},
+ contract: example.Contract,
+ expErr: true,
+ },
+ "update label - unknown contract": {
+ newLabel: "new label",
+ caller: example.CreatorAddr,
+ policy: DefaultAuthorizationPolicy{},
+ contract: RandomAccountAddress(t),
+ expErr: true,
+ },
+ }
+ for name, spec := range specs {
+ t.Run(name, func(t *testing.T) {
+ ctx, _ := parentCtx.CacheContext()
+ em := sdk.NewEventManager()
+ ctx = ctx.WithEventManager(em)
+ gotErr := k.setContractLabel(ctx, spec.contract, spec.caller, spec.newLabel, spec.policy)
+ if spec.expErr {
+ require.Error(t, gotErr)
+ return
+ }
+ require.NoError(t, gotErr)
+ assert.Equal(t, spec.newLabel, k.GetContractInfo(ctx, spec.contract).Label)
+ // and event emitted
+ require.Len(t, em.Events(), 1)
+ assert.Equal(t, "update_contract_label", em.Events()[0].Type)
+ exp := map[string]string{
+ "_contract_address": spec.contract.String(),
+ "new_label": spec.newLabel,
+ }
+ assert.Equal(t, exp, attrsToStringMap(em.Events()[0].Attributes))
+ })
+ }
+}
+
func attrsToStringMap(attrs []abci.EventAttribute) map[string]string {
r := make(map[string]string, len(attrs))
for _, v := range attrs {
diff --git a/x/wasm/keeper/msg_server.go b/x/wasm/keeper/msg_server.go
index 0cd43165c7..691ffa445c 100644
--- a/x/wasm/keeper/msg_server.go
+++ b/x/wasm/keeper/msg_server.go
@@ -462,3 +462,26 @@ func (m msgServer) StoreAndMigrateContract(goCtx context.Context, req *types.Msg
Data: data,
}, nil
}
+
+func (m msgServer) UpdateContractLabel(ctx context.Context, msg *types.MsgUpdateContractLabel) (*types.MsgUpdateContractLabelResponse, error) {
+ if err := msg.ValidateBasic(); err != nil {
+ return nil, err
+ }
+
+ senderAddr, err := sdk.AccAddressFromBech32(msg.Sender)
+ if err != nil {
+ return nil, errorsmod.Wrap(err, "sender")
+ }
+ contractAddr, err := sdk.AccAddressFromBech32(msg.Contract)
+ if err != nil {
+ return nil, errorsmod.Wrap(err, "contract")
+ }
+
+ policy := m.selectAuthorizationPolicy(ctx, msg.Sender)
+
+ if err := m.keeper.setContractLabel(ctx, contractAddr, senderAddr, msg.NewLabel, policy); err != nil {
+ return nil, err
+ }
+
+ return &types.MsgUpdateContractLabelResponse{}, nil
+}
diff --git a/x/wasm/keeper/msg_server_integration_test.go b/x/wasm/keeper/msg_server_integration_test.go
index da681fd5e9..5d737a93cc 100644
--- a/x/wasm/keeper/msg_server_integration_test.go
+++ b/x/wasm/keeper/msg_server_integration_test.go
@@ -1144,3 +1144,86 @@ func TestStoreAndMigrateContract(t *testing.T) {
})
}
}
+
+func TestUpdateContractLabel(t *testing.T) {
+ wasmApp := app.Setup(t)
+ ctx := wasmApp.BaseApp.NewContextLegacy(false, tmproto.Header{Time: time.Now()})
+
+ var (
+ myAddress sdk.AccAddress = make([]byte, types.ContractAddrLen)
+ authority = wasmApp.WasmKeeper.GetAuthority()
+ _, _, otherAddr = testdata.KeyTestPubAddr()
+ )
+
+ specs := map[string]struct {
+ addr string
+ newLabel string
+ expErr bool
+ }{
+ "authority can update contract label": {
+ addr: authority,
+ newLabel: "new label",
+ expErr: false,
+ },
+ "admin can update contract label": {
+ addr: myAddress.String(),
+ newLabel: "new label",
+ expErr: false,
+ },
+ "other address cannot update contract label": {
+ addr: otherAddr.String(),
+ newLabel: "new label",
+ expErr: true,
+ },
+ "empty new label": {
+ addr: authority,
+ expErr: true,
+ },
+ "invalid new label": {
+ addr: authority,
+ newLabel: " start with space ",
+ expErr: true,
+ },
+ }
+ for name, spec := range specs {
+ t.Run(name, func(t *testing.T) {
+ // setup
+ msg := &types.MsgStoreAndInstantiateContract{
+ Authority: spec.addr,
+ WASMByteCode: wasmContract,
+ InstantiatePermission: &types.AllowEverybody,
+ Admin: myAddress.String(),
+ UnpinCode: false,
+ Label: "old label",
+ Msg: []byte(`{}`),
+ Funds: sdk.Coins{},
+ }
+ rsp, err := wasmApp.MsgServiceRouter().Handler(msg)(ctx, msg)
+ require.NoError(t, err)
+ var storeAndInstantiateResponse types.MsgStoreAndInstantiateContractResponse
+ require.NoError(t, wasmApp.AppCodec().Unmarshal(rsp.Data, &storeAndInstantiateResponse))
+
+ contract := storeAndInstantiateResponse.Address
+ contractAddr, err := sdk.AccAddressFromBech32(contract)
+ require.NoError(t, err)
+ require.Equal(t, "old label", wasmApp.WasmKeeper.GetContractInfo(ctx, contractAddr).Label)
+
+ // when
+ msgUpdateLabel := &types.MsgUpdateContractLabel{
+ Sender: spec.addr,
+ NewLabel: spec.newLabel,
+ Contract: storeAndInstantiateResponse.Address,
+ }
+ _, err = wasmApp.MsgServiceRouter().Handler(msgUpdateLabel)(ctx, msgUpdateLabel)
+
+ // then
+ if spec.expErr {
+ require.Error(t, err)
+ require.Equal(t, "old label", wasmApp.WasmKeeper.GetContractInfo(ctx, contractAddr).Label)
+ } else {
+ require.NoError(t, err)
+ require.Equal(t, spec.newLabel, wasmApp.WasmKeeper.GetContractInfo(ctx, contractAddr).Label)
+ }
+ })
+ }
+}
diff --git a/x/wasm/types/codec.go b/x/wasm/types/codec.go
index 2f3985380e..c13f75191b 100644
--- a/x/wasm/types/codec.go
+++ b/x/wasm/types/codec.go
@@ -27,6 +27,7 @@ func RegisterLegacyAminoCodec(cdc *codec.LegacyAmino) {
cdc.RegisterConcrete(&MsgAddCodeUploadParamsAddresses{}, "wasm/MsgAddCodeUploadParamsAddresses", nil)
cdc.RegisterConcrete(&MsgRemoveCodeUploadParamsAddresses{}, "wasm/MsgRemoveCodeUploadParamsAddresses", nil)
cdc.RegisterConcrete(&MsgStoreAndMigrateContract{}, "wasm/MsgStoreAndMigrateContract", nil)
+ cdc.RegisterConcrete(&MsgUpdateContractLabel{}, "wasm/MsgUpdateContractLabel", nil)
cdc.RegisterConcrete(&PinCodesProposal{}, "wasm/PinCodesProposal", nil)
cdc.RegisterConcrete(&UnpinCodesProposal{}, "wasm/UnpinCodesProposal", nil)
@@ -79,6 +80,7 @@ func RegisterInterfaces(registry types.InterfaceRegistry) {
&MsgAddCodeUploadParamsAddresses{},
&MsgRemoveCodeUploadParamsAddresses{},
&MsgStoreAndMigrateContract{},
+ &MsgUpdateContractLabel{},
)
registry.RegisterImplementations(
(*v1beta1.Content)(nil),
diff --git a/x/wasm/types/events.go b/x/wasm/types/events.go
index e1588d6f36..db44bb4da7 100644
--- a/x/wasm/types/events.go
+++ b/x/wasm/types/events.go
@@ -24,6 +24,7 @@ const (
EventTypeReply = "reply"
EventTypeGovContractResult = "gov_contract_result"
EventTypeUpdateContractAdmin = "update_contract_admin"
+ EventTypeUpdateContractLabel = "update_contract_label"
EventTypeUpdateCodeAccessConfig = "update_code_access_config"
EventTypePacketRecv = "ibc_packet_received"
// add new types to IsAcceptedEventOnRecvPacketErrorAck
@@ -61,6 +62,7 @@ const (
AttributeKeyResultDataHex = "result"
AttributeKeyRequiredCapability = "required_capability"
AttributeKeyNewAdmin = "new_admin_address"
+ AttributeKeyNewLabel = "new_label"
AttributeKeyCodePermission = "code_permission"
AttributeKeyAuthorizedAddresses = "authorized_addresses"
AttributeKeyAckSuccess = "success"
diff --git a/x/wasm/types/tx.go b/x/wasm/types/tx.go
index a50196bd6c..f992b5409b 100644
--- a/x/wasm/types/tx.go
+++ b/x/wasm/types/tx.go
@@ -690,3 +690,32 @@ func hasDuplicates[T comparable](s []T) bool {
}
return false
}
+
+func (msg MsgUpdateContractLabel) Route() string {
+ return RouterKey
+}
+
+func (msg MsgUpdateContractLabel) Type() string {
+ return "update-contract-label"
+}
+
+func (msg MsgUpdateContractLabel) ValidateBasic() error {
+ if _, err := sdk.AccAddressFromBech32(msg.Sender); err != nil {
+ return errorsmod.Wrap(err, "sender")
+ }
+ if err := ValidateLabel(msg.NewLabel); err != nil {
+ return errorsmod.Wrap(err, "label")
+ }
+ if _, err := sdk.AccAddressFromBech32(msg.Contract); err != nil {
+ return errorsmod.Wrap(err, "contract")
+ }
+ return nil
+}
+
+func (msg MsgUpdateContractLabel) GetSigners() []sdk.AccAddress {
+ senderAddr, err := sdk.AccAddressFromBech32(msg.Sender)
+ if err != nil { // should never happen as valid basic rejects invalid addresses
+ panic(err.Error())
+ }
+ return []sdk.AccAddress{senderAddr}
+}
diff --git a/x/wasm/types/tx.pb.go b/x/wasm/types/tx.pb.go
index 4e38b0dc97..966465f78d 100644
--- a/x/wasm/types/tx.pb.go
+++ b/x/wasm/types/tx.pb.go
@@ -1578,6 +1578,95 @@ func (m *MsgStoreAndMigrateContractResponse) XXX_DiscardUnknown() {
var xxx_messageInfo_MsgStoreAndMigrateContractResponse proto.InternalMessageInfo
+// MsgUpdateContractLabel sets a new label for a smart contract
+type MsgUpdateContractLabel struct {
+ // Sender is the that actor that signed the messages
+ Sender string `protobuf:"bytes,1,opt,name=sender,proto3" json:"sender,omitempty"`
+ // NewLabel string to be set
+ NewLabel string `protobuf:"bytes,2,opt,name=new_label,json=newLabel,proto3" json:"new_label,omitempty"`
+ // Contract is the address of the smart contract
+ Contract string `protobuf:"bytes,3,opt,name=contract,proto3" json:"contract,omitempty"`
+}
+
+func (m *MsgUpdateContractLabel) Reset() { *m = MsgUpdateContractLabel{} }
+func (m *MsgUpdateContractLabel) String() string { return proto.CompactTextString(m) }
+func (*MsgUpdateContractLabel) ProtoMessage() {}
+func (*MsgUpdateContractLabel) Descriptor() ([]byte, []int) {
+ return fileDescriptor_4f74d82755520264, []int{32}
+}
+
+func (m *MsgUpdateContractLabel) XXX_Unmarshal(b []byte) error {
+ return m.Unmarshal(b)
+}
+
+func (m *MsgUpdateContractLabel) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
+ if deterministic {
+ return xxx_messageInfo_MsgUpdateContractLabel.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 *MsgUpdateContractLabel) XXX_Merge(src proto.Message) {
+ xxx_messageInfo_MsgUpdateContractLabel.Merge(m, src)
+}
+
+func (m *MsgUpdateContractLabel) XXX_Size() int {
+ return m.Size()
+}
+
+func (m *MsgUpdateContractLabel) XXX_DiscardUnknown() {
+ xxx_messageInfo_MsgUpdateContractLabel.DiscardUnknown(m)
+}
+
+var xxx_messageInfo_MsgUpdateContractLabel proto.InternalMessageInfo
+
+// MsgUpdateContractLabelResponse returns empty data
+type MsgUpdateContractLabelResponse struct{}
+
+func (m *MsgUpdateContractLabelResponse) Reset() { *m = MsgUpdateContractLabelResponse{} }
+func (m *MsgUpdateContractLabelResponse) String() string { return proto.CompactTextString(m) }
+func (*MsgUpdateContractLabelResponse) ProtoMessage() {}
+func (*MsgUpdateContractLabelResponse) Descriptor() ([]byte, []int) {
+ return fileDescriptor_4f74d82755520264, []int{33}
+}
+
+func (m *MsgUpdateContractLabelResponse) XXX_Unmarshal(b []byte) error {
+ return m.Unmarshal(b)
+}
+
+func (m *MsgUpdateContractLabelResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
+ if deterministic {
+ return xxx_messageInfo_MsgUpdateContractLabelResponse.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 *MsgUpdateContractLabelResponse) XXX_Merge(src proto.Message) {
+ xxx_messageInfo_MsgUpdateContractLabelResponse.Merge(m, src)
+}
+
+func (m *MsgUpdateContractLabelResponse) XXX_Size() int {
+ return m.Size()
+}
+
+func (m *MsgUpdateContractLabelResponse) XXX_DiscardUnknown() {
+ xxx_messageInfo_MsgUpdateContractLabelResponse.DiscardUnknown(m)
+}
+
+var xxx_messageInfo_MsgUpdateContractLabelResponse proto.InternalMessageInfo
+
func init() {
proto.RegisterType((*MsgStoreCode)(nil), "cosmwasm.wasm.v1.MsgStoreCode")
proto.RegisterType((*MsgStoreCodeResponse)(nil), "cosmwasm.wasm.v1.MsgStoreCodeResponse")
@@ -1611,116 +1700,122 @@ func init() {
proto.RegisterType((*MsgRemoveCodeUploadParamsAddressesResponse)(nil), "cosmwasm.wasm.v1.MsgRemoveCodeUploadParamsAddressesResponse")
proto.RegisterType((*MsgStoreAndMigrateContract)(nil), "cosmwasm.wasm.v1.MsgStoreAndMigrateContract")
proto.RegisterType((*MsgStoreAndMigrateContractResponse)(nil), "cosmwasm.wasm.v1.MsgStoreAndMigrateContractResponse")
+ proto.RegisterType((*MsgUpdateContractLabel)(nil), "cosmwasm.wasm.v1.MsgUpdateContractLabel")
+ proto.RegisterType((*MsgUpdateContractLabelResponse)(nil), "cosmwasm.wasm.v1.MsgUpdateContractLabelResponse")
}
func init() { proto.RegisterFile("cosmwasm/wasm/v1/tx.proto", fileDescriptor_4f74d82755520264) }
var fileDescriptor_4f74d82755520264 = []byte{
- // 1660 bytes of a gzipped FileDescriptorProto
- 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xec, 0x59, 0xbb, 0x6f, 0xdb, 0x56,
- 0x17, 0x37, 0xad, 0xf7, 0xb1, 0x93, 0x38, 0x8c, 0x63, 0xcb, 0x4c, 0x22, 0x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, 0x2e, 0x75, 0x91, 0x12, 0x5e, 0x1b, 0x44, 0xca, 0xb1, 0xeb, 0x23, 0x0e, 0xce,
+ 0x06, 0xf6, 0xa1, 0xde, 0xd5, 0x2d, 0x48, 0x44, 0xb8, 0xd9, 0xb7, 0x08, 0x7b, 0x2e, 0xfd, 0x9a,
+ 0xa4, 0xf9, 0x40, 0xec, 0xdd, 0x15, 0xec, 0x5a, 0x3f, 0xdc, 0xec, 0x05, 0xe4, 0x75, 0x91, 0x07,
+ 0xd5, 0xab, 0x36, 0x4e, 0x9f, 0x0b, 0x28, 0xe0, 0x42, 0x15, 0x22, 0xef, 0x9b, 0x23, 0x51, 0xf1,
+ 0xd6, 0xc3, 0xdf, 0x53, 0x43, 0x0f, 0x0f, 0x53, 0xdc, 0xa3, 0xc3, 0x14, 0xf7, 0xdb, 0x61, 0x8a,
+ 0xfb, 0xf8, 0x49, 0x6a, 0xe8, 0xd1, 0x93, 0xd4, 0xd0, 0xcf, 0x4f, 0x52, 0x43, 0xef, 0x5c, 0x66,
+ 0xe6, 0xab, 0x65, 0x1d, 0x57, 0xef, 0xd8, 0x3f, 0xb5, 0xca, 0xb9, 0x7d, 0xfa, 0x93, 0x2b, 0x99,
+ 0xb1, 0x36, 0xa3, 0xe4, 0x27, 0xd4, 0xff, 0xfd, 0x1d, 0x00, 0x00, 0xff, 0xff, 0xe7, 0x91, 0xf8,
+ 0x74, 0x0c, 0x1e, 0x00, 0x00,
}
// Reference imports to suppress errors if they are not otherwise used.
@@ -1749,7 +1844,7 @@ type MsgClient interface {
ExecuteContract(ctx context.Context, in *MsgExecuteContract, opts ...grpc.CallOption) (*MsgExecuteContractResponse, error)
// Migrate runs a code upgrade/ downgrade for a smart contract
MigrateContract(ctx context.Context, in *MsgMigrateContract, opts ...grpc.CallOption) (*MsgMigrateContractResponse, error)
- // UpdateAdmin sets a new admin for a smart contract
+ // UpdateAdmin sets a new admin for a smart contract
UpdateAdmin(ctx context.Context, in *MsgUpdateAdmin, opts ...grpc.CallOption) (*MsgUpdateAdminResponse, error)
// ClearAdmin removes any admin stored for a smart contract
ClearAdmin(ctx context.Context, in *MsgClearAdmin, opts ...grpc.CallOption) (*MsgClearAdminResponse, error)
@@ -1793,6 +1888,10 @@ type MsgClient interface {
//
// Since: 0.42
StoreAndMigrateContract(ctx context.Context, in *MsgStoreAndMigrateContract, opts ...grpc.CallOption) (*MsgStoreAndMigrateContractResponse, error)
+ // UpdateContractLabel sets a new label for a smart contract
+ //
+ // Since: 0.43
+ UpdateContractLabel(ctx context.Context, in *MsgUpdateContractLabel, opts ...grpc.CallOption) (*MsgUpdateContractLabelResponse, error)
}
type msgClient struct {
@@ -1947,6 +2046,15 @@ func (c *msgClient) StoreAndMigrateContract(ctx context.Context, in *MsgStoreAnd
return out, nil
}
+func (c *msgClient) UpdateContractLabel(ctx context.Context, in *MsgUpdateContractLabel, opts ...grpc.CallOption) (*MsgUpdateContractLabelResponse, error) {
+ out := new(MsgUpdateContractLabelResponse)
+ err := c.cc.Invoke(ctx, "/cosmwasm.wasm.v1.Msg/UpdateContractLabel", in, out, opts...)
+ if err != nil {
+ return nil, err
+ }
+ return out, nil
+}
+
// MsgServer is the server API for Msg service.
type MsgServer interface {
// StoreCode to submit Wasm code to the system
@@ -1961,7 +2069,7 @@ type MsgServer interface {
ExecuteContract(context.Context, *MsgExecuteContract) (*MsgExecuteContractResponse, error)
// Migrate runs a code upgrade/ downgrade for a smart contract
MigrateContract(context.Context, *MsgMigrateContract) (*MsgMigrateContractResponse, error)
- // UpdateAdmin sets a new admin for a smart contract
+ // UpdateAdmin sets a new admin for a smart contract
UpdateAdmin(context.Context, *MsgUpdateAdmin) (*MsgUpdateAdminResponse, error)
// ClearAdmin removes any admin stored for a smart contract
ClearAdmin(context.Context, *MsgClearAdmin) (*MsgClearAdminResponse, error)
@@ -2005,6 +2113,10 @@ type MsgServer interface {
//
// Since: 0.42
StoreAndMigrateContract(context.Context, *MsgStoreAndMigrateContract) (*MsgStoreAndMigrateContractResponse, error)
+ // UpdateContractLabel sets a new label for a smart contract
+ //
+ // Since: 0.43
+ UpdateContractLabel(context.Context, *MsgUpdateContractLabel) (*MsgUpdateContractLabelResponse, error)
}
// UnimplementedMsgServer can be embedded to have forward compatible implementations.
@@ -2074,6 +2186,10 @@ func (*UnimplementedMsgServer) StoreAndMigrateContract(ctx context.Context, req
return nil, status.Errorf(codes.Unimplemented, "method StoreAndMigrateContract not implemented")
}
+func (*UnimplementedMsgServer) UpdateContractLabel(ctx context.Context, req *MsgUpdateContractLabel) (*MsgUpdateContractLabelResponse, error) {
+ return nil, status.Errorf(codes.Unimplemented, "method UpdateContractLabel not implemented")
+}
+
func RegisterMsgServer(s grpc1.Server, srv MsgServer) {
s.RegisterService(&_Msg_serviceDesc, srv)
}
@@ -2366,6 +2482,24 @@ func _Msg_StoreAndMigrateContract_Handler(srv interface{}, ctx context.Context,
return interceptor(ctx, in, info, handler)
}
+func _Msg_UpdateContractLabel_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
+ in := new(MsgUpdateContractLabel)
+ if err := dec(in); err != nil {
+ return nil, err
+ }
+ if interceptor == nil {
+ return srv.(MsgServer).UpdateContractLabel(ctx, in)
+ }
+ info := &grpc.UnaryServerInfo{
+ Server: srv,
+ FullMethod: "/cosmwasm.wasm.v1.Msg/UpdateContractLabel",
+ }
+ handler := func(ctx context.Context, req interface{}) (interface{}, error) {
+ return srv.(MsgServer).UpdateContractLabel(ctx, req.(*MsgUpdateContractLabel))
+ }
+ return interceptor(ctx, in, info, handler)
+}
+
var _Msg_serviceDesc = grpc.ServiceDesc{
ServiceName: "cosmwasm.wasm.v1.Msg",
HandlerType: (*MsgServer)(nil),
@@ -2434,6 +2568,10 @@ var _Msg_serviceDesc = grpc.ServiceDesc{
MethodName: "StoreAndMigrateContract",
Handler: _Msg_StoreAndMigrateContract_Handler,
},
+ {
+ MethodName: "UpdateContractLabel",
+ Handler: _Msg_UpdateContractLabel_Handler,
+ },
},
Streams: []grpc.StreamDesc{},
Metadata: "cosmwasm/wasm/v1/tx.proto",
@@ -3778,6 +3916,73 @@ func (m *MsgStoreAndMigrateContractResponse) MarshalToSizedBuffer(dAtA []byte) (
return len(dAtA) - i, nil
}
+func (m *MsgUpdateContractLabel) 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 *MsgUpdateContractLabel) MarshalTo(dAtA []byte) (int, error) {
+ size := m.Size()
+ return m.MarshalToSizedBuffer(dAtA[:size])
+}
+
+func (m *MsgUpdateContractLabel) MarshalToSizedBuffer(dAtA []byte) (int, error) {
+ i := len(dAtA)
+ _ = i
+ var l int
+ _ = l
+ if len(m.Contract) > 0 {
+ i -= len(m.Contract)
+ copy(dAtA[i:], m.Contract)
+ i = encodeVarintTx(dAtA, i, uint64(len(m.Contract)))
+ i--
+ dAtA[i] = 0x1a
+ }
+ if len(m.NewLabel) > 0 {
+ i -= len(m.NewLabel)
+ copy(dAtA[i:], m.NewLabel)
+ i = encodeVarintTx(dAtA, i, uint64(len(m.NewLabel)))
+ i--
+ dAtA[i] = 0x12
+ }
+ if len(m.Sender) > 0 {
+ i -= len(m.Sender)
+ copy(dAtA[i:], m.Sender)
+ i = encodeVarintTx(dAtA, i, uint64(len(m.Sender)))
+ i--
+ dAtA[i] = 0xa
+ }
+ return len(dAtA) - i, nil
+}
+
+func (m *MsgUpdateContractLabelResponse) 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 *MsgUpdateContractLabelResponse) MarshalTo(dAtA []byte) (int, error) {
+ size := m.Size()
+ return m.MarshalToSizedBuffer(dAtA[:size])
+}
+
+func (m *MsgUpdateContractLabelResponse) 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
@@ -4390,6 +4595,36 @@ func (m *MsgStoreAndMigrateContractResponse) Size() (n int) {
return n
}
+func (m *MsgUpdateContractLabel) Size() (n int) {
+ if m == nil {
+ return 0
+ }
+ var l int
+ _ = l
+ l = len(m.Sender)
+ if l > 0 {
+ n += 1 + l + sovTx(uint64(l))
+ }
+ l = len(m.NewLabel)
+ if l > 0 {
+ n += 1 + l + sovTx(uint64(l))
+ }
+ l = len(m.Contract)
+ if l > 0 {
+ n += 1 + l + sovTx(uint64(l))
+ }
+ return n
+}
+
+func (m *MsgUpdateContractLabelResponse) 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
}
@@ -8515,6 +8750,204 @@ func (m *MsgStoreAndMigrateContractResponse) Unmarshal(dAtA []byte) error {
return nil
}
+func (m *MsgUpdateContractLabel) 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: MsgUpdateContractLabel: wiretype end group for non-group")
+ }
+ if fieldNum <= 0 {
+ return fmt.Errorf("proto: MsgUpdateContractLabel: illegal tag %d (wire type %d)", fieldNum, wire)
+ }
+ switch fieldNum {
+ case 1:
+ if wireType != 2 {
+ return fmt.Errorf("proto: wrong wireType = %d for field Sender", 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.Sender = string(dAtA[iNdEx:postIndex])
+ iNdEx = postIndex
+ case 2:
+ if wireType != 2 {
+ return fmt.Errorf("proto: wrong wireType = %d for field NewLabel", 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.NewLabel = string(dAtA[iNdEx:postIndex])
+ iNdEx = postIndex
+ case 3:
+ if wireType != 2 {
+ return fmt.Errorf("proto: wrong wireType = %d for field Contract", 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.Contract = string(dAtA[iNdEx:postIndex])
+ iNdEx = postIndex
+ default:
+ iNdEx = preIndex
+ skippy, err := skipTx(dAtA[iNdEx:])
+ if err != nil {
+ return err
+ }
+ if (skippy < 0) || (iNdEx+skippy) < 0 {
+ return ErrInvalidLengthTx
+ }
+ if (iNdEx + skippy) > l {
+ return io.ErrUnexpectedEOF
+ }
+ iNdEx += skippy
+ }
+ }
+
+ if iNdEx > l {
+ return io.ErrUnexpectedEOF
+ }
+ return nil
+}
+
+func (m *MsgUpdateContractLabelResponse) 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: MsgUpdateContractLabelResponse: wiretype end group for non-group")
+ }
+ if fieldNum <= 0 {
+ return fmt.Errorf("proto: MsgUpdateContractLabelResponse: 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) || (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
diff --git a/x/wasm/types/tx_test.go b/x/wasm/types/tx_test.go
index 87f439b0ca..fea5d7e14b 100644
--- a/x/wasm/types/tx_test.go
+++ b/x/wasm/types/tx_test.go
@@ -1326,3 +1326,71 @@ func TestMsgStoreAndMigrateContractValidation(t *testing.T) {
})
}
}
+
+func TestMsgUpdateContractLabel(t *testing.T) {
+ // proper address size
+ goodAddress := sdk.AccAddress(make([]byte, 20)).String()
+ otherGoodAddress := sdk.AccAddress(bytes.Repeat([]byte{0x1}, 20)).String()
+
+ specs := map[string]struct {
+ src MsgUpdateContractLabel
+ expErr bool
+ }{
+ "all good": {
+ src: MsgUpdateContractLabel{
+ Sender: goodAddress,
+ NewLabel: "new label",
+ Contract: otherGoodAddress,
+ },
+ },
+ "new label required": {
+ src: MsgUpdateContractLabel{
+ Sender: goodAddress,
+ Contract: otherGoodAddress,
+ },
+ expErr: true,
+ },
+ "bad sender": {
+ src: MsgUpdateContractLabel{
+ Sender: badAddress,
+ NewLabel: "new label",
+ Contract: otherGoodAddress,
+ },
+ expErr: true,
+ },
+ "empty new label": {
+ src: MsgUpdateContractLabel{
+ Sender: goodAddress,
+ NewLabel: "",
+ Contract: otherGoodAddress,
+ },
+ expErr: true,
+ },
+ "bad new label": {
+ src: MsgUpdateContractLabel{
+ Sender: goodAddress,
+ NewLabel: " start with space ",
+ Contract: otherGoodAddress,
+ },
+ expErr: true,
+ },
+ "bad contract addr": {
+ src: MsgUpdateContractLabel{
+ Sender: goodAddress,
+ NewLabel: "new label",
+ Contract: badAddress,
+ },
+ expErr: true,
+ },
+ }
+ for msg, spec := range specs {
+ t.Run(msg, func(t *testing.T) {
+ err := spec.src.ValidateBasic()
+ if spec.expErr {
+ require.Error(t, err)
+ return
+ }
+ require.NoError(t, err)
+ })
+ }
+}