From: Niels Möller Date: Wed, 21 Feb 2018 22:07:31 +0000 (+0100) Subject: Merge branch 'cmac-support' X-Git-Tag: nettle_3.5rc1~80 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=be5b2eda8461cbe2f586b82fc04a245e4d18da99;p=thirdparty%2Fnettle.git Merge branch 'cmac-support' --- be5b2eda8461cbe2f586b82fc04a245e4d18da99 diff --cc ChangeLog index 35dff214,57ea7cd0..efe70d63 --- a/ChangeLog +++ b/ChangeLog @@@ -1,14 -1,41 +1,52 @@@ + 2018-02-20 Niels Möller + + * testsuite/cmac-test.c (test_cmac_hash): Deallocate ctx properly. + + 2018-02-19 Niels Möller + + Mostly aesthetic changes. Besides indentation: + * cmac.h (struct cmac128): Rename, to cmac128_ctx. + (CMAC128_CTX): Rename first member from data to ctx. + + * cmac.c: Use const void * as the type for cipher arguments. + (block_mulx): Un-inline. + (cmac128_set_key): Make a constant function local. + + * testsuite/cmac-test.c: Delete local typedefs. + + 2018-02-19 Nikos Mavrogiannopoulos + + Add support for CMAC. + * cmac.h: New file. + (struct cmac128): New struct. + * cmac.c (block_mulx, cmac128_set_key, cmac128_update) + (cmac128_digest): New file, new functions. + * cmac-aes128.c (cmac_aes128_set_key, cmac_aes128_update) + (cmac_aes128_digest): New file, new functions. + * cmac-aes256.c (cmac_aes256_set_key, cmac_aes256_update) + (cmac_aes256_digest): New file, new functions. + * Makefile.in (nettle_SOURCES): Added cmac.c cmac-aes128.c cmac-aes256.c. + (HEADERS): Added cmac.h. + + * testsuite/cmac-test.c: New tests. + * testsuite/Makefile.in (TS_NETTLE_SOURCES): Add cmac-test.c. + + * examples/nettle-benchmark.c (time_cmac): New function. + (main): Use it. + + * nettle.texinfo: Document CMAC. + +2018-02-20 Niels Möller + + * testsuite/cbc-test.c (test_cbc_bulk): Use struct + aes256_ctx, instead of the deprecated struct aes_ctx. + * testsuite/cfb-test.c (test_cfb_bulk): Likewise. + * examples/rsa-session.h (struct rsa_session): Likewise. + * examples/rsa-encrypt.c (rsa_session_set_encrypt_key) + (process_file): Use aes256_* functions. + * examples/rsa-decrypt.c (rsa_session_set_decrypt_key) + (process_file): Likewise. + 2018-02-19 Niels Möller * nettle-internal.h: Include sha3.h, needed for the definition of