Documentation
¶
Index ¶
- Variables
- func Decrypt(v interface{}, sessionKey, encryptedData, ivStr string) error
- func DecryptInfo(v interface{}, sessionKey, rawData, encryptedData, signature, iv string) error
- func Gen(arr []string) (string, error)
- func GenWithAmple(arr []string) (string, error)
- func HmacSha256(str, key string) string
- func IsAnyEmpty(values ...string) bool
- func Md5(str string) string
- func NewTLSClient(certPath, keyPath string) (*http.Client, error)
- func Pkcs7Unpacked(data []byte, blockSize int) ([]byte, error)
- func RandSeq(n int) string
Constants ¶
This section is empty.
Variables ¶
Functions ¶
func DecryptInfo ¶ added in v0.2.0
DecryptInfo 解密用户信息
sessionKey 微信 session_key rawData 不包括敏感信息的原始数据字符串,用于计算签名。 encryptedData 包括敏感数据在内的完整用户信息的加密数据 signature 使用 sha1( rawData + session_key ) 得到字符串,用于校验用户信息 iv 加密算法的初始向量
func GenWithAmple ¶
func HmacSha256 ¶ added in v0.2.0
func IsAnyEmpty ¶
func NewTLSClient ¶ added in v0.2.0
NewTLSClient 创建支持双向证书认证的 http.Client.
func Pkcs7Unpacked ¶ added in v0.2.0
解压 pkcs7Unpacked returns slice of the original data without padding
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.