aes

package
v1.18.0-beta Latest Latest
Warning

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

Go to latest
Published: Jan 8, 2024 License: Apache-2.0, BSD-2-Clause, BSD-3-Clause, + 3 more Imports: 7 Imported by: 0

Documentation

Index

Constants

View Source
const (
	// PluginName plugin name
	PluginName = "AES"
)

Variables

This section is empty.

Functions

This section is empty.

Types

type AESCrypto

type AESCrypto struct {
}

AESCrypto AES crypto

func (*AESCrypto) Decrypt

func (c *AESCrypto) Decrypt(ciphertext string, key []byte) (string, error)

Decrypt base64 decode ciphertext and AES decrypt

func (*AESCrypto) Destroy

func (h *AESCrypto) Destroy() error

Destroy 销毁插件

func (*AESCrypto) Encrypt

func (c *AESCrypto) Encrypt(plaintext string, key []byte) (string, error)

Encrypt AES encrypt plaintext and base64 encode ciphertext

func (*AESCrypto) GenerateKey

func (c *AESCrypto) GenerateKey() ([]byte, error)

GenerateKey generate key

func (*AESCrypto) Initialize

func (h *AESCrypto) Initialize(c *plugin.ConfigEntry) error

Initialize 插件初始化

func (*AESCrypto) Name

func (h *AESCrypto) Name() string

Name 返回插件名字

Jump to

Keyboard shortcuts

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