From 8121d9beda5c711b937f5bb060a66ff1fc095557 Mon Sep 17 00:00:00 2001 From: keithsue Date: Tue, 14 Jan 2025 20:19:22 +0800 Subject: [PATCH] add MsgSubmitRepaymentAdaptorSignature --- api/side/lending/lending.pulsar.go | 161 ++- api/side/lending/tx.pulsar.go | 1222 +++++++++++++++-- api/side/lending/tx_grpc.pb.go | 53 +- proto/side/lending/lending.proto | 5 +- proto/side/lending/tx.proto | 13 + x/lending/keeper/msg_server.go | 47 + x/lending/types/errors.go | 11 +- x/lending/types/lending.pb.go | 182 ++- .../msg_submit_repayment_adaptor_signature.go | 28 + x/lending/types/tx.pb.go | 557 +++++++- 10 files changed, 2000 insertions(+), 279 deletions(-) create mode 100644 x/lending/types/msg_submit_repayment_adaptor_signature.go diff --git a/api/side/lending/lending.pulsar.go b/api/side/lending/lending.pulsar.go index 92e5474a..a9418601 100644 --- a/api/side/lending/lending.pulsar.go +++ b/api/side/lending/lending.pulsar.go @@ -3247,13 +3247,14 @@ func (x *fastReflection_DepositLog) ProtoMethods() *protoiface.Methods { } var ( - md_Repayment protoreflect.MessageDescriptor - fd_Repayment_loan_id protoreflect.FieldDescriptor - fd_Repayment_txid protoreflect.FieldDescriptor - fd_Repayment_tx protoreflect.FieldDescriptor - fd_Repayment_repay_adaptor_point protoreflect.FieldDescriptor - fd_Repayment_borrower_signature protoreflect.FieldDescriptor - fd_Repayment_create_at protoreflect.FieldDescriptor + md_Repayment protoreflect.MessageDescriptor + fd_Repayment_loan_id protoreflect.FieldDescriptor + fd_Repayment_txid protoreflect.FieldDescriptor + fd_Repayment_tx protoreflect.FieldDescriptor + fd_Repayment_repay_adaptor_point protoreflect.FieldDescriptor + fd_Repayment_dca_adaptor_signature protoreflect.FieldDescriptor + fd_Repayment_borrower_signature protoreflect.FieldDescriptor + fd_Repayment_create_at protoreflect.FieldDescriptor ) func init() { @@ -3263,6 +3264,7 @@ func init() { fd_Repayment_txid = md_Repayment.Fields().ByName("txid") fd_Repayment_tx = md_Repayment.Fields().ByName("tx") fd_Repayment_repay_adaptor_point = md_Repayment.Fields().ByName("repay_adaptor_point") + fd_Repayment_dca_adaptor_signature = md_Repayment.Fields().ByName("dca_adaptor_signature") fd_Repayment_borrower_signature = md_Repayment.Fields().ByName("borrower_signature") fd_Repayment_create_at = md_Repayment.Fields().ByName("create_at") } @@ -3356,6 +3358,12 @@ func (x *fastReflection_Repayment) Range(f func(protoreflect.FieldDescriptor, pr return } } + if x.DcaAdaptorSignature != "" { + value := protoreflect.ValueOfString(x.DcaAdaptorSignature) + if !f(fd_Repayment_dca_adaptor_signature, value) { + return + } + } if x.BorrowerSignature != "" { value := protoreflect.ValueOfString(x.BorrowerSignature) if !f(fd_Repayment_borrower_signature, value) { @@ -3391,6 +3399,8 @@ func (x *fastReflection_Repayment) Has(fd protoreflect.FieldDescriptor) bool { return x.Tx != "" case "side.lending.Repayment.repay_adaptor_point": return x.RepayAdaptorPoint != "" + case "side.lending.Repayment.dca_adaptor_signature": + return x.DcaAdaptorSignature != "" case "side.lending.Repayment.borrower_signature": return x.BorrowerSignature != "" case "side.lending.Repayment.create_at": @@ -3419,6 +3429,8 @@ func (x *fastReflection_Repayment) Clear(fd protoreflect.FieldDescriptor) { x.Tx = "" case "side.lending.Repayment.repay_adaptor_point": x.RepayAdaptorPoint = "" + case "side.lending.Repayment.dca_adaptor_signature": + x.DcaAdaptorSignature = "" case "side.lending.Repayment.borrower_signature": x.BorrowerSignature = "" case "side.lending.Repayment.create_at": @@ -3451,6 +3463,9 @@ func (x *fastReflection_Repayment) Get(descriptor protoreflect.FieldDescriptor) case "side.lending.Repayment.repay_adaptor_point": value := x.RepayAdaptorPoint return protoreflect.ValueOfString(value) + case "side.lending.Repayment.dca_adaptor_signature": + value := x.DcaAdaptorSignature + return protoreflect.ValueOfString(value) case "side.lending.Repayment.borrower_signature": value := x.BorrowerSignature return protoreflect.ValueOfString(value) @@ -3485,6 +3500,8 @@ func (x *fastReflection_Repayment) Set(fd protoreflect.FieldDescriptor, value pr x.Tx = value.Interface().(string) case "side.lending.Repayment.repay_adaptor_point": x.RepayAdaptorPoint = value.Interface().(string) + case "side.lending.Repayment.dca_adaptor_signature": + x.DcaAdaptorSignature = value.Interface().(string) case "side.lending.Repayment.borrower_signature": x.BorrowerSignature = value.Interface().(string) case "side.lending.Repayment.create_at": @@ -3522,6 +3539,8 @@ func (x *fastReflection_Repayment) Mutable(fd protoreflect.FieldDescriptor) prot panic(fmt.Errorf("field tx of message side.lending.Repayment is not mutable")) case "side.lending.Repayment.repay_adaptor_point": panic(fmt.Errorf("field repay_adaptor_point of message side.lending.Repayment is not mutable")) + case "side.lending.Repayment.dca_adaptor_signature": + panic(fmt.Errorf("field dca_adaptor_signature of message side.lending.Repayment is not mutable")) case "side.lending.Repayment.borrower_signature": panic(fmt.Errorf("field borrower_signature of message side.lending.Repayment is not mutable")) default: @@ -3545,6 +3564,8 @@ func (x *fastReflection_Repayment) NewField(fd protoreflect.FieldDescriptor) pro return protoreflect.ValueOfString("") case "side.lending.Repayment.repay_adaptor_point": return protoreflect.ValueOfString("") + case "side.lending.Repayment.dca_adaptor_signature": + return protoreflect.ValueOfString("") case "side.lending.Repayment.borrower_signature": return protoreflect.ValueOfString("") case "side.lending.Repayment.create_at": @@ -3635,6 +3656,10 @@ func (x *fastReflection_Repayment) ProtoMethods() *protoiface.Methods { if l > 0 { n += 1 + l + runtime.Sov(uint64(l)) } + l = len(x.DcaAdaptorSignature) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } l = len(x.BorrowerSignature) if l > 0 { n += 1 + l + runtime.Sov(uint64(l)) @@ -3684,13 +3709,20 @@ func (x *fastReflection_Repayment) ProtoMethods() *protoiface.Methods { copy(dAtA[i:], encoded) i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) i-- - dAtA[i] = 0x32 + dAtA[i] = 0x3a } if len(x.BorrowerSignature) > 0 { i -= len(x.BorrowerSignature) copy(dAtA[i:], x.BorrowerSignature) i = runtime.EncodeVarint(dAtA, i, uint64(len(x.BorrowerSignature))) i-- + dAtA[i] = 0x32 + } + if len(x.DcaAdaptorSignature) > 0 { + i -= len(x.DcaAdaptorSignature) + copy(dAtA[i:], x.DcaAdaptorSignature) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.DcaAdaptorSignature))) + i-- dAtA[i] = 0x2a } if len(x.RepayAdaptorPoint) > 0 { @@ -3899,6 +3931,38 @@ func (x *fastReflection_Repayment) ProtoMethods() *protoiface.Methods { x.RepayAdaptorPoint = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 5: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field DcaAdaptorSignature", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.DcaAdaptorSignature = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 6: if wireType != 2 { return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field BorrowerSignature", wireType) } @@ -3930,7 +3994,7 @@ func (x *fastReflection_Repayment) ProtoMethods() *protoiface.Methods { } x.BorrowerSignature = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex - case 6: + case 7: if wireType != 2 { return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field CreateAt", wireType) } @@ -4466,12 +4530,13 @@ type Repayment struct { sizeCache protoimpl.SizeCache unknownFields protoimpl.UnknownFields - LoanId string `protobuf:"bytes,1,opt,name=loan_id,json=loanId,proto3" json:"loan_id,omitempty"` - Txid string `protobuf:"bytes,2,opt,name=txid,proto3" json:"txid,omitempty"` - Tx string `protobuf:"bytes,3,opt,name=tx,proto3" json:"tx,omitempty"` - RepayAdaptorPoint string `protobuf:"bytes,4,opt,name=repay_adaptor_point,json=repayAdaptorPoint,proto3" json:"repay_adaptor_point,omitempty"` - BorrowerSignature string `protobuf:"bytes,5,opt,name=borrower_signature,json=borrowerSignature,proto3" json:"borrower_signature,omitempty"` - CreateAt *timestamppb.Timestamp `protobuf:"bytes,6,opt,name=create_at,json=createAt,proto3" json:"create_at,omitempty"` + LoanId string `protobuf:"bytes,1,opt,name=loan_id,json=loanId,proto3" json:"loan_id,omitempty"` + Txid string `protobuf:"bytes,2,opt,name=txid,proto3" json:"txid,omitempty"` + Tx string `protobuf:"bytes,3,opt,name=tx,proto3" json:"tx,omitempty"` + RepayAdaptorPoint string `protobuf:"bytes,4,opt,name=repay_adaptor_point,json=repayAdaptorPoint,proto3" json:"repay_adaptor_point,omitempty"` + DcaAdaptorSignature string `protobuf:"bytes,5,opt,name=dca_adaptor_signature,json=dcaAdaptorSignature,proto3" json:"dca_adaptor_signature,omitempty"` + BorrowerSignature string `protobuf:"bytes,6,opt,name=borrower_signature,json=borrowerSignature,proto3" json:"borrower_signature,omitempty"` + CreateAt *timestamppb.Timestamp `protobuf:"bytes,7,opt,name=create_at,json=createAt,proto3" json:"create_at,omitempty"` } func (x *Repayment) Reset() { @@ -4522,6 +4587,13 @@ func (x *Repayment) GetRepayAdaptorPoint() string { return "" } +func (x *Repayment) GetDcaAdaptorSignature() string { + if x != nil { + return x.DcaAdaptorSignature + } + return "" +} + func (x *Repayment) GetBorrowerSignature() string { if x != nil { return x.BorrowerSignature @@ -4623,40 +4695,43 @@ var file_side_lending_lending_proto_rawDesc = []byte{ 0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, 0x76, 0x61, 0x75, 0x6c, 0x74, 0x41, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x12, 0x1d, 0x0a, 0x0a, 0x64, 0x65, 0x70, 0x6f, 0x73, 0x69, 0x74, 0x5f, 0x74, 0x78, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x64, 0x65, 0x70, 0x6f, 0x73, 0x69, 0x74, 0x54, - 0x78, 0x22, 0xea, 0x01, 0x0a, 0x09, 0x52, 0x65, 0x70, 0x61, 0x79, 0x6d, 0x65, 0x6e, 0x74, 0x12, + 0x78, 0x22, 0x9e, 0x02, 0x0a, 0x09, 0x52, 0x65, 0x70, 0x61, 0x79, 0x6d, 0x65, 0x6e, 0x74, 0x12, 0x17, 0x0a, 0x07, 0x6c, 0x6f, 0x61, 0x6e, 0x5f, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x6c, 0x6f, 0x61, 0x6e, 0x49, 0x64, 0x12, 0x12, 0x0a, 0x04, 0x74, 0x78, 0x69, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x74, 0x78, 0x69, 0x64, 0x12, 0x0e, 0x0a, 0x02, 0x74, 0x78, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x74, 0x78, 0x12, 0x2e, 0x0a, 0x13, 0x72, 0x65, 0x70, 0x61, 0x79, 0x5f, 0x61, 0x64, 0x61, 0x70, 0x74, 0x6f, 0x72, 0x5f, 0x70, 0x6f, 0x69, 0x6e, 0x74, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x11, 0x72, 0x65, 0x70, 0x61, 0x79, - 0x41, 0x64, 0x61, 0x70, 0x74, 0x6f, 0x72, 0x50, 0x6f, 0x69, 0x6e, 0x74, 0x12, 0x2d, 0x0a, 0x12, - 0x62, 0x6f, 0x72, 0x72, 0x6f, 0x77, 0x65, 0x72, 0x5f, 0x73, 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, - 0x72, 0x65, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x11, 0x62, 0x6f, 0x72, 0x72, 0x6f, 0x77, - 0x65, 0x72, 0x53, 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x12, 0x41, 0x0a, 0x09, 0x63, - 0x72, 0x65, 0x61, 0x74, 0x65, 0x5f, 0x61, 0x74, 0x18, 0x06, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1a, - 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, - 0x2e, 0x54, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, 0x42, 0x08, 0xc8, 0xde, 0x1f, 0x00, - 0x90, 0xdf, 0x1f, 0x01, 0x52, 0x08, 0x63, 0x72, 0x65, 0x61, 0x74, 0x65, 0x41, 0x74, 0x2a, 0x26, - 0x0a, 0x0a, 0x50, 0x6f, 0x6f, 0x6c, 0x53, 0x74, 0x61, 0x74, 0x75, 0x73, 0x12, 0x0a, 0x0a, 0x06, - 0x41, 0x43, 0x54, 0x49, 0x56, 0x45, 0x10, 0x00, 0x12, 0x0c, 0x0a, 0x08, 0x49, 0x4e, 0x41, 0x43, - 0x54, 0x49, 0x56, 0x45, 0x10, 0x01, 0x2a, 0x64, 0x0a, 0x0a, 0x4c, 0x6f, 0x61, 0x6e, 0x53, 0x74, - 0x61, 0x74, 0x75, 0x73, 0x12, 0x09, 0x0a, 0x05, 0x41, 0x70, 0x70, 0x6c, 0x79, 0x10, 0x00, 0x12, - 0x0b, 0x0a, 0x07, 0x41, 0x70, 0x70, 0x72, 0x6f, 0x76, 0x65, 0x10, 0x01, 0x12, 0x0c, 0x0a, 0x08, - 0x44, 0x69, 0x73, 0x62, 0x75, 0x72, 0x73, 0x65, 0x10, 0x02, 0x12, 0x09, 0x0a, 0x05, 0x52, 0x65, - 0x70, 0x61, 0x79, 0x10, 0x03, 0x12, 0x0b, 0x0a, 0x07, 0x44, 0x65, 0x66, 0x61, 0x75, 0x6c, 0x74, - 0x10, 0x04, 0x12, 0x0d, 0x0a, 0x09, 0x4c, 0x69, 0x71, 0x75, 0x69, 0x64, 0x61, 0x74, 0x65, 0x10, - 0x05, 0x12, 0x09, 0x0a, 0x05, 0x43, 0x6c, 0x6f, 0x73, 0x65, 0x10, 0x06, 0x42, 0x90, 0x01, 0x0a, - 0x10, 0x63, 0x6f, 0x6d, 0x2e, 0x73, 0x69, 0x64, 0x65, 0x2e, 0x6c, 0x65, 0x6e, 0x64, 0x69, 0x6e, - 0x67, 0x42, 0x0c, 0x4c, 0x65, 0x6e, 0x64, 0x69, 0x6e, 0x67, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x50, - 0x01, 0x5a, 0x1d, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x73, 0x64, 0x6b, 0x2e, 0x69, 0x6f, 0x2f, - 0x61, 0x70, 0x69, 0x2f, 0x73, 0x69, 0x64, 0x65, 0x2f, 0x6c, 0x65, 0x6e, 0x64, 0x69, 0x6e, 0x67, - 0xa2, 0x02, 0x03, 0x53, 0x4c, 0x58, 0xaa, 0x02, 0x0c, 0x53, 0x69, 0x64, 0x65, 0x2e, 0x4c, 0x65, - 0x6e, 0x64, 0x69, 0x6e, 0x67, 0xca, 0x02, 0x0c, 0x53, 0x69, 0x64, 0x65, 0x5c, 0x4c, 0x65, 0x6e, - 0x64, 0x69, 0x6e, 0x67, 0xe2, 0x02, 0x18, 0x53, 0x69, 0x64, 0x65, 0x5c, 0x4c, 0x65, 0x6e, 0x64, - 0x69, 0x6e, 0x67, 0x5c, 0x47, 0x50, 0x42, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0xea, - 0x02, 0x0d, 0x53, 0x69, 0x64, 0x65, 0x3a, 0x3a, 0x4c, 0x65, 0x6e, 0x64, 0x69, 0x6e, 0x67, 0x62, - 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, + 0x41, 0x64, 0x61, 0x70, 0x74, 0x6f, 0x72, 0x50, 0x6f, 0x69, 0x6e, 0x74, 0x12, 0x32, 0x0a, 0x15, + 0x64, 0x63, 0x61, 0x5f, 0x61, 0x64, 0x61, 0x70, 0x74, 0x6f, 0x72, 0x5f, 0x73, 0x69, 0x67, 0x6e, + 0x61, 0x74, 0x75, 0x72, 0x65, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x13, 0x64, 0x63, 0x61, + 0x41, 0x64, 0x61, 0x70, 0x74, 0x6f, 0x72, 0x53, 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, + 0x12, 0x2d, 0x0a, 0x12, 0x62, 0x6f, 0x72, 0x72, 0x6f, 0x77, 0x65, 0x72, 0x5f, 0x73, 0x69, 0x67, + 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x18, 0x06, 0x20, 0x01, 0x28, 0x09, 0x52, 0x11, 0x62, 0x6f, + 0x72, 0x72, 0x6f, 0x77, 0x65, 0x72, 0x53, 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x12, + 0x41, 0x0a, 0x09, 0x63, 0x72, 0x65, 0x61, 0x74, 0x65, 0x5f, 0x61, 0x74, 0x18, 0x07, 0x20, 0x01, + 0x28, 0x0b, 0x32, 0x1a, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, + 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x54, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, 0x42, 0x08, + 0xc8, 0xde, 0x1f, 0x00, 0x90, 0xdf, 0x1f, 0x01, 0x52, 0x08, 0x63, 0x72, 0x65, 0x61, 0x74, 0x65, + 0x41, 0x74, 0x2a, 0x26, 0x0a, 0x0a, 0x50, 0x6f, 0x6f, 0x6c, 0x53, 0x74, 0x61, 0x74, 0x75, 0x73, + 0x12, 0x0a, 0x0a, 0x06, 0x41, 0x43, 0x54, 0x49, 0x56, 0x45, 0x10, 0x00, 0x12, 0x0c, 0x0a, 0x08, + 0x49, 0x4e, 0x41, 0x43, 0x54, 0x49, 0x56, 0x45, 0x10, 0x01, 0x2a, 0x64, 0x0a, 0x0a, 0x4c, 0x6f, + 0x61, 0x6e, 0x53, 0x74, 0x61, 0x74, 0x75, 0x73, 0x12, 0x09, 0x0a, 0x05, 0x41, 0x70, 0x70, 0x6c, + 0x79, 0x10, 0x00, 0x12, 0x0b, 0x0a, 0x07, 0x41, 0x70, 0x70, 0x72, 0x6f, 0x76, 0x65, 0x10, 0x01, + 0x12, 0x0c, 0x0a, 0x08, 0x44, 0x69, 0x73, 0x62, 0x75, 0x72, 0x73, 0x65, 0x10, 0x02, 0x12, 0x09, + 0x0a, 0x05, 0x52, 0x65, 0x70, 0x61, 0x79, 0x10, 0x03, 0x12, 0x0b, 0x0a, 0x07, 0x44, 0x65, 0x66, + 0x61, 0x75, 0x6c, 0x74, 0x10, 0x04, 0x12, 0x0d, 0x0a, 0x09, 0x4c, 0x69, 0x71, 0x75, 0x69, 0x64, + 0x61, 0x74, 0x65, 0x10, 0x05, 0x12, 0x09, 0x0a, 0x05, 0x43, 0x6c, 0x6f, 0x73, 0x65, 0x10, 0x06, + 0x42, 0x90, 0x01, 0x0a, 0x10, 0x63, 0x6f, 0x6d, 0x2e, 0x73, 0x69, 0x64, 0x65, 0x2e, 0x6c, 0x65, + 0x6e, 0x64, 0x69, 0x6e, 0x67, 0x42, 0x0c, 0x4c, 0x65, 0x6e, 0x64, 0x69, 0x6e, 0x67, 0x50, 0x72, + 0x6f, 0x74, 0x6f, 0x50, 0x01, 0x5a, 0x1d, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x73, 0x64, 0x6b, + 0x2e, 0x69, 0x6f, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x73, 0x69, 0x64, 0x65, 0x2f, 0x6c, 0x65, 0x6e, + 0x64, 0x69, 0x6e, 0x67, 0xa2, 0x02, 0x03, 0x53, 0x4c, 0x58, 0xaa, 0x02, 0x0c, 0x53, 0x69, 0x64, + 0x65, 0x2e, 0x4c, 0x65, 0x6e, 0x64, 0x69, 0x6e, 0x67, 0xca, 0x02, 0x0c, 0x53, 0x69, 0x64, 0x65, + 0x5c, 0x4c, 0x65, 0x6e, 0x64, 0x69, 0x6e, 0x67, 0xe2, 0x02, 0x18, 0x53, 0x69, 0x64, 0x65, 0x5c, + 0x4c, 0x65, 0x6e, 0x64, 0x69, 0x6e, 0x67, 0x5c, 0x47, 0x50, 0x42, 0x4d, 0x65, 0x74, 0x61, 0x64, + 0x61, 0x74, 0x61, 0xea, 0x02, 0x0d, 0x53, 0x69, 0x64, 0x65, 0x3a, 0x3a, 0x4c, 0x65, 0x6e, 0x64, + 0x69, 0x6e, 0x67, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, } var ( diff --git a/api/side/lending/tx.pulsar.go b/api/side/lending/tx.pulsar.go index f322a36e..6870b9e8 100644 --- a/api/side/lending/tx.pulsar.go +++ b/api/side/lending/tx.pulsar.go @@ -7070,6 +7070,910 @@ func (x *fastReflection_MsgApproveResponse) ProtoMethods() *protoiface.Methods { } } +var ( + md_MsgSubmitRepaymentAdaptorSignature protoreflect.MessageDescriptor + fd_MsgSubmitRepaymentAdaptorSignature_relayer protoreflect.FieldDescriptor + fd_MsgSubmitRepaymentAdaptorSignature_loan_id protoreflect.FieldDescriptor + fd_MsgSubmitRepaymentAdaptorSignature_adaptor_signature protoreflect.FieldDescriptor +) + +func init() { + file_side_lending_tx_proto_init() + md_MsgSubmitRepaymentAdaptorSignature = File_side_lending_tx_proto.Messages().ByName("MsgSubmitRepaymentAdaptorSignature") + fd_MsgSubmitRepaymentAdaptorSignature_relayer = md_MsgSubmitRepaymentAdaptorSignature.Fields().ByName("relayer") + fd_MsgSubmitRepaymentAdaptorSignature_loan_id = md_MsgSubmitRepaymentAdaptorSignature.Fields().ByName("loan_id") + fd_MsgSubmitRepaymentAdaptorSignature_adaptor_signature = md_MsgSubmitRepaymentAdaptorSignature.Fields().ByName("adaptor_signature") +} + +var _ protoreflect.Message = (*fastReflection_MsgSubmitRepaymentAdaptorSignature)(nil) + +type fastReflection_MsgSubmitRepaymentAdaptorSignature MsgSubmitRepaymentAdaptorSignature + +func (x *MsgSubmitRepaymentAdaptorSignature) ProtoReflect() protoreflect.Message { + return (*fastReflection_MsgSubmitRepaymentAdaptorSignature)(x) +} + +func (x *MsgSubmitRepaymentAdaptorSignature) slowProtoReflect() protoreflect.Message { + mi := &file_side_lending_tx_proto_msgTypes[14] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_MsgSubmitRepaymentAdaptorSignature_messageType fastReflection_MsgSubmitRepaymentAdaptorSignature_messageType +var _ protoreflect.MessageType = fastReflection_MsgSubmitRepaymentAdaptorSignature_messageType{} + +type fastReflection_MsgSubmitRepaymentAdaptorSignature_messageType struct{} + +func (x fastReflection_MsgSubmitRepaymentAdaptorSignature_messageType) Zero() protoreflect.Message { + return (*fastReflection_MsgSubmitRepaymentAdaptorSignature)(nil) +} +func (x fastReflection_MsgSubmitRepaymentAdaptorSignature_messageType) New() protoreflect.Message { + return new(fastReflection_MsgSubmitRepaymentAdaptorSignature) +} +func (x fastReflection_MsgSubmitRepaymentAdaptorSignature_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_MsgSubmitRepaymentAdaptorSignature +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_MsgSubmitRepaymentAdaptorSignature) Descriptor() protoreflect.MessageDescriptor { + return md_MsgSubmitRepaymentAdaptorSignature +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_MsgSubmitRepaymentAdaptorSignature) Type() protoreflect.MessageType { + return _fastReflection_MsgSubmitRepaymentAdaptorSignature_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_MsgSubmitRepaymentAdaptorSignature) New() protoreflect.Message { + return new(fastReflection_MsgSubmitRepaymentAdaptorSignature) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_MsgSubmitRepaymentAdaptorSignature) Interface() protoreflect.ProtoMessage { + return (*MsgSubmitRepaymentAdaptorSignature)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_MsgSubmitRepaymentAdaptorSignature) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.Relayer != "" { + value := protoreflect.ValueOfString(x.Relayer) + if !f(fd_MsgSubmitRepaymentAdaptorSignature_relayer, value) { + return + } + } + if x.LoanId != "" { + value := protoreflect.ValueOfString(x.LoanId) + if !f(fd_MsgSubmitRepaymentAdaptorSignature_loan_id, value) { + return + } + } + if x.AdaptorSignature != "" { + value := protoreflect.ValueOfString(x.AdaptorSignature) + if !f(fd_MsgSubmitRepaymentAdaptorSignature_adaptor_signature, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_MsgSubmitRepaymentAdaptorSignature) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "side.lending.MsgSubmitRepaymentAdaptorSignature.relayer": + return x.Relayer != "" + case "side.lending.MsgSubmitRepaymentAdaptorSignature.loan_id": + return x.LoanId != "" + case "side.lending.MsgSubmitRepaymentAdaptorSignature.adaptor_signature": + return x.AdaptorSignature != "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: side.lending.MsgSubmitRepaymentAdaptorSignature")) + } + panic(fmt.Errorf("message side.lending.MsgSubmitRepaymentAdaptorSignature does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgSubmitRepaymentAdaptorSignature) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "side.lending.MsgSubmitRepaymentAdaptorSignature.relayer": + x.Relayer = "" + case "side.lending.MsgSubmitRepaymentAdaptorSignature.loan_id": + x.LoanId = "" + case "side.lending.MsgSubmitRepaymentAdaptorSignature.adaptor_signature": + x.AdaptorSignature = "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: side.lending.MsgSubmitRepaymentAdaptorSignature")) + } + panic(fmt.Errorf("message side.lending.MsgSubmitRepaymentAdaptorSignature does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_MsgSubmitRepaymentAdaptorSignature) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "side.lending.MsgSubmitRepaymentAdaptorSignature.relayer": + value := x.Relayer + return protoreflect.ValueOfString(value) + case "side.lending.MsgSubmitRepaymentAdaptorSignature.loan_id": + value := x.LoanId + return protoreflect.ValueOfString(value) + case "side.lending.MsgSubmitRepaymentAdaptorSignature.adaptor_signature": + value := x.AdaptorSignature + return protoreflect.ValueOfString(value) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: side.lending.MsgSubmitRepaymentAdaptorSignature")) + } + panic(fmt.Errorf("message side.lending.MsgSubmitRepaymentAdaptorSignature does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgSubmitRepaymentAdaptorSignature) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "side.lending.MsgSubmitRepaymentAdaptorSignature.relayer": + x.Relayer = value.Interface().(string) + case "side.lending.MsgSubmitRepaymentAdaptorSignature.loan_id": + x.LoanId = value.Interface().(string) + case "side.lending.MsgSubmitRepaymentAdaptorSignature.adaptor_signature": + x.AdaptorSignature = value.Interface().(string) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: side.lending.MsgSubmitRepaymentAdaptorSignature")) + } + panic(fmt.Errorf("message side.lending.MsgSubmitRepaymentAdaptorSignature does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgSubmitRepaymentAdaptorSignature) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "side.lending.MsgSubmitRepaymentAdaptorSignature.relayer": + panic(fmt.Errorf("field relayer of message side.lending.MsgSubmitRepaymentAdaptorSignature is not mutable")) + case "side.lending.MsgSubmitRepaymentAdaptorSignature.loan_id": + panic(fmt.Errorf("field loan_id of message side.lending.MsgSubmitRepaymentAdaptorSignature is not mutable")) + case "side.lending.MsgSubmitRepaymentAdaptorSignature.adaptor_signature": + panic(fmt.Errorf("field adaptor_signature of message side.lending.MsgSubmitRepaymentAdaptorSignature is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: side.lending.MsgSubmitRepaymentAdaptorSignature")) + } + panic(fmt.Errorf("message side.lending.MsgSubmitRepaymentAdaptorSignature does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_MsgSubmitRepaymentAdaptorSignature) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "side.lending.MsgSubmitRepaymentAdaptorSignature.relayer": + return protoreflect.ValueOfString("") + case "side.lending.MsgSubmitRepaymentAdaptorSignature.loan_id": + return protoreflect.ValueOfString("") + case "side.lending.MsgSubmitRepaymentAdaptorSignature.adaptor_signature": + return protoreflect.ValueOfString("") + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: side.lending.MsgSubmitRepaymentAdaptorSignature")) + } + panic(fmt.Errorf("message side.lending.MsgSubmitRepaymentAdaptorSignature does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_MsgSubmitRepaymentAdaptorSignature) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in side.lending.MsgSubmitRepaymentAdaptorSignature", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_MsgSubmitRepaymentAdaptorSignature) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgSubmitRepaymentAdaptorSignature) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_MsgSubmitRepaymentAdaptorSignature) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_MsgSubmitRepaymentAdaptorSignature) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*MsgSubmitRepaymentAdaptorSignature) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + l = len(x.Relayer) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + l = len(x.LoanId) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + l = len(x.AdaptorSignature) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*MsgSubmitRepaymentAdaptorSignature) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if len(x.AdaptorSignature) > 0 { + i -= len(x.AdaptorSignature) + copy(dAtA[i:], x.AdaptorSignature) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.AdaptorSignature))) + i-- + dAtA[i] = 0x1a + } + if len(x.LoanId) > 0 { + i -= len(x.LoanId) + copy(dAtA[i:], x.LoanId) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.LoanId))) + i-- + dAtA[i] = 0x12 + } + if len(x.Relayer) > 0 { + i -= len(x.Relayer) + copy(dAtA[i:], x.Relayer) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Relayer))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*MsgSubmitRepaymentAdaptorSignature) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, 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 protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: MsgSubmitRepaymentAdaptorSignature: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: MsgSubmitRepaymentAdaptorSignature: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Relayer", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Relayer = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field LoanId", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.LoanId = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 3: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field AdaptorSignature", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.AdaptorSignature = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var ( + md_MsgSubmitRepaymentAdaptorSignatureResponse protoreflect.MessageDescriptor +) + +func init() { + file_side_lending_tx_proto_init() + md_MsgSubmitRepaymentAdaptorSignatureResponse = File_side_lending_tx_proto.Messages().ByName("MsgSubmitRepaymentAdaptorSignatureResponse") +} + +var _ protoreflect.Message = (*fastReflection_MsgSubmitRepaymentAdaptorSignatureResponse)(nil) + +type fastReflection_MsgSubmitRepaymentAdaptorSignatureResponse MsgSubmitRepaymentAdaptorSignatureResponse + +func (x *MsgSubmitRepaymentAdaptorSignatureResponse) ProtoReflect() protoreflect.Message { + return (*fastReflection_MsgSubmitRepaymentAdaptorSignatureResponse)(x) +} + +func (x *MsgSubmitRepaymentAdaptorSignatureResponse) slowProtoReflect() protoreflect.Message { + mi := &file_side_lending_tx_proto_msgTypes[15] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_MsgSubmitRepaymentAdaptorSignatureResponse_messageType fastReflection_MsgSubmitRepaymentAdaptorSignatureResponse_messageType +var _ protoreflect.MessageType = fastReflection_MsgSubmitRepaymentAdaptorSignatureResponse_messageType{} + +type fastReflection_MsgSubmitRepaymentAdaptorSignatureResponse_messageType struct{} + +func (x fastReflection_MsgSubmitRepaymentAdaptorSignatureResponse_messageType) Zero() protoreflect.Message { + return (*fastReflection_MsgSubmitRepaymentAdaptorSignatureResponse)(nil) +} +func (x fastReflection_MsgSubmitRepaymentAdaptorSignatureResponse_messageType) New() protoreflect.Message { + return new(fastReflection_MsgSubmitRepaymentAdaptorSignatureResponse) +} +func (x fastReflection_MsgSubmitRepaymentAdaptorSignatureResponse_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_MsgSubmitRepaymentAdaptorSignatureResponse +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_MsgSubmitRepaymentAdaptorSignatureResponse) Descriptor() protoreflect.MessageDescriptor { + return md_MsgSubmitRepaymentAdaptorSignatureResponse +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_MsgSubmitRepaymentAdaptorSignatureResponse) Type() protoreflect.MessageType { + return _fastReflection_MsgSubmitRepaymentAdaptorSignatureResponse_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_MsgSubmitRepaymentAdaptorSignatureResponse) New() protoreflect.Message { + return new(fastReflection_MsgSubmitRepaymentAdaptorSignatureResponse) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_MsgSubmitRepaymentAdaptorSignatureResponse) Interface() protoreflect.ProtoMessage { + return (*MsgSubmitRepaymentAdaptorSignatureResponse)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_MsgSubmitRepaymentAdaptorSignatureResponse) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_MsgSubmitRepaymentAdaptorSignatureResponse) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: side.lending.MsgSubmitRepaymentAdaptorSignatureResponse")) + } + panic(fmt.Errorf("message side.lending.MsgSubmitRepaymentAdaptorSignatureResponse does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgSubmitRepaymentAdaptorSignatureResponse) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: side.lending.MsgSubmitRepaymentAdaptorSignatureResponse")) + } + panic(fmt.Errorf("message side.lending.MsgSubmitRepaymentAdaptorSignatureResponse does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_MsgSubmitRepaymentAdaptorSignatureResponse) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: side.lending.MsgSubmitRepaymentAdaptorSignatureResponse")) + } + panic(fmt.Errorf("message side.lending.MsgSubmitRepaymentAdaptorSignatureResponse does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgSubmitRepaymentAdaptorSignatureResponse) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: side.lending.MsgSubmitRepaymentAdaptorSignatureResponse")) + } + panic(fmt.Errorf("message side.lending.MsgSubmitRepaymentAdaptorSignatureResponse does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgSubmitRepaymentAdaptorSignatureResponse) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: side.lending.MsgSubmitRepaymentAdaptorSignatureResponse")) + } + panic(fmt.Errorf("message side.lending.MsgSubmitRepaymentAdaptorSignatureResponse does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_MsgSubmitRepaymentAdaptorSignatureResponse) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: side.lending.MsgSubmitRepaymentAdaptorSignatureResponse")) + } + panic(fmt.Errorf("message side.lending.MsgSubmitRepaymentAdaptorSignatureResponse does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_MsgSubmitRepaymentAdaptorSignatureResponse) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in side.lending.MsgSubmitRepaymentAdaptorSignatureResponse", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_MsgSubmitRepaymentAdaptorSignatureResponse) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgSubmitRepaymentAdaptorSignatureResponse) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_MsgSubmitRepaymentAdaptorSignatureResponse) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_MsgSubmitRepaymentAdaptorSignatureResponse) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*MsgSubmitRepaymentAdaptorSignatureResponse) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*MsgSubmitRepaymentAdaptorSignatureResponse) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*MsgSubmitRepaymentAdaptorSignatureResponse) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, 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 protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: MsgSubmitRepaymentAdaptorSignatureResponse: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: MsgSubmitRepaymentAdaptorSignatureResponse: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + var ( md_MsgClose protoreflect.MessageDescriptor fd_MsgClose_relayer protoreflect.FieldDescriptor @@ -7094,7 +7998,7 @@ func (x *MsgClose) ProtoReflect() protoreflect.Message { } func (x *MsgClose) slowProtoReflect() protoreflect.Message { - mi := &file_side_lending_tx_proto_msgTypes[14] + mi := &file_side_lending_tx_proto_msgTypes[16] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -7636,7 +8540,7 @@ func (x *MsgCloseResponse) ProtoReflect() protoreflect.Message { } func (x *MsgCloseResponse) slowProtoReflect() protoreflect.Message { - mi := &file_side_lending_tx_proto_msgTypes[15] + mi := &file_side_lending_tx_proto_msgTypes[17] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -8609,6 +9513,83 @@ func (*MsgApproveResponse) Descriptor() ([]byte, []int) { return file_side_lending_tx_proto_rawDescGZIP(), []int{13} } +type MsgSubmitRepaymentAdaptorSignature struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + Relayer string `protobuf:"bytes,1,opt,name=relayer,proto3" json:"relayer,omitempty"` + LoanId string `protobuf:"bytes,2,opt,name=loan_id,json=loanId,proto3" json:"loan_id,omitempty"` + AdaptorSignature string `protobuf:"bytes,3,opt,name=adaptor_signature,json=adaptorSignature,proto3" json:"adaptor_signature,omitempty"` +} + +func (x *MsgSubmitRepaymentAdaptorSignature) Reset() { + *x = MsgSubmitRepaymentAdaptorSignature{} + if protoimpl.UnsafeEnabled { + mi := &file_side_lending_tx_proto_msgTypes[14] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *MsgSubmitRepaymentAdaptorSignature) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*MsgSubmitRepaymentAdaptorSignature) ProtoMessage() {} + +// Deprecated: Use MsgSubmitRepaymentAdaptorSignature.ProtoReflect.Descriptor instead. +func (*MsgSubmitRepaymentAdaptorSignature) Descriptor() ([]byte, []int) { + return file_side_lending_tx_proto_rawDescGZIP(), []int{14} +} + +func (x *MsgSubmitRepaymentAdaptorSignature) GetRelayer() string { + if x != nil { + return x.Relayer + } + return "" +} + +func (x *MsgSubmitRepaymentAdaptorSignature) GetLoanId() string { + if x != nil { + return x.LoanId + } + return "" +} + +func (x *MsgSubmitRepaymentAdaptorSignature) GetAdaptorSignature() string { + if x != nil { + return x.AdaptorSignature + } + return "" +} + +type MsgSubmitRepaymentAdaptorSignatureResponse struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields +} + +func (x *MsgSubmitRepaymentAdaptorSignatureResponse) Reset() { + *x = MsgSubmitRepaymentAdaptorSignatureResponse{} + if protoimpl.UnsafeEnabled { + mi := &file_side_lending_tx_proto_msgTypes[15] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *MsgSubmitRepaymentAdaptorSignatureResponse) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*MsgSubmitRepaymentAdaptorSignatureResponse) ProtoMessage() {} + +// Deprecated: Use MsgSubmitRepaymentAdaptorSignatureResponse.ProtoReflect.Descriptor instead. +func (*MsgSubmitRepaymentAdaptorSignatureResponse) Descriptor() ([]byte, []int) { + return file_side_lending_tx_proto_rawDescGZIP(), []int{15} +} + type MsgClose struct { state protoimpl.MessageState sizeCache protoimpl.SizeCache @@ -8622,7 +9603,7 @@ type MsgClose struct { func (x *MsgClose) Reset() { *x = MsgClose{} if protoimpl.UnsafeEnabled { - mi := &file_side_lending_tx_proto_msgTypes[14] + mi := &file_side_lending_tx_proto_msgTypes[16] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -8636,7 +9617,7 @@ func (*MsgClose) ProtoMessage() {} // Deprecated: Use MsgClose.ProtoReflect.Descriptor instead. func (*MsgClose) Descriptor() ([]byte, []int) { - return file_side_lending_tx_proto_rawDescGZIP(), []int{14} + return file_side_lending_tx_proto_rawDescGZIP(), []int{16} } func (x *MsgClose) GetRelayer() string { @@ -8669,7 +9650,7 @@ type MsgCloseResponse struct { func (x *MsgCloseResponse) Reset() { *x = MsgCloseResponse{} if protoimpl.UnsafeEnabled { - mi := &file_side_lending_tx_proto_msgTypes[15] + mi := &file_side_lending_tx_proto_msgTypes[17] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -8683,7 +9664,7 @@ func (*MsgCloseResponse) ProtoMessage() {} // Deprecated: Use MsgCloseResponse.ProtoReflect.Descriptor instead. func (*MsgCloseResponse) Descriptor() ([]byte, []int) { - return file_side_lending_tx_proto_rawDescGZIP(), []int{15} + return file_side_lending_tx_proto_rawDescGZIP(), []int{17} } var File_side_lending_tx_proto protoreflect.FileDescriptor @@ -8785,62 +9766,83 @@ var file_side_lending_tx_proto_rawDesc = []byte{ 0x18, 0x04, 0x20, 0x03, 0x28, 0x09, 0x52, 0x05, 0x70, 0x72, 0x6f, 0x6f, 0x66, 0x3a, 0x0c, 0x82, 0xe7, 0xb0, 0x2a, 0x07, 0x72, 0x65, 0x6c, 0x61, 0x79, 0x65, 0x72, 0x22, 0x14, 0x0a, 0x12, 0x4d, 0x73, 0x67, 0x41, 0x70, 0x70, 0x72, 0x6f, 0x76, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, - 0x65, 0x22, 0x69, 0x0a, 0x08, 0x4d, 0x73, 0x67, 0x43, 0x6c, 0x6f, 0x73, 0x65, 0x12, 0x18, 0x0a, - 0x07, 0x72, 0x65, 0x6c, 0x61, 0x79, 0x65, 0x72, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, - 0x72, 0x65, 0x6c, 0x61, 0x79, 0x65, 0x72, 0x12, 0x17, 0x0a, 0x07, 0x6c, 0x6f, 0x61, 0x6e, 0x5f, - 0x69, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x6c, 0x6f, 0x61, 0x6e, 0x49, 0x64, - 0x12, 0x1c, 0x0a, 0x09, 0x73, 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x18, 0x03, 0x20, - 0x01, 0x28, 0x09, 0x52, 0x09, 0x73, 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x3a, 0x0c, - 0x82, 0xe7, 0xb0, 0x2a, 0x07, 0x72, 0x65, 0x6c, 0x61, 0x79, 0x65, 0x72, 0x22, 0x12, 0x0a, 0x10, - 0x4d, 0x73, 0x67, 0x43, 0x6c, 0x6f, 0x73, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, - 0x32, 0xdf, 0x04, 0x0a, 0x03, 0x4d, 0x73, 0x67, 0x12, 0x4e, 0x0a, 0x0a, 0x43, 0x72, 0x65, 0x61, - 0x74, 0x65, 0x50, 0x6f, 0x6f, 0x6c, 0x12, 0x1b, 0x2e, 0x73, 0x69, 0x64, 0x65, 0x2e, 0x6c, 0x65, + 0x65, 0x22, 0x92, 0x01, 0x0a, 0x22, 0x4d, 0x73, 0x67, 0x53, 0x75, 0x62, 0x6d, 0x69, 0x74, 0x52, + 0x65, 0x70, 0x61, 0x79, 0x6d, 0x65, 0x6e, 0x74, 0x41, 0x64, 0x61, 0x70, 0x74, 0x6f, 0x72, 0x53, + 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x12, 0x18, 0x0a, 0x07, 0x72, 0x65, 0x6c, 0x61, + 0x79, 0x65, 0x72, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x72, 0x65, 0x6c, 0x61, 0x79, + 0x65, 0x72, 0x12, 0x17, 0x0a, 0x07, 0x6c, 0x6f, 0x61, 0x6e, 0x5f, 0x69, 0x64, 0x18, 0x02, 0x20, + 0x01, 0x28, 0x09, 0x52, 0x06, 0x6c, 0x6f, 0x61, 0x6e, 0x49, 0x64, 0x12, 0x2b, 0x0a, 0x11, 0x61, + 0x64, 0x61, 0x70, 0x74, 0x6f, 0x72, 0x5f, 0x73, 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, + 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x10, 0x61, 0x64, 0x61, 0x70, 0x74, 0x6f, 0x72, 0x53, + 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x3a, 0x0c, 0x82, 0xe7, 0xb0, 0x2a, 0x07, 0x72, + 0x65, 0x6c, 0x61, 0x79, 0x65, 0x72, 0x22, 0x2c, 0x0a, 0x2a, 0x4d, 0x73, 0x67, 0x53, 0x75, 0x62, + 0x6d, 0x69, 0x74, 0x52, 0x65, 0x70, 0x61, 0x79, 0x6d, 0x65, 0x6e, 0x74, 0x41, 0x64, 0x61, 0x70, + 0x74, 0x6f, 0x72, 0x53, 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x52, 0x65, 0x73, 0x70, + 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x69, 0x0a, 0x08, 0x4d, 0x73, 0x67, 0x43, 0x6c, 0x6f, 0x73, 0x65, + 0x12, 0x18, 0x0a, 0x07, 0x72, 0x65, 0x6c, 0x61, 0x79, 0x65, 0x72, 0x18, 0x01, 0x20, 0x01, 0x28, + 0x09, 0x52, 0x07, 0x72, 0x65, 0x6c, 0x61, 0x79, 0x65, 0x72, 0x12, 0x17, 0x0a, 0x07, 0x6c, 0x6f, + 0x61, 0x6e, 0x5f, 0x69, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x6c, 0x6f, 0x61, + 0x6e, 0x49, 0x64, 0x12, 0x1c, 0x0a, 0x09, 0x73, 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, + 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x73, 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, + 0x65, 0x3a, 0x0c, 0x82, 0xe7, 0xb0, 0x2a, 0x07, 0x72, 0x65, 0x6c, 0x61, 0x79, 0x65, 0x72, 0x22, + 0x12, 0x0a, 0x10, 0x4d, 0x73, 0x67, 0x43, 0x6c, 0x6f, 0x73, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, + 0x6e, 0x73, 0x65, 0x32, 0xef, 0x05, 0x0a, 0x03, 0x4d, 0x73, 0x67, 0x12, 0x4e, 0x0a, 0x0a, 0x43, + 0x72, 0x65, 0x61, 0x74, 0x65, 0x50, 0x6f, 0x6f, 0x6c, 0x12, 0x1b, 0x2e, 0x73, 0x69, 0x64, 0x65, + 0x2e, 0x6c, 0x65, 0x6e, 0x64, 0x69, 0x6e, 0x67, 0x2e, 0x4d, 0x73, 0x67, 0x43, 0x72, 0x65, 0x61, + 0x74, 0x65, 0x50, 0x6f, 0x6f, 0x6c, 0x1a, 0x23, 0x2e, 0x73, 0x69, 0x64, 0x65, 0x2e, 0x6c, 0x65, 0x6e, 0x64, 0x69, 0x6e, 0x67, 0x2e, 0x4d, 0x73, 0x67, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x50, - 0x6f, 0x6f, 0x6c, 0x1a, 0x23, 0x2e, 0x73, 0x69, 0x64, 0x65, 0x2e, 0x6c, 0x65, 0x6e, 0x64, 0x69, - 0x6e, 0x67, 0x2e, 0x4d, 0x73, 0x67, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x50, 0x6f, 0x6f, 0x6c, - 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x54, 0x0a, 0x0c, 0x41, 0x64, 0x64, 0x4c, - 0x69, 0x71, 0x75, 0x69, 0x64, 0x69, 0x74, 0x79, 0x12, 0x1d, 0x2e, 0x73, 0x69, 0x64, 0x65, 0x2e, - 0x6c, 0x65, 0x6e, 0x64, 0x69, 0x6e, 0x67, 0x2e, 0x4d, 0x73, 0x67, 0x41, 0x64, 0x64, 0x4c, 0x69, - 0x71, 0x75, 0x69, 0x64, 0x69, 0x74, 0x79, 0x1a, 0x25, 0x2e, 0x73, 0x69, 0x64, 0x65, 0x2e, 0x6c, - 0x65, 0x6e, 0x64, 0x69, 0x6e, 0x67, 0x2e, 0x4d, 0x73, 0x67, 0x41, 0x64, 0x64, 0x4c, 0x69, 0x71, - 0x75, 0x69, 0x64, 0x69, 0x74, 0x79, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x5d, - 0x0a, 0x0f, 0x52, 0x65, 0x6d, 0x6f, 0x76, 0x65, 0x4c, 0x69, 0x71, 0x75, 0x69, 0x64, 0x69, 0x74, - 0x79, 0x12, 0x20, 0x2e, 0x73, 0x69, 0x64, 0x65, 0x2e, 0x6c, 0x65, 0x6e, 0x64, 0x69, 0x6e, 0x67, - 0x2e, 0x4d, 0x73, 0x67, 0x52, 0x65, 0x6d, 0x6f, 0x76, 0x65, 0x4c, 0x69, 0x71, 0x75, 0x69, 0x64, - 0x69, 0x74, 0x79, 0x1a, 0x28, 0x2e, 0x73, 0x69, 0x64, 0x65, 0x2e, 0x6c, 0x65, 0x6e, 0x64, 0x69, - 0x6e, 0x67, 0x2e, 0x4d, 0x73, 0x67, 0x52, 0x65, 0x6d, 0x6f, 0x76, 0x65, 0x4c, 0x69, 0x71, 0x75, - 0x69, 0x64, 0x69, 0x74, 0x79, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x3f, 0x0a, - 0x05, 0x41, 0x70, 0x70, 0x6c, 0x79, 0x12, 0x16, 0x2e, 0x73, 0x69, 0x64, 0x65, 0x2e, 0x6c, 0x65, - 0x6e, 0x64, 0x69, 0x6e, 0x67, 0x2e, 0x4d, 0x73, 0x67, 0x41, 0x70, 0x70, 0x6c, 0x79, 0x1a, 0x1e, + 0x6f, 0x6f, 0x6c, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x54, 0x0a, 0x0c, 0x41, + 0x64, 0x64, 0x4c, 0x69, 0x71, 0x75, 0x69, 0x64, 0x69, 0x74, 0x79, 0x12, 0x1d, 0x2e, 0x73, 0x69, + 0x64, 0x65, 0x2e, 0x6c, 0x65, 0x6e, 0x64, 0x69, 0x6e, 0x67, 0x2e, 0x4d, 0x73, 0x67, 0x41, 0x64, + 0x64, 0x4c, 0x69, 0x71, 0x75, 0x69, 0x64, 0x69, 0x74, 0x79, 0x1a, 0x25, 0x2e, 0x73, 0x69, 0x64, + 0x65, 0x2e, 0x6c, 0x65, 0x6e, 0x64, 0x69, 0x6e, 0x67, 0x2e, 0x4d, 0x73, 0x67, 0x41, 0x64, 0x64, + 0x4c, 0x69, 0x71, 0x75, 0x69, 0x64, 0x69, 0x74, 0x79, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, + 0x65, 0x12, 0x5d, 0x0a, 0x0f, 0x52, 0x65, 0x6d, 0x6f, 0x76, 0x65, 0x4c, 0x69, 0x71, 0x75, 0x69, + 0x64, 0x69, 0x74, 0x79, 0x12, 0x20, 0x2e, 0x73, 0x69, 0x64, 0x65, 0x2e, 0x6c, 0x65, 0x6e, 0x64, + 0x69, 0x6e, 0x67, 0x2e, 0x4d, 0x73, 0x67, 0x52, 0x65, 0x6d, 0x6f, 0x76, 0x65, 0x4c, 0x69, 0x71, + 0x75, 0x69, 0x64, 0x69, 0x74, 0x79, 0x1a, 0x28, 0x2e, 0x73, 0x69, 0x64, 0x65, 0x2e, 0x6c, 0x65, + 0x6e, 0x64, 0x69, 0x6e, 0x67, 0x2e, 0x4d, 0x73, 0x67, 0x52, 0x65, 0x6d, 0x6f, 0x76, 0x65, 0x4c, + 0x69, 0x71, 0x75, 0x69, 0x64, 0x69, 0x74, 0x79, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, + 0x12, 0x3f, 0x0a, 0x05, 0x41, 0x70, 0x70, 0x6c, 0x79, 0x12, 0x16, 0x2e, 0x73, 0x69, 0x64, 0x65, + 0x2e, 0x6c, 0x65, 0x6e, 0x64, 0x69, 0x6e, 0x67, 0x2e, 0x4d, 0x73, 0x67, 0x41, 0x70, 0x70, 0x6c, + 0x79, 0x1a, 0x1e, 0x2e, 0x73, 0x69, 0x64, 0x65, 0x2e, 0x6c, 0x65, 0x6e, 0x64, 0x69, 0x6e, 0x67, + 0x2e, 0x4d, 0x73, 0x67, 0x41, 0x70, 0x70, 0x6c, 0x79, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, + 0x65, 0x12, 0x45, 0x0a, 0x07, 0x41, 0x70, 0x70, 0x72, 0x6f, 0x76, 0x65, 0x12, 0x18, 0x2e, 0x73, + 0x69, 0x64, 0x65, 0x2e, 0x6c, 0x65, 0x6e, 0x64, 0x69, 0x6e, 0x67, 0x2e, 0x4d, 0x73, 0x67, 0x41, + 0x70, 0x70, 0x72, 0x6f, 0x76, 0x65, 0x1a, 0x20, 0x2e, 0x73, 0x69, 0x64, 0x65, 0x2e, 0x6c, 0x65, + 0x6e, 0x64, 0x69, 0x6e, 0x67, 0x2e, 0x4d, 0x73, 0x67, 0x41, 0x70, 0x70, 0x72, 0x6f, 0x76, 0x65, + 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x42, 0x0a, 0x06, 0x52, 0x65, 0x64, 0x65, + 0x65, 0x6d, 0x12, 0x17, 0x2e, 0x73, 0x69, 0x64, 0x65, 0x2e, 0x6c, 0x65, 0x6e, 0x64, 0x69, 0x6e, + 0x67, 0x2e, 0x4d, 0x73, 0x67, 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, 0x1a, 0x1f, 0x2e, 0x73, 0x69, + 0x64, 0x65, 0x2e, 0x6c, 0x65, 0x6e, 0x64, 0x69, 0x6e, 0x67, 0x2e, 0x4d, 0x73, 0x67, 0x52, 0x65, + 0x64, 0x65, 0x65, 0x6d, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x3f, 0x0a, 0x05, + 0x52, 0x65, 0x70, 0x61, 0x79, 0x12, 0x16, 0x2e, 0x73, 0x69, 0x64, 0x65, 0x2e, 0x6c, 0x65, 0x6e, + 0x64, 0x69, 0x6e, 0x67, 0x2e, 0x4d, 0x73, 0x67, 0x52, 0x65, 0x70, 0x61, 0x79, 0x1a, 0x1e, 0x2e, + 0x73, 0x69, 0x64, 0x65, 0x2e, 0x6c, 0x65, 0x6e, 0x64, 0x69, 0x6e, 0x67, 0x2e, 0x4d, 0x73, 0x67, + 0x52, 0x65, 0x70, 0x61, 0x79, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x8d, 0x01, + 0x0a, 0x1f, 0x53, 0x75, 0x62, 0x6d, 0x69, 0x74, 0x52, 0x65, 0x70, 0x61, 0x79, 0x6d, 0x65, 0x6e, + 0x74, 0x41, 0x64, 0x61, 0x70, 0x74, 0x6f, 0x72, 0x53, 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, + 0x65, 0x12, 0x30, 0x2e, 0x73, 0x69, 0x64, 0x65, 0x2e, 0x6c, 0x65, 0x6e, 0x64, 0x69, 0x6e, 0x67, + 0x2e, 0x4d, 0x73, 0x67, 0x53, 0x75, 0x62, 0x6d, 0x69, 0x74, 0x52, 0x65, 0x70, 0x61, 0x79, 0x6d, + 0x65, 0x6e, 0x74, 0x41, 0x64, 0x61, 0x70, 0x74, 0x6f, 0x72, 0x53, 0x69, 0x67, 0x6e, 0x61, 0x74, + 0x75, 0x72, 0x65, 0x1a, 0x38, 0x2e, 0x73, 0x69, 0x64, 0x65, 0x2e, 0x6c, 0x65, 0x6e, 0x64, 0x69, + 0x6e, 0x67, 0x2e, 0x4d, 0x73, 0x67, 0x53, 0x75, 0x62, 0x6d, 0x69, 0x74, 0x52, 0x65, 0x70, 0x61, + 0x79, 0x6d, 0x65, 0x6e, 0x74, 0x41, 0x64, 0x61, 0x70, 0x74, 0x6f, 0x72, 0x53, 0x69, 0x67, 0x6e, + 0x61, 0x74, 0x75, 0x72, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x3f, 0x0a, + 0x05, 0x43, 0x6c, 0x6f, 0x73, 0x65, 0x12, 0x16, 0x2e, 0x73, 0x69, 0x64, 0x65, 0x2e, 0x6c, 0x65, + 0x6e, 0x64, 0x69, 0x6e, 0x67, 0x2e, 0x4d, 0x73, 0x67, 0x43, 0x6c, 0x6f, 0x73, 0x65, 0x1a, 0x1e, 0x2e, 0x73, 0x69, 0x64, 0x65, 0x2e, 0x6c, 0x65, 0x6e, 0x64, 0x69, 0x6e, 0x67, 0x2e, 0x4d, 0x73, - 0x67, 0x41, 0x70, 0x70, 0x6c, 0x79, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x45, - 0x0a, 0x07, 0x41, 0x70, 0x70, 0x72, 0x6f, 0x76, 0x65, 0x12, 0x18, 0x2e, 0x73, 0x69, 0x64, 0x65, - 0x2e, 0x6c, 0x65, 0x6e, 0x64, 0x69, 0x6e, 0x67, 0x2e, 0x4d, 0x73, 0x67, 0x41, 0x70, 0x70, 0x72, - 0x6f, 0x76, 0x65, 0x1a, 0x20, 0x2e, 0x73, 0x69, 0x64, 0x65, 0x2e, 0x6c, 0x65, 0x6e, 0x64, 0x69, - 0x6e, 0x67, 0x2e, 0x4d, 0x73, 0x67, 0x41, 0x70, 0x70, 0x72, 0x6f, 0x76, 0x65, 0x52, 0x65, 0x73, - 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x42, 0x0a, 0x06, 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, 0x12, - 0x17, 0x2e, 0x73, 0x69, 0x64, 0x65, 0x2e, 0x6c, 0x65, 0x6e, 0x64, 0x69, 0x6e, 0x67, 0x2e, 0x4d, - 0x73, 0x67, 0x52, 0x65, 0x64, 0x65, 0x65, 0x6d, 0x1a, 0x1f, 0x2e, 0x73, 0x69, 0x64, 0x65, 0x2e, - 0x6c, 0x65, 0x6e, 0x64, 0x69, 0x6e, 0x67, 0x2e, 0x4d, 0x73, 0x67, 0x52, 0x65, 0x64, 0x65, 0x65, - 0x6d, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x3f, 0x0a, 0x05, 0x52, 0x65, 0x70, - 0x61, 0x79, 0x12, 0x16, 0x2e, 0x73, 0x69, 0x64, 0x65, 0x2e, 0x6c, 0x65, 0x6e, 0x64, 0x69, 0x6e, - 0x67, 0x2e, 0x4d, 0x73, 0x67, 0x52, 0x65, 0x70, 0x61, 0x79, 0x1a, 0x1e, 0x2e, 0x73, 0x69, 0x64, - 0x65, 0x2e, 0x6c, 0x65, 0x6e, 0x64, 0x69, 0x6e, 0x67, 0x2e, 0x4d, 0x73, 0x67, 0x52, 0x65, 0x70, - 0x61, 0x79, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x3f, 0x0a, 0x05, 0x43, 0x6c, - 0x6f, 0x73, 0x65, 0x12, 0x16, 0x2e, 0x73, 0x69, 0x64, 0x65, 0x2e, 0x6c, 0x65, 0x6e, 0x64, 0x69, - 0x6e, 0x67, 0x2e, 0x4d, 0x73, 0x67, 0x43, 0x6c, 0x6f, 0x73, 0x65, 0x1a, 0x1e, 0x2e, 0x73, 0x69, - 0x64, 0x65, 0x2e, 0x6c, 0x65, 0x6e, 0x64, 0x69, 0x6e, 0x67, 0x2e, 0x4d, 0x73, 0x67, 0x43, 0x6c, - 0x6f, 0x73, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x1a, 0x05, 0x80, 0xe7, 0xb0, - 0x2a, 0x01, 0x42, 0x8b, 0x01, 0x0a, 0x10, 0x63, 0x6f, 0x6d, 0x2e, 0x73, 0x69, 0x64, 0x65, 0x2e, - 0x6c, 0x65, 0x6e, 0x64, 0x69, 0x6e, 0x67, 0x42, 0x07, 0x54, 0x78, 0x50, 0x72, 0x6f, 0x74, 0x6f, - 0x50, 0x01, 0x5a, 0x1d, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x73, 0x64, 0x6b, 0x2e, 0x69, 0x6f, - 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x73, 0x69, 0x64, 0x65, 0x2f, 0x6c, 0x65, 0x6e, 0x64, 0x69, 0x6e, - 0x67, 0xa2, 0x02, 0x03, 0x53, 0x4c, 0x58, 0xaa, 0x02, 0x0c, 0x53, 0x69, 0x64, 0x65, 0x2e, 0x4c, - 0x65, 0x6e, 0x64, 0x69, 0x6e, 0x67, 0xca, 0x02, 0x0c, 0x53, 0x69, 0x64, 0x65, 0x5c, 0x4c, 0x65, - 0x6e, 0x64, 0x69, 0x6e, 0x67, 0xe2, 0x02, 0x18, 0x53, 0x69, 0x64, 0x65, 0x5c, 0x4c, 0x65, 0x6e, - 0x64, 0x69, 0x6e, 0x67, 0x5c, 0x47, 0x50, 0x42, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, - 0xea, 0x02, 0x0d, 0x53, 0x69, 0x64, 0x65, 0x3a, 0x3a, 0x4c, 0x65, 0x6e, 0x64, 0x69, 0x6e, 0x67, - 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, + 0x67, 0x43, 0x6c, 0x6f, 0x73, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x1a, 0x05, + 0x80, 0xe7, 0xb0, 0x2a, 0x01, 0x42, 0x8b, 0x01, 0x0a, 0x10, 0x63, 0x6f, 0x6d, 0x2e, 0x73, 0x69, + 0x64, 0x65, 0x2e, 0x6c, 0x65, 0x6e, 0x64, 0x69, 0x6e, 0x67, 0x42, 0x07, 0x54, 0x78, 0x50, 0x72, + 0x6f, 0x74, 0x6f, 0x50, 0x01, 0x5a, 0x1d, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x73, 0x64, 0x6b, + 0x2e, 0x69, 0x6f, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x73, 0x69, 0x64, 0x65, 0x2f, 0x6c, 0x65, 0x6e, + 0x64, 0x69, 0x6e, 0x67, 0xa2, 0x02, 0x03, 0x53, 0x4c, 0x58, 0xaa, 0x02, 0x0c, 0x53, 0x69, 0x64, + 0x65, 0x2e, 0x4c, 0x65, 0x6e, 0x64, 0x69, 0x6e, 0x67, 0xca, 0x02, 0x0c, 0x53, 0x69, 0x64, 0x65, + 0x5c, 0x4c, 0x65, 0x6e, 0x64, 0x69, 0x6e, 0x67, 0xe2, 0x02, 0x18, 0x53, 0x69, 0x64, 0x65, 0x5c, + 0x4c, 0x65, 0x6e, 0x64, 0x69, 0x6e, 0x67, 0x5c, 0x47, 0x50, 0x42, 0x4d, 0x65, 0x74, 0x61, 0x64, + 0x61, 0x74, 0x61, 0xea, 0x02, 0x0d, 0x53, 0x69, 0x64, 0x65, 0x3a, 0x3a, 0x4c, 0x65, 0x6e, 0x64, + 0x69, 0x6e, 0x67, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, } var ( @@ -8855,32 +9857,34 @@ func file_side_lending_tx_proto_rawDescGZIP() []byte { return file_side_lending_tx_proto_rawDescData } -var file_side_lending_tx_proto_msgTypes = make([]protoimpl.MessageInfo, 16) +var file_side_lending_tx_proto_msgTypes = make([]protoimpl.MessageInfo, 18) var file_side_lending_tx_proto_goTypes = []interface{}{ - (*MsgCreatePool)(nil), // 0: side.lending.MsgCreatePool - (*MsgCreatePoolResponse)(nil), // 1: side.lending.MsgCreatePoolResponse - (*MsgRepay)(nil), // 2: side.lending.MsgRepay - (*MsgRepayResponse)(nil), // 3: side.lending.MsgRepayResponse - (*MsgRedeem)(nil), // 4: side.lending.MsgRedeem - (*MsgRedeemResponse)(nil), // 5: side.lending.MsgRedeemResponse - (*MsgAddLiquidity)(nil), // 6: side.lending.MsgAddLiquidity - (*MsgAddLiquidityResponse)(nil), // 7: side.lending.MsgAddLiquidityResponse - (*MsgRemoveLiquidity)(nil), // 8: side.lending.MsgRemoveLiquidity - (*MsgRemoveLiquidityResponse)(nil), // 9: side.lending.MsgRemoveLiquidityResponse - (*MsgApply)(nil), // 10: side.lending.MsgApply - (*MsgApplyResponse)(nil), // 11: side.lending.MsgApplyResponse - (*MsgApprove)(nil), // 12: side.lending.MsgApprove - (*MsgApproveResponse)(nil), // 13: side.lending.MsgApproveResponse - (*MsgClose)(nil), // 14: side.lending.MsgClose - (*MsgCloseResponse)(nil), // 15: side.lending.MsgCloseResponse - (*v1beta1.Coin)(nil), // 16: cosmos.base.v1beta1.Coin + (*MsgCreatePool)(nil), // 0: side.lending.MsgCreatePool + (*MsgCreatePoolResponse)(nil), // 1: side.lending.MsgCreatePoolResponse + (*MsgRepay)(nil), // 2: side.lending.MsgRepay + (*MsgRepayResponse)(nil), // 3: side.lending.MsgRepayResponse + (*MsgRedeem)(nil), // 4: side.lending.MsgRedeem + (*MsgRedeemResponse)(nil), // 5: side.lending.MsgRedeemResponse + (*MsgAddLiquidity)(nil), // 6: side.lending.MsgAddLiquidity + (*MsgAddLiquidityResponse)(nil), // 7: side.lending.MsgAddLiquidityResponse + (*MsgRemoveLiquidity)(nil), // 8: side.lending.MsgRemoveLiquidity + (*MsgRemoveLiquidityResponse)(nil), // 9: side.lending.MsgRemoveLiquidityResponse + (*MsgApply)(nil), // 10: side.lending.MsgApply + (*MsgApplyResponse)(nil), // 11: side.lending.MsgApplyResponse + (*MsgApprove)(nil), // 12: side.lending.MsgApprove + (*MsgApproveResponse)(nil), // 13: side.lending.MsgApproveResponse + (*MsgSubmitRepaymentAdaptorSignature)(nil), // 14: side.lending.MsgSubmitRepaymentAdaptorSignature + (*MsgSubmitRepaymentAdaptorSignatureResponse)(nil), // 15: side.lending.MsgSubmitRepaymentAdaptorSignatureResponse + (*MsgClose)(nil), // 16: side.lending.MsgClose + (*MsgCloseResponse)(nil), // 17: side.lending.MsgCloseResponse + (*v1beta1.Coin)(nil), // 18: cosmos.base.v1beta1.Coin } var file_side_lending_tx_proto_depIdxs = []int32{ - 16, // 0: side.lending.MsgAddLiquidity.amount:type_name -> cosmos.base.v1beta1.Coin - 16, // 1: side.lending.MsgAddLiquidityResponse.shares:type_name -> cosmos.base.v1beta1.Coin - 16, // 2: side.lending.MsgRemoveLiquidity.shares:type_name -> cosmos.base.v1beta1.Coin - 16, // 3: side.lending.MsgRemoveLiquidityResponse.amount:type_name -> cosmos.base.v1beta1.Coin - 16, // 4: side.lending.MsgApply.borrow_amount:type_name -> cosmos.base.v1beta1.Coin + 18, // 0: side.lending.MsgAddLiquidity.amount:type_name -> cosmos.base.v1beta1.Coin + 18, // 1: side.lending.MsgAddLiquidityResponse.shares:type_name -> cosmos.base.v1beta1.Coin + 18, // 2: side.lending.MsgRemoveLiquidity.shares:type_name -> cosmos.base.v1beta1.Coin + 18, // 3: side.lending.MsgRemoveLiquidityResponse.amount:type_name -> cosmos.base.v1beta1.Coin + 18, // 4: side.lending.MsgApply.borrow_amount:type_name -> cosmos.base.v1beta1.Coin 0, // 5: side.lending.Msg.CreatePool:input_type -> side.lending.MsgCreatePool 6, // 6: side.lending.Msg.AddLiquidity:input_type -> side.lending.MsgAddLiquidity 8, // 7: side.lending.Msg.RemoveLiquidity:input_type -> side.lending.MsgRemoveLiquidity @@ -8888,17 +9892,19 @@ var file_side_lending_tx_proto_depIdxs = []int32{ 12, // 9: side.lending.Msg.Approve:input_type -> side.lending.MsgApprove 4, // 10: side.lending.Msg.Redeem:input_type -> side.lending.MsgRedeem 2, // 11: side.lending.Msg.Repay:input_type -> side.lending.MsgRepay - 14, // 12: side.lending.Msg.Close:input_type -> side.lending.MsgClose - 1, // 13: side.lending.Msg.CreatePool:output_type -> side.lending.MsgCreatePoolResponse - 7, // 14: side.lending.Msg.AddLiquidity:output_type -> side.lending.MsgAddLiquidityResponse - 9, // 15: side.lending.Msg.RemoveLiquidity:output_type -> side.lending.MsgRemoveLiquidityResponse - 11, // 16: side.lending.Msg.Apply:output_type -> side.lending.MsgApplyResponse - 13, // 17: side.lending.Msg.Approve:output_type -> side.lending.MsgApproveResponse - 5, // 18: side.lending.Msg.Redeem:output_type -> side.lending.MsgRedeemResponse - 3, // 19: side.lending.Msg.Repay:output_type -> side.lending.MsgRepayResponse - 15, // 20: side.lending.Msg.Close:output_type -> side.lending.MsgCloseResponse - 13, // [13:21] is the sub-list for method output_type - 5, // [5:13] is the sub-list for method input_type + 14, // 12: side.lending.Msg.SubmitRepaymentAdaptorSignature:input_type -> side.lending.MsgSubmitRepaymentAdaptorSignature + 16, // 13: side.lending.Msg.Close:input_type -> side.lending.MsgClose + 1, // 14: side.lending.Msg.CreatePool:output_type -> side.lending.MsgCreatePoolResponse + 7, // 15: side.lending.Msg.AddLiquidity:output_type -> side.lending.MsgAddLiquidityResponse + 9, // 16: side.lending.Msg.RemoveLiquidity:output_type -> side.lending.MsgRemoveLiquidityResponse + 11, // 17: side.lending.Msg.Apply:output_type -> side.lending.MsgApplyResponse + 13, // 18: side.lending.Msg.Approve:output_type -> side.lending.MsgApproveResponse + 5, // 19: side.lending.Msg.Redeem:output_type -> side.lending.MsgRedeemResponse + 3, // 20: side.lending.Msg.Repay:output_type -> side.lending.MsgRepayResponse + 15, // 21: side.lending.Msg.SubmitRepaymentAdaptorSignature:output_type -> side.lending.MsgSubmitRepaymentAdaptorSignatureResponse + 17, // 22: side.lending.Msg.Close:output_type -> side.lending.MsgCloseResponse + 14, // [14:23] is the sub-list for method output_type + 5, // [5:14] is the sub-list for method input_type 5, // [5:5] is the sub-list for extension type_name 5, // [5:5] is the sub-list for extension extendee 0, // [0:5] is the sub-list for field type_name @@ -9079,7 +10085,7 @@ func file_side_lending_tx_proto_init() { } } file_side_lending_tx_proto_msgTypes[14].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*MsgClose); i { + switch v := v.(*MsgSubmitRepaymentAdaptorSignature); i { case 0: return &v.state case 1: @@ -9091,6 +10097,30 @@ func file_side_lending_tx_proto_init() { } } file_side_lending_tx_proto_msgTypes[15].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*MsgSubmitRepaymentAdaptorSignatureResponse); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_side_lending_tx_proto_msgTypes[16].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*MsgClose); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_side_lending_tx_proto_msgTypes[17].Exporter = func(v interface{}, i int) interface{} { switch v := v.(*MsgCloseResponse); i { case 0: return &v.state @@ -9109,7 +10139,7 @@ func file_side_lending_tx_proto_init() { GoPackagePath: reflect.TypeOf(x{}).PkgPath(), RawDescriptor: file_side_lending_tx_proto_rawDesc, NumEnums: 0, - NumMessages: 16, + NumMessages: 18, NumExtensions: 0, NumServices: 1, }, diff --git a/api/side/lending/tx_grpc.pb.go b/api/side/lending/tx_grpc.pb.go index 9d6013df..3a18262b 100644 --- a/api/side/lending/tx_grpc.pb.go +++ b/api/side/lending/tx_grpc.pb.go @@ -19,14 +19,15 @@ import ( const _ = grpc.SupportPackageIsVersion7 const ( - Msg_CreatePool_FullMethodName = "/side.lending.Msg/CreatePool" - Msg_AddLiquidity_FullMethodName = "/side.lending.Msg/AddLiquidity" - Msg_RemoveLiquidity_FullMethodName = "/side.lending.Msg/RemoveLiquidity" - Msg_Apply_FullMethodName = "/side.lending.Msg/Apply" - Msg_Approve_FullMethodName = "/side.lending.Msg/Approve" - Msg_Redeem_FullMethodName = "/side.lending.Msg/Redeem" - Msg_Repay_FullMethodName = "/side.lending.Msg/Repay" - Msg_Close_FullMethodName = "/side.lending.Msg/Close" + Msg_CreatePool_FullMethodName = "/side.lending.Msg/CreatePool" + Msg_AddLiquidity_FullMethodName = "/side.lending.Msg/AddLiquidity" + Msg_RemoveLiquidity_FullMethodName = "/side.lending.Msg/RemoveLiquidity" + Msg_Apply_FullMethodName = "/side.lending.Msg/Apply" + Msg_Approve_FullMethodName = "/side.lending.Msg/Approve" + Msg_Redeem_FullMethodName = "/side.lending.Msg/Redeem" + Msg_Repay_FullMethodName = "/side.lending.Msg/Repay" + Msg_SubmitRepaymentAdaptorSignature_FullMethodName = "/side.lending.Msg/SubmitRepaymentAdaptorSignature" + Msg_Close_FullMethodName = "/side.lending.Msg/Close" ) // MsgClient is the client API for Msg service. @@ -40,6 +41,7 @@ type MsgClient interface { Approve(ctx context.Context, in *MsgApprove, opts ...grpc.CallOption) (*MsgApproveResponse, error) Redeem(ctx context.Context, in *MsgRedeem, opts ...grpc.CallOption) (*MsgRedeemResponse, error) Repay(ctx context.Context, in *MsgRepay, opts ...grpc.CallOption) (*MsgRepayResponse, error) + SubmitRepaymentAdaptorSignature(ctx context.Context, in *MsgSubmitRepaymentAdaptorSignature, opts ...grpc.CallOption) (*MsgSubmitRepaymentAdaptorSignatureResponse, error) Close(ctx context.Context, in *MsgClose, opts ...grpc.CallOption) (*MsgCloseResponse, error) } @@ -114,6 +116,15 @@ func (c *msgClient) Repay(ctx context.Context, in *MsgRepay, opts ...grpc.CallOp return out, nil } +func (c *msgClient) SubmitRepaymentAdaptorSignature(ctx context.Context, in *MsgSubmitRepaymentAdaptorSignature, opts ...grpc.CallOption) (*MsgSubmitRepaymentAdaptorSignatureResponse, error) { + out := new(MsgSubmitRepaymentAdaptorSignatureResponse) + err := c.cc.Invoke(ctx, Msg_SubmitRepaymentAdaptorSignature_FullMethodName, in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + func (c *msgClient) Close(ctx context.Context, in *MsgClose, opts ...grpc.CallOption) (*MsgCloseResponse, error) { out := new(MsgCloseResponse) err := c.cc.Invoke(ctx, Msg_Close_FullMethodName, in, out, opts...) @@ -134,6 +145,7 @@ type MsgServer interface { Approve(context.Context, *MsgApprove) (*MsgApproveResponse, error) Redeem(context.Context, *MsgRedeem) (*MsgRedeemResponse, error) Repay(context.Context, *MsgRepay) (*MsgRepayResponse, error) + SubmitRepaymentAdaptorSignature(context.Context, *MsgSubmitRepaymentAdaptorSignature) (*MsgSubmitRepaymentAdaptorSignatureResponse, error) Close(context.Context, *MsgClose) (*MsgCloseResponse, error) mustEmbedUnimplementedMsgServer() } @@ -163,6 +175,9 @@ func (UnimplementedMsgServer) Redeem(context.Context, *MsgRedeem) (*MsgRedeemRes func (UnimplementedMsgServer) Repay(context.Context, *MsgRepay) (*MsgRepayResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method Repay not implemented") } +func (UnimplementedMsgServer) SubmitRepaymentAdaptorSignature(context.Context, *MsgSubmitRepaymentAdaptorSignature) (*MsgSubmitRepaymentAdaptorSignatureResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method SubmitRepaymentAdaptorSignature not implemented") +} func (UnimplementedMsgServer) Close(context.Context, *MsgClose) (*MsgCloseResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method Close not implemented") } @@ -305,6 +320,24 @@ func _Msg_Repay_Handler(srv interface{}, ctx context.Context, dec func(interface return interceptor(ctx, in, info, handler) } +func _Msg_SubmitRepaymentAdaptorSignature_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(MsgSubmitRepaymentAdaptorSignature) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(MsgServer).SubmitRepaymentAdaptorSignature(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: Msg_SubmitRepaymentAdaptorSignature_FullMethodName, + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(MsgServer).SubmitRepaymentAdaptorSignature(ctx, req.(*MsgSubmitRepaymentAdaptorSignature)) + } + return interceptor(ctx, in, info, handler) +} + func _Msg_Close_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(MsgClose) if err := dec(in); err != nil { @@ -358,6 +391,10 @@ var Msg_ServiceDesc = grpc.ServiceDesc{ MethodName: "Repay", Handler: _Msg_Repay_Handler, }, + { + MethodName: "SubmitRepaymentAdaptorSignature", + Handler: _Msg_SubmitRepaymentAdaptorSignature_Handler, + }, { MethodName: "Close", Handler: _Msg_Close_Handler, diff --git a/proto/side/lending/lending.proto b/proto/side/lending/lending.proto index 2a554323..074c0236 100644 --- a/proto/side/lending/lending.proto +++ b/proto/side/lending/lending.proto @@ -94,6 +94,7 @@ message Repayment { string txid = 2; string tx = 3; string repay_adaptor_point = 4; - string borrower_signature = 5; - google.protobuf.Timestamp create_at = 6 [(gogoproto.nullable) = false, (gogoproto.stdtime) = true]; + string dca_adaptor_signature = 5; + string borrower_signature = 6; + google.protobuf.Timestamp create_at = 7 [(gogoproto.nullable) = false, (gogoproto.stdtime) = true]; } \ No newline at end of file diff --git a/proto/side/lending/tx.proto b/proto/side/lending/tx.proto index b072a58b..7a806137 100644 --- a/proto/side/lending/tx.proto +++ b/proto/side/lending/tx.proto @@ -18,6 +18,7 @@ service Msg { rpc Approve(MsgApprove) returns (MsgApproveResponse); rpc Redeem(MsgRedeem) returns (MsgRedeemResponse); rpc Repay(MsgRepay) returns (MsgRepayResponse); + rpc SubmitRepaymentAdaptorSignature(MsgSubmitRepaymentAdaptorSignature) returns (MsgSubmitRepaymentAdaptorSignatureResponse); rpc Close(MsgClose) returns (MsgCloseResponse); } @@ -107,6 +108,18 @@ message MsgApproveResponse { } +message MsgSubmitRepaymentAdaptorSignature { + option (cosmos.msg.v1.signer) = "relayer"; + + string relayer = 1; + string loan_id = 2; + string adaptor_signature = 3; +} + +message MsgSubmitRepaymentAdaptorSignatureResponse { + +} + message MsgClose { option (cosmos.msg.v1.signer) = "relayer"; diff --git a/x/lending/keeper/msg_server.go b/x/lending/keeper/msg_server.go index d45a3b60..7aaebd31 100644 --- a/x/lending/keeper/msg_server.go +++ b/x/lending/keeper/msg_server.go @@ -4,6 +4,7 @@ import ( "bytes" "context" "encoding/base64" + "encoding/hex" "fmt" "cosmossdk.io/math" @@ -11,6 +12,7 @@ import ( sdk "github.com/cosmos/cosmos-sdk/types" + "github.com/sideprotocol/side/crypto/adaptor" dlc "github.com/sideprotocol/side/x/dlc/types" "github.com/sideprotocol/side/x/lending/types" ) @@ -275,6 +277,51 @@ func (m msgServer) Repay(goCtx context.Context, msg *types.MsgRepay) (*types.Msg return &types.MsgRepayResponse{}, nil } +// SubmitRepaymentAdaptorSignature implements types.MsgServer. +func (m msgServer) SubmitRepaymentAdaptorSignature(goCtx context.Context, msg *types.MsgSubmitRepaymentAdaptorSignature) (*types.MsgSubmitRepaymentAdaptorSignatureResponse, error) { + if err := msg.ValidateBasic(); err != nil { + return nil, err + } + + ctx := sdk.UnwrapSDKContext(goCtx) + + if !m.HasLoan(ctx, msg.LoanId) { + return nil, types.ErrLoanNotExists + } + + if !m.HasRepayment(ctx, msg.LoanId) { + return nil, types.ErrInvalidRepayment + } + + repayment := m.GetRepayment(ctx, msg.LoanId) + if len(repayment.DcaAdaptorSignature) != 0 { + return nil, types.ErrRepaymentAdaptorSigAlreadyExists + } + + loan := m.GetLoan(ctx, msg.LoanId) + + adaptorSigBytes, _ := hex.DecodeString(msg.AdaptorSignature) + adaptorPointBytes, _ := hex.DecodeString(repayment.RepayAdaptorPoint) + pubKeyBytes, _ := hex.DecodeString(loan.Agency) + + // TODO: calculate sig hash + sigHash := []byte{} + + if !adaptor.Verify(adaptorSigBytes, sigHash, pubKeyBytes, adaptorPointBytes) { + return nil, types.ErrInvalidAdaptorSignature + } + + repayment.DcaAdaptorSignature = msg.AdaptorSignature + m.SetRepayment(ctx, repayment) + + m.EmitEvent(ctx, msg.Relayer, + sdk.NewAttribute("loan_id", msg.LoanId), + sdk.NewAttribute("adaptor_signature", msg.AdaptorSignature), + ) + + return &types.MsgSubmitRepaymentAdaptorSignatureResponse{}, nil +} + // Close implements types.MsgServer. func (m msgServer) Close(goCtx context.Context, msg *types.MsgClose) (*types.MsgCloseResponse, error) { ctx := sdk.UnwrapSDKContext(goCtx) diff --git a/x/lending/types/errors.go b/x/lending/types/errors.go index 336cba58..20837570 100644 --- a/x/lending/types/errors.go +++ b/x/lending/types/errors.go @@ -38,8 +38,11 @@ var ( ErrEmptyLoanSecret = errorsmod.Register(ModuleName, 5002, "invalid loan secret") ErrMismatchLoanSecret = errorsmod.Register(ModuleName, 5003, "mismatch loan secret") - ErrEmptyAdaptorPoint = errorsmod.Register(ModuleName, 6001, "invalid adaptor point") - ErrInvalidRepayment = errorsmod.Register(ModuleName, 6002, "invalid repayment") - ErrInvalidRepaymentTx = errorsmod.Register(ModuleName, 6003, "invalid repayment tx") - ErrInvalidRepaymentSecret = errorsmod.Register(ModuleName, 6003, "invalid repayment secret") + ErrEmptyAdaptorPoint = errorsmod.Register(ModuleName, 6001, "invalid adaptor point") + ErrInvalidRepayment = errorsmod.Register(ModuleName, 6002, "invalid repayment") + ErrInvalidRepaymentTx = errorsmod.Register(ModuleName, 6003, "invalid repayment tx") + ErrInvalidRepaymentSecret = errorsmod.Register(ModuleName, 6004, "invalid repayment secret") + ErrRepaymentAdaptorSigAlreadyExists = errorsmod.Register(ModuleName, 6005, "repayment adaptor signature already exists") + ErrInvalidAdaptorSignature = errorsmod.Register(ModuleName, 6006, "invalid adaptor signature") + ErrEmptyLoanId = errorsmod.Register(ModuleName, 6007, "empty loan id") ) diff --git a/x/lending/types/lending.pb.go b/x/lending/types/lending.pb.go index 5340605b..fda5f3b2 100644 --- a/x/lending/types/lending.pb.go +++ b/x/lending/types/lending.pb.go @@ -429,12 +429,13 @@ func (m *DepositLog) GetDepositTx() string { } type Repayment struct { - LoanId string `protobuf:"bytes,1,opt,name=loan_id,json=loanId,proto3" json:"loan_id,omitempty"` - Txid string `protobuf:"bytes,2,opt,name=txid,proto3" json:"txid,omitempty"` - Tx string `protobuf:"bytes,3,opt,name=tx,proto3" json:"tx,omitempty"` - RepayAdaptorPoint string `protobuf:"bytes,4,opt,name=repay_adaptor_point,json=repayAdaptorPoint,proto3" json:"repay_adaptor_point,omitempty"` - BorrowerSignature string `protobuf:"bytes,5,opt,name=borrower_signature,json=borrowerSignature,proto3" json:"borrower_signature,omitempty"` - CreateAt time.Time `protobuf:"bytes,6,opt,name=create_at,json=createAt,proto3,stdtime" json:"create_at"` + LoanId string `protobuf:"bytes,1,opt,name=loan_id,json=loanId,proto3" json:"loan_id,omitempty"` + Txid string `protobuf:"bytes,2,opt,name=txid,proto3" json:"txid,omitempty"` + Tx string `protobuf:"bytes,3,opt,name=tx,proto3" json:"tx,omitempty"` + RepayAdaptorPoint string `protobuf:"bytes,4,opt,name=repay_adaptor_point,json=repayAdaptorPoint,proto3" json:"repay_adaptor_point,omitempty"` + DcaAdaptorSignature string `protobuf:"bytes,5,opt,name=dca_adaptor_signature,json=dcaAdaptorSignature,proto3" json:"dca_adaptor_signature,omitempty"` + BorrowerSignature string `protobuf:"bytes,6,opt,name=borrower_signature,json=borrowerSignature,proto3" json:"borrower_signature,omitempty"` + CreateAt time.Time `protobuf:"bytes,7,opt,name=create_at,json=createAt,proto3,stdtime" json:"create_at"` } func (m *Repayment) Reset() { *m = Repayment{} } @@ -498,6 +499,13 @@ func (m *Repayment) GetRepayAdaptorPoint() string { return "" } +func (m *Repayment) GetDcaAdaptorSignature() string { + if m != nil { + return m.DcaAdaptorSignature + } + return "" +} + func (m *Repayment) GetBorrowerSignature() string { if m != nil { return m.BorrowerSignature @@ -525,63 +533,64 @@ func init() { func init() { proto.RegisterFile("side/lending/lending.proto", fileDescriptor_eb4e0b35327359cc) } var fileDescriptor_eb4e0b35327359cc = []byte{ - // 893 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x9c, 0x55, 0xcd, 0x8e, 0xe3, 0x44, - 0x10, 0x8e, 0x93, 0x8c, 0x27, 0xae, 0xfc, 0xac, 0xa7, 0xf9, 0xf3, 0x46, 0xda, 0x24, 0x0a, 0x02, - 0x45, 0x2b, 0xb0, 0x99, 0xe1, 0x88, 0x84, 0xc8, 0xcc, 0xec, 0x4a, 0x41, 0x23, 0xb4, 0xf2, 0x44, - 0x1c, 0xb8, 0x58, 0x1d, 0x77, 0x8f, 0xd3, 0xc2, 0x76, 0x1b, 0x77, 0x7b, 0x48, 0xde, 0x81, 0xc3, - 0x1e, 0x78, 0xa8, 0x3d, 0xee, 0x11, 0x71, 0x58, 0xd0, 0xcc, 0x8d, 0xa7, 0x40, 0xdd, 0xb6, 0x93, - 0x59, 0x81, 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f, 0x0a, 0x46, 0xb0, 0xa4, 0xf6, - 0x91, 0xa2, 0x5d, 0xc4, 0x5c, 0x50, 0xdb, 0x3c, 0x7f, 0xfe, 0xea, 0x6e, 0x64, 0xbc, 0xbe, 0x1b, - 0x19, 0x7f, 0xde, 0x8d, 0x8c, 0x97, 0xf7, 0xa3, 0xc6, 0xeb, 0xfb, 0x51, 0xe3, 0xb7, 0xfb, 0x51, - 0xe3, 0x87, 0xcf, 0x22, 0x26, 0xd7, 0xc5, 0xca, 0x0d, 0x79, 0xe2, 0xa9, 0x99, 0xd3, 0xd7, 0x0b, - 0x79, 0xac, 0x0d, 0x6f, 0xb3, 0xfb, 0xbf, 0x93, 0xdb, 0x8c, 0x8a, 0x95, 0xa9, 0xe1, 0x2f, 0xff, - 0x0e, 0x00, 0x00, 0xff, 0xff, 0x6a, 0x9e, 0x21, 0xd3, 0x0c, 0x07, 0x00, 0x00, + // 912 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x9c, 0x55, 0xcf, 0x8e, 0xe3, 0xc4, + 0x13, 0x8e, 0x93, 0x8c, 0x13, 0x57, 0xfe, 0xac, 0xa7, 0xf7, 0xb7, 0x3f, 0xbc, 0x91, 0x36, 0x89, + 0x82, 0x40, 0xd1, 0x0a, 0x6c, 0x66, 0x38, 0x22, 0x21, 0x32, 0x33, 0xbb, 0x52, 0xd0, 0x08, 0xad, + 0x3c, 0x11, 0x07, 0x2e, 0x56, 0xc7, 0xdd, 0x93, 0xb4, 0xb0, 0xdd, 0xc6, 0xdd, 0x1e, 0x92, 0x77, + 0xe0, 0xb0, 0x07, 0xce, 0x3c, 0xcf, 0x1e, 0xf7, 0x88, 0x38, 0x2c, 0x68, 0xe6, 0x45, 0x50, 0xb7, + 0xed, 0x24, 0x2b, 0x10, 0x44, 0x9c, 0xe2, 0xaa, 0xef, 0xab, 0xaa, 0xee, 0xaa, 0xaf, 0x3a, 0x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xea, 0x49, 0x9a, 0xc5, 0x8e, 0x75, 0x54, + 0x3d, 0x45, 0x45, 0x4f, 0xa1, 0x4d, 0xef, 0x68, 0x22, 0x03, 0x46, 0x9c, 0xce, 0xd8, 0x98, 0x36, + 0xfd, 0x96, 0xb6, 0xe7, 0x04, 0x7d, 0x04, 0x7d, 0x2c, 0xa5, 0xda, 0x0a, 0xc9, 0x78, 0xa2, 0x08, + 0x5d, 0x4d, 0xe8, 0x1d, 0x78, 0xe7, 0x04, 0x8d, 0xa0, 0x43, 0x68, 0xca, 0x05, 0x93, 0x81, 0xdc, + 0x08, 0xa7, 0x37, 0x6e, 0x4c, 0x2d, 0x1f, 0x4a, 0xd7, 0x62, 0x23, 0xd0, 0xd7, 0x70, 0x1a, 0xf2, + 0x28, 0xc2, 0x92, 0x66, 0x38, 0xaa, 0x3a, 0xd9, 0x3f, 0xe6, 0x88, 0xf6, 0x3e, 0xae, 0xec, 0xe8, + 0x08, 0x3a, 0x87, 0x02, 0x78, 0xa4, 0x05, 0x00, 0xd1, 0x7e, 0xf8, 0x33, 0xb0, 0xc2, 0x8c, 0x62, + 0x49, 0x03, 0x2c, 0x1d, 0x5b, 0x8f, 0x6b, 0xe0, 0x16, 0xcb, 0xee, 0x56, 0xcb, 0xee, 0x2e, 0xaa, + 0x65, 0xbf, 0x68, 0xab, 0x03, 0xbc, 0xfe, 0x7d, 0x64, 0xf8, 0xed, 0x22, 0x6c, 0x76, 0xa8, 0xfe, + 0xd3, 0xbf, 0x53, 0xbf, 0x56, 0xda, 0x7b, 0xea, 0x47, 0x1f, 0x40, 0x2b, 0xe5, 0x3c, 0x52, 0x2d, + 0x42, 0x85, 0x68, 0x95, 0x39, 0x27, 0x93, 0x73, 0x68, 0x5c, 0xbe, 0x58, 0x28, 0x5c, 0x9f, 0x7a, + 0xf7, 0x42, 0x98, 0xca, 0x9c, 0x13, 0x84, 0xa0, 0x19, 0x52, 0x29, 0xca, 0x25, 0xd0, 0xdf, 0x13, + 0x02, 0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d, 0x44, 0x3d, 0xb0, 0xae, 0xd9, 0x0f, 0x39, 0x23, + 0x58, 0x52, 0xfb, 0x44, 0xd1, 0x2e, 0x23, 0x2e, 0xa8, 0x6d, 0x5e, 0xbc, 0x7c, 0x73, 0x3f, 0x34, + 0xde, 0xde, 0x0f, 0x8d, 0x3f, 0xee, 0x87, 0xc6, 0xeb, 0x87, 0x61, 0xed, 0xed, 0xc3, 0xb0, 0xf6, + 0xeb, 0xc3, 0xb0, 0xf6, 0xdd, 0x27, 0x2b, 0x26, 0xd7, 0xf9, 0xd2, 0x0d, 0x79, 0xec, 0x29, 0x9d, + 0xea, 0xeb, 0x85, 0x3c, 0xd2, 0x86, 0xb7, 0xd9, 0xfd, 0x47, 0xca, 0x6d, 0x4a, 0xc5, 0xd2, 0xd4, + 0xf0, 0xe7, 0x7f, 0x06, 0x00, 0x00, 0xff, 0xff, 0x88, 0xfe, 0x04, 0x94, 0x40, 0x07, 0x00, 0x00, } func (m *LendingPool) Marshal() (dAtA []byte, err error) { @@ -924,12 +933,19 @@ func (m *Repayment) MarshalToSizedBuffer(dAtA []byte) (int, error) { i -= n4 i = encodeVarintLending(dAtA, i, uint64(n4)) i-- - dAtA[i] = 0x32 + dAtA[i] = 0x3a if len(m.BorrowerSignature) > 0 { i -= len(m.BorrowerSignature) copy(dAtA[i:], m.BorrowerSignature) i = encodeVarintLending(dAtA, i, uint64(len(m.BorrowerSignature))) i-- + dAtA[i] = 0x32 + } + if len(m.DcaAdaptorSignature) > 0 { + i -= len(m.DcaAdaptorSignature) + copy(dAtA[i:], m.DcaAdaptorSignature) + i = encodeVarintLending(dAtA, i, uint64(len(m.DcaAdaptorSignature))) + i-- dAtA[i] = 0x2a } if len(m.RepayAdaptorPoint) > 0 { @@ -1126,6 +1142,10 @@ func (m *Repayment) Size() (n int) { if l > 0 { n += 1 + l + sovLending(uint64(l)) } + l = len(m.DcaAdaptorSignature) + if l > 0 { + n += 1 + l + sovLending(uint64(l)) + } l = len(m.BorrowerSignature) if l > 0 { n += 1 + l + sovLending(uint64(l)) @@ -2338,6 +2358,38 @@ func (m *Repayment) Unmarshal(dAtA []byte) error { m.RepayAdaptorPoint = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 5: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field DcaAdaptorSignature", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowLending + } + 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 ErrInvalidLengthLending + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return ErrInvalidLengthLending + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.DcaAdaptorSignature = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 6: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field BorrowerSignature", wireType) } @@ -2369,7 +2421,7 @@ func (m *Repayment) Unmarshal(dAtA []byte) error { } m.BorrowerSignature = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex - case 6: + case 7: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field CreateAt", wireType) } diff --git a/x/lending/types/msg_submit_repayment_adaptor_signature.go b/x/lending/types/msg_submit_repayment_adaptor_signature.go new file mode 100644 index 00000000..cf9c9428 --- /dev/null +++ b/x/lending/types/msg_submit_repayment_adaptor_signature.go @@ -0,0 +1,28 @@ +package types + +import ( + sdk "github.com/cosmos/cosmos-sdk/types" +) + +var _ sdk.Msg = &MsgSubmitRepaymentAdaptorSignature{} + +func NewMsgSubmitRepaymentAdaptorSignature(relayer string, loanId string, adaptorSignature string) *MsgSubmitRepaymentAdaptorSignature { + return &MsgSubmitRepaymentAdaptorSignature{ + Relayer: relayer, + LoanId: loanId, + AdaptorSignature: adaptorSignature, + } +} + +// ValidateBasic performs basic message validation. +func (m *MsgSubmitRepaymentAdaptorSignature) ValidateBasic() error { + if len(m.LoanId) == 0 { + return ErrEmptyLoanId + } + + if len(m.AdaptorSignature) == 0 { + return ErrInvalidAdaptorSignature + } + + return nil +} diff --git a/x/lending/types/tx.pb.go b/x/lending/types/tx.pb.go index 37bdf769..2ab1e830 100644 --- a/x/lending/types/tx.pb.go +++ b/x/lending/types/tx.pb.go @@ -782,6 +782,106 @@ func (m *MsgApproveResponse) XXX_DiscardUnknown() { var xxx_messageInfo_MsgApproveResponse proto.InternalMessageInfo +type MsgSubmitRepaymentAdaptorSignature struct { + Relayer string `protobuf:"bytes,1,opt,name=relayer,proto3" json:"relayer,omitempty"` + LoanId string `protobuf:"bytes,2,opt,name=loan_id,json=loanId,proto3" json:"loan_id,omitempty"` + AdaptorSignature string `protobuf:"bytes,3,opt,name=adaptor_signature,json=adaptorSignature,proto3" json:"adaptor_signature,omitempty"` +} + +func (m *MsgSubmitRepaymentAdaptorSignature) Reset() { *m = MsgSubmitRepaymentAdaptorSignature{} } +func (m *MsgSubmitRepaymentAdaptorSignature) String() string { return proto.CompactTextString(m) } +func (*MsgSubmitRepaymentAdaptorSignature) ProtoMessage() {} +func (*MsgSubmitRepaymentAdaptorSignature) Descriptor() ([]byte, []int) { + return fileDescriptor_13b5a91577424108, []int{14} +} +func (m *MsgSubmitRepaymentAdaptorSignature) XXX_Unmarshal(b []byte) error { + return m.Unmarshal(b) +} +func (m *MsgSubmitRepaymentAdaptorSignature) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { + if deterministic { + return xxx_messageInfo_MsgSubmitRepaymentAdaptorSignature.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 *MsgSubmitRepaymentAdaptorSignature) XXX_Merge(src proto.Message) { + xxx_messageInfo_MsgSubmitRepaymentAdaptorSignature.Merge(m, src) +} +func (m *MsgSubmitRepaymentAdaptorSignature) XXX_Size() int { + return m.Size() +} +func (m *MsgSubmitRepaymentAdaptorSignature) XXX_DiscardUnknown() { + xxx_messageInfo_MsgSubmitRepaymentAdaptorSignature.DiscardUnknown(m) +} + +var xxx_messageInfo_MsgSubmitRepaymentAdaptorSignature proto.InternalMessageInfo + +func (m *MsgSubmitRepaymentAdaptorSignature) GetRelayer() string { + if m != nil { + return m.Relayer + } + return "" +} + +func (m *MsgSubmitRepaymentAdaptorSignature) GetLoanId() string { + if m != nil { + return m.LoanId + } + return "" +} + +func (m *MsgSubmitRepaymentAdaptorSignature) GetAdaptorSignature() string { + if m != nil { + return m.AdaptorSignature + } + return "" +} + +type MsgSubmitRepaymentAdaptorSignatureResponse struct { +} + +func (m *MsgSubmitRepaymentAdaptorSignatureResponse) Reset() { + *m = MsgSubmitRepaymentAdaptorSignatureResponse{} +} +func (m *MsgSubmitRepaymentAdaptorSignatureResponse) String() string { + return proto.CompactTextString(m) +} +func (*MsgSubmitRepaymentAdaptorSignatureResponse) ProtoMessage() {} +func (*MsgSubmitRepaymentAdaptorSignatureResponse) Descriptor() ([]byte, []int) { + return fileDescriptor_13b5a91577424108, []int{15} +} +func (m *MsgSubmitRepaymentAdaptorSignatureResponse) XXX_Unmarshal(b []byte) error { + return m.Unmarshal(b) +} +func (m *MsgSubmitRepaymentAdaptorSignatureResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { + if deterministic { + return xxx_messageInfo_MsgSubmitRepaymentAdaptorSignatureResponse.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 *MsgSubmitRepaymentAdaptorSignatureResponse) XXX_Merge(src proto.Message) { + xxx_messageInfo_MsgSubmitRepaymentAdaptorSignatureResponse.Merge(m, src) +} +func (m *MsgSubmitRepaymentAdaptorSignatureResponse) XXX_Size() int { + return m.Size() +} +func (m *MsgSubmitRepaymentAdaptorSignatureResponse) XXX_DiscardUnknown() { + xxx_messageInfo_MsgSubmitRepaymentAdaptorSignatureResponse.DiscardUnknown(m) +} + +var xxx_messageInfo_MsgSubmitRepaymentAdaptorSignatureResponse proto.InternalMessageInfo + type MsgClose struct { Relayer string `protobuf:"bytes,1,opt,name=relayer,proto3" json:"relayer,omitempty"` LoanId string `protobuf:"bytes,2,opt,name=loan_id,json=loanId,proto3" json:"loan_id,omitempty"` @@ -792,7 +892,7 @@ func (m *MsgClose) Reset() { *m = MsgClose{} } func (m *MsgClose) String() string { return proto.CompactTextString(m) } func (*MsgClose) ProtoMessage() {} func (*MsgClose) Descriptor() ([]byte, []int) { - return fileDescriptor_13b5a91577424108, []int{14} + return fileDescriptor_13b5a91577424108, []int{16} } func (m *MsgClose) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -849,7 +949,7 @@ func (m *MsgCloseResponse) Reset() { *m = MsgCloseResponse{} } func (m *MsgCloseResponse) String() string { return proto.CompactTextString(m) } func (*MsgCloseResponse) ProtoMessage() {} func (*MsgCloseResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_13b5a91577424108, []int{15} + return fileDescriptor_13b5a91577424108, []int{17} } func (m *MsgCloseResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -893,6 +993,8 @@ func init() { proto.RegisterType((*MsgApplyResponse)(nil), "side.lending.MsgApplyResponse") proto.RegisterType((*MsgApprove)(nil), "side.lending.MsgApprove") proto.RegisterType((*MsgApproveResponse)(nil), "side.lending.MsgApproveResponse") + proto.RegisterType((*MsgSubmitRepaymentAdaptorSignature)(nil), "side.lending.MsgSubmitRepaymentAdaptorSignature") + proto.RegisterType((*MsgSubmitRepaymentAdaptorSignatureResponse)(nil), "side.lending.MsgSubmitRepaymentAdaptorSignatureResponse") proto.RegisterType((*MsgClose)(nil), "side.lending.MsgClose") proto.RegisterType((*MsgCloseResponse)(nil), "side.lending.MsgCloseResponse") } @@ -900,65 +1002,69 @@ func init() { func init() { proto.RegisterFile("side/lending/tx.proto", fileDescriptor_13b5a91577424108) } var fileDescriptor_13b5a91577424108 = []byte{ - // 923 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x9c, 0x56, 0x41, 0x6f, 0xdb, 0x36, - 0x14, 0x8e, 0x12, 0xc7, 0x8e, 0x5f, 0xec, 0xa6, 0xd3, 0xd2, 0x58, 0xd5, 0x56, 0xd7, 0x50, 0x30, - 0xcc, 0x28, 0x06, 0x09, 0xe9, 0x0e, 0x03, 0x72, 0xd8, 0xe0, 0x06, 0x1b, 0x16, 0xa0, 0xd9, 0x02, - 0x2f, 0xa7, 0x01, 0x83, 0x40, 0x5b, 0xac, 0x4c, 0x54, 0x12, 0x35, 0x91, 0xf6, 0xe2, 0xdb, 0xd0, - 0xfb, 0x80, 0xfd, 0x94, 0xfe, 0x8c, 0x1d, 0x7b, 0xdc, 0x6d, 0x43, 0x72, 0xe8, 0x6f, 0xd8, 0x6d, - 0x20, 0x45, 0xd1, 0x92, 0xed, 0xb8, 0x45, 0x4f, 0xd6, 0xfb, 0xbe, 0xa7, 0xf7, 0x3e, 0xf1, 0x7d, - 0x24, 0x0d, 0x0f, 0x18, 0x09, 0xb0, 0x17, 0xe1, 0x24, 0x20, 0x49, 0xe8, 0xf1, 0x6b, 0x37, 0xcd, - 0x28, 0xa7, 0x66, 0x4b, 0xc0, 0xae, 0x82, 0xed, 0xc3, 0x90, 0x86, 0x54, 0x12, 0x9e, 0x78, 0xca, - 0x73, 0xec, 0xce, 0x98, 0xb2, 0x98, 0x32, 0x2f, 0x66, 0xa1, 0x37, 0x3b, 0x11, 0x3f, 0x8a, 0xe8, - 0x2a, 0x62, 0x84, 0x18, 0xf6, 0x66, 0x27, 0x23, 0xcc, 0xd1, 0x89, 0x37, 0xa6, 0x24, 0xc9, 0x79, - 0x67, 0x0a, 0xed, 0x0b, 0x16, 0x9e, 0x65, 0x18, 0x71, 0x7c, 0x49, 0x69, 0x64, 0x5a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0x8a, 0xe6, 0x29, 0x66, 0xa3, 0xba, 0xa4, 0xbf, 0xfc, 0x3f, 0x00, - 0x00, 0xff, 0xff, 0x5d, 0x4d, 0x13, 0xcc, 0x32, 0x09, 0x00, 0x00, + // 988 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x9c, 0x56, 0x4f, 0x6f, 0x1b, 0x45, + 0x14, 0xcf, 0xe6, 0x8f, 0x1d, 0xbf, 0xd8, 0x4d, 0xba, 0xa4, 0xb1, 0xbb, 0x50, 0xc7, 0xda, 0x08, + 0x61, 0x85, 0xca, 0x26, 0xe5, 0x00, 0xca, 0x01, 0xe4, 0x46, 0x20, 0x22, 0xd5, 0x10, 0x39, 0x39, + 0x21, 0x21, 0x6b, 0xec, 0x9d, 0xae, 0x47, 0xdd, 0xdd, 0x59, 0x76, 0x66, 0x4d, 0x7c, 0x43, 0xbd, + 0x57, 0x42, 0x7c, 0x92, 0x7e, 0x0c, 0x8e, 0x3d, 0x72, 0x44, 0xc9, 0xa1, 0x47, 0xce, 0xdc, 0xd0, + 0xcc, 0xce, 0x8e, 0xd7, 0x6b, 0xc7, 0x6e, 0x7b, 0xb2, 0xdf, 0xef, 0xbd, 0x79, 0xef, 0x37, 0xef, + 0xdf, 0x2c, 0x3c, 0x60, 0xc4, 0xc1, 0x6d, 0x0f, 0x07, 0x0e, 0x09, 0xdc, 0x36, 0xbf, 0x6e, 0x85, + 0x11, 0xe5, 0xd4, 0x2c, 0x0b, 0xb8, 0xa5, 0x60, 0x6b, 0xdf, 0xa5, 0x2e, 0x95, 0x8a, 0xb6, 0xf8, + 0x97, 0xd8, 0x58, 0xd5, 0x21, 0x65, 0x3e, 0x65, 0x6d, 0x9f, 0xb9, 0xed, 0xf1, 0x89, 0xf8, 0x51, + 0x8a, 0xba, 0x52, 0x0c, 0x10, 0xc3, 0xed, 0xf1, 0xc9, 0x00, 0x73, 0x74, 0xd2, 0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0x24, 0x78, 0x95, 0x60, 0xd9, + 0x1e, 0x2a, 0xcc, 0xf4, 0xd0, 0x37, 0x50, 0x49, 0xe8, 0xf5, 0x55, 0x62, 0x8a, 0xab, 0x12, 0x53, + 0x4e, 0xec, 0x3b, 0xd2, 0xdc, 0x7c, 0x08, 0xdb, 0x78, 0x8c, 0x03, 0x2e, 0x3c, 0x6f, 0x37, 0x8c, + 0xe6, 0x66, 0xaf, 0x28, 0xe5, 0x73, 0xc7, 0x34, 0x61, 0x73, 0x88, 0x39, 0xab, 0x95, 0x64, 0x40, + 0xf9, 0xdf, 0x7c, 0x04, 0xe0, 0xe0, 0x90, 0x32, 0xc2, 0xfb, 0xfc, 0xba, 0x06, 0x52, 0x53, 0x52, + 0xc8, 0xd5, 0x75, 0x7e, 0x44, 0xbe, 0x92, 0x83, 0x2a, 0x53, 0xaf, 0x4b, 0x78, 0x04, 0x95, 0x31, + 0x8a, 0x3d, 0xde, 0x47, 0x8e, 0x13, 0x61, 0xc6, 0x54, 0x1d, 0xca, 0x12, 0xec, 0x24, 0x98, 0xfd, + 0xca, 0x00, 0x48, 0x4e, 0x46, 0x74, 0x8c, 0xc5, 0x92, 0x8b, 0xb0, 0x87, 0x26, 0xba, 0x6a, 0xa9, + 0x68, 0xda, 0x50, 0x99, 0xf2, 0x99, 0xce, 0xf4, 0x8e, 0xa6, 0x74, 0xee, 0x08, 0xce, 0x03, 0x8f, + 0x0e, 0x5f, 0x64, 0x2b, 0x55, 0x92, 0x88, 0x2c, 0xd2, 0x3e, 0x6c, 0x85, 0x11, 0xa5, 0xcf, 0x6b, + 0x9b, 0x8d, 0x8d, 0x66, 0xa9, 0x97, 0x08, 0x6a, 0xff, 0xa9, 0x30, 0xf6, 0xbe, 0x9c, 0x01, 0x45, + 0x47, 0x0f, 0xfb, 0x9f, 0x06, 0xd8, 0x5d, 0xe6, 0x5e, 0xc6, 0x03, 0x9f, 0x70, 0xb9, 0x8e, 0x7c, + 0x1c, 0xf0, 0x4e, 0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0x58, 0x71, 0xc2, 0xfa, 0xfa, 0x7d, 0x4f, + 0x64, 0x2f, 0x94, 0x4c, 0xc9, 0xfc, 0x85, 0x24, 0xbe, 0xe0, 0x42, 0x33, 0xad, 0x6e, 0x6d, 0xfd, + 0xfe, 0xf6, 0xf5, 0xb1, 0xf1, 0xf4, 0xfb, 0xbf, 0x6e, 0xea, 0xc6, 0x9b, 0x9b, 0xba, 0xf1, 0xcf, + 0x4d, 0xdd, 0xf8, 0xe3, 0xb6, 0xbe, 0xf6, 0xe6, 0xb6, 0xbe, 0xf6, 0xf7, 0x6d, 0x7d, 0xed, 0xe7, + 0xc7, 0x2e, 0xe1, 0xa3, 0x78, 0xd0, 0x1a, 0x52, 0xbf, 0x2d, 0x5c, 0xc9, 0x0f, 0xbe, 0x21, 0xf5, + 0xa4, 0xd0, 0xbe, 0x9e, 0x7e, 0x68, 0x4e, 0x42, 0xcc, 0x06, 0x05, 0xa9, 0xfe, 0xf2, 0xff, 0x00, + 0x00, 0x00, 0xff, 0xff, 0xdc, 0xec, 0x47, 0xb7, 0x85, 0x0a, 0x00, 0x00, } // Reference imports to suppress errors if they are not otherwise used. @@ -980,6 +1086,7 @@ type MsgClient interface { Approve(ctx context.Context, in *MsgApprove, opts ...grpc.CallOption) (*MsgApproveResponse, error) Redeem(ctx context.Context, in *MsgRedeem, opts ...grpc.CallOption) (*MsgRedeemResponse, error) Repay(ctx context.Context, in *MsgRepay, opts ...grpc.CallOption) (*MsgRepayResponse, error) + SubmitRepaymentAdaptorSignature(ctx context.Context, in *MsgSubmitRepaymentAdaptorSignature, opts ...grpc.CallOption) (*MsgSubmitRepaymentAdaptorSignatureResponse, error) Close(ctx context.Context, in *MsgClose, opts ...grpc.CallOption) (*MsgCloseResponse, error) } @@ -1054,6 +1161,15 @@ func (c *msgClient) Repay(ctx context.Context, in *MsgRepay, opts ...grpc.CallOp return out, nil } +func (c *msgClient) SubmitRepaymentAdaptorSignature(ctx context.Context, in *MsgSubmitRepaymentAdaptorSignature, opts ...grpc.CallOption) (*MsgSubmitRepaymentAdaptorSignatureResponse, error) { + out := new(MsgSubmitRepaymentAdaptorSignatureResponse) + err := c.cc.Invoke(ctx, "/side.lending.Msg/SubmitRepaymentAdaptorSignature", in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + func (c *msgClient) Close(ctx context.Context, in *MsgClose, opts ...grpc.CallOption) (*MsgCloseResponse, error) { out := new(MsgCloseResponse) err := c.cc.Invoke(ctx, "/side.lending.Msg/Close", in, out, opts...) @@ -1072,6 +1188,7 @@ type MsgServer interface { Approve(context.Context, *MsgApprove) (*MsgApproveResponse, error) Redeem(context.Context, *MsgRedeem) (*MsgRedeemResponse, error) Repay(context.Context, *MsgRepay) (*MsgRepayResponse, error) + SubmitRepaymentAdaptorSignature(context.Context, *MsgSubmitRepaymentAdaptorSignature) (*MsgSubmitRepaymentAdaptorSignatureResponse, error) Close(context.Context, *MsgClose) (*MsgCloseResponse, error) } @@ -1100,6 +1217,9 @@ func (*UnimplementedMsgServer) Redeem(ctx context.Context, req *MsgRedeem) (*Msg func (*UnimplementedMsgServer) Repay(ctx context.Context, req *MsgRepay) (*MsgRepayResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method Repay not implemented") } +func (*UnimplementedMsgServer) SubmitRepaymentAdaptorSignature(ctx context.Context, req *MsgSubmitRepaymentAdaptorSignature) (*MsgSubmitRepaymentAdaptorSignatureResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method SubmitRepaymentAdaptorSignature not implemented") +} func (*UnimplementedMsgServer) Close(ctx context.Context, req *MsgClose) (*MsgCloseResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method Close not implemented") } @@ -1234,6 +1354,24 @@ func _Msg_Repay_Handler(srv interface{}, ctx context.Context, dec func(interface return interceptor(ctx, in, info, handler) } +func _Msg_SubmitRepaymentAdaptorSignature_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(MsgSubmitRepaymentAdaptorSignature) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(MsgServer).SubmitRepaymentAdaptorSignature(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: "/side.lending.Msg/SubmitRepaymentAdaptorSignature", + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(MsgServer).SubmitRepaymentAdaptorSignature(ctx, req.(*MsgSubmitRepaymentAdaptorSignature)) + } + return interceptor(ctx, in, info, handler) +} + func _Msg_Close_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(MsgClose) if err := dec(in); err != nil { @@ -1285,6 +1423,10 @@ var _Msg_serviceDesc = grpc.ServiceDesc{ MethodName: "Repay", Handler: _Msg_Repay_Handler, }, + { + MethodName: "SubmitRepaymentAdaptorSignature", + Handler: _Msg_SubmitRepaymentAdaptorSignature_Handler, + }, { MethodName: "Close", Handler: _Msg_Close_Handler, @@ -1854,6 +1996,73 @@ func (m *MsgApproveResponse) MarshalToSizedBuffer(dAtA []byte) (int, error) { return len(dAtA) - i, nil } +func (m *MsgSubmitRepaymentAdaptorSignature) 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 *MsgSubmitRepaymentAdaptorSignature) MarshalTo(dAtA []byte) (int, error) { + size := m.Size() + return m.MarshalToSizedBuffer(dAtA[:size]) +} + +func (m *MsgSubmitRepaymentAdaptorSignature) MarshalToSizedBuffer(dAtA []byte) (int, error) { + i := len(dAtA) + _ = i + var l int + _ = l + if len(m.AdaptorSignature) > 0 { + i -= len(m.AdaptorSignature) + copy(dAtA[i:], m.AdaptorSignature) + i = encodeVarintTx(dAtA, i, uint64(len(m.AdaptorSignature))) + i-- + dAtA[i] = 0x1a + } + if len(m.LoanId) > 0 { + i -= len(m.LoanId) + copy(dAtA[i:], m.LoanId) + i = encodeVarintTx(dAtA, i, uint64(len(m.LoanId))) + i-- + dAtA[i] = 0x12 + } + if len(m.Relayer) > 0 { + i -= len(m.Relayer) + copy(dAtA[i:], m.Relayer) + i = encodeVarintTx(dAtA, i, uint64(len(m.Relayer))) + i-- + dAtA[i] = 0xa + } + return len(dAtA) - i, nil +} + +func (m *MsgSubmitRepaymentAdaptorSignatureResponse) 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 *MsgSubmitRepaymentAdaptorSignatureResponse) MarshalTo(dAtA []byte) (int, error) { + size := m.Size() + return m.MarshalToSizedBuffer(dAtA[:size]) +} + +func (m *MsgSubmitRepaymentAdaptorSignatureResponse) MarshalToSizedBuffer(dAtA []byte) (int, error) { + i := len(dAtA) + _ = i + var l int + _ = l + return len(dAtA) - i, nil +} + func (m *MsgClose) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) @@ -2181,6 +2390,36 @@ func (m *MsgApproveResponse) Size() (n int) { return n } +func (m *MsgSubmitRepaymentAdaptorSignature) Size() (n int) { + if m == nil { + return 0 + } + var l int + _ = l + l = len(m.Relayer) + if l > 0 { + n += 1 + l + sovTx(uint64(l)) + } + l = len(m.LoanId) + if l > 0 { + n += 1 + l + sovTx(uint64(l)) + } + l = len(m.AdaptorSignature) + if l > 0 { + n += 1 + l + sovTx(uint64(l)) + } + return n +} + +func (m *MsgSubmitRepaymentAdaptorSignatureResponse) Size() (n int) { + if m == nil { + return 0 + } + var l int + _ = l + return n +} + func (m *MsgClose) Size() (n int) { if m == nil { return 0 @@ -3890,6 +4129,202 @@ func (m *MsgApproveResponse) Unmarshal(dAtA []byte) error { } return nil } +func (m *MsgSubmitRepaymentAdaptorSignature) 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: MsgSubmitRepaymentAdaptorSignature: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: MsgSubmitRepaymentAdaptorSignature: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Relayer", 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.Relayer = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field LoanId", 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.LoanId = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 3: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field AdaptorSignature", 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.AdaptorSignature = 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 *MsgSubmitRepaymentAdaptorSignatureResponse) 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: MsgSubmitRepaymentAdaptorSignatureResponse: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: MsgSubmitRepaymentAdaptorSignatureResponse: 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 (m *MsgClose) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0