From: "Stephan Müller" <smueller@chronox.de>
To: Eric Biggers <ebiggers3@gmail.com>
Cc: "Theodore Y . Ts'o" <tytso@mit.edu>,
herbert@gondor.apana.org.au, Eric Biggers <ebiggers@google.com>,
Alex Cope <alexcope@google.com>,
linux-f2fs-devel@lists.sourceforge.net,
linux-fscrypt@vger.kernel.org, linux-mtd@lists.infradead.org,
linux-crypto@vger.kernel.org, linux-fsdevel@vger.kernel.org,
Jaegeuk Kim <jaegeuk@kernel.org>,
linux-ext4@vger.kernel.org
Subject: Re: [PATCH 3/6] fscrypt: use HKDF-SHA512 to derive the per-inode encryption keys
Date: Fri, 14 Jul 2017 17:50:06 +0200 [thread overview]
Message-ID: <6581107.6MsbyqD4B1@positron.chronox.de> (raw)
In-Reply-To: <20170713181057.GA143898@gmail.com>
Am Donnerstag, 13. Juli 2017, 20:10:57 CEST schrieb Eric Biggers:
Hi Eric,
> Hi Stephan,
>
> On Thu, Jul 13, 2017 at 04:54:55PM +0200, Stephan Müller wrote:
> > Am Mittwoch, 12. Juli 2017, 23:00:32 CEST schrieb Eric Biggers:
> >
> > Hi Herbert,
> >
> > This patch adds a second KDF to the kernel -- the first is found in the
> > keys subsystem.
> >
> > The next KDF that may come in is in the TLS scope.
> >
> > Would it make sense to warm up the KDF patches adding generic KDF support
> > to the kernel crypto API that I supplied some time ago? The advantages
> > would be to have one location of KDF implementations and the benefit of
> > the testmgr.
> That may be a good idea. Looking at the old thread, I share Herbert's
> concern (http://www.spinics.net/lists/linux-crypto/msg21231.html) about
> there likely not being more than one implementation of each KDF algorithm.
> So, perhaps some simple helper functions would be more appropriate.
> However, making the KDFs be covered by self-tests would be very nice.
I agree that it is likely that specific KDF implementations may only be used
once. But still, I would recommend to maintain those implementation under the
crypto API umbrella, as KDFs are cryptographic operations.
>
> Also, it seems your patch
> (http://www.spinics.net/lists/linux-crypto/msg21137.html) doesn't allow a
> salt to be passed in. In order to fully support HKDF, crypto_rng_reset()
> (which as I understand would be the way to invoke the "extract" step) would
> somehow need to accept both the input keying material and salt, both of
> which are arbitrary length binary.
I concur with you. I have implemented the HKDF in my libkcapi as well and saw
the need for a salt.
Let me work on an update to the KDF patch for the kernel crypto API.
Ciao
Stephan
------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
next prev parent reply other threads:[~2017-07-14 15:50 UTC|newest]
Thread overview: 25+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-07-12 21:00 [PATCH 0/6] fscrypt: key verification and KDF improvement Eric Biggers
2017-07-12 21:00 ` [PATCH 1/6] fscrypt: add v2 encryption context and policy Eric Biggers
2017-07-13 22:29 ` Michael Halcrow
2017-07-13 22:58 ` Eric Biggers
2017-07-14 20:08 ` Andreas Dilger
2017-07-12 21:00 ` [PATCH 2/6] fscrypt: rename ->ci_master_key to ->ci_master_key_descriptor Eric Biggers
2017-07-14 15:36 ` Michael Halcrow
2017-07-12 21:00 ` [PATCH 3/6] fscrypt: use HKDF-SHA512 to derive the per-inode encryption keys Eric Biggers
2017-07-13 14:54 ` Stephan Müller
2017-07-13 16:07 ` Herbert Xu
2017-07-13 16:18 ` Stephan Müller
2017-07-13 18:10 ` Eric Biggers
2017-07-14 15:50 ` Stephan Müller [this message]
2017-07-14 16:24 ` Michael Halcrow
2017-07-14 17:11 ` Michael Halcrow
2017-07-19 17:32 ` Eric Biggers
2017-07-12 21:00 ` [PATCH 4/6] fscrypt: verify that the correct master key was supplied Eric Biggers
2017-07-14 16:40 ` Michael Halcrow via Linux-f2fs-devel
2017-07-14 17:34 ` Jeffrey Walton
2017-07-15 0:52 ` Eric Biggers
2017-07-12 21:00 ` [PATCH 5/6] fscrypt: cache the HMAC transform for each master key Eric Biggers
2017-07-17 17:45 ` Michael Halcrow
2017-07-19 17:37 ` Eric Biggers
2017-07-12 21:00 ` [PATCH 6/6] fscrypt: for v2 policies, support "fscrypt:" key prefix only Eric Biggers
2017-07-17 17:54 ` Michael Halcrow
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=6581107.6MsbyqD4B1@positron.chronox.de \
--to=smueller@chronox.de \
--cc=alexcope@google.com \
--cc=ebiggers3@gmail.com \
--cc=ebiggers@google.com \
--cc=herbert@gondor.apana.org.au \
--cc=jaegeuk@kernel.org \
--cc=linux-crypto@vger.kernel.org \
--cc=linux-ext4@vger.kernel.org \
--cc=linux-f2fs-devel@lists.sourceforge.net \
--cc=linux-fscrypt@vger.kernel.org \
--cc=linux-fsdevel@vger.kernel.org \
--cc=linux-mtd@lists.infradead.org \
--cc=tytso@mit.edu \
/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;
as well as URLs for NNTP newsgroup(s).