From 5ce6a477fb1839d7ca8fbafc5c8eafabc2b29fcf Mon Sep 17 00:00:00 2001 From: Nathan Beddoe Date: Sat, 12 Sep 2026 09:40:52 +0200 Subject: [PATCH] Fix bridge assertion test's future-iat clock race --- tests/bridge.test.mjs | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/tests/bridge.test.mjs b/tests/bridge.test.mjs index 479d717..5bb5261 100644 --- a/tests/bridge.test.mjs +++ b/tests/bridge.test.mjs @@ -93,8 +93,11 @@ test("pinned bridge assertion validates every exact claim and separates purposes ), ); } + // A future `iat` must be rejected, but `now` is recomputed inside + // verifyAssertion. A one-second offset can be swallowed when the wall clock + // advances between capture and verification, so use a margin that cannot. for (const change of [ - { iat: now + 1 }, + { iat: now + 30 }, { exp: now }, { exp: now + 61 }, { jti: "short" }, -- 2.51.2