Received: from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org [10.30.226.201]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 85ABF194A6C for ; Wed, 29 Apr 2026 19:49:15 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=10.30.226.201 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1777492155; cv=none; b=RBpZiRz/qAh2pgaw6JMPo/yKY20bfGNZZqjnO6gIZR94MTqkjdbLybGKQuAtiLMFJCbCGV6wzrlG419dOaj/WRRdiIt14kMn7dNvn626tNWC+mFLzF57XKFeAApoJFPAods9pd4ppOWWON/aib62Z0/lbMekgoKLw1oaKBXC5vI= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1777492155; c=relaxed/simple; bh=ygoOGWfuTTYVpjITeEhWjUih0LWSjm8FhVsgpXwpZn8=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version; b=qdtsnNJ45jyi4ptLis2pRC4C5yss1FOcadhoAHiqnGJn02UKCkLko55n3BpTaHpNiF1SXASs6CF79Euy5FnMiRpF1BCPD3DhlK90PR+94b2qcFy5dD54WBNhsijdTHPzghBlktD9SKO2tYG98GlqKxhR0I71M33Lolj5bv6JbLM= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b=G1uAvWah; arc=none smtp.client-ip=10.30.226.201 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b="G1uAvWah" Received: by smtp.kernel.org (Postfix) with ESMTPSA id 8452AC19425; Wed, 29 Apr 2026 19:49:14 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1777492155; bh=ygoOGWfuTTYVpjITeEhWjUih0LWSjm8FhVsgpXwpZn8=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=G1uAvWahwwf9A9sW1V1gXX8S3pIaRF+mCQWbHqne+NcFNhnZJcKWcTPrUcHGwO8TD 4MrnXzIHcWPW3nO1H8iK3YRbBTL+dExow9TgdlayRDY4WrB4FY/3fhfxSLh8lfM/o1 hLhOAFjm8ortrU/2mhPrVltUTzCn+nI1ankxtHuxqsXBrJDHowYNMO8DFxMV8X9FdV pegNhPjV8dqXsbBJjXxuAyeP86ywAMoUZosvd17e8vtC1xYKfjBkD7QnYTubEY1LNf MbaDAE2o8/rRjHXcglKhycnYLGgus+AQsIUM4/s6D3ZehMXy3w8iIMzVuS+x5lFktm y6R89fqWB2ODQ== From: Sasha Levin To: Jorge Marques Cc: gregkh@linuxfoundation.org, philip.molloy@analog.com, philip@philipmolloy.com, gastmaier@gmail.com, linux-cve-announce@vger.kernel.org Subject: Re: [PATCH 1/3] strak: add cve listing tests Date: Wed, 29 Apr 2026 15:49:11 -0400 Message-ID: <20260429194913.232186-1-sashal@kernel.org> X-Mailer: git-send-email 2.53.0 In-Reply-To: <20260427104014.25683-2-jorge.marques@analog.com> References: <20260427104014.25683-1-jorge.marques@analog.com> <20260427104014.25683-2-jorge.marques@analog.com> Precedence: bulk X-Mailing-List: linux-cve-announce@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: 8bit On Mon, Apr 27, 2026 at 12:37:14PM +0200, Jorge Marques wrote: > Map some expected results in different scenarios, in particular, commits > merged on a stable tag, but created on a previous stable tag. The tests > also allow for assessing querying performance. > > Signed-off-by: Jorge Marques > --- > tools/strak/tests/strak.rs | 57 ++++++++++++++++++++++++++++++++++++++ > 1 file changed, 57 insertions(+) The five new tests pin the bug nicely; the negative cases (cve_fix_in_history, cve_newer_than_commit) are exactly what's needed to guard against an overcorrection. I confirmed locally that these tests fail on master and pass with patches 2 and 3 applied. One missing case that would have caught a regression in patch 3: a stable tag input asking about a fix released in that same major. See my comments on patch 3/3 for details, but please add something equivalent to: #[test] fn cve_fix_in_same_major_release() { let mut cmd = Command::new(cargo::cargo_bin!("strak")); cmd.arg("v6.12") .assert() .success() // CVE-2024-46869 fix is at 6.12 (7ffaa20025187). .stdout(predicate::str::contains("is vulnerable to CVE-2024-46869").not()); } > +/// Commit based on v6.11-rc2, merged into v6.12. > +const TOPIC_BRANCH_COMMIT: &str = "bbf3c7ff9dfa45be51500d23a1276991a7cd8c6e"; Worth a brief note in the file (or commit message) that these are integration tests against the live published/ tree and a working CVEKERNELTREE, so they will silently break if a referenced CVE's dyad ever changes. Pinning by SHA helps; pinning by CVE id less so. With the extra test (and the fix in 3/3) this looks good to me. -- Thanks, Sasha