I'm trying to get the hash sha256 value with utf8 string format.
I expect linh@test.com will be come c0f50b4ab8bdd7bae3a6aff8278d3e96b07d0957541fdc1d4ad8c09680e00d5c
with this line of code:
But, I receive this error message instead:
sjcl.js:8 Uncaught TypeError: Cannot read property 'length' of undefined
at Object.bitLength (sjcl.js:8)
at sjcl.hash.sha256.update (sjcl.js:18)
Could you please help me to get the right value?
Thank you
Best
Linh
Hi guys,
I'm trying to get the hash sha256 value with utf8 string format. I expect linh@test.com will be come c0f50b4ab8bdd7bae3a6aff8278d3e96b07d0957541fdc1d4ad8c09680e00d5c with this line of code:
sjcl.codec.utf8String.fromBits(sjcl.hash.sha256.hash("linh@test.com"));
But, I receive this error message instead: sjcl.js:8 Uncaught TypeError: Cannot read property 'length' of undefined at Object.bitLength (sjcl.js:8) at sjcl.hash.sha256.update (sjcl.js:18)
Could you please help me to get the right value? Thank you Best Linh