From b4736b4ec90647e5b249dc73440d22baf1d17108 Mon Sep 17 00:00:00 2001 From: AleF83 Date: Tue, 15 Jan 2019 17:04:31 +0200 Subject: [PATCH 1/9] CLI arguments made order invariant --- README.md | 33 +++++++++++++++++++-------------- cli/README.md | 10 +++++----- cli/actions/encrypt.js | 12 ++++++------ cli/index.js | 10 +++++----- 4 files changed, 35 insertions(+), 30 deletions(-) diff --git a/README.md b/README.md index 66c599f10..c23aedb36 100644 --- a/README.md +++ b/README.md @@ -1,4 +1,4 @@ -# Kamus ![logo](images/logo.png) +# Kamus ![logo](images/logo.png) An open source, git-ops, zero-trust secrets encryption and decryption solution for Kubernetes applications. Kamus enable users to easily encrypt secrets than can be decrypted only by the application running on Kubernetes. The encryption is done using strong encryption providers (currently supported: Azure KeyVault and AES). @@ -10,15 +10,20 @@ The simple way to run Kamus is by using the Helm chart: helm repo add soluto https://charts.soluto.io helm upgrade --install kamus soluto/kamus ``` -Refer to the installation guide for more details. +Refer to the [installation guide](./docs/install.md) for more details. After installing Kamus, you can start using it to encrypt secrets. Kamus encrypt secrets for a specific application, represent by a [Kubernetes Service Account](https://kubernetes.io/docs/tasks/configure-pod-container/configure-service-account). -Create a service account for your application, and mount it on the pods running your application. -Now, when you know the name of the service account, and the namespace it exists in, use Kamus CLI to encrypt the secret: +Create a service account for your application, and mount it on the pods running your application. +Now, when you know the name of the service account, and the namespace it exists in, install Kamus CLI: ``` npm install -g @soluto-asurion/kamus-cli -kamus-cli encrypt super-secret kamus-example-sa default --kamus-url ``` +Use Kamus CLI to encrypt the secret: +``` +kamus-cli encrypt --secret super-secret --service-account kamus-example-sa --namespace default --kamus-api-url +``` +*If you're running Kamus locally the Kamus API URL will be like `http://localhost:`. So you need to add `--allow-insecure-url` flag to enable http protocol.* + Pass the value returned by the CLI to your pod, and use Kamus Decrypt API to decrypt the value. The simplest way to achieve that is by using the init container. An alternative is to use Kamus decrypt API directly in the application code. @@ -31,32 +36,32 @@ Kamus has 3 components: * Decrypt API * Key Management System (KMS) -The encrypt and decrypt APIs handle encryption and decryption requests. +The encrypt and decrypt APIs handle encryption and decryption requests. The KMS is a wrapper for various cryptographic solutions. Currently supported: * AES - uses one key for all secrets -* Azure KeyVault - creates one key per service account. -* Google Cloud KMS - creates one key per service account. +* Azure KeyVault - creates one key per service account. +* Google Cloud KMS - creates one key per service account. -We look forward to add support for other cloud solutions, like AWS KMS. -If you're interested in such a feature, please let us know. +We look forward to add support for other cloud solutions, like AWS KMS. +If you're interested in such a feature, please let us know. We would like help with testing it out. Consult the [installation guide](docs/install.md) for more details on how to deploy Kamus using the relevant KMS. - + ### Utilities Kamus is shipped with 2 utilities that make it easier to use: * Kamus CLI - a small CLI that eases the interaction with the Encrypt API. Refer to the docs for more details. * Kamus init container - a init container that interacts with the Decrypt API. Refer to the docs for more details. ## Security -We take security seriously at Soluto. +We take security seriously at Soluto. To learn more about the security aspects of Kamus refer to the Threat Modeling docs containing all the various threats and mitigations we discussed. Before installing Kamus in production refer the installation guide to learn the best practices of deploying Kamus securely. In case you find a security issue or have something you would like to discuss refer to our [security.md](security.md) policy. ## Contributing -Find a bug? Have a missing feature? Please open an issue and let us know. +Find a bug? Have a missing feature? Please open an issue and let us know. We would like to help you using Kamus! -Please notice: Do not report security issues on GitHub. +Please notice: Do not report security issues on GitHub. We will immediately delete such issues. ## Attribution diff --git a/cli/README.md b/cli/README.md index 73ce78f42..470c4c0d4 100644 --- a/cli/README.md +++ b/cli/README.md @@ -1,11 +1,11 @@ [![npm version](https://badge.fury.io/js/%40soluto-asurion%2Fkamus-cli.svg)](https://badge.fury.io/js/%40soluto-asurion%2Fkamus-cli) [![Known Vulnerabilities](https://snyk.io/test/github/soluto/kamus/badge.svg?targetFile=cli/package.json)](https://snyk.io/test/github/soluto/kamus) [![docker hub](https://images.microbadger.com/badges/image/soluto/kamus-cli.svg)](https://hub.docker.com/r/soluto/kamus-cli "Get your own image badge on microbadger.com") -## Kamus CLI +## Kamus CLI This cli was created to provide an easy interface to interact with Kamus API. -It supports azure device flow authentication out of the box. +It supports azure device flow authentication out of the box. To install, use the following NPM command: ``` @@ -17,17 +17,17 @@ docker run -it --rm soluto/kamus-cli encrypt ``` Or, using kubectl: ``` -kubectl run -it --rm --restart=Never kamus-cli --image=soluto/kamus-cli -- encrypt +kubectl run -it --rm --restart=Never kamus-cli --image=**soluto**/kamus-cli -- encrypt ``` --- #### Supported commands: ##### Encrypt -`kamus-cli encrypt ` +`kamus-cli encrypt --secret --service-account --namespace --kamus-api-url ` --- -#### How to enable azure active directory authentication +#### How to enable azure active directory authentication You need working active directory [tenant](https://docs.microsoft.com/en-us/azure/active-directory/develop/quickstart-create-new-tenant) and designated [native app registration](https://docs.microsoft.com/en-us/azure/active-directory/develop/quickstart-v2-register-an-app), Then just set all the `auth` prefixed options. Once the user will run the cli with the auth options, he will get a small code and and azure URL to login into. diff --git a/cli/actions/encrypt.js b/cli/actions/encrypt.js index 618dfdf9d..9dbc1cb6c 100644 --- a/cli/actions/encrypt.js +++ b/cli/actions/encrypt.js @@ -14,15 +14,15 @@ module.exports = async (args, options, logger) => { _logger = logger; if (useAuth(options)) { const token = await acquireToken(options); - - await encrypt(args, options, token); + + await encrypt(options, token); } else { - await encrypt(args, options) + await encrypt(options) } } -const encrypt = async ({ data, serviceAccount, namespace }, { kamusUrl, allowInsecureUrl, certFingerprint }, token = null) => { +const encrypt = async ({ data, serviceAccount, namespace, kamusUrl, allowInsecureUrl, certFingerprint }, token = null) => { _logger.log('Encryption started...'); _logger.log('service account:', serviceAccount); _logger.log('namespace:', namespace); @@ -103,9 +103,9 @@ const performEncryptRequest = (data, serviceAccount, namespace, kamusUrl, certfi strictSSL: true, method: 'POST', }; - + var req = request(options, cb); - + req.on('socket', socket => { socket.on('secureConnect', () => { var fingerprint = socket.getPeerCertificate().fingerprint; diff --git a/cli/index.js b/cli/index.js index b5189c9b0..94c64853d 100755 --- a/cli/index.js +++ b/cli/index.js @@ -8,14 +8,14 @@ const regexGuid = /^[0-9a-f]{8}-[0-9a-f]{4}-[1-5][0-9a-f]{3}-[89ab][0-9a-f]{3}-[ prog .version(pjson.version) .command('encrypt', 'Encrypt data') - .argument('','Data to encrypt') - .argument('', 'Deployment service account') - .argument('', 'Deployment namespace') - .action(encrypt) + .action(encrypt) + .option('--secret ','Data to encrypt', prog.REQUIRED) + .option('--service-account ', 'Deployment service account', prog.REQUIRED) + .option('--namespace ', 'Deployment namespace', prog.REQUIRED) + .option('--kamus-api-url ', 'Kamus URL', prog.REQUIRED) .option('--auth-tenant ', 'Azure tenant id', regexGuid) .option('--auth-application ', 'Azure application id', regexGuid) .option('--auth-resource ', 'Azure resource name', prog.STRING) - .option('--kamus-url ', 'Kamus URL', prog.REQUIRED) .option('--allow-insecure-url', 'Allow insecure (http) Kamus URL', prog.BOOL) .option('--cert-fingerprint ', 'Force server certificate to match the given fingerprint', prog.STRING); From e0a1c4b97f346f196bc6ad1fe8a14b6ee2b7f666 Mon Sep 17 00:00:00 2001 From: AleF83 Date: Tue, 15 Jan 2019 17:58:11 +0200 Subject: [PATCH 2/9] Tests fixed and ESLint added --- cli/.eslintrc | 9 + cli/README.md | 2 +- cli/actions/encrypt.js | 37 ++- cli/index.js | 2 +- cli/package.json | 1 + cli/test/encrypt.js | 13 +- cli/yarn.lock | 583 ++++++++++++++++++++++++++++++++++++++++- example/README.md | 4 +- 8 files changed, 613 insertions(+), 38 deletions(-) create mode 100644 cli/.eslintrc diff --git a/cli/.eslintrc b/cli/.eslintrc new file mode 100644 index 000000000..576e631da --- /dev/null +++ b/cli/.eslintrc @@ -0,0 +1,9 @@ +{ + "env": { + "browser": false, + "node": true + }, + "parserOptions": { + "ecmaVersion": 2017 + } +} \ No newline at end of file diff --git a/cli/README.md b/cli/README.md index 470c4c0d4..43d55f59a 100644 --- a/cli/README.md +++ b/cli/README.md @@ -40,5 +40,5 @@ Once the user will run the cli with the auth options, he will get a small code a | --auth-application | false | azure authentication application id | | | --auth-resource | false | azure authentication resource id | | | --cert-fingerprint | false | [certificate fingerprint](http://hassansin.github.io/certificate-pinning-in-nodejs) of encrypt api for validation | | -| --kamus-url | true | url of kamus encrypt api | | +| --kamus-api-url | true | url of kamus encrypt api | | | --allow-insecure-url | false | allow or block non https endpoints | false | diff --git a/cli/actions/encrypt.js b/cli/actions/encrypt.js index 9dbc1cb6c..7a63595b5 100644 --- a/cli/actions/encrypt.js +++ b/cli/actions/encrypt.js @@ -1,4 +1,4 @@ -var bluebird = require('bluebird'); +const bluebird = require('bluebird'); const opn = require('opn'); const { AuthenticationContext } = require('adal-node'); const activeDirectoryEndpoint = "https://login.microsoftonline.com/"; @@ -10,7 +10,7 @@ var pjson = require('../package.json'); let _logger; -module.exports = async (args, options, logger) => { +module.exports = async (options, logger) => { _logger = logger; if (useAuth(options)) { const token = await acquireToken(options); @@ -18,28 +18,27 @@ module.exports = async (args, options, logger) => { await encrypt(options, token); } else { - await encrypt(options) + await encrypt(options); } } -const encrypt = async ({ data, serviceAccount, namespace, kamusUrl, allowInsecureUrl, certFingerprint }, token = null) => { +const encrypt = async ({ data, serviceAccount, namespace, kamusApiUrl, allowInsecureUrl, certFingerprint }, token = null) => { _logger.log('Encryption started...'); _logger.log('service account:', serviceAccount); _logger.log('namespace:', namespace); - if (!allowInsecureUrl && url.parse(kamusUrl).protocol !== "https:"){ + if (!allowInsecureUrl && url.parse(kamusApiUrl).protocol !== 'https:') { _logger.error("Insecure Kamus URL is not allowed"); process.exit(1); } - try { - var response = await performEncryptRequestAsync(data, serviceAccount, namespace, kamusUrl, certFingerprint, token) - if (response.statusCode >= 300) { + const response = await performEncryptRequestAsync(data, serviceAccount, namespace, kamusApiUrl, certFingerprint, token); + if (response && response.statusCode >= 300) { _logger.error(`Encrypt request failed due to unexpected error. Status code: ${response.statusCode}`); process.exit(1); } _logger.info(`Successfully encrypted data to ${serviceAccount} service account in ${namespace} namespace`); - _logger.info('Encrypted data:\n' + response.body); + _logger.info(`Encrypted data:\n${response.body}`); process.exit(0); } catch (err) { @@ -78,16 +77,14 @@ const useAuth = ({ authTenant, authApplication, authResource }) => { if (authTenant && authApplication && authResource) { return true; } - else { - _logger.warn('Auth options were not provided, will try to encrypt without authentication to kamus'); - return false; - } + _logger.warn('Auth options were not provided, will try to encrypt without authentication to kamus'); + return false; } //Source: http://hassansin.github.io/certificate-pinning-in-nodejs const performEncryptRequest = (data, serviceAccount, namespace, kamusUrl, certficateFingerprint, token, cb) => { - var headers = { + const headers = { 'User-Agent': `kamus-cli-${pjson.version}`, 'Content-Type': 'application/json' }; @@ -96,7 +93,7 @@ const performEncryptRequest = (data, serviceAccount, namespace, kamusUrl, certfi headers['Authorization'] = `Bearer ${token}` } - var options = { + const options = { url: kamusUrl + '/api/v1/encrypt', headers: headers, // Certificate validation @@ -104,13 +101,13 @@ const performEncryptRequest = (data, serviceAccount, namespace, kamusUrl, certfi method: 'POST', }; - var req = request(options, cb); + const req = request(options, cb); req.on('socket', socket => { socket.on('secureConnect', () => { - var fingerprint = socket.getPeerCertificate().fingerprint; + const fingerprint = socket.getPeerCertificate().fingerprint; // Match the fingerprint with our saved fingerprints - if(certficateFingerprint != undefined && certficateFingerprint != fingerprint){ + if(certficateFingerprint !== undefined && certficateFingerprint !== fingerprint) { // Abort request, optionally emit an error event req.emit('error', new Error(`Server fingerprint ${fingerprint} does not match provided fingerprint ${certficateFingerprint}`)); return req.abort(); @@ -120,8 +117,8 @@ const performEncryptRequest = (data, serviceAccount, namespace, kamusUrl, certfi req.write(JSON.stringify({ data, - "service-account": serviceAccount, - namespace + ['service-account']: serviceAccount, + namespace, })); } diff --git a/cli/index.js b/cli/index.js index 94c64853d..4bb8cad54 100755 --- a/cli/index.js +++ b/cli/index.js @@ -12,7 +12,7 @@ prog .option('--secret ','Data to encrypt', prog.REQUIRED) .option('--service-account ', 'Deployment service account', prog.REQUIRED) .option('--namespace ', 'Deployment namespace', prog.REQUIRED) - .option('--kamus-api-url ', 'Kamus URL', prog.REQUIRED) + .option('--kamus-api-url ', 'Kamus URL', prog.REQUIRED) .option('--auth-tenant ', 'Azure tenant id', regexGuid) .option('--auth-application ', 'Azure application id', regexGuid) .option('--auth-resource ', 'Azure resource name', prog.STRING) diff --git a/cli/package.json b/cli/package.json index 74958cd4c..286102df2 100644 --- a/cli/package.json +++ b/cli/package.json @@ -36,6 +36,7 @@ }, "devDependencies": { "chai": "^4.2.0", + "eslint": "^5.12.0", "mocha": "^5.2.0", "nock": "^10.0.5", "sinon": "^7.2.2" diff --git a/cli/test/encrypt.js b/cli/test/encrypt.js index 74436f77d..e8055eb23 100644 --- a/cli/test/encrypt.js +++ b/cli/test/encrypt.js @@ -4,7 +4,7 @@ const sinon = require('sinon'); const encrypt = require('../actions/encrypt.js'); -const logger = +const logger = { info: sinon.spy(), error: console.error, @@ -12,21 +12,24 @@ const logger = log: console.log }; -const kamusUrl = 'https://kamus.com'; +const kamusApiUrl = 'https://kamus.com'; const data = 'super-secret'; const serviceAccount = 'dummy'; const namespace = 'team-a'; +let kamusApiScope; + describe('Encrypt', () => { beforeEach(() => { sinon.stub(process, 'exit'); - nock(kamusUrl) - .post('/api/v1/encrypt', { data, "service-account": serviceAccount, namespace}) + kamusApiScope = nock(kamusApiUrl) + .post('/api/v1/encrypt', { data, ['service-account']: serviceAccount, namespace}) .reply(200, '123ABC'); }); it('Should return encrypted data', async () => { - await encrypt({data, serviceAccount, namespace}, {kamusUrl}, logger); + await encrypt({data, serviceAccount, namespace, kamusApiUrl}, logger); + expect(kamusApiScope.isDone()).to.be.true; expect(process.exit.called).to.be.true; expect(process.exit.calledWith(0)).to.be.true; expect(logger.info.lastCall.lastArg).to.equal('Encrypted data:\n123ABC') diff --git a/cli/yarn.lock b/cli/yarn.lock index 1e1e65e57..d272313f3 100644 --- a/cli/yarn.lock +++ b/cli/yarn.lock @@ -2,6 +2,22 @@ # yarn lockfile v1 +"@babel/code-frame@^7.0.0": + version "7.0.0" + resolved "https://registry.yarnpkg.com/@babel/code-frame/-/code-frame-7.0.0.tgz#06e2ab19bdb535385559aabb5ba59729482800f8" + integrity sha512-OfC2uemaknXr87bdLUkWog7nYuliM9Ij5HUcajsVcMCpQrcLmtxRbVFTIqmcSkSeYRBFBRxs2FiUqFJDLdiebA== + dependencies: + "@babel/highlight" "^7.0.0" + +"@babel/highlight@^7.0.0": + version "7.0.0" + resolved "https://registry.yarnpkg.com/@babel/highlight/-/highlight-7.0.0.tgz#f710c38c8d458e6dd9a201afb637fcb781ce99e4" + integrity sha512-UFMC4ZeFC48Tpvj7C8UgLvtkaUuovQX+5xNWrsIoMG8o2z+XFKjKaN9iVmS84dPwVN00W4wPmqvYoZF3EGAsfw== + dependencies: + chalk "^2.0.0" + esutils "^2.0.2" + js-tokens "^4.0.0" + "@sinonjs/commons@^1.0.2", "@sinonjs/commons@^1.2.0": version "1.3.0" resolved "https://registry.yarnpkg.com/@sinonjs/commons/-/commons-1.3.0.tgz#50a2754016b6f30a994ceda6d9a0a8c36adda849" @@ -30,6 +46,16 @@ resolved "https://registry.yarnpkg.com/@types/node/-/node-8.10.39.tgz#e7e87ad00364dd7bc485c940926345b8ec1a26ca" integrity sha512-rE7fktr02J8ybFf6eysife+WF+L4sAHWzw09DgdCebEu+qDwMvv4zl6Bc+825ttGZP73kCKxa3dhJOoGJ8+5mA== +acorn-jsx@^5.0.0: + version "5.0.1" + resolved "https://registry.yarnpkg.com/acorn-jsx/-/acorn-jsx-5.0.1.tgz#32a064fd925429216a09b141102bfdd185fae40e" + integrity sha512-HJ7CfNHrfJLlNTzIEUTj43LNWGkqpRLxm3YjAlcD0ACydk9XynzYsCBHxut+iqt+1aBXkx9UP/w/ZqMr13XIzg== + +acorn@^6.0.2: + version "6.0.5" + resolved "https://registry.yarnpkg.com/acorn/-/acorn-6.0.5.tgz#81730c0815f3f3b34d8efa95cb7430965f4d887a" + integrity sha512-i33Zgp3XWtmZBMNvCr4azvOFeWVw1Rk6p3hfi3LUDvIFraOMywb1kAtrbi+med14m4Xfpqm3zRZMT+c0FNE7kg== + adal-node@^0.1.28: version "0.1.28" resolved "https://registry.yarnpkg.com/adal-node/-/adal-node-0.1.28.tgz#468c4bb3ebbd96b1270669f4b9cba4e0065ea485" @@ -45,6 +71,16 @@ adal-node@^0.1.28: xmldom ">= 0.1.x" xpath.js "~1.1.0" +ajv@^6.5.3, ajv@^6.6.1: + version "6.7.0" + resolved "https://registry.yarnpkg.com/ajv/-/ajv-6.7.0.tgz#e3ce7bb372d6577bb1839f1dfdfcbf5ad2948d96" + integrity sha512-RZXPviBTtfmtka9n9sy1N5M5b82CbxWIR6HIis4s3WQTXDJamc/0gpCWNGz6EWdWp4DOfjzJfhz/AS9zVPjjWg== + dependencies: + fast-deep-equal "^2.0.1" + fast-json-stable-stringify "^2.0.0" + json-schema-traverse "^0.4.1" + uri-js "^4.2.2" + ajv@^6.5.5: version "6.6.2" resolved "https://registry.yarnpkg.com/ajv/-/ajv-6.6.2.tgz#caceccf474bf3fc3ce3b147443711a24063cc30d" @@ -60,6 +96,11 @@ ansi-escapes@^1.1.0: resolved "https://registry.yarnpkg.com/ansi-escapes/-/ansi-escapes-1.4.0.tgz#d3a8a83b319aa67793662b13e761c7911422306e" integrity sha1-06ioOzGapneTZisT52HHkRQiMG4= +ansi-escapes@^3.0.0: + version "3.1.0" + resolved "https://registry.yarnpkg.com/ansi-escapes/-/ansi-escapes-3.1.0.tgz#f73207bb81207d75fd6c83f125af26eea378ca30" + integrity sha512-UgAb8H9D41AQnu/PbWlCofQVcnV4Gs2bBJi9eZPxfU/hgglFh3SMDMENRIqdr7H6XFnXdoknctFByVsCOotTVw== + ansi-regex@^2.0.0: version "2.1.1" resolved "https://registry.yarnpkg.com/ansi-regex/-/ansi-regex-2.1.1.tgz#c3b33ab5ee360d86e0e628f0468ae7ef27d654df" @@ -70,11 +111,23 @@ ansi-regex@^3.0.0: resolved "https://registry.yarnpkg.com/ansi-regex/-/ansi-regex-3.0.0.tgz#ed0317c322064f79466c02966bddb605ab37d998" integrity sha1-7QMXwyIGT3lGbAKWa922Bas32Zg= +ansi-regex@^4.0.0: + version "4.0.0" + resolved "https://registry.yarnpkg.com/ansi-regex/-/ansi-regex-4.0.0.tgz#70de791edf021404c3fd615aa89118ae0432e5a9" + integrity sha512-iB5Dda8t/UqpPI/IjsejXu5jOGDrzn41wJyljwPH65VCIbk6+1BzFIMJGFwTNrYXT1CrD+B4l19U7awiQ8rk7w== + ansi-styles@^2.2.1: version "2.2.1" resolved "https://registry.yarnpkg.com/ansi-styles/-/ansi-styles-2.2.1.tgz#b432dd3358b634cf75e1e4664368240533c1ddbe" integrity sha1-tDLdM1i2NM914eRmQ2gkBTPB3b4= +ansi-styles@^3.2.0, ansi-styles@^3.2.1: + version "3.2.1" + resolved "https://registry.yarnpkg.com/ansi-styles/-/ansi-styles-3.2.1.tgz#41fbb20243e50b12be0f04b8dedbf07520ce841d" + integrity sha512-VT0ZI6kZRdTh8YyJw3SMbYm/u+NqfsAxEpWO0Pf9sq8/e94WxxOpPKx9FR1FlyCtOVDNOQ+8ntlqFxiRc+r5qA== + dependencies: + color-convert "^1.9.0" + ansi@^0.3.0, ansi@~0.3.1: version "0.3.1" resolved "https://registry.yarnpkg.com/ansi/-/ansi-0.3.1.tgz#0c42d4fb17160d5a9af1e484bace1c66922c1b21" @@ -88,6 +141,13 @@ are-we-there-yet@~1.1.2: delegates "^1.0.0" readable-stream "^2.0.6" +argparse@^1.0.7: + version "1.0.10" + resolved "https://registry.yarnpkg.com/argparse/-/argparse-1.0.10.tgz#bcd6791ea5ae09725e17e5ad988134cd40b3d911" + integrity sha512-o5Roy6tNG4SL/FOkCAN6RzjiakZS25RLYFrcMttJqbdd8BWrnA+fGz57iN5Pb06pvBGvl5gQ0B48dJlslXvoTg== + dependencies: + sprintf-js "~1.0.2" + array-from@^2.1.1: version "2.1.1" resolved "https://registry.yarnpkg.com/array-from/-/array-from-2.1.1.tgz#cfe9d8c26628b9dc5aecc62a9f5d8f1f352c1195" @@ -110,6 +170,11 @@ assertion-error@^1.1.0: resolved "https://registry.yarnpkg.com/assertion-error/-/assertion-error-1.1.0.tgz#e60b6b0e8f301bd97e5375215bda406c85118c0b" integrity sha512-jgsaNduz+ndvGyFt3uSuWqvy4lCnIJiovtouQN5JZHOKCS2QuhEdbcQHFhVksz2N2U9hXJo8odG7ETyWlEeuDw== +astral-regex@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/astral-regex/-/astral-regex-1.0.0.tgz#6c8c3fb827dd43ee3918f27b82782ab7658a6fd9" + integrity sha512-+Ryf6g3BKoRc7jfp7ad8tM4TtMiaWvbF/1/sQcZPkkS7ag3D5nMBCe2UfOTONtAkaG0tO0ij3C5Lwmf1EiyjHg== + async@>=0.6.0: version "2.6.1" resolved "https://registry.yarnpkg.com/async/-/async-2.6.1.tgz#b245a23ca71930044ec53fa46aa00a3e87c6a610" @@ -177,6 +242,11 @@ buffer-from@^1.0.0: resolved "https://registry.yarnpkg.com/buffer-from/-/buffer-from-1.1.1.tgz#32713bc028f75c02fdb710d7c7bcec1f2c6070ef" integrity sha512-MQcXEUbCKtEo7bhqEs6560Hyd4XaovZlO/k9V3hjVUF/zwW7KBVdSK4gIt/bzwS9MbR5qob+F5jusZsb0YQK2A== +callsites@^3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/callsites/-/callsites-3.0.0.tgz#fb7eb569b72ad7a45812f93fd9430a3e410b3dd3" + integrity sha512-tWnkwu9YEq2uzlBDI4RcLn8jrFvF9AOi8PxDNU3hZZjJcjkcRAq3vCI+vZcg1SuxISDYe86k9VZFwAxDiJGoAw== + caporal@^1.1.0: version "1.1.0" resolved "https://registry.yarnpkg.com/caporal/-/caporal-1.1.0.tgz#834fd2348ab6ae79171a023a975ccc6f04620533" @@ -222,11 +292,30 @@ chalk@^1.0.0: strip-ansi "^3.0.0" supports-color "^2.0.0" +chalk@^2.0.0, chalk@^2.1.0: + version "2.4.2" + resolved "https://registry.yarnpkg.com/chalk/-/chalk-2.4.2.tgz#cd42541677a54333cf541a49108c1432b44c9424" + integrity sha512-Mti+f9lpJNcwF4tWV8/OrTTtF1gZi+f8FqlyAdouralcFWFQWF2+NgCHShjkCb+IFBLq9buZwE1xckQU4peSuQ== + dependencies: + ansi-styles "^3.2.1" + escape-string-regexp "^1.0.5" + supports-color "^5.3.0" + +chardet@^0.7.0: + version "0.7.0" + resolved "https://registry.yarnpkg.com/chardet/-/chardet-0.7.0.tgz#90094849f0937f2eedc2425d0d28a9e5f0cbad9e" + integrity sha512-mT8iDcrh03qDGRRmoA2hmBJnxpllMR+0/0qlzjqZES6NdiWDcZkCNAk4rPFZ9Q85r27unkiNNg8ZOiwZXBHwcA== + check-error@^1.0.2: version "1.0.2" resolved "https://registry.yarnpkg.com/check-error/-/check-error-1.0.2.tgz#574d312edd88bb5dd8912e9286dd6c0aed4aac82" integrity sha1-V00xLt2Iu13YkS6Sht1sCu1KrII= +circular-json@^0.3.1: + version "0.3.3" + resolved "https://registry.yarnpkg.com/circular-json/-/circular-json-0.3.3.tgz#815c99ea84f6809529d2f45791bdf82711352d66" + integrity sha512-UZK3NBx2Mca+b5LsG7bY183pHWt5Y1xts4P3Pz7ENTwGVnJOUWbRb3ocjvX7hx9tq/yTAdclXm9sZ38gNuem4A== + cli-cursor@^1.0.1: version "1.0.2" resolved "https://registry.yarnpkg.com/cli-cursor/-/cli-cursor-1.0.2.tgz#64da3f7d56a54412e59794bd62dc35295e8f2987" @@ -234,6 +323,13 @@ cli-cursor@^1.0.1: dependencies: restore-cursor "^1.0.1" +cli-cursor@^2.1.0: + version "2.1.0" + resolved "https://registry.yarnpkg.com/cli-cursor/-/cli-cursor-2.1.0.tgz#b35dac376479facc3e94747d41d0d0f5238ffcb5" + integrity sha1-s12sN2R5+sw+lHR9QdDQ9SOP/LU= + dependencies: + restore-cursor "^2.0.0" + cli-table3@^0.5.0: version "0.5.1" resolved "https://registry.yarnpkg.com/cli-table3/-/cli-table3-0.5.1.tgz#0252372d94dfc40dbd8df06005f48f31f656f202" @@ -254,6 +350,18 @@ code-point-at@^1.0.0: resolved "https://registry.yarnpkg.com/code-point-at/-/code-point-at-1.1.0.tgz#0d070b4d043a5bea33a2f1a40e2edb3d9a4ccf77" integrity sha1-DQcLTQQ6W+ozovGkDi7bPZpMz3c= +color-convert@^1.9.0: + version "1.9.3" + resolved "https://registry.yarnpkg.com/color-convert/-/color-convert-1.9.3.tgz#bb71850690e1f136567de629d2d5471deda4c1e8" + integrity sha512-QfAUtd+vFdAtFQcC8CCyYt1fYWxSqAiK2cSD6zDB8N3cpsEBAvRxp9zOGg6G/SHHJYAT88/az/IuDGALsNVbGg== + dependencies: + color-name "1.1.3" + +color-name@1.1.3: + version "1.1.3" + resolved "https://registry.yarnpkg.com/color-name/-/color-name-1.1.3.tgz#a7d0558bd89c42f795dd42328f740831ca53bc25" + integrity sha1-p9BVi9icQveV3UIyj3QIMcpTvCU= + colorette@1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/colorette/-/colorette-1.0.1.tgz#434bad4bd70969c075162fec86ca55da36bf837c" @@ -301,6 +409,17 @@ core-util-is@1.0.2, core-util-is@~1.0.0: resolved "https://registry.yarnpkg.com/core-util-is/-/core-util-is-1.0.2.tgz#b5fd54220aa2bc5ab57aab7140c940754503c1a7" integrity sha1-tf1UIgqivFq1eqtxQMlAdUUDwac= +cross-spawn@^6.0.5: + version "6.0.5" + resolved "https://registry.yarnpkg.com/cross-spawn/-/cross-spawn-6.0.5.tgz#4a5ec7c64dfae22c3a14124dbacdee846d80cbc4" + integrity sha512-eTVLrBSt7fjbDygz805pMnstIs2VTBNkRm0qxZd+M7A5XDdxVRWO5MxGBXZhjY4cqLYLdtrGqRf8mBPmzwSpWQ== + dependencies: + nice-try "^1.0.4" + path-key "^2.0.1" + semver "^5.5.0" + shebang-command "^1.2.0" + which "^1.2.9" + cycle@1.0.x: version "1.0.3" resolved "https://registry.yarnpkg.com/cycle/-/cycle-1.0.3.tgz#21e80b2be8580f98b468f379430662b046c34ad2" @@ -332,7 +451,7 @@ debug@^2.2.0: dependencies: ms "2.0.0" -debug@^4.1.0: +debug@^4.0.1, debug@^4.1.0: version "4.1.1" resolved "https://registry.yarnpkg.com/debug/-/debug-4.1.1.tgz#3b72260255109c6b589cee050f1d516139664791" integrity sha512-pYAIzeRo8J6KPEaJ0VWOh5Pzkbw/RetuzehGM7QRRX5he4fPHx2rdKMB256ehJCkX+XRQm16eZLqLNS8RSZXZw== @@ -351,6 +470,11 @@ deep-equal@^1.0.0: resolved "https://registry.yarnpkg.com/deep-equal/-/deep-equal-1.0.1.tgz#f5d260292b660e084eff4cdbc9f08ad3247448b5" integrity sha1-9dJgKStmDghO/0zbyfCK0yR0SLU= +deep-is@~0.1.3: + version "0.1.3" + resolved "https://registry.yarnpkg.com/deep-is/-/deep-is-0.1.3.tgz#b369d6fb5dbc13eecf524f91b070feedc357cf34" + integrity sha1-s2nW+128E+7PUk+RsHD+7cNXzzQ= + delayed-stream@~1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/delayed-stream/-/delayed-stream-1.0.0.tgz#df3ae199acadfb7d440aaae0b29e2272b24ec619" @@ -366,6 +490,13 @@ diff@3.5.0, diff@^3.5.0: resolved "https://registry.yarnpkg.com/diff/-/diff-3.5.0.tgz#800c0dd1e0a8bfbc95835c202ad220fe317e5a12" integrity sha512-A46qtFgd+g7pDZinpnwiRJtxbC1hpgf0uzP3iG89scHk0AUC7A1TGxf5OiiOUv/JMZR8GOt8hL900hV0bOy5xA== +doctrine@^2.1.0: + version "2.1.0" + resolved "https://registry.yarnpkg.com/doctrine/-/doctrine-2.1.0.tgz#5cd01fc101621b42c4cd7f5d1a66243716d3f39d" + integrity sha512-35mSku4ZXK0vfCuHEDAwt55dg2jNajHZ1odvF+8SSr82EsZY4QmXfuWso8oEd8zRhVObSN18aM0CjSdoBX7zIw== + dependencies: + esutils "^2.0.2" + ecc-jsbn@~0.1.1: version "0.1.2" resolved "https://registry.yarnpkg.com/ecc-jsbn/-/ecc-jsbn-0.1.2.tgz#3a83a904e54353287874c564b7549386849a98c9" @@ -386,6 +517,105 @@ escape-string-regexp@1.0.5, escape-string-regexp@^1.0.2, escape-string-regexp@^1 resolved "https://registry.yarnpkg.com/escape-string-regexp/-/escape-string-regexp-1.0.5.tgz#1b61c0562190a8dff6ae3bb2cf0200ca130b86d4" integrity sha1-G2HAViGQqN/2rjuyzwIAyhMLhtQ= +eslint-scope@^4.0.0: + version "4.0.0" + resolved "https://registry.yarnpkg.com/eslint-scope/-/eslint-scope-4.0.0.tgz#50bf3071e9338bcdc43331794a0cb533f0136172" + integrity sha512-1G6UTDi7Jc1ELFwnR58HV4fK9OQK4S6N985f166xqXxpjU6plxFISJa2Ba9KCQuFa8RCnj/lSFJbHo7UFDBnUA== + dependencies: + esrecurse "^4.1.0" + estraverse "^4.1.1" + +eslint-utils@^1.3.1: + version "1.3.1" + resolved "https://registry.yarnpkg.com/eslint-utils/-/eslint-utils-1.3.1.tgz#9a851ba89ee7c460346f97cf8939c7298827e512" + integrity sha512-Z7YjnIldX+2XMcjr7ZkgEsOj/bREONV60qYeB/bjMAqqqZ4zxKyWX+BOUkdmRmA9riiIPVvo5x86m5elviOk0Q== + +eslint-visitor-keys@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/eslint-visitor-keys/-/eslint-visitor-keys-1.0.0.tgz#3f3180fb2e291017716acb4c9d6d5b5c34a6a81d" + integrity sha512-qzm/XxIbxm/FHyH341ZrbnMUpe+5Bocte9xkmFMzPMjRaZMcXww+MpBptFvtU+79L362nqiLhekCxCxDPaUMBQ== + +eslint@5.12.0: + version "5.12.0" + resolved "https://registry.yarnpkg.com/eslint/-/eslint-5.12.0.tgz#fab3b908f60c52671fb14e996a450b96c743c859" + integrity sha512-LntwyPxtOHrsJdcSwyQKVtHofPHdv+4+mFwEe91r2V13vqpM8yLr7b1sW+Oo/yheOPkWYsYlYJCkzlFAt8KV7g== + dependencies: + "@babel/code-frame" "^7.0.0" + ajv "^6.5.3" + chalk "^2.1.0" + cross-spawn "^6.0.5" + debug "^4.0.1" + doctrine "^2.1.0" + eslint-scope "^4.0.0" + eslint-utils "^1.3.1" + eslint-visitor-keys "^1.0.0" + espree "^5.0.0" + esquery "^1.0.1" + esutils "^2.0.2" + file-entry-cache "^2.0.0" + functional-red-black-tree "^1.0.1" + glob "^7.1.2" + globals "^11.7.0" + ignore "^4.0.6" + import-fresh "^3.0.0" + imurmurhash "^0.1.4" + inquirer "^6.1.0" + js-yaml "^3.12.0" + json-stable-stringify-without-jsonify "^1.0.1" + levn "^0.3.0" + lodash "^4.17.5" + minimatch "^3.0.4" + mkdirp "^0.5.1" + natural-compare "^1.4.0" + optionator "^0.8.2" + path-is-inside "^1.0.2" + pluralize "^7.0.0" + progress "^2.0.0" + regexpp "^2.0.1" + semver "^5.5.1" + strip-ansi "^4.0.0" + strip-json-comments "^2.0.1" + table "^5.0.2" + text-table "^0.2.0" + +espree@^5.0.0: + version "5.0.0" + resolved "https://registry.yarnpkg.com/espree/-/espree-5.0.0.tgz#fc7f984b62b36a0f543b13fb9cd7b9f4a7f5b65c" + integrity sha512-1MpUfwsdS9MMoN7ZXqAr9e9UKdVHDcvrJpyx7mm1WuQlx/ygErEQBzgi5Nh5qBHIoYweprhtMkTCb9GhcAIcsA== + dependencies: + acorn "^6.0.2" + acorn-jsx "^5.0.0" + eslint-visitor-keys "^1.0.0" + +esprima@^4.0.0: + version "4.0.1" + resolved "https://registry.yarnpkg.com/esprima/-/esprima-4.0.1.tgz#13b04cdb3e6c5d19df91ab6987a8695619b0aa71" + integrity sha512-eGuFFw7Upda+g4p+QHvnW0RyTX/SVeJBDM/gCtMARO0cLuT2HcEKnTPvhjV6aGeqrCB/sbNop0Kszm0jsaWU4A== + +esquery@^1.0.1: + version "1.0.1" + resolved "https://registry.yarnpkg.com/esquery/-/esquery-1.0.1.tgz#406c51658b1f5991a5f9b62b1dc25b00e3e5c708" + integrity sha512-SmiyZ5zIWH9VM+SRUReLS5Q8a7GxtRdxEBVZpm98rJM7Sb+A9DVCndXfkeFUd3byderg+EbDkfnevfCwynWaNA== + dependencies: + estraverse "^4.0.0" + +esrecurse@^4.1.0: + version "4.2.1" + resolved "https://registry.yarnpkg.com/esrecurse/-/esrecurse-4.2.1.tgz#007a3b9fdbc2b3bb87e4879ea19c92fdbd3942cf" + integrity sha512-64RBB++fIOAXPw3P9cy89qfMlvZEXZkqqJkjqqXIvzP5ezRZjW+lPWjw35UX/3EhUPFYbg5ER4JYgDw4007/DQ== + dependencies: + estraverse "^4.1.0" + +estraverse@^4.0.0, estraverse@^4.1.0, estraverse@^4.1.1: + version "4.2.0" + resolved "https://registry.yarnpkg.com/estraverse/-/estraverse-4.2.0.tgz#0dee3fed31fcd469618ce7342099fc1afa0bdb13" + integrity sha1-De4/7TH81GlhjOc0IJn8GvoL2xM= + +esutils@^2.0.2: + version "2.0.2" + resolved "https://registry.yarnpkg.com/esutils/-/esutils-2.0.2.tgz#0abf4f1caa5bcb1f7a9d8acc6dea4faaa04bac9b" + integrity sha1-Cr9PHKpbyx96nYrMbepPqqBLrJs= + exit-hook@^1.0.0: version "1.1.1" resolved "https://registry.yarnpkg.com/exit-hook/-/exit-hook-1.1.1.tgz#f05ca233b48c05d54fff07765df8507e95c02ff8" @@ -405,6 +635,15 @@ external-editor@^1.1.0: spawn-sync "^1.0.15" tmp "^0.0.29" +external-editor@^3.0.0: + version "3.0.3" + resolved "https://registry.yarnpkg.com/external-editor/-/external-editor-3.0.3.tgz#5866db29a97826dbe4bf3afd24070ead9ea43a27" + integrity sha512-bn71H9+qWoOQKyZDo25mOMVpSmXROAsTJVVVYzrrtol3d4y+AsKjf4Iwl2Q+IuT0kFSQ1qo166UuIwqYq7mGnA== + dependencies: + chardet "^0.7.0" + iconv-lite "^0.4.24" + tmp "^0.0.33" + extsprintf@1.3.0: version "1.3.0" resolved "https://registry.yarnpkg.com/extsprintf/-/extsprintf-1.3.0.tgz#96918440e3041a7a414f8c52e3c574eb3c3e1e05" @@ -430,7 +669,7 @@ fast-json-stable-stringify@^2.0.0: resolved "https://registry.yarnpkg.com/fast-json-stable-stringify/-/fast-json-stable-stringify-2.0.0.tgz#d5142c0caee6b1189f87d3a76111064f86c8bbf2" integrity sha1-1RQsDK7msRifh9OnYREGT4bIu/I= -fast-levenshtein@^2.0.6: +fast-levenshtein@^2.0.6, fast-levenshtein@~2.0.4: version "2.0.6" resolved "https://registry.yarnpkg.com/fast-levenshtein/-/fast-levenshtein-2.0.6.tgz#3d8a5c66883a16a30ca8643e851f19baa7797917" integrity sha1-PYpcZog6FqMMqGQ+hR8Zuqd5eRc= @@ -443,6 +682,31 @@ figures@^1.3.5: escape-string-regexp "^1.0.5" object-assign "^4.1.0" +figures@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/figures/-/figures-2.0.0.tgz#3ab1a2d2a62c8bfb431a0c94cb797a2fce27c962" + integrity sha1-OrGi0qYsi/tDGgyUy3l6L84nyWI= + dependencies: + escape-string-regexp "^1.0.5" + +file-entry-cache@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/file-entry-cache/-/file-entry-cache-2.0.0.tgz#c392990c3e684783d838b8c84a45d8a048458361" + integrity sha1-w5KZDD5oR4PYOLjISkXYoEhFg2E= + dependencies: + flat-cache "^1.2.1" + object-assign "^4.0.1" + +flat-cache@^1.2.1: + version "1.3.4" + resolved "https://registry.yarnpkg.com/flat-cache/-/flat-cache-1.3.4.tgz#2c2ef77525cc2929007dfffa1dd314aa9c9dee6f" + integrity sha512-VwyB3Lkgacfik2vhqR4uv2rvebqmDvFu4jlN/C1RzWoJEo8I7z4Q404oiqYCkq41mni8EzQnm95emU9seckwtg== + dependencies: + circular-json "^0.3.1" + graceful-fs "^4.1.2" + rimraf "~2.6.2" + write "^0.2.1" + forever-agent@~0.6.1: version "0.6.1" resolved "https://registry.yarnpkg.com/forever-agent/-/forever-agent-0.6.1.tgz#fbc71f0c41adeb37f96c577ad1ed42d8fdacca91" @@ -462,6 +726,11 @@ fs.realpath@^1.0.0: resolved "https://registry.yarnpkg.com/fs.realpath/-/fs.realpath-1.0.0.tgz#1504ad2523158caa40db4a2787cb01411994ea4f" integrity sha1-FQStJSMVjKpA20onh8sBQRmU6k8= +functional-red-black-tree@^1.0.1: + version "1.0.1" + resolved "https://registry.yarnpkg.com/functional-red-black-tree/-/functional-red-black-tree-1.0.1.tgz#1b0ab3bd553b2a0d6399d29c0e3ea0b252078327" + integrity sha1-GwqzvVU7Kg1jmdKcDj6gslIHgyc= + gauge@~1.2.5: version "1.2.7" resolved "https://registry.yarnpkg.com/gauge/-/gauge-1.2.7.tgz#e9cec5483d3d4ee0ef44b60a7d99e4935e136d93" @@ -497,6 +766,28 @@ glob@7.1.2: once "^1.3.0" path-is-absolute "^1.0.0" +glob@^7.1.2, glob@^7.1.3: + version "7.1.3" + resolved "https://registry.yarnpkg.com/glob/-/glob-7.1.3.tgz#3960832d3f1574108342dafd3a67b332c0969df1" + integrity sha512-vcfuiIxogLV4DlGBHIUOwI0IbrJ8HWPc4MU7HzviGeNho/UJDfi6B5p3sHeWIQ0KGIU0Jpxi5ZHxemQfLkkAwQ== + dependencies: + fs.realpath "^1.0.0" + inflight "^1.0.4" + inherits "2" + minimatch "^3.0.4" + once "^1.3.0" + path-is-absolute "^1.0.0" + +globals@^11.7.0: + version "11.10.0" + resolved "https://registry.yarnpkg.com/globals/-/globals-11.10.0.tgz#1e09776dffda5e01816b3bb4077c8b59c24eaa50" + integrity sha512-0GZF1RiPKU97IHUO5TORo9w1PwrH/NBPl+fS7oMLdaTRiYmYbwK4NWoZWrAdd0/abG9R2BU+OiwyQpTpE6pdfQ== + +graceful-fs@^4.1.2: + version "4.1.15" + resolved "https://registry.yarnpkg.com/graceful-fs/-/graceful-fs-4.1.15.tgz#ffb703e1066e8a0eeaa4c8b80ba9253eeefbfb00" + integrity sha512-6uHUhOPEBgQ24HM+r6b/QwWfZq+yiFcipKFrOFiBEnWdy5sdzYoi+pJeQaPI5qOLRFqWmAXUPQNsielzdLoecA== + growl@1.10.5: version "1.10.5" resolved "https://registry.yarnpkg.com/growl/-/growl-1.10.5.tgz#f2735dc2283674fa67478b10181059355c369e5e" @@ -546,6 +837,31 @@ http-signature@~1.2.0: jsprim "^1.2.2" sshpk "^1.7.0" +iconv-lite@^0.4.24: + version "0.4.24" + resolved "https://registry.yarnpkg.com/iconv-lite/-/iconv-lite-0.4.24.tgz#2022b4b25fbddc21d2f524974a474aafe733908b" + integrity sha512-v3MXnZAcvnywkTUEZomIActle7RXXeedOR31wwl7VlyoXO4Qi9arvSenNQWne1TcRwhCL1HwLI21bEqdpj8/rA== + dependencies: + safer-buffer ">= 2.1.2 < 3" + +ignore@^4.0.6: + version "4.0.6" + resolved "https://registry.yarnpkg.com/ignore/-/ignore-4.0.6.tgz#750e3db5862087b4737ebac8207ffd1ef27b25fc" + integrity sha512-cyFDKrqc/YdcWFniJhzI42+AzS+gNwmUzOSFcRCQYwySuBBBy/KjuxWLZ/FHEH6Moq1NizMOBWyTcv8O4OZIMg== + +import-fresh@^3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/import-fresh/-/import-fresh-3.0.0.tgz#a3d897f420cab0e671236897f75bc14b4885c390" + integrity sha512-pOnA9tfM3Uwics+SaBLCNyZZZbK+4PTu0OPZtLlMIrv17EdBoC15S9Kn8ckJ9TZTyKb3ywNE5y1yeDxxGA7nTQ== + dependencies: + parent-module "^1.0.0" + resolve-from "^4.0.0" + +imurmurhash@^0.1.4: + version "0.1.4" + resolved "https://registry.yarnpkg.com/imurmurhash/-/imurmurhash-0.1.4.tgz#9218b9b2b928a238b13dc4fb6b6d576f231453ea" + integrity sha1-khi5srkoojixPcT7a21XbyMUU+o= + inflight@^1.0.4: version "1.0.6" resolved "https://registry.yarnpkg.com/inflight/-/inflight-1.0.6.tgz#49bd6331d7d02d0c09bc910a1075ba8165b56df9" @@ -579,6 +895,25 @@ inquirer@^1.0.2: strip-ansi "^3.0.0" through "^2.3.6" +inquirer@^6.1.0: + version "6.2.1" + resolved "https://registry.yarnpkg.com/inquirer/-/inquirer-6.2.1.tgz#9943fc4882161bdb0b0c9276769c75b32dbfcd52" + integrity sha512-088kl3DRT2dLU5riVMKKr1DlImd6X7smDhpXUCkJDCKvTEJeRiXh0G132HG9u5a+6Ylw9plFRY7RuTnwohYSpg== + dependencies: + ansi-escapes "^3.0.0" + chalk "^2.0.0" + cli-cursor "^2.1.0" + cli-width "^2.0.0" + external-editor "^3.0.0" + figures "^2.0.0" + lodash "^4.17.10" + mute-stream "0.0.7" + run-async "^2.2.0" + rxjs "^6.1.0" + string-width "^2.1.0" + strip-ansi "^5.0.0" + through "^2.3.6" + is-fullwidth-code-point@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/is-fullwidth-code-point/-/is-fullwidth-code-point-1.0.0.tgz#ef9e31386f031a7f0d643af82fde50c457ef00cb" @@ -616,11 +951,29 @@ isarray@~1.0.0: resolved "https://registry.yarnpkg.com/isarray/-/isarray-1.0.0.tgz#bb935d48582cba168c06834957a54a3e07124f11" integrity sha1-u5NdSFgsuhaMBoNJV6VKPgcSTxE= +isexe@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/isexe/-/isexe-2.0.0.tgz#e8fbf374dc556ff8947a10dcb0572d633f2cfa10" + integrity sha1-6PvzdNxVb/iUehDcsFctYz8s+hA= + isstream@0.1.x, isstream@~0.1.2: version "0.1.2" resolved "https://registry.yarnpkg.com/isstream/-/isstream-0.1.2.tgz#47e63f7af55afa6f92e1500e690eb8b8529c099a" integrity sha1-R+Y/evVa+m+S4VAOaQ64uFKcCZo= +js-tokens@^4.0.0: + version "4.0.0" + resolved "https://registry.yarnpkg.com/js-tokens/-/js-tokens-4.0.0.tgz#19203fb59991df98e3a287050d4647cdeaf32499" + integrity sha512-RdJUflcE3cUzKiMqQgsCu06FPu9UdIJO0beYbPhHN4k6apgJtifcoCtT9bcxOpYBtpD2kCM6Sbzg4CausW/PKQ== + +js-yaml@^3.12.0: + version "3.12.1" + resolved "https://registry.yarnpkg.com/js-yaml/-/js-yaml-3.12.1.tgz#295c8632a18a23e054cf5c9d3cecafe678167600" + integrity sha512-um46hB9wNOKlwkHgiuyEVAybXBjwFUV0Z/RaHJblRd9DXltue9FTYvzCr9ErQrK9Adz5MU4gHWVaNUfdmrC8qA== + dependencies: + argparse "^1.0.7" + esprima "^4.0.0" + jsbn@~0.1.0: version "0.1.1" resolved "https://registry.yarnpkg.com/jsbn/-/jsbn-0.1.1.tgz#a5e654c2e5a2deb5f201d96cefbca80c0ef2f513" @@ -636,6 +989,11 @@ json-schema@0.2.3: resolved "https://registry.yarnpkg.com/json-schema/-/json-schema-0.2.3.tgz#b480c892e59a2f05954ce727bd3f2a4e882f9e13" integrity sha1-tIDIkuWaLwWVTOcnvT8qTogvnhM= +json-stable-stringify-without-jsonify@^1.0.1: + version "1.0.1" + resolved "https://registry.yarnpkg.com/json-stable-stringify-without-jsonify/-/json-stable-stringify-without-jsonify-1.0.1.tgz#9db7b59496ad3f3cfef30a75142d2d930ad72651" + integrity sha1-nbe1lJatPzz+8wp1FC0tkwrXJlE= + json-stringify-safe@^5.0.1, json-stringify-safe@~5.0.1: version "5.0.1" resolved "https://registry.yarnpkg.com/json-stringify-safe/-/json-stringify-safe-5.0.1.tgz#1296a2d58fd45f19a0f6ce01d65701e2c735b6eb" @@ -673,6 +1031,14 @@ jws@3.x.x: jwa "^1.1.5" safe-buffer "^5.0.1" +levn@^0.3.0, levn@~0.3.0: + version "0.3.0" + resolved "https://registry.yarnpkg.com/levn/-/levn-0.3.0.tgz#3b09924edf9f083c0490fdd4c0bc4421e04764ee" + integrity sha1-OwmSTt+fCDwEkP3UwLxEIeBHZO4= + dependencies: + prelude-ls "~1.1.2" + type-check "~0.3.2" + lodash.camelcase@^4.3.0: version "4.3.0" resolved "https://registry.yarnpkg.com/lodash.camelcase/-/lodash.camelcase-4.3.0.tgz#b28aa6288a2b9fc651035c7711f65ab6190331a6" @@ -718,7 +1084,7 @@ lodash.uniq@^4.5.0: resolved "https://registry.yarnpkg.com/lodash.uniq/-/lodash.uniq-4.5.0.tgz#d0225373aeb652adc1bc82e4945339a842754773" integrity sha1-0CJTc662Uq3BvILklFM5qEJ1R3M= -lodash@^4.17.10, lodash@^4.17.5, lodash@^4.3.0: +lodash@^4.17.10, lodash@^4.17.11, lodash@^4.17.5, lodash@^4.3.0: version "4.17.11" resolved "https://registry.yarnpkg.com/lodash/-/lodash-4.17.11.tgz#b39ea6229ef607ecd89e2c8df12536891cac9b8d" integrity sha512-cQKh8igo5QUhZ7lg38DYWAxMvjSAKG0A8wGSVimP07SIUEK2UO+arSRKbRZWtelMtN5V0Hkwh5ryOto/SshYIg== @@ -752,6 +1118,11 @@ mime-types@^2.1.12, mime-types@~2.1.19: dependencies: mime-db "~1.37.0" +mimic-fn@^1.0.0: + version "1.2.0" + resolved "https://registry.yarnpkg.com/mimic-fn/-/mimic-fn-1.2.0.tgz#820c86a39334640e99516928bd03fca88057d022" + integrity sha512-jf84uxzwiuiIVKiOLpfYk7N46TSy8ubTonmneY9vrpHNAnp0QBt2BxWV9dO3/j+BoVAb+a5G6YDPW3M5HOdMWQ== + minimatch@3.0.4, minimatch@^3.0.4: version "3.0.4" resolved "https://registry.yarnpkg.com/minimatch/-/minimatch-3.0.4.tgz#5166e286457f03306064be5497e8dbb0c3d32083" @@ -808,6 +1179,21 @@ mute-stream@0.0.6: resolved "https://registry.yarnpkg.com/mute-stream/-/mute-stream-0.0.6.tgz#48962b19e169fd1dfc240b3f1e7317627bbc47db" integrity sha1-SJYrGeFp/R38JAs/HnMXYnu8R9s= +mute-stream@0.0.7: + version "0.0.7" + resolved "https://registry.yarnpkg.com/mute-stream/-/mute-stream-0.0.7.tgz#3075ce93bc21b8fab43e1bc4da7e8115ed1e7bab" + integrity sha1-MHXOk7whuPq0PhvE2n6BFe0ee6s= + +natural-compare@^1.4.0: + version "1.4.0" + resolved "https://registry.yarnpkg.com/natural-compare/-/natural-compare-1.4.0.tgz#4abebfeed7541f2c27acfb29bdbbd15c8d5ba4f7" + integrity sha1-Sr6/7tdUHywnrPspvbvRXI1bpPc= + +nice-try@^1.0.4: + version "1.0.5" + resolved "https://registry.yarnpkg.com/nice-try/-/nice-try-1.0.5.tgz#a3378a7696ce7d223e88fc9b764bd7ef1089e366" + integrity sha512-1nh45deeb5olNY7eX82BkPO7SSxR5SSYJiPTrTdFUVYwAl8CKMA5N9PjTYkHiRjisVcxcQ1HXdLhx2qxxJzLNQ== + nise@^1.4.7: version "1.4.8" resolved "https://registry.yarnpkg.com/nise/-/nise-1.4.8.tgz#ce91c31e86cf9b2c4cac49d7fcd7f56779bfd6b0" @@ -858,7 +1244,7 @@ oauth-sign@~0.9.0: resolved "https://registry.yarnpkg.com/oauth-sign/-/oauth-sign-0.9.0.tgz#47a7b016baa68b5fa0ecf3dee08a85c679ac6455" integrity sha512-fexhUFFPTGV8ybAtSIGbV6gOkSv8UtRbDBnAyLQw4QPKkgNlsH2ByPGtMUqdWkos6YCRmAqViwgZrJc/mRDzZQ== -object-assign@^4.1.0: +object-assign@^4.0.1, object-assign@^4.1.0: version "4.1.1" resolved "https://registry.yarnpkg.com/object-assign/-/object-assign-4.1.1.tgz#2109adc7965887cfc05cbbd442cac8bfbb360863" integrity sha1-IQmtx5ZYh8/AXLvUQsrIv7s2CGM= @@ -875,6 +1261,13 @@ onetime@^1.0.0: resolved "https://registry.yarnpkg.com/onetime/-/onetime-1.1.0.tgz#a1f7838f8314c516f05ecefcbc4ccfe04b4ed789" integrity sha1-ofeDj4MUxRbwXs78vEzP4EtO14k= +onetime@^2.0.0: + version "2.0.1" + resolved "https://registry.yarnpkg.com/onetime/-/onetime-2.0.1.tgz#067428230fd67443b2794b22bba528b6867962d4" + integrity sha1-BnQoIw/WdEOyeUsiu6UotoZ5YtQ= + dependencies: + mimic-fn "^1.0.0" + opn@^5.4.0: version "5.4.0" resolved "https://registry.yarnpkg.com/opn/-/opn-5.4.0.tgz#cb545e7aab78562beb11aa3bfabc7042e1761035" @@ -882,21 +1275,50 @@ opn@^5.4.0: dependencies: is-wsl "^1.1.0" +optionator@^0.8.2: + version "0.8.2" + resolved "https://registry.yarnpkg.com/optionator/-/optionator-0.8.2.tgz#364c5e409d3f4d6301d6c0b4c05bba50180aeb64" + integrity sha1-NkxeQJ0/TWMB1sC0wFu6UBgK62Q= + dependencies: + deep-is "~0.1.3" + fast-levenshtein "~2.0.4" + levn "~0.3.0" + prelude-ls "~1.1.2" + type-check "~0.3.2" + wordwrap "~1.0.0" + os-shim@^0.1.2: version "0.1.3" resolved "https://registry.yarnpkg.com/os-shim/-/os-shim-0.1.3.tgz#6b62c3791cf7909ea35ed46e17658bb417cb3917" integrity sha1-a2LDeRz3kJ6jXtRuF2WLtBfLORc= -os-tmpdir@~1.0.1: +os-tmpdir@~1.0.1, os-tmpdir@~1.0.2: version "1.0.2" resolved "https://registry.yarnpkg.com/os-tmpdir/-/os-tmpdir-1.0.2.tgz#bbe67406c79aa85c5cfec766fe5734555dfa1274" integrity sha1-u+Z0BseaqFxc/sdm/lc0VV36EnQ= +parent-module@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/parent-module/-/parent-module-1.0.0.tgz#df250bdc5391f4a085fb589dad761f5ad6b865b5" + integrity sha512-8Mf5juOMmiE4FcmzYc4IaiS9L3+9paz2KOiXzkRviCP6aDmN49Hz6EMWz0lGNp9pX80GvvAuLADtyGfW/Em3TA== + dependencies: + callsites "^3.0.0" + path-is-absolute@^1.0.0: version "1.0.1" resolved "https://registry.yarnpkg.com/path-is-absolute/-/path-is-absolute-1.0.1.tgz#174b9268735534ffbc7ace6bf53a5a9e1b5c5f5f" integrity sha1-F0uSaHNVNP+8es5r9TpanhtcX18= +path-is-inside@^1.0.2: + version "1.0.2" + resolved "https://registry.yarnpkg.com/path-is-inside/-/path-is-inside-1.0.2.tgz#365417dede44430d1c11af61027facf074bdfc53" + integrity sha1-NlQX3t5EQw0cEa9hAn+s8HS9/FM= + +path-key@^2.0.1: + version "2.0.1" + resolved "https://registry.yarnpkg.com/path-key/-/path-key-2.0.1.tgz#411cadb574c5a140d3a4b1910d40d80cc9f40b40" + integrity sha1-QRyttXTFoUDTpLGRDUDYDMn0C0A= + path-to-regexp@^1.7.0: version "1.7.0" resolved "https://registry.yarnpkg.com/path-to-regexp/-/path-to-regexp-1.7.0.tgz#59fde0f435badacba103a84e9d3bc64e96b9937d" @@ -926,6 +1348,16 @@ pinkie@^2.0.0: resolved "https://registry.yarnpkg.com/pinkie/-/pinkie-2.0.4.tgz#72556b80cfa0d48a974e80e77248e80ed4f7f870" integrity sha1-clVrgM+g1IqXToDnckjoDtT3+HA= +pluralize@^7.0.0: + version "7.0.0" + resolved "https://registry.yarnpkg.com/pluralize/-/pluralize-7.0.0.tgz#298b89df8b93b0221dbf421ad2b1b1ea23fc6777" + integrity sha512-ARhBOdzS3e41FbkW/XWrTEtukqqLoK5+Z/4UeDaLuSW+39JPeFgs4gCGqsrJHVZX0fUrx//4OF0K1CUGwlIFow== + +prelude-ls@~1.1.2: + version "1.1.2" + resolved "https://registry.yarnpkg.com/prelude-ls/-/prelude-ls-1.1.2.tgz#21932a549f5e52ffd9a827f570e04be62a97da54" + integrity sha1-IZMqVJ9eUv/ZqCf1cOBL5iqX2lQ= + prettyjson@^1.2.1: version "1.2.1" resolved "https://registry.yarnpkg.com/prettyjson/-/prettyjson-1.2.1.tgz#fcffab41d19cab4dfae5e575e64246619b12d289" @@ -939,6 +1371,11 @@ process-nextick-args@~2.0.0: resolved "https://registry.yarnpkg.com/process-nextick-args/-/process-nextick-args-2.0.0.tgz#a37d732f4271b4ab1ad070d35508e8290788ffaa" integrity sha512-MtEC1TqN0EU5nephaJ4rAtThHtC86dNN9qCuEhtshvpVBkAW5ZO7BASN9REnF9eoXGcRub+pFuKEpOHE+HbEMw== +progress@^2.0.0: + version "2.0.3" + resolved "https://registry.yarnpkg.com/progress/-/progress-2.0.3.tgz#7e8cf8d8f5b8f239c1bc68beb4eb78567d572ef8" + integrity sha512-7PiHtLll5LdnKIMw100I+8xJXR5gW2QwWYkT6iJva0bXitZKa/XMrSbdmg3r2Xnaidz9Qumd0VPaMrZlF9V9sA== + propagate@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/propagate/-/propagate-1.0.0.tgz#00c2daeedda20e87e3782b344adba1cddd6ad709" @@ -982,6 +1419,11 @@ readable-stream@^2.0.6, readable-stream@^2.2.2: string_decoder "~1.1.1" util-deprecate "~1.0.1" +regexpp@^2.0.1: + version "2.0.1" + resolved "https://registry.yarnpkg.com/regexpp/-/regexpp-2.0.1.tgz#8d19d31cf632482b589049f8281f93dbcba4d07f" + integrity sha512-lv0M6+TkDVniA3aD1Eg0DVpfU/booSu7Eev3TDO/mZKHBfVjgCGTV4t4buppESEYDtkArYFOxTJWv6S5C+iaNw== + "request@>= 2.52.0", request@^2.88.0: version "2.88.0" resolved "https://registry.yarnpkg.com/request/-/request-2.88.0.tgz#9c2fca4f7d35b592efe57c7f0a55e81052124fef" @@ -1008,6 +1450,11 @@ readable-stream@^2.0.6, readable-stream@^2.2.2: tunnel-agent "^0.6.0" uuid "^3.3.2" +resolve-from@^4.0.0: + version "4.0.0" + resolved "https://registry.yarnpkg.com/resolve-from/-/resolve-from-4.0.0.tgz#4abcd852ad32dd7baabfe9b40e00a36db5f392e6" + integrity sha512-pb/MYmXstAkysRFx8piNI1tGFNQIFA3vkE3Gq4EuA1dF6gHp/+vgZqsCGJapvy8N3Q+4o7FwvquPJcnZ7RYy4g== + restore-cursor@^1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/restore-cursor/-/restore-cursor-1.0.1.tgz#34661f46886327fed2991479152252df92daa541" @@ -1016,6 +1463,21 @@ restore-cursor@^1.0.1: exit-hook "^1.0.0" onetime "^1.0.0" +restore-cursor@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/restore-cursor/-/restore-cursor-2.0.0.tgz#9f7ee287f82fd326d4fd162923d62129eee0dfaf" + integrity sha1-n37ih/gv0ybU/RYpI9YhKe7g368= + dependencies: + onetime "^2.0.0" + signal-exit "^3.0.2" + +rimraf@~2.6.2: + version "2.6.3" + resolved "https://registry.yarnpkg.com/rimraf/-/rimraf-2.6.3.tgz#b2d104fe0d8fb27cf9e0a1cda8262dd3833c6cab" + integrity sha512-mwqeW5XsA2qAejG46gYdENaxXjx9onRNCfn7L0duuP4hCuTIi/QO7PDK07KJfp1d+izWPrzEJDcSqBa0OZQriA== + dependencies: + glob "^7.1.3" + run-async@^2.2.0: version "2.3.0" resolved "https://registry.yarnpkg.com/run-async/-/run-async-2.3.0.tgz#0371ab4ae0bdd720d4166d7dfda64ff7a445a6c0" @@ -1028,21 +1490,45 @@ rx@^4.1.0: resolved "https://registry.yarnpkg.com/rx/-/rx-4.1.0.tgz#a5f13ff79ef3b740fe30aa803fb09f98805d4782" integrity sha1-pfE/957zt0D+MKqAP7CfmIBdR4I= +rxjs@^6.1.0: + version "6.3.3" + resolved "https://registry.yarnpkg.com/rxjs/-/rxjs-6.3.3.tgz#3c6a7fa420e844a81390fb1158a9ec614f4bad55" + integrity sha512-JTWmoY9tWCs7zvIk/CvRjhjGaOd+OVBM987mxFo+OW66cGpdKjZcpmc74ES1sB//7Kl/PAe8+wEakuhG4pcgOw== + dependencies: + tslib "^1.9.0" + safe-buffer@^5.0.1, safe-buffer@^5.1.2, safe-buffer@~5.1.0, safe-buffer@~5.1.1: version "5.1.2" resolved "https://registry.yarnpkg.com/safe-buffer/-/safe-buffer-5.1.2.tgz#991ec69d296e0313747d59bdfd2b745c35f8828d" integrity sha512-Gd2UZBJDkXlY7GbJxfsE8/nvKkUEU1G38c1siN6QP6a9PT9MmHB8GnpscSmMJSoF8LOIrt8ud/wPtojys4G6+g== -safer-buffer@^2.0.2, safer-buffer@^2.1.0, safer-buffer@~2.1.0: +"safer-buffer@>= 2.1.2 < 3", safer-buffer@^2.0.2, safer-buffer@^2.1.0, safer-buffer@~2.1.0: version "2.1.2" resolved "https://registry.yarnpkg.com/safer-buffer/-/safer-buffer-2.1.2.tgz#44fa161b0187b9549dd84bb91802f9bd8385cd6a" integrity sha512-YZo3K82SD7Riyi0E1EQPojLz7kpepnSQI9IyPbHHg1XXXevb5dJI7tpyN2ADxGcQbHG7vcyRHk0cbwqcQriUtg== -semver@^5.5.0: +semver@^5.5.0, semver@^5.5.1: version "5.6.0" resolved "https://registry.yarnpkg.com/semver/-/semver-5.6.0.tgz#7e74256fbaa49c75aa7c7a205cc22799cac80004" integrity sha512-RS9R6R35NYgQn++fkDWaOmqGoj4Ek9gGs+DPxNUZKuwE183xjJroKvyo1IzVFeXvUrvmALy6FWD5xrdJT25gMg== +shebang-command@^1.2.0: + version "1.2.0" + resolved "https://registry.yarnpkg.com/shebang-command/-/shebang-command-1.2.0.tgz#44aac65b695b03398968c39f363fee5deafdf1ea" + integrity sha1-RKrGW2lbAzmJaMOfNj/uXer98eo= + dependencies: + shebang-regex "^1.0.0" + +shebang-regex@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/shebang-regex/-/shebang-regex-1.0.0.tgz#da42f49740c0b42db2ca9728571cb190c98efea3" + integrity sha1-2kL0l0DAtC2yypcoVxyxkMmO/qM= + +signal-exit@^3.0.2: + version "3.0.2" + resolved "https://registry.yarnpkg.com/signal-exit/-/signal-exit-3.0.2.tgz#b5fdc08f1287ea1178628e415e25132b73646c6d" + integrity sha1-tf3AjxKH6hF4Yo5BXiUTK3NkbG0= + sinon@^7.2.2: version "7.2.2" resolved "https://registry.yarnpkg.com/sinon/-/sinon-7.2.2.tgz#388ecabd42fa93c592bfc71d35a70894d5a0ca07" @@ -1056,6 +1542,15 @@ sinon@^7.2.2: nise "^1.4.7" supports-color "^5.5.0" +slice-ansi@2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/slice-ansi/-/slice-ansi-2.0.0.tgz#5373bdb8559b45676e8541c66916cdd6251612e7" + integrity sha512-4j2WTWjp3GsZ+AOagyzVbzp4vWGtZ0hEZ/gDY/uTvm6MTxUfTUIsnMIFb1bn8o0RuXiqUw15H1bue8f22Vw2oQ== + dependencies: + ansi-styles "^3.2.0" + astral-regex "^1.0.0" + is-fullwidth-code-point "^2.0.0" + spawn-sync@^1.0.15: version "1.0.15" resolved "https://registry.yarnpkg.com/spawn-sync/-/spawn-sync-1.0.15.tgz#b00799557eb7fb0c8376c29d44e8a1ea67e57476" @@ -1064,6 +1559,11 @@ spawn-sync@^1.0.15: concat-stream "^1.4.7" os-shim "^0.1.2" +sprintf-js@~1.0.2: + version "1.0.3" + resolved "https://registry.yarnpkg.com/sprintf-js/-/sprintf-js-1.0.3.tgz#04e6926f662895354f3dd015203633b857297e2c" + integrity sha1-BOaSb2YolTVPPdAVIDYzuFcpfiw= + sshpk@^1.7.0: version "1.15.2" resolved "https://registry.yarnpkg.com/sshpk/-/sshpk-1.15.2.tgz#c946d6bd9b1a39d0e8635763f5242d6ed6dcb629" @@ -1093,7 +1593,7 @@ string-width@^1.0.1: is-fullwidth-code-point "^1.0.0" strip-ansi "^3.0.0" -string-width@^2.1.1: +string-width@^2.1.0, string-width@^2.1.1: version "2.1.1" resolved "https://registry.yarnpkg.com/string-width/-/string-width-2.1.1.tgz#ab93f27a8dc13d28cac815c462143a6d9012ae9e" integrity sha512-nOqH59deCq9SRHlxq1Aw85Jnt4w6KvLKqWVik6oA9ZklXLNIOlqg4F2yrT1MVaTjAqvVwdfeZ7w7aCvJD7ugkw== @@ -1122,6 +1622,18 @@ strip-ansi@^4.0.0: dependencies: ansi-regex "^3.0.0" +strip-ansi@^5.0.0: + version "5.0.0" + resolved "https://registry.yarnpkg.com/strip-ansi/-/strip-ansi-5.0.0.tgz#f78f68b5d0866c20b2c9b8c61b5298508dc8756f" + integrity sha512-Uu7gQyZI7J7gn5qLn1Np3G9vcYGTVqB+lFTytnDJv83dd8T22aGH451P3jueT2/QemInJDfxHB5Tde5OzgG1Ow== + dependencies: + ansi-regex "^4.0.0" + +strip-json-comments@^2.0.1: + version "2.0.1" + resolved "https://registry.yarnpkg.com/strip-json-comments/-/strip-json-comments-2.0.1.tgz#3c531942e908c2697c0ec344858c286c7ca0a60a" + integrity sha1-PFMZQukIwml8DsNEhYwobHygpgo= + supports-color@5.4.0: version "5.4.0" resolved "https://registry.yarnpkg.com/supports-color/-/supports-color-5.4.0.tgz#1c6b337402c2137605efe19f10fec390f6faab54" @@ -1134,13 +1646,23 @@ supports-color@^2.0.0: resolved "https://registry.yarnpkg.com/supports-color/-/supports-color-2.0.0.tgz#535d045ce6b6363fa40117084629995e9df324c7" integrity sha1-U10EXOa2Nj+kARcIRimZXp3zJMc= -supports-color@^5.5.0: +supports-color@^5.3.0, supports-color@^5.5.0: version "5.5.0" resolved "https://registry.yarnpkg.com/supports-color/-/supports-color-5.5.0.tgz#e2e69a44ac8772f78a1ec0b35b689df6530efc8f" integrity sha512-QjVjwdXIt408MIiAqCX4oUKsgU2EqAGzs2Ppkm4aQYbjm+ZEWEcW4SfFNTr4uMNZma0ey4f5lgLrkB0aX0QMow== dependencies: has-flag "^3.0.0" +table@^5.0.2: + version "5.2.1" + resolved "https://registry.yarnpkg.com/table/-/table-5.2.1.tgz#e78463702b1be9f7131c39860bcfb1b81114c2a1" + integrity sha512-qmhNs2GEHNqY5fd2Mo+8N1r2sw/rvTAAvBZTaTx+Y7PHLypqyrxr1MdIu0pLw6Xvl/Gi4ONu/sdceP8vvUjkyA== + dependencies: + ajv "^6.6.1" + lodash "^4.17.11" + slice-ansi "2.0.0" + string-width "^2.1.1" + tabtab@^2.2.2: version "2.2.2" resolved "https://registry.yarnpkg.com/tabtab/-/tabtab-2.2.2.tgz#7a047f143b010b4cbd31f857e82961512cbf4e14" @@ -1160,6 +1682,11 @@ text-encoding@^0.6.4: resolved "https://registry.yarnpkg.com/text-encoding/-/text-encoding-0.6.4.tgz#e399a982257a276dae428bb92845cb71bdc26d19" integrity sha1-45mpgiV6J22uQou5KEXLcb3CbRk= +text-table@^0.2.0: + version "0.2.0" + resolved "https://registry.yarnpkg.com/text-table/-/text-table-0.2.0.tgz#7f5ee823ae805207c00af2df4a84ec3fcfa570b4" + integrity sha1-f17oI66AUgfACvLfSoTsP8+lcLQ= + through@^2.3.6: version "2.3.8" resolved "https://registry.yarnpkg.com/through/-/through-2.3.8.tgz#0dd4c9ffaabc357960b1b724115d7e0e86a2e1f5" @@ -1172,6 +1699,13 @@ tmp@^0.0.29: dependencies: os-tmpdir "~1.0.1" +tmp@^0.0.33: + version "0.0.33" + resolved "https://registry.yarnpkg.com/tmp/-/tmp-0.0.33.tgz#6d34335889768d21b2bcda0aa277ced3b1bfadf9" + integrity sha512-jRCJlojKnZ3addtTOjdIqoRuPEKBvNXcGYqzO6zWZX8KfKEpnGY5jfggJQ3EjKuu8D4bJRr0y+cYJFmYbImXGw== + dependencies: + os-tmpdir "~1.0.2" + tough-cookie@~2.4.3: version "2.4.3" resolved "https://registry.yarnpkg.com/tough-cookie/-/tough-cookie-2.4.3.tgz#53f36da3f47783b0925afa06ff9f3b165280f781" @@ -1180,6 +1714,11 @@ tough-cookie@~2.4.3: psl "^1.1.24" punycode "^1.4.1" +tslib@^1.9.0: + version "1.9.3" + resolved "https://registry.yarnpkg.com/tslib/-/tslib-1.9.3.tgz#d7e4dd79245d85428c4d7e4822a79917954ca286" + integrity sha512-4krF8scpejhaOgqzBEcGM7yDIEfi0/8+8zDRZhNZZ2kjmHJ4hv3zCbQWxoJGz1iw5U0Jl0nma13xzHXcncMavQ== + tunnel-agent@^0.6.0: version "0.6.0" resolved "https://registry.yarnpkg.com/tunnel-agent/-/tunnel-agent-0.6.0.tgz#27a5dea06b36b04a0a9966774b290868f0fc40fd" @@ -1192,6 +1731,13 @@ tweetnacl@^0.14.3, tweetnacl@~0.14.0: resolved "https://registry.yarnpkg.com/tweetnacl/-/tweetnacl-0.14.5.tgz#5ae68177f192d4456269d108afa93ff8743f4f64" integrity sha1-WuaBd/GS1EViadEIr6k/+HQ/T2Q= +type-check@~0.3.2: + version "0.3.2" + resolved "https://registry.yarnpkg.com/type-check/-/type-check-0.3.2.tgz#5884cab512cf1d355e3fb784f30804b2b520db72" + integrity sha1-WITKtRLPHTVeP7eE8wgEsrUg23I= + dependencies: + prelude-ls "~1.1.2" + type-detect@4.0.8, type-detect@^4.0.0, type-detect@^4.0.5: version "4.0.8" resolved "https://registry.yarnpkg.com/type-detect/-/type-detect-4.0.8.tgz#7646fb5f18871cfbb7749e69bd39a6388eb7450c" @@ -1233,6 +1779,13 @@ verror@1.10.0: core-util-is "1.0.2" extsprintf "^1.2.0" +which@^1.2.9: + version "1.3.1" + resolved "https://registry.yarnpkg.com/which/-/which-1.3.1.tgz#a45043d54f5805316da8d62f9f50918d3da70b0a" + integrity sha512-HxJdYWq1MTIQbJ3nw0cqssHoTNU267KlrDuGZ1WYlxDStUtKUhOaJmh112/TZmHxxUfuJqPXSOm7tDyas0OSIQ== + dependencies: + isexe "^2.0.0" + winston@^2.3.1: version "2.4.4" resolved "https://registry.yarnpkg.com/winston/-/winston-2.4.4.tgz#a01e4d1d0a103cf4eada6fc1f886b3110d71c34b" @@ -1245,11 +1798,23 @@ winston@^2.3.1: isstream "0.1.x" stack-trace "0.0.x" +wordwrap@~1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/wordwrap/-/wordwrap-1.0.0.tgz#27584810891456a4171c8d0226441ade90cbcaeb" + integrity sha1-J1hIEIkUVqQXHI0CJkQa3pDLyus= + wrappy@1: version "1.0.2" resolved "https://registry.yarnpkg.com/wrappy/-/wrappy-1.0.2.tgz#b5243d8f3ec1aa35f1364605bc0d1036e30ab69f" integrity sha1-tSQ9jz7BqjXxNkYFvA0QNuMKtp8= +write@^0.2.1: + version "0.2.1" + resolved "https://registry.yarnpkg.com/write/-/write-0.2.1.tgz#5fc03828e264cea3fe91455476f7a3c566cb0757" + integrity sha1-X8A4KOJkzqP+kUVUdvejxWbLB1c= + dependencies: + mkdirp "^0.5.1" + "xmldom@>= 0.1.x": version "0.1.27" resolved "https://registry.yarnpkg.com/xmldom/-/xmldom-0.1.27.tgz#d501f97b3bdb403af8ef9ecc20573187aadac0e9" diff --git a/example/README.md b/example/README.md index b7f70d351..298931698 100644 --- a/example/README.md +++ b/example/README.md @@ -11,7 +11,7 @@ helm upgrade --install soluto/kamus Start by encrypting a secret using the CLI: ``` -kamus-cli encrypt super-secret kamus-example-sa default --kamus-url +kamus-cli encrypt super-secret kamus-example-sa default --kamus-api-url ``` You might have to pass aditional arguments, based on your installation. @@ -22,7 +22,7 @@ Now, run ``` kubectl apply -f deployment-kamus/ ``` -To deploy the example app. +To deploy the example app. Check deployment status using ``` kubectl get pods From 6b6b0611dbe536023a1c37826236d342204ed93d Mon Sep 17 00:00:00 2001 From: AleF83 Date: Tue, 15 Jan 2019 18:08:22 +0200 Subject: [PATCH 3/9] Tiny refactor --- cli/README.md | 2 +- cli/package.json | 2 +- cli/test/{encrypt.js => encrypt.spec.js} | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) rename cli/test/{encrypt.js => encrypt.spec.js} (95%) diff --git a/cli/README.md b/cli/README.md index 43d55f59a..3ae2b6324 100644 --- a/cli/README.md +++ b/cli/README.md @@ -40,5 +40,5 @@ Once the user will run the cli with the auth options, he will get a small code a | --auth-application | false | azure authentication application id | | | --auth-resource | false | azure authentication resource id | | | --cert-fingerprint | false | [certificate fingerprint](http://hassansin.github.io/certificate-pinning-in-nodejs) of encrypt api for validation | | -| --kamus-api-url | true | url of kamus encrypt api | | +| --kamus-api-url | true | url of kamus encrypt api | | | --allow-insecure-url | false | allow or block non https endpoints | false | diff --git a/cli/package.json b/cli/package.json index 286102df2..10e3252e8 100644 --- a/cli/package.json +++ b/cli/package.json @@ -4,7 +4,7 @@ "description": "CLI Tool to encrypt secrets for kamus", "main": "index.js", "scripts": { - "test": "node_modules/.bin/mocha", + "test": "node_modules/.bin/mocha ./test/*.spec.js", "ci-publish": "ci-publish" }, "repository": { diff --git a/cli/test/encrypt.js b/cli/test/encrypt.spec.js similarity index 95% rename from cli/test/encrypt.js rename to cli/test/encrypt.spec.js index e8055eb23..7a79d0f7c 100644 --- a/cli/test/encrypt.js +++ b/cli/test/encrypt.spec.js @@ -2,7 +2,7 @@ const expect = require('chai').expect; const nock = require('nock'); const sinon = require('sinon'); -const encrypt = require('../actions/encrypt.js'); +const encrypt = require('../actions/encrypt'); const logger = { From f9f34b6df6efa9a1b011f4031f08807366f869f7 Mon Sep 17 00:00:00 2001 From: AleF83 Date: Wed, 16 Jan 2019 08:58:11 +0200 Subject: [PATCH 4/9] Remove bold inserted by mistake --- cli/README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/cli/README.md b/cli/README.md index 3ae2b6324..a0abe1991 100644 --- a/cli/README.md +++ b/cli/README.md @@ -17,7 +17,7 @@ docker run -it --rm soluto/kamus-cli encrypt ``` Or, using kubectl: ``` -kubectl run -it --rm --restart=Never kamus-cli --image=**soluto**/kamus-cli -- encrypt +kubectl run -it --rm --restart=Never kamus-cli --image=soluto/kamus-cli -- encrypt ``` --- From 53577b6b7fb597cfe6185a84b1dfae42f5c46e4f Mon Sep 17 00:00:00 2001 From: AleF83 Date: Wed, 16 Jan 2019 09:25:27 +0200 Subject: [PATCH 5/9] bug fixed --- cli/actions/encrypt.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/cli/actions/encrypt.js b/cli/actions/encrypt.js index 7a63595b5..cee2b9882 100644 --- a/cli/actions/encrypt.js +++ b/cli/actions/encrypt.js @@ -10,7 +10,7 @@ var pjson = require('../package.json'); let _logger; -module.exports = async (options, logger) => { +module.exports = async (args, options, logger) => { _logger = logger; if (useAuth(options)) { const token = await acquireToken(options); From ee535e522d980ac54b68f10487e6428966d1d8b1 Mon Sep 17 00:00:00 2001 From: AleF83 Date: Wed, 16 Jan 2019 10:05:18 +0200 Subject: [PATCH 6/9] api removed from kamus-api-url argument --- README.md | 4 ++-- cli/README.md | 4 ++-- cli/index.js | 2 +- example/README.md | 2 +- 4 files changed, 6 insertions(+), 6 deletions(-) diff --git a/README.md b/README.md index c23aedb36..c13e6397e 100644 --- a/README.md +++ b/README.md @@ -20,9 +20,9 @@ npm install -g @soluto-asurion/kamus-cli ``` Use Kamus CLI to encrypt the secret: ``` -kamus-cli encrypt --secret super-secret --service-account kamus-example-sa --namespace default --kamus-api-url +kamus-cli encrypt --secret super-secret --service-account kamus-example-sa --namespace default --kamus-url ``` -*If you're running Kamus locally the Kamus API URL will be like `http://localhost:`. So you need to add `--allow-insecure-url` flag to enable http protocol.* +*If you're running Kamus locally the Kamus URL will be like `http://localhost:`. So you need to add `--allow-insecure-url` flag to enable http protocol.* Pass the value returned by the CLI to your pod, and use Kamus Decrypt API to decrypt the value. The simplest way to achieve that is by using the init container. diff --git a/cli/README.md b/cli/README.md index a0abe1991..67de11cff 100644 --- a/cli/README.md +++ b/cli/README.md @@ -24,7 +24,7 @@ kubectl run -it --rm --restart=Never kamus-cli --image=soluto/kamus-cli -- encry #### Supported commands: ##### Encrypt -`kamus-cli encrypt --secret --service-account --namespace --kamus-api-url ` +`kamus-cli encrypt --secret --service-account --namespace --kamus-url ` --- #### How to enable azure active directory authentication @@ -40,5 +40,5 @@ Once the user will run the cli with the auth options, he will get a small code a | --auth-application | false | azure authentication application id | | | --auth-resource | false | azure authentication resource id | | | --cert-fingerprint | false | [certificate fingerprint](http://hassansin.github.io/certificate-pinning-in-nodejs) of encrypt api for validation | | -| --kamus-api-url | true | url of kamus encrypt api | | +| --kamus-url | true | url of kamus encrypt api | | | --allow-insecure-url | false | allow or block non https endpoints | false | diff --git a/cli/index.js b/cli/index.js index 4bb8cad54..15f31c683 100755 --- a/cli/index.js +++ b/cli/index.js @@ -12,7 +12,7 @@ prog .option('--secret ','Data to encrypt', prog.REQUIRED) .option('--service-account ', 'Deployment service account', prog.REQUIRED) .option('--namespace ', 'Deployment namespace', prog.REQUIRED) - .option('--kamus-api-url ', 'Kamus URL', prog.REQUIRED) + .option('--kamus-url ', 'Kamus URL', prog.REQUIRED) .option('--auth-tenant ', 'Azure tenant id', regexGuid) .option('--auth-application ', 'Azure application id', regexGuid) .option('--auth-resource ', 'Azure resource name', prog.STRING) diff --git a/example/README.md b/example/README.md index 298931698..269e88d24 100644 --- a/example/README.md +++ b/example/README.md @@ -11,7 +11,7 @@ helm upgrade --install soluto/kamus Start by encrypting a secret using the CLI: ``` -kamus-cli encrypt super-secret kamus-example-sa default --kamus-api-url +kamus-cli encrypt super-secret kamus-example-sa default --kamus-url ``` You might have to pass aditional arguments, based on your installation. From ae6438e34e21c463bbec0e2319b962d1a2b1d7b9 Mon Sep 17 00:00:00 2001 From: AleF83 Date: Wed, 16 Jan 2019 10:28:19 +0200 Subject: [PATCH 7/9] One more fix --- cli/actions/encrypt.js | 8 ++++---- cli/index.js | 2 +- cli/is-docker.js | 4 ++-- cli/test/encrypt.spec.js | 6 +++--- 4 files changed, 10 insertions(+), 10 deletions(-) diff --git a/cli/actions/encrypt.js b/cli/actions/encrypt.js index cee2b9882..c8f6c7d5c 100644 --- a/cli/actions/encrypt.js +++ b/cli/actions/encrypt.js @@ -22,17 +22,17 @@ module.exports = async (args, options, logger) => { } } -const encrypt = async ({ data, serviceAccount, namespace, kamusApiUrl, allowInsecureUrl, certFingerprint }, token = null) => { +const encrypt = async ({ data, serviceAccount, namespace, kamusUrl, allowInsecureUrl, certFingerprint }, token = null) => { _logger.log('Encryption started...'); _logger.log('service account:', serviceAccount); _logger.log('namespace:', namespace); - if (!allowInsecureUrl && url.parse(kamusApiUrl).protocol !== 'https:') { + if (!allowInsecureUrl && url.parse(kamusUrl).protocol !== 'https:') { _logger.error("Insecure Kamus URL is not allowed"); process.exit(1); } try { - const response = await performEncryptRequestAsync(data, serviceAccount, namespace, kamusApiUrl, certFingerprint, token); + const response = await performEncryptRequestAsync(data, serviceAccount, namespace, kamusUrl, certFingerprint, token); if (response && response.statusCode >= 300) { _logger.error(`Encrypt request failed due to unexpected error. Status code: ${response.statusCode}`); process.exit(1); @@ -48,7 +48,7 @@ const encrypt = async ({ data, serviceAccount, namespace, kamusApiUrl, allowInse } const acquireToken = async ({ authTenant, authApplication, authResource }) => { - const context = new AuthenticationContext(activeDirectoryEndpoint + authTenant); + const context = new AuthenticationContext(`${activeDirectoryEndpoint}${authTenant}`); bluebird.promisifyAll(context); refreshToken = await acquireTokenWithDeviceCode(context, authApplication, authResource); const refreshTokenResponse = diff --git a/cli/index.js b/cli/index.js index 15f31c683..4d274517e 100755 --- a/cli/index.js +++ b/cli/index.js @@ -1,6 +1,6 @@ #!/usr/bin/env node -var pjson = require('./package.json'); +const pjson = require('./package.json'); const prog = require('caporal'); const encrypt = require('./actions/encrypt'); const regexGuid = /^[0-9a-f]{8}-[0-9a-f]{4}-[1-5][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}$/i; diff --git a/cli/is-docker.js b/cli/is-docker.js index 762d603ec..33ae28d43 100644 --- a/cli/is-docker.js +++ b/cli/is-docker.js @@ -1,6 +1,6 @@ -var fs = require('fs'); +const fs = require('fs'); -var isDocker; +let isDocker; function hasDockerEnv() { try { diff --git a/cli/test/encrypt.spec.js b/cli/test/encrypt.spec.js index 7a79d0f7c..9e12411a8 100644 --- a/cli/test/encrypt.spec.js +++ b/cli/test/encrypt.spec.js @@ -12,7 +12,7 @@ const logger = log: console.log }; -const kamusApiUrl = 'https://kamus.com'; +const kamusUrl = 'https://kamus.com'; const data = 'super-secret'; const serviceAccount = 'dummy'; const namespace = 'team-a'; @@ -22,13 +22,13 @@ let kamusApiScope; describe('Encrypt', () => { beforeEach(() => { sinon.stub(process, 'exit'); - kamusApiScope = nock(kamusApiUrl) + kamusApiScope = nock(kamusUrl) .post('/api/v1/encrypt', { data, ['service-account']: serviceAccount, namespace}) .reply(200, '123ABC'); }); it('Should return encrypted data', async () => { - await encrypt({data, serviceAccount, namespace, kamusApiUrl}, logger); + await encrypt(null, {data, serviceAccount, namespace, kamusUrl}, logger); expect(kamusApiScope.isDone()).to.be.true; expect(process.exit.called).to.be.true; expect(process.exit.calledWith(0)).to.be.true; From a2b0a494261c31d36e207c06cb0bd606def72aee Mon Sep 17 00:00:00 2001 From: AleF83 Date: Wed, 16 Jan 2019 15:33:14 +0200 Subject: [PATCH 8/9] CLI package version bumped --- cli/Dockerfile | 2 +- cli/package.json | 2 +- cli/yarn.lock | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/cli/Dockerfile b/cli/Dockerfile index 3f727ba89..0a1a31b94 100644 --- a/cli/Dockerfile +++ b/cli/Dockerfile @@ -1,5 +1,5 @@ FROM node:10-alpine -ARG CLI_VERSION=0.0.6 +ARG CLI_VERSION=0.0.7 RUN yarn global add @soluto-asurion/kamus-cli@${CLI_VERSION} ENTRYPOINT ["kamus-cli"] \ No newline at end of file diff --git a/cli/package.json b/cli/package.json index 10e3252e8..28ac3eb10 100644 --- a/cli/package.json +++ b/cli/package.json @@ -1,6 +1,6 @@ { "name": "@soluto-asurion/kamus-cli", - "version": "0.0.6", + "version": "0.0.7", "description": "CLI Tool to encrypt secrets for kamus", "main": "index.js", "scripts": { diff --git a/cli/yarn.lock b/cli/yarn.lock index d272313f3..5571c6d4a 100644 --- a/cli/yarn.lock +++ b/cli/yarn.lock @@ -535,7 +535,7 @@ eslint-visitor-keys@^1.0.0: resolved "https://registry.yarnpkg.com/eslint-visitor-keys/-/eslint-visitor-keys-1.0.0.tgz#3f3180fb2e291017716acb4c9d6d5b5c34a6a81d" integrity sha512-qzm/XxIbxm/FHyH341ZrbnMUpe+5Bocte9xkmFMzPMjRaZMcXww+MpBptFvtU+79L362nqiLhekCxCxDPaUMBQ== -eslint@5.12.0: +eslint@^5.12.0: version "5.12.0" resolved "https://registry.yarnpkg.com/eslint/-/eslint-5.12.0.tgz#fab3b908f60c52671fb14e996a450b96c743c859" integrity sha512-LntwyPxtOHrsJdcSwyQKVtHofPHdv+4+mFwEe91r2V13vqpM8yLr7b1sW+Oo/yheOPkWYsYlYJCkzlFAt8KV7g== From 15b87afe626d808d65ffc92ffd1a7ce1dd4a3c8d Mon Sep 17 00:00:00 2001 From: AleF83 Date: Thu, 17 Jan 2019 11:54:14 +0200 Subject: [PATCH 9/9] Short alias to options provided --- cli/index.js | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/cli/index.js b/cli/index.js index 4d274517e..158192a7f 100755 --- a/cli/index.js +++ b/cli/index.js @@ -9,10 +9,10 @@ prog .version(pjson.version) .command('encrypt', 'Encrypt data') .action(encrypt) - .option('--secret ','Data to encrypt', prog.REQUIRED) - .option('--service-account ', 'Deployment service account', prog.REQUIRED) - .option('--namespace ', 'Deployment namespace', prog.REQUIRED) - .option('--kamus-url ', 'Kamus URL', prog.REQUIRED) + .option('-s, --secret ','Data to encrypt', prog.REQUIRED) + .option('-a, --service-account ', 'Deployment service account', prog.REQUIRED) + .option('-n, --namespace ', 'Deployment namespace', prog.REQUIRED) + .option('-u, --kamus-url ', 'Kamus URL', prog.REQUIRED) .option('--auth-tenant ', 'Azure tenant id', regexGuid) .option('--auth-application ', 'Azure application id', regexGuid) .option('--auth-resource ', 'Azure resource name', prog.STRING)