diff options
author | Dmitry Baryshkov <dbaryshkov@gmail.com> | 2020-03-21 22:33:50 +0300 |
---|---|---|
committer | Jussi Kivilinna <jussi.kivilinna@iki.fi> | 2020-04-19 21:57:48 +0300 |
commit | d7fa70ed9ddc6e0189a8b59016b1f17717a26865 (patch) | |
tree | 82fd521483eddfd3e5ac102e372d03a3c9694e48 /cipher/mac-poly1305.c | |
parent | 469e2fefb64e3a4bd80995935f82caf416e3a4ae (diff) | |
download | libgcrypt-d7fa70ed9ddc6e0189a8b59016b1f17717a26865.tar.gz |
mac: add support for gcry_mac_ctl(GCRYCTL_SET_SBOX)
* cipher/mac-internal.h (gcry_mac_spec_ops_t): add set_extra_info field
for providing additional settings.
* cipher/mac.c (_gcry_mac_ctl): support GCRYCTL_SET_SBOX call.
* cipher/mac-cmac.c (cmac_ops): set set_extra_info to NULL.
* cipher/mac-gmac.c (gmac_ops): the same.
* cipher/mac-hmac.c (hmac_ops): the same.
* cipher/mac-poly1305.c (poly1305mac_ops): the same.
--
New MAC GOST28147-IMIT needs info about S-Box to be used. This info can
be passed via a call to gcry_mac_ctl(GCRYCTL_SET_SBOX, ...).
Signed-off-by: Dmitry Baryshkov <dbaryshkov@gmail.com>
Diffstat (limited to 'cipher/mac-poly1305.c')
-rw-r--r-- | cipher/mac-poly1305.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/cipher/mac-poly1305.c b/cipher/mac-poly1305.c index b80f87db..39ba790f 100644 --- a/cipher/mac-poly1305.c +++ b/cipher/mac-poly1305.c @@ -322,7 +322,8 @@ static gcry_mac_spec_ops_t poly1305mac_ops = { poly1305mac_read, poly1305mac_verify, poly1305mac_get_maclen, - poly1305mac_get_keylen + poly1305mac_get_keylen, + NULL }; |