Documentation ¶
Index ¶
- Variables
- type KeyPair
- func (key KeyPair) Clear()
- func (key KeyPair) PrivateKeyBytes() []byte
- func (key KeyPair) PrivateKeyPKIX() []byte
- func (key KeyPair) PrivateKeyPKIXBase64() string
- func (key KeyPair) PrivateKeyPKIXPem() string
- func (key KeyPair) PublicKeyBytes() []byte
- func (key KeyPair) PublicKeyPKIX() ([]byte, error)
- func (key KeyPair) PublicKeyPKIXBase64() (string, error)
- func (key KeyPair) PublicKeyPKIXPem() (string, error)
- func (key KeyPair) ToX25519() []byte
- func (key KeyPair) ToX25519Base64() string
Constants ¶
This section is empty.
Variables ¶
View Source
var Ed25519PKIXPrivatePrefix = []byte{0x30, 0x2E, 0x02, 0x01, 0x00, 0x30, 0x05, 0x06, 0x03, 0x2B, 0x65, 0x70, 0x04, 0x22, 0x04, 0x20}
View Source
var Ed25519PKIXPublicPrefix = []byte{0x30, 0x2A, 0x30, 0x05, 0x06, 0x03, 0x2B, 0x65, 0x70, 0x03, 0x21, 0x00}
Functions ¶
This section is empty.
Types ¶
type KeyPair ¶
type KeyPair struct {
// contains filtered or unexported fields
}
func (KeyPair) PrivateKeyBytes ¶
func (KeyPair) PrivateKeyPKIX ¶
PrivateKeyPKIX private key in PKIX, ASN.1 DER format
func (KeyPair) PrivateKeyPKIXBase64 ¶
PrivateKeyPKIXBase64 returns private key PKIX, ASN.1 DER in Base64
func (KeyPair) PrivateKeyPKIXPem ¶
PrivateKeyPKIXPem returns private key ASN.1 DER representation as PEM
func (KeyPair) PublicKeyBytes ¶
func (KeyPair) PublicKeyPKIX ¶
PublicKeyPKIX returns public key in PKIX, ASN.1 DER format
func (KeyPair) PublicKeyPKIXBase64 ¶
PublicKeyPKIXBase64 public key in PKIX, ASN.1 DER in Base64
func (KeyPair) PublicKeyPKIXPem ¶
PublicKeyPKIXPem returns public key in ASN.1 DER representation as PEM
func (KeyPair) ToX25519Base64 ¶
ToX25519Base64 converts to X25519 secret key encoded as base64.
Click to show internal directories.
Click to hide internal directories.