hashMessage
Callable
Parameters
message: string
A message to hash, if its HEX it will be UTF8 decoded.
Returns string
The hashed message
hashMessage("Hello world")
> "0x8144a6fa26be252b86456491fbcd43c1de7e022241845ffea1c3df066f7cfede"
hashMessage(utf8ToHex("Hello world")) // Will be hex decoded in hashMessage
> "0x8144a6fa26be252b86456491fbcd43c1de7e022241845ffea1c3df066f7cfede"
Hashes the given message. The data will be UTF-8 HEX decoded and enveloped as follows: “\x19Ethereum Signed Message:\n” + message.length + message and hashed using keccak256.