diff --git a/Makefile b/Makefile index 45ddd9b..cd7b5b3 100644 --- a/Makefile +++ b/Makefile @@ -1,7 +1,5 @@ default: lintf -SRC_DIR=./info ./ledger - install: brew install protobuf brew install prototool @@ -13,7 +11,4 @@ lintf: build: prototool all go mod tidy - for dir in $(SRC_DIR); \ - do \ - go build $$dir; \ - done + go build ./... diff --git a/protos/escrow/escrow.pb.go b/protos/escrow/escrow.pb.go index 0b1d204..9906a09 100644 --- a/protos/escrow/escrow.pb.go +++ b/protos/escrow/escrow.pb.go @@ -6,18 +6,21 @@ package escrowpb import ( context "context" fmt "fmt" + _ "github.com/gogo/protobuf/gogoproto" proto "github.com/gogo/protobuf/proto" - types "github.com/gogo/protobuf/types" + _ "github.com/gogo/protobuf/types" grpc "google.golang.org/grpc" codes "google.golang.org/grpc/codes" status "google.golang.org/grpc/status" math "math" + time "time" ) // Reference imports to suppress errors if they are not otherwise used. var _ = proto.Marshal var _ = fmt.Errorf var _ = math.Inf +var _ = time.Kitchen // This is a compile-time assertion to ensure that this generated file // is compatible with the proto package it is being compiled against. @@ -109,7 +112,6 @@ func (EscrowStatus) EnumDescriptor() ([]byte, []int) { type ContractID struct { ContractId []byte `protobuf:"bytes,1,opt,name=contract_id,json=contractId,proto3" json:"contract_id,omitempty"` Address []byte `protobuf:"bytes,2,opt,name=address,proto3" json:"address,omitempty"` - Signature []byte `protobuf:"bytes,3,opt,name=signature,proto3" json:"signature,omitempty"` XXX_NoUnkeyedLiteral struct{} `json:"-"` XXX_unrecognized []byte `json:"-"` XXX_sizecache int32 `json:"-"` @@ -153,7 +155,46 @@ func (m *ContractID) GetAddress() []byte { return nil } -func (m *ContractID) GetSignature() []byte { +type SignedContractID struct { + Data *ContractID `protobuf:"bytes,1,opt,name=data,proto3" json:"data,omitempty"` + Signature []byte `protobuf:"bytes,2,opt,name=signature,proto3" json:"signature,omitempty"` + XXX_NoUnkeyedLiteral struct{} `json:"-"` + XXX_unrecognized []byte `json:"-"` + XXX_sizecache int32 `json:"-"` +} + +func (m *SignedContractID) Reset() { *m = SignedContractID{} } +func (m *SignedContractID) String() string { return proto.CompactTextString(m) } +func (*SignedContractID) ProtoMessage() {} +func (*SignedContractID) Descriptor() ([]byte, []int) { + return fileDescriptor_92a6463c7f7e20b5, []int{1} +} +func (m *SignedContractID) XXX_Unmarshal(b []byte) error { + return xxx_messageInfo_SignedContractID.Unmarshal(m, b) +} +func (m *SignedContractID) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { + return xxx_messageInfo_SignedContractID.Marshal(b, m, deterministic) +} +func (m *SignedContractID) XXX_Merge(src proto.Message) { + xxx_messageInfo_SignedContractID.Merge(m, src) +} +func (m *SignedContractID) XXX_Size() int { + return xxx_messageInfo_SignedContractID.Size(m) +} +func (m *SignedContractID) XXX_DiscardUnknown() { + xxx_messageInfo_SignedContractID.DiscardUnknown(m) +} + +var xxx_messageInfo_SignedContractID proto.InternalMessageInfo + +func (m *SignedContractID) GetData() *ContractID { + if m != nil { + return m.Data + } + return nil +} + +func (m *SignedContractID) GetSignature() []byte { if m != nil { return m.Signature } @@ -181,7 +222,7 @@ func (m *EscrowContract) Reset() { *m = EscrowContract{} } func (m *EscrowContract) String() string { return proto.CompactTextString(m) } func (*EscrowContract) ProtoMessage() {} func (*EscrowContract) Descriptor() ([]byte, []int) { - return fileDescriptor_92a6463c7f7e20b5, []int{1} + return fileDescriptor_92a6463c7f7e20b5, []int{2} } func (m *EscrowContract) XXX_Unmarshal(b []byte) error { return xxx_messageInfo_EscrowContract.Unmarshal(m, b) @@ -291,7 +332,7 @@ func (m *SignedEscrowContract) Reset() { *m = SignedEscrowContract{} } func (m *SignedEscrowContract) String() string { return proto.CompactTextString(m) } func (*SignedEscrowContract) ProtoMessage() {} func (*SignedEscrowContract) Descriptor() ([]byte, []int) { - return fileDescriptor_92a6463c7f7e20b5, []int{2} + return fileDescriptor_92a6463c7f7e20b5, []int{3} } func (m *SignedEscrowContract) XXX_Unmarshal(b []byte) error { return xxx_messageInfo_SignedEscrowContract.Unmarshal(m, b) @@ -343,7 +384,7 @@ func (m *EscrowContractRequest) Reset() { *m = EscrowContractRequest{} } func (m *EscrowContractRequest) String() string { return proto.CompactTextString(m) } func (*EscrowContractRequest) ProtoMessage() {} func (*EscrowContractRequest) Descriptor() ([]byte, []int) { - return fileDescriptor_92a6463c7f7e20b5, []int{3} + return fileDescriptor_92a6463c7f7e20b5, []int{4} } func (m *EscrowContractRequest) XXX_Unmarshal(b []byte) error { return xxx_messageInfo_EscrowContractRequest.Unmarshal(m, b) @@ -386,7 +427,7 @@ func (m *Escrow) Reset() { *m = Escrow{} } func (m *Escrow) String() string { return proto.CompactTextString(m) } func (*Escrow) ProtoMessage() {} func (*Escrow) Descriptor() ([]byte, []int) { - return fileDescriptor_92a6463c7f7e20b5, []int{4} + return fileDescriptor_92a6463c7f7e20b5, []int{5} } func (m *Escrow) XXX_Unmarshal(b []byte) error { return xxx_messageInfo_Escrow.Unmarshal(m, b) @@ -448,70 +489,108 @@ func (m *Escrow) GetCollateralAmount() int64 { return 0 } -type EscrowContractResult struct { - PayinId []byte `protobuf:"bytes,1,opt,name=payin_id,json=payinId,proto3" json:"payin_id,omitempty"` - Escrow []*Escrow `protobuf:"bytes,2,rep,name=escrow,proto3" json:"escrow,omitempty"` - EscrowAddress []byte `protobuf:"bytes,3,opt,name=escrow_address,json=escrowAddress,proto3" json:"escrow_address,omitempty"` - EscrowSignedTime *types.Timestamp `protobuf:"bytes,4,opt,name=escrow_signed_time,json=escrowSignedTime,proto3" json:"escrow_signed_time,omitempty"` - EscrowSignature []byte `protobuf:"bytes,5,opt,name=escrow_signature,json=escrowSignature,proto3" json:"escrow_signature,omitempty"` - XXX_NoUnkeyedLiteral struct{} `json:"-"` - XXX_unrecognized []byte `json:"-"` - XXX_sizecache int32 `json:"-"` +type SubmitContractResult struct { + PayinId []byte `protobuf:"bytes,1,opt,name=payin_id,json=payinId,proto3" json:"payin_id,omitempty"` + Escrow []*Escrow `protobuf:"bytes,2,rep,name=escrow,proto3" json:"escrow,omitempty"` + EscrowAddress []byte `protobuf:"bytes,3,opt,name=escrow_address,json=escrowAddress,proto3" json:"escrow_address,omitempty"` + EscrowSignedTime *time.Time `protobuf:"bytes,4,opt,name=escrow_signed_time,json=escrowSignedTime,proto3,stdtime" json:"escrow_signed_time,omitempty"` + XXX_NoUnkeyedLiteral struct{} `json:"-"` + XXX_unrecognized []byte `json:"-"` + XXX_sizecache int32 `json:"-"` } -func (m *EscrowContractResult) Reset() { *m = EscrowContractResult{} } -func (m *EscrowContractResult) String() string { return proto.CompactTextString(m) } -func (*EscrowContractResult) ProtoMessage() {} -func (*EscrowContractResult) Descriptor() ([]byte, []int) { - return fileDescriptor_92a6463c7f7e20b5, []int{5} +func (m *SubmitContractResult) Reset() { *m = SubmitContractResult{} } +func (m *SubmitContractResult) String() string { return proto.CompactTextString(m) } +func (*SubmitContractResult) ProtoMessage() {} +func (*SubmitContractResult) Descriptor() ([]byte, []int) { + return fileDescriptor_92a6463c7f7e20b5, []int{6} } -func (m *EscrowContractResult) XXX_Unmarshal(b []byte) error { - return xxx_messageInfo_EscrowContractResult.Unmarshal(m, b) +func (m *SubmitContractResult) XXX_Unmarshal(b []byte) error { + return xxx_messageInfo_SubmitContractResult.Unmarshal(m, b) } -func (m *EscrowContractResult) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - return xxx_messageInfo_EscrowContractResult.Marshal(b, m, deterministic) +func (m *SubmitContractResult) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { + return xxx_messageInfo_SubmitContractResult.Marshal(b, m, deterministic) } -func (m *EscrowContractResult) XXX_Merge(src proto.Message) { - xxx_messageInfo_EscrowContractResult.Merge(m, src) +func (m *SubmitContractResult) XXX_Merge(src proto.Message) { + xxx_messageInfo_SubmitContractResult.Merge(m, src) } -func (m *EscrowContractResult) XXX_Size() int { - return xxx_messageInfo_EscrowContractResult.Size(m) +func (m *SubmitContractResult) XXX_Size() int { + return xxx_messageInfo_SubmitContractResult.Size(m) } -func (m *EscrowContractResult) XXX_DiscardUnknown() { - xxx_messageInfo_EscrowContractResult.DiscardUnknown(m) +func (m *SubmitContractResult) XXX_DiscardUnknown() { + xxx_messageInfo_SubmitContractResult.DiscardUnknown(m) } -var xxx_messageInfo_EscrowContractResult proto.InternalMessageInfo +var xxx_messageInfo_SubmitContractResult proto.InternalMessageInfo -func (m *EscrowContractResult) GetPayinId() []byte { +func (m *SubmitContractResult) GetPayinId() []byte { if m != nil { return m.PayinId } return nil } -func (m *EscrowContractResult) GetEscrow() []*Escrow { +func (m *SubmitContractResult) GetEscrow() []*Escrow { if m != nil { return m.Escrow } return nil } -func (m *EscrowContractResult) GetEscrowAddress() []byte { +func (m *SubmitContractResult) GetEscrowAddress() []byte { if m != nil { return m.EscrowAddress } return nil } -func (m *EscrowContractResult) GetEscrowSignedTime() *types.Timestamp { +func (m *SubmitContractResult) GetEscrowSignedTime() *time.Time { if m != nil { return m.EscrowSignedTime } return nil } -func (m *EscrowContractResult) GetEscrowSignature() []byte { +type SignedSubmitContractResult struct { + Result *SubmitContractResult `protobuf:"bytes,1,opt,name=result,proto3" json:"result,omitempty"` + EscrowSignature []byte `protobuf:"bytes,2,opt,name=escrow_signature,json=escrowSignature,proto3" json:"escrow_signature,omitempty"` + XXX_NoUnkeyedLiteral struct{} `json:"-"` + XXX_unrecognized []byte `json:"-"` + XXX_sizecache int32 `json:"-"` +} + +func (m *SignedSubmitContractResult) Reset() { *m = SignedSubmitContractResult{} } +func (m *SignedSubmitContractResult) String() string { return proto.CompactTextString(m) } +func (*SignedSubmitContractResult) ProtoMessage() {} +func (*SignedSubmitContractResult) Descriptor() ([]byte, []int) { + return fileDescriptor_92a6463c7f7e20b5, []int{7} +} +func (m *SignedSubmitContractResult) XXX_Unmarshal(b []byte) error { + return xxx_messageInfo_SignedSubmitContractResult.Unmarshal(m, b) +} +func (m *SignedSubmitContractResult) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { + return xxx_messageInfo_SignedSubmitContractResult.Marshal(b, m, deterministic) +} +func (m *SignedSubmitContractResult) XXX_Merge(src proto.Message) { + xxx_messageInfo_SignedSubmitContractResult.Merge(m, src) +} +func (m *SignedSubmitContractResult) XXX_Size() int { + return xxx_messageInfo_SignedSubmitContractResult.Size(m) +} +func (m *SignedSubmitContractResult) XXX_DiscardUnknown() { + xxx_messageInfo_SignedSubmitContractResult.DiscardUnknown(m) +} + +var xxx_messageInfo_SignedSubmitContractResult proto.InternalMessageInfo + +func (m *SignedSubmitContractResult) GetResult() *SubmitContractResult { + if m != nil { + return m.Result + } + return nil +} + +func (m *SignedSubmitContractResult) GetEscrowSignature() []byte { if m != nil { return m.EscrowSignature } @@ -521,7 +600,6 @@ func (m *EscrowContractResult) GetEscrowSignature() []byte { type PayinRquest struct { PayinId []byte `protobuf:"bytes,1,opt,name=payin_id,json=payinId,proto3" json:"payin_id,omitempty"` BuyerAddress []byte `protobuf:"bytes,2,opt,name=buyer_address,json=buyerAddress,proto3" json:"buyer_address,omitempty"` - BuyerSignature []byte `protobuf:"bytes,3,opt,name=buyer_signature,json=buyerSignature,proto3" json:"buyer_signature,omitempty"` XXX_NoUnkeyedLiteral struct{} `json:"-"` XXX_unrecognized []byte `json:"-"` XXX_sizecache int32 `json:"-"` @@ -531,7 +609,7 @@ func (m *PayinRquest) Reset() { *m = PayinRquest{} } func (m *PayinRquest) String() string { return proto.CompactTextString(m) } func (*PayinRquest) ProtoMessage() {} func (*PayinRquest) Descriptor() ([]byte, []int) { - return fileDescriptor_92a6463c7f7e20b5, []int{6} + return fileDescriptor_92a6463c7f7e20b5, []int{8} } func (m *PayinRquest) XXX_Unmarshal(b []byte) error { return xxx_messageInfo_PayinRquest.Unmarshal(m, b) @@ -565,7 +643,46 @@ func (m *PayinRquest) GetBuyerAddress() []byte { return nil } -func (m *PayinRquest) GetBuyerSignature() []byte { +type SignedPayinRquest struct { + Request *PayinRquest `protobuf:"bytes,1,opt,name=request,proto3" json:"request,omitempty"` + BuyerSignature []byte `protobuf:"bytes,2,opt,name=buyer_signature,json=buyerSignature,proto3" json:"buyer_signature,omitempty"` + XXX_NoUnkeyedLiteral struct{} `json:"-"` + XXX_unrecognized []byte `json:"-"` + XXX_sizecache int32 `json:"-"` +} + +func (m *SignedPayinRquest) Reset() { *m = SignedPayinRquest{} } +func (m *SignedPayinRquest) String() string { return proto.CompactTextString(m) } +func (*SignedPayinRquest) ProtoMessage() {} +func (*SignedPayinRquest) Descriptor() ([]byte, []int) { + return fileDescriptor_92a6463c7f7e20b5, []int{9} +} +func (m *SignedPayinRquest) XXX_Unmarshal(b []byte) error { + return xxx_messageInfo_SignedPayinRquest.Unmarshal(m, b) +} +func (m *SignedPayinRquest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { + return xxx_messageInfo_SignedPayinRquest.Marshal(b, m, deterministic) +} +func (m *SignedPayinRquest) XXX_Merge(src proto.Message) { + xxx_messageInfo_SignedPayinRquest.Merge(m, src) +} +func (m *SignedPayinRquest) XXX_Size() int { + return xxx_messageInfo_SignedPayinRquest.Size(m) +} +func (m *SignedPayinRquest) XXX_DiscardUnknown() { + xxx_messageInfo_SignedPayinRquest.DiscardUnknown(m) +} + +var xxx_messageInfo_SignedPayinRquest proto.InternalMessageInfo + +func (m *SignedPayinRquest) GetRequest() *PayinRquest { + if m != nil { + return m.Request + } + return nil +} + +func (m *SignedPayinRquest) GetBuyerSignature() []byte { if m != nil { return m.BuyerSignature } @@ -573,22 +690,21 @@ func (m *PayinRquest) GetBuyerSignature() []byte { } type PayinResult struct { - PayinId []byte `protobuf:"bytes,1,opt,name=payin_id,json=payinId,proto3" json:"payin_id,omitempty"` - Amount int64 `protobuf:"varint,2,opt,name=amount,proto3" json:"amount,omitempty"` - SequenceId int64 `protobuf:"varint,3,opt,name=sequence_id,json=sequenceId,proto3" json:"sequence_id,omitempty"` - EscrowAddress []byte `protobuf:"bytes,4,opt,name=escrow_address,json=escrowAddress,proto3" json:"escrow_address,omitempty"` - EscrowSignedTime *types.Timestamp `protobuf:"bytes,5,opt,name=escrow_signed_time,json=escrowSignedTime,proto3" json:"escrow_signed_time,omitempty"` - EscrowSignature []byte `protobuf:"bytes,6,opt,name=escrow_signature,json=escrowSignature,proto3" json:"escrow_signature,omitempty"` - XXX_NoUnkeyedLiteral struct{} `json:"-"` - XXX_unrecognized []byte `json:"-"` - XXX_sizecache int32 `json:"-"` + PayinId []byte `protobuf:"bytes,1,opt,name=payin_id,json=payinId,proto3" json:"payin_id,omitempty"` + Amount int64 `protobuf:"varint,2,opt,name=amount,proto3" json:"amount,omitempty"` + SequenceId int64 `protobuf:"varint,3,opt,name=sequence_id,json=sequenceId,proto3" json:"sequence_id,omitempty"` + EscrowAddress []byte `protobuf:"bytes,4,opt,name=escrow_address,json=escrowAddress,proto3" json:"escrow_address,omitempty"` + EscrowSignedTime *time.Time `protobuf:"bytes,5,opt,name=escrow_signed_time,json=escrowSignedTime,proto3,stdtime" json:"escrow_signed_time,omitempty"` + XXX_NoUnkeyedLiteral struct{} `json:"-"` + XXX_unrecognized []byte `json:"-"` + XXX_sizecache int32 `json:"-"` } func (m *PayinResult) Reset() { *m = PayinResult{} } func (m *PayinResult) String() string { return proto.CompactTextString(m) } func (*PayinResult) ProtoMessage() {} func (*PayinResult) Descriptor() ([]byte, []int) { - return fileDescriptor_92a6463c7f7e20b5, []int{7} + return fileDescriptor_92a6463c7f7e20b5, []int{10} } func (m *PayinResult) XXX_Unmarshal(b []byte) error { return xxx_messageInfo_PayinResult.Unmarshal(m, b) @@ -636,14 +752,53 @@ func (m *PayinResult) GetEscrowAddress() []byte { return nil } -func (m *PayinResult) GetEscrowSignedTime() *types.Timestamp { +func (m *PayinResult) GetEscrowSignedTime() *time.Time { if m != nil { return m.EscrowSignedTime } return nil } -func (m *PayinResult) GetEscrowSignature() []byte { +type SignedPayinResult struct { + Result *PayinResult `protobuf:"bytes,1,opt,name=result,proto3" json:"result,omitempty"` + EscrowSignature []byte `protobuf:"bytes,2,opt,name=escrow_signature,json=escrowSignature,proto3" json:"escrow_signature,omitempty"` + XXX_NoUnkeyedLiteral struct{} `json:"-"` + XXX_unrecognized []byte `json:"-"` + XXX_sizecache int32 `json:"-"` +} + +func (m *SignedPayinResult) Reset() { *m = SignedPayinResult{} } +func (m *SignedPayinResult) String() string { return proto.CompactTextString(m) } +func (*SignedPayinResult) ProtoMessage() {} +func (*SignedPayinResult) Descriptor() ([]byte, []int) { + return fileDescriptor_92a6463c7f7e20b5, []int{11} +} +func (m *SignedPayinResult) XXX_Unmarshal(b []byte) error { + return xxx_messageInfo_SignedPayinResult.Unmarshal(m, b) +} +func (m *SignedPayinResult) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { + return xxx_messageInfo_SignedPayinResult.Marshal(b, m, deterministic) +} +func (m *SignedPayinResult) XXX_Merge(src proto.Message) { + xxx_messageInfo_SignedPayinResult.Merge(m, src) +} +func (m *SignedPayinResult) XXX_Size() int { + return xxx_messageInfo_SignedPayinResult.Size(m) +} +func (m *SignedPayinResult) XXX_DiscardUnknown() { + xxx_messageInfo_SignedPayinResult.DiscardUnknown(m) +} + +var xxx_messageInfo_SignedPayinResult proto.InternalMessageInfo + +func (m *SignedPayinResult) GetResult() *PayinResult { + if m != nil { + return m.Result + } + return nil +} + +func (m *SignedPayinResult) GetEscrowSignature() []byte { if m != nil { return m.EscrowSignature } @@ -651,18 +806,20 @@ func (m *PayinResult) GetEscrowSignature() []byte { } type PayinStatus struct { - Paid bool `protobuf:"varint,1,opt,name=paid,proto3" json:"paid,omitempty"` - SequenceId int64 `protobuf:"varint,2,opt,name=sequence_id,json=sequenceId,proto3" json:"sequence_id,omitempty"` - XXX_NoUnkeyedLiteral struct{} `json:"-"` - XXX_unrecognized []byte `json:"-"` - XXX_sizecache int32 `json:"-"` + Paid bool `protobuf:"varint,1,opt,name=paid,proto3" json:"paid,omitempty"` + SequenceId int64 `protobuf:"varint,2,opt,name=sequence_id,json=sequenceId,proto3" json:"sequence_id,omitempty"` + EscrowAddress []byte `protobuf:"bytes,3,opt,name=escrow_address,json=escrowAddress,proto3" json:"escrow_address,omitempty"` + EscrowSignedTime *time.Time `protobuf:"bytes,4,opt,name=escrow_signed_time,json=escrowSignedTime,proto3,stdtime" json:"escrow_signed_time,omitempty"` + XXX_NoUnkeyedLiteral struct{} `json:"-"` + XXX_unrecognized []byte `json:"-"` + XXX_sizecache int32 `json:"-"` } func (m *PayinStatus) Reset() { *m = PayinStatus{} } func (m *PayinStatus) String() string { return proto.CompactTextString(m) } func (*PayinStatus) ProtoMessage() {} func (*PayinStatus) Descriptor() ([]byte, []int) { - return fileDescriptor_92a6463c7f7e20b5, []int{8} + return fileDescriptor_92a6463c7f7e20b5, []int{12} } func (m *PayinStatus) XXX_Unmarshal(b []byte) error { return xxx_messageInfo_PayinStatus.Unmarshal(m, b) @@ -696,34 +853,93 @@ func (m *PayinStatus) GetSequenceId() int64 { return 0 } +func (m *PayinStatus) GetEscrowAddress() []byte { + if m != nil { + return m.EscrowAddress + } + return nil +} + +func (m *PayinStatus) GetEscrowSignedTime() *time.Time { + if m != nil { + return m.EscrowSignedTime + } + return nil +} + +type SignedPayinStatus struct { + Status *PayinStatus `protobuf:"bytes,1,opt,name=status,proto3" json:"status,omitempty"` + EscrowSignature []byte `protobuf:"bytes,2,opt,name=escrow_signature,json=escrowSignature,proto3" json:"escrow_signature,omitempty"` + XXX_NoUnkeyedLiteral struct{} `json:"-"` + XXX_unrecognized []byte `json:"-"` + XXX_sizecache int32 `json:"-"` +} + +func (m *SignedPayinStatus) Reset() { *m = SignedPayinStatus{} } +func (m *SignedPayinStatus) String() string { return proto.CompactTextString(m) } +func (*SignedPayinStatus) ProtoMessage() {} +func (*SignedPayinStatus) Descriptor() ([]byte, []int) { + return fileDescriptor_92a6463c7f7e20b5, []int{13} +} +func (m *SignedPayinStatus) XXX_Unmarshal(b []byte) error { + return xxx_messageInfo_SignedPayinStatus.Unmarshal(m, b) +} +func (m *SignedPayinStatus) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { + return xxx_messageInfo_SignedPayinStatus.Marshal(b, m, deterministic) +} +func (m *SignedPayinStatus) XXX_Merge(src proto.Message) { + xxx_messageInfo_SignedPayinStatus.Merge(m, src) +} +func (m *SignedPayinStatus) XXX_Size() int { + return xxx_messageInfo_SignedPayinStatus.Size(m) +} +func (m *SignedPayinStatus) XXX_DiscardUnknown() { + xxx_messageInfo_SignedPayinStatus.DiscardUnknown(m) +} + +var xxx_messageInfo_SignedPayinStatus proto.InternalMessageInfo + +func (m *SignedPayinStatus) GetStatus() *PayinStatus { + if m != nil { + return m.Status + } + return nil +} + +func (m *SignedPayinStatus) GetEscrowSignature() []byte { + if m != nil { + return m.EscrowSignature + } + return nil +} + type PayoutStatus struct { - FromAddress []byte `protobuf:"bytes,1,opt,name=from_address,json=fromAddress,proto3" json:"from_address,omitempty"` - ToAddress []byte `protobuf:"bytes,2,opt,name=to_address,json=toAddress,proto3" json:"to_address,omitempty"` - AuthAddress []byte `protobuf:"bytes,3,opt,name=auth_address,json=authAddress,proto3" json:"auth_address,omitempty"` - Status EscrowStatus `protobuf:"varint,4,opt,name=status,proto3,enum=escrow.EscrowStatus" json:"status,omitempty"` - Amount int64 `protobuf:"varint,5,opt,name=amount,proto3" json:"amount,omitempty"` - Collateral int64 `protobuf:"varint,6,opt,name=collateral,proto3" json:"collateral,omitempty"` - Withhold int64 `protobuf:"varint,7,opt,name=withhold,proto3" json:"withhold,omitempty"` - PaidAmount int64 `protobuf:"varint,8,opt,name=paid_amount,json=paidAmount,proto3" json:"paid_amount,omitempty"` - NumPaid int32 `protobuf:"varint,9,opt,name=num_paid,json=numPaid,proto3" json:"num_paid,omitempty"` - LeftAmount int64 `protobuf:"varint,10,opt,name=left_amount,json=leftAmount,proto3" json:"left_amount,omitempty"` - NumLeft int32 `protobuf:"varint,11,opt,name=num_left,json=numLeft,proto3" json:"num_left,omitempty"` - NextAmount int64 `protobuf:"varint,12,opt,name=next_amount,json=nextAmount,proto3" json:"next_amount,omitempty"` - LastPayoutTime *types.Timestamp `protobuf:"bytes,13,opt,name=last_payout_time,json=lastPayoutTime,proto3" json:"last_payout_time,omitempty"` - NextPayoutTime *types.Timestamp `protobuf:"bytes,14,opt,name=next_payout_time,json=nextPayoutTime,proto3" json:"next_payout_time,omitempty"` - EscrowAddress []byte `protobuf:"bytes,15,opt,name=escrow_address,json=escrowAddress,proto3" json:"escrow_address,omitempty"` - SignTime *types.Timestamp `protobuf:"bytes,16,opt,name=sign_time,json=signTime,proto3" json:"sign_time,omitempty"` - EscrowSignature []byte `protobuf:"bytes,17,opt,name=escrow_signature,json=escrowSignature,proto3" json:"escrow_signature,omitempty"` - XXX_NoUnkeyedLiteral struct{} `json:"-"` - XXX_unrecognized []byte `json:"-"` - XXX_sizecache int32 `json:"-"` + FromAddress []byte `protobuf:"bytes,1,opt,name=from_address,json=fromAddress,proto3" json:"from_address,omitempty"` + ToAddress []byte `protobuf:"bytes,2,opt,name=to_address,json=toAddress,proto3" json:"to_address,omitempty"` + AuthAddress []byte `protobuf:"bytes,3,opt,name=auth_address,json=authAddress,proto3" json:"auth_address,omitempty"` + Status EscrowStatus `protobuf:"varint,4,opt,name=status,proto3,enum=escrow.EscrowStatus" json:"status,omitempty"` + Amount int64 `protobuf:"varint,5,opt,name=amount,proto3" json:"amount,omitempty"` + Collateral int64 `protobuf:"varint,6,opt,name=collateral,proto3" json:"collateral,omitempty"` + Withhold int64 `protobuf:"varint,7,opt,name=withhold,proto3" json:"withhold,omitempty"` + PaidAmount int64 `protobuf:"varint,8,opt,name=paid_amount,json=paidAmount,proto3" json:"paid_amount,omitempty"` + NumPaid int32 `protobuf:"varint,9,opt,name=num_paid,json=numPaid,proto3" json:"num_paid,omitempty"` + LeftAmount int64 `protobuf:"varint,10,opt,name=left_amount,json=leftAmount,proto3" json:"left_amount,omitempty"` + NumLeft int32 `protobuf:"varint,11,opt,name=num_left,json=numLeft,proto3" json:"num_left,omitempty"` + NextAmount int64 `protobuf:"varint,12,opt,name=next_amount,json=nextAmount,proto3" json:"next_amount,omitempty"` + LastPayoutTime *time.Time `protobuf:"bytes,13,opt,name=last_payout_time,json=lastPayoutTime,proto3,stdtime" json:"last_payout_time,omitempty"` + NextPayoutTime *time.Time `protobuf:"bytes,14,opt,name=next_payout_time,json=nextPayoutTime,proto3,stdtime" json:"next_payout_time,omitempty"` + EscrowAddress []byte `protobuf:"bytes,15,opt,name=escrow_address,json=escrowAddress,proto3" json:"escrow_address,omitempty"` + EscrowSignTime *time.Time `protobuf:"bytes,16,opt,name=escrow_sign_time,json=escrowSignTime,proto3,stdtime" json:"escrow_sign_time,omitempty"` + XXX_NoUnkeyedLiteral struct{} `json:"-"` + XXX_unrecognized []byte `json:"-"` + XXX_sizecache int32 `json:"-"` } func (m *PayoutStatus) Reset() { *m = PayoutStatus{} } func (m *PayoutStatus) String() string { return proto.CompactTextString(m) } func (*PayoutStatus) ProtoMessage() {} func (*PayoutStatus) Descriptor() ([]byte, []int) { - return fileDescriptor_92a6463c7f7e20b5, []int{9} + return fileDescriptor_92a6463c7f7e20b5, []int{14} } func (m *PayoutStatus) XXX_Unmarshal(b []byte) error { return xxx_messageInfo_PayoutStatus.Unmarshal(m, b) @@ -827,14 +1043,14 @@ func (m *PayoutStatus) GetNextAmount() int64 { return 0 } -func (m *PayoutStatus) GetLastPayoutTime() *types.Timestamp { +func (m *PayoutStatus) GetLastPayoutTime() *time.Time { if m != nil { return m.LastPayoutTime } return nil } -func (m *PayoutStatus) GetNextPayoutTime() *types.Timestamp { +func (m *PayoutStatus) GetNextPayoutTime() *time.Time { if m != nil { return m.NextPayoutTime } @@ -848,14 +1064,53 @@ func (m *PayoutStatus) GetEscrowAddress() []byte { return nil } -func (m *PayoutStatus) GetSignTime() *types.Timestamp { +func (m *PayoutStatus) GetEscrowSignTime() *time.Time { if m != nil { - return m.SignTime + return m.EscrowSignTime } return nil } -func (m *PayoutStatus) GetEscrowSignature() []byte { +type SignedPayoutStatus struct { + Status *PayoutStatus `protobuf:"bytes,1,opt,name=status,proto3" json:"status,omitempty"` + EscrowSignature []byte `protobuf:"bytes,2,opt,name=escrow_signature,json=escrowSignature,proto3" json:"escrow_signature,omitempty"` + XXX_NoUnkeyedLiteral struct{} `json:"-"` + XXX_unrecognized []byte `json:"-"` + XXX_sizecache int32 `json:"-"` +} + +func (m *SignedPayoutStatus) Reset() { *m = SignedPayoutStatus{} } +func (m *SignedPayoutStatus) String() string { return proto.CompactTextString(m) } +func (*SignedPayoutStatus) ProtoMessage() {} +func (*SignedPayoutStatus) Descriptor() ([]byte, []int) { + return fileDescriptor_92a6463c7f7e20b5, []int{15} +} +func (m *SignedPayoutStatus) XXX_Unmarshal(b []byte) error { + return xxx_messageInfo_SignedPayoutStatus.Unmarshal(m, b) +} +func (m *SignedPayoutStatus) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { + return xxx_messageInfo_SignedPayoutStatus.Marshal(b, m, deterministic) +} +func (m *SignedPayoutStatus) XXX_Merge(src proto.Message) { + xxx_messageInfo_SignedPayoutStatus.Merge(m, src) +} +func (m *SignedPayoutStatus) XXX_Size() int { + return xxx_messageInfo_SignedPayoutStatus.Size(m) +} +func (m *SignedPayoutStatus) XXX_DiscardUnknown() { + xxx_messageInfo_SignedPayoutStatus.DiscardUnknown(m) +} + +var xxx_messageInfo_SignedPayoutStatus proto.InternalMessageInfo + +func (m *SignedPayoutStatus) GetStatus() *PayoutStatus { + if m != nil { + return m.Status + } + return nil +} + +func (m *SignedPayoutStatus) GetEscrowSignature() []byte { if m != nil { return m.EscrowSignature } @@ -865,7 +1120,6 @@ func (m *PayoutStatus) GetEscrowSignature() []byte { type CancelContractRequest struct { ContractId [][]byte `protobuf:"bytes,1,rep,name=contract_id,json=contractId,proto3" json:"contract_id,omitempty"` AuthAddress []byte `protobuf:"bytes,2,opt,name=auth_address,json=authAddress,proto3" json:"auth_address,omitempty"` - AuthSignature []byte `protobuf:"bytes,3,opt,name=auth_signature,json=authSignature,proto3" json:"auth_signature,omitempty"` XXX_NoUnkeyedLiteral struct{} `json:"-"` XXX_unrecognized []byte `json:"-"` XXX_sizecache int32 `json:"-"` @@ -875,7 +1129,7 @@ func (m *CancelContractRequest) Reset() { *m = CancelContractRequest{} } func (m *CancelContractRequest) String() string { return proto.CompactTextString(m) } func (*CancelContractRequest) ProtoMessage() {} func (*CancelContractRequest) Descriptor() ([]byte, []int) { - return fileDescriptor_92a6463c7f7e20b5, []int{10} + return fileDescriptor_92a6463c7f7e20b5, []int{16} } func (m *CancelContractRequest) XXX_Unmarshal(b []byte) error { return xxx_messageInfo_CancelContractRequest.Unmarshal(m, b) @@ -909,7 +1163,46 @@ func (m *CancelContractRequest) GetAuthAddress() []byte { return nil } -func (m *CancelContractRequest) GetAuthSignature() []byte { +type SignedCancelRequest struct { + Request *CancelContractRequest `protobuf:"bytes,1,opt,name=request,proto3" json:"request,omitempty"` + AuthSignature []byte `protobuf:"bytes,2,opt,name=auth_signature,json=authSignature,proto3" json:"auth_signature,omitempty"` + XXX_NoUnkeyedLiteral struct{} `json:"-"` + XXX_unrecognized []byte `json:"-"` + XXX_sizecache int32 `json:"-"` +} + +func (m *SignedCancelRequest) Reset() { *m = SignedCancelRequest{} } +func (m *SignedCancelRequest) String() string { return proto.CompactTextString(m) } +func (*SignedCancelRequest) ProtoMessage() {} +func (*SignedCancelRequest) Descriptor() ([]byte, []int) { + return fileDescriptor_92a6463c7f7e20b5, []int{17} +} +func (m *SignedCancelRequest) XXX_Unmarshal(b []byte) error { + return xxx_messageInfo_SignedCancelRequest.Unmarshal(m, b) +} +func (m *SignedCancelRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { + return xxx_messageInfo_SignedCancelRequest.Marshal(b, m, deterministic) +} +func (m *SignedCancelRequest) XXX_Merge(src proto.Message) { + xxx_messageInfo_SignedCancelRequest.Merge(m, src) +} +func (m *SignedCancelRequest) XXX_Size() int { + return xxx_messageInfo_SignedCancelRequest.Size(m) +} +func (m *SignedCancelRequest) XXX_DiscardUnknown() { + xxx_messageInfo_SignedCancelRequest.DiscardUnknown(m) +} + +var xxx_messageInfo_SignedCancelRequest proto.InternalMessageInfo + +func (m *SignedCancelRequest) GetRequest() *CancelContractRequest { + if m != nil { + return m.Request + } + return nil +} + +func (m *SignedCancelRequest) GetAuthSignature() []byte { if m != nil { return m.AuthSignature } @@ -917,20 +1210,21 @@ func (m *CancelContractRequest) GetAuthSignature() []byte { } type CancelContractResult struct { - Result *CancelContractResult_Result `protobuf:"bytes,1,opt,name=result,proto3" json:"result,omitempty"` - EscrowAddress []byte `protobuf:"bytes,2,opt,name=escrow_address,json=escrowAddress,proto3" json:"escrow_address,omitempty"` - EscrowSignedTime *types.Timestamp `protobuf:"bytes,3,opt,name=escrow_signed_time,json=escrowSignedTime,proto3" json:"escrow_signed_time,omitempty"` - EscrowSignature []byte `protobuf:"bytes,4,opt,name=escrow_signature,json=escrowSignature,proto3" json:"escrow_signature,omitempty"` - XXX_NoUnkeyedLiteral struct{} `json:"-"` - XXX_unrecognized []byte `json:"-"` - XXX_sizecache int32 `json:"-"` + ContractId []byte `protobuf:"bytes,1,opt,name=contract_id,json=contractId,proto3" json:"contract_id,omitempty"` + EscrowId int64 `protobuf:"varint,2,opt,name=escrow_id,json=escrowId,proto3" json:"escrow_id,omitempty"` + Canceled bool `protobuf:"varint,3,opt,name=canceled,proto3" json:"canceled,omitempty"` + EscrowAddress []byte `protobuf:"bytes,4,opt,name=escrow_address,json=escrowAddress,proto3" json:"escrow_address,omitempty"` + EscrowSignedTime *time.Time `protobuf:"bytes,5,opt,name=escrow_signed_time,json=escrowSignedTime,proto3,stdtime" json:"escrow_signed_time,omitempty"` + XXX_NoUnkeyedLiteral struct{} `json:"-"` + XXX_unrecognized []byte `json:"-"` + XXX_sizecache int32 `json:"-"` } func (m *CancelContractResult) Reset() { *m = CancelContractResult{} } func (m *CancelContractResult) String() string { return proto.CompactTextString(m) } func (*CancelContractResult) ProtoMessage() {} func (*CancelContractResult) Descriptor() ([]byte, []int) { - return fileDescriptor_92a6463c7f7e20b5, []int{11} + return fileDescriptor_92a6463c7f7e20b5, []int{18} } func (m *CancelContractResult) XXX_Unmarshal(b []byte) error { return xxx_messageInfo_CancelContractResult.Unmarshal(m, b) @@ -950,86 +1244,85 @@ func (m *CancelContractResult) XXX_DiscardUnknown() { var xxx_messageInfo_CancelContractResult proto.InternalMessageInfo -func (m *CancelContractResult) GetResult() *CancelContractResult_Result { +func (m *CancelContractResult) GetContractId() []byte { if m != nil { - return m.Result + return m.ContractId } return nil } -func (m *CancelContractResult) GetEscrowAddress() []byte { +func (m *CancelContractResult) GetEscrowId() int64 { if m != nil { - return m.EscrowAddress + return m.EscrowId } - return nil + return 0 } -func (m *CancelContractResult) GetEscrowSignedTime() *types.Timestamp { +func (m *CancelContractResult) GetCanceled() bool { if m != nil { - return m.EscrowSignedTime + return m.Canceled + } + return false +} + +func (m *CancelContractResult) GetEscrowAddress() []byte { + if m != nil { + return m.EscrowAddress } return nil } -func (m *CancelContractResult) GetEscrowSignature() []byte { +func (m *CancelContractResult) GetEscrowSignedTime() *time.Time { if m != nil { - return m.EscrowSignature + return m.EscrowSignedTime } return nil } -type CancelContractResult_Result struct { - ContractId []byte `protobuf:"bytes,1,opt,name=contract_id,json=contractId,proto3" json:"contract_id,omitempty"` - EscrowId int64 `protobuf:"varint,2,opt,name=escrow_id,json=escrowId,proto3" json:"escrow_id,omitempty"` - Canceled bool `protobuf:"varint,3,opt,name=canceled,proto3" json:"canceled,omitempty"` - XXX_NoUnkeyedLiteral struct{} `json:"-"` - XXX_unrecognized []byte `json:"-"` - XXX_sizecache int32 `json:"-"` +type SignedCancelContractResult struct { + Result *CancelContractResult `protobuf:"bytes,1,opt,name=result,proto3" json:"result,omitempty"` + EscrowSignature []byte `protobuf:"bytes,2,opt,name=escrow_signature,json=escrowSignature,proto3" json:"escrow_signature,omitempty"` + XXX_NoUnkeyedLiteral struct{} `json:"-"` + XXX_unrecognized []byte `json:"-"` + XXX_sizecache int32 `json:"-"` } -func (m *CancelContractResult_Result) Reset() { *m = CancelContractResult_Result{} } -func (m *CancelContractResult_Result) String() string { return proto.CompactTextString(m) } -func (*CancelContractResult_Result) ProtoMessage() {} -func (*CancelContractResult_Result) Descriptor() ([]byte, []int) { - return fileDescriptor_92a6463c7f7e20b5, []int{11, 0} +func (m *SignedCancelContractResult) Reset() { *m = SignedCancelContractResult{} } +func (m *SignedCancelContractResult) String() string { return proto.CompactTextString(m) } +func (*SignedCancelContractResult) ProtoMessage() {} +func (*SignedCancelContractResult) Descriptor() ([]byte, []int) { + return fileDescriptor_92a6463c7f7e20b5, []int{19} } -func (m *CancelContractResult_Result) XXX_Unmarshal(b []byte) error { - return xxx_messageInfo_CancelContractResult_Result.Unmarshal(m, b) +func (m *SignedCancelContractResult) XXX_Unmarshal(b []byte) error { + return xxx_messageInfo_SignedCancelContractResult.Unmarshal(m, b) } -func (m *CancelContractResult_Result) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - return xxx_messageInfo_CancelContractResult_Result.Marshal(b, m, deterministic) +func (m *SignedCancelContractResult) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { + return xxx_messageInfo_SignedCancelContractResult.Marshal(b, m, deterministic) } -func (m *CancelContractResult_Result) XXX_Merge(src proto.Message) { - xxx_messageInfo_CancelContractResult_Result.Merge(m, src) +func (m *SignedCancelContractResult) XXX_Merge(src proto.Message) { + xxx_messageInfo_SignedCancelContractResult.Merge(m, src) } -func (m *CancelContractResult_Result) XXX_Size() int { - return xxx_messageInfo_CancelContractResult_Result.Size(m) +func (m *SignedCancelContractResult) XXX_Size() int { + return xxx_messageInfo_SignedCancelContractResult.Size(m) } -func (m *CancelContractResult_Result) XXX_DiscardUnknown() { - xxx_messageInfo_CancelContractResult_Result.DiscardUnknown(m) +func (m *SignedCancelContractResult) XXX_DiscardUnknown() { + xxx_messageInfo_SignedCancelContractResult.DiscardUnknown(m) } -var xxx_messageInfo_CancelContractResult_Result proto.InternalMessageInfo +var xxx_messageInfo_SignedCancelContractResult proto.InternalMessageInfo -func (m *CancelContractResult_Result) GetContractId() []byte { +func (m *SignedCancelContractResult) GetResult() *CancelContractResult { if m != nil { - return m.ContractId + return m.Result } return nil } -func (m *CancelContractResult_Result) GetEscrowId() int64 { +func (m *SignedCancelContractResult) GetEscrowSignature() []byte { if m != nil { - return m.EscrowId - } - return 0 -} - -func (m *CancelContractResult_Result) GetCanceled() bool { - if m != nil { - return m.Canceled + return m.EscrowSignature } - return false + return nil } func init() { @@ -1037,98 +1330,114 @@ func init() { proto.RegisterEnum("escrow.Schedule", Schedule_name, Schedule_value) proto.RegisterEnum("escrow.EscrowStatus", EscrowStatus_name, EscrowStatus_value) proto.RegisterType((*ContractID)(nil), "escrow.ContractID") + proto.RegisterType((*SignedContractID)(nil), "escrow.SignedContractID") proto.RegisterType((*EscrowContract)(nil), "escrow.EscrowContract") proto.RegisterType((*SignedEscrowContract)(nil), "escrow.SignedEscrowContract") proto.RegisterType((*EscrowContractRequest)(nil), "escrow.EscrowContractRequest") proto.RegisterType((*Escrow)(nil), "escrow.Escrow") - proto.RegisterType((*EscrowContractResult)(nil), "escrow.EscrowContractResult") + proto.RegisterType((*SubmitContractResult)(nil), "escrow.SubmitContractResult") + proto.RegisterType((*SignedSubmitContractResult)(nil), "escrow.SignedSubmitContractResult") proto.RegisterType((*PayinRquest)(nil), "escrow.PayinRquest") + proto.RegisterType((*SignedPayinRquest)(nil), "escrow.SignedPayinRquest") proto.RegisterType((*PayinResult)(nil), "escrow.PayinResult") + proto.RegisterType((*SignedPayinResult)(nil), "escrow.SignedPayinResult") proto.RegisterType((*PayinStatus)(nil), "escrow.PayinStatus") + proto.RegisterType((*SignedPayinStatus)(nil), "escrow.SignedPayinStatus") proto.RegisterType((*PayoutStatus)(nil), "escrow.PayoutStatus") + proto.RegisterType((*SignedPayoutStatus)(nil), "escrow.SignedPayoutStatus") proto.RegisterType((*CancelContractRequest)(nil), "escrow.CancelContractRequest") + proto.RegisterType((*SignedCancelRequest)(nil), "escrow.SignedCancelRequest") proto.RegisterType((*CancelContractResult)(nil), "escrow.CancelContractResult") - proto.RegisterType((*CancelContractResult_Result)(nil), "escrow.CancelContractResult.Result") + proto.RegisterType((*SignedCancelContractResult)(nil), "escrow.SignedCancelContractResult") } func init() { proto.RegisterFile("protos/escrow/escrow.proto", fileDescriptor_92a6463c7f7e20b5) } var fileDescriptor_92a6463c7f7e20b5 = []byte{ - // 1174 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xac, 0x57, 0x5f, 0x6f, 0xe2, 0x46, - 0x10, 0x8f, 0x4d, 0x00, 0x33, 0x80, 0x71, 0xb6, 0xdc, 0x89, 0xa3, 0xb9, 0x26, 0xe5, 0x74, 0x6d, - 0x2e, 0xad, 0x48, 0x4b, 0x2b, 0xb5, 0xd5, 0x3d, 0x11, 0x40, 0x3d, 0x24, 0x4a, 0x72, 0x86, 0xab, - 0x94, 0xbe, 0x20, 0x83, 0x97, 0x04, 0xd5, 0xd8, 0xd4, 0x5e, 0xdf, 0x95, 0xd7, 0x7e, 0x90, 0xbe, - 0xf5, 0x4b, 0xf4, 0x3b, 0xf4, 0xa5, 0xfd, 0x2c, 0x7d, 0xac, 0x54, 0xed, 0x3f, 0x1b, 0x1c, 0xa7, - 0x44, 0x6a, 0x9e, 0xc2, 0xfe, 0xf6, 0x37, 0xbb, 0x3b, 0x33, 0xbf, 0x99, 0x71, 0xa0, 0xbe, 0xf2, - 0x3d, 0xe2, 0x05, 0x67, 0x38, 0x98, 0xf9, 0xde, 0x3b, 0xf1, 0xa7, 0xc9, 0x40, 0x94, 0xe3, 0xab, - 0xfa, 0xd1, 0xb5, 0xe7, 0x5d, 0x3b, 0xf8, 0x8c, 0xa1, 0xd3, 0x70, 0x7e, 0x46, 0x16, 0x4b, 0x1c, - 0x10, 0x6b, 0xb9, 0xe2, 0xc4, 0x06, 0x06, 0xe8, 0x78, 0x2e, 0xf1, 0xad, 0x19, 0xe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x33, 0x19, 0xa0, - 0xa7, 0x77, 0x7c, 0x85, 0x71, 0x55, 0xd6, 0x0f, 0xef, 0xda, 0x66, 0xc1, 0xfc, 0x1c, 0xb2, 0x97, - 0xd6, 0xba, 0xef, 0xa2, 0xf7, 0x24, 0x6d, 0x63, 0x80, 0xd6, 0x13, 0xa0, 0x34, 0xc9, 0xf5, 0x03, - 0xd6, 0x7e, 0x50, 0x24, 0xae, 0xe8, 0x9f, 0x8a, 0x84, 0x89, 0x70, 0xfe, 0x25, 0x54, 0xbe, 0xc5, - 0xb4, 0x9e, 0x2f, 0xa2, 0xee, 0x9e, 0x66, 0x5b, 0xdd, 0xb0, 0x8d, 0xe7, 0xc0, 0x10, 0x2a, 0xdb, - 0xe2, 0xdd, 0x70, 0x39, 0xb5, 0x10, 0x63, 0x97, 0xd3, 0x44, 0x7f, 0xfe, 0x02, 0xf4, 0x85, 0xd7, - 0x9c, 0x92, 0x79, 0x20, 0x68, 0xe7, 0x45, 0x1e, 0x9a, 0x4b, 0x2a, 0xd9, 0x4b, 0xe5, 0x07, 0x21, - 0x96, 0xd5, 0x74, 0x9a, 0x63, 0x2a, 0xfe, 0xe2, 0xdf, 0x00, 0x00, 0x00, 0xff, 0xff, 0x3e, 0x6e, - 0x17, 0xc2, 0x7d, 0x0d, 0x00, 0x00, + // 1318 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xc4, 0x57, 0xcb, 0x72, 0x1b, 0x45, + 0x17, 0xce, 0x48, 0xb6, 0x34, 0x3a, 0xba, 0x4d, 0x3a, 0x4e, 0x4a, 0x51, 0x92, 0xdf, 0xfe, 0x87, + 0x4a, 0x70, 0x6e, 0x0a, 0x25, 0x52, 0x05, 0x2c, 0x58, 0xc8, 0xb2, 0x2a, 0x28, 0xa5, 0x28, 0xce, + 0x58, 0xa1, 0x30, 0x2c, 0x54, 0x23, 0x4d, 0x4b, 0x56, 0x65, 0x34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, 0xcf, 0xb0, 0x87, 0x9d, 0x29, 0x6e, 0x94, + 0xf9, 0xe3, 0x85, 0x02, 0xfd, 0x07, 0x05, 0x76, 0x38, 0x2f, 0x52, 0x4f, 0xd8, 0x06, 0x55, 0xbe, + 0x97, 0xe0, 0xc7, 0x0d, 0x79, 0x97, 0x24, 0xd2, 0x08, 0x71, 0x34, 0x42, 0xfc, 0x55, 0xd3, 0x6c, + 0xa9, 0x31, 0xf1, 0xb1, 0x94, 0xa2, 0xfb, 0xa0, 0x89, 0x97, 0x8d, 0x90, 0xfc, 0x6d, 0xeb, 0x5c, + 0x1e, 0x42, 0xf5, 0x57, 0x70, 0x3d, 0x75, 0x1e, 0xfe, 0x32, 0xc0, 0x3e, 0x41, 0x1f, 0x26, 0x2e, + 0x98, 0xdf, 0x2f, 0xb7, 0x6f, 0x87, 0xc1, 0xca, 0x70, 0x28, 0xba, 0xa6, 0xfe, 0xb3, 0x02, 0x05, + 0xbe, 0x79, 0x31, 0x51, 0x6f, 0x41, 0x89, 0x1b, 0xa5, 0xdb, 0x39, 0xf6, 0xdc, 0x2a, 0x17, 0xf4, + 0x2d, 0xca, 0xbc, 0x99, 0xe7, 0x2e, 0x53, 0xf4, 0x2c, 0x53, 0x99, 0x64, 0xde, 0x1d, 0xca, 0x85, + 0x14, 0x35, 0x4b, 0xc4, 0xfd, 0x27, 0x89, 0xa9, 0xff, 0x42, 0xdf, 0x30, 0x98, 0x2c, 0x17, 0x24, + 0x8a, 0x91, 0x1f, 0xd8, 0x04, 0xdd, 0x04, 0x75, 0x65, 0xae, 0x17, 0x4e, 0xe4, 0x5a, 0x91, 0xad, + 0xfb, 0x16, 0xba, 0x07, 0xa2, 0x62, 0x35, 0x72, 0x2c, 0x76, 0xb5, 0xe4, 0xe3, 0x1a, 0x62, 0x97, + 0xe6, 0xa0, 0xf0, 0x3f, 0x95, 0x83, 0x5c, 0x2a, 0xfd, 0x18, 0x02, 0x12, 0x30, 0x9f, 0xc5, 0x7e, + 0x4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51, 0x2a, + 0x13, 0x76, 0x62, 0x99, 0x10, 0xa2, 0x2e, 0x93, 0x0a, 0x5f, 0xc0, 0xf5, 0xae, 0xe9, 0x4c, 0xb1, + 0x9d, 0x1e, 0x56, 0xce, 0xcc, 0x19, 0xf9, 0xd4, 0x9c, 0x91, 0x66, 0x7c, 0xee, 0x0c, 0xe3, 0xf5, + 0x00, 0xae, 0x89, 0x09, 0x9e, 0x1d, 0x21, 0x4d, 0x7f, 0x90, 0xee, 0x23, 0x77, 0xc2, 0x39, 0x3e, + 0xeb, 0x2a, 0x51, 0x47, 0xb9, 0x0b, 0x35, 0x76, 0x64, 0xda, 0xab, 0x2a, 0x95, 0x46, 0x3e, 0xfd, + 0xae, 0xc0, 0x4e, 0xda, 0x12, 0xab, 0xa5, 0x7f, 0x6f, 0x76, 0x6a, 0x82, 0x3a, 0x65, 0x56, 0x31, + 0x6f, 0x30, 0xaa, 0x11, 0xae, 0xff, 0xab, 0xf6, 0x12, 0x0e, 0x1d, 0x99, 0xee, 0x9e, 0x3b, 0x74, + 0x64, 0xa1, 0x2f, 0xd1, 0x70, 0x1e, 0xec, 0x40, 0x29, 0xfc, 0x73, 0x80, 0x8a, 0x90, 0x3f, 0x18, + 0x8d, 0xb4, 0x2b, 0x0f, 0x9e, 0x82, 0x1a, 0xce, 0xfa, 0x65, 0x28, 0xbe, 0x78, 0x39, 0x1c, 0x7d, + 0x32, 0x38, 0xd1, 0xae, 0xa0, 0x2a, 0x94, 0x5e, 0xbd, 0xee, 0x18, 0xa3, 0x9e, 0x31, 0x38, 0xd1, + 0x14, 0x54, 0x01, 0xb5, 0x33, 0x1c, 0xbe, 0xee, 0x0c, 0x06, 0x27, 0x5a, 0xee, 0x41, 0x17, 0x2a, + 0xf1, 0x3a, 0x48, 0xc1, 0xfd, 0x61, 0x7f, 0xd4, 0xef, 0x8c, 0x7a, 0x87, 0xda, 0x15, 0x04, 0x50, + 0xe8, 0x74, 0x47, 0xfd, 0x4f, 0x7b, 0x5c, 0xb1, 0xdb, 0x19, 0x76, 0x7b, 0x83, 0xde, 0xa1, 0x96, + 0xa3, 0x3b, 0xdd, 0xc1, 0xcb, 0xe3, 0xde, 0xa1, 0x96, 0x6f, 0x7f, 0x9b, 0x87, 0xaa, 0xb0, 0x82, + 0xbd, 0xaf, 0x16, 0x53, 0x8c, 0x46, 0x50, 0x4f, 0x8e, 0x58, 0x3e, 0xba, 0x73, 0xce, 0xbf, 0x02, + 0x4e, 0xb2, 0xa6, 0x9e, 0x9c, 0xc9, 0x33, 0xc7, 0xb9, 0x8f, 0x61, 0xfb, 0xc8, 0x5c, 0xf7, 0x1d, + 0x74, 0x33, 0x09, 0x8e, 0xcd, 0x41, 0xcd, 0xcc, 0x2d, 0xa9, 0x5e, 0xe8, 0xfb, 0xac, 0xaa, 0x36, + 0x92, 0xa0, 0xe8, 0x7f, 0x6c, 0xa6, 0xba, 0x08, 0xcd, 0x33, 0xa8, 0x3f, 0xc3, 0xb4, 0x4c, 0xbd, + 0x0c, 0xeb, 0xc3, 0xf9, 0x76, 0x9a, 0x67, 0xec, 0x44, 0x55, 0xc5, 0x80, 0x7a, 0x92, 0x0a, 0x3e, + 0xba, 0x95, 0x32, 0x14, 0x4f, 0xdc, 0x74, 0x68, 0xb2, 0x68, 0x74, 0x70, 0x1f, 0x6a, 0x0b, 0xb7, + 0x35, 0x21, 0x33, 0x5f, 0x80, 0x0f, 0xca, 0x3c, 0xce, 0x47, 0x94, 0xd6, 0x47, 0xca, 0xe7, 0x22, + 0xa1, 0x56, 0x93, 0x49, 0x81, 0x31, 0xfd, 0xfd, 0x3f, 0x02, 0x00, 0x00, 0xff, 0xff, 0x7b, 0xd7, + 0x71, 0x69, 0xa6, 0x10, 0x00, 0x00, } // Reference imports to suppress errors if they are not otherwise used. @@ -1147,17 +1456,17 @@ type EscrowServiceClient interface { // one contract is one buyer to one seller, and is one escrow in escrow service // buyer can submit multiple contracts in one request // return same number of results as request contracts - SubmitContracts(ctx context.Context, in *EscrowContractRequest, opts ...grpc.CallOption) (*EscrowContractResult, error) + SubmitContracts(ctx context.Context, in *EscrowContractRequest, opts ...grpc.CallOption) (*SignedSubmitContractResult, error) // after submit contract, buyer request to pay in // escrow will transfer contract amount from buyer wallet to escrow wallet - PayIn(ctx context.Context, in *PayinRquest, opts ...grpc.CallOption) (*PayinResult, error) + PayIn(ctx context.Context, in *SignedPayinRquest, opts ...grpc.CallOption) (*SignedPayinResult, error) // seller use this to check if a contract is paid in - IsPaid(ctx context.Context, in *ContractID, opts ...grpc.CallOption) (*PayinStatus, error) + IsPaid(ctx context.Context, in *SignedContractID, opts ...grpc.CallOption) (*SignedPayinStatus, error) // check escrow pay out to seller status of a contract - GetPayOutStatus(ctx context.Context, in *ContractID, opts ...grpc.CallOption) (*PayoutStatus, error) + GetPayOutStatus(ctx context.Context, in *SignedContractID, opts ...grpc.CallOption) (*SignedPayoutStatus, error) // auth request to cancel the contract // escrow will cancel the left payments to seller - CancelContracts(ctx context.Context, in *CancelContractRequest, opts ...grpc.CallOption) (*CancelContractResult, error) + CancelContracts(ctx context.Context, in *SignedCancelRequest, opts ...grpc.CallOption) (*SignedCancelContractResult, error) } type escrowServiceClient struct { @@ -1168,8 +1477,8 @@ func NewEscrowServiceClient(cc *grpc.ClientConn) EscrowServiceClient { return &escrowServiceClient{cc} } -func (c *escrowServiceClient) SubmitContracts(ctx context.Context, in *EscrowContractRequest, opts ...grpc.CallOption) (*EscrowContractResult, error) { - out := new(EscrowContractResult) +func (c *escrowServiceClient) SubmitContracts(ctx context.Context, in *EscrowContractRequest, opts ...grpc.CallOption) (*SignedSubmitContractResult, error) { + out := new(SignedSubmitContractResult) err := c.cc.Invoke(ctx, "/escrow.EscrowService/SubmitContracts", in, out, opts...) if err != nil { return nil, err @@ -1177,8 +1486,8 @@ func (c *escrowServiceClient) SubmitContracts(ctx context.Context, in *EscrowCon return out, nil } -func (c *escrowServiceClient) PayIn(ctx context.Context, in *PayinRquest, opts ...grpc.CallOption) (*PayinResult, error) { - out := new(PayinResult) +func (c *escrowServiceClient) PayIn(ctx context.Context, in *SignedPayinRquest, opts ...grpc.CallOption) (*SignedPayinResult, error) { + out := new(SignedPayinResult) err := c.cc.Invoke(ctx, "/escrow.EscrowService/PayIn", in, out, opts...) if err != nil { return nil, err @@ -1186,8 +1495,8 @@ func (c *escrowServiceClient) PayIn(ctx context.Context, in *PayinRquest, opts . return out, nil } -func (c *escrowServiceClient) IsPaid(ctx context.Context, in *ContractID, opts ...grpc.CallOption) (*PayinStatus, error) { - out := new(PayinStatus) +func (c *escrowServiceClient) IsPaid(ctx context.Context, in *SignedContractID, opts ...grpc.CallOption) (*SignedPayinStatus, error) { + out := new(SignedPayinStatus) err := c.cc.Invoke(ctx, "/escrow.EscrowService/IsPaid", in, out, opts...) if err != nil { return nil, err @@ -1195,8 +1504,8 @@ func (c *escrowServiceClient) IsPaid(ctx context.Context, in *ContractID, opts . return out, nil } -func (c *escrowServiceClient) GetPayOutStatus(ctx context.Context, in *ContractID, opts ...grpc.CallOption) (*PayoutStatus, error) { - out := new(PayoutStatus) +func (c *escrowServiceClient) GetPayOutStatus(ctx context.Context, in *SignedContractID, opts ...grpc.CallOption) (*SignedPayoutStatus, error) { + out := new(SignedPayoutStatus) err := c.cc.Invoke(ctx, "/escrow.EscrowService/GetPayOutStatus", in, out, opts...) if err != nil { return nil, err @@ -1204,8 +1513,8 @@ func (c *escrowServiceClient) GetPayOutStatus(ctx context.Context, in *ContractI return out, nil } -func (c *escrowServiceClient) CancelContracts(ctx context.Context, in *CancelContractRequest, opts ...grpc.CallOption) (*CancelContractResult, error) { - out := new(CancelContractResult) +func (c *escrowServiceClient) CancelContracts(ctx context.Context, in *SignedCancelRequest, opts ...grpc.CallOption) (*SignedCancelContractResult, error) { + out := new(SignedCancelContractResult) err := c.cc.Invoke(ctx, "/escrow.EscrowService/CancelContracts", in, out, opts...) if err != nil { return nil, err @@ -1219,36 +1528,36 @@ type EscrowServiceServer interface { // one contract is one buyer to one seller, and is one escrow in escrow service // buyer can submit multiple contracts in one request // return same number of results as request contracts - SubmitContracts(context.Context, *EscrowContractRequest) (*EscrowContractResult, error) + SubmitContracts(context.Context, *EscrowContractRequest) (*SignedSubmitContractResult, error) // after submit contract, buyer request to pay in // escrow will transfer contract amount from buyer wallet to escrow wallet - PayIn(context.Context, *PayinRquest) (*PayinResult, error) + PayIn(context.Context, *SignedPayinRquest) (*SignedPayinResult, error) // seller use this to check if a contract is paid in - IsPaid(context.Context, *ContractID) (*PayinStatus, error) + IsPaid(context.Context, *SignedContractID) (*SignedPayinStatus, error) // check escrow pay out to seller status of a contract - GetPayOutStatus(context.Context, *ContractID) (*PayoutStatus, error) + GetPayOutStatus(context.Context, *SignedContractID) (*SignedPayoutStatus, error) // auth request to cancel the contract // escrow will cancel the left payments to seller - CancelContracts(context.Context, *CancelContractRequest) (*CancelContractResult, error) + CancelContracts(context.Context, *SignedCancelRequest) (*SignedCancelContractResult, error) } // UnimplementedEscrowServiceServer can be embedded to have forward compatible implementations. type UnimplementedEscrowServiceServer struct { } -func (*UnimplementedEscrowServiceServer) SubmitContracts(ctx context.Context, req *EscrowContractRequest) (*EscrowContractResult, error) { +func (*UnimplementedEscrowServiceServer) SubmitContracts(ctx context.Context, req *EscrowContractRequest) (*SignedSubmitContractResult, error) { return nil, status.Errorf(codes.Unimplemented, "method SubmitContracts not implemented") } -func (*UnimplementedEscrowServiceServer) PayIn(ctx context.Context, req *PayinRquest) (*PayinResult, error) { +func (*UnimplementedEscrowServiceServer) PayIn(ctx context.Context, req *SignedPayinRquest) (*SignedPayinResult, error) { return nil, status.Errorf(codes.Unimplemented, "method PayIn not implemented") } -func (*UnimplementedEscrowServiceServer) IsPaid(ctx context.Context, req *ContractID) (*PayinStatus, error) { +func (*UnimplementedEscrowServiceServer) IsPaid(ctx context.Context, req *SignedContractID) (*SignedPayinStatus, error) { return nil, status.Errorf(codes.Unimplemented, "method IsPaid not implemented") } -func (*UnimplementedEscrowServiceServer) GetPayOutStatus(ctx context.Context, req *ContractID) (*PayoutStatus, error) { +func (*UnimplementedEscrowServiceServer) GetPayOutStatus(ctx context.Context, req *SignedContractID) (*SignedPayoutStatus, error) { return nil, status.Errorf(codes.Unimplemented, "method GetPayOutStatus not implemented") } -func (*UnimplementedEscrowServiceServer) CancelContracts(ctx context.Context, req *CancelContractRequest) (*CancelContractResult, error) { +func (*UnimplementedEscrowServiceServer) CancelContracts(ctx context.Context, req *SignedCancelRequest) (*SignedCancelContractResult, error) { return nil, status.Errorf(codes.Unimplemented, "method CancelContracts not implemented") } @@ -1275,7 +1584,7 @@ func _EscrowService_SubmitContracts_Handler(srv interface{}, ctx context.Context } func _EscrowService_PayIn_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { - in := new(PayinRquest) + in := new(SignedPayinRquest) if err := dec(in); err != nil { return nil, err } @@ -1287,13 +1596,13 @@ func _EscrowService_PayIn_Handler(srv interface{}, ctx context.Context, dec func FullMethod: "/escrow.EscrowService/PayIn", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { - return srv.(EscrowServiceServer).PayIn(ctx, req.(*PayinRquest)) + return srv.(EscrowServiceServer).PayIn(ctx, req.(*SignedPayinRquest)) } return interceptor(ctx, in, info, handler) } func _EscrowService_IsPaid_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { - in := new(ContractID) + in := new(SignedContractID) if err := dec(in); err != nil { return nil, err } @@ -1305,13 +1614,13 @@ func _EscrowService_IsPaid_Handler(srv interface{}, ctx context.Context, dec fun FullMethod: "/escrow.EscrowService/IsPaid", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { - return srv.(EscrowServiceServer).IsPaid(ctx, req.(*ContractID)) + return srv.(EscrowServiceServer).IsPaid(ctx, req.(*SignedContractID)) } return interceptor(ctx, in, info, handler) } func _EscrowService_GetPayOutStatus_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { - in := new(ContractID) + in := new(SignedContractID) if err := dec(in); err != nil { return nil, err } @@ -1323,13 +1632,13 @@ func _EscrowService_GetPayOutStatus_Handler(srv interface{}, ctx context.Context FullMethod: "/escrow.EscrowService/GetPayOutStatus", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { - return srv.(EscrowServiceServer).GetPayOutStatus(ctx, req.(*ContractID)) + return srv.(EscrowServiceServer).GetPayOutStatus(ctx, req.(*SignedContractID)) } return interceptor(ctx, in, info, handler) } func _EscrowService_CancelContracts_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { - in := new(CancelContractRequest) + in := new(SignedCancelRequest) if err := dec(in); err != nil { return nil, err } @@ -1341,7 +1650,7 @@ func _EscrowService_CancelContracts_Handler(srv interface{}, ctx context.Context FullMethod: "/escrow.EscrowService/CancelContracts", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { - return srv.(EscrowServiceServer).CancelContracts(ctx, req.(*CancelContractRequest)) + return srv.(EscrowServiceServer).CancelContracts(ctx, req.(*SignedCancelRequest)) } return interceptor(ctx, in, info, handler) } diff --git a/protos/escrow/escrow.proto b/protos/escrow/escrow.proto index b4e04b0..e6b561e 100644 --- a/protos/escrow/escrow.proto +++ b/protos/escrow/escrow.proto @@ -9,6 +9,7 @@ option java_multiple_files = true; option java_outer_classname = "EscrowProto"; option java_package = "io.btfs.escrow"; +import "github.com/gogo/protobuf/gogoproto/gogo.proto"; import "google/protobuf/timestamp.proto"; service EscrowService { @@ -16,17 +17,17 @@ service EscrowService { // one contract is one buyer to one seller, and is one escrow in escrow service // buyer can submit multiple contracts in one request // return same number of results as request contracts - rpc SubmitContracts(EscrowContractRequest) returns (EscrowContractResult); + rpc SubmitContracts(EscrowContractRequest) returns (SignedSubmitContractResult); // after submit contract, buyer request to pay in // escrow will transfer contract amount from buyer wallet to escrow wallet - rpc PayIn(PayinRquest) returns (PayinResult); + rpc PayIn(SignedPayinRquest) returns (SignedPayinResult); // seller use this to check if a contract is paid in - rpc IsPaid(ContractID) returns (PayinStatus); + rpc IsPaid(SignedContractID) returns (SignedPayinStatus); // check escrow pay out to seller status of a contract - rpc GetPayOutStatus(ContractID) returns (PayoutStatus); + rpc GetPayOutStatus(SignedContractID) returns (SignedPayoutStatus); // auth request to cancel the contract // escrow will cancel the left payments to seller - rpc CancelContracts(CancelContractRequest) returns (CancelContractResult); + rpc CancelContracts(SignedCancelRequest) returns (SignedCancelContractResult); } enum TokenType { @@ -42,7 +43,11 @@ enum Schedule { message ContractID { bytes contract_id = 1; bytes address = 2; - bytes signature = 3; +} + +message SignedContractID { + ContractID data = 1; + bytes signature = 2; } message EscrowContract { @@ -78,18 +83,26 @@ message Escrow { int64 collateral_amount = 6; } -message EscrowContractResult { +message SubmitContractResult { bytes payin_id = 1; // for buyer to pay in a group of escrows repeated Escrow escrow = 2; bytes escrow_address = 3; - google.protobuf.Timestamp escrow_signed_time = 4; - bytes escrow_signature = 5; + google.protobuf.Timestamp escrow_signed_time = 4 [(gogoproto.stdtime) = true]; +} + +message SignedSubmitContractResult { + SubmitContractResult result = 1; + bytes escrow_signature = 2; } message PayinRquest { bytes payin_id = 1; bytes buyer_address = 2; - bytes buyer_signature = 3; +} + +message SignedPayinRquest { + PayinRquest request = 1; + bytes buyer_signature = 2; } message PayinResult { @@ -97,13 +110,24 @@ message PayinResult { int64 amount = 2; int64 sequence_id = 3; // ledger sequence id bytes escrow_address = 4; - google.protobuf.Timestamp escrow_signed_time = 5; - bytes escrow_signature = 6; + google.protobuf.Timestamp escrow_signed_time = 5 [(gogoproto.stdtime) = true]; +} + +message SignedPayinResult { + PayinResult result = 1; + bytes escrow_signature = 2; } message PayinStatus { bool paid = 1; int64 sequence_id = 2; + bytes escrow_address = 3; + google.protobuf.Timestamp escrow_signed_time = 4 [(gogoproto.stdtime) = true]; +} + +message SignedPayinStatus { + PayinStatus status = 1; + bytes escrow_signature = 2; } enum EscrowStatus { @@ -126,27 +150,36 @@ message PayoutStatus { int64 left_amount = 10; int32 num_left = 11; // how many times left escrow is going to pay int64 next_amount = 12; // next payout amount - google.protobuf.Timestamp last_payout_time = 13; - google.protobuf.Timestamp next_payout_time = 14; + google.protobuf.Timestamp last_payout_time = 13 [(gogoproto.stdtime) = true]; + google.protobuf.Timestamp next_payout_time = 14 [(gogoproto.stdtime) = true]; bytes escrow_address = 15; - google.protobuf.Timestamp sign_time = 16; - bytes escrow_signature = 17; + google.protobuf.Timestamp escrow_sign_time = 16 [(gogoproto.stdtime) = true]; +} + +message SignedPayoutStatus { + PayoutStatus status = 1; + bytes escrow_signature = 2; } message CancelContractRequest { repeated bytes contract_id = 1; bytes auth_address = 2; - bytes auth_signature = 3; // authority signature +} + +message SignedCancelRequest { + CancelContractRequest request = 1; + bytes auth_signature = 2; // authority signature } message CancelContractResult { - message Result { - bytes contract_id = 1; - int64 escrow_id = 2; - bool canceled = 3; - } - Result result = 1; - bytes escrow_address = 2; - google.protobuf.Timestamp escrow_signed_time = 3; - bytes escrow_signature = 4; + bytes contract_id = 1; + int64 escrow_id = 2; + bool canceled = 3; + bytes escrow_address = 4; + google.protobuf.Timestamp escrow_signed_time = 5 [(gogoproto.stdtime) = true]; +} + +message SignedCancelContractResult { + CancelContractResult result = 1; + bytes escrow_signature = 2; }