From 72beb736a6f077b3d96e2e1c746d6817057bc707 Mon Sep 17 00:00:00 2001 From: Aman Gupta Date: Mon, 10 Jun 2024 11:43:46 +0530 Subject: [PATCH] fix: fix clow stew issue (#1344) --- packages/restapi/src/lib/chat/helpers/pgp.ts | 2 ++ 1 file changed, 2 insertions(+) diff --git a/packages/restapi/src/lib/chat/helpers/pgp.ts b/packages/restapi/src/lib/chat/helpers/pgp.ts index 6240dc60d..0c06c7d24 100644 --- a/packages/restapi/src/lib/chat/helpers/pgp.ts +++ b/packages/restapi/src/lib/chat/helpers/pgp.ts @@ -75,6 +75,8 @@ const PGPHelper:IPGPHelper = { }) const publicKey: openpgp.PublicKey = await openpgp.readKey({ armoredKey: publicKeyArmored }) const verificationResult = await openpgp.verify({ + // setting date to 1 day in the future to avoid issues with clock skew + date: new Date(Date.now() + 1000 * 60 * 60 * 24), message, signature, verificationKeys: publicKey