Re: [PATCH 4/6] fscrypt: verify that the correct master key was supplied

2017-07-14 Thread Eric Biggers
Hi Jeff, On Fri, Jul 14, 2017 at 01:34:48PM -0400, Jeffrey Walton wrote: > On Wed, Jul 12, 2017 at 5:00 PM, Eric Biggers wrote: > > From: Eric Biggers > > > > > > Solve the problem for v2 encryption policies by storing a "hash" of the > > master encryption key in the encryption xattr and ver

Re: [PATCH 1/6] fscrypt: add v2 encryption context and policy

2017-07-14 Thread Andreas Dilger
On Jul 13, 2017, at 3:58 PM, Eric Biggers wrote: > > Hi Michael, > > On Thu, Jul 13, 2017 at 03:29:44PM -0700, Michael Halcrow wrote: >> On Wed, Jul 12, 2017 at 02:00:30PM -0700, Eric Biggers wrote: >>> From: Eric Biggers >>> >>> Currently, the fscrypt_context (i.e. the encryption xattr) does

Re: [PATCH 4/6] fscrypt: verify that the correct master key was supplied

2017-07-14 Thread Jeffrey Walton
On Wed, Jul 12, 2017 at 5:00 PM, Eric Biggers wrote: > From: Eric Biggers > > > Solve the problem for v2 encryption policies by storing a "hash" of the > master encryption key in the encryption xattr and verifying it before > accepting the user-provided key. > ... Forgive my ignorance... Doe

Re: [PATCH 3/6] fscrypt: use HKDF-SHA512 to derive the per-inode encryption keys

2017-07-14 Thread Michael Halcrow
On Fri, Jul 14, 2017 at 09:24:40AM -0700, Michael Halcrow wrote: > On Wed, Jul 12, 2017 at 02:00:32PM -0700, Eric Biggers wrote: > > From: Eric Biggers > > > > By design, the keys which userspace provides in the keyring are not used > > to encrypt data directly. Instead, a KDF (Key Derivation Fu

Re: [PATCH 4/6] fscrypt: verify that the correct master key was supplied

2017-07-14 Thread Michael Halcrow
On Wed, Jul 12, 2017 at 02:00:33PM -0700, Eric Biggers wrote: > From: Eric Biggers > > Currently, while a fscrypt master key is required to have a certain > description in the keyring, its payload is never verified to be correct. > While sufficient for well-behaved userspace, this is insecure in

Re: [PATCH 3/6] fscrypt: use HKDF-SHA512 to derive the per-inode encryption keys

2017-07-14 Thread Michael Halcrow
On Wed, Jul 12, 2017 at 02:00:32PM -0700, Eric Biggers wrote: > From: Eric Biggers > > By design, the keys which userspace provides in the keyring are not used > to encrypt data directly. Instead, a KDF (Key Derivation Function) is > used to derive a unique encryption key for each inode, given a

Re: [PATCH 3/6] fscrypt: use HKDF-SHA512 to derive the per-inode encryption keys

2017-07-14 Thread Stephan Müller
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 kerne

Re: [PATCH 2/6] fscrypt: rename ->ci_master_key to ->ci_master_key_descriptor

2017-07-14 Thread Michael Halcrow
On Wed, Jul 12, 2017 at 02:00:31PM -0700, Eric Biggers wrote: > From: Eric Biggers > > In struct fscrypt_info, ->ci_master_key is the master key descriptor, > not the master key itself. In preparation for introducing a struct > fscrypt_master_key and making ->ci_master_key point to it, rename th

Re: [PATCH 00/12] staging: ccree: coding style fixes

2017-07-14 Thread Gilad Ben-Yossef
On Fri, Jul 14, 2017 at 2:39 PM, Greg Kroah-Hartman wrote: > On Thu, Jul 13, 2017 at 11:19:50AM +0300, Gilad Ben-Yossef wrote: >> Another batch of ccree coding style fixes. >> >> These goes on top of commit a8c4ae12 ("staging: ccree: Fix alignment issues >> in ssi_sysfs.c") >> in staging-testing.

Crypto Fixes for 4.13

2017-07-14 Thread Herbert Xu
Hi Linus: This push fixes the following issues: - New compiler warnings in cavium. - Set post-op IV properly in caam (this fixes chaining). - Fix potential use-after-free in atmel in case of EBUSY. - Fix sleeping in softirq path in chcr. - Disable buggy sha1-avx2 driver (may overread and page fa

Re: [PATCH 00/12] staging: ccree: coding style fixes

2017-07-14 Thread Greg Kroah-Hartman
On Thu, Jul 13, 2017 at 11:19:50AM +0300, Gilad Ben-Yossef wrote: > Another batch of ccree coding style fixes. > > These goes on top of commit a8c4ae12 ("staging: ccree: Fix alignment issues > in ssi_sysfs.c") > in staging-testing. Odd, some of these did not apply, but others did. Please rebase

Re: [PATCH v2 2/2] crypto: engine - Permit to enqueue skcipher request

2017-07-14 Thread Corentin Labbe
On Fri, Jun 23, 2017 at 02:48:37PM +0800, Herbert Xu wrote: > On Mon, Jun 19, 2017 at 09:55:24AM +0200, Corentin Labbe wrote: > > > > Since there are two different user of "crypto engine + ablkcipher", it will > > be not easy to convert them in one serie. (I could do it, but I simply > > could no