Documentation ¶
Index ¶
- Constants
- Variables
- func ComputeAbsCorruptionThreshold(safetyThreshold utils.Threshold, totalShareCount sdk.Int) int64
- type KeyID
- type KeyRequirement
- func (*KeyRequirement) Descriptor() ([]byte, []int)
- func (m *KeyRequirement) GetKeyRole() KeyRole
- func (m *KeyRequirement) GetKeyShareDistributionPolicy() KeyShareDistributionPolicy
- func (m *KeyRequirement) GetKeyType() KeyType
- func (m *KeyRequirement) GetKeygenTimeout() int64
- func (m *KeyRequirement) GetKeygenVotingThreshold() utils.Threshold
- func (m *KeyRequirement) GetMaxTotalShareCount() int64
- func (m *KeyRequirement) GetMinKeygenThreshold() utils.Threshold
- func (m *KeyRequirement) GetMinTotalShareCount() int64
- func (m *KeyRequirement) GetSafetyThreshold() utils.Threshold
- func (m *KeyRequirement) GetSignTimeout() int64
- func (m *KeyRequirement) GetSignVotingThreshold() utils.Threshold
- func (m *KeyRequirement) Marshal() (dAtA []byte, err error)
- func (m *KeyRequirement) MarshalTo(dAtA []byte) (int, error)
- func (m *KeyRequirement) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (*KeyRequirement) ProtoMessage()
- func (m *KeyRequirement) Reset()
- func (m *KeyRequirement) Size() (n int)
- func (m *KeyRequirement) String() string
- func (m *KeyRequirement) Unmarshal(dAtA []byte) error
- func (m KeyRequirement) Validate() error
- func (m *KeyRequirement) XXX_DiscardUnknown()
- func (m *KeyRequirement) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *KeyRequirement) XXX_Merge(src proto.Message)
- func (m *KeyRequirement) XXX_Size() int
- func (m *KeyRequirement) XXX_Unmarshal(b []byte) error
- type KeyRole
- type KeyShareDistributionPolicy
- type KeyType
- type SigKeyPair
- func (*SigKeyPair) Descriptor() ([]byte, []int)
- func (m SigKeyPair) GetKey() (ecdsa.PublicKey, error)
- func (m *SigKeyPair) GetPubKey() []byte
- func (m SigKeyPair) GetSig() (ec.Signature, error)
- func (m *SigKeyPair) GetSignature() []byte
- func (m *SigKeyPair) Marshal() (dAtA []byte, err error)
- func (m *SigKeyPair) MarshalTo(dAtA []byte) (int, error)
- func (m *SigKeyPair) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (*SigKeyPair) ProtoMessage()
- func (m *SigKeyPair) Reset()
- func (m *SigKeyPair) Size() (n int)
- func (m *SigKeyPair) String() string
- func (m *SigKeyPair) Unmarshal(dAtA []byte) error
- func (m SigKeyPair) Validate() error
- func (m *SigKeyPair) XXX_DiscardUnknown()
- func (m *SigKeyPair) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *SigKeyPair) XXX_Merge(src proto.Message)
- func (m *SigKeyPair) XXX_Size() int
- func (m *SigKeyPair) XXX_Unmarshal(b []byte) error
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 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
0: "KEY_SHARE_DISTRIBUTION_POLICY_UNSPECIFIED",
1: "KEY_SHARE_DISTRIBUTION_POLICY_WEIGHTED_BY_STAKE",
2: "KEY_SHARE_DISTRIBUTION_POLICY_ONE_PER_VALIDATOR",
}
View Source
"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,
}
Functions ¶
Types ¶
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"` 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) 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
func KeyRoleFromSimpleStr ¶
KeyRoleFromSimpleStr creates a KeyRole from string
func (KeyRole) EnumDescriptor ¶
func (KeyRole) SimpleString ¶
SimpleString returns a human-readable string
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 (x KeyShareDistributionPolicy) String() string
func (KeyShareDistributionPolicy) Validate ¶
func (r KeyShareDistributionPolicy) Validate() error
Validate validates the KeyShareDistributionPolicy
type KeyType ¶
type KeyType int32
func (KeyType) EnumDescriptor ¶
func (KeyType) SimpleString ¶
SimpleString returns a human-readable string
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() (ec.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) 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) 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
Click to show internal directories.
Click to hide internal directories.