[][src]Function ffsend_api::crypto::sig::signature_encoded

pub fn signature_encoded(key: &[u8], data: &[u8]) -> Result<String, ErrorStack>

Compute the signature for the given data and key. This is done using an HMAC key using the SHA256 digest.

The resulting signature is encoded as base64 string in an URL-safe manner.

If computing the signature failed, an error is returned.