From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753164AbdCFMXn (ORCPT ); Mon, 6 Mar 2017 07:23:43 -0500 Received: from merlin.infradead.org ([205.233.59.134]:38342 "EHLO merlin.infradead.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752139AbdCFMXg (ORCPT ); Mon, 6 Mar 2017 07:23:36 -0500 Date: Mon, 6 Mar 2017 13:23:27 +0100 From: Peter Zijlstra To: Dmitry Vyukov Cc: Ingo Molnar , Arnaldo Carvalho de Melo , Alexander Shishkin , LKML , Mathieu Desnoyers , syzkaller Subject: Re: perf: use-after-free in perf_release Message-ID: <20170306122327.GJ6500@twins.programming.kicks-ass.net> References: <20170306121314.GB6515@twins.programming.kicks-ass.net> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.5.23.1 (2014-03-12) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Mon, Mar 06, 2017 at 01:17:42PM +0100, Dmitry Vyukov wrote: > On Mon, Mar 6, 2017 at 1:13 PM, Peter Zijlstra wrote: > > On Mon, Mar 06, 2017 at 10:57:07AM +0100, Dmitry Vyukov wrote: > >> Hello, > >> > >> I've got the following use-after-free report while running syzkaller > >> fuzzer on 86292b33d4b79ee03e2f43ea0381ef85f077c760. Note that the task > >> is freed right in copy_process due to some error, but it's referenced > >> by another thread in perf subsystem. > > > > Weird... you don't happen to have a reproduction case available? > > > Unfortunately no. I've looked at both logs that I have and there are > no memory allocation failures preceding the crash (however maybe > somebody used NOWARN?). But probably if you inject an error into > copy_process somewhere after perf_event_init_task, it should reproduce > the bug with KASAN I think. I'll try. Thanks!