Documentation ¶
Index ¶
Constants ¶
View Source
const PemFramePrivateKeyPrefixSize = 16
View Source
const PemFramePublicKeyPrefixSize = 12
View Source
const PublicKeySize = 32
Variables ¶
This section is empty.
Functions ¶
func PrivateKeyToPem ¶
func PrivateKeyToPem(priv ed25519.PrivateKey) ([]byte, error)
Types ¶
type PrivateKey ¶
type PrivateKey struct {
// contains filtered or unexported fields
}
func GeneratePrivateKey ¶
func GeneratePrivateKey() (PrivateKey, error)
func NewPrivateKeyFromPEM ¶
func NewPrivateKeyFromPEM(content []byte) (PrivateKey, error)
func (PrivateKey) PublicKeyBytes ¶
func (k PrivateKey) PublicKeyBytes() []byte
func (PrivateKey) ToPem ¶
func (k PrivateKey) ToPem() ([]byte, error)
Click to show internal directories.
Click to hide internal directories.