Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func LoadNodeKey ¶
func LoadNodeKey(path string) (crypto.PrivateKey, error)
func SaveNodeKey ¶
func SaveNodeKey(path string, pk crypto.PrivateKey) error
Types ¶
type NodeKeyFile ¶
type NodeKeyFile struct {
Key crypto.PrivateKey
}
func (NodeKeyFile) MarshalJSON ¶
func (nk NodeKeyFile) MarshalJSON() ([]byte, error)
func (*NodeKeyFile) UnmarshalJSON ¶
func (nk *NodeKeyFile) UnmarshalJSON(data []byte) error
type PrivateKeyInfo ¶
type PrivateKeyInfo struct { KeyType string `json:"key_type"` PrivateKeyText string `json:"private_key_text"` PublicKeyHex string `json:"public_key_hex"` NodeID string `json:"node_id,omitempty"` // Address is an optional field that may be set for certain key types that // can generate an address depending on the signature (auth) type used. Address string `json:"user_address,omitempty"` // contains filtered or unexported fields }
func (*PrivateKeyInfo) MarshalJSON ¶
func (p *PrivateKeyInfo) MarshalJSON() ([]byte, error)
func (*PrivateKeyInfo) MarshalText ¶
func (p *PrivateKeyInfo) MarshalText() ([]byte, error)
Click to show internal directories.
Click to hide internal directories.