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: <202507281805.14457D3EAF@keescook>
Date: Mon, 28 Jul 2025 18:07:42 -0700
From: Kees Cook <kees@...nel.org>
To: Johannes Nixdorf <johannes@...dorf.dev>
Cc: Andy Lutomirski <luto@...capital.net>, Will Drewry <wad@...omium.org>,
	Sargun Dhillon <sargun@...gun.me>, Shuah Khan <shuah@...nel.org>,
	linux-kernel@...r.kernel.org, Ali Polatel <alip@...sswob.org>,
	linux-kselftest@...r.kernel.org, bpf@...r.kernel.org
Subject: Re: [PATCH v2 2/2] selftests/seccomp: Add a test for the
 WAIT_KILLABLE_RECV fast reply race

On Fri, Jul 25, 2025 at 06:31:19PM +0200, Johannes Nixdorf wrote:
> +		struct itimerval timer = {
> +			.it_value = { .tv_usec = 1000 },
> +			.it_interval = { .tv_usec = 1000 },
> +		};

To get this to build, I needed to add a sys/time.h include:

diff --git a/tools/testing/selftests/seccomp/seccomp_bpf.c b/tools/testing/selftests/seccomp/seccomp_bpf.c
index b24d0cbe88b4..fc4910d35342 100644
--- a/tools/testing/selftests/seccomp/seccomp_bpf.c
+++ b/tools/testing/selftests/seccomp/seccomp_bpf.c
@@ -24,6 +24,7 @@
 #include <linux/filter.h>
 #include <sys/prctl.h>
 #include <sys/ptrace.h>
+#include <sys/time.h>
 #include <sys/user.h>
 #include <linux/prctl.h>
 #include <linux/ptrace.h>

But, with that, yes, I can confirm the race and the fix. Thank you!
I can fix that up locally.

-Kees

-- 
Kees Cook

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ