key

package
v0.0.0-...-2fa318d Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Feb 4, 2024 License: Apache-2.0 Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func DecodeECDHPublicKey

func DecodeECDHPublicKey(
	key []byte,
) (*ecdh.PublicKey, error)

func Decrypt

func Decrypt(
	key []byte,
	cip string,
) ([]byte, error)

func EncodeECDHPublicKey

func EncodeECDHPublicKey(
	key *ecdh.PublicKey,
) ([]byte, error)

func Encrypt

func Encrypt(
	key []byte,
	text []byte,
) (string, error)

func GenerateECDH

func GenerateECDH() (*ecdh.PrivateKey, error)

Types

type CommonKey

type CommonKey []byte

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL