Computes the message hash for Bitcoin ECDSA signatures. This function follows the Bitcoin message signing standard, which involves prefixing the message with a magic string and its length, then double SHA256 hashing the result.
The message to be hashed. Can be a string or BytesLike.
Optional
Optional. A custom prefix to use instead of the default "\u0018Bitcoin Signed Message:\n".
The Bitcoin hash of the prefixed message as Bytes.
Computes the message hash for Bitcoin ECDSA signatures. This function follows the Bitcoin message signing standard, which involves prefixing the message with a magic string and its length, then double SHA256 hashing the result.