Skip to content

Commit

Permalink
chore: exp value fix in JWT payload
Browse files Browse the repository at this point in the history
  • Loading branch information
sanderPostma committed Nov 1, 2024
1 parent 3b516be commit 086f910
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion packages/oid4vci-common/lib/functions/ProofUtil.ts
Original file line number Diff line number Diff line change
Expand Up @@ -147,7 +147,7 @@ const createJWT = (mode: PoPMode, jwtProps?: JwtProps, existingJwt?: Jwt): Jwt =
const jwtPayload: Partial<JWTPayload> = {
...(aud && { aud }),
iat: jwt.payload?.iat ?? Math.floor(now / 1000) - 60, // Let's ensure we subtract 60 seconds for potential time offsets
exp: jwt.payload?.exp ?? (Math.floor(now / 1000) + 10) * 60,
exp: jwt.payload?.exp ?? Math.floor(now / 1000) + (10 * 60),
nonce,
...(client_id && { client_id }),
...(iss && { iss }),
Expand Down

0 comments on commit 086f910

Please sign in to comment.