INNER CODE UNIT · Go
hmacBytes
cc1a2b/JShunter · internal/jshunter/aws_pair.go:181
func hmacBytes(key, msg []byte) []byte {
m := hmac.New(sha256.New, key)
m.Write(msg)
return m.Sum(nil)
}
func hmacHex(key, msg []byte) string {
return hex.EncodeToString(hmacBytes(key, msg))
}