From mboxrd@z Thu Jan 1 00:00:00 1970 From: Marc Zyngier Subject: Re: [PATCH 1/2] kvm: whitelist struct kvm_vcpu_arch Date: Thu, 26 Oct 2017 15:34:38 +0100 Message-ID: <86h8umasg1.fsf@arm.com> References: <20171026134547.23664-1-pbonzini@redhat.com> <20171026134547.23664-2-pbonzini@redhat.com> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8BIT Cc: linux-kernel@vger.kernel.org, kvm@vger.kernel.org, Christoffer Dall , Christian Borntraeger , Cornelia Huck , James Hogan , Paul Mackerras , kernel-hardening@lists.openwall.com, Kees Cook , Christian Borntraeger , Christoffer Dall , Radim =?utf-8?B?S3LEjW3DocWZ?= To: Paolo Bonzini Return-path: In-Reply-To: <20171026134547.23664-2-pbonzini@redhat.com> (Paolo Bonzini's message of "Thu, 26 Oct 2017 15:45:46 +0200") Sender: linux-kernel-owner@vger.kernel.org List-Id: kvm.vger.kernel.org On Thu, Oct 26 2017 at 3:45:46 pm BST, Paolo Bonzini wrote: > On x86, ARM and s390, struct kvm_vcpu_arch has a usercopy region > taht is read and written by the KVM_GET/SET_CPUID2 ioctls (x86) > or KVM_GET/SET_ONE_REG (ARM/s390). Without whitelisting the area, > KVM is completely broken on those architectures with usercopy hardening > enabled. > > For now, allow writing to the entire struct on all architectures. > The KVM tree will not refine this to an architecture-specific > subset of struct kvm_vcpu_arch. > > Cc: kernel-hardening@lists.openwall.com > Cc: Kees Cook > Cc: Christian Borntraeger > Cc: Christoffer Dall > Cc: Radim Krčmář > Signed-off-by: Paolo Bonzini Acked-by: Marc Zyngier M. -- Jazz is not dead. It just smells funny.