chacha20

package
v0.3.0 Latest Latest
Warning

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

Go to latest
Published: May 6, 2024 License: MIT Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	ErrUnsupportedMethod = errors.New("chacha20: unsupported method")
)

Functions

This section is empty.

Types

type KeyImpl

type KeyImpl[T types.DataType] struct {
	// contains filtered or unexported fields
}

func (*KeyImpl[T]) Algorithm

func (k *KeyImpl[T]) Algorithm() types.Algorithm

func (*KeyImpl[T]) Decrypt

func (k *KeyImpl[T]) Decrypt(ciphertext T) (plaintext T, err error)

func (*KeyImpl[T]) Encrypt

func (k *KeyImpl[T]) Encrypt(plaintext T) (ciphertext T, err error)

func (*KeyImpl[T]) Export

func (k *KeyImpl[T]) Export() (key T, err error)

func (*KeyImpl[T]) PublicKey

func (k *KeyImpl[T]) PublicKey() (key.Key[T], error)

func (*KeyImpl[T]) SKI

func (k *KeyImpl[T]) SKI() T

func (*KeyImpl[T]) Sign

func (k *KeyImpl[T]) Sign(_ T) (signature T, err error)

func (*KeyImpl[T]) Verify

func (k *KeyImpl[T]) Verify(_, _ T) (bool, error)

type KeyImportImpl

type KeyImportImpl[T types.DataType] struct{}

func (*KeyImportImpl[T]) KeyImport

func (k *KeyImportImpl[T]) KeyImport(raw interface{}, alg types.Algorithm, opts ...key.Option[T]) (key.Key[T], error)

Jump to

Keyboard shortcuts

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