Re: [PATCH 0/7] Add meta interface for MAC algorithms

2019-07-19 Thread Dmitry Eremin-Solenikov
Hello, пт, 19 июл. 2019 г. в 16:38, Daiki Ueno : > > From: Daiki Ueno > > As discussed in: > https://lists.lysator.liu.se/pipermail/nettle-bugs/2019/007662.html > > This moves `struct nettle_mac` to nettle-meta.h and provide the meta > interface for all defined MAC algorithms. Great! > Each

Re: [PATCH 1/7] hmac: Add set_key_expanded function

2019-07-19 Thread Dmitry Eremin-Solenikov
Hello, пт, 19 июл. 2019 г. в 16:38, Daiki Ueno : > > From: Daiki Ueno > > This adds a set_key_expanded to all HMACs, to provide a compatible > signature with nettle_set_key_func. This function is similar to > set_key, but assumes the input is already expanded to the hash block > size. I'd

[PATCH 6/7] nettle-meta: Expose all defined MACs through nettle_macs

2019-07-19 Thread Daiki Ueno
From: Daiki Ueno Signed-off-by: Daiki Ueno --- Makefile.in| 2 +- nettle-meta-macs.c | 61 ++ nettle-meta.h | 7 ++ 3 files changed, 69 insertions(+), 1 deletion(-) create mode 100644 nettle-meta-macs.c diff --git a/Makefile.in

[PATCH 0/7] Add meta interface for MAC algorithms

2019-07-19 Thread Daiki Ueno
From: Daiki Ueno As discussed in: https://lists.lysator.liu.se/pipermail/nettle-bugs/2019/007662.html This moves `struct nettle_mac` to nettle-meta.h and provide the meta interface for all defined MAC algorithms. Each meta interface shall provide the following 4 functions:

[PATCH 1/7] hmac: Add set_key_expanded function

2019-07-19 Thread Daiki Ueno
From: Daiki Ueno This adds a set_key_expanded to all HMACs, to provide a compatible signature with nettle_set_key_func. This function is similar to set_key, but assumes the input is already expanded to the hash block size. Signed-off-by: Daiki Ueno --- hmac-md5.c | 7 +++

[PATCH 3/7] nettle-meta: Add meta interface for CMAC functions

2019-07-19 Thread Daiki Ueno
From: Daiki Ueno Signed-off-by: Daiki Ueno --- Makefile.in | 1 + cmac-aes128-meta.c| 48 +++ cmac-aes256-meta.c| 48 +++ nettle-meta.h | 15 ++ testsuite/cmac-test.c | 24

[PATCH 5/7] nettle-meta: Add meta interface for UMAC functions

2019-07-19 Thread Daiki Ueno
From: Daiki Ueno Signed-off-by: Daiki Ueno --- Makefile.in| 1 + nettle-meta.h | 17 + umac128-meta.c | 47 +++ umac32-meta.c | 47 +++ umac64-meta.c | 47

[PATCH 2/7] nettle-meta: Move struct nettle_mac to nettle-meta.h

2019-07-19 Thread Daiki Ueno
From: Daiki Ueno The struct was defined in testutils.h as the interface was not stable. This generalizes the interface to cover all defined MAC algorithms in nettle. Signed-off-by: Daiki Ueno --- nettle-meta.h | 22 ++ testsuite/testutils.h | 29

[PATCH 4/7] nettle-meta: Add meta interface for HMAC functions

2019-07-19 Thread Daiki Ueno
From: Daiki Ueno Signed-off-by: Daiki Ueno --- Makefile.in | 3 +++ hmac-md5-meta.c | 46 +++ hmac-ripemd160-meta.c | 46 +++ hmac-sha1-meta.c | 46 +++