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: <ZtbRA6SUWjo-WTO2@arm.com>
Date: Tue, 3 Sep 2024 10:04:03 +0100
From: Yury Khrustalev <yury.khrustalev@....com>
To: Mark Brown <broonie@...nel.org>
CC: <Szabolcs.Nagy@....com>, <akpm@...ux-foundation.org>,
	<aou@...s.berkeley.edu>, <ardb@...nel.org>, <arnd@...db.de>,
	<brauner@...nel.org>, <catalin.marinas@....com>, <corbet@....net>,
	<debug@...osinc.com>, <ebiederm@...ssion.com>, <fweimer@...hat.com>,
	<hjl.tools@...il.com>, <james.morse@....com>, <kees@...nel.org>,
	<kvmarm@...ts.linux.dev>, <linux-arch@...r.kernel.org>,
	<linux-arm-kernel@...ts.infradead.org>, <linux-doc@...r.kernel.org>,
	<linux-fsdevel@...r.kernel.org>, <linux-kernel@...r.kernel.org>,
	<linux-kselftest@...r.kernel.org>, <linux-mm@...ck.org>,
	<linux-riscv@...ts.infradead.org>, <maz@...nel.org>, <oleg@...hat.com>,
	<oliver.upton@...ux.dev>, <palmer@...belt.com>, <paul.walmsley@...ive.com>,
	<rick.p.edgecombe@...el.com>, <ross.burton@....com>, <shuah@...nel.org>,
	<suzuki.poulose@....com>, <thiago.bauermann@...aro.org>,
	<wilco.dijkstra@....com>, <will@...nel.org>, <yury.khrustalev@....com>
Subject: Re: [PATCH v12 21/39] arm64/gcs: Ensure that new threads have a GCS

On Thu, Aug 29, 2024 at 12:27:37AM +0100, Mark Brown wrote:
> When a new thread is created by a thread with GCS enabled the GCS needs
> to be specified along with the regular stack.
> 
> Unfortunately plain clone() is not extensible and existing clone3()
> users will not specify a stack so all existing code would be broken if
> we mandated specifying the stack explicitly.  For compatibility with
> these cases and also x86 (which did not initially implement clone3()
> support for shadow stacks) if no GCS is specified we will allocate one
> so when a thread is created which has GCS enabled allocate one for it.
> We follow the extensively discussed x86 implementation and allocate
> min(RLIMIT_STACK, 2G).  Since the GCS only stores the call stack and not
> any variables this should be more than sufficient for most applications.
> 
> GCSs allocated via this mechanism will be freed when the thread exits.
> 
> Reviewed-by: Catalin Marinas <catalin.marinas@....com>
> Reviewed-by: Thiago Jung Bauermann <thiago.bauermann@...aro.org>
> Signed-off-by: Mark Brown <broonie@...nel.org>

Acked-by: Yury Khrustalev <yury.khrustalev@....com>


Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ