blob: 4a9afcc109b44145e13fafba1fd72ac5fdf98de7 [file] [log] [blame]
Test HMAC sign and verify functions with an empty key.
On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
Importing a raw HMAC key from string literal...
PASS key.type is 'secret'
PASS key.extractable is true
PASS key.algorithm.name is 'hmac'
PASS key.algorithm.length is 0
PASS key.algorithm.hash.name is 'sha-1'
PASS key.usages is ['sign', 'verify']
Using the key to sign 'foo'...
PASS bytesToHexString(new Uint8Array(signature)) is 'a3cc770fc033e2cb419d42b64e0081a3bd3be30e'
Verifying the signature...
PASS verificationResult is true
PASS successfullyParsed is true
TEST COMPLETE