diff --git a/card.go b/card.go index d6dd29e..5b1242a 100644 --- a/card.go +++ b/card.go @@ -2,7 +2,7 @@ package larkhertz import ( "context" - "crypto/sha256" + "crypto/sha1" "encoding/json" "fmt" "strings" @@ -59,7 +59,7 @@ func (opt LarkMiddleware) cardSignature(nonce string, timestamp string, body str b.WriteString(token) b.WriteString(body) bs := []byte(b.String()) - h := sha256.New() + h := sha1.New() h.Write(bs) bs = h.Sum(nil) return fmt.Sprintf("%x", bs)