Linux cryptographic layer development
 help / color / mirror / Atom feed
* [PATCH v2 0/4]  crypto: switch to crypto API for ESSIV generation
@ 2019-06-18 21:27 Ard Biesheuvel
  2019-06-18 21:27 ` [PATCH v2 1/4] crypto: essiv - create wrapper template " Ard Biesheuvel
                   ` (4 more replies)
  0 siblings, 5 replies; 17+ messages in thread
From: Ard Biesheuvel @ 2019-06-18 21:27 UTC (permalink / raw)
  To: linux-crypto
  Cc: Ard Biesheuvel, Herbert Xu, Eric Biggers, dm-devel, linux-fscrypt,
	Gilad Ben-Yossef, Milan Broz

This series creates an ESSIV template that produces a skcipher or AEAD
transform based on a tuple of the form '<skcipher>,<cipher>,<shash>'
(or '<aead>,<cipher>,<shash>' for the AEAD case). It exposes the
encapsulated sync or async skcipher/aead by passing through all operations,
while using the cipher/shash pair to transform the input IV into an ESSIV
output IV.

This matches what both users of ESSIV in the kernel do, and so it is proposed
as a replacement for those, in patches #2 and #4.

This code has been tested using the fscrypt test suggested by Eric
(generic/549), as well as the mode-test script suggested by Milan for
the dm-crypt case. I also tested the aead case in a virtual machine,
but it definitely needs some wider testing from the dm-crypt experts.

Cc: Herbert Xu <herbert@gondor.apana.org.au>
Cc: Eric Biggers <ebiggers@google.com>
Cc: dm-devel@redhat.com
Cc: linux-fscrypt@vger.kernel.org
Cc: Gilad Ben-Yossef <gilad@benyossef.com>
Cc: Milan Broz <gmazyland@gmail.com>

Ard Biesheuvel (4):
  crypto: essiv - create wrapper template for ESSIV generation
  fs: crypto: invoke crypto API for ESSIV handling
  md: dm-crypt: infer ESSIV block cipher from cipher string directly
  md: dm-crypt: switch to ESSIV crypto API template

 crypto/Kconfig              |   4 +
 crypto/Makefile             |   1 +
 crypto/essiv.c              | 624 ++++++++++++++++++++
 drivers/md/Kconfig          |   1 +
 drivers/md/dm-crypt.c       | 237 ++------
 fs/crypto/Kconfig           |   1 +
 fs/crypto/crypto.c          |   5 -
 fs/crypto/fscrypt_private.h |   9 -
 fs/crypto/keyinfo.c         |  88 +--
 9 files changed, 675 insertions(+), 295 deletions(-)
 create mode 100644 crypto/essiv.c

-- 
2.17.1


^ permalink raw reply	[flat|nested] 17+ messages in thread

end of thread, other threads:[~2019-06-19 15:45 UTC | newest]

Thread overview: 17+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2019-06-18 21:27 [PATCH v2 0/4] crypto: switch to crypto API for ESSIV generation Ard Biesheuvel
2019-06-18 21:27 ` [PATCH v2 1/4] crypto: essiv - create wrapper template " Ard Biesheuvel
2019-06-19 15:18   ` Ondrej Mosnáček
2019-06-19 15:45     ` Ard Biesheuvel
2019-06-18 21:27 ` [PATCH v2 2/4] fs: crypto: invoke crypto API for ESSIV handling Ard Biesheuvel
2019-06-18 21:27 ` [PATCH v2 3/4] md: dm-crypt: infer ESSIV block cipher from cipher string directly Ard Biesheuvel
2019-06-18 21:27 ` [PATCH v2 4/4] md: dm-crypt: switch to ESSIV crypto API template Ard Biesheuvel
2019-06-19  6:56 ` [PATCH v2 0/4] crypto: switch to crypto API for ESSIV generation Milan Broz
2019-06-19  7:11   ` Ard Biesheuvel
2019-06-19  9:14     ` Ard Biesheuvel
2019-06-19 11:01       ` Milan Broz
2019-06-19 11:16         ` Ard Biesheuvel
2019-06-19 11:33           ` Milan Broz
2019-06-19 12:36             ` Ard Biesheuvel
2019-06-19 12:49               ` Ard Biesheuvel
2019-06-19 13:08                 ` Milan Broz
2019-06-19 13:13                 ` Ard Biesheuvel

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox