From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753399AbbCEXHv (ORCPT ); Thu, 5 Mar 2015 18:07:51 -0500 Received: from mail-lb0-f181.google.com ([209.85.217.181]:37573 "EHLO mail-lb0-f181.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750914AbbCEXHs (ORCPT ); Thu, 5 Mar 2015 18:07:48 -0500 MIME-Version: 1.0 In-Reply-To: References: <20150301233359.GA22196@mail.hallyn.com> <20150305171326.GA14998@mail.hallyn.com> From: Andy Lutomirski Date: Thu, 5 Mar 2015 15:07:26 -0800 Message-ID: Subject: Re: [PATCH] capabilities: Ambient capability set V2 To: Christoph Lameter Cc: Jarkko Sakkinen , Andrew Morton , LSM List , "Andrew G. Morgan" , Michael Kerrisk , Mimi Zohar , "linux-kernel@vger.kernel.org" , Austin S Hemmelgarn , Aaron Jones , Serge Hallyn , "Serge E. Hallyn" , Markku Savela , Linux API , Jonathan Corbet Content-Type: text/plain; charset=UTF-8 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Mar 5, 2015 10:41 AM, "Christoph Lameter" wrote: > > On Thu, 5 Mar 2015, Serge E. Hallyn wrote: > > > > > > > > > So I'd say drop this change ^ > > > > > > Then the ambient caps get ignored for a executables that have capabilities > > > seton the file? > > > > Yes. Those are assumed to already know what they're doing. > > Do they? What if there is a LD_PRELOAD library that redirects socket calls > and that needs raw device access (there are actually a number of software > packages like that to reduce the latency of network I/O. See for example > Solarflare's software products and the current rsocket libary in OFED. > There are cap issues if the rsocket library should be made useful for > Ethernet instead of infiniband). > > > Why? Do you foresee cases where a file that has fP set needs capabilities > > that aren't in its fP? > > Yes due to the library issues. You can't LD_PRELOAD and fP together. And I'm still unconvinced that ambient caps can ever be safe in conjunction with fP. I'll grill you next week on what you're trying to do that makes you want this :) --Andy > > > It seems more likely that they'll risk misbehaving due to an unexpected set > > of caps. > > The userspace driver code in the library wont work since it does not have > the caps to access the raw device registers.