From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753706AbcFTXtc (ORCPT ); Mon, 20 Jun 2016 19:49:32 -0400 Received: from imap.thunk.org ([74.207.234.97]:48522 "EHLO imap.thunk.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1754306AbcFTXsl (ORCPT ); Mon, 20 Jun 2016 19:48:41 -0400 Date: Mon, 20 Jun 2016 19:48:19 -0400 From: "Theodore Ts'o" To: Stephan Mueller Cc: Herbert Xu , Linux Kernel Developers List , linux-crypto@vger.kernel.org, andi@firstfloor.org, sandyinchina@gmail.com, jsd@av8n.com, hpa@zytor.com Subject: Re: [PATCH 5/7] random: replace non-blocking pool with a Chacha20-based CRNG Message-ID: <20160620234819.GF9848@thunk.org> Mail-Followup-To: Theodore Ts'o , Stephan Mueller , Herbert Xu , Linux Kernel Developers List , linux-crypto@vger.kernel.org, andi@firstfloor.org, sandyinchina@gmail.com, jsd@av8n.com, hpa@zytor.com References: <1465832919-11316-1-git-send-email-tytso@mit.edu> <20160620051917.GA8719@gondor.apana.org.au> <20160620150147.GD9848@thunk.org> <2101992.L9gKN5cFdv@tauon.atsec.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <2101992.L9gKN5cFdv@tauon.atsec.com> User-Agent: Mutt/1.6.0 (2016-04-01) X-SA-Exim-Connect-IP: X-SA-Exim-Mail-From: tytso@thunk.org X-SA-Exim-Scanned: No (on imap.thunk.org); SAEximRunCond expanded to false Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Mon, Jun 20, 2016 at 05:49:17PM +0200, Stephan Mueller wrote: > > Is speed everything we should care about? What about: > > - offloading of crypto operation from the CPU In practice CPU offland is not helpful, and in fact, in most cases is harmful, when one is only encrypting a tiny amount of data. That's because the cost of setup and teardown, not to mention key scheduling, dominate. This is less of the case in the case of the SIMD / AVX optimizations --- but that's because these are CPU instructions, and there really isn't any CPU offloading going on. > - potentially additional security features a hardware cipher may provide like > cache coloring attack resistance? Um.... have you even taken a *look* at how ChaCha20 is implemented? *What* cache coloring attack is possible at all, period? Hint: where are the lookup tables? Where are the data-dependent memory accesses in the ChaCha20 core? - Ted