Follow @Openwall on Twitter for new release announcements and other news
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date: Fri, 19 Jun 2020 22:13:25 -0700
From: Andy Lutomirski <>
To: John Andersen <>
Cc: Jonathan Corbet <>, Paolo Bonzini <>, 
	Thomas Gleixner <>, Ingo Molnar <>, Borislav Petkov <>, 
	X86 ML <>, "H. Peter Anvin" <>, Shuah Khan <>, 
	"Christopherson, Sean J" <>, Liran Alon <>, 
	Andrew Jones <>, Rick Edgecombe <>, 
	Kristen Carlson Accardi <>, Vitaly Kuznetsov <>, 
	Wanpeng Li <>, Jim Mattson <>, 
	Joerg Roedel <>,, 
	Greg KH <>, "Paul E. McKenney" <>,, Juergen Gross <>, 
	Mike Kravetz <>, Oliver Neukum <>, 
	Andrew Lutomirski <>, Peter Zijlstra <>, 
	Fenghua Yu <>,,, Dave Hansen <>, 
	Arjan van de Ven <>,, 
	Baoquan He <>, Arvind Sankar <>, 
	Kees Cook <>, Dan Williams <>,,, Peter Xu <>,, 
	"open list:DOCUMENTATION" <>, LKML <>, 
	kvm list <>, 
	Kernel Hardening <>
Subject: Re: [PATCH 4/4] X86: Use KVM CR pin MSRs

On Wed, Jun 17, 2020 at 12:05 PM John Andersen
<> wrote:
> Guests using the kexec system call currently do not support
> paravirtualized control register pinning. This is due to early boot
> code writing known good values to control registers, these values do
> not contain the protected bits. This is due to CPU feature
> identification being done at a later time, when the kernel properly
> checks if it can enable protections. As such, the pv_cr_pin command line
> option has been added which instructs the kernel to disable kexec in
> favor of enabling paravirtualized control register pinning. crashkernel
> is also disabled when the pv_cr_pin parameter is specified due to its
> reliance on kexec.

Is there a plan for fixing this for real?  I'm wondering if there is a
sane weakening of this feature that still allows things like kexec.

What happens if a guest tries to reset?  For that matter, what happens
when a guest vCPU sends SIPI to another guest vCPU?  The target CPU
starts up in real mode, right?  There's no SMEP or SMAP in real mode,
and real mode has basically no security mitigations at all.

PCID is an odd case.  I see no good reason to pin it, and pinning PCID
on prevents use of 32-bit mode.

Powered by blists - more mailing lists

Confused about mailing lists and their use? Read about mailing lists on Wikipedia and check out these guidelines on proper formatting of your messages.