@universal-packages/time-based-one-time-password
Advanced tools
Comparing version 1.0.4 to 1.1.0
@@ -6,3 +6,3 @@ "use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
exports.generate = void 0; | ||
exports.generate = generate; | ||
const crypto_1 = __importDefault(require("crypto")); | ||
@@ -28,3 +28,3 @@ /** | ||
steps = '0' + steps; | ||
const hmac = crypto_1.default.createHmac(finalOptions.algorithm, Buffer.from(hexSecret, 'hex')); | ||
const hmac = crypto_1.default.createHmac(finalOptions.algorithm, new Uint8Array(Buffer.from(hexSecret, 'hex'))); | ||
hmac.update(steps, 'hex'); | ||
@@ -37,3 +37,2 @@ const hash = hmac.digest('hex'); | ||
} | ||
exports.generate = generate; | ||
//# sourceMappingURL=generate.js.map |
{ | ||
"name": "@universal-packages/time-based-one-time-password", | ||
"version": "1.0.4", | ||
"version": "1.1.0", | ||
"description": "Time-based one-time password implementation", | ||
@@ -20,9 +20,9 @@ "author": "David De Anda <david@universal-packages.com> (https://github.com/universal-packages)", | ||
"@trivago/prettier-plugin-sort-imports": "^4.3.0", | ||
"@types/jest": "^29.5.12", | ||
"@types/jest": "^29.5.14", | ||
"@types/node": "^18.11.9", | ||
"@universal-packages/maintenance": "^1.6.3", | ||
"@universal-packages/maintenance": "^1.6.12", | ||
"jest": "^29.7.0", | ||
"prettier": "^3.0.3", | ||
"ts-jest": "^29.1.2", | ||
"typescript": "^5.4.3" | ||
"prettier": "^3.4.1", | ||
"ts-jest": "^29.2.5", | ||
"typescript": "^5.7.2" | ||
}, | ||
@@ -29,0 +29,0 @@ "jest": { |
"use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
exports.verify = void 0; | ||
exports.verify = verify; | ||
const generate_1 = require("./generate"); | ||
@@ -14,3 +14,2 @@ function verify(password, secret, options) { | ||
} | ||
exports.verify = verify; | ||
//# sourceMappingURL=verify.js.map |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
11938
92