• Hashes a message using SHA256.

    • When a message string is provided, we hash as a UTF-8 string using SHA-256.

    • When a message object with personalSign property is provided, we hash using SHA-256 of the following format:

    0x19 <0x46 (F)> <uel Signed Message:\n" + len(message)> <message>
    

    Following a similar approach to that of EIP-191.

    Parameters

    Returns string

    A sha256 hash of the message