From mboxrd@z Thu Jan 1 00:00:00 1970 From: Ingo Molnar Subject: Re: [PATCH v4 01/29] bluetooth: Switch SMP to crypto_cipher_encrypt_one() Date: Mon, 27 Jun 2016 10:54:03 +0200 Message-ID: <20160627085403.GA26865@gmail.com> References: <264af59a3060c2bc2a725cfc66a8fa68219d1c4a.1466974736.git.luto@kernel.org> <8C5360E3-94EE-4869-B9B9-AF9D41B5A3AC@holtmann.org> Reply-To: kernel-hardening@lists.openwall.com Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Return-path: List-Post: List-Help: List-Unsubscribe: List-Subscribe: Sender: Ingo Molnar Content-Disposition: inline In-Reply-To: <8C5360E3-94EE-4869-B9B9-AF9D41B5A3AC@holtmann.org> To: Marcel Holtmann Cc: Andy Lutomirski , x86@kernel.org, LKML , linux-arch@vger.kernel.org, Borislav Petkov , Nadav Amit , Kees Cook , Brian Gerst , "kernel-hardening@lists.openwall.com" , Linus Torvalds , Josh Poimboeuf , Jann Horn , Heiko Carstens , "Gustavo F. Padovan" , Johan Hedberg , "David S. Miller" , linux-bluetooth@vger.kernel.org, netdev@vger.kernel.org List-Id: linux-arch.vger.kernel.org * Marcel Holtmann wrote: > Hi Andy, > > > SMP does ECB crypto on stack buffers. This is complicated and > > fragile, and it will not work if the stack is virtually allocated. > > > > Switch to the crypto_cipher interface, which is simpler and safer. > > > > Cc: Marcel Holtmann > > Cc: Gustavo Padovan > > Cc: Johan Hedberg > > Cc: "David S. Miller" > > Cc: linux-bluetooth@vger.kernel.org > > Cc: netdev@vger.kernel.org > > Acked-by: Herbert Xu > > Acked-and-tested-by: Johan Hedberg > > Signed-off-by: Andy Lutomirski > > --- > > net/bluetooth/smp.c | 67 ++++++++++++++++++++++------------------------------- > > 1 file changed, 28 insertions(+), 39 deletions(-) > > patch has been applied to bluetooth-next tree. Sadly carrying this separately will delay the virtual kernel stacks feature by a kernel cycle, because it's a must-have prerequisite. Thanks, Ingo From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-wm0-f66.google.com ([74.125.82.66]:35174 "EHLO mail-wm0-f66.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750796AbcF0IyJ (ORCPT ); Mon, 27 Jun 2016 04:54:09 -0400 Date: Mon, 27 Jun 2016 10:54:03 +0200 From: Ingo Molnar Subject: Re: [PATCH v4 01/29] bluetooth: Switch SMP to crypto_cipher_encrypt_one() Message-ID: <20160627085403.GA26865@gmail.com> References: <264af59a3060c2bc2a725cfc66a8fa68219d1c4a.1466974736.git.luto@kernel.org> <8C5360E3-94EE-4869-B9B9-AF9D41B5A3AC@holtmann.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <8C5360E3-94EE-4869-B9B9-AF9D41B5A3AC@holtmann.org> Sender: linux-arch-owner@vger.kernel.org List-ID: To: Marcel Holtmann Cc: Andy Lutomirski , x86@kernel.org, LKML , linux-arch@vger.kernel.org, Borislav Petkov , Nadav Amit , Kees Cook , Brian Gerst , "kernel-hardening@lists.openwall.com" , Linus Torvalds , Josh Poimboeuf , Jann Horn , Heiko Carstens , "Gustavo F. Padovan" , Johan Hedberg , "David S. Miller" , linux-bluetooth@vger.kernel.org, netdev@vger.kernel.org Message-ID: <20160627085403.N3McxJlcsYP4BRHD1SQmF64k77ZZJx8DZk-pJhWpPvk@z> * Marcel Holtmann wrote: > Hi Andy, > > > SMP does ECB crypto on stack buffers. This is complicated and > > fragile, and it will not work if the stack is virtually allocated. > > > > Switch to the crypto_cipher interface, which is simpler and safer. > > > > Cc: Marcel Holtmann > > Cc: Gustavo Padovan > > Cc: Johan Hedberg > > Cc: "David S. Miller" > > Cc: linux-bluetooth@vger.kernel.org > > Cc: netdev@vger.kernel.org > > Acked-by: Herbert Xu > > Acked-and-tested-by: Johan Hedberg > > Signed-off-by: Andy Lutomirski > > --- > > net/bluetooth/smp.c | 67 ++++++++++++++++++++++------------------------------- > > 1 file changed, 28 insertions(+), 39 deletions(-) > > patch has been applied to bluetooth-next tree. Sadly carrying this separately will delay the virtual kernel stacks feature by a kernel cycle, because it's a must-have prerequisite. Thanks, Ingo