From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1946929Ab3BHT1Y (ORCPT ); Fri, 8 Feb 2013 14:27:24 -0500 Received: from ch1ehsobe001.messaging.microsoft.com ([216.32.181.181]:42714 "EHLO ch1outboundpool.messaging.microsoft.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1946782Ab3BHT1W (ORCPT ); Fri, 8 Feb 2013 14:27:22 -0500 X-Forefront-Antispam-Report: CIP:157.56.236.101;KIP:(null);UIP:(null);IPV:NLI;H:BY2PRD0510HT002.namprd05.prod.outlook.com;RD:none;EFVD:NLI X-SpamScore: -4 X-BigFish: PS-4(zz98dI9371I936eI1432Izz1f42h1ee6h1de0h1202h1e76h1d1ah1d2ahzz8275ch177df4h17326ah8275bhz2fh2a8h668h839h93fhd24he5bhf0ah1288h12a5h12a9h12bdh137ah13b6h1441h1504h1537h153bh162dh1631h1758h18e1h1946h19b5h1155h) From: Matthew Garrett To: Kees Cook CC: "linux-kernel@vger.kernel.org" , "H. Peter Anvin" , Thomas Gleixner , Ingo Molnar , "x86@kernel.org" , "linux-efi@vger.kernel.org" , "linux-security-module@vger.kernel.org" Subject: Re: [PATCH] x86: Lock down MSR writing in secure boot Thread-Topic: [PATCH] x86: Lock down MSR writing in secure boot Thread-Index: AQHOBjA7mQsIMlqU/k+EElzc7Yz1iZhwVXyAgAABLICAAAGKgA== Date: Fri, 8 Feb 2013 19:27:09 +0000 Message-ID: <1360351629.18083.15.camel@x230.lan> References: <20130208191213.GA25081@www.outflux.net> <1360351047.18083.14.camel@x230.lan> In-Reply-To: Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-originating-ip: [10.255.84.4] Content-Type: text/plain; charset="utf-8" Content-ID: <1D2B3823B22DE547BEB4061801F001D6@namprd05.prod.outlook.com> MIME-Version: 1.0 X-OriginatorOrg: nebula.com Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Transfer-Encoding: 8bit X-MIME-Autoconverted: from base64 to 8bit by mail.home.local id r18JRNr3005453 On Fri, 2013-02-08 at 11:21 -0800, Kees Cook wrote: > On Fri, Feb 8, 2013 at 11:17 AM, Matthew Garrett > wrote: > > On Fri, 2013-02-08 at 11:12 -0800, Kees Cook wrote: > >> Writing to MSRs should not be allowed unless CAP_COMPROMISE_KERNEL is > >> set since it could lead to execution of arbitrary code in kernel mode. > > > > Willing to buy this, but do you have a description of one potential > > approach? We should probably also figure out what's writing to MSRs at > > the moment (anything other than energy_perf_bias?) and decide what the > > best thing to do there is. > > Yes, change the SYSENTER entry point to where-ever you like. There are > examples already written: > http://grsecurity.net/~spender/msr32.c Cool. Yup, this sounds like a good plan. {.n++%ݶw{.n+{G{ayʇڙ,jfhz_(階ݢj"mG?&~iOzv^m ?I