crypt

package
v0.19.2 Latest Latest
Warning

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

Go to latest
Published: Mar 25, 2019 License: MIT Imports: 12 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func AesDecrypt

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

de

func AesEncrypt

func AesEncrypt(origData, key []byte) ([]byte, error)

en

func GetRandomString

func GetRandomString(l int) string

Generating Random Verification Key

func InitTls added in v0.19.0

func InitTls(pem, key string)

func Md5

func Md5(s string) string

Generate 32-bit MD5 strings

func NewTlsClientConn added in v0.18.1

func NewTlsClientConn(conn net.Conn) net.Conn

func NewTlsServerConn added in v0.18.1

func NewTlsServerConn(conn net.Conn) net.Conn

func PKCS5Padding

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

Completion when the length is insufficient

func PKCS5UnPadding

func PKCS5UnPadding(origData []byte) (error, []byte)

Remove excess

Types

This section is empty.

Jump to

Keyboard shortcuts

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