Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func MarshalPrivateKey ¶
func MarshalPrivateKey(key PrivateKey) ([]byte, error)
MarshalPrivateKey returns the base64 encoded private key.
func MarshalPublicKey ¶
MarshalPublicKey returns the base64 encoded public key.
Types ¶
type PrivateKey ¶
type PrivateKey = ed25519.PrivateKey
func NewPrivateKey ¶
func NewPrivateKey() (PrivateKey, error)
NewPrivateKey returns a new private key.
func UnmarshalPrivateKey ¶
func UnmarshalPrivateKey(b []byte) (PrivateKey, error)
UnmarshalPrivateKey returns a private key from a base64 encoded key.
type PublicKey ¶
func Public ¶
func Public(key PrivateKey) PublicKey
Public extracts the public key from a private key.
func UnmarshalPublicKey ¶
UnmarshalPublicKey returns a public key from a base64 encoded key.
Click to show internal directories.
Click to hide internal directories.