From: Herbert Xu <herbert@gondor.apana.org.au>
To: Ondrej Mosnacek <omosnace@redhat.com>
Cc: Milan Broz <gmazyland@gmail.com>,
linux-crypto@vger.kernel.org, dm-devel@redhat.com,
Mike Snitzer <snitzer@redhat.com>,
Alasdair Kergon <agk@redhat.com>,
Mikulas Patocka <mpatocka@redhat.com>,
Binoy Jayan <binoy.jayan@linaro.org>,
Gilad Ben-Yossef <gilad@benyossef.com>
Subject: Re: dm-crypt IV generation (summary)
Date: Fri, 7 Apr 2017 14:12:26 +0800 [thread overview]
Message-ID: <20170407061226.GA2282@gondor.apana.org.au> (raw)
In-Reply-To: <CAFqZXNs0=6+PvpGq3weRwCJkUOfSn06i_fD6ZuvXo_0rms9zeA@mail.gmail.com>
On Fri, Mar 10, 2017 at 02:44:26PM +0100, Ondrej Mosnacek wrote:
>
> ISSUES:
> a) The 'keycount' parameter.
> In order to support multi-key modes from Loop-AES,
> dm-crypt accepts a keycount parameter which, if it != 1, causes
> consecutive sectors to be encrypted with a different key. This
> parameter can be specified with any of the cipher modes, which makes
> porting the whole scale of modes supported by dm-crypt to crypto API
> rather messy, since a lot of dm-crypt specific stuff needs to be moved
> into the crypto drivers.
Actually I think this one can probably easily handled in the crypto
layer. All we need is to add a multikey template that sits on top
of an underlying IV generator. The multikey instance can then accept
a key length that is a multiple of the underlying key length.
> b) New AEAD functionality; random IV generator.
> The soon-to-be-added AEAD functionality in dm-crypt
> introduces a new IV generator that generates IVs randomly and stores
> them as sector metadata. This means IV generation cannot be handled
> solely in the driver. Also, additional AEAD implementation of IV
> generators would be eventually needed.
Again I don't see the problem here. IV generators are supposed
to return the IV to the caller so that it can be transmitted.
For example, the IV generated in IPsec is explicitly transmitted.
Here we just need to store the IV.
Cheers,
--
Email: Herbert Xu <herbert@gondor.apana.org.au>
Home Page: http://gondor.apana.org.au/~herbert/
PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt
next prev parent reply other threads:[~2017-04-07 6:13 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-03-10 13:44 dm-crypt IV generation (summary) Ondrej Mosnacek
2017-03-13 18:23 ` Mike Snitzer
2017-04-06 9:29 ` Herbert Xu
2017-04-06 14:37 ` Mike Snitzer
2017-04-07 6:12 ` Herbert Xu [this message]
2017-05-18 11:40 ` Ondrej Mosnacek
2017-06-23 8:49 ` Herbert Xu
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20170407061226.GA2282@gondor.apana.org.au \
--to=herbert@gondor.apana.org.au \
--cc=agk@redhat.com \
--cc=binoy.jayan@linaro.org \
--cc=dm-devel@redhat.com \
--cc=gilad@benyossef.com \
--cc=gmazyland@gmail.com \
--cc=linux-crypto@vger.kernel.org \
--cc=mpatocka@redhat.com \
--cc=omosnace@redhat.com \
--cc=snitzer@redhat.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox