UNPKG

jose

Version:

Universal 'JSON Web Almost Everything' - JWA, JWS, JWE, JWT, JWK with no dependencies

10 lines (9 loc) 333 B
"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); const errors_js_1 = require("../util/errors.js"); function checkP2s(p2s) { if (!(p2s instanceof Uint8Array) || p2s.length < 8) { throw new errors_js_1.JWEInvalid('PBES2 Salt Input must be 8 or more octets'); } } exports.default = checkP2s;