exported

package
v0.19.3 Latest Latest
Warning

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

Go to latest
Published: Jun 7, 2022 License: Apache-2.0 Imports: 18 Imported by: 0

Documentation

Index

Constants

View Source
const (
	KeyIDLengthMin = 4
	KeyIDLengthMax = 256
)

key id length range bounds dictated by tofnd

Variables

View Source
var (
	ErrInvalidLengthTypes        = fmt.Errorf("proto: negative length found during unmarshaling")
	ErrIntOverflowTypes          = fmt.Errorf("proto: integer overflow")
	ErrUnexpectedEndOfGroupTypes = fmt.Errorf("proto: unexpected end of group")
)
View Source
var AckType_name = map[int32]string{
	0: "ACK_TYPE_UNSPECIFIED",
	1: "ACK_TYPE_KEYGEN",
	2: "ACK_TYPE_SIGN",
}
View Source
var AckType_value = map[string]int32{
	"ACK_TYPE_UNSPECIFIED": 0,
	"ACK_TYPE_KEYGEN":      1,
	"ACK_TYPE_SIGN":        2,
}
View Source
var KeyRole_name = map[int32]string{
	0: "KEY_ROLE_UNSPECIFIED",
	1: "KEY_ROLE_MASTER_KEY",
	2: "KEY_ROLE_SECONDARY_KEY",
	3: "KEY_ROLE_EXTERNAL_KEY",
}
View Source
var KeyRole_value = map[string]int32{
	"KEY_ROLE_UNSPECIFIED":   0,
	"KEY_ROLE_MASTER_KEY":    1,
	"KEY_ROLE_SECONDARY_KEY": 2,
	"KEY_ROLE_EXTERNAL_KEY":  3,
}
View Source
var KeyShareDistributionPolicy_name = map[int32]string{
	0: "KEY_SHARE_DISTRIBUTION_POLICY_UNSPECIFIED",
	1: "KEY_SHARE_DISTRIBUTION_POLICY_WEIGHTED_BY_STAKE",
	2: "KEY_SHARE_DISTRIBUTION_POLICY_ONE_PER_VALIDATOR",
}
View Source
var KeyShareDistributionPolicy_value = map[string]int32{
	"KEY_SHARE_DISTRIBUTION_POLICY_UNSPECIFIED":       0,
	"KEY_SHARE_DISTRIBUTION_POLICY_WEIGHTED_BY_STAKE": 1,
	"KEY_SHARE_DISTRIBUTION_POLICY_ONE_PER_VALIDATOR": 2,
}
View Source
var KeyType_name = map[int32]string{
	0: "KEY_TYPE_UNSPECIFIED",
	1: "KEY_TYPE_NONE",
	2: "KEY_TYPE_THRESHOLD",
	3: "KEY_TYPE_MULTISIG",
}
View Source
var KeyType_value = map[string]int32{
	"KEY_TYPE_UNSPECIFIED": 0,
	"KEY_TYPE_NONE":        1,
	"KEY_TYPE_THRESHOLD":   2,
	"KEY_TYPE_MULTISIG":    3,
}
View Source
var SigStatus_name = map[int32]string{
	0: "SIG_STATUS_UNSPECIFIED",
	1: "SIG_STATUS_QUEUED",
	2: "SIG_STATUS_SIGNING",
	3: "SIG_STATUS_SIGNED",
	4: "SIG_STATUS_ABORTED",
	5: "SIG_STATUS_INVALID",
}
View Source
var SigStatus_value = map[string]int32{
	"SIG_STATUS_UNSPECIFIED": 0,
	"SIG_STATUS_QUEUED":      1,
	"SIG_STATUS_SIGNING":     2,
	"SIG_STATUS_SIGNED":      3,
	"SIG_STATUS_ABORTED":     4,
	"SIG_STATUS_INVALID":     5,
}

Functions

func ComputeAbsCorruptionThreshold

func ComputeAbsCorruptionThreshold(safetyThreshold utils.Threshold, totalShareCount sdk.Int) int64

ComputeAbsCorruptionThreshold returns absolute corruption threshold to be used by tss. (threshold + 1) shares are required to sign

func KeyIDsToStrings

func KeyIDsToStrings(keyIDs []KeyID) []string

KeyIDsToStrings converts a slice of type KeyID to a slice of strings

Types

type AckType

type AckType int32
const (
	AckType_Unspecified AckType = 0
	AckType_Keygen      AckType = 1
	AckType_Sign        AckType = 2
)

func (AckType) EnumDescriptor

func (AckType) EnumDescriptor() ([]byte, []int)

func (AckType) String

func (x AckType) String() string

type Handler

type Handler func(ctx sdk.Context, info SignInfo) error

Handler defines a function that handles a signature after it has been generated and voted on

type Key

type Key struct {
	ID   KeyID   `protobuf:"bytes,1,opt,name=id,proto3,casttype=KeyID" json:"id,omitempty"`
	Role KeyRole `protobuf:"varint,2,opt,name=role,proto3,enum=axelar.tss.exported.v1beta1.KeyRole" json:"role,omitempty"`
	Type KeyType `protobuf:"varint,3,opt,name=type,proto3,enum=axelar.tss.exported.v1beta1.KeyType" json:"type,omitempty"`
	// Types that are valid to be assigned to PublicKey:
	//	*Key_ECDSAKey_
	//	*Key_MultisigKey_
	PublicKey       isKey_PublicKey `protobuf_oneof:"public_key"`
	RotatedAt       *time.Time      `protobuf:"bytes,6,opt,name=rotated_at,json=rotatedAt,proto3,stdtime" json:"rotated_at,omitempty"`
	RotationCount   int64           `protobuf:"varint,7,opt,name=rotation_count,json=rotationCount,proto3" json:"rotation_count,omitempty"`
	Chain           string          `protobuf:"bytes,8,opt,name=chain,proto3" json:"chain,omitempty"`
	SnapshotCounter int64           `protobuf:"varint,9,opt,name=snapshot_counter,json=snapshotCounter,proto3" json:"snapshot_counter,omitempty"`
}

func (*Key) Descriptor

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

func (*Key) GetChain added in v0.9.0

func (m *Key) GetChain() string

func (*Key) GetECDSAKey

func (m *Key) GetECDSAKey() *Key_ECDSAKey

func (*Key) GetECDSAPubKey

func (m *Key) GetECDSAPubKey() (ecdsa.PublicKey, error)

GetECDSAPubKey returns public key for ECDSAKey

func (*Key) GetID

func (m *Key) GetID() KeyID

func (*Key) GetMultisigKey

func (m *Key) GetMultisigKey() *Key_MultisigKey

func (*Key) GetMultisigPubKey

func (m *Key) GetMultisigPubKey() ([]ecdsa.PublicKey, error)

GetMultisigPubKey returns public keys for MultisigKey

func (*Key) GetPublicKey

func (m *Key) GetPublicKey() isKey_PublicKey

func (*Key) GetRole

func (m *Key) GetRole() KeyRole

func (*Key) GetRotatedAt

func (m *Key) GetRotatedAt() *time.Time

func (*Key) GetRotationCount added in v0.9.0

func (m *Key) GetRotationCount() int64

func (*Key) GetSnapshotCounter added in v0.9.0

func (m *Key) GetSnapshotCounter() int64

func (*Key) GetType

func (m *Key) GetType() KeyType

func (*Key) Marshal

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

func (*Key) MarshalTo

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

func (*Key) MarshalToSizedBuffer

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

func (*Key) ProtoMessage

func (*Key) ProtoMessage()

func (*Key) Reset

func (m *Key) Reset()

func (*Key) Size

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

func (*Key) String

func (m *Key) String() string

func (*Key) Unmarshal

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

func (Key) Validate added in v0.9.0

func (m Key) Validate() error

Validate returns an error if the key is not valid; nil otherwise

func (*Key) XXX_DiscardUnknown

func (m *Key) XXX_DiscardUnknown()

func (*Key) XXX_Marshal

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

func (*Key) XXX_Merge

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

func (*Key) XXX_OneofWrappers

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

XXX_OneofWrappers is for the internal use of the proto package.

func (*Key) XXX_Size

func (m *Key) XXX_Size() int

func (*Key) XXX_Unmarshal

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

type KeyID

type KeyID string

KeyID ensures a correctly formatted tss key ID

func (KeyID) Validate

func (id KeyID) Validate() error

Validate returns an error, if the key ID is too short or too long

type KeyRequirement

type KeyRequirement struct {
	KeyRole                    KeyRole                    `protobuf:"varint,1,opt,name=key_role,json=keyRole,proto3,enum=axelar.tss.exported.v1beta1.KeyRole" json:"key_role,omitempty"`
	KeyType                    KeyType                    `protobuf:"varint,2,opt,name=key_type,json=keyType,proto3,enum=axelar.tss.exported.v1beta1.KeyType" json:"key_type,omitempty"`
	MinKeygenThreshold         utils.Threshold            `protobuf:"bytes,3,opt,name=min_keygen_threshold,json=minKeygenThreshold,proto3" json:"min_keygen_threshold"`
	SafetyThreshold            utils.Threshold            `protobuf:"bytes,4,opt,name=safety_threshold,json=safetyThreshold,proto3" json:"safety_threshold"`
	KeyShareDistributionPolicy KeyShareDistributionPolicy `` /* 204-byte string literal not displayed */
	MaxTotalShareCount         int64                      `protobuf:"varint,6,opt,name=max_total_share_count,json=maxTotalShareCount,proto3" json:"max_total_share_count,omitempty"`
	MinTotalShareCount         int64                      `protobuf:"varint,7,opt,name=min_total_share_count,json=minTotalShareCount,proto3" json:"min_total_share_count,omitempty"`
	KeygenVotingThreshold      utils.Threshold            `protobuf:"bytes,8,opt,name=keygen_voting_threshold,json=keygenVotingThreshold,proto3" json:"keygen_voting_threshold"`
	SignVotingThreshold        utils.Threshold            `protobuf:"bytes,9,opt,name=sign_voting_threshold,json=signVotingThreshold,proto3" json:"sign_voting_threshold"`
	KeygenTimeout              int64                      `protobuf:"varint,10,opt,name=keygen_timeout,json=keygenTimeout,proto3" json:"keygen_timeout,omitempty"`
	SignTimeout                int64                      `protobuf:"varint,11,opt,name=sign_timeout,json=signTimeout,proto3" json:"sign_timeout,omitempty"`
}

KeyRequirement defines requirements for keys

func (*KeyRequirement) Descriptor

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

func (*KeyRequirement) GetKeyRole

func (m *KeyRequirement) GetKeyRole() KeyRole

func (*KeyRequirement) GetKeyShareDistributionPolicy

func (m *KeyRequirement) GetKeyShareDistributionPolicy() KeyShareDistributionPolicy

func (*KeyRequirement) GetKeyType

func (m *KeyRequirement) GetKeyType() KeyType

func (*KeyRequirement) GetKeygenTimeout

func (m *KeyRequirement) GetKeygenTimeout() int64

func (*KeyRequirement) GetKeygenVotingThreshold

func (m *KeyRequirement) GetKeygenVotingThreshold() utils.Threshold

func (*KeyRequirement) GetMaxTotalShareCount

func (m *KeyRequirement) GetMaxTotalShareCount() int64

func (*KeyRequirement) GetMinKeygenThreshold

func (m *KeyRequirement) GetMinKeygenThreshold() utils.Threshold

func (*KeyRequirement) GetMinTotalShareCount

func (m *KeyRequirement) GetMinTotalShareCount() int64

func (*KeyRequirement) GetSafetyThreshold

func (m *KeyRequirement) GetSafetyThreshold() utils.Threshold

func (*KeyRequirement) GetSignTimeout

func (m *KeyRequirement) GetSignTimeout() int64

func (*KeyRequirement) GetSignVotingThreshold

func (m *KeyRequirement) GetSignVotingThreshold() utils.Threshold

func (*KeyRequirement) Marshal

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

func (*KeyRequirement) MarshalTo

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

func (*KeyRequirement) MarshalToSizedBuffer

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

func (*KeyRequirement) ProtoMessage

func (*KeyRequirement) ProtoMessage()

func (*KeyRequirement) Reset

func (m *KeyRequirement) Reset()

func (*KeyRequirement) Size

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

func (*KeyRequirement) String

func (m *KeyRequirement) String() string

func (*KeyRequirement) Unmarshal

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

func (KeyRequirement) Validate

func (m KeyRequirement) Validate() error

Validate validates the KeyRequirement

func (*KeyRequirement) XXX_DiscardUnknown

func (m *KeyRequirement) XXX_DiscardUnknown()

func (*KeyRequirement) XXX_Marshal

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

func (*KeyRequirement) XXX_Merge

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

func (*KeyRequirement) XXX_Size

func (m *KeyRequirement) XXX_Size() int

func (*KeyRequirement) XXX_Unmarshal

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

type KeyRole

type KeyRole int32
const (
	Unknown      KeyRole = 0
	MasterKey    KeyRole = 1
	SecondaryKey KeyRole = 2
	ExternalKey  KeyRole = 3
)

func GetKeyRoles

func GetKeyRoles() []KeyRole

GetKeyRoles returns an array of all types of key role

func KeyRoleFromSimpleStr

func KeyRoleFromSimpleStr(str string) (KeyRole, error)

KeyRoleFromSimpleStr creates a KeyRole from string

func (KeyRole) EnumDescriptor

func (KeyRole) EnumDescriptor() ([]byte, []int)

func (KeyRole) SimpleString

func (x KeyRole) SimpleString() string

SimpleString returns a human-readable string

func (KeyRole) String

func (x KeyRole) String() string

func (KeyRole) Validate

func (x KeyRole) Validate() error

Validate validates the KeyRole

type KeyShareDistributionPolicy

type KeyShareDistributionPolicy int32
const (
	Unspecified     KeyShareDistributionPolicy = 0
	WeightedByStake KeyShareDistributionPolicy = 1
	OnePerValidator KeyShareDistributionPolicy = 2
)

func KeyShareDistributionPolicyFromSimpleStr

func KeyShareDistributionPolicyFromSimpleStr(str string) (KeyShareDistributionPolicy, error)

KeyShareDistributionPolicyFromSimpleStr creates a KeyShareDistributionPolicy from string

func (KeyShareDistributionPolicy) EnumDescriptor

func (KeyShareDistributionPolicy) EnumDescriptor() ([]byte, []int)

func (KeyShareDistributionPolicy) SimpleString

func (r KeyShareDistributionPolicy) SimpleString() string

SimpleString returns a human-readable string

func (KeyShareDistributionPolicy) String

func (KeyShareDistributionPolicy) Validate

func (r KeyShareDistributionPolicy) Validate() error

Validate validates the KeyShareDistributionPolicy

type KeyType

type KeyType int32
const (
	KEY_TYPE_UNSPECIFIED KeyType = 0
	None                 KeyType = 1
	Threshold            KeyType = 2
	Multisig             KeyType = 3
)

func KeyTypeFromSimpleStr

func KeyTypeFromSimpleStr(str string) (KeyType, error)

KeyTypeFromSimpleStr creates a KeyType from string

func (KeyType) EnumDescriptor

func (KeyType) EnumDescriptor() ([]byte, []int)

func (KeyType) SimpleString

func (x KeyType) SimpleString() string

SimpleString returns a human-readable string

func (KeyType) String

func (x KeyType) String() string

func (KeyType) Validate

func (x KeyType) Validate() error

Validate validates the KeyType

type Key_ECDSAKey

type Key_ECDSAKey struct {
	Value []byte `protobuf:"bytes,1,opt,name=value,proto3" json:"value,omitempty"`
}

func (*Key_ECDSAKey) Descriptor

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

func (*Key_ECDSAKey) GetPubKey

func (m *Key_ECDSAKey) GetPubKey() (*ecdsa.PublicKey, error)

GetPubKey returns the ECDSA public Key

func (*Key_ECDSAKey) GetValue

func (m *Key_ECDSAKey) GetValue() []byte

func (*Key_ECDSAKey) Marshal

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

func (*Key_ECDSAKey) MarshalTo

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

func (*Key_ECDSAKey) MarshalToSizedBuffer

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

func (*Key_ECDSAKey) ProtoMessage

func (*Key_ECDSAKey) ProtoMessage()

func (*Key_ECDSAKey) Reset

func (m *Key_ECDSAKey) Reset()

func (*Key_ECDSAKey) Size

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

func (*Key_ECDSAKey) String

func (m *Key_ECDSAKey) String() string

func (*Key_ECDSAKey) Unmarshal

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

func (*Key_ECDSAKey) XXX_DiscardUnknown

func (m *Key_ECDSAKey) XXX_DiscardUnknown()

func (*Key_ECDSAKey) XXX_Marshal

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

func (*Key_ECDSAKey) XXX_Merge

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

func (*Key_ECDSAKey) XXX_Size

func (m *Key_ECDSAKey) XXX_Size() int

func (*Key_ECDSAKey) XXX_Unmarshal

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

type Key_ECDSAKey_

type Key_ECDSAKey_ struct {
	ECDSAKey *Key_ECDSAKey `protobuf:"bytes,4,opt,name=ecdsa_key,json=ecdsaKey,proto3,oneof" json:"ecdsa_key,omitempty"`
}

func (*Key_ECDSAKey_) MarshalTo

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

func (*Key_ECDSAKey_) MarshalToSizedBuffer

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

func (*Key_ECDSAKey_) Size

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

type Key_MultisigKey

type Key_MultisigKey struct {
	Values    [][]byte `protobuf:"bytes,1,rep,name=values,proto3" json:"values,omitempty"`
	Threshold int64    `protobuf:"varint,2,opt,name=threshold,proto3" json:"threshold,omitempty"`
}

func (*Key_MultisigKey) Descriptor

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

func (*Key_MultisigKey) GetPubKey

func (m *Key_MultisigKey) GetPubKey() ([]*ecdsa.PublicKey, error)

GetPubKey returns the ECDSA public Key

func (*Key_MultisigKey) GetThreshold

func (m *Key_MultisigKey) GetThreshold() int64

func (*Key_MultisigKey) GetValues

func (m *Key_MultisigKey) GetValues() [][]byte

func (*Key_MultisigKey) Marshal

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

func (*Key_MultisigKey) MarshalTo

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

func (*Key_MultisigKey) MarshalToSizedBuffer

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

func (*Key_MultisigKey) ProtoMessage

func (*Key_MultisigKey) ProtoMessage()

func (*Key_MultisigKey) Reset

func (m *Key_MultisigKey) Reset()

func (*Key_MultisigKey) Size

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

func (*Key_MultisigKey) String

func (m *Key_MultisigKey) String() string

func (*Key_MultisigKey) Unmarshal

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

func (*Key_MultisigKey) XXX_DiscardUnknown

func (m *Key_MultisigKey) XXX_DiscardUnknown()

func (*Key_MultisigKey) XXX_Marshal

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

func (*Key_MultisigKey) XXX_Merge

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

func (*Key_MultisigKey) XXX_Size

func (m *Key_MultisigKey) XXX_Size() int

func (*Key_MultisigKey) XXX_Unmarshal

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

type Key_MultisigKey_

type Key_MultisigKey_ struct {
	MultisigKey *Key_MultisigKey `protobuf:"bytes,5,opt,name=multisig_key,json=multisigKey,proto3,oneof" json:"multisig_key,omitempty"`
}

func (*Key_MultisigKey_) MarshalTo

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

func (*Key_MultisigKey_) MarshalToSizedBuffer

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

func (*Key_MultisigKey_) Size

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

type MultisigKey

type MultisigKey struct {
	ID        KeyID
	Values    []ecdsa.PublicKey
	Role      KeyRole
	RotatedAt *time.Time
}

MultisigKey contains the public key value and corresponding ID

type SigKeyPair

type SigKeyPair struct {
	PubKey    []byte `protobuf:"bytes,1,opt,name=pub_key,json=pubKey,proto3" json:"pub_key,omitempty"`
	Signature []byte `protobuf:"bytes,2,opt,name=signature,proto3" json:"signature,omitempty"`
}

PubKeyInfo holds a pubkey and a signature

func (*SigKeyPair) Descriptor

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

func (SigKeyPair) GetKey

func (m SigKeyPair) GetKey() (ecdsa.PublicKey, error)

GetKey returns the public key of the SigKeyPair

func (*SigKeyPair) GetPubKey

func (m *SigKeyPair) GetPubKey() []byte

func (SigKeyPair) GetSig

func (m SigKeyPair) GetSig() (btcec.Signature, error)

GetSig returns the signature of the SigKeyPair

func (*SigKeyPair) GetSignature

func (m *SigKeyPair) GetSignature() []byte

func (*SigKeyPair) Marshal

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

func (*SigKeyPair) MarshalTo

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

func (*SigKeyPair) MarshalToSizedBuffer

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

func (*SigKeyPair) ProtoMessage

func (*SigKeyPair) ProtoMessage()

func (*SigKeyPair) Reset

func (m *SigKeyPair) Reset()

func (*SigKeyPair) Size

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

func (*SigKeyPair) String

func (m *SigKeyPair) String() string

func (*SigKeyPair) Unmarshal

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

func (SigKeyPair) Validate

func (m SigKeyPair) Validate() error

Validate validates the SigKeyPair

func (*SigKeyPair) XXX_DiscardUnknown

func (m *SigKeyPair) XXX_DiscardUnknown()

func (*SigKeyPair) XXX_Marshal

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

func (*SigKeyPair) XXX_Merge

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

func (*SigKeyPair) XXX_Size

func (m *SigKeyPair) XXX_Size() int

func (*SigKeyPair) XXX_Unmarshal

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

type SigStatus

type SigStatus int32
const (
	SigStatus_Unspecified SigStatus = 0
	SigStatus_Queued      SigStatus = 1
	SigStatus_Signing     SigStatus = 2
	SigStatus_Signed      SigStatus = 3
	SigStatus_Aborted     SigStatus = 4
	SigStatus_Invalid     SigStatus = 5
)

func (SigStatus) EnumDescriptor

func (SigStatus) EnumDescriptor() ([]byte, []int)

func (SigStatus) String

func (x SigStatus) String() string

type SignInfo

type SignInfo struct {
	KeyID           KeyID      `protobuf:"bytes,1,opt,name=key_id,json=keyId,proto3,casttype=KeyID" json:"key_id,omitempty"`
	SigID           string     `protobuf:"bytes,2,opt,name=sig_id,json=sigId,proto3" json:"sig_id,omitempty"`
	Msg             []byte     `protobuf:"bytes,3,opt,name=msg,proto3" json:"msg,omitempty"`
	SnapshotCounter int64      `protobuf:"varint,4,opt,name=snapshot_counter,json=snapshotCounter,proto3" json:"snapshot_counter,omitempty"`
	RequestModule   string     `protobuf:"bytes,5,opt,name=request_module,json=requestModule,proto3" json:"request_module,omitempty"`
	Metadata        string     `protobuf:"bytes,6,opt,name=metadata,proto3" json:"metadata,omitempty"` // Deprecated: Do not use.
	ModuleMetadata  *types.Any `protobuf:"bytes,7,opt,name=module_metadata,json=moduleMetadata,proto3" json:"module_metadata,omitempty"`
}

SignInfo holds information about a sign request

func (*SignInfo) Descriptor

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

func (*SignInfo) GetKeyID

func (m *SignInfo) GetKeyID() KeyID

func (*SignInfo) GetMetadata deprecated

func (m *SignInfo) GetMetadata() string

Deprecated: Do not use.

func (*SignInfo) GetModuleMetadata added in v0.18.0

func (m *SignInfo) GetModuleMetadata() *types.Any

func (*SignInfo) GetMsg

func (m *SignInfo) GetMsg() []byte

func (*SignInfo) GetRequestModule

func (m *SignInfo) GetRequestModule() string

func (*SignInfo) GetSigID

func (m *SignInfo) GetSigID() string

func (*SignInfo) GetSnapshotCounter

func (m *SignInfo) GetSnapshotCounter() int64

func (*SignInfo) Marshal

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

func (*SignInfo) MarshalTo

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

func (*SignInfo) MarshalToSizedBuffer

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

func (*SignInfo) ProtoMessage

func (*SignInfo) ProtoMessage()

func (*SignInfo) Reset

func (m *SignInfo) Reset()

func (*SignInfo) Size

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

func (*SignInfo) String

func (m *SignInfo) String() string

func (*SignInfo) Unmarshal

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

func (SignInfo) UnpackInterfaces added in v0.18.3

func (m SignInfo) UnpackInterfaces(unpacker codectypes.AnyUnpacker) error

UnpackInterfaces implements UnpackInterfacesMessage

func (*SignInfo) XXX_DiscardUnknown

func (m *SignInfo) XXX_DiscardUnknown()

func (*SignInfo) XXX_Marshal

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

func (*SignInfo) XXX_Merge

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

func (*SignInfo) XXX_Size

func (m *SignInfo) XXX_Size() int

func (*SignInfo) XXX_Unmarshal

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

type Signature

type Signature struct {
	SigID string `protobuf:"bytes,1,opt,name=sig_id,json=sigId,proto3" json:"sig_id,omitempty"`
	// Types that are valid to be assigned to Sig:
	//	*Signature_SingleSig_
	//	*Signature_MultiSig_
	Sig       isSignature_Sig `protobuf_oneof:"sig"`
	SigStatus SigStatus       `` /* 132-byte string literal not displayed */
}

Signature holds public key and ECDSA signature

func (*Signature) Descriptor

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

func (*Signature) GetMultiSig

func (m *Signature) GetMultiSig() *Signature_MultiSig

func (*Signature) GetSig

func (m *Signature) GetSig() isSignature_Sig

func (*Signature) GetSigID

func (m *Signature) GetSigID() string

func (*Signature) GetSigStatus

func (m *Signature) GetSigStatus() SigStatus

func (*Signature) GetSingleSig

func (m *Signature) GetSingleSig() *Signature_SingleSig

func (*Signature) Marshal

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

func (*Signature) MarshalTo

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

func (*Signature) MarshalToSizedBuffer

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

func (*Signature) ProtoMessage

func (*Signature) ProtoMessage()

func (*Signature) Reset

func (m *Signature) Reset()

func (*Signature) Size

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

func (*Signature) String

func (m *Signature) String() string

func (*Signature) Unmarshal

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

func (Signature) Validate added in v0.9.0

func (m Signature) Validate() error

Validate validates the given Signature

func (*Signature) XXX_DiscardUnknown

func (m *Signature) XXX_DiscardUnknown()

func (*Signature) XXX_Marshal

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

func (*Signature) XXX_Merge

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

func (*Signature) XXX_OneofWrappers

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

XXX_OneofWrappers is for the internal use of the proto package.

func (*Signature) XXX_Size

func (m *Signature) XXX_Size() int

func (*Signature) XXX_Unmarshal

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

type Signature_MultiSig

type Signature_MultiSig struct {
	SigKeyPairs []SigKeyPair `protobuf:"bytes,1,rep,name=sig_key_pairs,json=sigKeyPairs,proto3" json:"sig_key_pairs"`
}

func (*Signature_MultiSig) Descriptor

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

func (*Signature_MultiSig) GetSigKeyPairs

func (m *Signature_MultiSig) GetSigKeyPairs() []SigKeyPair

func (*Signature_MultiSig) Marshal

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

func (*Signature_MultiSig) MarshalTo

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

func (*Signature_MultiSig) MarshalToSizedBuffer

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

func (*Signature_MultiSig) ProtoMessage

func (*Signature_MultiSig) ProtoMessage()

func (*Signature_MultiSig) Reset

func (m *Signature_MultiSig) Reset()

func (*Signature_MultiSig) Size

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

func (*Signature_MultiSig) String

func (m *Signature_MultiSig) String() string

func (*Signature_MultiSig) Unmarshal

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

func (*Signature_MultiSig) XXX_DiscardUnknown

func (m *Signature_MultiSig) XXX_DiscardUnknown()

func (*Signature_MultiSig) XXX_Marshal

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

func (*Signature_MultiSig) XXX_Merge

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

func (*Signature_MultiSig) XXX_Size

func (m *Signature_MultiSig) XXX_Size() int

func (*Signature_MultiSig) XXX_Unmarshal

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

type Signature_MultiSig_

type Signature_MultiSig_ struct {
	MultiSig *Signature_MultiSig `protobuf:"bytes,3,opt,name=multi_sig,json=multiSig,proto3,oneof" json:"multi_sig,omitempty"`
}

func (*Signature_MultiSig_) GetSignature

func (m *Signature_MultiSig_) GetSignature() ([]btcec.Signature, error)

GetSignature returns list of btcec Signatures for multi sig

func (*Signature_MultiSig_) MarshalTo

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

func (*Signature_MultiSig_) MarshalToSizedBuffer

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

func (*Signature_MultiSig_) Size

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

type Signature_SingleSig

type Signature_SingleSig struct {
	SigKeyPair SigKeyPair `protobuf:"bytes,1,opt,name=sig_key_pair,json=sigKeyPair,proto3" json:"sig_key_pair"`
}

func (*Signature_SingleSig) Descriptor

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

func (*Signature_SingleSig) GetSigKeyPair

func (m *Signature_SingleSig) GetSigKeyPair() SigKeyPair

func (*Signature_SingleSig) Marshal

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

func (*Signature_SingleSig) MarshalTo

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

func (*Signature_SingleSig) MarshalToSizedBuffer

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

func (*Signature_SingleSig) ProtoMessage

func (*Signature_SingleSig) ProtoMessage()

func (*Signature_SingleSig) Reset

func (m *Signature_SingleSig) Reset()

func (*Signature_SingleSig) Size

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

func (*Signature_SingleSig) String

func (m *Signature_SingleSig) String() string

func (*Signature_SingleSig) Unmarshal

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

func (*Signature_SingleSig) XXX_DiscardUnknown

func (m *Signature_SingleSig) XXX_DiscardUnknown()

func (*Signature_SingleSig) XXX_Marshal

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

func (*Signature_SingleSig) XXX_Merge

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

func (*Signature_SingleSig) XXX_Size

func (m *Signature_SingleSig) XXX_Size() int

func (*Signature_SingleSig) XXX_Unmarshal

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

type Signature_SingleSig_

type Signature_SingleSig_ struct {
	SingleSig *Signature_SingleSig `protobuf:"bytes,2,opt,name=single_sig,json=singleSig,proto3,oneof" json:"single_sig,omitempty"`
}

func (*Signature_SingleSig_) GetSignature

func (m *Signature_SingleSig_) GetSignature() (btcec.Signature, error)

GetSignature returns btcec Signature for single sig

func (*Signature_SingleSig_) MarshalTo

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

func (*Signature_SingleSig_) MarshalToSizedBuffer

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

func (*Signature_SingleSig_) Size

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

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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