aboutsummaryrefslogtreecommitdiff
path: root/cc/mac/mac_key_templates.h
diff options
context:
space:
mode:
authorcandrian <candrian@google.com>2019-04-10 11:41:54 -0700
committerCharles Lee <ckl@google.com>2019-05-02 00:35:19 -0700
commita4f1b0f48d214d74e8afc624bca0e0742b427876 (patch)
treec5fd4847aeeecf24f99150e97a44911cd29bc2cf /cc/mac/mac_key_templates.h
parentf40334bcbf24fee5f6f9a0df4b0212d3dc2544a0 (diff)
downloadtink-a4f1b0f48d214d74e8afc624bca0e0742b427876.tar.gz
Add HMAC-SHA512 key templates.
PiperOrigin-RevId: 242909760 GitOrigin-RevId: 64152d44c3bd6c54b72e41923b1bf4fc3d54a7d5
Diffstat (limited to 'cc/mac/mac_key_templates.h')
-rw-r--r--cc/mac/mac_key_templates.h16
1 files changed, 16 insertions, 0 deletions
diff --git a/cc/mac/mac_key_templates.h b/cc/mac/mac_key_templates.h
index b9d59e394..f10a4f79f 100644
--- a/cc/mac/mac_key_templates.h
+++ b/cc/mac/mac_key_templates.h
@@ -50,6 +50,22 @@ class MacKeyTemplates {
// - hash function: SHA256
// - OutputPrefixType: TINK
static const google::crypto::tink::KeyTemplate& HmacSha256();
+
+ // Returns a KeyTemplate that generates new instances of HmacKey
+ // with the following parameters:
+ // - key size: 64 bytes
+ // - tag size: 32 bytes
+ // - hash function: SHA512
+ // - OutputPrefixType: TINK
+ static const google::crypto::tink::KeyTemplate& HmacSha512HalfSizeTag();
+
+ // Returns a KeyTemplate that generates new instances of HmacKey
+ // with the following parameters:
+ // - key size: 64 bytes
+ // - tag size: 64 bytes
+ // - hash function: SHA512
+ // - OutputPrefixType: TINK
+ static const google::crypto::tink::KeyTemplate& HmacSha512();
};
} // namespace tink