From mboxrd@z Thu Jan 1 00:00:00 1970 Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.remote-ip=100.103.45.18 ARC-Seal: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; cv=none; t=1796049830; b=YcvO+kNEh/h5XKGT2xqEsUhdO0jUBLvSwKrqqF6KcNURoDjFVrRdWwcUvbu3UDS4oFX3 ggrlHkCyCDYT1Hos4K6kLnoGocpVFVLQNFwwYAq37zdCm/P4yNI8v5a/104sFEvVnw1Pz XsJlJ2oWWt7rmRvV1BlKF9mj/TXNEe5NvzVPb82oeDXm2DkHICziQsozAhmUHFTFwanHS FYtirb6cVXobGZ2NuZQMd7RrFJ2siLNLyPNuWdZpW50dHJeoLqYbMJJKOjrNufHDSalVm juHukS+xAaF/M5KUjk4C4Ar4RU8YB/819sF+UUuZ+MyLuBIkh9YyBv7URwjOEJDoBLA== ARC-Message-Signature: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; c=relaxed/relaxed; t=1796049830; h=Received:DKIM-Signature:Message-ID:From:Subject:Reply-To:Cc: In-Reply-To:References:Content-Type:Content-Transfer-Encoding:Date; bh=jb8+WQcVclXTrpfRfGlQlh7OKRB8q5lohKwZiXeYMYo=; b=rqtKbdQljVLxT536mEGQjhmjLmb5pWxrDxJKdOsgowjSWXy45RDiDMbjRFi1olb5faGi Zf2xH+F2UfVKm3zo6grw87iPEus+5kM1IB01ZPVjv/WuEGqG6y8riyWP3bSJECmFN00UM eK+Cu6pPwKKJgXOtpvAh/ta2XxxUVQ/GWD+Uc600qS0RgsWsWKftXyVWNrXhZf8ZuVoYJ KDgIBhS32E6RU3su36R3Lw4yHJ4WVj9MfksxKCGD95u0r7S4CRBXCVWUPc0QtNlOa3Hn8 ZKUPn31ca6KxqqIM1UkcHYkNwJWwpicIWUF5vVCrsq1OohqW/v5ZN07PRgV/85rUGiA== ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dkim=pass header.d=kernel.org header.i=@kernel.org header.a=rsa-sha256 header.s=k20260515 header.b=Payh22E8; arc=none smtp.remote-ip=100.103.45.18 Received: from smtp.kernel.org (quasi.space.kernel.org [100.103.45.18]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (prime256v1) server-digest SHA256) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id D6C21606A325 for ; Mon, 30 Nov 2026 14:43:50 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.a=rsa-sha256 header.s=k20260515 header.b=Payh22E8 Received: by smtp.kernel.org (Postfix) with ESMTPSA id 37E9B1F000C1 for ; Mon, 30 Nov 2026 14:43:50 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=kernel.org; s=k20260515; t=1796049830; bh=jb8+WQcVclXTrpfRfGlQlh7OKRB8q5lohKwZiXeYMYo=; h=From:Subject:Reply-To:Cc:In-Reply-To:References:Date; b=Payh22E8sh4eBaY8uV46tyxn1JhDPugHyj01pfvYTuZFRT5HHd5C6ASvXHv06JZpF xlBhvLEA+ZqOKF/Oh5T8FFBtXJVATh2qN+YQpOH5qcPTDcA/DAi9cGJjSdU+7YivIM T6IPaBAaBrehlo6nsxPZ3AhKWBiTG1VaSGLmHOn7VqpzmffO4huKB6UWUNFmizWIpi iQGzhTmwkJ1JZYz+ygeF8FqvuEQlSB66YNNgiTO2V60fynbFLqvlPQ5Hss5vl9+jJ2 PvC47g/RrQkm6HxENYjwhn2OK75H6qe+iI8hb9p1EyZP+PDBW7GpJFQr046I5586y4 qSMUfcGAuHbMw== Message-ID: From: sashiko-bot@kernel.org Subject: Re: [PATCH v2] landlock: Do not hold exec_update_lock across the TSYNC wait Reply-To: sashiko-reviews@lists.linux.dev Cc: linux-security-module@vger.kernel.org In-Reply-To: <20261130143603.512171-1-mic@digikod.net> References: <20261130143603.512171-1-mic@digikod.net> Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Date: Mon, 30 Nov 2026 14:43:49 +0000 X-Mailing-List: linux-security-module@vger.kernel.org List-Id: List-Post: List-Help: List-Subscribe: List-Unsubscribe: List-Owner: Precedence: list > landlock_restrict_sibling_threads() write-locks > current->signal->exec_update_lock to serialize TSYNC callers, and holds > it until every sibling thread has run its task_work. This wait is > unbounded: TWA_SIGNAL does not wake a TASK_KILLABLE sleeper, so a > sibling blocked as a vfork() parent runs it only once its child execs or > exits. >=20 > Meanwhile, readers of this lock block, mostly in D state: > /proc//stat, mm_access(), pidfd_getfd(), kcmp(), perf_event_open(), > etc. An unprivileged process can thus stall tools run by other users, > including root, such as ps and top. >=20 > Only a per-process "TSYNC in progress" marker is needed. Use an unused > signal_struct.flags bit, protected by sighand->siglock, which is held > only to set or clear the marker. A second caller still restarts the > [ ... ] > Acked-by: Christian Brauner (Amutable) > Acked-by: G=C3=BCnther Noack > Reviewed-by: Oleg Nesterov > Fixes: ff88df67dbf7 ("landlock: Serialize TSYNC thread restriction") > Signed-off-by: Micka=C3=ABl Sala=C3=BCn Sashiko has reviewed this patch and found no issues. --=20 Sashiko AI review =C2=B7 https://sashiko.dev/#/patchset/20261130143603.5121= 71-1-mic@digikod.net?part=3D1