[PATCH] caam: desc: Remove unused JUMP_TYPE_MASK definition

2015-09-03 Thread Fabio Estevam
From: Fabio Estevam JUMP_TYPE_MASK is defined in desc.h and it is never used, so we can safely remove it to avoid the following build warning: In file included from drivers/crypto/caam/desc_constr.h:7:0, from drivers/crypto/caam/ctrl.c:15: drivers/crypto/caam/desc.h:1495:0: warn

Announce loop-AES-v3.7e file/swap crypto package

2015-09-03 Thread Jari Ruusu
loop-AES changes since previous release: - Worked around block layer interface changes on 4.2 kernels. bzip2 compressed tarball is here: http://loop-aes.sourceforge.net/loop-AES/loop-AES-v3.7e.tar.bz2 md5sum 209fd5f3e658d6527bc1607f8726acda http://loop-aes.sourceforge.net/loop-AES/lo

Re: [PATCH] crypto/testmgr: don't copy from source IV too much

2015-09-03 Thread Herbert Xu
On Thu, Sep 03, 2015 at 02:32:00PM +0300, Andrey Ryabinin wrote: > While the destination buffer 'iv' is MAX_IVLEN size, > the source 'template[i].iv' could be smaller. Thus > copying it via memcpy() leads to invalid memory access. > Use strlcpy() instead. > > Signed-off-by: Andrey Ryabinin Thank

Re: testmgr: templates not tested

2015-09-03 Thread Herbert Xu
On Thu, Sep 03, 2015 at 12:21:37PM +0200, Stephan Mueller wrote: > > I see. But then it seems to be a pervasive bug as xts suffers from the same > issue too. Right. Every ablkcipher template has the same issue. That's why I wanted to take care of this in bulk with the skcipher conversion rathe

[PATCH] x86/crypto/ghash-intel: specify context size for ghash async algorithm

2015-09-03 Thread Andrey Ryabinin
Currently context size (cra_ctxsize) doesn't specified for ghash_async_alg. Which means it's zero. Thus crypto_create_tfm() doesn't allocate needed space for ghash_async_ctx, so any read/write to ctx (e.g. in ghash_async_init_tfm()) is not valid. Signed-off-by: Andrey Ryabinin --- arch/x86/crypt

[PATCH] crypto/testmgr: don't copy from source IV too much

2015-09-03 Thread Andrey Ryabinin
While the destination buffer 'iv' is MAX_IVLEN size, the source 'template[i].iv' could be smaller. Thus copying it via memcpy() leads to invalid memory access. Use strlcpy() instead. Signed-off-by: Andrey Ryabinin --- crypto/testmgr.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) di

Re: testmgr: templates not tested

2015-09-03 Thread Stephan Mueller
Am Donnerstag, 3. September 2015, 15:45:39 schrieb Herbert Xu: Hi Herbert, > It's the same bug as gcm. cbc should use the underlying cra_name > in its cra_name. I see. But then it seems to be a pervasive bug as xts suffers from the same issue too. Would you please be so kind and give me a hin

Re: testmgr: templates not tested

2015-09-03 Thread Herbert Xu
On Thu, Sep 03, 2015 at 04:20:01AM +0200, Stephan Mueller wrote: > > while playing with the testmgr in FIPS mode, I see that ciphers with a > template are not tested even though test vectors exist. > > For example, when allocating cbc(aes-generic) I see records of aes-generic > (aes) being test