Re: [PATCH 4/4] selftests/exec: add test for HWCAP inheritance
From: Kees Cook
Date: Thu Feb 12 2026 - 18:57:35 EST
On Mon, Feb 09, 2026 at 07:06:05PM +0000, Andrei Vagin wrote:
> Verify that HWCAPs are correctly inherited/preserved across execve() when
> modified via prctl(PR_SET_MM_AUXV).
>
> The test performs the following steps:
> * reads the current AUXV using prctl(PR_GET_AUXV);
> * finds an HWCAP entry and toggles its most significant bit;
> * replaces the AUXV of the current process with the modified one using
> prctl(PR_SET_MM, PR_SET_MM_AUXV);
> * executes itself to verify that the new program sees the modified HWCAP
> value.
>
> Signed-off-by: Andrei Vagin <avagin@xxxxxxxxxx>
Reviewed-by: Kees Cook <kees@xxxxxxxxxx>
--
Kees Cook