wkutil

package
v1.0.0 Latest Latest
Warning

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

Go to latest
Published: Jul 29, 2023 License: Apache-2.0 Imports: 13 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func AesDecrypt

func AesDecrypt(crypted, key []byte, iv []byte, unPaddingFunc func([]byte) []byte) ([]byte, error)

AesDecrypt AesDecrypt

func AesDecryptPkcs5

func AesDecryptPkcs5(crypted []byte, key []byte, iv []byte) ([]byte, error)

AesDecryptPkcs5 解密

func AesDecryptPkcs7

func AesDecryptPkcs7(crypted []byte, key []byte, iv []byte) ([]byte, error)

AesDecryptPkcs7 解密

func AesDecryptPkcs7Base64

func AesDecryptPkcs7Base64(crypted []byte, key []byte, iv []byte) ([]byte, error)

AesDecryptPkcs7Base64 解密

func AesDecryptSimple

func AesDecryptSimple(crypted []byte, key string, iv string) ([]byte, error)

AesDecryptSimple 解密

func AesEncrypt

func AesEncrypt(origData []byte, key []byte, iv []byte, paddingFunc func([]byte, int) []byte) ([]byte, error)

AesEncrypt AesEncrypt

func AesEncryptPkcs5

func AesEncryptPkcs5(origData []byte, key []byte, iv []byte) ([]byte, error)

AesEncryptPkcs5 加密

func AesEncryptPkcs7

func AesEncryptPkcs7(origData []byte, key []byte, iv []byte) ([]byte, error)

AesEncryptPkcs7 加密

func AesEncryptPkcs7Base64

func AesEncryptPkcs7Base64(origData []byte, key []byte, iv []byte) ([]byte, error)

AesEncryptPkcs7Base64

func AesEncryptSimple

func AesEncryptSimple(origData []byte, key string, iv string) ([]byte, error)

AesEncryptSimple 加密

func GenUUID

func GenUUID() string

GenUUID 生成uuid

func GetCurve25519Key

func GetCurve25519Key(private, public [32]byte) (Key [32]byte)

GetCurve25519Key GetCurve25519Key

func GetCurve25519KeypPair

func GetCurve25519KeypPair() (Aprivate, Apublic [32]byte)

GetCurve25519KeypPair GetCurve25519KeypPair

func GetRandomString

func GetRandomString(num int) string

GetRandomString 生成随机字符串

func MD5

func MD5(str string) string

MD5 加密

func PKCS5Padding

func PKCS5Padding(ciphertext []byte, blockSize int) []byte

PKCS5Padding PKCS5Padding

func PKCS5UnPadding

func PKCS5UnPadding(origData []byte) []byte

PKCS5UnPadding PKCS5UnPadding

func PKCS7Padding

func PKCS7Padding(ciphertext []byte, blockSize int) []byte

PKCS7Padding PKCS7Padding

func PKCS7UnPadding

func PKCS7UnPadding(origData []byte) []byte

PKCS7UnPadding PKCS7UnPadding

Types

This section is empty.

Jump to

Keyboard shortcuts

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