lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <f722fd24bef96dc12500eaffb1d1e1f169a6dd9f.camel@intel.com>
Date: Mon, 12 Aug 2024 10:34:55 +0000
From: "Huang, Kai" <kai.huang@...el.com>
To: "Kuvaiskii, Dmitrii" <dmitrii.kuvaiskii@...el.com>
CC: "linux-sgx@...r.kernel.org" <linux-sgx@...r.kernel.org>,
	"dave.hansen@...ux.intel.com" <dave.hansen@...ux.intel.com>,
	"jarkko@...nel.org" <jarkko@...nel.org>, "Chatre, Reinette"
	<reinette.chatre@...el.com>, "linux-kernel@...r.kernel.org"
	<linux-kernel@...r.kernel.org>, "Qin, Kailun" <kailun.qin@...el.com>,
	"haitao.huang@...ux.intel.com" <haitao.huang@...ux.intel.com>,
	"stable@...r.kernel.org" <stable@...r.kernel.org>, "Vij, Mona"
	<mona.vij@...el.com>
Subject: Re: [PATCH v4 3/3] x86/sgx: Resolve EREMOVE page vs EAUG page data
 race

On Mon, 2024-08-12 at 01:32 -0700, Kuvaiskii, Dmitrii wrote:
> On Fri, Aug 09, 2024 at 11:19:22AM +0000, Huang, Kai wrote:
> 
> > > TLDR: I can add similar handling to sgx_enclave_modify_types() if
> > > reviewers insist, but I don't see how this data race can ever be
> > > triggered by benign real-world SGX applications.
> > 
> > So as mentioned above, I intend to suggest to also apply the BUSY flag here.  
> > And we can have a consist rule in the kernel:
> > 
> > If an enclave page is under certainly operation by the kernel with the mapping
> > removed, other threads trying to access that page are temporarily blocked and
> > should retry.
> 
> I agree with your assessment on the consequences of such bug in
> sgx_enclave_modify_types(). To my understanding, this bug can only affect
> the SGX enclave (i.e. the userspace) -- either the SGX enclave will hang
> or will be terminated.
> 
> Anyway, I will apply the BUSY flag also in sgx_enclave_modify_types() in
> the next iteration of this patch series.
> 

Thanks.

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ