Received: by 10.223.176.46 with SMTP id f43csp977529wra; Fri, 26 Jan 2018 09:48:20 -0800 (PST) X-Google-Smtp-Source: AH8x225D1ApKGS4XHLAFQcjbVNPigDQvRTsgDMlA2FipjT8tm4AWuPv89ychBJO7q1P0nNCj5bW4 X-Received: by 2002:a17:902:8ec4:: with SMTP id x4-v6mr14426100plo.271.1516988900300; Fri, 26 Jan 2018 09:48:20 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1516988900; cv=none; d=google.com; s=arc-20160816; b=yNl6wo84wQApTTcTFIBLvmTqosYrKnjdgOogptB2wohwbi5yBQ6nVBs2sHxW9JYu6N DfqtmL+NpJMtfODEFr98U8WgN/+OhB7rqKIRabSkKL2qKMOVl1i6rmluV+EOme2D9PVG KuvVDML/XHbRMLxpnEYd0+Y/Md1z32YRSKkPdGEeVyzbTUaUkarT5VIafw0vz2b6VY/D mUrXCmUAdrxSN6qznoF48Dc+oClqmSog8y+EgG0cqShRhBrquVfIY0Y6FFE8ltsIfBiy N821rlhcg4J7VdKg9vVsz/go1F/7rGTEMEzUPm0SbQID0kn7AuacsRtYJIrhyPZd32yM cyxA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:cc:to:subject:message-id:date:from :references:in-reply-to:mime-version:dkim-signature :arc-authentication-results; bh=m6fmBCGDFigrBZN5FQrDIpUpP4TZrNQ9H0rOJqSw14g=; b=Y2v3dO0mdRLE23Q3mFBIZqIw2QdFK6wtcA5R1T/BwJqaeGC8XrOR8ZeSoko31Mb1Rp GeCDUPthnXJ854coEVpRcHmUia6JQY9SruJAhQ13c/9IvChuj/H/Pgp6ZrXk2ecDew2Q nAi8zIG1cqUZY1vuh5GIzhuK2P/icHujq8hfcS/BkelUvvEeWOJXVs9JztVrNwnwyCkG Jq4FbCF3da7lkzMLQKX5qMyQg1a0lDtjhgJ2SweBugWnBEbS70rN1I63uzdgssy9EVky /zlEo6916OB3HHQ0BGz4GOvUbZexXckBpT+VIVtMG1jrRYrNKbYxRMoM+gOf2toVSz8S 3WeQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@zx2c4.com header.s=mail header.b=cwW85Mkk; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=zx2c4.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id f64-v6si3961295plb.817.2018.01.26.09.48.06; Fri, 26 Jan 2018 09:48:20 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@zx2c4.com header.s=mail header.b=cwW85Mkk; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=zx2c4.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751969AbeAZRrd (ORCPT + 99 others); Fri, 26 Jan 2018 12:47:33 -0500 Received: from frisell.zx2c4.com ([192.95.5.64]:41061 "EHLO frisell.zx2c4.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751398AbeAZRrc (ORCPT ); Fri, 26 Jan 2018 12:47:32 -0500 Received: by frisell.zx2c4.com (ZX2C4 Mail Server) with ESMTP id 585711f1 for ; Fri, 26 Jan 2018 17:34:10 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=zx2c4.com; h=mime-version :in-reply-to:references:from:date:message-id:subject:to:cc :content-type; s=mail; bh=s0dRBxDIJvlsDD7H88SYcKatyLQ=; b=cwW85M kk7uZnS54CLFQdyN/jVHpdxNNhTqPRL9m2wUsKFuM4h69cXJLxreinBo7L8wMh3x 555tfdwe1rrHx64yWusjzgOZcTJxI4QQu/j5uIBfZKaaKlC0RoA9bR0/HKfOCV2h m0RnFuolsQGLBLv/v0yifvNhpwL0jXZtFZNB7G7X3ALDnAO0o0CTvKw0Vhc1M3tu TgyVwfhPvXt41bPL4IOYG115/I8Arxm0qHcx4wFaZrLwIedn8SZ9uxqvgcjZTZKP fwprz62WMwLoYjLRHU6sylhKPgi1iuYJkukpV/rojx4pKnUihpHOG/SFTtyEo2KC HrYhFuxVGthTcBXQ== Received: by frisell.zx2c4.com (ZX2C4 Mail Server) with ESMTPSA id 85d07bfa (TLSv1.2:ECDHE-RSA-AES128-GCM-SHA256:128:NO) for ; Fri, 26 Jan 2018 17:34:09 +0000 (UTC) Received: by mail-oi0-f54.google.com with SMTP id a184so831581oif.7 for ; Fri, 26 Jan 2018 09:47:30 -0800 (PST) X-Gm-Message-State: AKwxyte7Yp4v2hhvQ8veJwDSTggVfANjhNicMsJbFyA2cKANOOHd0DKO J1gRm1HlOdvMo7Ic6D+QewE7W5ONQKCdN1P6b6k= X-Received: by 10.202.80.200 with SMTP id e191mr12291702oib.333.1516988848780; Fri, 26 Jan 2018 09:47:28 -0800 (PST) MIME-Version: 1.0 Received: by 10.74.140.12 with HTTP; Fri, 26 Jan 2018 09:47:28 -0800 (PST) In-Reply-To: <20180126164310.13a29ad2@alans-desktop> References: <20180126123158.9575-1-Jason@zx2c4.com> <20180126164310.13a29ad2@alans-desktop> From: "Jason A. Donenfeld" Date: Fri, 26 Jan 2018 18:47:28 +0100 X-Gmail-Original-Message-ID: Message-ID: Subject: Re: [kernel-hardening] Re: [PATCH v2] cpu: do not leak vulnerabilities to unprivileged users To: Alan Cox Cc: Greg Kroah-Hartman , LKML , kernel-hardening@lists.openwall.com Content-Type: text/plain; charset="UTF-8" Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Fri, Jan 26, 2018 at 5:43 PM, Alan Cox wrote: > a) The info is already trivially accessible via /proc/cpuinfo No, /proc/cpuinfo shows if the CPU itself has these bugs, but doesn't show whether or not the kernel has gone to lengths to mitigate these bugs. # grep -o 'bugs.*cpu_meltdown' -m1 /proc/cpuinfo bugs : cpu_meltdown # cat /sys/devices/system/cpu/vulnerabilities/meltdown Mitigation: PTI > or by measurement to an attacker Right, so without this, an attacker has to measure. The purpose of this patchset is to require the attacker to perform an additional measurement. That seems worthwhile, especially if measurements are or would ever become non-trivial to make. > b) Some JIT and other environments need to know Shouldn't JITs do the best they can with the environment they're in? And for that, isn't /proc/cpuinfo enough? Jason