pkcs7
Advanced tools
Comparing version 1.0.2 to 1.0.3-0
@@ -0,3 +1,6 @@ | ||
/*! @name pkcs7 @version 1.0.3-0 @license Apache-2.0 */ | ||
'use strict'; | ||
Object.defineProperty(exports, '__esModule', { value: true }); | ||
/* | ||
@@ -10,7 +13,6 @@ * pkcs7.pad | ||
*/ | ||
var PADDING = void 0; | ||
var PADDING; | ||
/** | ||
* Returns a new Uint8Array that is padded with PKCS#7 padding. | ||
* | ||
* @param plaintext {Uint8Array} the input bytes before encryption | ||
@@ -20,13 +22,11 @@ * @return {Uint8Array} the padded bytes | ||
*/ | ||
function pad(plaintext) { | ||
var padding = PADDING[plaintext.byteLength % 16 || 0]; | ||
var result = new Uint8Array(plaintext.byteLength + padding.length); | ||
result.set(plaintext); | ||
result.set(padding, plaintext.byteLength); | ||
return result; | ||
} | ||
} // pre-define the padding values | ||
// pre-define the padding values | ||
PADDING = [[16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16], [15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15], [14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14], [13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13], [12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12], [11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11], [10, 10, 10, 10, 10, 10, 10, 10, 10, 10], [9, 9, 9, 9, 9, 9, 9, 9, 9], [8, 8, 8, 8, 8, 8, 8, 8], [7, 7, 7, 7, 7, 7, 7], [6, 6, 6, 6, 6, 6], [5, 5, 5, 5, 5], [4, 4, 4, 4], [3, 3, 3], [2, 2], [1]]; | ||
@@ -36,2 +36,3 @@ | ||
* Returns the subarray of a Uint8Array without PKCS#7 padding. | ||
* | ||
* @param padded {Uint8Array} unencrypted bytes that have been padded | ||
@@ -45,6 +46,6 @@ * @return {Uint8Array} the unpadded bytes | ||
var version = "1.0.2"; | ||
var version = "1.0.3-0"; | ||
exports.VERSION = version; | ||
exports.pad = pad; | ||
exports.unpad = unpad; | ||
exports.VERSION = version; |
@@ -0,1 +1,2 @@ | ||
/*! @name pkcs7 @version 1.0.3-0 @license Apache-2.0 */ | ||
/* | ||
@@ -8,7 +9,6 @@ * pkcs7.pad | ||
*/ | ||
var PADDING = void 0; | ||
var PADDING; | ||
/** | ||
* Returns a new Uint8Array that is padded with PKCS#7 padding. | ||
* | ||
* @param plaintext {Uint8Array} the input bytes before encryption | ||
@@ -18,13 +18,11 @@ * @return {Uint8Array} the padded bytes | ||
*/ | ||
function pad(plaintext) { | ||
var padding = PADDING[plaintext.byteLength % 16 || 0]; | ||
var result = new Uint8Array(plaintext.byteLength + padding.length); | ||
result.set(plaintext); | ||
result.set(padding, plaintext.byteLength); | ||
return result; | ||
} | ||
} // pre-define the padding values | ||
// pre-define the padding values | ||
PADDING = [[16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16], [15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15], [14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14], [13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13], [12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12], [11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11], [10, 10, 10, 10, 10, 10, 10, 10, 10, 10], [9, 9, 9, 9, 9, 9, 9, 9, 9], [8, 8, 8, 8, 8, 8, 8, 8], [7, 7, 7, 7, 7, 7, 7], [6, 6, 6, 6, 6, 6], [5, 5, 5, 5, 5], [4, 4, 4, 4], [3, 3, 3], [2, 2], [1]]; | ||
@@ -34,2 +32,3 @@ | ||
* Returns the subarray of a Uint8Array without PKCS#7 padding. | ||
* | ||
* @param padded {Uint8Array} unencrypted bytes that have been padded | ||
@@ -43,4 +42,4 @@ * @return {Uint8Array} the unpadded bytes | ||
var version = "1.0.2"; | ||
var version = "1.0.3-0"; | ||
export { pad, unpad, version as VERSION }; | ||
export { version as VERSION, pad, unpad }; |
@@ -0,52 +1,53 @@ | ||
/*! @name pkcs7 @version 1.0.3-0 @license Apache-2.0 */ | ||
(function (global, factory) { | ||
typeof exports === 'object' && typeof module !== 'undefined' ? factory(exports) : | ||
typeof define === 'function' && define.amd ? define(['exports'], factory) : | ||
(factory((global.pkcs7 = global.pkcs7 || {}))); | ||
}(this, (function (exports) { 'use strict'; | ||
typeof exports === 'object' && typeof module !== 'undefined' ? factory(exports) : | ||
typeof define === 'function' && define.amd ? define(['exports'], factory) : | ||
(global = global || self, factory(global.pkcs7 = {})); | ||
}(this, function (exports) { 'use strict'; | ||
/* | ||
* pkcs7.pad | ||
* https://github.com/brightcove/pkcs7 | ||
* | ||
* Copyright (c) 2014 Brightcove | ||
* Licensed under the apache2 license. | ||
*/ | ||
/* | ||
* pkcs7.pad | ||
* https://github.com/brightcove/pkcs7 | ||
* | ||
* Copyright (c) 2014 Brightcove | ||
* Licensed under the apache2 license. | ||
*/ | ||
var PADDING; | ||
/** | ||
* Returns a new Uint8Array that is padded with PKCS#7 padding. | ||
* | ||
* @param plaintext {Uint8Array} the input bytes before encryption | ||
* @return {Uint8Array} the padded bytes | ||
* @see http://tools.ietf.org/html/rfc5652 | ||
*/ | ||
var PADDING = void 0; | ||
function pad(plaintext) { | ||
var padding = PADDING[plaintext.byteLength % 16 || 0]; | ||
var result = new Uint8Array(plaintext.byteLength + padding.length); | ||
result.set(plaintext); | ||
result.set(padding, plaintext.byteLength); | ||
return result; | ||
} // pre-define the padding values | ||
/** | ||
* Returns a new Uint8Array that is padded with PKCS#7 padding. | ||
* @param plaintext {Uint8Array} the input bytes before encryption | ||
* @return {Uint8Array} the padded bytes | ||
* @see http://tools.ietf.org/html/rfc5652 | ||
*/ | ||
function pad(plaintext) { | ||
var padding = PADDING[plaintext.byteLength % 16 || 0]; | ||
var result = new Uint8Array(plaintext.byteLength + padding.length); | ||
PADDING = [[16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16], [15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15], [14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14], [13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13], [12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12], [11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11], [10, 10, 10, 10, 10, 10, 10, 10, 10, 10], [9, 9, 9, 9, 9, 9, 9, 9, 9], [8, 8, 8, 8, 8, 8, 8, 8], [7, 7, 7, 7, 7, 7, 7], [6, 6, 6, 6, 6, 6], [5, 5, 5, 5, 5], [4, 4, 4, 4], [3, 3, 3], [2, 2], [1]]; | ||
result.set(plaintext); | ||
result.set(padding, plaintext.byteLength); | ||
/** | ||
* Returns the subarray of a Uint8Array without PKCS#7 padding. | ||
* | ||
* @param padded {Uint8Array} unencrypted bytes that have been padded | ||
* @return {Uint8Array} the unpadded bytes | ||
* @see http://tools.ietf.org/html/rfc5652 | ||
*/ | ||
function unpad(padded) { | ||
return padded.subarray(0, padded.byteLength - padded[padded.byteLength - 1]); | ||
} | ||
return result; | ||
} | ||
var version = "1.0.3-0"; | ||
// pre-define the padding values | ||
PADDING = [[16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16], [15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15], [14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14], [13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13], [12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12], [11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11], [10, 10, 10, 10, 10, 10, 10, 10, 10, 10], [9, 9, 9, 9, 9, 9, 9, 9, 9], [8, 8, 8, 8, 8, 8, 8, 8], [7, 7, 7, 7, 7, 7, 7], [6, 6, 6, 6, 6, 6], [5, 5, 5, 5, 5], [4, 4, 4, 4], [3, 3, 3], [2, 2], [1]]; | ||
exports.VERSION = version; | ||
exports.pad = pad; | ||
exports.unpad = unpad; | ||
/** | ||
* Returns the subarray of a Uint8Array without PKCS#7 padding. | ||
* @param padded {Uint8Array} unencrypted bytes that have been padded | ||
* @return {Uint8Array} the unpadded bytes | ||
* @see http://tools.ietf.org/html/rfc5652 | ||
*/ | ||
function unpad(padded) { | ||
return padded.subarray(0, padded.byteLength - padded[padded.byteLength - 1]); | ||
} | ||
Object.defineProperty(exports, '__esModule', { value: true }); | ||
var version = "1.0.2"; | ||
exports.pad = pad; | ||
exports.unpad = unpad; | ||
exports.VERSION = version; | ||
}))); | ||
})); |
@@ -0,38 +1,36 @@ | ||
/*! @name pkcs7 @version 1.0.3-0 @license Apache-2.0 */ | ||
(function (global, factory) { | ||
typeof exports === 'object' && typeof module !== 'undefined' ? module.exports = factory() : | ||
typeof define === 'function' && define.amd ? define(factory) : | ||
(global.pkcs7 = global.pkcs7 || {}, global.pkcs7.pad = factory()); | ||
}(this, (function () { 'use strict'; | ||
typeof exports === 'object' && typeof module !== 'undefined' ? module.exports = factory() : | ||
typeof define === 'function' && define.amd ? define(factory) : | ||
(global = global || self, (global.pkcs7 = global.pkcs7 || {}, global.pkcs7.pad = factory())); | ||
}(this, function () { 'use strict'; | ||
/* | ||
* pkcs7.pad | ||
* https://github.com/brightcove/pkcs7 | ||
* | ||
* Copyright (c) 2014 Brightcove | ||
* Licensed under the apache2 license. | ||
*/ | ||
/* | ||
* pkcs7.pad | ||
* https://github.com/brightcove/pkcs7 | ||
* | ||
* Copyright (c) 2014 Brightcove | ||
* Licensed under the apache2 license. | ||
*/ | ||
var PADDING; | ||
/** | ||
* Returns a new Uint8Array that is padded with PKCS#7 padding. | ||
* | ||
* @param plaintext {Uint8Array} the input bytes before encryption | ||
* @return {Uint8Array} the padded bytes | ||
* @see http://tools.ietf.org/html/rfc5652 | ||
*/ | ||
var PADDING = void 0; | ||
function pad(plaintext) { | ||
var padding = PADDING[plaintext.byteLength % 16 || 0]; | ||
var result = new Uint8Array(plaintext.byteLength + padding.length); | ||
result.set(plaintext); | ||
result.set(padding, plaintext.byteLength); | ||
return result; | ||
} // pre-define the padding values | ||
/** | ||
* Returns a new Uint8Array that is padded with PKCS#7 padding. | ||
* @param plaintext {Uint8Array} the input bytes before encryption | ||
* @return {Uint8Array} the padded bytes | ||
* @see http://tools.ietf.org/html/rfc5652 | ||
*/ | ||
function pad(plaintext) { | ||
var padding = PADDING[plaintext.byteLength % 16 || 0]; | ||
var result = new Uint8Array(plaintext.byteLength + padding.length); | ||
PADDING = [[16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16], [15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15], [14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14], [13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13], [12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12], [11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11], [10, 10, 10, 10, 10, 10, 10, 10, 10, 10], [9, 9, 9, 9, 9, 9, 9, 9, 9], [8, 8, 8, 8, 8, 8, 8, 8], [7, 7, 7, 7, 7, 7, 7], [6, 6, 6, 6, 6, 6], [5, 5, 5, 5, 5], [4, 4, 4, 4], [3, 3, 3], [2, 2], [1]]; | ||
result.set(plaintext); | ||
result.set(padding, plaintext.byteLength); | ||
return pad; | ||
return result; | ||
} | ||
// pre-define the padding values | ||
PADDING = [[16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16], [15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15], [14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14], [13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13], [12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12], [11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11], [10, 10, 10, 10, 10, 10, 10, 10, 10, 10], [9, 9, 9, 9, 9, 9, 9, 9, 9], [8, 8, 8, 8, 8, 8, 8, 8], [7, 7, 7, 7, 7, 7, 7], [6, 6, 6, 6, 6, 6], [5, 5, 5, 5, 5], [4, 4, 4, 4], [3, 3, 3], [2, 2], [1]]; | ||
return pad; | ||
}))); | ||
})); |
@@ -0,19 +1,21 @@ | ||
/*! @name pkcs7 @version 1.0.3-0 @license Apache-2.0 */ | ||
(function (global, factory) { | ||
typeof exports === 'object' && typeof module !== 'undefined' ? module.exports = factory() : | ||
typeof define === 'function' && define.amd ? define(factory) : | ||
(global.pkcs7 = global.pkcs7 || {}, global.pkcs7.unpad = factory()); | ||
}(this, (function () { 'use strict'; | ||
typeof exports === 'object' && typeof module !== 'undefined' ? module.exports = factory() : | ||
typeof define === 'function' && define.amd ? define(factory) : | ||
(global = global || self, (global.pkcs7 = global.pkcs7 || {}, global.pkcs7.unpad = factory())); | ||
}(this, function () { 'use strict'; | ||
/** | ||
* Returns the subarray of a Uint8Array without PKCS#7 padding. | ||
* @param padded {Uint8Array} unencrypted bytes that have been padded | ||
* @return {Uint8Array} the unpadded bytes | ||
* @see http://tools.ietf.org/html/rfc5652 | ||
*/ | ||
function unpad(padded) { | ||
return padded.subarray(0, padded.byteLength - padded[padded.byteLength - 1]); | ||
} | ||
/** | ||
* Returns the subarray of a Uint8Array without PKCS#7 padding. | ||
* | ||
* @param padded {Uint8Array} unencrypted bytes that have been padded | ||
* @return {Uint8Array} the unpadded bytes | ||
* @see http://tools.ietf.org/html/rfc5652 | ||
*/ | ||
function unpad(padded) { | ||
return padded.subarray(0, padded.byteLength - padded[padded.byteLength - 1]); | ||
} | ||
return unpad; | ||
return unpad; | ||
}))); | ||
})); |
106
package.json
{ | ||
"name": "pkcs7", | ||
"version": "1.0.2", | ||
"version": "1.0.3-0", | ||
"main": "dist/pkcs7.cjs.js", | ||
@@ -9,6 +9,2 @@ "module": "dist/pkcs7.es.js", | ||
"bugs": "https://github.com/brightcove/pkcs7/issues", | ||
"engines": { | ||
"npm": "^1.4.6", | ||
"node": "^0.10" | ||
}, | ||
"author": { | ||
@@ -21,49 +17,53 @@ "name": "Brightcove" | ||
}, | ||
"license": "Apache2", | ||
"license": "Apache-2.0", | ||
"files": [ | ||
"bin", | ||
"src", | ||
"dist" | ||
"CONTRIBUTING.md", | ||
"dist/", | ||
"docs/", | ||
"index.html", | ||
"scripts/", | ||
"src/", | ||
"test/" | ||
], | ||
"keywords": [ | ||
"pkcs7", | ||
"pkcs7 encrypt decrypt padding pkcs" | ||
"pkcs7 encrypt decrypt padding pkcs", | ||
"videojs", | ||
"videojs-plugin" | ||
], | ||
"dependencies": { | ||
"@babel/runtime": "^7.5.5" | ||
}, | ||
"devDependencies": { | ||
"babel-cli": "^6.24.1", | ||
"babel-plugin-external-helpers": "^6.22.0", | ||
"babel-preset-es2015": "^6.24.1", | ||
"babel-preset-es3": "^1.0.1", | ||
"mkdirp": "^0.5.1", | ||
"nodeunit": "^0.11.0", | ||
"npm-run-all": "^4.0.2", | ||
"rimraf": "^2.6.1", | ||
"rollup": "^0.41.6", | ||
"rollup-plugin-babel": "^2.7.1", | ||
"rollup-plugin-json": "^2.1.1", | ||
"rollup-watch": "^3.2.2", | ||
"videojs-standard": "^5.2.0" | ||
"rollup": "^1.19.4", | ||
"@videojs/generator-helpers": "~1.2.0", | ||
"jsdoc": "BrandonOCasey/jsdoc#feat/plugin-from-cli", | ||
"karma": "^4.0.0", | ||
"postcss-cli": "^6.0.0", | ||
"sinon": "^7.2.2", | ||
"videojs-generate-karma-config": "~5.3.0", | ||
"videojs-generator-verify": "~1.2.0", | ||
"videojs-generate-rollup-config": "~5.0.0", | ||
"videojs-languages": "^2.0.0", | ||
"videojs-standard": "^8.0.3" | ||
}, | ||
"scripts": { | ||
"prebuild": "npm run clean", | ||
"build": "npm-run-all -p build:*", | ||
"build:js": "npm-run-all -p build:js:modules build:js:umd build:js:pad build:js:unpad", | ||
"build:js:modules": "rollup -c scripts/modules.rollup.js", | ||
"build:js:umd": "rollup -c scripts/umd.rollup.js", | ||
"build:js:pad": "rollup -c scripts/pad.rollup.js", | ||
"build:js:unpad": "rollup -c scripts/unpad.rollup.js", | ||
"build:test": "rollup -c scripts/test.rollup.js", | ||
"clean": "rimraf dist test/dist", | ||
"postclean": "mkdirp dist test/dist", | ||
"build-test": "cross-env-shell TEST_BUNDLE_ONLY=1 'npm run build'", | ||
"build-prod": "cross-env-shell NO_TEST_BUNDLE=1 'npm run build'", | ||
"build": "npm-run-all -s clean -p build:*", | ||
"build:js": "rollup -c scripts/rollup.config.js", | ||
"clean": "shx rm -rf ./dist ./test/dist && shx mkdir -p ./dist ./test/dist", | ||
"lint": "vjsstandard", | ||
"pretest": "npm-run-all lint build:test", | ||
"test": "nodeunit test/dist/pkcs7_test.js", | ||
"prepublishOnly": "npm-run-all build-prod && vjsverify --verbose", | ||
"start": "npm-run-all -p server watch", | ||
"server": "karma start scripts/karma.conf.js --singleRun=false --auto-watch", | ||
"test": "npm-run-all lint build-test -p test:*", | ||
"test:browser": "karma start scripts/karma.conf.js", | ||
"test:node": "qunit test/dist/bundle.js", | ||
"posttest": "shx cat test/dist/coverage/text.txt", | ||
"preversion": "npm test", | ||
"version": "is-prerelease || npm run update-changelog && git add CHANGELOG.md", | ||
"update-changelog": "conventional-changelog -p videojs -i CHANGELOG.md -s", | ||
"watch": "npm-run-all -p watch:*", | ||
"watch:js": "npm-run-all -p watch:js:modules watch:js:umd watch:js:pad watch:js:unpad", | ||
"watch:js:modules": "rollup -c scripts/modules.rollup.js -w", | ||
"watch:js:umd": "rollup -c scripts/umd.rollup.js -w", | ||
"watch:js:pad": "rollup -c scripts/pad.rollup.js -w", | ||
"watch:js:unpad": "rollup -c scripts/unpad.rollup.js -w", | ||
"watch:test": "rollup -c scripts/test.rollup.js -w", | ||
"prepublish": "npm run build" | ||
"watch:js": "npm run build:js -- -w" | ||
}, | ||
@@ -79,3 +79,25 @@ "bin": { | ||
] | ||
}, | ||
"generator-videojs-plugin": { | ||
"version": "7.7.0" | ||
}, | ||
"browserslist": [ | ||
"defaults", | ||
"ie 11" | ||
], | ||
"husky": { | ||
"hooks": { | ||
"pre-commit": "lint-staged" | ||
} | ||
}, | ||
"lint-staged": { | ||
"*.js": [ | ||
"vjsstandard --fix", | ||
"git add" | ||
], | ||
"README.md": [ | ||
"npm run docs:toc", | ||
"git add" | ||
] | ||
} | ||
} |
@@ -1,6 +0,23 @@ | ||
# pkcs7 [![Build Status](https://secure.travis-ci.org/brightcove/pkcs7.png?branch=master)](http://travis-ci.org/brightcove/pkcs7) | ||
# pkcs7 | ||
[![Build Status](https://travis-ci.org/brightcove/pkcs7.svg?branch=master)](https://travis-ci.org/brightcove/pkcs7) | ||
[![Greenkeeper badge](https://badges.greenkeeper.io/brightcove/pkcs7.svg)](https://greenkeeper.io/) | ||
[![Slack Status](http://slack.videojs.com/badge.svg)](http://slack.videojs.com) | ||
[![NPM](https://nodei.co/npm/pkcs7.png?downloads=true&downloadRank=true)](https://nodei.co/npm/pkcs7/) | ||
> Add and remove pkcs7-style padding. | ||
<!-- START doctoc generated TOC please keep comment here to allow auto update --> | ||
<!-- DON'T EDIT THIS SECTION, INSTEAD RE-RUN doctoc TO UPDATE --> | ||
**Table of Contents** *generated with [DocToc](https://github.com/thlorenz/doctoc)* | ||
- [Getting Started](#getting-started) | ||
- [Documentation](#documentation) | ||
- [Examples](#examples) | ||
- [Contributing](#contributing) | ||
- [License](#license) | ||
<!-- END doctoc generated TOC please keep comment here to allow auto update --> | ||
## Getting Started | ||
@@ -57,3 +74,3 @@ | ||
Copyright (c) 2014 Brightcove | ||
Copyright (c) 2014 Brightcove | ||
Licensed under the Apache-2 license. |
@@ -13,2 +13,3 @@ /* | ||
* Returns a new Uint8Array that is padded with PKCS#7 padding. | ||
* | ||
* @param plaintext {Uint8Array} the input bytes before encryption | ||
@@ -31,48 +32,48 @@ * @return {Uint8Array} the padded bytes | ||
[16, 16, 16, 16, | ||
16, 16, 16, 16, | ||
16, 16, 16, 16, | ||
16, 16, 16, 16], | ||
16, 16, 16, 16, | ||
16, 16, 16, 16, | ||
16, 16, 16, 16], | ||
[15, 15, 15, 15, | ||
15, 15, 15, 15, | ||
15, 15, 15, 15, | ||
15, 15, 15], | ||
15, 15, 15, 15, | ||
15, 15, 15, 15, | ||
15, 15, 15], | ||
[14, 14, 14, 14, | ||
14, 14, 14, 14, | ||
14, 14, 14, 14, | ||
14, 14], | ||
14, 14, 14, 14, | ||
14, 14, 14, 14, | ||
14, 14], | ||
[13, 13, 13, 13, | ||
13, 13, 13, 13, | ||
13, 13, 13, 13, | ||
13], | ||
13, 13, 13, 13, | ||
13, 13, 13, 13, | ||
13], | ||
[12, 12, 12, 12, | ||
12, 12, 12, 12, | ||
12, 12, 12, 12], | ||
12, 12, 12, 12, | ||
12, 12, 12, 12], | ||
[11, 11, 11, 11, | ||
11, 11, 11, 11, | ||
11, 11, 11], | ||
11, 11, 11, 11, | ||
11, 11, 11], | ||
[10, 10, 10, 10, | ||
10, 10, 10, 10, | ||
10, 10], | ||
10, 10, 10, 10, | ||
10, 10], | ||
[9, 9, 9, 9, | ||
9, 9, 9, 9, | ||
9], | ||
9, 9, 9, 9, | ||
9], | ||
[8, 8, 8, 8, | ||
8, 8, 8, 8], | ||
8, 8, 8, 8], | ||
[7, 7, 7, 7, | ||
7, 7, 7], | ||
7, 7, 7], | ||
[6, 6, 6, 6, | ||
6, 6], | ||
6, 6], | ||
[5, 5, 5, 5, | ||
5], | ||
5], | ||
@@ -79,0 +80,0 @@ [4, 4, 4, 4], |
/** | ||
* Returns the subarray of a Uint8Array without PKCS#7 padding. | ||
* | ||
* @param padded {Uint8Array} unencrypted bytes that have been padded | ||
@@ -4,0 +5,0 @@ * @return {Uint8Array} the unpadded bytes |
New author
Supply chain riskA new npm collaborator published a version of the package for the first time. New collaborators are usually benign additions to a project, but do indicate a change to the security surface area of a package.
Found 1 instance in 1 package
Mixed license
License(Experimental) Package contains multiple licenses.
Found 1 instance in 1 package
No v1
QualityPackage is not semver >=1. This means it is not stable and does not support ^ ranges.
Found 1 instance in 1 package
Non-permissive License
License(Experimental) A license not known to be considered permissive was found
Found 1 instance in 1 package
Unidentified License
License(Experimental) Something that seems like a license was found, but its contents could not be matched with a known license
Found 1 instance in 1 package
Filesystem access
Supply chain riskAccesses the file system, and could potentially read sensitive data.
Found 1 instance in 1 package
No License Found
License(Experimental) License information could not be found
Found 1 instance in 1 package
21250
11
19
352
76
0
1
3
80
1
1
+ Added@babel/runtime@^7.5.5
+ Added@babel/runtime@7.24.5(transitive)
+ Addedregenerator-runtime@0.14.1(transitive)