Documentation ¶
Index ¶
- func AesDecrypt(cryted, key string) (orig string)
- func AesEncrypt(orig, key string) (cryted string)
- func MD5Check(content, encrypted string) bool
- func MD5Encode(data string) string
- func PKCS7Padding(ciphertext []byte, blocksize int) []byte
- func PKCS7UnPadding(origData []byte) []byte
- func RsaDecrypt(cryted string, privateKey []byte) (orig string)
- func RsaEncrypt(orig string, publicKey []byte) (cryted string)
- func RsaKeyPairs(keyName string, bits int) (privateKeyString, publicKeyString string)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func AesDecrypt ¶
AesEncrypt("Y14T6rcetYC2WoB2y5JGNQ", "1234567890123456") key's length must in 16/24/32
func AesEncrypt ¶
AesEncrypt("woolge735", "1234567890123456") key's length must in 16/24/32
func RsaKeyPairs ¶
RsaKeyPairs("keyName", 2048)
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.