apipost-cli 1.0.8 → 1.0.13
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.
- package/README.md +4 -0
- package/dist/37.index.js +452 -0
- package/dist/841.index.js +6984 -0
- package/dist/action.js +4 -0
- package/dist/apipost-cli/node_modules/@azure/abort-controller/types/3.1/AbortController.d.ts +85 -0
- package/dist/apipost-cli/node_modules/@azure/abort-controller/types/3.1/AbortSignal.d.ts +80 -0
- package/dist/apipost-cli/node_modules/@azure/abort-controller/types/3.1/index.d.ts +3 -0
- package/dist/apipost-cli/node_modules/@azure/core-auth/types/3.1/core-auth.d.ts +229 -0
- package/dist/apipost-cli/node_modules/@azure/core-client/types/3.1/core-client.d.ts +900 -0
- package/dist/apipost-cli/node_modules/@azure/core-paging/types/3.1/core-paging.d.ts +77 -0
- package/dist/apipost-cli/node_modules/@azure/core-paging/types/3.1/samples-dev/getPagedAsyncIteratorSample.d.ts +2 -0
- package/dist/apipost-cli/node_modules/@azure/core-paging/types/3.1/src/getPagedAsyncIterator.d.ts +10 -0
- package/dist/apipost-cli/node_modules/@azure/core-paging/types/3.1/src/index.d.ts +3 -0
- package/dist/apipost-cli/node_modules/@azure/core-paging/types/3.1/src/models.d.ts +69 -0
- package/dist/apipost-cli/node_modules/@azure/core-paging/types/3.1/test/getPagedAsyncIterator.spec.d.ts +2 -0
- package/dist/apipost-cli/node_modules/@azure/core-rest-pipeline/types/3.1/core-rest-pipeline.d.ts +1114 -0
- package/dist/apipost-cli/node_modules/@azure/core-util/types/3.1/core-util.d.ts +112 -0
- package/dist/apipost-cli/node_modules/@nodelib/fs.scandir/LICENSE +21 -0
- package/dist/apipost-cli/node_modules/@nodelib/fs.scandir/out/adapters/fs.d.ts +20 -0
- package/dist/apipost-cli/node_modules/@nodelib/fs.scandir/out/adapters/fs.js +19 -0
- package/dist/apipost-cli/node_modules/@nodelib/fs.scandir/out/constants.d.ts +4 -0
- package/dist/apipost-cli/node_modules/@nodelib/fs.scandir/out/constants.js +17 -0
- package/dist/apipost-cli/node_modules/@nodelib/fs.scandir/out/index.d.ts +12 -0
- package/dist/apipost-cli/node_modules/@nodelib/fs.scandir/out/index.js +26 -0
- package/dist/apipost-cli/node_modules/@nodelib/fs.scandir/out/providers/async.d.ts +7 -0
- package/dist/apipost-cli/node_modules/@nodelib/fs.scandir/out/providers/async.js +104 -0
- package/dist/apipost-cli/node_modules/@nodelib/fs.scandir/out/providers/common.d.ts +1 -0
- package/dist/apipost-cli/node_modules/@nodelib/fs.scandir/out/providers/common.js +13 -0
- package/dist/apipost-cli/node_modules/@nodelib/fs.scandir/out/providers/sync.d.ts +5 -0
- package/dist/apipost-cli/node_modules/@nodelib/fs.scandir/out/providers/sync.js +54 -0
- package/dist/apipost-cli/node_modules/@nodelib/fs.scandir/out/settings.d.ts +20 -0
- package/dist/apipost-cli/node_modules/@nodelib/fs.scandir/out/settings.js +24 -0
- package/dist/apipost-cli/node_modules/@nodelib/fs.scandir/out/types/index.d.ts +20 -0
- package/dist/apipost-cli/node_modules/@nodelib/fs.scandir/out/types/index.js +2 -0
- package/dist/apipost-cli/node_modules/@nodelib/fs.scandir/out/utils/fs.d.ts +2 -0
- package/dist/apipost-cli/node_modules/@nodelib/fs.scandir/out/utils/fs.js +19 -0
- package/dist/apipost-cli/node_modules/@nodelib/fs.scandir/out/utils/index.d.ts +2 -0
- package/dist/apipost-cli/node_modules/@nodelib/fs.scandir/out/utils/index.js +5 -0
- package/dist/apipost-cli/node_modules/@nodelib/fs.scandir/package.json +44 -0
- package/dist/apipost-cli/node_modules/@nodelib/fs.stat/LICENSE +21 -0
- package/dist/apipost-cli/node_modules/@nodelib/fs.stat/out/adapters/fs.d.ts +13 -0
- package/dist/apipost-cli/node_modules/@nodelib/fs.stat/out/adapters/fs.js +17 -0
- package/dist/apipost-cli/node_modules/@nodelib/fs.stat/out/index.d.ts +12 -0
- package/dist/apipost-cli/node_modules/@nodelib/fs.stat/out/index.js +26 -0
- package/dist/apipost-cli/node_modules/@nodelib/fs.stat/out/providers/async.d.ts +4 -0
- package/dist/apipost-cli/node_modules/@nodelib/fs.stat/out/providers/async.js +36 -0
- package/dist/apipost-cli/node_modules/@nodelib/fs.stat/out/providers/sync.d.ts +3 -0
- package/dist/apipost-cli/node_modules/@nodelib/fs.stat/out/providers/sync.js +23 -0
- package/dist/apipost-cli/node_modules/@nodelib/fs.stat/out/settings.d.ts +16 -0
- package/dist/apipost-cli/node_modules/@nodelib/fs.stat/out/settings.js +16 -0
- package/dist/apipost-cli/node_modules/@nodelib/fs.stat/out/types/index.d.ts +4 -0
- package/dist/apipost-cli/node_modules/@nodelib/fs.stat/out/types/index.js +2 -0
- package/dist/apipost-cli/node_modules/@nodelib/fs.stat/package.json +37 -0
- package/dist/apipost-cli/node_modules/@nodelib/fs.walk/LICENSE +21 -0
- package/dist/apipost-cli/node_modules/@nodelib/fs.walk/out/index.d.ts +14 -0
- package/dist/apipost-cli/node_modules/@nodelib/fs.walk/out/index.js +34 -0
- package/dist/apipost-cli/node_modules/@nodelib/fs.walk/out/providers/async.d.ts +12 -0
- package/dist/apipost-cli/node_modules/@nodelib/fs.walk/out/providers/async.js +30 -0
- package/dist/apipost-cli/node_modules/@nodelib/fs.walk/out/providers/index.d.ts +4 -0
- package/dist/apipost-cli/node_modules/@nodelib/fs.walk/out/providers/index.js +9 -0
- package/dist/apipost-cli/node_modules/@nodelib/fs.walk/out/providers/stream.d.ts +12 -0
- package/dist/apipost-cli/node_modules/@nodelib/fs.walk/out/providers/stream.js +34 -0
- package/dist/apipost-cli/node_modules/@nodelib/fs.walk/out/providers/sync.d.ts +10 -0
- package/dist/apipost-cli/node_modules/@nodelib/fs.walk/out/providers/sync.js +14 -0
- package/dist/apipost-cli/node_modules/@nodelib/fs.walk/out/readers/async.d.ts +30 -0
- package/dist/apipost-cli/node_modules/@nodelib/fs.walk/out/readers/async.js +97 -0
- package/dist/apipost-cli/node_modules/@nodelib/fs.walk/out/readers/common.d.ts +7 -0
- package/dist/apipost-cli/node_modules/@nodelib/fs.walk/out/readers/common.js +31 -0
- package/dist/apipost-cli/node_modules/@nodelib/fs.walk/out/readers/reader.d.ts +6 -0
- package/dist/apipost-cli/node_modules/@nodelib/fs.walk/out/readers/reader.js +11 -0
- package/dist/apipost-cli/node_modules/@nodelib/fs.walk/out/readers/sync.d.ts +15 -0
- package/dist/apipost-cli/node_modules/@nodelib/fs.walk/out/readers/sync.js +59 -0
- package/dist/apipost-cli/node_modules/@nodelib/fs.walk/out/settings.d.ts +30 -0
- package/dist/apipost-cli/node_modules/@nodelib/fs.walk/out/settings.js +26 -0
- package/dist/apipost-cli/node_modules/@nodelib/fs.walk/out/types/index.d.ts +8 -0
- package/dist/apipost-cli/node_modules/@nodelib/fs.walk/out/types/index.js +2 -0
- package/dist/apipost-cli/node_modules/@nodelib/fs.walk/package.json +44 -0
- package/dist/apipost-cli/node_modules/@types/node/ts4.8/assert/strict.d.ts +8 -0
- package/dist/apipost-cli/node_modules/@types/node/ts4.8/assert.d.ts +972 -0
- package/dist/apipost-cli/node_modules/@types/node/ts4.8/async_hooks.d.ts +530 -0
- package/dist/apipost-cli/node_modules/@types/node/ts4.8/buffer.d.ts +2351 -0
- package/dist/apipost-cli/node_modules/@types/node/ts4.8/child_process.d.ts +1395 -0
- package/dist/apipost-cli/node_modules/@types/node/ts4.8/cluster.d.ts +410 -0
- package/dist/apipost-cli/node_modules/@types/node/ts4.8/console.d.ts +412 -0
- package/dist/apipost-cli/node_modules/@types/node/ts4.8/constants.d.ts +18 -0
- package/dist/apipost-cli/node_modules/@types/node/ts4.8/crypto.d.ts +3961 -0
- package/dist/apipost-cli/node_modules/@types/node/ts4.8/dgram.d.ts +545 -0
- package/dist/apipost-cli/node_modules/@types/node/ts4.8/diagnostics_channel.d.ts +191 -0
- package/dist/apipost-cli/node_modules/@types/node/ts4.8/dns/promises.d.ts +414 -0
- package/dist/apipost-cli/node_modules/@types/node/ts4.8/dns.d.ts +668 -0
- package/dist/apipost-cli/node_modules/@types/node/ts4.8/dom-events.d.ts +126 -0
- package/dist/apipost-cli/node_modules/@types/node/ts4.8/domain.d.ts +170 -0
- package/dist/apipost-cli/node_modules/@types/node/ts4.8/events.d.ts +724 -0
- package/dist/apipost-cli/node_modules/@types/node/ts4.8/fs/promises.d.ts +1189 -0
- package/dist/apipost-cli/node_modules/@types/node/ts4.8/fs.d.ts +4043 -0
- package/dist/apipost-cli/node_modules/@types/node/ts4.8/globals.d.ts +303 -0
- package/dist/apipost-cli/node_modules/@types/node/ts4.8/globals.global.d.ts +1 -0
- package/dist/apipost-cli/node_modules/@types/node/ts4.8/http.d.ts +1724 -0
- package/dist/apipost-cli/node_modules/@types/node/ts4.8/http2.d.ts +2129 -0
- package/dist/apipost-cli/node_modules/@types/node/ts4.8/https.d.ts +441 -0
- package/dist/apipost-cli/node_modules/@types/node/ts4.8/index.d.ts +88 -0
- package/dist/apipost-cli/node_modules/@types/node/ts4.8/inspector.d.ts +2748 -0
- package/dist/apipost-cli/node_modules/@types/node/ts4.8/module.d.ts +116 -0
- package/dist/apipost-cli/node_modules/@types/node/ts4.8/net.d.ts +886 -0
- package/dist/apipost-cli/node_modules/@types/node/ts4.8/os.d.ts +477 -0
- package/dist/apipost-cli/node_modules/@types/node/ts4.8/path.d.ts +191 -0
- package/dist/apipost-cli/node_modules/@types/node/ts4.8/perf_hooks.d.ts +638 -0
- package/dist/apipost-cli/node_modules/@types/node/ts4.8/process.d.ts +1485 -0
- package/dist/apipost-cli/node_modules/@types/node/ts4.8/punycode.d.ts +117 -0
- package/dist/apipost-cli/node_modules/@types/node/ts4.8/querystring.d.ts +131 -0
- package/dist/apipost-cli/node_modules/@types/node/ts4.8/readline/promises.d.ts +145 -0
- package/dist/apipost-cli/node_modules/@types/node/ts4.8/readline.d.ts +526 -0
- package/dist/apipost-cli/node_modules/@types/node/ts4.8/repl.d.ts +424 -0
- package/dist/apipost-cli/node_modules/@types/node/ts4.8/stream/consumers.d.ts +12 -0
- package/dist/apipost-cli/node_modules/@types/node/ts4.8/stream/promises.d.ts +42 -0
- package/dist/apipost-cli/node_modules/@types/node/ts4.8/stream/web.d.ts +330 -0
- package/dist/apipost-cli/node_modules/@types/node/ts4.8/stream.d.ts +1392 -0
- package/dist/apipost-cli/node_modules/@types/node/ts4.8/string_decoder.d.ts +67 -0
- package/dist/apipost-cli/node_modules/@types/node/ts4.8/test.d.ts +1052 -0
- package/dist/apipost-cli/node_modules/@types/node/ts4.8/timers/promises.d.ts +93 -0
- package/dist/apipost-cli/node_modules/@types/node/ts4.8/timers.d.ts +215 -0
- package/dist/apipost-cli/node_modules/@types/node/ts4.8/tls.d.ts +1119 -0
- package/dist/apipost-cli/node_modules/@types/node/ts4.8/trace_events.d.ts +182 -0
- package/dist/apipost-cli/node_modules/@types/node/ts4.8/tty.d.ts +205 -0
- package/dist/apipost-cli/node_modules/@types/node/ts4.8/url.d.ts +901 -0
- package/dist/apipost-cli/node_modules/@types/node/ts4.8/util.d.ts +2052 -0
- package/dist/apipost-cli/node_modules/@types/node/ts4.8/v8.d.ts +635 -0
- package/dist/apipost-cli/node_modules/@types/node/ts4.8/vm.d.ts +894 -0
- package/dist/apipost-cli/node_modules/@types/node/ts4.8/wasi.d.ts +152 -0
- package/dist/apipost-cli/node_modules/@types/node/ts4.8/worker_threads.d.ts +693 -0
- package/dist/apipost-cli/node_modules/@types/node/ts4.8/zlib.d.ts +517 -0
- package/dist/apipost-cli/node_modules/bignumber.js/LICENCE.md +26 -0
- package/dist/apipost-cli/node_modules/bignumber.js/bignumber.d.ts +1831 -0
- package/dist/apipost-cli/node_modules/bignumber.js/bignumber.js +2926 -0
- package/dist/apipost-cli/node_modules/bignumber.js/bignumber.mjs +2889 -0
- package/dist/apipost-cli/node_modules/bignumber.js/doc/API.html +2249 -0
- package/dist/apipost-cli/node_modules/bignumber.js/package.json +50 -0
- package/dist/apipost-cli/node_modules/cpu-features/build/Release/obj.target/cpu_features/deps/cpu_features/src/filesystem.o +0 -0
- package/dist/apipost-cli/node_modules/cpu-features/build/Release/obj.target/cpu_features/deps/cpu_features/src/hwcaps.o +0 -0
- package/dist/apipost-cli/node_modules/cpu-features/build/Release/obj.target/cpu_features/deps/cpu_features/src/impl_aarch64_linux_or_android.o +0 -0
- package/dist/apipost-cli/node_modules/cpu-features/build/Release/obj.target/cpu_features/deps/cpu_features/src/impl_aarch64_macos_or_iphone.o +0 -0
- package/dist/apipost-cli/node_modules/cpu-features/build/Release/obj.target/cpu_features/deps/cpu_features/src/impl_arm_linux_or_android.o +0 -0
- package/dist/apipost-cli/node_modules/cpu-features/build/Release/obj.target/cpu_features/deps/cpu_features/src/impl_mips_linux_or_android.o +0 -0
- package/dist/apipost-cli/node_modules/cpu-features/build/Release/obj.target/cpu_features/deps/cpu_features/src/impl_ppc_linux.o +0 -0
- package/dist/apipost-cli/node_modules/cpu-features/build/Release/obj.target/cpu_features/deps/cpu_features/src/impl_x86_freebsd.o +0 -0
- package/dist/apipost-cli/node_modules/cpu-features/build/Release/obj.target/cpu_features/deps/cpu_features/src/impl_x86_linux_or_android.o +0 -0
- package/dist/apipost-cli/node_modules/cpu-features/build/Release/obj.target/cpu_features/deps/cpu_features/src/impl_x86_macos.o +0 -0
- package/dist/apipost-cli/node_modules/cpu-features/build/Release/obj.target/cpu_features/deps/cpu_features/src/impl_x86_windows.o +0 -0
- package/dist/apipost-cli/node_modules/cpu-features/build/Release/obj.target/cpu_features/deps/cpu_features/src/stack_line_reader.o +0 -0
- package/dist/apipost-cli/node_modules/cpu-features/build/Release/obj.target/cpu_features/deps/cpu_features/src/string_view.o +0 -0
- package/dist/apipost-cli/node_modules/cpu-features/build/Release/obj.target/cpufeatures/src/binding.o +0 -0
- package/dist/apipost-cli/node_modules/des.js/lib/des/cbc.js +65 -0
- package/dist/apipost-cli/node_modules/des.js/lib/des/cipher.js +142 -0
- package/dist/apipost-cli/node_modules/des.js/lib/des/des.js +150 -0
- package/dist/apipost-cli/node_modules/des.js/lib/des/ede.js +54 -0
- package/dist/apipost-cli/node_modules/des.js/lib/des/utils.js +256 -0
- package/dist/apipost-cli/node_modules/des.js/lib/des.js +7 -0
- package/dist/apipost-cli/node_modules/des.js/package.json +33 -0
- package/dist/apipost-cli/node_modules/des.js/test/cbc-test.js +73 -0
- package/dist/apipost-cli/node_modules/des.js/test/des-test.js +139 -0
- package/dist/apipost-cli/node_modules/des.js/test/ede-test.js +106 -0
- package/dist/apipost-cli/node_modules/des.js/test/fixtures.js +5 -0
- package/dist/apipost-cli/node_modules/des.js/test/utils-test.js +169 -0
- package/dist/apipost-cli/node_modules/fs.realpath/LICENSE +43 -0
- package/dist/apipost-cli/node_modules/fs.realpath/index.js +66 -0
- package/dist/apipost-cli/node_modules/fs.realpath/old.js +303 -0
- package/dist/apipost-cli/node_modules/fs.realpath/package.json +26 -0
- package/dist/apipost-cli/node_modules/function.prototype.name/LICENSE +21 -0
- package/dist/apipost-cli/node_modules/function.prototype.name/auto.js +3 -0
- package/dist/apipost-cli/node_modules/function.prototype.name/helpers/functionsHaveNames.js +5 -0
- package/dist/apipost-cli/node_modules/function.prototype.name/implementation.js +43 -0
- package/dist/apipost-cli/node_modules/function.prototype.name/index.js +18 -0
- package/dist/apipost-cli/node_modules/function.prototype.name/package.json +80 -0
- package/dist/apipost-cli/node_modules/function.prototype.name/polyfill.js +7 -0
- package/dist/apipost-cli/node_modules/function.prototype.name/shim.js +35 -0
- package/dist/apipost-cli/node_modules/function.prototype.name/test/implementation.js +20 -0
- package/dist/apipost-cli/node_modules/function.prototype.name/test/index.js +23 -0
- package/dist/apipost-cli/node_modules/function.prototype.name/test/shimmed.js +21 -0
- package/dist/apipost-cli/node_modules/function.prototype.name/test/tests.js +60 -0
- package/dist/apipost-cli/node_modules/function.prototype.name/test/uglified.js +17 -0
- package/dist/apipost-cli/node_modules/lodash.camelcase/LICENSE +47 -0
- package/dist/apipost-cli/node_modules/lodash.camelcase/index.js +599 -0
- package/dist/apipost-cli/node_modules/lodash.camelcase/package.json +17 -0
- package/dist/apipost-cli/node_modules/lodash.memoize/LICENSE +47 -0
- package/dist/apipost-cli/node_modules/lodash.memoize/index.js +676 -0
- package/dist/apipost-cli/node_modules/lodash.memoize/package.json +17 -0
- package/dist/apipost-cli/node_modules/lodash.uniq/LICENSE +47 -0
- package/dist/apipost-cli/node_modules/lodash.uniq/index.js +896 -0
- package/dist/apipost-cli/node_modules/lodash.uniq/package.json +17 -0
- package/dist/apipost-cli/node_modules/moment/ts3.1-typings/moment.d.ts +785 -0
- package/dist/apipost-cli/node_modules/oauth-1.0a/LICENSE +20 -0
- package/dist/apipost-cli/node_modules/oauth-1.0a/Makefile +36 -0
- package/dist/apipost-cli/node_modules/oauth-1.0a/oauth-1.0a.d.ts +192 -0
- package/dist/apipost-cli/node_modules/oauth-1.0a/oauth-1.0a.js +377 -0
- package/dist/apipost-cli/node_modules/oauth-1.0a/package.json +30 -0
- package/dist/apipost-cli/node_modules/oauth-1.0a/test/getParameterString.js +21 -0
- package/dist/apipost-cli/node_modules/oauth-1.0a/test/mocha.opts +4 -0
- package/dist/apipost-cli/node_modules/oauth-1.0a/test/oauth_body_hash.js +141 -0
- package/dist/apipost-cli/node_modules/oauth-1.0a/test/options/consumer.js +14 -0
- package/dist/apipost-cli/node_modules/oauth-1.0a/test/options/last_ampersand.js +55 -0
- package/dist/apipost-cli/node_modules/oauth-1.0a/test/options/multiple_values.js +54 -0
- package/dist/apipost-cli/node_modules/oauth-1.0a/test/options/multiple_values_qs.js +50 -0
- package/dist/apipost-cli/node_modules/oauth-1.0a/test/options/nonce_length.js +44 -0
- package/dist/apipost-cli/node_modules/oauth-1.0a/test/options/parameter_seperator.js +102 -0
- package/dist/apipost-cli/node_modules/oauth-1.0a/test/options/realm.js +51 -0
- package/dist/apipost-cli/node_modules/oauth-1.0a/test/options/signature_method.js +36 -0
- package/dist/apipost-cli/node_modules/oauth-1.0a/test/services/bitbucket.js +88 -0
- package/dist/apipost-cli/node_modules/oauth-1.0a/test/services/flickr.js +196 -0
- package/dist/apipost-cli/node_modules/oauth-1.0a/test/services/openbank.js +61 -0
- package/dist/apipost-cli/node_modules/oauth-1.0a/test/services/twitter.js +183 -0
- package/dist/apipost-cli/node_modules/oauth-1.0a/test/twitter_sample_data.js +94 -0
- package/dist/apipost-cli/node_modules/object.assign/LICENSE +21 -0
- package/dist/apipost-cli/node_modules/object.assign/auto.js +3 -0
- package/dist/apipost-cli/node_modules/object.assign/dist/browser.js +944 -0
- package/dist/apipost-cli/node_modules/object.assign/hasSymbols.js +43 -0
- package/dist/apipost-cli/node_modules/object.assign/implementation.js +46 -0
- package/dist/apipost-cli/node_modules/object.assign/index.js +22 -0
- package/dist/apipost-cli/node_modules/object.assign/package.json +96 -0
- package/dist/apipost-cli/node_modules/object.assign/polyfill.js +55 -0
- package/dist/apipost-cli/node_modules/object.assign/shim.js +14 -0
- package/dist/apipost-cli/node_modules/object.assign/test/implementation.js +19 -0
- package/dist/apipost-cli/node_modules/object.assign/test/index.js +17 -0
- package/dist/apipost-cli/node_modules/object.assign/test/native.js +49 -0
- package/dist/apipost-cli/node_modules/object.assign/test/ses-compat.js +12 -0
- package/dist/apipost-cli/node_modules/object.assign/test/shimmed.js +52 -0
- package/dist/apipost-cli/node_modules/object.assign/test/tests.js +232 -0
- package/dist/apipost-cli/node_modules/object.assign/test.html +18458 -0
- package/dist/apipost-cli/node_modules/promise.series/LICENSE +21 -0
- package/dist/apipost-cli/node_modules/promise.series/index.js +10 -0
- package/dist/apipost-cli/node_modules/promise.series/package.json +34 -0
- package/dist/apipost-cli/node_modules/regexp.prototype.flags/LICENSE +22 -0
- package/dist/apipost-cli/node_modules/regexp.prototype.flags/auto.js +3 -0
- package/dist/apipost-cli/node_modules/regexp.prototype.flags/implementation.js +42 -0
- package/dist/apipost-cli/node_modules/regexp.prototype.flags/index.js +18 -0
- package/dist/apipost-cli/node_modules/regexp.prototype.flags/package.json +100 -0
- package/dist/apipost-cli/node_modules/regexp.prototype.flags/polyfill.js +36 -0
- package/dist/apipost-cli/node_modules/regexp.prototype.flags/shim.js +26 -0
- package/dist/apipost-cli/node_modules/regexp.prototype.flags/test/implementation.js +20 -0
- package/dist/apipost-cli/node_modules/regexp.prototype.flags/test/index.js +17 -0
- package/dist/apipost-cli/node_modules/regexp.prototype.flags/test/shimmed.js +48 -0
- package/dist/apipost-cli/node_modules/regexp.prototype.flags/test/tests.js +143 -0
- package/dist/apipost-cli/node_modules/resolve.exports/dist/index.js +1 -0
- package/dist/apipost-cli/node_modules/resolve.exports/dist/index.mjs +1 -0
- package/dist/apipost-cli/node_modules/resolve.exports/index.d.ts +100 -0
- package/dist/apipost-cli/node_modules/resolve.exports/license +21 -0
- package/dist/apipost-cli/node_modules/resolve.exports/package.json +50 -0
- package/dist/apipost-cli/node_modules/ssh2/lib/protocol/crypto/build/Release/obj.target/sshcrypto/src/binding.o +0 -0
- package/dist/apipost-cli/node_modules/string.prototype.trim/LICENSE +21 -0
- package/dist/apipost-cli/node_modules/string.prototype.trim/auto.js +3 -0
- package/dist/apipost-cli/node_modules/string.prototype.trim/implementation.js +21 -0
- package/dist/apipost-cli/node_modules/string.prototype.trim/index.js +23 -0
- package/dist/apipost-cli/node_modules/string.prototype.trim/package.json +101 -0
- package/dist/apipost-cli/node_modules/string.prototype.trim/polyfill.js +19 -0
- package/dist/apipost-cli/node_modules/string.prototype.trim/shim.js +14 -0
- package/dist/apipost-cli/node_modules/string.prototype.trim/test/implementation.js +21 -0
- package/dist/apipost-cli/node_modules/string.prototype.trim/test/index.js +17 -0
- package/dist/apipost-cli/node_modules/string.prototype.trim/test/shimmed.js +36 -0
- package/dist/apipost-cli/node_modules/string.prototype.trim/test/tests.js +45 -0
- package/dist/apipost-cli/node_modules/string.prototype.trimend/LICENSE +21 -0
- package/dist/apipost-cli/node_modules/string.prototype.trimend/auto.js +3 -0
- package/dist/apipost-cli/node_modules/string.prototype.trimend/implementation.js +15 -0
- package/dist/apipost-cli/node_modules/string.prototype.trimend/index.js +23 -0
- package/dist/apipost-cli/node_modules/string.prototype.trimend/package.json +79 -0
- package/dist/apipost-cli/node_modules/string.prototype.trimend/polyfill.js +15 -0
- package/dist/apipost-cli/node_modules/string.prototype.trimend/shim.js +14 -0
- package/dist/apipost-cli/node_modules/string.prototype.trimend/test/implementation.js +20 -0
- package/dist/apipost-cli/node_modules/string.prototype.trimend/test/index.js +17 -0
- package/dist/apipost-cli/node_modules/string.prototype.trimend/test/shimmed.js +36 -0
- package/dist/apipost-cli/node_modules/string.prototype.trimend/test/tests.js +31 -0
- package/dist/apipost-cli/node_modules/string.prototype.trimstart/LICENSE +21 -0
- package/dist/apipost-cli/node_modules/string.prototype.trimstart/auto.js +3 -0
- package/dist/apipost-cli/node_modules/string.prototype.trimstart/implementation.js +15 -0
- package/dist/apipost-cli/node_modules/string.prototype.trimstart/index.js +23 -0
- package/dist/apipost-cli/node_modules/string.prototype.trimstart/package.json +79 -0
- package/dist/apipost-cli/node_modules/string.prototype.trimstart/polyfill.js +15 -0
- package/dist/apipost-cli/node_modules/string.prototype.trimstart/shim.js +14 -0
- package/dist/apipost-cli/node_modules/string.prototype.trimstart/test/implementation.js +20 -0
- package/dist/apipost-cli/node_modules/string.prototype.trimstart/test/index.js +18 -0
- package/dist/apipost-cli/node_modules/string.prototype.trimstart/test/shimmed.js +36 -0
- package/dist/apipost-cli/node_modules/string.prototype.trimstart/test/tests.js +31 -0
- package/dist/apipost-cli/node_modules/web-streams-polyfill/dist/types/ts3.6/polyfill.d.ts +771 -0
- package/dist/apipost-http-schema.json +129 -0
- package/dist/bridge.js +1010 -0
- package/dist/build/Release/cpufeatures.node +0 -0
- package/dist/esprima.js +3756 -0
- package/dist/events.js +977 -0
- package/dist/index.js +565958 -0
- package/dist/index1.js +26 -0
- package/dist/lib/protocol/crypto/build/Release/sshcrypto.node +0 -0
- package/dist/module.js +34 -0
- package/dist/pagent.exe +0 -0
- package/dist/setup-node-sandbox.js +461 -0
- package/dist/setup-sandbox.js +545 -0
- package/dist/snappy.darwin-arm64.node +0 -0
- package/dist/xdg-open +1066 -0
- package/package.json +13 -4
- package/bin/cli.js +0 -216
- package/bin/template.js +0 -803
- /package/{bin → dist/apipost-cli}/apipost-reports//346/265/213/350/257/225.html" +0 -0
- /package/{bin → dist/apipost-cli}/apipost-reports//346/265/213/350/257/225.json" +0 -0
|
@@ -0,0 +1,256 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
|
|
3
|
+
exports.readUInt32BE = function readUInt32BE(bytes, off) {
|
|
4
|
+
var res = (bytes[0 + off] << 24) |
|
|
5
|
+
(bytes[1 + off] << 16) |
|
|
6
|
+
(bytes[2 + off] << 8) |
|
|
7
|
+
bytes[3 + off];
|
|
8
|
+
return res >>> 0;
|
|
9
|
+
};
|
|
10
|
+
|
|
11
|
+
exports.writeUInt32BE = function writeUInt32BE(bytes, value, off) {
|
|
12
|
+
bytes[0 + off] = value >>> 24;
|
|
13
|
+
bytes[1 + off] = (value >>> 16) & 0xff;
|
|
14
|
+
bytes[2 + off] = (value >>> 8) & 0xff;
|
|
15
|
+
bytes[3 + off] = value & 0xff;
|
|
16
|
+
};
|
|
17
|
+
|
|
18
|
+
exports.ip = function ip(inL, inR, out, off) {
|
|
19
|
+
var outL = 0;
|
|
20
|
+
var outR = 0;
|
|
21
|
+
|
|
22
|
+
for (var i = 6; i >= 0; i -= 2) {
|
|
23
|
+
for (var j = 0; j <= 24; j += 8) {
|
|
24
|
+
outL <<= 1;
|
|
25
|
+
outL |= (inR >>> (j + i)) & 1;
|
|
26
|
+
}
|
|
27
|
+
for (var j = 0; j <= 24; j += 8) {
|
|
28
|
+
outL <<= 1;
|
|
29
|
+
outL |= (inL >>> (j + i)) & 1;
|
|
30
|
+
}
|
|
31
|
+
}
|
|
32
|
+
|
|
33
|
+
for (var i = 6; i >= 0; i -= 2) {
|
|
34
|
+
for (var j = 1; j <= 25; j += 8) {
|
|
35
|
+
outR <<= 1;
|
|
36
|
+
outR |= (inR >>> (j + i)) & 1;
|
|
37
|
+
}
|
|
38
|
+
for (var j = 1; j <= 25; j += 8) {
|
|
39
|
+
outR <<= 1;
|
|
40
|
+
outR |= (inL >>> (j + i)) & 1;
|
|
41
|
+
}
|
|
42
|
+
}
|
|
43
|
+
|
|
44
|
+
out[off + 0] = outL >>> 0;
|
|
45
|
+
out[off + 1] = outR >>> 0;
|
|
46
|
+
};
|
|
47
|
+
|
|
48
|
+
exports.rip = function rip(inL, inR, out, off) {
|
|
49
|
+
var outL = 0;
|
|
50
|
+
var outR = 0;
|
|
51
|
+
|
|
52
|
+
for (var i = 0; i < 4; i++) {
|
|
53
|
+
for (var j = 24; j >= 0; j -= 8) {
|
|
54
|
+
outL <<= 1;
|
|
55
|
+
outL |= (inR >>> (j + i)) & 1;
|
|
56
|
+
outL <<= 1;
|
|
57
|
+
outL |= (inL >>> (j + i)) & 1;
|
|
58
|
+
}
|
|
59
|
+
}
|
|
60
|
+
for (var i = 4; i < 8; i++) {
|
|
61
|
+
for (var j = 24; j >= 0; j -= 8) {
|
|
62
|
+
outR <<= 1;
|
|
63
|
+
outR |= (inR >>> (j + i)) & 1;
|
|
64
|
+
outR <<= 1;
|
|
65
|
+
outR |= (inL >>> (j + i)) & 1;
|
|
66
|
+
}
|
|
67
|
+
}
|
|
68
|
+
|
|
69
|
+
out[off + 0] = outL >>> 0;
|
|
70
|
+
out[off + 1] = outR >>> 0;
|
|
71
|
+
};
|
|
72
|
+
|
|
73
|
+
exports.pc1 = function pc1(inL, inR, out, off) {
|
|
74
|
+
var outL = 0;
|
|
75
|
+
var outR = 0;
|
|
76
|
+
|
|
77
|
+
// 7, 15, 23, 31, 39, 47, 55, 63
|
|
78
|
+
// 6, 14, 22, 30, 39, 47, 55, 63
|
|
79
|
+
// 5, 13, 21, 29, 39, 47, 55, 63
|
|
80
|
+
// 4, 12, 20, 28
|
|
81
|
+
for (var i = 7; i >= 5; i--) {
|
|
82
|
+
for (var j = 0; j <= 24; j += 8) {
|
|
83
|
+
outL <<= 1;
|
|
84
|
+
outL |= (inR >> (j + i)) & 1;
|
|
85
|
+
}
|
|
86
|
+
for (var j = 0; j <= 24; j += 8) {
|
|
87
|
+
outL <<= 1;
|
|
88
|
+
outL |= (inL >> (j + i)) & 1;
|
|
89
|
+
}
|
|
90
|
+
}
|
|
91
|
+
for (var j = 0; j <= 24; j += 8) {
|
|
92
|
+
outL <<= 1;
|
|
93
|
+
outL |= (inR >> (j + i)) & 1;
|
|
94
|
+
}
|
|
95
|
+
|
|
96
|
+
// 1, 9, 17, 25, 33, 41, 49, 57
|
|
97
|
+
// 2, 10, 18, 26, 34, 42, 50, 58
|
|
98
|
+
// 3, 11, 19, 27, 35, 43, 51, 59
|
|
99
|
+
// 36, 44, 52, 60
|
|
100
|
+
for (var i = 1; i <= 3; i++) {
|
|
101
|
+
for (var j = 0; j <= 24; j += 8) {
|
|
102
|
+
outR <<= 1;
|
|
103
|
+
outR |= (inR >> (j + i)) & 1;
|
|
104
|
+
}
|
|
105
|
+
for (var j = 0; j <= 24; j += 8) {
|
|
106
|
+
outR <<= 1;
|
|
107
|
+
outR |= (inL >> (j + i)) & 1;
|
|
108
|
+
}
|
|
109
|
+
}
|
|
110
|
+
for (var j = 0; j <= 24; j += 8) {
|
|
111
|
+
outR <<= 1;
|
|
112
|
+
outR |= (inL >> (j + i)) & 1;
|
|
113
|
+
}
|
|
114
|
+
|
|
115
|
+
out[off + 0] = outL >>> 0;
|
|
116
|
+
out[off + 1] = outR >>> 0;
|
|
117
|
+
};
|
|
118
|
+
|
|
119
|
+
exports.r28shl = function r28shl(num, shift) {
|
|
120
|
+
return ((num << shift) & 0xfffffff) | (num >>> (28 - shift));
|
|
121
|
+
};
|
|
122
|
+
|
|
123
|
+
var pc2table = [
|
|
124
|
+
// inL => outL
|
|
125
|
+
14, 11, 17, 4, 27, 23, 25, 0,
|
|
126
|
+
13, 22, 7, 18, 5, 9, 16, 24,
|
|
127
|
+
2, 20, 12, 21, 1, 8, 15, 26,
|
|
128
|
+
|
|
129
|
+
// inR => outR
|
|
130
|
+
15, 4, 25, 19, 9, 1, 26, 16,
|
|
131
|
+
5, 11, 23, 8, 12, 7, 17, 0,
|
|
132
|
+
22, 3, 10, 14, 6, 20, 27, 24
|
|
133
|
+
];
|
|
134
|
+
|
|
135
|
+
exports.pc2 = function pc2(inL, inR, out, off) {
|
|
136
|
+
var outL = 0;
|
|
137
|
+
var outR = 0;
|
|
138
|
+
|
|
139
|
+
var len = pc2table.length >>> 1;
|
|
140
|
+
for (var i = 0; i < len; i++) {
|
|
141
|
+
outL <<= 1;
|
|
142
|
+
outL |= (inL >>> pc2table[i]) & 0x1;
|
|
143
|
+
}
|
|
144
|
+
for (var i = len; i < pc2table.length; i++) {
|
|
145
|
+
outR <<= 1;
|
|
146
|
+
outR |= (inR >>> pc2table[i]) & 0x1;
|
|
147
|
+
}
|
|
148
|
+
|
|
149
|
+
out[off + 0] = outL >>> 0;
|
|
150
|
+
out[off + 1] = outR >>> 0;
|
|
151
|
+
};
|
|
152
|
+
|
|
153
|
+
exports.expand = function expand(r, out, off) {
|
|
154
|
+
var outL = 0;
|
|
155
|
+
var outR = 0;
|
|
156
|
+
|
|
157
|
+
outL = ((r & 1) << 5) | (r >>> 27);
|
|
158
|
+
for (var i = 23; i >= 15; i -= 4) {
|
|
159
|
+
outL <<= 6;
|
|
160
|
+
outL |= (r >>> i) & 0x3f;
|
|
161
|
+
}
|
|
162
|
+
for (var i = 11; i >= 3; i -= 4) {
|
|
163
|
+
outR |= (r >>> i) & 0x3f;
|
|
164
|
+
outR <<= 6;
|
|
165
|
+
}
|
|
166
|
+
outR |= ((r & 0x1f) << 1) | (r >>> 31);
|
|
167
|
+
|
|
168
|
+
out[off + 0] = outL >>> 0;
|
|
169
|
+
out[off + 1] = outR >>> 0;
|
|
170
|
+
};
|
|
171
|
+
|
|
172
|
+
var sTable = [
|
|
173
|
+
14, 0, 4, 15, 13, 7, 1, 4, 2, 14, 15, 2, 11, 13, 8, 1,
|
|
174
|
+
3, 10, 10, 6, 6, 12, 12, 11, 5, 9, 9, 5, 0, 3, 7, 8,
|
|
175
|
+
4, 15, 1, 12, 14, 8, 8, 2, 13, 4, 6, 9, 2, 1, 11, 7,
|
|
176
|
+
15, 5, 12, 11, 9, 3, 7, 14, 3, 10, 10, 0, 5, 6, 0, 13,
|
|
177
|
+
|
|
178
|
+
15, 3, 1, 13, 8, 4, 14, 7, 6, 15, 11, 2, 3, 8, 4, 14,
|
|
179
|
+
9, 12, 7, 0, 2, 1, 13, 10, 12, 6, 0, 9, 5, 11, 10, 5,
|
|
180
|
+
0, 13, 14, 8, 7, 10, 11, 1, 10, 3, 4, 15, 13, 4, 1, 2,
|
|
181
|
+
5, 11, 8, 6, 12, 7, 6, 12, 9, 0, 3, 5, 2, 14, 15, 9,
|
|
182
|
+
|
|
183
|
+
10, 13, 0, 7, 9, 0, 14, 9, 6, 3, 3, 4, 15, 6, 5, 10,
|
|
184
|
+
1, 2, 13, 8, 12, 5, 7, 14, 11, 12, 4, 11, 2, 15, 8, 1,
|
|
185
|
+
13, 1, 6, 10, 4, 13, 9, 0, 8, 6, 15, 9, 3, 8, 0, 7,
|
|
186
|
+
11, 4, 1, 15, 2, 14, 12, 3, 5, 11, 10, 5, 14, 2, 7, 12,
|
|
187
|
+
|
|
188
|
+
7, 13, 13, 8, 14, 11, 3, 5, 0, 6, 6, 15, 9, 0, 10, 3,
|
|
189
|
+
1, 4, 2, 7, 8, 2, 5, 12, 11, 1, 12, 10, 4, 14, 15, 9,
|
|
190
|
+
10, 3, 6, 15, 9, 0, 0, 6, 12, 10, 11, 1, 7, 13, 13, 8,
|
|
191
|
+
15, 9, 1, 4, 3, 5, 14, 11, 5, 12, 2, 7, 8, 2, 4, 14,
|
|
192
|
+
|
|
193
|
+
2, 14, 12, 11, 4, 2, 1, 12, 7, 4, 10, 7, 11, 13, 6, 1,
|
|
194
|
+
8, 5, 5, 0, 3, 15, 15, 10, 13, 3, 0, 9, 14, 8, 9, 6,
|
|
195
|
+
4, 11, 2, 8, 1, 12, 11, 7, 10, 1, 13, 14, 7, 2, 8, 13,
|
|
196
|
+
15, 6, 9, 15, 12, 0, 5, 9, 6, 10, 3, 4, 0, 5, 14, 3,
|
|
197
|
+
|
|
198
|
+
12, 10, 1, 15, 10, 4, 15, 2, 9, 7, 2, 12, 6, 9, 8, 5,
|
|
199
|
+
0, 6, 13, 1, 3, 13, 4, 14, 14, 0, 7, 11, 5, 3, 11, 8,
|
|
200
|
+
9, 4, 14, 3, 15, 2, 5, 12, 2, 9, 8, 5, 12, 15, 3, 10,
|
|
201
|
+
7, 11, 0, 14, 4, 1, 10, 7, 1, 6, 13, 0, 11, 8, 6, 13,
|
|
202
|
+
|
|
203
|
+
4, 13, 11, 0, 2, 11, 14, 7, 15, 4, 0, 9, 8, 1, 13, 10,
|
|
204
|
+
3, 14, 12, 3, 9, 5, 7, 12, 5, 2, 10, 15, 6, 8, 1, 6,
|
|
205
|
+
1, 6, 4, 11, 11, 13, 13, 8, 12, 1, 3, 4, 7, 10, 14, 7,
|
|
206
|
+
10, 9, 15, 5, 6, 0, 8, 15, 0, 14, 5, 2, 9, 3, 2, 12,
|
|
207
|
+
|
|
208
|
+
13, 1, 2, 15, 8, 13, 4, 8, 6, 10, 15, 3, 11, 7, 1, 4,
|
|
209
|
+
10, 12, 9, 5, 3, 6, 14, 11, 5, 0, 0, 14, 12, 9, 7, 2,
|
|
210
|
+
7, 2, 11, 1, 4, 14, 1, 7, 9, 4, 12, 10, 14, 8, 2, 13,
|
|
211
|
+
0, 15, 6, 12, 10, 9, 13, 0, 15, 3, 3, 5, 5, 6, 8, 11
|
|
212
|
+
];
|
|
213
|
+
|
|
214
|
+
exports.substitute = function substitute(inL, inR) {
|
|
215
|
+
var out = 0;
|
|
216
|
+
for (var i = 0; i < 4; i++) {
|
|
217
|
+
var b = (inL >>> (18 - i * 6)) & 0x3f;
|
|
218
|
+
var sb = sTable[i * 0x40 + b];
|
|
219
|
+
|
|
220
|
+
out <<= 4;
|
|
221
|
+
out |= sb;
|
|
222
|
+
}
|
|
223
|
+
for (var i = 0; i < 4; i++) {
|
|
224
|
+
var b = (inR >>> (18 - i * 6)) & 0x3f;
|
|
225
|
+
var sb = sTable[4 * 0x40 + i * 0x40 + b];
|
|
226
|
+
|
|
227
|
+
out <<= 4;
|
|
228
|
+
out |= sb;
|
|
229
|
+
}
|
|
230
|
+
return out >>> 0;
|
|
231
|
+
};
|
|
232
|
+
|
|
233
|
+
var permuteTable = [
|
|
234
|
+
16, 25, 12, 11, 3, 20, 4, 15, 31, 17, 9, 6, 27, 14, 1, 22,
|
|
235
|
+
30, 24, 8, 18, 0, 5, 29, 23, 13, 19, 2, 26, 10, 21, 28, 7
|
|
236
|
+
];
|
|
237
|
+
|
|
238
|
+
exports.permute = function permute(num) {
|
|
239
|
+
var out = 0;
|
|
240
|
+
for (var i = 0; i < permuteTable.length; i++) {
|
|
241
|
+
out <<= 1;
|
|
242
|
+
out |= (num >>> permuteTable[i]) & 0x1;
|
|
243
|
+
}
|
|
244
|
+
return out >>> 0;
|
|
245
|
+
};
|
|
246
|
+
|
|
247
|
+
exports.padSplit = function padSplit(num, size, group) {
|
|
248
|
+
var str = num.toString(2);
|
|
249
|
+
while (str.length < size)
|
|
250
|
+
str = '0' + str;
|
|
251
|
+
|
|
252
|
+
var out = [];
|
|
253
|
+
for (var i = 0; i < size; i += group)
|
|
254
|
+
out.push(str.slice(i, i + group));
|
|
255
|
+
return out.join(' ');
|
|
256
|
+
};
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "des.js",
|
|
3
|
+
"version": "1.1.0",
|
|
4
|
+
"description": "DES implementation",
|
|
5
|
+
"main": "lib/des.js",
|
|
6
|
+
"scripts": {
|
|
7
|
+
"test": "NODE_OPTIONS=--openssl-legacy-provider mocha --reporter=spec test/*-test.js"
|
|
8
|
+
},
|
|
9
|
+
"repository": {
|
|
10
|
+
"type": "git",
|
|
11
|
+
"url": "git+ssh://git@github.com/indutny/des.js.git"
|
|
12
|
+
},
|
|
13
|
+
"keywords": [
|
|
14
|
+
"DES",
|
|
15
|
+
"3DES",
|
|
16
|
+
"EDE",
|
|
17
|
+
"CBC"
|
|
18
|
+
],
|
|
19
|
+
"author": "Fedor Indutny <fedor@indutny.com>",
|
|
20
|
+
"license": "MIT",
|
|
21
|
+
"bugs": {
|
|
22
|
+
"url": "https://github.com/indutny/des.js/issues"
|
|
23
|
+
},
|
|
24
|
+
"homepage": "https://github.com/indutny/des.js#readme",
|
|
25
|
+
"devDependencies": {
|
|
26
|
+
"jshint": "^2.8.0",
|
|
27
|
+
"mocha": "^10.2.0"
|
|
28
|
+
},
|
|
29
|
+
"dependencies": {
|
|
30
|
+
"inherits": "^2.0.1",
|
|
31
|
+
"minimalistic-assert": "^1.0.0"
|
|
32
|
+
}
|
|
33
|
+
}
|
|
@@ -0,0 +1,73 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
|
|
3
|
+
var assert = require('assert');
|
|
4
|
+
var crypto = require('crypto');
|
|
5
|
+
var Buffer = require('buffer').Buffer;
|
|
6
|
+
|
|
7
|
+
var des = require('../');
|
|
8
|
+
|
|
9
|
+
var fixtures = require('./fixtures');
|
|
10
|
+
var bin = fixtures.bin;
|
|
11
|
+
|
|
12
|
+
describe('DES-CBC', function() {
|
|
13
|
+
var CBC = des.CBC.instantiate(des.DES);
|
|
14
|
+
|
|
15
|
+
describe('encryption/decryption', function() {
|
|
16
|
+
var vectors = [
|
|
17
|
+
{
|
|
18
|
+
key: '133457799bbcdff1',
|
|
19
|
+
iv: '0102030405060708',
|
|
20
|
+
input: '0123456789abcdef'
|
|
21
|
+
},
|
|
22
|
+
{
|
|
23
|
+
key: '0000000000000000',
|
|
24
|
+
iv: 'ffffffffffffffff',
|
|
25
|
+
input: '0000000000000000'
|
|
26
|
+
},
|
|
27
|
+
{
|
|
28
|
+
key: 'a3a3a3a3b3b3b3b3',
|
|
29
|
+
iv: 'cdcdcdcdcdcdcdcd',
|
|
30
|
+
input: 'cccccccccccccccc'
|
|
31
|
+
},
|
|
32
|
+
{
|
|
33
|
+
key: 'deadbeefabbadead',
|
|
34
|
+
iv: 'a0da0da0da0da0da',
|
|
35
|
+
input: '0102030405060708090a'
|
|
36
|
+
},
|
|
37
|
+
{
|
|
38
|
+
key: 'aabbccddeeff0011',
|
|
39
|
+
iv: 'fefefefefefefefe',
|
|
40
|
+
input: '0102030405060708090a0102030405060708090a0102030405060708090a' +
|
|
41
|
+
'0102030405060708090a0102030405060607080a0102030405060708090a'
|
|
42
|
+
}
|
|
43
|
+
];
|
|
44
|
+
|
|
45
|
+
vectors.forEach(function(vec, i) {
|
|
46
|
+
it('should encrypt vector ' + i, function() {
|
|
47
|
+
var key = Buffer.from(vec.key, 'hex');
|
|
48
|
+
var iv = Buffer.from(vec.iv, 'hex');
|
|
49
|
+
var input = Buffer.from(vec.input, 'hex');
|
|
50
|
+
|
|
51
|
+
var enc = CBC.create({
|
|
52
|
+
type: 'encrypt',
|
|
53
|
+
key: key,
|
|
54
|
+
iv: iv
|
|
55
|
+
});
|
|
56
|
+
var out = Buffer.from(enc.update(input).concat(enc.final()));
|
|
57
|
+
|
|
58
|
+
var cipher = crypto.createCipheriv('des-cbc', key, iv);
|
|
59
|
+
var expected = Buffer.concat([ cipher.update(input), cipher.final() ]);
|
|
60
|
+
|
|
61
|
+
assert.deepEqual(out, expected);
|
|
62
|
+
|
|
63
|
+
var dec = CBC.create({
|
|
64
|
+
type: 'decrypt',
|
|
65
|
+
key: key,
|
|
66
|
+
iv: iv
|
|
67
|
+
});
|
|
68
|
+
assert.deepEqual(Buffer.from(dec.update(out).concat(dec.final())),
|
|
69
|
+
input);
|
|
70
|
+
});
|
|
71
|
+
});
|
|
72
|
+
});
|
|
73
|
+
});
|
|
@@ -0,0 +1,139 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
|
|
3
|
+
var assert = require('assert');
|
|
4
|
+
var crypto = require('crypto');
|
|
5
|
+
var Buffer = require('buffer').Buffer;
|
|
6
|
+
|
|
7
|
+
var des = require('../');
|
|
8
|
+
|
|
9
|
+
var fixtures = require('./fixtures');
|
|
10
|
+
var bin = fixtures.bin;
|
|
11
|
+
|
|
12
|
+
describe('DES', function() {
|
|
13
|
+
describe('Key Derivation', function() {
|
|
14
|
+
it('should derive proper keys', function() {
|
|
15
|
+
var d = des.DES.create({
|
|
16
|
+
type: 'encrypt',
|
|
17
|
+
key: [ 0x13, 0x34, 0x57, 0x79, 0x9B, 0xBC, 0xDF, 0xF1 ]
|
|
18
|
+
});
|
|
19
|
+
|
|
20
|
+
var expected = [
|
|
21
|
+
'000110 110000 001011 101111',
|
|
22
|
+
'111111 000111 000001 110010',
|
|
23
|
+
'011110 011010 111011 011001',
|
|
24
|
+
'110110 111100 100111 100101',
|
|
25
|
+
'010101 011111 110010 001010',
|
|
26
|
+
'010000 101100 111110 011001',
|
|
27
|
+
'011100 101010 110111 010110',
|
|
28
|
+
'110110 110011 010100 011101',
|
|
29
|
+
'011111 001110 110000 000111',
|
|
30
|
+
'111010 110101 001110 101000',
|
|
31
|
+
'011000 111010 010100 111110',
|
|
32
|
+
'010100 000111 101100 101111',
|
|
33
|
+
'111011 001000 010010 110111',
|
|
34
|
+
'111101 100001 100010 111100',
|
|
35
|
+
'111101 111000 101000 111010',
|
|
36
|
+
'110000 010011 101111 111011',
|
|
37
|
+
'111000 001101 101111 101011',
|
|
38
|
+
'111011 011110 011110 000001',
|
|
39
|
+
'101100 011111 001101 000111',
|
|
40
|
+
'101110 100100 011001 001111',
|
|
41
|
+
'001000 010101 111111 010011',
|
|
42
|
+
'110111 101101 001110 000110',
|
|
43
|
+
'011101 010111 000111 110101',
|
|
44
|
+
'100101 000110 011111 101001',
|
|
45
|
+
'100101 111100 010111 010001',
|
|
46
|
+
'111110 101011 101001 000001',
|
|
47
|
+
'010111 110100 001110 110111',
|
|
48
|
+
'111100 101110 011100 111010',
|
|
49
|
+
'101111 111001 000110 001101',
|
|
50
|
+
'001111 010011 111100 001010',
|
|
51
|
+
'110010 110011 110110 001011',
|
|
52
|
+
'000011 100001 011111 110101'
|
|
53
|
+
];
|
|
54
|
+
|
|
55
|
+
expected = expected.map(fixtures.bin);
|
|
56
|
+
assert.deepEqual(d._desState.keys, expected);
|
|
57
|
+
});
|
|
58
|
+
});
|
|
59
|
+
|
|
60
|
+
describe('encryption/decryption', function() {
|
|
61
|
+
var vectors = [
|
|
62
|
+
{
|
|
63
|
+
key: '133457799bbcdff1',
|
|
64
|
+
input: '0123456789abcdef'
|
|
65
|
+
},
|
|
66
|
+
{
|
|
67
|
+
key: '0000000000000000',
|
|
68
|
+
input: '0000000000000000'
|
|
69
|
+
},
|
|
70
|
+
{
|
|
71
|
+
key: 'a3a3a3a3b3b3b3b3',
|
|
72
|
+
input: 'cccccccccccccccc'
|
|
73
|
+
},
|
|
74
|
+
{
|
|
75
|
+
key: 'deadbeefabbadead',
|
|
76
|
+
input: '0102030405060708090a'
|
|
77
|
+
},
|
|
78
|
+
{
|
|
79
|
+
key: 'aabbccddeeff0011',
|
|
80
|
+
input: '0102030405060708090a0102030405060708090a0102030405060708090a' +
|
|
81
|
+
'0102030405060708090a0102030405060607080a0102030405060708090a'
|
|
82
|
+
}
|
|
83
|
+
];
|
|
84
|
+
|
|
85
|
+
vectors.forEach(function(vec, i) {
|
|
86
|
+
it('should encrypt vector ' + i, function() {
|
|
87
|
+
var key = Buffer.from(vec.key, 'hex');
|
|
88
|
+
var input = Buffer.from(vec.input, 'hex');
|
|
89
|
+
|
|
90
|
+
var enc = des.DES.create({
|
|
91
|
+
type: 'encrypt',
|
|
92
|
+
key: key
|
|
93
|
+
});
|
|
94
|
+
var dec = des.DES.create({
|
|
95
|
+
type: 'decrypt',
|
|
96
|
+
key: key
|
|
97
|
+
});
|
|
98
|
+
var out = Buffer.from(enc.update(input).concat(enc.final()));
|
|
99
|
+
|
|
100
|
+
var cipher = crypto.createCipheriv('des-ecb', key, Buffer.alloc(0));
|
|
101
|
+
var expected = Buffer.concat([ cipher.update(input), cipher.final() ]);
|
|
102
|
+
|
|
103
|
+
assert.deepEqual(out, expected);
|
|
104
|
+
|
|
105
|
+
assert.deepEqual(Buffer.from(dec.update(out).concat(dec.final())),
|
|
106
|
+
input);
|
|
107
|
+
});
|
|
108
|
+
});
|
|
109
|
+
|
|
110
|
+
it('should buffer during encryption/decryption', function() {
|
|
111
|
+
var key = Buffer.from('0102030405060708', 'hex');
|
|
112
|
+
var chunk = Buffer.from('01020304050607', 'hex');
|
|
113
|
+
var count = 257;
|
|
114
|
+
var expected = Buffer.from(
|
|
115
|
+
new Array(count + 1).join('01020304050607'), 'hex');
|
|
116
|
+
|
|
117
|
+
var enc = des.DES.create({
|
|
118
|
+
type: 'encrypt',
|
|
119
|
+
key: key
|
|
120
|
+
});
|
|
121
|
+
var cipher = [];
|
|
122
|
+
for (var i = 0; i < count; i++)
|
|
123
|
+
cipher = cipher.concat(enc.update(chunk));
|
|
124
|
+
cipher = cipher.concat(enc.final());
|
|
125
|
+
|
|
126
|
+
var dec = des.DES.create({
|
|
127
|
+
type: 'decrypt',
|
|
128
|
+
key: key
|
|
129
|
+
});
|
|
130
|
+
var out = [];
|
|
131
|
+
for (var i = 0; i < count; i++)
|
|
132
|
+
out = out.concat(dec.update(cipher.slice(i * 7, (i + 1) * 7)));
|
|
133
|
+
out = out.concat(dec.final(cipher.slice(i * 7)));
|
|
134
|
+
|
|
135
|
+
out = Buffer.from(out);
|
|
136
|
+
assert.deepEqual(out, expected);
|
|
137
|
+
});
|
|
138
|
+
});
|
|
139
|
+
});
|
|
@@ -0,0 +1,106 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
|
|
3
|
+
var assert = require('assert');
|
|
4
|
+
var crypto = require('crypto');
|
|
5
|
+
var Buffer = require('buffer').Buffer;
|
|
6
|
+
|
|
7
|
+
var des = require('../');
|
|
8
|
+
|
|
9
|
+
var fixtures = require('./fixtures');
|
|
10
|
+
var bin = fixtures.bin;
|
|
11
|
+
|
|
12
|
+
describe('DES-EDE-CBC', function() {
|
|
13
|
+
var CBC = des.CBC.instantiate(des.EDE);
|
|
14
|
+
|
|
15
|
+
describe('encryption/decryption', function() {
|
|
16
|
+
var vectors = [
|
|
17
|
+
{
|
|
18
|
+
key: new Array(4).join('133457799bbcdff1'),
|
|
19
|
+
iv: '0102030405060708',
|
|
20
|
+
input: '0123456789abcdef'
|
|
21
|
+
},
|
|
22
|
+
{
|
|
23
|
+
key: new Array(4).join('0000000000000000'),
|
|
24
|
+
iv: 'ffffffffffffffff',
|
|
25
|
+
input: '0000000000000000'
|
|
26
|
+
},
|
|
27
|
+
{
|
|
28
|
+
key: new Array(4).join('a3a3a3a3b3b3b3b3'),
|
|
29
|
+
iv: 'cdcdcdcdcdcdcdcd',
|
|
30
|
+
input: 'cccccccccccccccc'
|
|
31
|
+
},
|
|
32
|
+
{
|
|
33
|
+
key: new Array(4).join('deadbeefabbadead'),
|
|
34
|
+
iv: 'a0da0da0da0da0da',
|
|
35
|
+
input: '0102030405060708090a'
|
|
36
|
+
},
|
|
37
|
+
{
|
|
38
|
+
key: 'aabbccddeeff0011' + '1111222233334444' + 'ffffeeeeddddcccc',
|
|
39
|
+
iv: 'fefefefefefefefe',
|
|
40
|
+
input: '0102030405060708090a0102030405060708090a0102030405060708090a' +
|
|
41
|
+
'0102030405060708090a0102030405060607080a0102030405060708090a'
|
|
42
|
+
}
|
|
43
|
+
];
|
|
44
|
+
|
|
45
|
+
vectors.forEach(function(vec, i) {
|
|
46
|
+
it('should encrypt vector ' + i, function() {
|
|
47
|
+
var key = Buffer.from(vec.key, 'hex');
|
|
48
|
+
var iv = Buffer.from(vec.iv, 'hex');
|
|
49
|
+
var input = Buffer.from(vec.input, 'hex');
|
|
50
|
+
|
|
51
|
+
var enc = CBC.create({
|
|
52
|
+
type: 'encrypt',
|
|
53
|
+
key: key,
|
|
54
|
+
iv: iv
|
|
55
|
+
});
|
|
56
|
+
var out = Buffer.from(enc.update(input).concat(enc.final()));
|
|
57
|
+
|
|
58
|
+
var cipher = crypto.createCipheriv('des-ede3-cbc', key, iv);
|
|
59
|
+
var expected = Buffer.concat([ cipher.update(input), cipher.final() ]);
|
|
60
|
+
|
|
61
|
+
assert.deepEqual(out, expected);
|
|
62
|
+
|
|
63
|
+
var dec = CBC.create({
|
|
64
|
+
type: 'decrypt',
|
|
65
|
+
key: key,
|
|
66
|
+
iv: iv
|
|
67
|
+
});
|
|
68
|
+
assert.deepEqual(Buffer.from(dec.update(out).concat(dec.final())),
|
|
69
|
+
input);
|
|
70
|
+
});
|
|
71
|
+
});
|
|
72
|
+
vectors.forEach(function(vec, i) {
|
|
73
|
+
it('should decrypt without unpadding vector ' + i, function() {
|
|
74
|
+
var key = Buffer.from(vec.key, 'hex');
|
|
75
|
+
var iv = Buffer.from(vec.iv, 'hex');
|
|
76
|
+
var input = Buffer.from(vec.input, 'hex');
|
|
77
|
+
|
|
78
|
+
var enc = CBC.create({
|
|
79
|
+
type: 'encrypt',
|
|
80
|
+
key: key,
|
|
81
|
+
iv: iv,
|
|
82
|
+
});
|
|
83
|
+
|
|
84
|
+
var out = Buffer.from(enc.update(input).concat(enc.final()));
|
|
85
|
+
|
|
86
|
+
var cipher = crypto.createCipheriv('des-ede3-cbc', key, iv);
|
|
87
|
+
var expected = Buffer.concat([ cipher.update(input), cipher.final() ]);
|
|
88
|
+
|
|
89
|
+
assert.deepEqual(out, expected);
|
|
90
|
+
|
|
91
|
+
var dec = CBC.create({
|
|
92
|
+
type: 'decrypt',
|
|
93
|
+
key: key,
|
|
94
|
+
iv: iv,
|
|
95
|
+
padding: false
|
|
96
|
+
});
|
|
97
|
+
|
|
98
|
+
var decipher = crypto.createDecipheriv('des-ede3-cbc', key, iv);
|
|
99
|
+
decipher.setAutoPadding(false);
|
|
100
|
+
expected = Buffer.concat([ decipher.update(out), decipher.final() ]);
|
|
101
|
+
assert.deepEqual(Buffer.from(dec.update(out).concat(dec.final())),
|
|
102
|
+
Buffer.from(expected));
|
|
103
|
+
});
|
|
104
|
+
});
|
|
105
|
+
});
|
|
106
|
+
});
|