aes

package
v0.0.4 Latest Latest
Warning

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

Go to latest
Published: Feb 5, 2023 License: MIT Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type AESEncryptor

type AESEncryptor struct {
	// contains filtered or unexported fields
}

AESEncryptor implements Encryptor interface by using AES

func NewAESEncryptor

func NewAESEncryptor(key []byte) (*AESEncryptor, error)

NewAESEncryptor instantiate an in memory encryption service

func (*AESEncryptor) Decrypt

func (ae *AESEncryptor) Decrypt(ciphertext, appName string) (string, error)

Decrypt the given ciphertext and return the plaintext or an error

func (*AESEncryptor) Encrypt

func (ae *AESEncryptor) Encrypt(plaintext, appName string) (string, error)

Encrypt the plaintext argument and return a ciphertext string or an error

Jump to

Keyboard shortcuts

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