Re: [PATCH 1/4] crypto: add eboiv as a crypto API template

2020-10-26 Thread Gilad Ben-Yossef
On Mon, Oct 26, 2020 at 8:26 PM Eric Biggers wrote: > > Here's the version of eboiv_create() I recommend (untested): > > static int eboiv_create(struct crypto_template *tmpl, struct rtattr **tb) > { > struct skcipher_instance *inst; > struct eboiv_instance_ctx *ictx; > str

Re: [PATCH 1/4] crypto: add eboiv as a crypto API template

2020-10-26 Thread Eric Biggers
On Mon, Oct 26, 2020 at 11:24:50AM -0700, Eric Biggers wrote: > > +static int eboiv_create(struct crypto_template *tmpl, struct rtattr **tb) > > +{ > > + struct crypto_attr_type *algt; > > + const char *inner_cipher_name; > > + struct skcipher_instance *skcipher_inst = NULL; > > + struct cr

Re: [PATCH 1/4] crypto: add eboiv as a crypto API template

2020-10-26 Thread Eric Biggers
On Mon, Oct 26, 2020 at 03:04:44PM +0200, Gilad Ben-Yossef wrote: > diff --git a/crypto/eboiv.c b/crypto/eboiv.c > new file mode 100644 > index ..467833e89139 > --- /dev/null > +++ b/crypto/eboiv.c > @@ -0,0 +1,295 @@ > +// SPDX-License-Identifier: GPL-2.0 > +/* > + * EBOIV skcipher tem

[PATCH 1/4] crypto: add eboiv as a crypto API template

2020-10-26 Thread Gilad Ben-Yossef
Encrypted byte-offset initialization vector (EBOIV) is an IV generation method that is used in some cases by dm-crypt for supporting the BitLocker volume encryption used by Windows 8 and onwards as a backwards compatible version in lieu of XTS support. Support for eboiv was added to dm-crypt in 5.6