From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752838AbdLKTGT (ORCPT ); Mon, 11 Dec 2017 14:06:19 -0500 Received: from mail-it0-f41.google.com ([209.85.214.41]:37712 "EHLO mail-it0-f41.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752650AbdLKTGN (ORCPT ); Mon, 11 Dec 2017 14:06:13 -0500 X-Google-Smtp-Source: ACJfBosL7Ms1XsoPg5z/7ZPZjFluC/NY59BS/JsJS8SRg3v/RKODYDzBptPZ1bUjbQwz7Sq2e1KvjA== Date: Mon, 11 Dec 2017 11:06:09 -0800 From: Eric Biggers To: syzbot Cc: davem@davemloft.net, herbert@gondor.apana.org.au, linux-crypto@vger.kernel.org, linux-kernel@vger.kernel.org, syzkaller-bugs@googlegroups.com Subject: Re: general protection fault in crypto_chacha20_crypt Message-ID: <20171211190609.GC62691@gmail.com> References: <001a113fae28149757055f0bbe00@google.com> <20171129092438.GC20992@zzz.localdomain> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20171129092438.GC20992@zzz.localdomain> User-Agent: Mutt/1.5.21 (2010-09-15) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed, Nov 29, 2017 at 01:24:38AM -0800, Eric Biggers wrote: > > The bug is that the skcipher_walk API doesn't set the IV for zero-length inputs, > while some algorithms (e.g. ChaCha20) access the IV even if the input is > zero-length. So it was dereferencing a pointer which came from uninitialized > stack memory. I've sent out a fix: > > "crypto: skcipher - set walk.iv for zero-length inputs" > #syz fix: crypto: skcipher - set walk.iv for zero-length inputs