Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753821AbeAGMee (ORCPT + 1 other); Sun, 7 Jan 2018 07:34:34 -0500 Received: from forward2p.cmail.yandex.net ([77.88.31.17]:59011 "EHLO forward2p.cmail.yandex.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752984AbeAGMed (ORCPT ); Sun, 7 Jan 2018 07:34:33 -0500 Authentication-Results: mxback20j.mail.yandex.net; dkim=pass header.i=@yandex.com.tr From: Ozgur Envelope-From: okaratas@yandex.com.tr To: Theodore Ts'o , Avi Kivity Cc: Alan Cox , "linux-kernel@vger.kernel.org" In-Reply-To: <20180107122918.GE2404@thunk.org> References: <20180106200232.67387c5a@alans-desktop> <20180107122918.GE2404@thunk.org> Subject: Re: Proposal: CAP_PAYLOAD to reduce Meltdown and Spectre mitigation costs MIME-Version: 1.0 Message-Id: <341211515328469@web54o.yandex.ru> X-Mailer: Yamail [ http://yandex.ru ] 5.0 Date: Sun, 07 Jan 2018 15:34:29 +0300 Content-Transfer-Encoding: 8bit Content-Type: text/plain; charset=utf-8 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Return-Path: 07.01.2018, 15:29, "Theodore Ts'o" : > On Sun, Jan 07, 2018 at 11:16:28AM +0200, Avi Kivity wrote: >>  I think capabilities will work just as well with cgroups. The container >>  manager will set CAP_PAYLOAD to payload containers; and if those run an init >>  system or a container manager themselves, they'll drop CAP_PAYLOAD for all >>  process/sub-containers but their payloads. > > The reason why cgroups are better is Spectre can be used to steal > information from within the same privilege level --- e.g., you could > use Javascript to steal a user's Coindesk credentials or Lastpass > data, which is going to be *way* more lucrative than trying to mine > cryptocurrency in the sly in a user's browser. :-) I think the web coin mining pages also work with this method they probably use JS in the background but currently, impossible to do kernel-level operations. All process start on the browser level and Spectre not read kernel memory, right? Ozgur > As a result, you probably want Spectre mitigations to be enabled in a > root process --- which means capabilities aren't the right answer. > > Regards, > >                                                 - Ted