Reputation: 90
I'm new to Haskell so forgive me for not understanding the basics.
When using the Crypto.Hash.SHA256 to hash the result is something like below.
\159\252\170M\NAK\221\189S\n\191{\197y\t\USUx\143\&3\249\198K}]'\195\nU\154\SI3\199
Can anyone explain what the hell it is I'm looking at?
Upvotes: 1
Views: 396
Reputation: 48592
You're looking at the binary representation of the hash. You're probably used to seeing the hexadecimal representation. To get that, import Data.ByteString.Builder
and call toLazyByteString . byteStringHex
on it. With the hash in your question, the hexadecimal representation will be 9ffcaa4d15ddbd530abf7bc579091f55788f33f9c64b7d5d27c30a559a0f33c7
.
Upvotes: 3