diff --git a/src/client/utils/auth.ts b/src/client/utils/auth.ts index f39a1215..4f895aeb 100644 --- a/src/client/utils/auth.ts +++ b/src/client/utils/auth.ts @@ -44,7 +44,7 @@ export const signAuthenticationToken = (methodRaw: string | undefined, uri: stri } const iat = Math.floor(Date.now() / 1000); - const exp = iat + 3600; + const exp = iat + 300; const sha256 = sha256Hash(Buffer.from(method + uri + data)).toString('hex'); const payload = { @@ -80,7 +80,7 @@ export const signOauthAccessToken = (methodRaw: string | undefined, uri: string, } const iat = Math.floor(Date.now() / 1000); - const exp = iat + 3600; + const exp = iat + 300; const sha256 = sha256Hash(Buffer.from(method + uri + data)).toString('hex'); const payload = { diff --git a/test/mixin/auth.test.ts b/test/mixin/auth.test.ts index a326951c..b840fcfc 100644 --- a/test/mixin/auth.test.ts +++ b/test/mixin/auth.test.ts @@ -43,7 +43,7 @@ describe('authentication utilities', () => { uid: appID, sid: sessionID, iat: 1767323045, - exp: 1767326645, + exp: 1767323345, jti: requestID, scp: 'FULL', sig: sha256Hash(Buffer.from(`POST/resource${serialize(body, { unsafe: true })}`)).toString('hex'),