Documentation ¶
Index ¶
- type BootstrapNode
- type Certificate
- func (cert *Certificate) Dump() (string, error)
- func (cert *Certificate) GetDiscoveryNodes() []core.DiscoveryNode
- func (cert *Certificate) GetNodeRef() *core.RecordRef
- func (cert *Certificate) GetPublicKey() crypto.PublicKey
- func (cert *Certificate) GetRole() core.StaticRole
- func (cert *Certificate) GetRootDomainReference() *core.RecordRef
- func (cert *Certificate) SetRootDomainReference(ref *core.RecordRef)
- func (cert *Certificate) SignNetworkPart(key crypto.PrivateKey) ([]byte, error)
- func (cert *Certificate) SignNodePart(key crypto.PrivateKey) ([]byte, error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type BootstrapNode ¶ added in v0.6.2
type BootstrapNode struct { PublicKey string `json:"public_key"` Host string `json:"host"` NetworkSign []byte `json:"network_sign"` NodeSign []byte `json:"node_sign"` NodeRef string `json:"node_ref"` // contains filtered or unexported fields }
BootstrapNode holds info about bootstrap nodes
func (*BootstrapNode) GetHost ¶ added in v0.6.3
func (bn *BootstrapNode) GetHost() string
func (*BootstrapNode) GetNodeRef ¶ added in v0.6.3
func (bn *BootstrapNode) GetNodeRef() *core.RecordRef
func (*BootstrapNode) GetPublicKey ¶ added in v0.6.3
func (bn *BootstrapNode) GetPublicKey() crypto.PublicKey
type Certificate ¶
type Certificate struct { MajorityRule int `json:"majority_rule"` MinRoles struct { Virtual uint `json:"virtual"` HeavyMaterial uint `json:"heavy_material"` LightMaterial uint `json:"light_material"` } `json:"min_roles"` PublicKey string `json:"public_key"` Reference string `json:"reference"` PulsarPublicKeys []string `json:"pulsar_public_keys"` Role string `json:"role"` BootstrapNodes []BootstrapNode `json:"bootstrap_nodes"` RootDomainReference string `json:"root_domain_ref"` // contains filtered or unexported fields }
Certificate holds info about certificate
func NewCertificatesWithKeys ¶ added in v0.6.2
func NewCertificatesWithKeys(publicKey crypto.PublicKey, keyProcessor core.KeyProcessor) (*Certificate, error)
NewCertificatesWithKeys generate certificate from given keys
func ReadCertificate ¶ added in v0.6.3
func ReadCertificate(publicKey crypto.PublicKey, keyProcessor core.KeyProcessor, certPath string) (*Certificate, error)
ReadCertificate constructor creates new Certificate component
func (*Certificate) Dump ¶
func (cert *Certificate) Dump() (string, error)
func (*Certificate) GetDiscoveryNodes ¶ added in v0.6.3
func (cert *Certificate) GetDiscoveryNodes() []core.DiscoveryNode
GetDiscoveryNodes return bootstrap nodes array
func (*Certificate) GetNodeRef ¶ added in v0.6.3
func (cert *Certificate) GetNodeRef() *core.RecordRef
func (*Certificate) GetPublicKey ¶
func (cert *Certificate) GetPublicKey() crypto.PublicKey
func (*Certificate) GetRole ¶ added in v0.6.3
func (cert *Certificate) GetRole() core.StaticRole
func (*Certificate) GetRootDomainReference ¶ added in v0.6.3
func (cert *Certificate) GetRootDomainReference() *core.RecordRef
GetRootDomainReference returns RootDomain reference
func (*Certificate) SetRootDomainReference ¶ added in v0.6.3
func (cert *Certificate) SetRootDomainReference(ref *core.RecordRef)
SetRootDomainReference sets RootDomain reference for certificate
func (*Certificate) SignNetworkPart ¶ added in v0.6.3
func (cert *Certificate) SignNetworkPart(key crypto.PrivateKey) ([]byte, error)
SignNetworkPart signs network part in certificate
func (*Certificate) SignNodePart ¶ added in v0.6.3
func (cert *Certificate) SignNodePart(key crypto.PrivateKey) ([]byte, error)
SignNodePart signs node part in certificate
Click to show internal directories.
Click to hide internal directories.