ECDSA stuff in Haskell