@arasaka-cinema/passport 1.0.0 → 1.0.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -45,7 +45,7 @@ let PassportService = class PassportService {
45
45
  const [userPart, iatPart, expPart, mac] = parts;
46
46
  const serialized = this.serialize(userPart, iatPart, expPart);
47
47
  const expectedMac = this.computeHmac(this.SECRET_KEY, serialized);
48
- if (!(0, utils_1.constantTimeEqual)(expectedMac, token))
48
+ if (!(0, utils_1.constantTimeEqual)(expectedMac, mac))
49
49
  return { valid: false, reason: 'Invalid token signature' };
50
50
  const expNumber = Number((0, utils_1.base64UrlDecode)(expPart));
51
51
  if (!Number.isFinite(expNumber))
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@arasaka-cinema/passport",
3
- "version": "1.0.0",
3
+ "version": "1.0.1",
4
4
  "description": "Lightweight JWT-like authentication middleware for NestJS",
5
5
  "main": "./dist/index.js",
6
6
  "types": "./dist/index.d.ts",