Implementation of the Bitcoin cryptographic primitives in Haskell