From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1031534Ab2CVXqh (ORCPT ); Thu, 22 Mar 2012 19:46:37 -0400 Received: from www.linutronix.de ([62.245.132.108]:42850 "EHLO Galois.linutronix.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1758440Ab2CVXqf (ORCPT ); Thu, 22 Mar 2012 19:46:35 -0400 Date: Fri, 23 Mar 2012 00:46:27 +0100 (CET) From: Thomas Gleixner To: Ingo Molnar cc: Kees Cook , Serge Hallyn , LKML , Darren Hart , Peter Zijlstra , Andrew Morton , Jiri Kosina , "Eric W. Biederman" , David Howells , kernel-hardening@lists.openwall.com, spender@grsecurity.net Subject: Re: [PATCH] futex: do not leak robust list to unprivileged process In-Reply-To: <20120320172300.GA8888@gmail.com> Message-ID: References: <20120319231253.GA20893@www.outflux.net> <20120320133141.GC2918@peqn> <20120320172300.GA8888@gmail.com> User-Agent: Alpine 2.02 (LFD 1266 2009-07-14) MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII X-Linutronix-Spam-Score: -1.0 X-Linutronix-Spam-Level: - X-Linutronix-Spam-Status: No , -1.0 points, 5.0 required, ALL_TRUSTED=-1,SHORTCIRCUIT=-0.0001 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue, 20 Mar 2012, Ingo Molnar wrote: > * Kees Cook wrote: > > On Tue, Mar 20, 2012 at 10:02 AM, Thomas Gleixner wrote: > > > I really wonder why we have this syscall at all. > > > > The documentation I found yesterday while looking at this was: > > http://linux.die.net/man/2/get_robust_list > > > > Which says "The system call is only available for debugging > > purposes and is not needed for normal operations. Both system > > calls are not available to application programs as functions; > > they can be called using the syscall(3) function." > > > > Dropping the syscall entirely would certainly make it secure. > > ;) > > The thinking was API completeness. In general it's possible for > a sufficiently privileged task to figure out all the state of a > task. We can query timers, fds - the robust list is such a > resource as well. The information leakage was obviously not > intended. So I think it's safe to take Kees' patch as is. On top of that we should add a WARN_ONCE when the syscall is invoked and schedule the sucker for removal. Thoughts ? tglx