You can perform crypto operations such as hashing using the following library.

String Description Input Output
String hmacHexDigest(String <data>, String <key>, String <algorithm>)

where:

  • <data> is the string value to be hashed and must not be null
  • <key> is the string secret key to use and must not be null
  • <algorithm> is the hashing algorithm to use and must not be null
Note:

Supported algorithms are HmacMD5, HmacSHA1, HmacSHA224, HmacSHA256, HmacSHA384 and HmacSHA512.

Creates a hash for the required data with Hashed Message Authentication Code (HMAC) using the specified secret key and cryptographic hashing function algorithm.

Returns the hash or digest as a string containing only hexadecimal digits.

Supported algorithms for hashing functions are HmacMD5, HmacSHA1, HmacSHA224, HmacSHA256, HmacSHA384, and HmacSHA512.

#crypto.hmacHexDigest('data', 'secretKey', 'HmacMD5')

6659dfc3b860b836c087e3fd82c0d16b