Base64, Hashes, Encryption
Webhook Relay provides a helper package to deal with various hashing and cryptography related operations.
Encoding and decoding base64 data
When base64 encoding is needed, import crypto
package:
To decode some value:
Create MD5 hash
Note: MD5 is considered cryptographically broken, if you can, use SHA256 hashing algorithm.
Create SHA1, SHA256, SHA512 hashes
Calculating HMAC
Method hmac
takes three parameters:
Algorithm, valid values: md5, sha1, sha256, sha512
Data to verify
Secret key in a string form (not base64 encoded)
Calculating CRC32 checksum
Last updated
Was this helpful?