crypto

package
v0.0.18 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: May 26, 2021 License: Apache-2.0 Imports: 7 Imported by: 5

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	ErrInvalidLengthKeys        = fmt.Errorf("proto: negative length found during unmarshaling")
	ErrIntOverflowKeys          = fmt.Errorf("proto: integer overflow")
	ErrUnexpectedEndOfGroupKeys = fmt.Errorf("proto: unexpected end of group")
)
View Source
var (
	ErrInvalidLengthProof        = fmt.Errorf("proto: negative length found during unmarshaling")
	ErrIntOverflowProof          = fmt.Errorf("proto: integer overflow")
	ErrUnexpectedEndOfGroupProof = fmt.Errorf("proto: unexpected end of group")
)

Functions

This section is empty.

Types

type DominoOp

type DominoOp struct {
	Key    string `protobuf:"bytes,1,opt,name=key,proto3" json:"key,omitempty"`
	Input  string `protobuf:"bytes,2,opt,name=input,proto3" json:"input,omitempty"`
	Output string `protobuf:"bytes,3,opt,name=output,proto3" json:"output,omitempty"`
}

func (*DominoOp) Descriptor

func (*DominoOp) Descriptor() ([]byte, []int)

func (*DominoOp) GetInput

func (m *DominoOp) GetInput() string

func (*DominoOp) GetKey

func (m *DominoOp) GetKey() string

func (*DominoOp) GetOutput

func (m *DominoOp) GetOutput() string

func (*DominoOp) Marshal

func (m *DominoOp) Marshal() (dAtA []byte, err error)

func (*DominoOp) MarshalTo

func (m *DominoOp) MarshalTo(dAtA []byte) (int, error)

func (*DominoOp) MarshalToSizedBuffer

func (m *DominoOp) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*DominoOp) ProtoMessage

func (*DominoOp) ProtoMessage()

func (*DominoOp) Reset

func (m *DominoOp) Reset()

func (*DominoOp) Size

func (m *DominoOp) Size() (n int)

func (*DominoOp) String

func (m *DominoOp) String() string

func (*DominoOp) Unmarshal

func (m *DominoOp) Unmarshal(dAtA []byte) error

func (*DominoOp) XXX_DiscardUnknown

func (m *DominoOp) XXX_DiscardUnknown()

func (*DominoOp) XXX_Marshal

func (m *DominoOp) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*DominoOp) XXX_Merge

func (m *DominoOp) XXX_Merge(src proto.Message)

func (*DominoOp) XXX_Size

func (m *DominoOp) XXX_Size() int

func (*DominoOp) XXX_Unmarshal

func (m *DominoOp) XXX_Unmarshal(b []byte) error

type Proof

type Proof struct {
	Total    int64    `protobuf:"varint,1,opt,name=total,proto3" json:"total,omitempty"`
	Index    int64    `protobuf:"varint,2,opt,name=index,proto3" json:"index,omitempty"`
	LeafHash []byte   `protobuf:"bytes,3,opt,name=leaf_hash,json=leafHash,proto3" json:"leaf_hash,omitempty"`
	Aunts    [][]byte `protobuf:"bytes,4,rep,name=aunts,proto3" json:"aunts,omitempty"`
}

func (*Proof) Descriptor

func (*Proof) Descriptor() ([]byte, []int)

func (*Proof) GetAunts

func (m *Proof) GetAunts() [][]byte

func (*Proof) GetIndex

func (m *Proof) GetIndex() int64

func (*Proof) GetLeafHash

func (m *Proof) GetLeafHash() []byte

func (*Proof) GetTotal

func (m *Proof) GetTotal() int64

func (*Proof) Marshal

func (m *Proof) Marshal() (dAtA []byte, err error)

func (*Proof) MarshalTo

func (m *Proof) MarshalTo(dAtA []byte) (int, error)

func (*Proof) MarshalToSizedBuffer

func (m *Proof) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*Proof) ProtoMessage

func (*Proof) ProtoMessage()

func (*Proof) Reset

func (m *Proof) Reset()

func (*Proof) Size

func (m *Proof) Size() (n int)

func (*Proof) String

func (m *Proof) String() string

func (*Proof) Unmarshal

func (m *Proof) Unmarshal(dAtA []byte) error

func (*Proof) XXX_DiscardUnknown

func (m *Proof) XXX_DiscardUnknown()

func (*Proof) XXX_Marshal

func (m *Proof) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*Proof) XXX_Merge

func (m *Proof) XXX_Merge(src proto.Message)

func (*Proof) XXX_Size

func (m *Proof) XXX_Size() int

func (*Proof) XXX_Unmarshal

func (m *Proof) XXX_Unmarshal(b []byte) error

type ProofOp

type ProofOp struct {
	Type string `protobuf:"bytes,1,opt,name=type,proto3" json:"type,omitempty"`
	Key  []byte `protobuf:"bytes,2,opt,name=key,proto3" json:"key,omitempty"`
	Data []byte `protobuf:"bytes,3,opt,name=data,proto3" json:"data,omitempty"`
}

ProofOp defines an operation used for calculating Merkle root The data could be arbitrary format, providing nessecary data for example neighbouring node hash

func (*ProofOp) Descriptor

func (*ProofOp) Descriptor() ([]byte, []int)

func (*ProofOp) GetData

func (m *ProofOp) GetData() []byte

func (*ProofOp) GetKey

func (m *ProofOp) GetKey() []byte

func (*ProofOp) GetType

func (m *ProofOp) GetType() string

func (*ProofOp) Marshal

func (m *ProofOp) Marshal() (dAtA []byte, err error)

func (*ProofOp) MarshalTo

func (m *ProofOp) MarshalTo(dAtA []byte) (int, error)

func (*ProofOp) MarshalToSizedBuffer

func (m *ProofOp) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*ProofOp) ProtoMessage

func (*ProofOp) ProtoMessage()

func (*ProofOp) Reset

func (m *ProofOp) Reset()

func (*ProofOp) Size

func (m *ProofOp) Size() (n int)

func (*ProofOp) String

func (m *ProofOp) String() string

func (*ProofOp) Unmarshal

func (m *ProofOp) Unmarshal(dAtA []byte) error

func (*ProofOp) XXX_DiscardUnknown

func (m *ProofOp) XXX_DiscardUnknown()

func (*ProofOp) XXX_Marshal

func (m *ProofOp) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*ProofOp) XXX_Merge

func (m *ProofOp) XXX_Merge(src proto.Message)

func (*ProofOp) XXX_Size

func (m *ProofOp) XXX_Size() int

func (*ProofOp) XXX_Unmarshal

func (m *ProofOp) XXX_Unmarshal(b []byte) error

type ProofOps

type ProofOps struct {
	Ops []ProofOp `protobuf:"bytes,1,rep,name=ops,proto3" json:"ops"`
}

ProofOps is Merkle proof defined by the list of ProofOps

func (*ProofOps) Descriptor

func (*ProofOps) Descriptor() ([]byte, []int)

func (*ProofOps) GetOps

func (m *ProofOps) GetOps() []ProofOp

func (*ProofOps) Marshal

func (m *ProofOps) Marshal() (dAtA []byte, err error)

func (*ProofOps) MarshalTo

func (m *ProofOps) MarshalTo(dAtA []byte) (int, error)

func (*ProofOps) MarshalToSizedBuffer

func (m *ProofOps) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*ProofOps) ProtoMessage

func (*ProofOps) ProtoMessage()

func (*ProofOps) Reset

func (m *ProofOps) Reset()

func (*ProofOps) Size

func (m *ProofOps) Size() (n int)

func (*ProofOps) String

func (m *ProofOps) String() string

func (*ProofOps) Unmarshal

func (m *ProofOps) Unmarshal(dAtA []byte) error

func (*ProofOps) XXX_DiscardUnknown

func (m *ProofOps) XXX_DiscardUnknown()

func (*ProofOps) XXX_Marshal

func (m *ProofOps) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*ProofOps) XXX_Merge

func (m *ProofOps) XXX_Merge(src proto.Message)

func (*ProofOps) XXX_Size

func (m *ProofOps) XXX_Size() int

func (*ProofOps) XXX_Unmarshal

func (m *ProofOps) XXX_Unmarshal(b []byte) error

type PublicKey

type PublicKey struct {
	// Types that are valid to be assigned to Sum:
	//	*PublicKey_Ed25519
	//	*PublicKey_Secp256K1
	Sum isPublicKey_Sum `protobuf_oneof:"sum"`
}

PublicKey defines the keys available for use with Tendermint Validators

func (*PublicKey) Compare

func (this *PublicKey) Compare(that interface{}) int

func (*PublicKey) Descriptor

func (*PublicKey) Descriptor() ([]byte, []int)

func (*PublicKey) Equal

func (this *PublicKey) Equal(that interface{}) bool

func (*PublicKey) GetEd25519

func (m *PublicKey) GetEd25519() []byte

func (*PublicKey) GetSecp256K1

func (m *PublicKey) GetSecp256K1() []byte

func (*PublicKey) GetSum

func (m *PublicKey) GetSum() isPublicKey_Sum

func (*PublicKey) Marshal

func (m *PublicKey) Marshal() (dAtA []byte, err error)

func (*PublicKey) MarshalTo

func (m *PublicKey) MarshalTo(dAtA []byte) (int, error)

func (*PublicKey) MarshalToSizedBuffer

func (m *PublicKey) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*PublicKey) ProtoMessage

func (*PublicKey) ProtoMessage()

func (*PublicKey) Reset

func (m *PublicKey) Reset()

func (*PublicKey) Size

func (m *PublicKey) Size() (n int)

func (*PublicKey) String

func (m *PublicKey) String() string

func (*PublicKey) Unmarshal

func (m *PublicKey) Unmarshal(dAtA []byte) error

func (*PublicKey) XXX_DiscardUnknown

func (m *PublicKey) XXX_DiscardUnknown()

func (*PublicKey) XXX_Marshal

func (m *PublicKey) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*PublicKey) XXX_Merge

func (m *PublicKey) XXX_Merge(src proto.Message)

func (*PublicKey) XXX_OneofWrappers

func (*PublicKey) XXX_OneofWrappers() []interface{}

XXX_OneofWrappers is for the internal use of the proto package.

func (*PublicKey) XXX_Size

func (m *PublicKey) XXX_Size() int

func (*PublicKey) XXX_Unmarshal

func (m *PublicKey) XXX_Unmarshal(b []byte) error

type PublicKey_Ed25519

type PublicKey_Ed25519 struct {
	Ed25519 []byte `protobuf:"bytes,1,opt,name=ed25519,proto3,oneof" json:"ed25519,omitempty"`
}

func (*PublicKey_Ed25519) Compare

func (this *PublicKey_Ed25519) Compare(that interface{}) int

func (*PublicKey_Ed25519) Equal

func (this *PublicKey_Ed25519) Equal(that interface{}) bool

func (*PublicKey_Ed25519) MarshalTo

func (m *PublicKey_Ed25519) MarshalTo(dAtA []byte) (int, error)

func (*PublicKey_Ed25519) MarshalToSizedBuffer

func (m *PublicKey_Ed25519) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*PublicKey_Ed25519) Size

func (m *PublicKey_Ed25519) Size() (n int)

type PublicKey_Secp256K1

type PublicKey_Secp256K1 struct {
	Secp256K1 []byte `protobuf:"bytes,2,opt,name=secp256k1,proto3,oneof" json:"secp256k1,omitempty"`
}

func (*PublicKey_Secp256K1) Compare

func (this *PublicKey_Secp256K1) Compare(that interface{}) int

func (*PublicKey_Secp256K1) Equal

func (this *PublicKey_Secp256K1) Equal(that interface{}) bool

func (*PublicKey_Secp256K1) MarshalTo

func (m *PublicKey_Secp256K1) MarshalTo(dAtA []byte) (int, error)

func (*PublicKey_Secp256K1) MarshalToSizedBuffer

func (m *PublicKey_Secp256K1) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*PublicKey_Secp256K1) Size

func (m *PublicKey_Secp256K1) Size() (n int)

type ValueOp

type ValueOp struct {
	// Encoded in ProofOp.Key.
	Key []byte `protobuf:"bytes,1,opt,name=key,proto3" json:"key,omitempty"`
	// To encode in ProofOp.Data
	Proof *Proof `protobuf:"bytes,2,opt,name=proof,proto3" json:"proof,omitempty"`
}

func (*ValueOp) Descriptor

func (*ValueOp) Descriptor() ([]byte, []int)

func (*ValueOp) GetKey

func (m *ValueOp) GetKey() []byte

func (*ValueOp) GetProof

func (m *ValueOp) GetProof() *Proof

func (*ValueOp) Marshal

func (m *ValueOp) Marshal() (dAtA []byte, err error)

func (*ValueOp) MarshalTo

func (m *ValueOp) MarshalTo(dAtA []byte) (int, error)

func (*ValueOp) MarshalToSizedBuffer

func (m *ValueOp) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*ValueOp) ProtoMessage

func (*ValueOp) ProtoMessage()

func (*ValueOp) Reset

func (m *ValueOp) Reset()

func (*ValueOp) Size

func (m *ValueOp) Size() (n int)

func (*ValueOp) String

func (m *ValueOp) String() string

func (*ValueOp) Unmarshal

func (m *ValueOp) Unmarshal(dAtA []byte) error

func (*ValueOp) XXX_DiscardUnknown

func (m *ValueOp) XXX_DiscardUnknown()

func (*ValueOp) XXX_Marshal

func (m *ValueOp) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*ValueOp) XXX_Merge

func (m *ValueOp) XXX_Merge(src proto.Message)

func (*ValueOp) XXX_Size

func (m *ValueOp) XXX_Size() int

func (*ValueOp) XXX_Unmarshal

func (m *ValueOp) XXX_Unmarshal(b []byte) error

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL