enc

package
v0.0.0-...-7578c0e Latest Latest
Warning

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

Go to latest
Published: Sep 29, 2023 License: MIT Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Aes256DecryptByPassFromBase64String

func Aes256DecryptByPassFromBase64String(encryptedBase64Data, password string) (decryptedBytes []byte, err error)

Aes256DecryptByPassFromBase64String a user friendly wrapper of AesDecrypt and the reverse operation of AesEncryptStringToBase64String: it accepts base64 encrypted string and a password and returns a decrypted data

func Aes256Encrypt

func Aes256Encrypt(payload, aes32Key []byte) (encryptedData []byte, err error)

func Aes256EncryptByPassToBase64String

func Aes256EncryptByPassToBase64String(payload []byte, password string) (encryptedBase64Data string, err error)

AesEncryptStringToBase64String a user friendly wrapper of AesEncrypt which converts a password of any length to 32byte aes256 key and returns a base64 encoded encrypted data

func AesDecrypt

func AesDecrypt(encryptedData, key []byte) (decryptedData []byte, err error)

Types

This section is empty.

Jump to

Keyboard shortcuts

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