diff --git a/docs/proto/proto-docs.md b/docs/proto/proto-docs.md index f430151531..15c892acb3 100644 --- a/docs/proto/proto-docs.md +++ b/docs/proto/proto-docs.md @@ -887,6 +887,8 @@ Msg defines the nexus Msg service. | `fee` | [cosmos.base.v1beta1.Coin](#cosmos.base.v1beta1.Coin) | | | | `refund_recipient` | [string](#string) | | | | `asset` | [string](#string) | | registered asset name in nexus | +| `source_chain` | [string](#string) | | | +| `destination_chain` | [string](#string) | | | diff --git a/proto/axelar/axelarnet/v1beta1/events.proto b/proto/axelar/axelarnet/v1beta1/events.proto index a5e9e0a67d..8c25374d8a 100644 --- a/proto/axelar/axelarnet/v1beta1/events.proto +++ b/proto/axelar/axelarnet/v1beta1/events.proto @@ -82,6 +82,12 @@ message FeePaid { cosmos.base.v1beta1.Coin fee = 3 [ (gogoproto.nullable) = false ]; string refund_recipient = 4; string asset = 5; // registered asset name in nexus + string source_chain = 6 + [ (gogoproto.casttype) = + "github.com/axelarnetwork/axelar-core/x/nexus/exported.ChainName" ]; + string destination_chain = 7 + [ (gogoproto.casttype) = + "github.com/axelarnetwork/axelar-core/x/nexus/exported.ChainName" ]; } message ContractCallSubmitted { diff --git a/x/axelarnet/keeper/msg_server.go b/x/axelarnet/keeper/msg_server.go index 99bb342b06..ddde89acec 100644 --- a/x/axelarnet/keeper/msg_server.go +++ b/x/axelarnet/keeper/msg_server.go @@ -93,10 +93,12 @@ func (s msgServer) CallContract(c context.Context, req *types.CallContractReques } feePaidEvent := types.FeePaid{ - MessageID: msgID, - Recipient: req.Fee.Recipient, - Fee: req.Fee.Amount, - Asset: token.GetDenom(), + MessageID: msgID, + Recipient: req.Fee.Recipient, + Fee: req.Fee.Amount, + Asset: token.GetDenom(), + SourceChain: msg.GetSourceChain(), + DestinationChain: msg.GetDestinationChain(), } if req.Fee.RefundRecipient != nil { feePaidEvent.RefundRecipient = req.Fee.RefundRecipient.String() diff --git a/x/axelarnet/message_handler.go b/x/axelarnet/message_handler.go index 8c92bde012..818a097dd7 100644 --- a/x/axelarnet/message_handler.go +++ b/x/axelarnet/message_handler.go @@ -246,12 +246,6 @@ func validateMessage(ctx sdk.Context, ibcK keeper.IBCKeeper, n types.Nexus, ibcP func handleMessage(ctx sdk.Context, n types.Nexus, b types.BankKeeper, sourceAddress nexus.CrossChainAddress, msg Message, token keeper.Coin) error { id, txID, nonce := n.GenerateMessageID(ctx) - // ignore token for call contract - _, err := deductFee(ctx, b, msg.Fee, token, id) - if err != nil { - return err - } - destChain, ok := n.GetChain(ctx, nexus.ChainName(msg.DestinationChain)) if !ok { // try forwarding it to wasm router if destination chain is not registered @@ -260,6 +254,12 @@ func handleMessage(ctx sdk.Context, n types.Nexus, b types.BankKeeper, sourceAdd destChain = nexus.Chain{Name: destChainName, SupportsForeignAssets: false, KeyType: tss.None, Module: wasm.ModuleName} } + // ignore token for call contract + _, err := deductFee(ctx, b, msg.Fee, token, id, sourceAddress.Chain.Name, destChain.Name) + if err != nil { + return err + } + recipient := nexus.CrossChainAddress{Chain: destChain, Address: msg.DestinationAddress} m := nexus.NewGeneralMessage( id, @@ -287,7 +287,9 @@ func handleMessage(ctx sdk.Context, n types.Nexus, b types.BankKeeper, sourceAdd func handleMessageWithToken(ctx sdk.Context, n types.Nexus, b types.BankKeeper, sourceAddress nexus.CrossChainAddress, msg Message, token keeper.Coin) error { id, txID, nonce := n.GenerateMessageID(ctx) - token, err := deductFee(ctx, b, msg.Fee, token, id) + destChain := funcs.MustOk(n.GetChain(ctx, nexus.ChainName(msg.DestinationChain))) + + token, err := deductFee(ctx, b, msg.Fee, token, id, sourceAddress.Chain.Name, destChain.Name) if err != nil { return err } @@ -296,7 +298,6 @@ func handleMessageWithToken(ctx sdk.Context, n types.Nexus, b types.BankKeeper, return err } - destChain := funcs.MustOk(n.GetChain(ctx, nexus.ChainName(msg.DestinationChain))) recipient := nexus.CrossChainAddress{Chain: destChain, Address: msg.DestinationAddress} m := nexus.NewGeneralMessage( id, @@ -392,7 +393,7 @@ func extractTokenFromPacketData(ctx sdk.Context, ibcK keeper.IBCKeeper, n types. } // deductFee pays the fee and returns the updated transfer amount with the fee deducted -func deductFee(ctx sdk.Context, b types.BankKeeper, fee *Fee, token keeper.Coin, msgID string) (keeper.Coin, error) { +func deductFee(ctx sdk.Context, b types.BankKeeper, fee *Fee, token keeper.Coin, msgID string, sourceChain nexus.ChainName, destinationChain nexus.ChainName) (keeper.Coin, error) { if fee == nil { return token, nil } @@ -402,10 +403,12 @@ func deductFee(ctx sdk.Context, b types.BankKeeper, fee *Fee, token keeper.Coin, recipient := funcs.Must(sdk.AccAddressFromBech32(fee.Recipient)) feePaidEvent := types.FeePaid{ - MessageID: msgID, - Recipient: recipient, - Fee: coin, - Asset: token.GetDenom(), + MessageID: msgID, + Recipient: recipient, + Fee: coin, + Asset: token.GetDenom(), + SourceChain: sourceChain, + DestinationChain: destinationChain, } if fee.RefundRecipient != nil { feePaidEvent.RefundRecipient = *fee.RefundRecipient diff --git a/x/axelarnet/types/events.pb.go b/x/axelarnet/types/events.pb.go index 6a705ce1db..6c249252d6 100644 --- a/x/axelarnet/types/events.pb.go +++ b/x/axelarnet/types/events.pb.go @@ -494,11 +494,13 @@ func (*FeeCollected) XXX_MessageName() string { } type FeePaid struct { - MessageID string `protobuf:"bytes,1,opt,name=message_id,json=messageId,proto3" json:"message_id,omitempty"` - Recipient github_com_cosmos_cosmos_sdk_types.AccAddress `protobuf:"bytes,2,opt,name=recipient,proto3,casttype=github.com/cosmos/cosmos-sdk/types.AccAddress" json:"recipient,omitempty"` - Fee types.Coin `protobuf:"bytes,3,opt,name=fee,proto3" json:"fee"` - RefundRecipient string `protobuf:"bytes,4,opt,name=refund_recipient,json=refundRecipient,proto3" json:"refund_recipient,omitempty"` - Asset string `protobuf:"bytes,5,opt,name=asset,proto3" json:"asset,omitempty"` + MessageID string `protobuf:"bytes,1,opt,name=message_id,json=messageId,proto3" json:"message_id,omitempty"` + Recipient github_com_cosmos_cosmos_sdk_types.AccAddress `protobuf:"bytes,2,opt,name=recipient,proto3,casttype=github.com/cosmos/cosmos-sdk/types.AccAddress" json:"recipient,omitempty"` + Fee types.Coin `protobuf:"bytes,3,opt,name=fee,proto3" json:"fee"` + RefundRecipient string `protobuf:"bytes,4,opt,name=refund_recipient,json=refundRecipient,proto3" json:"refund_recipient,omitempty"` + Asset string `protobuf:"bytes,5,opt,name=asset,proto3" json:"asset,omitempty"` + SourceChain github_com_axelarnetwork_axelar_core_x_nexus_exported.ChainName `protobuf:"bytes,6,opt,name=source_chain,json=sourceChain,proto3,casttype=github.com/axelarnetwork/axelar-core/x/nexus/exported.ChainName" json:"source_chain,omitempty"` + DestinationChain github_com_axelarnetwork_axelar_core_x_nexus_exported.ChainName `protobuf:"bytes,7,opt,name=destination_chain,json=destinationChain,proto3,casttype=github.com/axelarnetwork/axelar-core/x/nexus/exported.ChainName" json:"destination_chain,omitempty"` } func (m *FeePaid) Reset() { *m = FeePaid{} } @@ -569,6 +571,20 @@ func (m *FeePaid) GetAsset() string { return "" } +func (m *FeePaid) GetSourceChain() github_com_axelarnetwork_axelar_core_x_nexus_exported.ChainName { + if m != nil { + return m.SourceChain + } + return "" +} + +func (m *FeePaid) GetDestinationChain() github_com_axelarnetwork_axelar_core_x_nexus_exported.ChainName { + if m != nil { + return m.DestinationChain + } + return "" +} + func (*FeePaid) XXX_MessageName() string { return "axelar.axelarnet.v1beta1.FeePaid" } @@ -878,59 +894,60 @@ func init() { } var fileDescriptor_7e862d506c60b5a3 = []byte{ - // 830 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xec, 0x57, 0x41, 0x6f, 0xe3, 0x44, - 0x14, 0xae, 0x9d, 0x6c, 0xba, 0x79, 0x0d, 0x6a, 0x77, 0x28, 0x10, 0x2a, 0xe4, 0x94, 0x20, 0xa4, - 0xae, 0x44, 0x6d, 0x15, 0x04, 0x57, 0x68, 0x5c, 0x55, 0x04, 0x09, 0x58, 0x79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e8, 0x7c, 0x16, 0x78, 0x4f, 0x67, 0x81, 0xf7, 0xeb, 0x2c, 0xf0, - 0xbe, 0xbf, 0x08, 0x56, 0xce, 0x2f, 0x02, 0xef, 0xe9, 0x45, 0xb0, 0xf2, 0xec, 0x22, 0x58, 0x79, - 0xf4, 0xc9, 0x15, 0x89, 0x2d, 0x7f, 0x89, 0xca, 0x0f, 0xc8, 0xb0, 0x51, 0xfe, 0xba, 0x7c, 0xf4, - 0x67, 0x00, 0x00, 0x00, 0xff, 0xff, 0x49, 0xfb, 0xe1, 0xd9, 0x33, 0x0d, 0x00, 0x00, + // 837 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xec, 0x57, 0x4f, 0x6f, 0xe3, 0x44, + 0x14, 0xaf, 0xed, 0x6c, 0xb2, 0x79, 0x0d, 0xea, 0xae, 0x29, 0x10, 0x2a, 0xe4, 0x94, 0x20, 0xa4, + 0x22, 0x51, 0x5b, 0x05, 0xc1, 0x15, 0x1a, 0x57, 0x15, 0x46, 0x02, 0x56, 0xde, 0x4a, 0x48, 0x7b, + 0x89, 0x26, 0xf6, 0x6b, 0x33, 0xaa, 0x33, 0x13, 0x66, 0x26, 0x4b, 0xf7, 0x5b, 0x20, 0xbe, 0x00, + 0x5f, 0xa7, 0xc7, 0xbd, 0x80, 0x56, 0x1c, 0x0c, 0xa4, 0x77, 0x3e, 0x40, 0x4f, 0xc8, 0x9e, 0x71, + 0xe2, 0x5d, 0x04, 0x6a, 0x57, 0x9b, 0x15, 0xa2, 0x7b, 0xb2, 0xe7, 0xcd, 0xd3, 0x9b, 0xf7, 0xfb, + 0x33, 0x7e, 0x32, 0xbc, 0x4f, 0xce, 0x30, 0x23, 0x22, 0xd0, 0x0f, 0x86, 0x2a, 0x78, 0xb8, 0x37, + 0x42, 0x45, 0xf6, 0x02, 0x7c, 0x88, 0x4c, 0x49, 0x7f, 0x2a, 0xb8, 0xe2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, 0xb8, 0x71, + 0xaf, 0xdb, 0x85, 0xd6, 0x94, 0x3c, 0xca, 0x38, 0xd1, 0x1f, 0xc3, 0x4e, 0x5c, 0x2d, 0xdd, 0x77, + 0xa1, 0x63, 0x5e, 0x87, 0x63, 0x22, 0xc7, 0xa5, 0xd6, 0x9d, 0x78, 0xdd, 0xc4, 0xbe, 0x20, 0x72, + 0xdc, 0xff, 0xcd, 0x01, 0xaf, 0xae, 0xd0, 0xb7, 0x54, 0x8d, 0x8f, 0xf8, 0x29, 0xb2, 0x57, 0x52, + 0xfd, 0xc7, 0xa4, 0x5a, 0xce, 0x83, 0xdb, 0xd7, 0x99, 0x07, 0xfd, 0x5f, 0x1d, 0x68, 0x6b, 0x45, + 0x8b, 0x2f, 0x90, 0x84, 0x75, 0x65, 0x46, 0xd1, 0x70, 0x31, 0xdd, 0xe2, 0x79, 0xde, 0x83, 0xe5, + 0x84, 0x7a, 0x21, 0x53, 0x0e, 0xaa, 0x63, 0x6e, 0xa4, 0x27, 0x02, 0x78, 0xbd, 0x7e, 0xe2, 0xd3, + 0xb6, 0x70, 0x6b, 0x5b, 0x95, 0x33, 0x16, 0xe2, 0x36, 0xaf, 0x23, 0xee, 0xe0, 0xe8, 0x7c, 0xee, + 0x59, 0x8f, 0xe7, 0x9e, 0xf5, 0xfb, 0xdc, 0xb3, 0x7e, 0xb8, 0xf0, 0xd6, 0xce, 0x2f, 0x3c, 0xeb, + 0xf1, 0x85, 0xb7, 0xf6, 0xe4, 0xc2, 0x5b, 0x7b, 0xf0, 0xe9, 0x15, 0x81, 0x2d, 0x7f, 0xf6, 0xca, + 0xd1, 0x38, 0x6a, 0x96, 0x3f, 0x65, 0x1f, 0xff, 0x15, 0x00, 0x00, 0xff, 0xff, 0x5b, 0x9c, 0x09, + 0x02, 0x0d, 0x0e, 0x00, 0x00, } func (m *IBCTransferSent) Marshal() (dAtA []byte, err error) { @@ -1281,6 +1298,20 @@ func (m *FeePaid) MarshalToSizedBuffer(dAtA []byte) (int, error) { _ = i var l int _ = l + if len(m.DestinationChain) > 0 { + i -= len(m.DestinationChain) + copy(dAtA[i:], m.DestinationChain) + i = encodeVarintEvents(dAtA, i, uint64(len(m.DestinationChain))) + i-- + dAtA[i] = 0x3a + } + if len(m.SourceChain) > 0 { + i -= len(m.SourceChain) + copy(dAtA[i:], m.SourceChain) + i = encodeVarintEvents(dAtA, i, uint64(len(m.SourceChain))) + i-- + dAtA[i] = 0x32 + } if len(m.Asset) > 0 { i -= len(m.Asset) copy(dAtA[i:], m.Asset) @@ -1726,6 +1757,14 @@ func (m *FeePaid) Size() (n int) { if l > 0 { n += 1 + l + sovEvents(uint64(l)) } + l = len(m.SourceChain) + if l > 0 { + n += 1 + l + sovEvents(uint64(l)) + } + l = len(m.DestinationChain) + if l > 0 { + n += 1 + l + sovEvents(uint64(l)) + } return n } @@ -3118,6 +3157,70 @@ func (m *FeePaid) Unmarshal(dAtA []byte) error { } m.Asset = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex + case 6: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field SourceChain", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowEvents + } + 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 ErrInvalidLengthEvents + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return ErrInvalidLengthEvents + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.SourceChain = github_com_axelarnetwork_axelar_core_x_nexus_exported.ChainName(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 7: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field DestinationChain", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowEvents + } + 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 ErrInvalidLengthEvents + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return ErrInvalidLengthEvents + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.DestinationChain = github_com_axelarnetwork_axelar_core_x_nexus_exported.ChainName(dAtA[iNdEx:postIndex]) + iNdEx = postIndex default: iNdEx = preIndex skippy, err := skipEvents(dAtA[iNdEx:])