github.com/vipernet-xyz/tm@v0.34.24/proto/tendermint/privval/types.pb.go (about)

     1  // Code generated by protoc-gen-gogo. DO NOT EDIT.
     2  // source: tendermint/privval/types.proto
     3  
     4  package privval
     5  
     6  import (
     7  	fmt "fmt"
     8  	_ "github.com/gogo/protobuf/gogoproto"
     9  	proto "github.com/gogo/protobuf/proto"
    10  	crypto "github.com/vipernet-xyz/tm/proto/tendermint/crypto"
    11  	types "github.com/vipernet-xyz/tm/proto/tendermint/types"
    12  	io "io"
    13  	math "math"
    14  	math_bits "math/bits"
    15  )
    16  
    17  // Reference imports to suppress errors if they are not otherwise used.
    18  var _ = proto.Marshal
    19  var _ = fmt.Errorf
    20  var _ = math.Inf
    21  
    22  // This is a compile-time assertion to ensure that this generated file
    23  // is compatible with the proto package it is being compiled against.
    24  // A compilation error at this line likely means your copy of the
    25  // proto package needs to be updated.
    26  const _ = proto.GoGoProtoPackageIsVersion3 // please upgrade the proto package
    27  
    28  type Errors int32
    29  
    30  const (
    31  	Errors_ERRORS_UNKNOWN             Errors = 0
    32  	Errors_ERRORS_UNEXPECTED_RESPONSE Errors = 1
    33  	Errors_ERRORS_NO_CONNECTION       Errors = 2
    34  	Errors_ERRORS_CONNECTION_TIMEOUT  Errors = 3
    35  	Errors_ERRORS_READ_TIMEOUT        Errors = 4
    36  	Errors_ERRORS_WRITE_TIMEOUT       Errors = 5
    37  )
    38  
    39  var Errors_name = map[int32]string{
    40  	0: "ERRORS_UNKNOWN",
    41  	1: "ERRORS_UNEXPECTED_RESPONSE",
    42  	2: "ERRORS_NO_CONNECTION",
    43  	3: "ERRORS_CONNECTION_TIMEOUT",
    44  	4: "ERRORS_READ_TIMEOUT",
    45  	5: "ERRORS_WRITE_TIMEOUT",
    46  }
    47  
    48  var Errors_value = map[string]int32{
    49  	"ERRORS_UNKNOWN":             0,
    50  	"ERRORS_UNEXPECTED_RESPONSE": 1,
    51  	"ERRORS_NO_CONNECTION":       2,
    52  	"ERRORS_CONNECTION_TIMEOUT":  3,
    53  	"ERRORS_READ_TIMEOUT":        4,
    54  	"ERRORS_WRITE_TIMEOUT":       5,
    55  }
    56  
    57  func (x Errors) String() string {
    58  	return proto.EnumName(Errors_name, int32(x))
    59  }
    60  
    61  func (Errors) EnumDescriptor() ([]byte, []int) {
    62  	return fileDescriptor_cb4e437a5328cf9c, []int{0}
    63  }
    64  
    65  type RemoteSignerError struct {
    66  	Code        int32  `protobuf:"varint,1,opt,name=code,proto3" json:"code,omitempty"`
    67  	Description string `protobuf:"bytes,2,opt,name=description,proto3" json:"description,omitempty"`
    68  }
    69  
    70  func (m *RemoteSignerError) Reset()         { *m = RemoteSignerError{} }
    71  func (m *RemoteSignerError) String() string { return proto.CompactTextString(m) }
    72  func (*RemoteSignerError) ProtoMessage()    {}
    73  func (*RemoteSignerError) Descriptor() ([]byte, []int) {
    74  	return fileDescriptor_cb4e437a5328cf9c, []int{0}
    75  }
    76  func (m *RemoteSignerError) XXX_Unmarshal(b []byte) error {
    77  	return m.Unmarshal(b)
    78  }
    79  func (m *RemoteSignerError) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
    80  	if deterministic {
    81  		return xxx_messageInfo_RemoteSignerError.Marshal(b, m, deterministic)
    82  	} else {
    83  		b = b[:cap(b)]
    84  		n, err := m.MarshalToSizedBuffer(b)
    85  		if err != nil {
    86  			return nil, err
    87  		}
    88  		return b[:n], nil
    89  	}
    90  }
    91  func (m *RemoteSignerError) XXX_Merge(src proto.Message) {
    92  	xxx_messageInfo_RemoteSignerError.Merge(m, src)
    93  }
    94  func (m *RemoteSignerError) XXX_Size() int {
    95  	return m.Size()
    96  }
    97  func (m *RemoteSignerError) XXX_DiscardUnknown() {
    98  	xxx_messageInfo_RemoteSignerError.DiscardUnknown(m)
    99  }
   100  
   101  var xxx_messageInfo_RemoteSignerError proto.InternalMessageInfo
   102  
   103  func (m *RemoteSignerError) GetCode() int32 {
   104  	if m != nil {
   105  		return m.Code
   106  	}
   107  	return 0
   108  }
   109  
   110  func (m *RemoteSignerError) GetDescription() string {
   111  	if m != nil {
   112  		return m.Description
   113  	}
   114  	return ""
   115  }
   116  
   117  // PubKeyRequest requests the consensus public key from the remote signer.
   118  type PubKeyRequest struct {
   119  	ChainId string `protobuf:"bytes,1,opt,name=chain_id,json=chainId,proto3" json:"chain_id,omitempty"`
   120  }
   121  
   122  func (m *PubKeyRequest) Reset()         { *m = PubKeyRequest{} }
   123  func (m *PubKeyRequest) String() string { return proto.CompactTextString(m) }
   124  func (*PubKeyRequest) ProtoMessage()    {}
   125  func (*PubKeyRequest) Descriptor() ([]byte, []int) {
   126  	return fileDescriptor_cb4e437a5328cf9c, []int{1}
   127  }
   128  func (m *PubKeyRequest) XXX_Unmarshal(b []byte) error {
   129  	return m.Unmarshal(b)
   130  }
   131  func (m *PubKeyRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
   132  	if deterministic {
   133  		return xxx_messageInfo_PubKeyRequest.Marshal(b, m, deterministic)
   134  	} else {
   135  		b = b[:cap(b)]
   136  		n, err := m.MarshalToSizedBuffer(b)
   137  		if err != nil {
   138  			return nil, err
   139  		}
   140  		return b[:n], nil
   141  	}
   142  }
   143  func (m *PubKeyRequest) XXX_Merge(src proto.Message) {
   144  	xxx_messageInfo_PubKeyRequest.Merge(m, src)
   145  }
   146  func (m *PubKeyRequest) XXX_Size() int {
   147  	return m.Size()
   148  }
   149  func (m *PubKeyRequest) XXX_DiscardUnknown() {
   150  	xxx_messageInfo_PubKeyRequest.DiscardUnknown(m)
   151  }
   152  
   153  var xxx_messageInfo_PubKeyRequest proto.InternalMessageInfo
   154  
   155  func (m *PubKeyRequest) GetChainId() string {
   156  	if m != nil {
   157  		return m.ChainId
   158  	}
   159  	return ""
   160  }
   161  
   162  // PubKeyResponse is a response message containing the public key.
   163  type PubKeyResponse struct {
   164  	PubKey crypto.PublicKey   `protobuf:"bytes,1,opt,name=pub_key,json=pubKey,proto3" json:"pub_key"`
   165  	Error  *RemoteSignerError `protobuf:"bytes,2,opt,name=error,proto3" json:"error,omitempty"`
   166  }
   167  
   168  func (m *PubKeyResponse) Reset()         { *m = PubKeyResponse{} }
   169  func (m *PubKeyResponse) String() string { return proto.CompactTextString(m) }
   170  func (*PubKeyResponse) ProtoMessage()    {}
   171  func (*PubKeyResponse) Descriptor() ([]byte, []int) {
   172  	return fileDescriptor_cb4e437a5328cf9c, []int{2}
   173  }
   174  func (m *PubKeyResponse) XXX_Unmarshal(b []byte) error {
   175  	return m.Unmarshal(b)
   176  }
   177  func (m *PubKeyResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
   178  	if deterministic {
   179  		return xxx_messageInfo_PubKeyResponse.Marshal(b, m, deterministic)
   180  	} else {
   181  		b = b[:cap(b)]
   182  		n, err := m.MarshalToSizedBuffer(b)
   183  		if err != nil {
   184  			return nil, err
   185  		}
   186  		return b[:n], nil
   187  	}
   188  }
   189  func (m *PubKeyResponse) XXX_Merge(src proto.Message) {
   190  	xxx_messageInfo_PubKeyResponse.Merge(m, src)
   191  }
   192  func (m *PubKeyResponse) XXX_Size() int {
   193  	return m.Size()
   194  }
   195  func (m *PubKeyResponse) XXX_DiscardUnknown() {
   196  	xxx_messageInfo_PubKeyResponse.DiscardUnknown(m)
   197  }
   198  
   199  var xxx_messageInfo_PubKeyResponse proto.InternalMessageInfo
   200  
   201  func (m *PubKeyResponse) GetPubKey() crypto.PublicKey {
   202  	if m != nil {
   203  		return m.PubKey
   204  	}
   205  	return crypto.PublicKey{}
   206  }
   207  
   208  func (m *PubKeyResponse) GetError() *RemoteSignerError {
   209  	if m != nil {
   210  		return m.Error
   211  	}
   212  	return nil
   213  }
   214  
   215  // SignVoteRequest is a request to sign a vote
   216  type SignVoteRequest struct {
   217  	Vote    *types.Vote `protobuf:"bytes,1,opt,name=vote,proto3" json:"vote,omitempty"`
   218  	ChainId string      `protobuf:"bytes,2,opt,name=chain_id,json=chainId,proto3" json:"chain_id,omitempty"`
   219  }
   220  
   221  func (m *SignVoteRequest) Reset()         { *m = SignVoteRequest{} }
   222  func (m *SignVoteRequest) String() string { return proto.CompactTextString(m) }
   223  func (*SignVoteRequest) ProtoMessage()    {}
   224  func (*SignVoteRequest) Descriptor() ([]byte, []int) {
   225  	return fileDescriptor_cb4e437a5328cf9c, []int{3}
   226  }
   227  func (m *SignVoteRequest) XXX_Unmarshal(b []byte) error {
   228  	return m.Unmarshal(b)
   229  }
   230  func (m *SignVoteRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
   231  	if deterministic {
   232  		return xxx_messageInfo_SignVoteRequest.Marshal(b, m, deterministic)
   233  	} else {
   234  		b = b[:cap(b)]
   235  		n, err := m.MarshalToSizedBuffer(b)
   236  		if err != nil {
   237  			return nil, err
   238  		}
   239  		return b[:n], nil
   240  	}
   241  }
   242  func (m *SignVoteRequest) XXX_Merge(src proto.Message) {
   243  	xxx_messageInfo_SignVoteRequest.Merge(m, src)
   244  }
   245  func (m *SignVoteRequest) XXX_Size() int {
   246  	return m.Size()
   247  }
   248  func (m *SignVoteRequest) XXX_DiscardUnknown() {
   249  	xxx_messageInfo_SignVoteRequest.DiscardUnknown(m)
   250  }
   251  
   252  var xxx_messageInfo_SignVoteRequest proto.InternalMessageInfo
   253  
   254  func (m *SignVoteRequest) GetVote() *types.Vote {
   255  	if m != nil {
   256  		return m.Vote
   257  	}
   258  	return nil
   259  }
   260  
   261  func (m *SignVoteRequest) GetChainId() string {
   262  	if m != nil {
   263  		return m.ChainId
   264  	}
   265  	return ""
   266  }
   267  
   268  // SignedVoteResponse is a response containing a signed vote or an error
   269  type SignedVoteResponse struct {
   270  	Vote  types.Vote         `protobuf:"bytes,1,opt,name=vote,proto3" json:"vote"`
   271  	Error *RemoteSignerError `protobuf:"bytes,2,opt,name=error,proto3" json:"error,omitempty"`
   272  }
   273  
   274  func (m *SignedVoteResponse) Reset()         { *m = SignedVoteResponse{} }
   275  func (m *SignedVoteResponse) String() string { return proto.CompactTextString(m) }
   276  func (*SignedVoteResponse) ProtoMessage()    {}
   277  func (*SignedVoteResponse) Descriptor() ([]byte, []int) {
   278  	return fileDescriptor_cb4e437a5328cf9c, []int{4}
   279  }
   280  func (m *SignedVoteResponse) XXX_Unmarshal(b []byte) error {
   281  	return m.Unmarshal(b)
   282  }
   283  func (m *SignedVoteResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
   284  	if deterministic {
   285  		return xxx_messageInfo_SignedVoteResponse.Marshal(b, m, deterministic)
   286  	} else {
   287  		b = b[:cap(b)]
   288  		n, err := m.MarshalToSizedBuffer(b)
   289  		if err != nil {
   290  			return nil, err
   291  		}
   292  		return b[:n], nil
   293  	}
   294  }
   295  func (m *SignedVoteResponse) XXX_Merge(src proto.Message) {
   296  	xxx_messageInfo_SignedVoteResponse.Merge(m, src)
   297  }
   298  func (m *SignedVoteResponse) XXX_Size() int {
   299  	return m.Size()
   300  }
   301  func (m *SignedVoteResponse) XXX_DiscardUnknown() {
   302  	xxx_messageInfo_SignedVoteResponse.DiscardUnknown(m)
   303  }
   304  
   305  var xxx_messageInfo_SignedVoteResponse proto.InternalMessageInfo
   306  
   307  func (m *SignedVoteResponse) GetVote() types.Vote {
   308  	if m != nil {
   309  		return m.Vote
   310  	}
   311  	return types.Vote{}
   312  }
   313  
   314  func (m *SignedVoteResponse) GetError() *RemoteSignerError {
   315  	if m != nil {
   316  		return m.Error
   317  	}
   318  	return nil
   319  }
   320  
   321  // SignProposalRequest is a request to sign a proposal
   322  type SignProposalRequest struct {
   323  	Proposal *types.Proposal `protobuf:"bytes,1,opt,name=proposal,proto3" json:"proposal,omitempty"`
   324  	ChainId  string          `protobuf:"bytes,2,opt,name=chain_id,json=chainId,proto3" json:"chain_id,omitempty"`
   325  }
   326  
   327  func (m *SignProposalRequest) Reset()         { *m = SignProposalRequest{} }
   328  func (m *SignProposalRequest) String() string { return proto.CompactTextString(m) }
   329  func (*SignProposalRequest) ProtoMessage()    {}
   330  func (*SignProposalRequest) Descriptor() ([]byte, []int) {
   331  	return fileDescriptor_cb4e437a5328cf9c, []int{5}
   332  }
   333  func (m *SignProposalRequest) XXX_Unmarshal(b []byte) error {
   334  	return m.Unmarshal(b)
   335  }
   336  func (m *SignProposalRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
   337  	if deterministic {
   338  		return xxx_messageInfo_SignProposalRequest.Marshal(b, m, deterministic)
   339  	} else {
   340  		b = b[:cap(b)]
   341  		n, err := m.MarshalToSizedBuffer(b)
   342  		if err != nil {
   343  			return nil, err
   344  		}
   345  		return b[:n], nil
   346  	}
   347  }
   348  func (m *SignProposalRequest) XXX_Merge(src proto.Message) {
   349  	xxx_messageInfo_SignProposalRequest.Merge(m, src)
   350  }
   351  func (m *SignProposalRequest) XXX_Size() int {
   352  	return m.Size()
   353  }
   354  func (m *SignProposalRequest) XXX_DiscardUnknown() {
   355  	xxx_messageInfo_SignProposalRequest.DiscardUnknown(m)
   356  }
   357  
   358  var xxx_messageInfo_SignProposalRequest proto.InternalMessageInfo
   359  
   360  func (m *SignProposalRequest) GetProposal() *types.Proposal {
   361  	if m != nil {
   362  		return m.Proposal
   363  	}
   364  	return nil
   365  }
   366  
   367  func (m *SignProposalRequest) GetChainId() string {
   368  	if m != nil {
   369  		return m.ChainId
   370  	}
   371  	return ""
   372  }
   373  
   374  // SignedProposalResponse is response containing a signed proposal or an error
   375  type SignedProposalResponse struct {
   376  	Proposal types.Proposal     `protobuf:"bytes,1,opt,name=proposal,proto3" json:"proposal"`
   377  	Error    *RemoteSignerError `protobuf:"bytes,2,opt,name=error,proto3" json:"error,omitempty"`
   378  }
   379  
   380  func (m *SignedProposalResponse) Reset()         { *m = SignedProposalResponse{} }
   381  func (m *SignedProposalResponse) String() string { return proto.CompactTextString(m) }
   382  func (*SignedProposalResponse) ProtoMessage()    {}
   383  func (*SignedProposalResponse) Descriptor() ([]byte, []int) {
   384  	return fileDescriptor_cb4e437a5328cf9c, []int{6}
   385  }
   386  func (m *SignedProposalResponse) XXX_Unmarshal(b []byte) error {
   387  	return m.Unmarshal(b)
   388  }
   389  func (m *SignedProposalResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
   390  	if deterministic {
   391  		return xxx_messageInfo_SignedProposalResponse.Marshal(b, m, deterministic)
   392  	} else {
   393  		b = b[:cap(b)]
   394  		n, err := m.MarshalToSizedBuffer(b)
   395  		if err != nil {
   396  			return nil, err
   397  		}
   398  		return b[:n], nil
   399  	}
   400  }
   401  func (m *SignedProposalResponse) XXX_Merge(src proto.Message) {
   402  	xxx_messageInfo_SignedProposalResponse.Merge(m, src)
   403  }
   404  func (m *SignedProposalResponse) XXX_Size() int {
   405  	return m.Size()
   406  }
   407  func (m *SignedProposalResponse) XXX_DiscardUnknown() {
   408  	xxx_messageInfo_SignedProposalResponse.DiscardUnknown(m)
   409  }
   410  
   411  var xxx_messageInfo_SignedProposalResponse proto.InternalMessageInfo
   412  
   413  func (m *SignedProposalResponse) GetProposal() types.Proposal {
   414  	if m != nil {
   415  		return m.Proposal
   416  	}
   417  	return types.Proposal{}
   418  }
   419  
   420  func (m *SignedProposalResponse) GetError() *RemoteSignerError {
   421  	if m != nil {
   422  		return m.Error
   423  	}
   424  	return nil
   425  }
   426  
   427  // PingRequest is a request to confirm that the connection is alive.
   428  type PingRequest struct {
   429  }
   430  
   431  func (m *PingRequest) Reset()         { *m = PingRequest{} }
   432  func (m *PingRequest) String() string { return proto.CompactTextString(m) }
   433  func (*PingRequest) ProtoMessage()    {}
   434  func (*PingRequest) Descriptor() ([]byte, []int) {
   435  	return fileDescriptor_cb4e437a5328cf9c, []int{7}
   436  }
   437  func (m *PingRequest) XXX_Unmarshal(b []byte) error {
   438  	return m.Unmarshal(b)
   439  }
   440  func (m *PingRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
   441  	if deterministic {
   442  		return xxx_messageInfo_PingRequest.Marshal(b, m, deterministic)
   443  	} else {
   444  		b = b[:cap(b)]
   445  		n, err := m.MarshalToSizedBuffer(b)
   446  		if err != nil {
   447  			return nil, err
   448  		}
   449  		return b[:n], nil
   450  	}
   451  }
   452  func (m *PingRequest) XXX_Merge(src proto.Message) {
   453  	xxx_messageInfo_PingRequest.Merge(m, src)
   454  }
   455  func (m *PingRequest) XXX_Size() int {
   456  	return m.Size()
   457  }
   458  func (m *PingRequest) XXX_DiscardUnknown() {
   459  	xxx_messageInfo_PingRequest.DiscardUnknown(m)
   460  }
   461  
   462  var xxx_messageInfo_PingRequest proto.InternalMessageInfo
   463  
   464  // PingResponse is a response to confirm that the connection is alive.
   465  type PingResponse struct {
   466  }
   467  
   468  func (m *PingResponse) Reset()         { *m = PingResponse{} }
   469  func (m *PingResponse) String() string { return proto.CompactTextString(m) }
   470  func (*PingResponse) ProtoMessage()    {}
   471  func (*PingResponse) Descriptor() ([]byte, []int) {
   472  	return fileDescriptor_cb4e437a5328cf9c, []int{8}
   473  }
   474  func (m *PingResponse) XXX_Unmarshal(b []byte) error {
   475  	return m.Unmarshal(b)
   476  }
   477  func (m *PingResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
   478  	if deterministic {
   479  		return xxx_messageInfo_PingResponse.Marshal(b, m, deterministic)
   480  	} else {
   481  		b = b[:cap(b)]
   482  		n, err := m.MarshalToSizedBuffer(b)
   483  		if err != nil {
   484  			return nil, err
   485  		}
   486  		return b[:n], nil
   487  	}
   488  }
   489  func (m *PingResponse) XXX_Merge(src proto.Message) {
   490  	xxx_messageInfo_PingResponse.Merge(m, src)
   491  }
   492  func (m *PingResponse) XXX_Size() int {
   493  	return m.Size()
   494  }
   495  func (m *PingResponse) XXX_DiscardUnknown() {
   496  	xxx_messageInfo_PingResponse.DiscardUnknown(m)
   497  }
   498  
   499  var xxx_messageInfo_PingResponse proto.InternalMessageInfo
   500  
   501  type Message struct {
   502  	// Types that are valid to be assigned to Sum:
   503  	//	*Message_PubKeyRequest
   504  	//	*Message_PubKeyResponse
   505  	//	*Message_SignVoteRequest
   506  	//	*Message_SignedVoteResponse
   507  	//	*Message_SignProposalRequest
   508  	//	*Message_SignedProposalResponse
   509  	//	*Message_PingRequest
   510  	//	*Message_PingResponse
   511  	Sum isMessage_Sum `protobuf_oneof:"sum"`
   512  }
   513  
   514  func (m *Message) Reset()         { *m = Message{} }
   515  func (m *Message) String() string { return proto.CompactTextString(m) }
   516  func (*Message) ProtoMessage()    {}
   517  func (*Message) Descriptor() ([]byte, []int) {
   518  	return fileDescriptor_cb4e437a5328cf9c, []int{9}
   519  }
   520  func (m *Message) XXX_Unmarshal(b []byte) error {
   521  	return m.Unmarshal(b)
   522  }
   523  func (m *Message) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
   524  	if deterministic {
   525  		return xxx_messageInfo_Message.Marshal(b, m, deterministic)
   526  	} else {
   527  		b = b[:cap(b)]
   528  		n, err := m.MarshalToSizedBuffer(b)
   529  		if err != nil {
   530  			return nil, err
   531  		}
   532  		return b[:n], nil
   533  	}
   534  }
   535  func (m *Message) XXX_Merge(src proto.Message) {
   536  	xxx_messageInfo_Message.Merge(m, src)
   537  }
   538  func (m *Message) XXX_Size() int {
   539  	return m.Size()
   540  }
   541  func (m *Message) XXX_DiscardUnknown() {
   542  	xxx_messageInfo_Message.DiscardUnknown(m)
   543  }
   544  
   545  var xxx_messageInfo_Message proto.InternalMessageInfo
   546  
   547  type isMessage_Sum interface {
   548  	isMessage_Sum()
   549  	MarshalTo([]byte) (int, error)
   550  	Size() int
   551  }
   552  
   553  type Message_PubKeyRequest struct {
   554  	PubKeyRequest *PubKeyRequest `protobuf:"bytes,1,opt,name=pub_key_request,json=pubKeyRequest,proto3,oneof" json:"pub_key_request,omitempty"`
   555  }
   556  type Message_PubKeyResponse struct {
   557  	PubKeyResponse *PubKeyResponse `protobuf:"bytes,2,opt,name=pub_key_response,json=pubKeyResponse,proto3,oneof" json:"pub_key_response,omitempty"`
   558  }
   559  type Message_SignVoteRequest struct {
   560  	SignVoteRequest *SignVoteRequest `protobuf:"bytes,3,opt,name=sign_vote_request,json=signVoteRequest,proto3,oneof" json:"sign_vote_request,omitempty"`
   561  }
   562  type Message_SignedVoteResponse struct {
   563  	SignedVoteResponse *SignedVoteResponse `protobuf:"bytes,4,opt,name=signed_vote_response,json=signedVoteResponse,proto3,oneof" json:"signed_vote_response,omitempty"`
   564  }
   565  type Message_SignProposalRequest struct {
   566  	SignProposalRequest *SignProposalRequest `protobuf:"bytes,5,opt,name=sign_proposal_request,json=signProposalRequest,proto3,oneof" json:"sign_proposal_request,omitempty"`
   567  }
   568  type Message_SignedProposalResponse struct {
   569  	SignedProposalResponse *SignedProposalResponse `protobuf:"bytes,6,opt,name=signed_proposal_response,json=signedProposalResponse,proto3,oneof" json:"signed_proposal_response,omitempty"`
   570  }
   571  type Message_PingRequest struct {
   572  	PingRequest *PingRequest `protobuf:"bytes,7,opt,name=ping_request,json=pingRequest,proto3,oneof" json:"ping_request,omitempty"`
   573  }
   574  type Message_PingResponse struct {
   575  	PingResponse *PingResponse `protobuf:"bytes,8,opt,name=ping_response,json=pingResponse,proto3,oneof" json:"ping_response,omitempty"`
   576  }
   577  
   578  func (*Message_PubKeyRequest) isMessage_Sum()          {}
   579  func (*Message_PubKeyResponse) isMessage_Sum()         {}
   580  func (*Message_SignVoteRequest) isMessage_Sum()        {}
   581  func (*Message_SignedVoteResponse) isMessage_Sum()     {}
   582  func (*Message_SignProposalRequest) isMessage_Sum()    {}
   583  func (*Message_SignedProposalResponse) isMessage_Sum() {}
   584  func (*Message_PingRequest) isMessage_Sum()            {}
   585  func (*Message_PingResponse) isMessage_Sum()           {}
   586  
   587  func (m *Message) GetSum() isMessage_Sum {
   588  	if m != nil {
   589  		return m.Sum
   590  	}
   591  	return nil
   592  }
   593  
   594  func (m *Message) GetPubKeyRequest() *PubKeyRequest {
   595  	if x, ok := m.GetSum().(*Message_PubKeyRequest); ok {
   596  		return x.PubKeyRequest
   597  	}
   598  	return nil
   599  }
   600  
   601  func (m *Message) GetPubKeyResponse() *PubKeyResponse {
   602  	if x, ok := m.GetSum().(*Message_PubKeyResponse); ok {
   603  		return x.PubKeyResponse
   604  	}
   605  	return nil
   606  }
   607  
   608  func (m *Message) GetSignVoteRequest() *SignVoteRequest {
   609  	if x, ok := m.GetSum().(*Message_SignVoteRequest); ok {
   610  		return x.SignVoteRequest
   611  	}
   612  	return nil
   613  }
   614  
   615  func (m *Message) GetSignedVoteResponse() *SignedVoteResponse {
   616  	if x, ok := m.GetSum().(*Message_SignedVoteResponse); ok {
   617  		return x.SignedVoteResponse
   618  	}
   619  	return nil
   620  }
   621  
   622  func (m *Message) GetSignProposalRequest() *SignProposalRequest {
   623  	if x, ok := m.GetSum().(*Message_SignProposalRequest); ok {
   624  		return x.SignProposalRequest
   625  	}
   626  	return nil
   627  }
   628  
   629  func (m *Message) GetSignedProposalResponse() *SignedProposalResponse {
   630  	if x, ok := m.GetSum().(*Message_SignedProposalResponse); ok {
   631  		return x.SignedProposalResponse
   632  	}
   633  	return nil
   634  }
   635  
   636  func (m *Message) GetPingRequest() *PingRequest {
   637  	if x, ok := m.GetSum().(*Message_PingRequest); ok {
   638  		return x.PingRequest
   639  	}
   640  	return nil
   641  }
   642  
   643  func (m *Message) GetPingResponse() *PingResponse {
   644  	if x, ok := m.GetSum().(*Message_PingResponse); ok {
   645  		return x.PingResponse
   646  	}
   647  	return nil
   648  }
   649  
   650  // XXX_OneofWrappers is for the internal use of the proto package.
   651  func (*Message) XXX_OneofWrappers() []interface{} {
   652  	return []interface{}{
   653  		(*Message_PubKeyRequest)(nil),
   654  		(*Message_PubKeyResponse)(nil),
   655  		(*Message_SignVoteRequest)(nil),
   656  		(*Message_SignedVoteResponse)(nil),
   657  		(*Message_SignProposalRequest)(nil),
   658  		(*Message_SignedProposalResponse)(nil),
   659  		(*Message_PingRequest)(nil),
   660  		(*Message_PingResponse)(nil),
   661  	}
   662  }
   663  
   664  func init() {
   665  	proto.RegisterEnum("tendermint.privval.Errors", Errors_name, Errors_value)
   666  	proto.RegisterType((*RemoteSignerError)(nil), "tendermint.privval.RemoteSignerError")
   667  	proto.RegisterType((*PubKeyRequest)(nil), "tendermint.privval.PubKeyRequest")
   668  	proto.RegisterType((*PubKeyResponse)(nil), "tendermint.privval.PubKeyResponse")
   669  	proto.RegisterType((*SignVoteRequest)(nil), "tendermint.privval.SignVoteRequest")
   670  	proto.RegisterType((*SignedVoteResponse)(nil), "tendermint.privval.SignedVoteResponse")
   671  	proto.RegisterType((*SignProposalRequest)(nil), "tendermint.privval.SignProposalRequest")
   672  	proto.RegisterType((*SignedProposalResponse)(nil), "tendermint.privval.SignedProposalResponse")
   673  	proto.RegisterType((*PingRequest)(nil), "tendermint.privval.PingRequest")
   674  	proto.RegisterType((*PingResponse)(nil), "tendermint.privval.PingResponse")
   675  	proto.RegisterType((*Message)(nil), "tendermint.privval.Message")
   676  }
   677  
   678  func init() { proto.RegisterFile("tendermint/privval/types.proto", fileDescriptor_cb4e437a5328cf9c) }
   679  
   680  var fileDescriptor_cb4e437a5328cf9c = []byte{
   681  	// 750 bytes of a gzipped FileDescriptorProto
   682  	0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xa4, 0x55, 0x4d, 0x4f, 0x13, 0x41,
   683  	0x18, 0xde, 0x85, 0x7e, 0xc0, 0x5b, 0x5a, 0xca, 0x80, 0x58, 0x1a, 0x5c, 0x6a, 0x8d, 0x4a, 0x7a,
   684  	0x68, 0x0d, 0x26, 0x26, 0x06, 0x2f, 0x02, 0x1b, 0xdb, 0x34, 0x6c, 0xeb, 0xb4, 0x08, 0x21, 0x31,
   685  	0x9b, 0x7e, 0x8c, 0xcb, 0x06, 0xba, 0x3b, 0xee, 0x6c, 0x49, 0x7a, 0xf6, 0xe6, 0xc9, 0xc4, 0x3f,
   686  	0xe1, 0xd9, 0x5f, 0xc1, 0x91, 0xa3, 0x27, 0x63, 0xe0, 0x8f, 0x98, 0xce, 0x4e, 0xb7, 0xdb, 0x2f,
   687  	0xa2, 0xe1, 0xb6, 0xf3, 0xbe, 0xef, 0x3c, 0x1f, 0x33, 0xcf, 0x66, 0x40, 0x71, 0x89, 0xd5, 0x26,
   688  	0x4e, 0xc7, 0xb4, 0xdc, 0x02, 0x75, 0xcc, 0xcb, 0xcb, 0xc6, 0x45, 0xc1, 0xed, 0x51, 0xc2, 0xf2,
   689  	0xd4, 0xb1, 0x5d, 0x1b, 0xa1, 0x61, 0x3f, 0x2f, 0xfa, 0xe9, 0xcd, 0xc0, 0x9e, 0x96, 0xd3, 0xa3,
   690  	0xae, 0x5d, 0x38, 0x27, 0x3d, 0xb1, 0x63, 0xa4, 0xcb, 0x91, 0x82, 0x78, 0xe9, 0x35, 0xc3, 0x36,
   691  	0x6c, 0xfe, 0x59, 0xe8, 0x7f, 0x79, 0xd5, 0x6c, 0x09, 0x56, 0x30, 0xe9, 0xd8, 0x2e, 0xa9, 0x99,
   692  	0x86, 0x45, 0x1c, 0xd5, 0x71, 0x6c, 0x07, 0x21, 0x08, 0xb5, 0xec, 0x36, 0x49, 0xc9, 0x19, 0x79,
   693  	0x3b, 0x8c, 0xf9, 0x37, 0xca, 0x40, 0xac, 0x4d, 0x58, 0xcb, 0x31, 0xa9, 0x6b, 0xda, 0x56, 0x6a,
   694  	0x2e, 0x23, 0x6f, 0x2f, 0xe2, 0x60, 0x29, 0x9b, 0x83, 0x78, 0xb5, 0xdb, 0x2c, 0x93, 0x1e, 0x26,
   695  	0x9f, 0xbb, 0x84, 0xb9, 0x68, 0x03, 0x16, 0x5a, 0x67, 0x0d, 0xd3, 0xd2, 0xcd, 0x36, 0x87, 0x5a,
   696  	0xc4, 0x51, 0xbe, 0x2e, 0xb5, 0xb3, 0x5f, 0x65, 0x48, 0x0c, 0x86, 0x19, 0xb5, 0x2d, 0x46, 0xd0,
   697  	0x2e, 0x44, 0x69, 0xb7, 0xa9, 0x9f, 0x93, 0x1e, 0x1f, 0x8e, 0xed, 0x6c, 0xe6, 0x03, 0x27, 0xe0,
   698  	0xb9, 0xcd, 0x57, 0xbb, 0xcd, 0x0b, 0xb3, 0x55, 0x26, 0xbd, 0xbd, 0xd0, 0xd5, 0xef, 0x2d, 0x09,
   699  	0x47, 0x28, 0x07, 0x41, 0xbb, 0x10, 0x26, 0x7d, 0xe9, 0x5c, 0x57, 0x6c, 0xe7, 0x69, 0x7e, 0xf2,
   700  	0xf0, 0xf2, 0x13, 0x3e, 0xb1, 0xb7, 0x27, 0x7b, 0x02, 0xcb, 0xfd, 0xea, 0x07, 0xdb, 0x25, 0x03,
   701  	0xe9, 0x39, 0x08, 0x5d, 0xda, 0x2e, 0x11, 0x4a, 0xd6, 0x83, 0x70, 0xde, 0x99, 0xf2, 0x61, 0x3e,
   702  	0x33, 0x62, 0x73, 0x6e, 0xd4, 0xe6, 0x17, 0x19, 0x10, 0x27, 0x6c, 0x7b, 0xe0, 0xc2, 0xea, 0x8b,
   703  	0x7f, 0x41, 0x17, 0x0e, 0x3d, 0x8e, 0x7b, 0xf9, 0x3b, 0x83, 0xd5, 0x7e, 0xb5, 0xea, 0xd8, 0xd4,
   704  	0x66, 0x8d, 0x8b, 0x81, 0xc7, 0x57, 0xb0, 0x40, 0x45, 0x49, 0x28, 0x49, 0x4f, 0x2a, 0xf1, 0x37,
   705  	0xf9, 0xb3, 0x77, 0xf9, 0xfd, 0x2e, 0xc3, 0xba, 0xe7, 0x77, 0x48, 0x26, 0x3c, 0xbf, 0xf9, 0x1f,
   706  	0x36, 0xe1, 0x7d, 0xc8, 0x79, 0x2f, 0xff, 0x71, 0x88, 0x55, 0x4d, 0xcb, 0x10, 0xbe, 0xb3, 0x09,
   707  	0x58, 0xf2, 0x96, 0x9e, 0xb2, 0xec, 0xcf, 0x30, 0x44, 0x0f, 0x09, 0x63, 0x0d, 0x83, 0xa0, 0x32,
   708  	0x2c, 0x8b, 0x10, 0xea, 0x8e, 0x37, 0x2e, 0xc4, 0x3e, 0x9e, 0xc6, 0x38, 0x12, 0xf7, 0xa2, 0x84,
   709  	0xe3, 0x74, 0x24, 0xff, 0x1a, 0x24, 0x87, 0x60, 0x1e, 0x99, 0xd0, 0x9f, 0xbd, 0x0b, 0xcd, 0x9b,
   710  	0x2c, 0x4a, 0x38, 0x41, 0x47, 0xff, 0x90, 0xf7, 0xb0, 0xc2, 0x4c, 0xc3, 0xd2, 0xfb, 0x89, 0xf0,
   711  	0xe5, 0xcd, 0x73, 0xc0, 0x27, 0xd3, 0x00, 0xc7, 0x42, 0x5d, 0x94, 0xf0, 0x32, 0x1b, 0xcb, 0xf9,
   712  	0x29, 0xac, 0x31, 0x7e, 0x5f, 0x03, 0x50, 0x21, 0x33, 0xc4, 0x51, 0x9f, 0xcd, 0x42, 0x1d, 0xcd,
   713  	0x73, 0x51, 0xc2, 0x88, 0x4d, 0xa6, 0xfc, 0x23, 0x3c, 0xe0, 0x72, 0x07, 0x97, 0xe8, 0x4b, 0x0e,
   714  	0x73, 0xf0, 0xe7, 0xb3, 0xc0, 0xc7, 0x72, 0x5a, 0x94, 0xf0, 0x2a, 0x9b, 0x12, 0xdf, 0x4f, 0x90,
   715  	0x12, 0xd2, 0x03, 0x04, 0x42, 0x7e, 0x84, 0x33, 0xe4, 0x66, 0xcb, 0x1f, 0x8f, 0x67, 0x51, 0xc2,
   716  	0xeb, 0x6c, 0x7a, 0x70, 0x0f, 0x60, 0x89, 0x9a, 0x96, 0xe1, 0xab, 0x8f, 0x72, 0xec, 0xad, 0xa9,
   717  	0x37, 0x38, 0x4c, 0x59, 0x51, 0xc2, 0x31, 0x3a, 0x5c, 0xa2, 0x77, 0x10, 0x17, 0x28, 0x42, 0xe2,
   718  	0x02, 0x87, 0xc9, 0xcc, 0x86, 0xf1, 0x85, 0x2d, 0xd1, 0xc0, 0x7a, 0x2f, 0x0c, 0xf3, 0xac, 0xdb,
   719  	0xc9, 0xfd, 0x90, 0x21, 0xc2, 0x43, 0xce, 0x10, 0x82, 0x84, 0x8a, 0x71, 0x05, 0xd7, 0xf4, 0x23,
   720  	0xad, 0xac, 0x55, 0x8e, 0xb5, 0xa4, 0x84, 0x14, 0x48, 0xfb, 0x35, 0xf5, 0xa4, 0xaa, 0xee, 0xd7,
   721  	0xd5, 0x03, 0x1d, 0xab, 0xb5, 0x6a, 0x45, 0xab, 0xa9, 0x49, 0x19, 0xa5, 0x60, 0x4d, 0xf4, 0xb5,
   722  	0x8a, 0xbe, 0x5f, 0xd1, 0x34, 0x75, 0xbf, 0x5e, 0xaa, 0x68, 0xc9, 0x39, 0xf4, 0x08, 0x36, 0x44,
   723  	0x67, 0x58, 0xd6, 0xeb, 0xa5, 0x43, 0xb5, 0x72, 0x54, 0x4f, 0xce, 0xa3, 0x87, 0xb0, 0x2a, 0xda,
   724  	0x58, 0x7d, 0x7b, 0xe0, 0x37, 0x42, 0x01, 0xc4, 0x63, 0x5c, 0xaa, 0xab, 0x7e, 0x27, 0xbc, 0x57,
   725  	0xbb, 0xba, 0x51, 0xe4, 0xeb, 0x1b, 0x45, 0xfe, 0x73, 0xa3, 0xc8, 0xdf, 0x6e, 0x15, 0xe9, 0xfa,
   726  	0x56, 0x91, 0x7e, 0xdd, 0x2a, 0xd2, 0xe9, 0x6b, 0xc3, 0x74, 0xcf, 0xba, 0xcd, 0x7c, 0xcb, 0xee,
   727  	0x14, 0x82, 0x6f, 0x57, 0xf0, 0x61, 0xec, 0xbf, 0x57, 0x93, 0x2f, 0x65, 0x33, 0xc2, 0x3b, 0x2f,
   728  	0xff, 0x06, 0x00, 0x00, 0xff, 0xff, 0xa5, 0x2a, 0xe5, 0x4a, 0x46, 0x07, 0x00, 0x00,
   729  }
   730  
   731  func (m *RemoteSignerError) Marshal() (dAtA []byte, err error) {
   732  	size := m.Size()
   733  	dAtA = make([]byte, size)
   734  	n, err := m.MarshalToSizedBuffer(dAtA[:size])
   735  	if err != nil {
   736  		return nil, err
   737  	}
   738  	return dAtA[:n], nil
   739  }
   740  
   741  func (m *RemoteSignerError) MarshalTo(dAtA []byte) (int, error) {
   742  	size := m.Size()
   743  	return m.MarshalToSizedBuffer(dAtA[:size])
   744  }
   745  
   746  func (m *RemoteSignerError) MarshalToSizedBuffer(dAtA []byte) (int, error) {
   747  	i := len(dAtA)
   748  	_ = i
   749  	var l int
   750  	_ = l
   751  	if len(m.Description) > 0 {
   752  		i -= len(m.Description)
   753  		copy(dAtA[i:], m.Description)
   754  		i = encodeVarintTypes(dAtA, i, uint64(len(m.Description)))
   755  		i--
   756  		dAtA[i] = 0x12
   757  	}
   758  	if m.Code != 0 {
   759  		i = encodeVarintTypes(dAtA, i, uint64(m.Code))
   760  		i--
   761  		dAtA[i] = 0x8
   762  	}
   763  	return len(dAtA) - i, nil
   764  }
   765  
   766  func (m *PubKeyRequest) Marshal() (dAtA []byte, err error) {
   767  	size := m.Size()
   768  	dAtA = make([]byte, size)
   769  	n, err := m.MarshalToSizedBuffer(dAtA[:size])
   770  	if err != nil {
   771  		return nil, err
   772  	}
   773  	return dAtA[:n], nil
   774  }
   775  
   776  func (m *PubKeyRequest) MarshalTo(dAtA []byte) (int, error) {
   777  	size := m.Size()
   778  	return m.MarshalToSizedBuffer(dAtA[:size])
   779  }
   780  
   781  func (m *PubKeyRequest) MarshalToSizedBuffer(dAtA []byte) (int, error) {
   782  	i := len(dAtA)
   783  	_ = i
   784  	var l int
   785  	_ = l
   786  	if len(m.ChainId) > 0 {
   787  		i -= len(m.ChainId)
   788  		copy(dAtA[i:], m.ChainId)
   789  		i = encodeVarintTypes(dAtA, i, uint64(len(m.ChainId)))
   790  		i--
   791  		dAtA[i] = 0xa
   792  	}
   793  	return len(dAtA) - i, nil
   794  }
   795  
   796  func (m *PubKeyResponse) Marshal() (dAtA []byte, err error) {
   797  	size := m.Size()
   798  	dAtA = make([]byte, size)
   799  	n, err := m.MarshalToSizedBuffer(dAtA[:size])
   800  	if err != nil {
   801  		return nil, err
   802  	}
   803  	return dAtA[:n], nil
   804  }
   805  
   806  func (m *PubKeyResponse) MarshalTo(dAtA []byte) (int, error) {
   807  	size := m.Size()
   808  	return m.MarshalToSizedBuffer(dAtA[:size])
   809  }
   810  
   811  func (m *PubKeyResponse) MarshalToSizedBuffer(dAtA []byte) (int, error) {
   812  	i := len(dAtA)
   813  	_ = i
   814  	var l int
   815  	_ = l
   816  	if m.Error != nil {
   817  		{
   818  			size, err := m.Error.MarshalToSizedBuffer(dAtA[:i])
   819  			if err != nil {
   820  				return 0, err
   821  			}
   822  			i -= size
   823  			i = encodeVarintTypes(dAtA, i, uint64(size))
   824  		}
   825  		i--
   826  		dAtA[i] = 0x12
   827  	}
   828  	{
   829  		size, err := m.PubKey.MarshalToSizedBuffer(dAtA[:i])
   830  		if err != nil {
   831  			return 0, err
   832  		}
   833  		i -= size
   834  		i = encodeVarintTypes(dAtA, i, uint64(size))
   835  	}
   836  	i--
   837  	dAtA[i] = 0xa
   838  	return len(dAtA) - i, nil
   839  }
   840  
   841  func (m *SignVoteRequest) Marshal() (dAtA []byte, err error) {
   842  	size := m.Size()
   843  	dAtA = make([]byte, size)
   844  	n, err := m.MarshalToSizedBuffer(dAtA[:size])
   845  	if err != nil {
   846  		return nil, err
   847  	}
   848  	return dAtA[:n], nil
   849  }
   850  
   851  func (m *SignVoteRequest) MarshalTo(dAtA []byte) (int, error) {
   852  	size := m.Size()
   853  	return m.MarshalToSizedBuffer(dAtA[:size])
   854  }
   855  
   856  func (m *SignVoteRequest) MarshalToSizedBuffer(dAtA []byte) (int, error) {
   857  	i := len(dAtA)
   858  	_ = i
   859  	var l int
   860  	_ = l
   861  	if len(m.ChainId) > 0 {
   862  		i -= len(m.ChainId)
   863  		copy(dAtA[i:], m.ChainId)
   864  		i = encodeVarintTypes(dAtA, i, uint64(len(m.ChainId)))
   865  		i--
   866  		dAtA[i] = 0x12
   867  	}
   868  	if m.Vote != nil {
   869  		{
   870  			size, err := m.Vote.MarshalToSizedBuffer(dAtA[:i])
   871  			if err != nil {
   872  				return 0, err
   873  			}
   874  			i -= size
   875  			i = encodeVarintTypes(dAtA, i, uint64(size))
   876  		}
   877  		i--
   878  		dAtA[i] = 0xa
   879  	}
   880  	return len(dAtA) - i, nil
   881  }
   882  
   883  func (m *SignedVoteResponse) Marshal() (dAtA []byte, err error) {
   884  	size := m.Size()
   885  	dAtA = make([]byte, size)
   886  	n, err := m.MarshalToSizedBuffer(dAtA[:size])
   887  	if err != nil {
   888  		return nil, err
   889  	}
   890  	return dAtA[:n], nil
   891  }
   892  
   893  func (m *SignedVoteResponse) MarshalTo(dAtA []byte) (int, error) {
   894  	size := m.Size()
   895  	return m.MarshalToSizedBuffer(dAtA[:size])
   896  }
   897  
   898  func (m *SignedVoteResponse) MarshalToSizedBuffer(dAtA []byte) (int, error) {
   899  	i := len(dAtA)
   900  	_ = i
   901  	var l int
   902  	_ = l
   903  	if m.Error != nil {
   904  		{
   905  			size, err := m.Error.MarshalToSizedBuffer(dAtA[:i])
   906  			if err != nil {
   907  				return 0, err
   908  			}
   909  			i -= size
   910  			i = encodeVarintTypes(dAtA, i, uint64(size))
   911  		}
   912  		i--
   913  		dAtA[i] = 0x12
   914  	}
   915  	{
   916  		size, err := m.Vote.MarshalToSizedBuffer(dAtA[:i])
   917  		if err != nil {
   918  			return 0, err
   919  		}
   920  		i -= size
   921  		i = encodeVarintTypes(dAtA, i, uint64(size))
   922  	}
   923  	i--
   924  	dAtA[i] = 0xa
   925  	return len(dAtA) - i, nil
   926  }
   927  
   928  func (m *SignProposalRequest) Marshal() (dAtA []byte, err error) {
   929  	size := m.Size()
   930  	dAtA = make([]byte, size)
   931  	n, err := m.MarshalToSizedBuffer(dAtA[:size])
   932  	if err != nil {
   933  		return nil, err
   934  	}
   935  	return dAtA[:n], nil
   936  }
   937  
   938  func (m *SignProposalRequest) MarshalTo(dAtA []byte) (int, error) {
   939  	size := m.Size()
   940  	return m.MarshalToSizedBuffer(dAtA[:size])
   941  }
   942  
   943  func (m *SignProposalRequest) MarshalToSizedBuffer(dAtA []byte) (int, error) {
   944  	i := len(dAtA)
   945  	_ = i
   946  	var l int
   947  	_ = l
   948  	if len(m.ChainId) > 0 {
   949  		i -= len(m.ChainId)
   950  		copy(dAtA[i:], m.ChainId)
   951  		i = encodeVarintTypes(dAtA, i, uint64(len(m.ChainId)))
   952  		i--
   953  		dAtA[i] = 0x12
   954  	}
   955  	if m.Proposal != nil {
   956  		{
   957  			size, err := m.Proposal.MarshalToSizedBuffer(dAtA[:i])
   958  			if err != nil {
   959  				return 0, err
   960  			}
   961  			i -= size
   962  			i = encodeVarintTypes(dAtA, i, uint64(size))
   963  		}
   964  		i--
   965  		dAtA[i] = 0xa
   966  	}
   967  	return len(dAtA) - i, nil
   968  }
   969  
   970  func (m *SignedProposalResponse) Marshal() (dAtA []byte, err error) {
   971  	size := m.Size()
   972  	dAtA = make([]byte, size)
   973  	n, err := m.MarshalToSizedBuffer(dAtA[:size])
   974  	if err != nil {
   975  		return nil, err
   976  	}
   977  	return dAtA[:n], nil
   978  }
   979  
   980  func (m *SignedProposalResponse) MarshalTo(dAtA []byte) (int, error) {
   981  	size := m.Size()
   982  	return m.MarshalToSizedBuffer(dAtA[:size])
   983  }
   984  
   985  func (m *SignedProposalResponse) MarshalToSizedBuffer(dAtA []byte) (int, error) {
   986  	i := len(dAtA)
   987  	_ = i
   988  	var l int
   989  	_ = l
   990  	if m.Error != nil {
   991  		{
   992  			size, err := m.Error.MarshalToSizedBuffer(dAtA[:i])
   993  			if err != nil {
   994  				return 0, err
   995  			}
   996  			i -= size
   997  			i = encodeVarintTypes(dAtA, i, uint64(size))
   998  		}
   999  		i--
  1000  		dAtA[i] = 0x12
  1001  	}
  1002  	{
  1003  		size, err := m.Proposal.MarshalToSizedBuffer(dAtA[:i])
  1004  		if err != nil {
  1005  			return 0, err
  1006  		}
  1007  		i -= size
  1008  		i = encodeVarintTypes(dAtA, i, uint64(size))
  1009  	}
  1010  	i--
  1011  	dAtA[i] = 0xa
  1012  	return len(dAtA) - i, nil
  1013  }
  1014  
  1015  func (m *PingRequest) Marshal() (dAtA []byte, err error) {
  1016  	size := m.Size()
  1017  	dAtA = make([]byte, size)
  1018  	n, err := m.MarshalToSizedBuffer(dAtA[:size])
  1019  	if err != nil {
  1020  		return nil, err
  1021  	}
  1022  	return dAtA[:n], nil
  1023  }
  1024  
  1025  func (m *PingRequest) MarshalTo(dAtA []byte) (int, error) {
  1026  	size := m.Size()
  1027  	return m.MarshalToSizedBuffer(dAtA[:size])
  1028  }
  1029  
  1030  func (m *PingRequest) MarshalToSizedBuffer(dAtA []byte) (int, error) {
  1031  	i := len(dAtA)
  1032  	_ = i
  1033  	var l int
  1034  	_ = l
  1035  	return len(dAtA) - i, nil
  1036  }
  1037  
  1038  func (m *PingResponse) Marshal() (dAtA []byte, err error) {
  1039  	size := m.Size()
  1040  	dAtA = make([]byte, size)
  1041  	n, err := m.MarshalToSizedBuffer(dAtA[:size])
  1042  	if err != nil {
  1043  		return nil, err
  1044  	}
  1045  	return dAtA[:n], nil
  1046  }
  1047  
  1048  func (m *PingResponse) MarshalTo(dAtA []byte) (int, error) {
  1049  	size := m.Size()
  1050  	return m.MarshalToSizedBuffer(dAtA[:size])
  1051  }
  1052  
  1053  func (m *PingResponse) MarshalToSizedBuffer(dAtA []byte) (int, error) {
  1054  	i := len(dAtA)
  1055  	_ = i
  1056  	var l int
  1057  	_ = l
  1058  	return len(dAtA) - i, nil
  1059  }
  1060  
  1061  func (m *Message) Marshal() (dAtA []byte, err error) {
  1062  	size := m.Size()
  1063  	dAtA = make([]byte, size)
  1064  	n, err := m.MarshalToSizedBuffer(dAtA[:size])
  1065  	if err != nil {
  1066  		return nil, err
  1067  	}
  1068  	return dAtA[:n], nil
  1069  }
  1070  
  1071  func (m *Message) MarshalTo(dAtA []byte) (int, error) {
  1072  	size := m.Size()
  1073  	return m.MarshalToSizedBuffer(dAtA[:size])
  1074  }
  1075  
  1076  func (m *Message) MarshalToSizedBuffer(dAtA []byte) (int, error) {
  1077  	i := len(dAtA)
  1078  	_ = i
  1079  	var l int
  1080  	_ = l
  1081  	if m.Sum != nil {
  1082  		{
  1083  			size := m.Sum.Size()
  1084  			i -= size
  1085  			if _, err := m.Sum.MarshalTo(dAtA[i:]); err != nil {
  1086  				return 0, err
  1087  			}
  1088  		}
  1089  	}
  1090  	return len(dAtA) - i, nil
  1091  }
  1092  
  1093  func (m *Message_PubKeyRequest) MarshalTo(dAtA []byte) (int, error) {
  1094  	size := m.Size()
  1095  	return m.MarshalToSizedBuffer(dAtA[:size])
  1096  }
  1097  
  1098  func (m *Message_PubKeyRequest) MarshalToSizedBuffer(dAtA []byte) (int, error) {
  1099  	i := len(dAtA)
  1100  	if m.PubKeyRequest != nil {
  1101  		{
  1102  			size, err := m.PubKeyRequest.MarshalToSizedBuffer(dAtA[:i])
  1103  			if err != nil {
  1104  				return 0, err
  1105  			}
  1106  			i -= size
  1107  			i = encodeVarintTypes(dAtA, i, uint64(size))
  1108  		}
  1109  		i--
  1110  		dAtA[i] = 0xa
  1111  	}
  1112  	return len(dAtA) - i, nil
  1113  }
  1114  func (m *Message_PubKeyResponse) MarshalTo(dAtA []byte) (int, error) {
  1115  	size := m.Size()
  1116  	return m.MarshalToSizedBuffer(dAtA[:size])
  1117  }
  1118  
  1119  func (m *Message_PubKeyResponse) MarshalToSizedBuffer(dAtA []byte) (int, error) {
  1120  	i := len(dAtA)
  1121  	if m.PubKeyResponse != nil {
  1122  		{
  1123  			size, err := m.PubKeyResponse.MarshalToSizedBuffer(dAtA[:i])
  1124  			if err != nil {
  1125  				return 0, err
  1126  			}
  1127  			i -= size
  1128  			i = encodeVarintTypes(dAtA, i, uint64(size))
  1129  		}
  1130  		i--
  1131  		dAtA[i] = 0x12
  1132  	}
  1133  	return len(dAtA) - i, nil
  1134  }
  1135  func (m *Message_SignVoteRequest) MarshalTo(dAtA []byte) (int, error) {
  1136  	size := m.Size()
  1137  	return m.MarshalToSizedBuffer(dAtA[:size])
  1138  }
  1139  
  1140  func (m *Message_SignVoteRequest) MarshalToSizedBuffer(dAtA []byte) (int, error) {
  1141  	i := len(dAtA)
  1142  	if m.SignVoteRequest != nil {
  1143  		{
  1144  			size, err := m.SignVoteRequest.MarshalToSizedBuffer(dAtA[:i])
  1145  			if err != nil {
  1146  				return 0, err
  1147  			}
  1148  			i -= size
  1149  			i = encodeVarintTypes(dAtA, i, uint64(size))
  1150  		}
  1151  		i--
  1152  		dAtA[i] = 0x1a
  1153  	}
  1154  	return len(dAtA) - i, nil
  1155  }
  1156  func (m *Message_SignedVoteResponse) MarshalTo(dAtA []byte) (int, error) {
  1157  	size := m.Size()
  1158  	return m.MarshalToSizedBuffer(dAtA[:size])
  1159  }
  1160  
  1161  func (m *Message_SignedVoteResponse) MarshalToSizedBuffer(dAtA []byte) (int, error) {
  1162  	i := len(dAtA)
  1163  	if m.SignedVoteResponse != nil {
  1164  		{
  1165  			size, err := m.SignedVoteResponse.MarshalToSizedBuffer(dAtA[:i])
  1166  			if err != nil {
  1167  				return 0, err
  1168  			}
  1169  			i -= size
  1170  			i = encodeVarintTypes(dAtA, i, uint64(size))
  1171  		}
  1172  		i--
  1173  		dAtA[i] = 0x22
  1174  	}
  1175  	return len(dAtA) - i, nil
  1176  }
  1177  func (m *Message_SignProposalRequest) MarshalTo(dAtA []byte) (int, error) {
  1178  	size := m.Size()
  1179  	return m.MarshalToSizedBuffer(dAtA[:size])
  1180  }
  1181  
  1182  func (m *Message_SignProposalRequest) MarshalToSizedBuffer(dAtA []byte) (int, error) {
  1183  	i := len(dAtA)
  1184  	if m.SignProposalRequest != nil {
  1185  		{
  1186  			size, err := m.SignProposalRequest.MarshalToSizedBuffer(dAtA[:i])
  1187  			if err != nil {
  1188  				return 0, err
  1189  			}
  1190  			i -= size
  1191  			i = encodeVarintTypes(dAtA, i, uint64(size))
  1192  		}
  1193  		i--
  1194  		dAtA[i] = 0x2a
  1195  	}
  1196  	return len(dAtA) - i, nil
  1197  }
  1198  func (m *Message_SignedProposalResponse) MarshalTo(dAtA []byte) (int, error) {
  1199  	size := m.Size()
  1200  	return m.MarshalToSizedBuffer(dAtA[:size])
  1201  }
  1202  
  1203  func (m *Message_SignedProposalResponse) MarshalToSizedBuffer(dAtA []byte) (int, error) {
  1204  	i := len(dAtA)
  1205  	if m.SignedProposalResponse != nil {
  1206  		{
  1207  			size, err := m.SignedProposalResponse.MarshalToSizedBuffer(dAtA[:i])
  1208  			if err != nil {
  1209  				return 0, err
  1210  			}
  1211  			i -= size
  1212  			i = encodeVarintTypes(dAtA, i, uint64(size))
  1213  		}
  1214  		i--
  1215  		dAtA[i] = 0x32
  1216  	}
  1217  	return len(dAtA) - i, nil
  1218  }
  1219  func (m *Message_PingRequest) MarshalTo(dAtA []byte) (int, error) {
  1220  	size := m.Size()
  1221  	return m.MarshalToSizedBuffer(dAtA[:size])
  1222  }
  1223  
  1224  func (m *Message_PingRequest) MarshalToSizedBuffer(dAtA []byte) (int, error) {
  1225  	i := len(dAtA)
  1226  	if m.PingRequest != nil {
  1227  		{
  1228  			size, err := m.PingRequest.MarshalToSizedBuffer(dAtA[:i])
  1229  			if err != nil {
  1230  				return 0, err
  1231  			}
  1232  			i -= size
  1233  			i = encodeVarintTypes(dAtA, i, uint64(size))
  1234  		}
  1235  		i--
  1236  		dAtA[i] = 0x3a
  1237  	}
  1238  	return len(dAtA) - i, nil
  1239  }
  1240  func (m *Message_PingResponse) MarshalTo(dAtA []byte) (int, error) {
  1241  	size := m.Size()
  1242  	return m.MarshalToSizedBuffer(dAtA[:size])
  1243  }
  1244  
  1245  func (m *Message_PingResponse) MarshalToSizedBuffer(dAtA []byte) (int, error) {
  1246  	i := len(dAtA)
  1247  	if m.PingResponse != nil {
  1248  		{
  1249  			size, err := m.PingResponse.MarshalToSizedBuffer(dAtA[:i])
  1250  			if err != nil {
  1251  				return 0, err
  1252  			}
  1253  			i -= size
  1254  			i = encodeVarintTypes(dAtA, i, uint64(size))
  1255  		}
  1256  		i--
  1257  		dAtA[i] = 0x42
  1258  	}
  1259  	return len(dAtA) - i, nil
  1260  }
  1261  func encodeVarintTypes(dAtA []byte, offset int, v uint64) int {
  1262  	offset -= sovTypes(v)
  1263  	base := offset
  1264  	for v >= 1<<7 {
  1265  		dAtA[offset] = uint8(v&0x7f | 0x80)
  1266  		v >>= 7
  1267  		offset++
  1268  	}
  1269  	dAtA[offset] = uint8(v)
  1270  	return base
  1271  }
  1272  func (m *RemoteSignerError) Size() (n int) {
  1273  	if m == nil {
  1274  		return 0
  1275  	}
  1276  	var l int
  1277  	_ = l
  1278  	if m.Code != 0 {
  1279  		n += 1 + sovTypes(uint64(m.Code))
  1280  	}
  1281  	l = len(m.Description)
  1282  	if l > 0 {
  1283  		n += 1 + l + sovTypes(uint64(l))
  1284  	}
  1285  	return n
  1286  }
  1287  
  1288  func (m *PubKeyRequest) Size() (n int) {
  1289  	if m == nil {
  1290  		return 0
  1291  	}
  1292  	var l int
  1293  	_ = l
  1294  	l = len(m.ChainId)
  1295  	if l > 0 {
  1296  		n += 1 + l + sovTypes(uint64(l))
  1297  	}
  1298  	return n
  1299  }
  1300  
  1301  func (m *PubKeyResponse) Size() (n int) {
  1302  	if m == nil {
  1303  		return 0
  1304  	}
  1305  	var l int
  1306  	_ = l
  1307  	l = m.PubKey.Size()
  1308  	n += 1 + l + sovTypes(uint64(l))
  1309  	if m.Error != nil {
  1310  		l = m.Error.Size()
  1311  		n += 1 + l + sovTypes(uint64(l))
  1312  	}
  1313  	return n
  1314  }
  1315  
  1316  func (m *SignVoteRequest) Size() (n int) {
  1317  	if m == nil {
  1318  		return 0
  1319  	}
  1320  	var l int
  1321  	_ = l
  1322  	if m.Vote != nil {
  1323  		l = m.Vote.Size()
  1324  		n += 1 + l + sovTypes(uint64(l))
  1325  	}
  1326  	l = len(m.ChainId)
  1327  	if l > 0 {
  1328  		n += 1 + l + sovTypes(uint64(l))
  1329  	}
  1330  	return n
  1331  }
  1332  
  1333  func (m *SignedVoteResponse) Size() (n int) {
  1334  	if m == nil {
  1335  		return 0
  1336  	}
  1337  	var l int
  1338  	_ = l
  1339  	l = m.Vote.Size()
  1340  	n += 1 + l + sovTypes(uint64(l))
  1341  	if m.Error != nil {
  1342  		l = m.Error.Size()
  1343  		n += 1 + l + sovTypes(uint64(l))
  1344  	}
  1345  	return n
  1346  }
  1347  
  1348  func (m *SignProposalRequest) Size() (n int) {
  1349  	if m == nil {
  1350  		return 0
  1351  	}
  1352  	var l int
  1353  	_ = l
  1354  	if m.Proposal != nil {
  1355  		l = m.Proposal.Size()
  1356  		n += 1 + l + sovTypes(uint64(l))
  1357  	}
  1358  	l = len(m.ChainId)
  1359  	if l > 0 {
  1360  		n += 1 + l + sovTypes(uint64(l))
  1361  	}
  1362  	return n
  1363  }
  1364  
  1365  func (m *SignedProposalResponse) Size() (n int) {
  1366  	if m == nil {
  1367  		return 0
  1368  	}
  1369  	var l int
  1370  	_ = l
  1371  	l = m.Proposal.Size()
  1372  	n += 1 + l + sovTypes(uint64(l))
  1373  	if m.Error != nil {
  1374  		l = m.Error.Size()
  1375  		n += 1 + l + sovTypes(uint64(l))
  1376  	}
  1377  	return n
  1378  }
  1379  
  1380  func (m *PingRequest) Size() (n int) {
  1381  	if m == nil {
  1382  		return 0
  1383  	}
  1384  	var l int
  1385  	_ = l
  1386  	return n
  1387  }
  1388  
  1389  func (m *PingResponse) Size() (n int) {
  1390  	if m == nil {
  1391  		return 0
  1392  	}
  1393  	var l int
  1394  	_ = l
  1395  	return n
  1396  }
  1397  
  1398  func (m *Message) Size() (n int) {
  1399  	if m == nil {
  1400  		return 0
  1401  	}
  1402  	var l int
  1403  	_ = l
  1404  	if m.Sum != nil {
  1405  		n += m.Sum.Size()
  1406  	}
  1407  	return n
  1408  }
  1409  
  1410  func (m *Message_PubKeyRequest) Size() (n int) {
  1411  	if m == nil {
  1412  		return 0
  1413  	}
  1414  	var l int
  1415  	_ = l
  1416  	if m.PubKeyRequest != nil {
  1417  		l = m.PubKeyRequest.Size()
  1418  		n += 1 + l + sovTypes(uint64(l))
  1419  	}
  1420  	return n
  1421  }
  1422  func (m *Message_PubKeyResponse) Size() (n int) {
  1423  	if m == nil {
  1424  		return 0
  1425  	}
  1426  	var l int
  1427  	_ = l
  1428  	if m.PubKeyResponse != nil {
  1429  		l = m.PubKeyResponse.Size()
  1430  		n += 1 + l + sovTypes(uint64(l))
  1431  	}
  1432  	return n
  1433  }
  1434  func (m *Message_SignVoteRequest) Size() (n int) {
  1435  	if m == nil {
  1436  		return 0
  1437  	}
  1438  	var l int
  1439  	_ = l
  1440  	if m.SignVoteRequest != nil {
  1441  		l = m.SignVoteRequest.Size()
  1442  		n += 1 + l + sovTypes(uint64(l))
  1443  	}
  1444  	return n
  1445  }
  1446  func (m *Message_SignedVoteResponse) Size() (n int) {
  1447  	if m == nil {
  1448  		return 0
  1449  	}
  1450  	var l int
  1451  	_ = l
  1452  	if m.SignedVoteResponse != nil {
  1453  		l = m.SignedVoteResponse.Size()
  1454  		n += 1 + l + sovTypes(uint64(l))
  1455  	}
  1456  	return n
  1457  }
  1458  func (m *Message_SignProposalRequest) Size() (n int) {
  1459  	if m == nil {
  1460  		return 0
  1461  	}
  1462  	var l int
  1463  	_ = l
  1464  	if m.SignProposalRequest != nil {
  1465  		l = m.SignProposalRequest.Size()
  1466  		n += 1 + l + sovTypes(uint64(l))
  1467  	}
  1468  	return n
  1469  }
  1470  func (m *Message_SignedProposalResponse) Size() (n int) {
  1471  	if m == nil {
  1472  		return 0
  1473  	}
  1474  	var l int
  1475  	_ = l
  1476  	if m.SignedProposalResponse != nil {
  1477  		l = m.SignedProposalResponse.Size()
  1478  		n += 1 + l + sovTypes(uint64(l))
  1479  	}
  1480  	return n
  1481  }
  1482  func (m *Message_PingRequest) Size() (n int) {
  1483  	if m == nil {
  1484  		return 0
  1485  	}
  1486  	var l int
  1487  	_ = l
  1488  	if m.PingRequest != nil {
  1489  		l = m.PingRequest.Size()
  1490  		n += 1 + l + sovTypes(uint64(l))
  1491  	}
  1492  	return n
  1493  }
  1494  func (m *Message_PingResponse) Size() (n int) {
  1495  	if m == nil {
  1496  		return 0
  1497  	}
  1498  	var l int
  1499  	_ = l
  1500  	if m.PingResponse != nil {
  1501  		l = m.PingResponse.Size()
  1502  		n += 1 + l + sovTypes(uint64(l))
  1503  	}
  1504  	return n
  1505  }
  1506  
  1507  func sovTypes(x uint64) (n int) {
  1508  	return (math_bits.Len64(x|1) + 6) / 7
  1509  }
  1510  func sozTypes(x uint64) (n int) {
  1511  	return sovTypes(uint64((x << 1) ^ uint64((int64(x) >> 63))))
  1512  }
  1513  func (m *RemoteSignerError) Unmarshal(dAtA []byte) error {
  1514  	l := len(dAtA)
  1515  	iNdEx := 0
  1516  	for iNdEx < l {
  1517  		preIndex := iNdEx
  1518  		var wire uint64
  1519  		for shift := uint(0); ; shift += 7 {
  1520  			if shift >= 64 {
  1521  				return ErrIntOverflowTypes
  1522  			}
  1523  			if iNdEx >= l {
  1524  				return io.ErrUnexpectedEOF
  1525  			}
  1526  			b := dAtA[iNdEx]
  1527  			iNdEx++
  1528  			wire |= uint64(b&0x7F) << shift
  1529  			if b < 0x80 {
  1530  				break
  1531  			}
  1532  		}
  1533  		fieldNum := int32(wire >> 3)
  1534  		wireType := int(wire & 0x7)
  1535  		if wireType == 4 {
  1536  			return fmt.Errorf("proto: RemoteSignerError: wiretype end group for non-group")
  1537  		}
  1538  		if fieldNum <= 0 {
  1539  			return fmt.Errorf("proto: RemoteSignerError: illegal tag %d (wire type %d)", fieldNum, wire)
  1540  		}
  1541  		switch fieldNum {
  1542  		case 1:
  1543  			if wireType != 0 {
  1544  				return fmt.Errorf("proto: wrong wireType = %d for field Code", wireType)
  1545  			}
  1546  			m.Code = 0
  1547  			for shift := uint(0); ; shift += 7 {
  1548  				if shift >= 64 {
  1549  					return ErrIntOverflowTypes
  1550  				}
  1551  				if iNdEx >= l {
  1552  					return io.ErrUnexpectedEOF
  1553  				}
  1554  				b := dAtA[iNdEx]
  1555  				iNdEx++
  1556  				m.Code |= int32(b&0x7F) << shift
  1557  				if b < 0x80 {
  1558  					break
  1559  				}
  1560  			}
  1561  		case 2:
  1562  			if wireType != 2 {
  1563  				return fmt.Errorf("proto: wrong wireType = %d for field Description", wireType)
  1564  			}
  1565  			var stringLen uint64
  1566  			for shift := uint(0); ; shift += 7 {
  1567  				if shift >= 64 {
  1568  					return ErrIntOverflowTypes
  1569  				}
  1570  				if iNdEx >= l {
  1571  					return io.ErrUnexpectedEOF
  1572  				}
  1573  				b := dAtA[iNdEx]
  1574  				iNdEx++
  1575  				stringLen |= uint64(b&0x7F) << shift
  1576  				if b < 0x80 {
  1577  					break
  1578  				}
  1579  			}
  1580  			intStringLen := int(stringLen)
  1581  			if intStringLen < 0 {
  1582  				return ErrInvalidLengthTypes
  1583  			}
  1584  			postIndex := iNdEx + intStringLen
  1585  			if postIndex < 0 {
  1586  				return ErrInvalidLengthTypes
  1587  			}
  1588  			if postIndex > l {
  1589  				return io.ErrUnexpectedEOF
  1590  			}
  1591  			m.Description = string(dAtA[iNdEx:postIndex])
  1592  			iNdEx = postIndex
  1593  		default:
  1594  			iNdEx = preIndex
  1595  			skippy, err := skipTypes(dAtA[iNdEx:])
  1596  			if err != nil {
  1597  				return err
  1598  			}
  1599  			if (skippy < 0) || (iNdEx+skippy) < 0 {
  1600  				return ErrInvalidLengthTypes
  1601  			}
  1602  			if (iNdEx + skippy) > l {
  1603  				return io.ErrUnexpectedEOF
  1604  			}
  1605  			iNdEx += skippy
  1606  		}
  1607  	}
  1608  
  1609  	if iNdEx > l {
  1610  		return io.ErrUnexpectedEOF
  1611  	}
  1612  	return nil
  1613  }
  1614  func (m *PubKeyRequest) Unmarshal(dAtA []byte) error {
  1615  	l := len(dAtA)
  1616  	iNdEx := 0
  1617  	for iNdEx < l {
  1618  		preIndex := iNdEx
  1619  		var wire uint64
  1620  		for shift := uint(0); ; shift += 7 {
  1621  			if shift >= 64 {
  1622  				return ErrIntOverflowTypes
  1623  			}
  1624  			if iNdEx >= l {
  1625  				return io.ErrUnexpectedEOF
  1626  			}
  1627  			b := dAtA[iNdEx]
  1628  			iNdEx++
  1629  			wire |= uint64(b&0x7F) << shift
  1630  			if b < 0x80 {
  1631  				break
  1632  			}
  1633  		}
  1634  		fieldNum := int32(wire >> 3)
  1635  		wireType := int(wire & 0x7)
  1636  		if wireType == 4 {
  1637  			return fmt.Errorf("proto: PubKeyRequest: wiretype end group for non-group")
  1638  		}
  1639  		if fieldNum <= 0 {
  1640  			return fmt.Errorf("proto: PubKeyRequest: illegal tag %d (wire type %d)", fieldNum, wire)
  1641  		}
  1642  		switch fieldNum {
  1643  		case 1:
  1644  			if wireType != 2 {
  1645  				return fmt.Errorf("proto: wrong wireType = %d for field ChainId", wireType)
  1646  			}
  1647  			var stringLen uint64
  1648  			for shift := uint(0); ; shift += 7 {
  1649  				if shift >= 64 {
  1650  					return ErrIntOverflowTypes
  1651  				}
  1652  				if iNdEx >= l {
  1653  					return io.ErrUnexpectedEOF
  1654  				}
  1655  				b := dAtA[iNdEx]
  1656  				iNdEx++
  1657  				stringLen |= uint64(b&0x7F) << shift
  1658  				if b < 0x80 {
  1659  					break
  1660  				}
  1661  			}
  1662  			intStringLen := int(stringLen)
  1663  			if intStringLen < 0 {
  1664  				return ErrInvalidLengthTypes
  1665  			}
  1666  			postIndex := iNdEx + intStringLen
  1667  			if postIndex < 0 {
  1668  				return ErrInvalidLengthTypes
  1669  			}
  1670  			if postIndex > l {
  1671  				return io.ErrUnexpectedEOF
  1672  			}
  1673  			m.ChainId = string(dAtA[iNdEx:postIndex])
  1674  			iNdEx = postIndex
  1675  		default:
  1676  			iNdEx = preIndex
  1677  			skippy, err := skipTypes(dAtA[iNdEx:])
  1678  			if err != nil {
  1679  				return err
  1680  			}
  1681  			if (skippy < 0) || (iNdEx+skippy) < 0 {
  1682  				return ErrInvalidLengthTypes
  1683  			}
  1684  			if (iNdEx + skippy) > l {
  1685  				return io.ErrUnexpectedEOF
  1686  			}
  1687  			iNdEx += skippy
  1688  		}
  1689  	}
  1690  
  1691  	if iNdEx > l {
  1692  		return io.ErrUnexpectedEOF
  1693  	}
  1694  	return nil
  1695  }
  1696  func (m *PubKeyResponse) Unmarshal(dAtA []byte) error {
  1697  	l := len(dAtA)
  1698  	iNdEx := 0
  1699  	for iNdEx < l {
  1700  		preIndex := iNdEx
  1701  		var wire uint64
  1702  		for shift := uint(0); ; shift += 7 {
  1703  			if shift >= 64 {
  1704  				return ErrIntOverflowTypes
  1705  			}
  1706  			if iNdEx >= l {
  1707  				return io.ErrUnexpectedEOF
  1708  			}
  1709  			b := dAtA[iNdEx]
  1710  			iNdEx++
  1711  			wire |= uint64(b&0x7F) << shift
  1712  			if b < 0x80 {
  1713  				break
  1714  			}
  1715  		}
  1716  		fieldNum := int32(wire >> 3)
  1717  		wireType := int(wire & 0x7)
  1718  		if wireType == 4 {
  1719  			return fmt.Errorf("proto: PubKeyResponse: wiretype end group for non-group")
  1720  		}
  1721  		if fieldNum <= 0 {
  1722  			return fmt.Errorf("proto: PubKeyResponse: illegal tag %d (wire type %d)", fieldNum, wire)
  1723  		}
  1724  		switch fieldNum {
  1725  		case 1:
  1726  			if wireType != 2 {
  1727  				return fmt.Errorf("proto: wrong wireType = %d for field PubKey", wireType)
  1728  			}
  1729  			var msglen int
  1730  			for shift := uint(0); ; shift += 7 {
  1731  				if shift >= 64 {
  1732  					return ErrIntOverflowTypes
  1733  				}
  1734  				if iNdEx >= l {
  1735  					return io.ErrUnexpectedEOF
  1736  				}
  1737  				b := dAtA[iNdEx]
  1738  				iNdEx++
  1739  				msglen |= int(b&0x7F) << shift
  1740  				if b < 0x80 {
  1741  					break
  1742  				}
  1743  			}
  1744  			if msglen < 0 {
  1745  				return ErrInvalidLengthTypes
  1746  			}
  1747  			postIndex := iNdEx + msglen
  1748  			if postIndex < 0 {
  1749  				return ErrInvalidLengthTypes
  1750  			}
  1751  			if postIndex > l {
  1752  				return io.ErrUnexpectedEOF
  1753  			}
  1754  			if err := m.PubKey.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
  1755  				return err
  1756  			}
  1757  			iNdEx = postIndex
  1758  		case 2:
  1759  			if wireType != 2 {
  1760  				return fmt.Errorf("proto: wrong wireType = %d for field Error", wireType)
  1761  			}
  1762  			var msglen int
  1763  			for shift := uint(0); ; shift += 7 {
  1764  				if shift >= 64 {
  1765  					return ErrIntOverflowTypes
  1766  				}
  1767  				if iNdEx >= l {
  1768  					return io.ErrUnexpectedEOF
  1769  				}
  1770  				b := dAtA[iNdEx]
  1771  				iNdEx++
  1772  				msglen |= int(b&0x7F) << shift
  1773  				if b < 0x80 {
  1774  					break
  1775  				}
  1776  			}
  1777  			if msglen < 0 {
  1778  				return ErrInvalidLengthTypes
  1779  			}
  1780  			postIndex := iNdEx + msglen
  1781  			if postIndex < 0 {
  1782  				return ErrInvalidLengthTypes
  1783  			}
  1784  			if postIndex > l {
  1785  				return io.ErrUnexpectedEOF
  1786  			}
  1787  			if m.Error == nil {
  1788  				m.Error = &RemoteSignerError{}
  1789  			}
  1790  			if err := m.Error.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
  1791  				return err
  1792  			}
  1793  			iNdEx = postIndex
  1794  		default:
  1795  			iNdEx = preIndex
  1796  			skippy, err := skipTypes(dAtA[iNdEx:])
  1797  			if err != nil {
  1798  				return err
  1799  			}
  1800  			if (skippy < 0) || (iNdEx+skippy) < 0 {
  1801  				return ErrInvalidLengthTypes
  1802  			}
  1803  			if (iNdEx + skippy) > l {
  1804  				return io.ErrUnexpectedEOF
  1805  			}
  1806  			iNdEx += skippy
  1807  		}
  1808  	}
  1809  
  1810  	if iNdEx > l {
  1811  		return io.ErrUnexpectedEOF
  1812  	}
  1813  	return nil
  1814  }
  1815  func (m *SignVoteRequest) Unmarshal(dAtA []byte) error {
  1816  	l := len(dAtA)
  1817  	iNdEx := 0
  1818  	for iNdEx < l {
  1819  		preIndex := iNdEx
  1820  		var wire uint64
  1821  		for shift := uint(0); ; shift += 7 {
  1822  			if shift >= 64 {
  1823  				return ErrIntOverflowTypes
  1824  			}
  1825  			if iNdEx >= l {
  1826  				return io.ErrUnexpectedEOF
  1827  			}
  1828  			b := dAtA[iNdEx]
  1829  			iNdEx++
  1830  			wire |= uint64(b&0x7F) << shift
  1831  			if b < 0x80 {
  1832  				break
  1833  			}
  1834  		}
  1835  		fieldNum := int32(wire >> 3)
  1836  		wireType := int(wire & 0x7)
  1837  		if wireType == 4 {
  1838  			return fmt.Errorf("proto: SignVoteRequest: wiretype end group for non-group")
  1839  		}
  1840  		if fieldNum <= 0 {
  1841  			return fmt.Errorf("proto: SignVoteRequest: illegal tag %d (wire type %d)", fieldNum, wire)
  1842  		}
  1843  		switch fieldNum {
  1844  		case 1:
  1845  			if wireType != 2 {
  1846  				return fmt.Errorf("proto: wrong wireType = %d for field Vote", wireType)
  1847  			}
  1848  			var msglen int
  1849  			for shift := uint(0); ; shift += 7 {
  1850  				if shift >= 64 {
  1851  					return ErrIntOverflowTypes
  1852  				}
  1853  				if iNdEx >= l {
  1854  					return io.ErrUnexpectedEOF
  1855  				}
  1856  				b := dAtA[iNdEx]
  1857  				iNdEx++
  1858  				msglen |= int(b&0x7F) << shift
  1859  				if b < 0x80 {
  1860  					break
  1861  				}
  1862  			}
  1863  			if msglen < 0 {
  1864  				return ErrInvalidLengthTypes
  1865  			}
  1866  			postIndex := iNdEx + msglen
  1867  			if postIndex < 0 {
  1868  				return ErrInvalidLengthTypes
  1869  			}
  1870  			if postIndex > l {
  1871  				return io.ErrUnexpectedEOF
  1872  			}
  1873  			if m.Vote == nil {
  1874  				m.Vote = &types.Vote{}
  1875  			}
  1876  			if err := m.Vote.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
  1877  				return err
  1878  			}
  1879  			iNdEx = postIndex
  1880  		case 2:
  1881  			if wireType != 2 {
  1882  				return fmt.Errorf("proto: wrong wireType = %d for field ChainId", wireType)
  1883  			}
  1884  			var stringLen uint64
  1885  			for shift := uint(0); ; shift += 7 {
  1886  				if shift >= 64 {
  1887  					return ErrIntOverflowTypes
  1888  				}
  1889  				if iNdEx >= l {
  1890  					return io.ErrUnexpectedEOF
  1891  				}
  1892  				b := dAtA[iNdEx]
  1893  				iNdEx++
  1894  				stringLen |= uint64(b&0x7F) << shift
  1895  				if b < 0x80 {
  1896  					break
  1897  				}
  1898  			}
  1899  			intStringLen := int(stringLen)
  1900  			if intStringLen < 0 {
  1901  				return ErrInvalidLengthTypes
  1902  			}
  1903  			postIndex := iNdEx + intStringLen
  1904  			if postIndex < 0 {
  1905  				return ErrInvalidLengthTypes
  1906  			}
  1907  			if postIndex > l {
  1908  				return io.ErrUnexpectedEOF
  1909  			}
  1910  			m.ChainId = string(dAtA[iNdEx:postIndex])
  1911  			iNdEx = postIndex
  1912  		default:
  1913  			iNdEx = preIndex
  1914  			skippy, err := skipTypes(dAtA[iNdEx:])
  1915  			if err != nil {
  1916  				return err
  1917  			}
  1918  			if (skippy < 0) || (iNdEx+skippy) < 0 {
  1919  				return ErrInvalidLengthTypes
  1920  			}
  1921  			if (iNdEx + skippy) > l {
  1922  				return io.ErrUnexpectedEOF
  1923  			}
  1924  			iNdEx += skippy
  1925  		}
  1926  	}
  1927  
  1928  	if iNdEx > l {
  1929  		return io.ErrUnexpectedEOF
  1930  	}
  1931  	return nil
  1932  }
  1933  func (m *SignedVoteResponse) Unmarshal(dAtA []byte) error {
  1934  	l := len(dAtA)
  1935  	iNdEx := 0
  1936  	for iNdEx < l {
  1937  		preIndex := iNdEx
  1938  		var wire uint64
  1939  		for shift := uint(0); ; shift += 7 {
  1940  			if shift >= 64 {
  1941  				return ErrIntOverflowTypes
  1942  			}
  1943  			if iNdEx >= l {
  1944  				return io.ErrUnexpectedEOF
  1945  			}
  1946  			b := dAtA[iNdEx]
  1947  			iNdEx++
  1948  			wire |= uint64(b&0x7F) << shift
  1949  			if b < 0x80 {
  1950  				break
  1951  			}
  1952  		}
  1953  		fieldNum := int32(wire >> 3)
  1954  		wireType := int(wire & 0x7)
  1955  		if wireType == 4 {
  1956  			return fmt.Errorf("proto: SignedVoteResponse: wiretype end group for non-group")
  1957  		}
  1958  		if fieldNum <= 0 {
  1959  			return fmt.Errorf("proto: SignedVoteResponse: illegal tag %d (wire type %d)", fieldNum, wire)
  1960  		}
  1961  		switch fieldNum {
  1962  		case 1:
  1963  			if wireType != 2 {
  1964  				return fmt.Errorf("proto: wrong wireType = %d for field Vote", wireType)
  1965  			}
  1966  			var msglen int
  1967  			for shift := uint(0); ; shift += 7 {
  1968  				if shift >= 64 {
  1969  					return ErrIntOverflowTypes
  1970  				}
  1971  				if iNdEx >= l {
  1972  					return io.ErrUnexpectedEOF
  1973  				}
  1974  				b := dAtA[iNdEx]
  1975  				iNdEx++
  1976  				msglen |= int(b&0x7F) << shift
  1977  				if b < 0x80 {
  1978  					break
  1979  				}
  1980  			}
  1981  			if msglen < 0 {
  1982  				return ErrInvalidLengthTypes
  1983  			}
  1984  			postIndex := iNdEx + msglen
  1985  			if postIndex < 0 {
  1986  				return ErrInvalidLengthTypes
  1987  			}
  1988  			if postIndex > l {
  1989  				return io.ErrUnexpectedEOF
  1990  			}
  1991  			if err := m.Vote.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
  1992  				return err
  1993  			}
  1994  			iNdEx = postIndex
  1995  		case 2:
  1996  			if wireType != 2 {
  1997  				return fmt.Errorf("proto: wrong wireType = %d for field Error", wireType)
  1998  			}
  1999  			var msglen int
  2000  			for shift := uint(0); ; shift += 7 {
  2001  				if shift >= 64 {
  2002  					return ErrIntOverflowTypes
  2003  				}
  2004  				if iNdEx >= l {
  2005  					return io.ErrUnexpectedEOF
  2006  				}
  2007  				b := dAtA[iNdEx]
  2008  				iNdEx++
  2009  				msglen |= int(b&0x7F) << shift
  2010  				if b < 0x80 {
  2011  					break
  2012  				}
  2013  			}
  2014  			if msglen < 0 {
  2015  				return ErrInvalidLengthTypes
  2016  			}
  2017  			postIndex := iNdEx + msglen
  2018  			if postIndex < 0 {
  2019  				return ErrInvalidLengthTypes
  2020  			}
  2021  			if postIndex > l {
  2022  				return io.ErrUnexpectedEOF
  2023  			}
  2024  			if m.Error == nil {
  2025  				m.Error = &RemoteSignerError{}
  2026  			}
  2027  			if err := m.Error.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
  2028  				return err
  2029  			}
  2030  			iNdEx = postIndex
  2031  		default:
  2032  			iNdEx = preIndex
  2033  			skippy, err := skipTypes(dAtA[iNdEx:])
  2034  			if err != nil {
  2035  				return err
  2036  			}
  2037  			if (skippy < 0) || (iNdEx+skippy) < 0 {
  2038  				return ErrInvalidLengthTypes
  2039  			}
  2040  			if (iNdEx + skippy) > l {
  2041  				return io.ErrUnexpectedEOF
  2042  			}
  2043  			iNdEx += skippy
  2044  		}
  2045  	}
  2046  
  2047  	if iNdEx > l {
  2048  		return io.ErrUnexpectedEOF
  2049  	}
  2050  	return nil
  2051  }
  2052  func (m *SignProposalRequest) Unmarshal(dAtA []byte) error {
  2053  	l := len(dAtA)
  2054  	iNdEx := 0
  2055  	for iNdEx < l {
  2056  		preIndex := iNdEx
  2057  		var wire uint64
  2058  		for shift := uint(0); ; shift += 7 {
  2059  			if shift >= 64 {
  2060  				return ErrIntOverflowTypes
  2061  			}
  2062  			if iNdEx >= l {
  2063  				return io.ErrUnexpectedEOF
  2064  			}
  2065  			b := dAtA[iNdEx]
  2066  			iNdEx++
  2067  			wire |= uint64(b&0x7F) << shift
  2068  			if b < 0x80 {
  2069  				break
  2070  			}
  2071  		}
  2072  		fieldNum := int32(wire >> 3)
  2073  		wireType := int(wire & 0x7)
  2074  		if wireType == 4 {
  2075  			return fmt.Errorf("proto: SignProposalRequest: wiretype end group for non-group")
  2076  		}
  2077  		if fieldNum <= 0 {
  2078  			return fmt.Errorf("proto: SignProposalRequest: illegal tag %d (wire type %d)", fieldNum, wire)
  2079  		}
  2080  		switch fieldNum {
  2081  		case 1:
  2082  			if wireType != 2 {
  2083  				return fmt.Errorf("proto: wrong wireType = %d for field Proposal", wireType)
  2084  			}
  2085  			var msglen int
  2086  			for shift := uint(0); ; shift += 7 {
  2087  				if shift >= 64 {
  2088  					return ErrIntOverflowTypes
  2089  				}
  2090  				if iNdEx >= l {
  2091  					return io.ErrUnexpectedEOF
  2092  				}
  2093  				b := dAtA[iNdEx]
  2094  				iNdEx++
  2095  				msglen |= int(b&0x7F) << shift
  2096  				if b < 0x80 {
  2097  					break
  2098  				}
  2099  			}
  2100  			if msglen < 0 {
  2101  				return ErrInvalidLengthTypes
  2102  			}
  2103  			postIndex := iNdEx + msglen
  2104  			if postIndex < 0 {
  2105  				return ErrInvalidLengthTypes
  2106  			}
  2107  			if postIndex > l {
  2108  				return io.ErrUnexpectedEOF
  2109  			}
  2110  			if m.Proposal == nil {
  2111  				m.Proposal = &types.Proposal{}
  2112  			}
  2113  			if err := m.Proposal.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
  2114  				return err
  2115  			}
  2116  			iNdEx = postIndex
  2117  		case 2:
  2118  			if wireType != 2 {
  2119  				return fmt.Errorf("proto: wrong wireType = %d for field ChainId", wireType)
  2120  			}
  2121  			var stringLen uint64
  2122  			for shift := uint(0); ; shift += 7 {
  2123  				if shift >= 64 {
  2124  					return ErrIntOverflowTypes
  2125  				}
  2126  				if iNdEx >= l {
  2127  					return io.ErrUnexpectedEOF
  2128  				}
  2129  				b := dAtA[iNdEx]
  2130  				iNdEx++
  2131  				stringLen |= uint64(b&0x7F) << shift
  2132  				if b < 0x80 {
  2133  					break
  2134  				}
  2135  			}
  2136  			intStringLen := int(stringLen)
  2137  			if intStringLen < 0 {
  2138  				return ErrInvalidLengthTypes
  2139  			}
  2140  			postIndex := iNdEx + intStringLen
  2141  			if postIndex < 0 {
  2142  				return ErrInvalidLengthTypes
  2143  			}
  2144  			if postIndex > l {
  2145  				return io.ErrUnexpectedEOF
  2146  			}
  2147  			m.ChainId = string(dAtA[iNdEx:postIndex])
  2148  			iNdEx = postIndex
  2149  		default:
  2150  			iNdEx = preIndex
  2151  			skippy, err := skipTypes(dAtA[iNdEx:])
  2152  			if err != nil {
  2153  				return err
  2154  			}
  2155  			if (skippy < 0) || (iNdEx+skippy) < 0 {
  2156  				return ErrInvalidLengthTypes
  2157  			}
  2158  			if (iNdEx + skippy) > l {
  2159  				return io.ErrUnexpectedEOF
  2160  			}
  2161  			iNdEx += skippy
  2162  		}
  2163  	}
  2164  
  2165  	if iNdEx > l {
  2166  		return io.ErrUnexpectedEOF
  2167  	}
  2168  	return nil
  2169  }
  2170  func (m *SignedProposalResponse) Unmarshal(dAtA []byte) error {
  2171  	l := len(dAtA)
  2172  	iNdEx := 0
  2173  	for iNdEx < l {
  2174  		preIndex := iNdEx
  2175  		var wire uint64
  2176  		for shift := uint(0); ; shift += 7 {
  2177  			if shift >= 64 {
  2178  				return ErrIntOverflowTypes
  2179  			}
  2180  			if iNdEx >= l {
  2181  				return io.ErrUnexpectedEOF
  2182  			}
  2183  			b := dAtA[iNdEx]
  2184  			iNdEx++
  2185  			wire |= uint64(b&0x7F) << shift
  2186  			if b < 0x80 {
  2187  				break
  2188  			}
  2189  		}
  2190  		fieldNum := int32(wire >> 3)
  2191  		wireType := int(wire & 0x7)
  2192  		if wireType == 4 {
  2193  			return fmt.Errorf("proto: SignedProposalResponse: wiretype end group for non-group")
  2194  		}
  2195  		if fieldNum <= 0 {
  2196  			return fmt.Errorf("proto: SignedProposalResponse: illegal tag %d (wire type %d)", fieldNum, wire)
  2197  		}
  2198  		switch fieldNum {
  2199  		case 1:
  2200  			if wireType != 2 {
  2201  				return fmt.Errorf("proto: wrong wireType = %d for field Proposal", wireType)
  2202  			}
  2203  			var msglen int
  2204  			for shift := uint(0); ; shift += 7 {
  2205  				if shift >= 64 {
  2206  					return ErrIntOverflowTypes
  2207  				}
  2208  				if iNdEx >= l {
  2209  					return io.ErrUnexpectedEOF
  2210  				}
  2211  				b := dAtA[iNdEx]
  2212  				iNdEx++
  2213  				msglen |= int(b&0x7F) << shift
  2214  				if b < 0x80 {
  2215  					break
  2216  				}
  2217  			}
  2218  			if msglen < 0 {
  2219  				return ErrInvalidLengthTypes
  2220  			}
  2221  			postIndex := iNdEx + msglen
  2222  			if postIndex < 0 {
  2223  				return ErrInvalidLengthTypes
  2224  			}
  2225  			if postIndex > l {
  2226  				return io.ErrUnexpectedEOF
  2227  			}
  2228  			if err := m.Proposal.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
  2229  				return err
  2230  			}
  2231  			iNdEx = postIndex
  2232  		case 2:
  2233  			if wireType != 2 {
  2234  				return fmt.Errorf("proto: wrong wireType = %d for field Error", wireType)
  2235  			}
  2236  			var msglen int
  2237  			for shift := uint(0); ; shift += 7 {
  2238  				if shift >= 64 {
  2239  					return ErrIntOverflowTypes
  2240  				}
  2241  				if iNdEx >= l {
  2242  					return io.ErrUnexpectedEOF
  2243  				}
  2244  				b := dAtA[iNdEx]
  2245  				iNdEx++
  2246  				msglen |= int(b&0x7F) << shift
  2247  				if b < 0x80 {
  2248  					break
  2249  				}
  2250  			}
  2251  			if msglen < 0 {
  2252  				return ErrInvalidLengthTypes
  2253  			}
  2254  			postIndex := iNdEx + msglen
  2255  			if postIndex < 0 {
  2256  				return ErrInvalidLengthTypes
  2257  			}
  2258  			if postIndex > l {
  2259  				return io.ErrUnexpectedEOF
  2260  			}
  2261  			if m.Error == nil {
  2262  				m.Error = &RemoteSignerError{}
  2263  			}
  2264  			if err := m.Error.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
  2265  				return err
  2266  			}
  2267  			iNdEx = postIndex
  2268  		default:
  2269  			iNdEx = preIndex
  2270  			skippy, err := skipTypes(dAtA[iNdEx:])
  2271  			if err != nil {
  2272  				return err
  2273  			}
  2274  			if (skippy < 0) || (iNdEx+skippy) < 0 {
  2275  				return ErrInvalidLengthTypes
  2276  			}
  2277  			if (iNdEx + skippy) > l {
  2278  				return io.ErrUnexpectedEOF
  2279  			}
  2280  			iNdEx += skippy
  2281  		}
  2282  	}
  2283  
  2284  	if iNdEx > l {
  2285  		return io.ErrUnexpectedEOF
  2286  	}
  2287  	return nil
  2288  }
  2289  func (m *PingRequest) Unmarshal(dAtA []byte) error {
  2290  	l := len(dAtA)
  2291  	iNdEx := 0
  2292  	for iNdEx < l {
  2293  		preIndex := iNdEx
  2294  		var wire uint64
  2295  		for shift := uint(0); ; shift += 7 {
  2296  			if shift >= 64 {
  2297  				return ErrIntOverflowTypes
  2298  			}
  2299  			if iNdEx >= l {
  2300  				return io.ErrUnexpectedEOF
  2301  			}
  2302  			b := dAtA[iNdEx]
  2303  			iNdEx++
  2304  			wire |= uint64(b&0x7F) << shift
  2305  			if b < 0x80 {
  2306  				break
  2307  			}
  2308  		}
  2309  		fieldNum := int32(wire >> 3)
  2310  		wireType := int(wire & 0x7)
  2311  		if wireType == 4 {
  2312  			return fmt.Errorf("proto: PingRequest: wiretype end group for non-group")
  2313  		}
  2314  		if fieldNum <= 0 {
  2315  			return fmt.Errorf("proto: PingRequest: illegal tag %d (wire type %d)", fieldNum, wire)
  2316  		}
  2317  		switch fieldNum {
  2318  		default:
  2319  			iNdEx = preIndex
  2320  			skippy, err := skipTypes(dAtA[iNdEx:])
  2321  			if err != nil {
  2322  				return err
  2323  			}
  2324  			if (skippy < 0) || (iNdEx+skippy) < 0 {
  2325  				return ErrInvalidLengthTypes
  2326  			}
  2327  			if (iNdEx + skippy) > l {
  2328  				return io.ErrUnexpectedEOF
  2329  			}
  2330  			iNdEx += skippy
  2331  		}
  2332  	}
  2333  
  2334  	if iNdEx > l {
  2335  		return io.ErrUnexpectedEOF
  2336  	}
  2337  	return nil
  2338  }
  2339  func (m *PingResponse) Unmarshal(dAtA []byte) error {
  2340  	l := len(dAtA)
  2341  	iNdEx := 0
  2342  	for iNdEx < l {
  2343  		preIndex := iNdEx
  2344  		var wire uint64
  2345  		for shift := uint(0); ; shift += 7 {
  2346  			if shift >= 64 {
  2347  				return ErrIntOverflowTypes
  2348  			}
  2349  			if iNdEx >= l {
  2350  				return io.ErrUnexpectedEOF
  2351  			}
  2352  			b := dAtA[iNdEx]
  2353  			iNdEx++
  2354  			wire |= uint64(b&0x7F) << shift
  2355  			if b < 0x80 {
  2356  				break
  2357  			}
  2358  		}
  2359  		fieldNum := int32(wire >> 3)
  2360  		wireType := int(wire & 0x7)
  2361  		if wireType == 4 {
  2362  			return fmt.Errorf("proto: PingResponse: wiretype end group for non-group")
  2363  		}
  2364  		if fieldNum <= 0 {
  2365  			return fmt.Errorf("proto: PingResponse: illegal tag %d (wire type %d)", fieldNum, wire)
  2366  		}
  2367  		switch fieldNum {
  2368  		default:
  2369  			iNdEx = preIndex
  2370  			skippy, err := skipTypes(dAtA[iNdEx:])
  2371  			if err != nil {
  2372  				return err
  2373  			}
  2374  			if (skippy < 0) || (iNdEx+skippy) < 0 {
  2375  				return ErrInvalidLengthTypes
  2376  			}
  2377  			if (iNdEx + skippy) > l {
  2378  				return io.ErrUnexpectedEOF
  2379  			}
  2380  			iNdEx += skippy
  2381  		}
  2382  	}
  2383  
  2384  	if iNdEx > l {
  2385  		return io.ErrUnexpectedEOF
  2386  	}
  2387  	return nil
  2388  }
  2389  func (m *Message) Unmarshal(dAtA []byte) error {
  2390  	l := len(dAtA)
  2391  	iNdEx := 0
  2392  	for iNdEx < l {
  2393  		preIndex := iNdEx
  2394  		var wire uint64
  2395  		for shift := uint(0); ; shift += 7 {
  2396  			if shift >= 64 {
  2397  				return ErrIntOverflowTypes
  2398  			}
  2399  			if iNdEx >= l {
  2400  				return io.ErrUnexpectedEOF
  2401  			}
  2402  			b := dAtA[iNdEx]
  2403  			iNdEx++
  2404  			wire |= uint64(b&0x7F) << shift
  2405  			if b < 0x80 {
  2406  				break
  2407  			}
  2408  		}
  2409  		fieldNum := int32(wire >> 3)
  2410  		wireType := int(wire & 0x7)
  2411  		if wireType == 4 {
  2412  			return fmt.Errorf("proto: Message: wiretype end group for non-group")
  2413  		}
  2414  		if fieldNum <= 0 {
  2415  			return fmt.Errorf("proto: Message: illegal tag %d (wire type %d)", fieldNum, wire)
  2416  		}
  2417  		switch fieldNum {
  2418  		case 1:
  2419  			if wireType != 2 {
  2420  				return fmt.Errorf("proto: wrong wireType = %d for field PubKeyRequest", wireType)
  2421  			}
  2422  			var msglen int
  2423  			for shift := uint(0); ; shift += 7 {
  2424  				if shift >= 64 {
  2425  					return ErrIntOverflowTypes
  2426  				}
  2427  				if iNdEx >= l {
  2428  					return io.ErrUnexpectedEOF
  2429  				}
  2430  				b := dAtA[iNdEx]
  2431  				iNdEx++
  2432  				msglen |= int(b&0x7F) << shift
  2433  				if b < 0x80 {
  2434  					break
  2435  				}
  2436  			}
  2437  			if msglen < 0 {
  2438  				return ErrInvalidLengthTypes
  2439  			}
  2440  			postIndex := iNdEx + msglen
  2441  			if postIndex < 0 {
  2442  				return ErrInvalidLengthTypes
  2443  			}
  2444  			if postIndex > l {
  2445  				return io.ErrUnexpectedEOF
  2446  			}
  2447  			v := &PubKeyRequest{}
  2448  			if err := v.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
  2449  				return err
  2450  			}
  2451  			m.Sum = &Message_PubKeyRequest{v}
  2452  			iNdEx = postIndex
  2453  		case 2:
  2454  			if wireType != 2 {
  2455  				return fmt.Errorf("proto: wrong wireType = %d for field PubKeyResponse", wireType)
  2456  			}
  2457  			var msglen int
  2458  			for shift := uint(0); ; shift += 7 {
  2459  				if shift >= 64 {
  2460  					return ErrIntOverflowTypes
  2461  				}
  2462  				if iNdEx >= l {
  2463  					return io.ErrUnexpectedEOF
  2464  				}
  2465  				b := dAtA[iNdEx]
  2466  				iNdEx++
  2467  				msglen |= int(b&0x7F) << shift
  2468  				if b < 0x80 {
  2469  					break
  2470  				}
  2471  			}
  2472  			if msglen < 0 {
  2473  				return ErrInvalidLengthTypes
  2474  			}
  2475  			postIndex := iNdEx + msglen
  2476  			if postIndex < 0 {
  2477  				return ErrInvalidLengthTypes
  2478  			}
  2479  			if postIndex > l {
  2480  				return io.ErrUnexpectedEOF
  2481  			}
  2482  			v := &PubKeyResponse{}
  2483  			if err := v.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
  2484  				return err
  2485  			}
  2486  			m.Sum = &Message_PubKeyResponse{v}
  2487  			iNdEx = postIndex
  2488  		case 3:
  2489  			if wireType != 2 {
  2490  				return fmt.Errorf("proto: wrong wireType = %d for field SignVoteRequest", wireType)
  2491  			}
  2492  			var msglen int
  2493  			for shift := uint(0); ; shift += 7 {
  2494  				if shift >= 64 {
  2495  					return ErrIntOverflowTypes
  2496  				}
  2497  				if iNdEx >= l {
  2498  					return io.ErrUnexpectedEOF
  2499  				}
  2500  				b := dAtA[iNdEx]
  2501  				iNdEx++
  2502  				msglen |= int(b&0x7F) << shift
  2503  				if b < 0x80 {
  2504  					break
  2505  				}
  2506  			}
  2507  			if msglen < 0 {
  2508  				return ErrInvalidLengthTypes
  2509  			}
  2510  			postIndex := iNdEx + msglen
  2511  			if postIndex < 0 {
  2512  				return ErrInvalidLengthTypes
  2513  			}
  2514  			if postIndex > l {
  2515  				return io.ErrUnexpectedEOF
  2516  			}
  2517  			v := &SignVoteRequest{}
  2518  			if err := v.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
  2519  				return err
  2520  			}
  2521  			m.Sum = &Message_SignVoteRequest{v}
  2522  			iNdEx = postIndex
  2523  		case 4:
  2524  			if wireType != 2 {
  2525  				return fmt.Errorf("proto: wrong wireType = %d for field SignedVoteResponse", wireType)
  2526  			}
  2527  			var msglen int
  2528  			for shift := uint(0); ; shift += 7 {
  2529  				if shift >= 64 {
  2530  					return ErrIntOverflowTypes
  2531  				}
  2532  				if iNdEx >= l {
  2533  					return io.ErrUnexpectedEOF
  2534  				}
  2535  				b := dAtA[iNdEx]
  2536  				iNdEx++
  2537  				msglen |= int(b&0x7F) << shift
  2538  				if b < 0x80 {
  2539  					break
  2540  				}
  2541  			}
  2542  			if msglen < 0 {
  2543  				return ErrInvalidLengthTypes
  2544  			}
  2545  			postIndex := iNdEx + msglen
  2546  			if postIndex < 0 {
  2547  				return ErrInvalidLengthTypes
  2548  			}
  2549  			if postIndex > l {
  2550  				return io.ErrUnexpectedEOF
  2551  			}
  2552  			v := &SignedVoteResponse{}
  2553  			if err := v.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
  2554  				return err
  2555  			}
  2556  			m.Sum = &Message_SignedVoteResponse{v}
  2557  			iNdEx = postIndex
  2558  		case 5:
  2559  			if wireType != 2 {
  2560  				return fmt.Errorf("proto: wrong wireType = %d for field SignProposalRequest", wireType)
  2561  			}
  2562  			var msglen int
  2563  			for shift := uint(0); ; shift += 7 {
  2564  				if shift >= 64 {
  2565  					return ErrIntOverflowTypes
  2566  				}
  2567  				if iNdEx >= l {
  2568  					return io.ErrUnexpectedEOF
  2569  				}
  2570  				b := dAtA[iNdEx]
  2571  				iNdEx++
  2572  				msglen |= int(b&0x7F) << shift
  2573  				if b < 0x80 {
  2574  					break
  2575  				}
  2576  			}
  2577  			if msglen < 0 {
  2578  				return ErrInvalidLengthTypes
  2579  			}
  2580  			postIndex := iNdEx + msglen
  2581  			if postIndex < 0 {
  2582  				return ErrInvalidLengthTypes
  2583  			}
  2584  			if postIndex > l {
  2585  				return io.ErrUnexpectedEOF
  2586  			}
  2587  			v := &SignProposalRequest{}
  2588  			if err := v.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
  2589  				return err
  2590  			}
  2591  			m.Sum = &Message_SignProposalRequest{v}
  2592  			iNdEx = postIndex
  2593  		case 6:
  2594  			if wireType != 2 {
  2595  				return fmt.Errorf("proto: wrong wireType = %d for field SignedProposalResponse", wireType)
  2596  			}
  2597  			var msglen int
  2598  			for shift := uint(0); ; shift += 7 {
  2599  				if shift >= 64 {
  2600  					return ErrIntOverflowTypes
  2601  				}
  2602  				if iNdEx >= l {
  2603  					return io.ErrUnexpectedEOF
  2604  				}
  2605  				b := dAtA[iNdEx]
  2606  				iNdEx++
  2607  				msglen |= int(b&0x7F) << shift
  2608  				if b < 0x80 {
  2609  					break
  2610  				}
  2611  			}
  2612  			if msglen < 0 {
  2613  				return ErrInvalidLengthTypes
  2614  			}
  2615  			postIndex := iNdEx + msglen
  2616  			if postIndex < 0 {
  2617  				return ErrInvalidLengthTypes
  2618  			}
  2619  			if postIndex > l {
  2620  				return io.ErrUnexpectedEOF
  2621  			}
  2622  			v := &SignedProposalResponse{}
  2623  			if err := v.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
  2624  				return err
  2625  			}
  2626  			m.Sum = &Message_SignedProposalResponse{v}
  2627  			iNdEx = postIndex
  2628  		case 7:
  2629  			if wireType != 2 {
  2630  				return fmt.Errorf("proto: wrong wireType = %d for field PingRequest", wireType)
  2631  			}
  2632  			var msglen int
  2633  			for shift := uint(0); ; shift += 7 {
  2634  				if shift >= 64 {
  2635  					return ErrIntOverflowTypes
  2636  				}
  2637  				if iNdEx >= l {
  2638  					return io.ErrUnexpectedEOF
  2639  				}
  2640  				b := dAtA[iNdEx]
  2641  				iNdEx++
  2642  				msglen |= int(b&0x7F) << shift
  2643  				if b < 0x80 {
  2644  					break
  2645  				}
  2646  			}
  2647  			if msglen < 0 {
  2648  				return ErrInvalidLengthTypes
  2649  			}
  2650  			postIndex := iNdEx + msglen
  2651  			if postIndex < 0 {
  2652  				return ErrInvalidLengthTypes
  2653  			}
  2654  			if postIndex > l {
  2655  				return io.ErrUnexpectedEOF
  2656  			}
  2657  			v := &PingRequest{}
  2658  			if err := v.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
  2659  				return err
  2660  			}
  2661  			m.Sum = &Message_PingRequest{v}
  2662  			iNdEx = postIndex
  2663  		case 8:
  2664  			if wireType != 2 {
  2665  				return fmt.Errorf("proto: wrong wireType = %d for field PingResponse", wireType)
  2666  			}
  2667  			var msglen int
  2668  			for shift := uint(0); ; shift += 7 {
  2669  				if shift >= 64 {
  2670  					return ErrIntOverflowTypes
  2671  				}
  2672  				if iNdEx >= l {
  2673  					return io.ErrUnexpectedEOF
  2674  				}
  2675  				b := dAtA[iNdEx]
  2676  				iNdEx++
  2677  				msglen |= int(b&0x7F) << shift
  2678  				if b < 0x80 {
  2679  					break
  2680  				}
  2681  			}
  2682  			if msglen < 0 {
  2683  				return ErrInvalidLengthTypes
  2684  			}
  2685  			postIndex := iNdEx + msglen
  2686  			if postIndex < 0 {
  2687  				return ErrInvalidLengthTypes
  2688  			}
  2689  			if postIndex > l {
  2690  				return io.ErrUnexpectedEOF
  2691  			}
  2692  			v := &PingResponse{}
  2693  			if err := v.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
  2694  				return err
  2695  			}
  2696  			m.Sum = &Message_PingResponse{v}
  2697  			iNdEx = postIndex
  2698  		default:
  2699  			iNdEx = preIndex
  2700  			skippy, err := skipTypes(dAtA[iNdEx:])
  2701  			if err != nil {
  2702  				return err
  2703  			}
  2704  			if (skippy < 0) || (iNdEx+skippy) < 0 {
  2705  				return ErrInvalidLengthTypes
  2706  			}
  2707  			if (iNdEx + skippy) > l {
  2708  				return io.ErrUnexpectedEOF
  2709  			}
  2710  			iNdEx += skippy
  2711  		}
  2712  	}
  2713  
  2714  	if iNdEx > l {
  2715  		return io.ErrUnexpectedEOF
  2716  	}
  2717  	return nil
  2718  }
  2719  func skipTypes(dAtA []byte) (n int, err error) {
  2720  	l := len(dAtA)
  2721  	iNdEx := 0
  2722  	depth := 0
  2723  	for iNdEx < l {
  2724  		var wire uint64
  2725  		for shift := uint(0); ; shift += 7 {
  2726  			if shift >= 64 {
  2727  				return 0, ErrIntOverflowTypes
  2728  			}
  2729  			if iNdEx >= l {
  2730  				return 0, io.ErrUnexpectedEOF
  2731  			}
  2732  			b := dAtA[iNdEx]
  2733  			iNdEx++
  2734  			wire |= (uint64(b) & 0x7F) << shift
  2735  			if b < 0x80 {
  2736  				break
  2737  			}
  2738  		}
  2739  		wireType := int(wire & 0x7)
  2740  		switch wireType {
  2741  		case 0:
  2742  			for shift := uint(0); ; shift += 7 {
  2743  				if shift >= 64 {
  2744  					return 0, ErrIntOverflowTypes
  2745  				}
  2746  				if iNdEx >= l {
  2747  					return 0, io.ErrUnexpectedEOF
  2748  				}
  2749  				iNdEx++
  2750  				if dAtA[iNdEx-1] < 0x80 {
  2751  					break
  2752  				}
  2753  			}
  2754  		case 1:
  2755  			iNdEx += 8
  2756  		case 2:
  2757  			var length int
  2758  			for shift := uint(0); ; shift += 7 {
  2759  				if shift >= 64 {
  2760  					return 0, ErrIntOverflowTypes
  2761  				}
  2762  				if iNdEx >= l {
  2763  					return 0, io.ErrUnexpectedEOF
  2764  				}
  2765  				b := dAtA[iNdEx]
  2766  				iNdEx++
  2767  				length |= (int(b) & 0x7F) << shift
  2768  				if b < 0x80 {
  2769  					break
  2770  				}
  2771  			}
  2772  			if length < 0 {
  2773  				return 0, ErrInvalidLengthTypes
  2774  			}
  2775  			iNdEx += length
  2776  		case 3:
  2777  			depth++
  2778  		case 4:
  2779  			if depth == 0 {
  2780  				return 0, ErrUnexpectedEndOfGroupTypes
  2781  			}
  2782  			depth--
  2783  		case 5:
  2784  			iNdEx += 4
  2785  		default:
  2786  			return 0, fmt.Errorf("proto: illegal wireType %d", wireType)
  2787  		}
  2788  		if iNdEx < 0 {
  2789  			return 0, ErrInvalidLengthTypes
  2790  		}
  2791  		if depth == 0 {
  2792  			return iNdEx, nil
  2793  		}
  2794  	}
  2795  	return 0, io.ErrUnexpectedEOF
  2796  }
  2797  
  2798  var (
  2799  	ErrInvalidLengthTypes        = fmt.Errorf("proto: negative length found during unmarshaling")
  2800  	ErrIntOverflowTypes          = fmt.Errorf("proto: integer overflow")
  2801  	ErrUnexpectedEndOfGroupTypes = fmt.Errorf("proto: unexpected end of group")
  2802  )