Package com.xmlcalabash.util
Object HashUtils.Companion
-
- All Implemented Interfaces:
public class HashUtils.Companion
-
-
Field Summary
Fields Modifier and Type Field Description private final String
HMAC_SHA1_ALGORITHM
public final static HashUtils.Companion
INSTANCE
-
Method Summary
Modifier and Type Method Description final String
crc(ByteArray bytes, String version)
final String
md(ByteArray bytes, String version)
final String
sha(ByteArray bytes, String version)
final String
hmac(ByteArray bytes, String key)
Computes RFC 2104-compliant HMAC signature. final String
blake3(ByteArray bytes)
final String
blake3(ByteArray bytes, XdmValue key)
final String
blake3(ByteArray context, XdmValue sharedSecret, XdmValue senderId, XdmValue recipientId)
final String
getHMAC_SHA1_ALGORITHM()
-
-
Method Detail
-
hmac
final String hmac(ByteArray bytes, String key)
Computes RFC 2104-compliant HMAC signature. Copied/modified slightly from amazon.webservices.common.Signature Contributed by Henry Thompson, used with permission
- Parameters:
bytes
- The data to be signed.key
- The signing key.- Returns:
The Base64-encoded RFC 2104-compliant HMAC signature.
-
blake3
final String blake3(ByteArray context, XdmValue sharedSecret, XdmValue senderId, XdmValue recipientId)
-
getHMAC_SHA1_ALGORITHM
final String getHMAC_SHA1_ALGORITHM()
-
-
-
-