You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
taobao/crypto.go

16 lines
244 B

package taobao
import (
"crypto/md5"
"encoding/hex"
"strings"
)
// 签名
func createSign(signStr string) string {
h := md5.New()
h.Write([]byte(signStr))
cipherStr := h.Sum(nil)
return strings.ToUpper(hex.EncodeToString(cipherStr))
}