Documentation ¶
Index ¶
- func AESDecrypt(content, key string, mode ...string) (res string, err error)
- func AESEncrypt(content, key string, mode ...string) (res string, err error)
- func CheckInArray(value string, input []string) bool
- func CheckInMap(key string, input map[string]interface{}) bool
- func DESDecrypt(input string, skey string, mode ...string) (r string, err error)
- func DESEncrypt(input string, skey string, mode ...string) (r string, err error)
- func GenRsaKey(pkcsType string, bits int) (pubKey, priKey string, err error)
- func GetSecret(l int) string
- func GetSecretExtra(l int) string
- func HmacEncrypt(data, key string) string
- func MD5(str string) string
- func RSADecrypt(origin, key, pkcsType string) (string, error)
- func RSAEncrypt(origData, publicKey, pkcsType string) (data string, err error)
- func RSASign(message, privateKey, mode, pkcsType string) (string, error)
- func RSASignVerify(src, sign, publicKey, mode, pkcsType string) (pass bool, err error)
- func Sha1Encrypt(raw string) string
- func Sha256Encrypt(raw string) string
- func Sha512Encrypt(raw string) string
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func AESDecrypt ¶
AESDecrypt aes解密
func AESEncrypt ¶
AESEncrypt aes加密
func CheckInMap ¶
CheckInMap 检查map中是否存在某键值对,值不能为空
func DESDecrypt ¶
DESDecrypt DES解密
func DESEncrypt ¶
DESEncrypt des加密
func RSAEncrypt ¶
RSAEncrypt RSA公钥加密
func RSASignVerify ¶
RSASignVerify RSA签名验证
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.