This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// From https://gist.github.com/stevendesu/2d52f7b5e1f1184af3b667c0b5e054b8 | |
// To ensure cross-browser support even without a proper SubtleCrypto | |
// impelmentation (or without access to the impelmentation, as is the case with | |
// Chrome loaded over HTTP instead of HTTPS), this library can create SHA-256 | |
// HMAC signatures using nothing but raw JavaScript | |
/* eslint-disable no-magic-numbers, id-length, no-param-reassign, new-cap */ | |
// By giving internal functions names that we can mangle, future calls to |