In Go: hmac.New(sha256.New, key), write the message, Sum(nil). Compare tags with hmac.Equal.