Documentation ¶
Index ¶
- Constants
- type PrivateKey
- type PublicKey
- type Scheme
- func (s Scheme) ComputeShared(dst []byte, priv *PrivateKey, pub *PublicKey) error
- func (s Scheme) DerivePublic(priv *PrivateKey) PublicKey
- func (s Scheme) Generate(rng io.Reader) (PublicKey, PrivateKey, error)
- func (s Scheme) MarshalPrivate(dst []byte, priv *PrivateKey)
- func (s Scheme) MarshalPublic(dst []byte, x *PublicKey)
- func (s Scheme) ParsePrivate(x []byte) (PrivateKey, error)
- func (s Scheme) ParsePublic(x []byte) (PublicKey, error)
- func (s Scheme) PrivateKeySize() int
- func (s Scheme) PublicKeySize() int
- func (s Scheme) SharedSize() int
Constants ¶
View Source
const ( PrivateKeySize = curve25519.ScalarSize PublicKeySize = curve25519.PointSize )
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type PrivateKey ¶
type PrivateKey = [PrivateKeySize]byte
type PublicKey ¶
type PublicKey = [PublicKeySize]byte
type Scheme ¶
type Scheme struct{}
func (Scheme) ComputeShared ¶
func (s Scheme) ComputeShared(dst []byte, priv *PrivateKey, pub *PublicKey) error
func (Scheme) DerivePublic ¶
func (s Scheme) DerivePublic(priv *PrivateKey) PublicKey
func (Scheme) MarshalPrivate ¶
func (s Scheme) MarshalPrivate(dst []byte, priv *PrivateKey)
func (Scheme) MarshalPublic ¶
func (Scheme) ParsePrivate ¶
func (s Scheme) ParsePrivate(x []byte) (PrivateKey, error)
func (Scheme) PrivateKeySize ¶
func (Scheme) PublicKeySize ¶
func (Scheme) SharedSize ¶
Click to show internal directories.
Click to hide internal directories.