@sw-tsdk/plugin-connector 2.0.1-next.47 → 2.0.1-next.68
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 +33 -29
- package/lib/commands/action/add.js +1 -1
- package/lib/commands/action/add.js.map +1 -1
- package/lib/commands/action/generate/data.d.ts +5 -3
- package/lib/commands/action/generate/data.js +61 -48
- package/lib/commands/action/generate/data.js.map +1 -1
- package/lib/commands/action/{input.d.ts → generate/input.d.ts} +0 -0
- package/lib/commands/action/{input.js → generate/input.js} +1 -2
- package/lib/commands/action/generate/input.js.map +1 -0
- package/lib/commands/action/{output.d.ts → generate/output.d.ts} +0 -0
- package/lib/commands/action/{output.js → generate/output.js} +1 -2
- package/lib/commands/action/generate/output.js.map +1 -0
- package/lib/commands/action/run/image.d.ts +2 -1
- package/lib/commands/action/run/image.js +12 -6
- package/lib/commands/action/run/image.js.map +1 -1
- package/lib/commands/action/run/local.js +22 -5
- package/lib/commands/action/run/local.js.map +1 -1
- package/lib/commands/asset/add.js +2 -1
- package/lib/commands/asset/add.js.map +1 -1
- package/lib/commands/connector/create.js +7 -1
- package/lib/commands/connector/create.js.map +1 -1
- package/lib/commands/connector/sign.js +1 -1
- package/lib/commands/connector/sign.js.map +1 -1
- package/lib/common.d.ts +1 -0
- package/lib/common.js +25 -9
- package/lib/common.js.map +1 -1
- package/lib/templates/assets/apikey.yaml +0 -1
- package/lib/templates/assets/http_basic.yaml +0 -1
- package/lib/templates/assets/http_bearer.yaml +1 -2
- package/lib/templates/assets/oauth2_client_credentials.yaml +1 -1
- package/lib/templates/assets/oauth2_password.yaml +59 -0
- package/lib/templates/python_310_definition/template/connector/config/actions/example.yaml +1 -1
- package/oclif.manifest.json +1 -1
- package/package.json +12 -11
- package/lib/commands/action/input.js.map +0 -1
- package/lib/commands/action/output.js.map +0 -1
|
@@ -12,6 +12,7 @@ const slug_1 = tslib_1.__importDefault(require("slug"));
|
|
|
12
12
|
const docker_reference_1 = require("@swimlane/docker-reference");
|
|
13
13
|
const connector_1 = require("@sw-tsdk/connector");
|
|
14
14
|
const common_1 = require("../../../common");
|
|
15
|
+
const connector_interfaces_1 = require("@swimlane/connector-interfaces");
|
|
15
16
|
// noinspection JSUnusedGlobalSymbols
|
|
16
17
|
class Local extends core_2.Base {
|
|
17
18
|
constructor() {
|
|
@@ -19,6 +20,7 @@ class Local extends core_2.Base {
|
|
|
19
20
|
this.docker = new docker_1.Docker();
|
|
20
21
|
}
|
|
21
22
|
async run() {
|
|
23
|
+
var _a;
|
|
22
24
|
const { flags, } = await this.parse(Local);
|
|
23
25
|
let { directory, } = flags;
|
|
24
26
|
let image = '';
|
|
@@ -28,15 +30,28 @@ class Local extends core_2.Base {
|
|
|
28
30
|
try {
|
|
29
31
|
await fs_extra_1.promises.access(directory);
|
|
30
32
|
}
|
|
31
|
-
catch (
|
|
33
|
+
catch (_b) {
|
|
32
34
|
this.error(`Could not access ${directory}`);
|
|
33
35
|
}
|
|
34
36
|
// select action if not provided.
|
|
35
37
|
const actionToExecute = action || await (0, common_1.chooseAction)(directory);
|
|
38
|
+
const manifests = await (0, connector_1.allManifests)(directory);
|
|
39
|
+
const assetManifests = manifests.assetManifests;
|
|
40
|
+
let assetName = assetManifests.length === 1 ? assetManifests[0].name : '';
|
|
41
|
+
if (assetManifests.length > 1) {
|
|
42
|
+
assetName = await (0, common_1.chooseAsset)(directory);
|
|
43
|
+
}
|
|
44
|
+
const actions = manifests.actionManifests;
|
|
45
|
+
if (!actions.some((x) => x.name === actionToExecute)) {
|
|
46
|
+
this.error(`Invalid action: ${actionToExecute}`);
|
|
47
|
+
return;
|
|
48
|
+
}
|
|
49
|
+
const connectorManifest = manifests.connectorManifest;
|
|
50
|
+
const useStdin = (connectorManifest.runConfig && connectorManifest.runConfig.inputs.type === connector_interfaces_1.ConnectorInputsType.stdin);
|
|
36
51
|
const inputPath = flags['input-path'] || (0, node_path_1.join)(directory, 'data', `${actionToExecute}.json`);
|
|
37
52
|
const outputPath = flags['output-path'] || (0, node_path_1.join)(directory, 'data', `${actionToExecute}_output.json`);
|
|
38
53
|
const errorPath = flags['error-path'] || (0, node_path_1.join)(directory, 'data', `${actionToExecute}_error.txt`);
|
|
39
|
-
const assetPath = flags['asset-path'] || (0, node_path_1.join)(directory, 'data', 'asset.json
|
|
54
|
+
const assetPath = flags['asset-path'] || (0, node_path_1.join)(directory, 'data', `${assetName || 'asset'}.json`);
|
|
40
55
|
if (!await (0, core_2.fileExists)(inputPath)) {
|
|
41
56
|
core_1.CliUx.ux.error(`Missing test data ${inputPath}`);
|
|
42
57
|
}
|
|
@@ -68,19 +83,20 @@ class Local extends core_2.Base {
|
|
|
68
83
|
await fs_extra_1.promises.writeFile(outputPath, '{}');
|
|
69
84
|
await fs_extra_1.promises.writeFile(errorPath, '');
|
|
70
85
|
const containerReference = (0, docker_reference_1.parseQualifiedName)(image);
|
|
71
|
-
this.containerName = (0, slug_1.default)(containerReference.repository);
|
|
86
|
+
this.containerName = (0, slug_1.default)((_a = containerReference.repository) !== null && _a !== void 0 ? _a : '');
|
|
72
87
|
const cleanup = this.cleanup;
|
|
73
88
|
node_process_1.default.on('SIGINT', async function () {
|
|
74
89
|
await cleanup();
|
|
75
90
|
});
|
|
76
91
|
const environmentVars = Object.entries({
|
|
77
|
-
INPUTS: inputs,
|
|
92
|
+
INPUTS: useStdin ? '' : inputs,
|
|
78
93
|
IPC_API_URI: 'http://localhost:8080',
|
|
79
94
|
IPC_API_TOKEN: '',
|
|
80
95
|
}).map(([key, value]) => `${key}=${value !== null && value !== void 0 ? value : ''}`);
|
|
81
96
|
const createOptions = {
|
|
82
97
|
Env: environmentVars,
|
|
83
98
|
name: this.containerName,
|
|
99
|
+
AttachStdin: useStdin,
|
|
84
100
|
AttachStdout: true,
|
|
85
101
|
AttachStderr: true,
|
|
86
102
|
Cmd: [actionToExecute],
|
|
@@ -91,11 +107,12 @@ class Local extends core_2.Base {
|
|
|
91
107
|
core_1.CliUx.ux.action.start('Executing...');
|
|
92
108
|
const outputFile = new connector_1.ContainerStdoutActionOutputTransform((0, fs_extra_1.createWriteStream)(outputPath));
|
|
93
109
|
const errorFile = await (0, fs_extra_1.createWriteStream)(errorPath);
|
|
94
|
-
const success = await this.docker.
|
|
110
|
+
const success = await this.docker.runStdinImage(image, createOptions, outputFile, errorFile, inputs);
|
|
95
111
|
core_1.CliUx.ux.action.stop();
|
|
96
112
|
if (!success) {
|
|
97
113
|
core_1.Errors.exit(-1);
|
|
98
114
|
}
|
|
115
|
+
await this.cleanup();
|
|
99
116
|
}
|
|
100
117
|
async catch(error) {
|
|
101
118
|
await this.cleanup();
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"local.js","sourceRoot":"","sources":["../../../../src/commands/action/run/local.ts"],"names":[],"mappings":";;;;AAAA,sCAAgD;AAChD,wCAA8C;AAC9C,yCAAuC;AACvC,uCAAyE;AACzE,4CAAqD;AACrD,wEAAkC;AAClC,wDAAuB;AACvB,iEAA6D;AAC7D,
|
|
1
|
+
{"version":3,"file":"local.js","sourceRoot":"","sources":["../../../../src/commands/action/run/local.ts"],"names":[],"mappings":";;;;AAAA,sCAAgD;AAChD,wCAA8C;AAC9C,yCAAuC;AACvC,uCAAyE;AACzE,4CAAqD;AACrD,wEAAkC;AAClC,wDAAuB;AACvB,iEAA6D;AAC7D,kDAAqG;AACrG,4CAAyD;AACzD,yEAA2F;AAE3F,qCAAqC;AACrC,MAAa,KAAM,SAAQ,WAAI;IAA/B;;QAuDU,WAAM,GAAW,IAAI,eAAM,EAAE,CAAA;IAwJvC,CAAC;IArJC,KAAK,CAAC,GAAG;;QACP,MAAM,EACJ,KAAK,GACN,GAAG,MAAM,IAAI,CAAC,KAAK,CAAC,KAAK,CAAC,CAAA;QAE3B,IAAI,EACF,SAAS,GACV,GAAG,KAAK,CAAA;QAET,IAAI,KAAK,GAAG,EAAE,CAAA;QAEd,MAAM,EACJ,QAAQ,EACR,MAAM,EACN,kBAAkB,EAA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CAAC,EACF,eAAe,EAAE,YAAK,CAAC,OAAO,CAAC;QAC7B,IAAI,EAAE,GAAG;QACT,WAAW,EAAE,mCAAmC;KACjD,CAAC,EACF,QAAQ,EAAE,YAAK,CAAC,MAAM,CAAC;QACrB,MAAM,EAAE,IAAI;QACZ,OAAO,EAAE,aAAa;KACvB,CAAC,EACF,IAAI,EAAE,YAAK,CAAC,IAAI,CAAC;QACf,IAAI,EAAE,GAAG;KACV,CAAC,IACH"}
|
|
@@ -23,6 +23,7 @@ class Add extends core_2.Base {
|
|
|
23
23
|
'custom',
|
|
24
24
|
'apikey',
|
|
25
25
|
'oauth2_client_credentials',
|
|
26
|
+
'oauth2_password',
|
|
26
27
|
'http_basic',
|
|
27
28
|
'http_bearer',
|
|
28
29
|
],
|
|
@@ -43,7 +44,7 @@ Add.flags = Object.assign(Object.assign({}, core_2.Base.flags), { directory: cor
|
|
|
43
44
|
}), scheme: core_1.Flags.string({
|
|
44
45
|
char: 's',
|
|
45
46
|
description: 'asset template to scaffold',
|
|
46
|
-
options: ['custom', 'apikey', '
|
|
47
|
+
options: ['custom', 'apikey', 'oauth2_client_credentials', 'http_basic', 'http_bearer'],
|
|
47
48
|
}), help: core_1.Flags.help({
|
|
48
49
|
char: 'h',
|
|
49
50
|
}) });
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"add.js","sourceRoot":"","sources":["../../../src/commands/asset/add.ts"],"names":[],"mappings":";;;;AAAA,sCAAwC;AACxC,wCAAkC;AAClC,yCAAuC;AACvC,uCAA6B;AAC7B,wEAAkC;AAClC,gEAA+B;AAE/B,qCAAqC;AACrC,MAAa,GAAI,SAAQ,WAAI;IAoB3B,KAAK,CAAC,GAAG;QACP,MAAM,EACJ,KAAK,GACN,GAAG,MAAM,IAAI,CAAC,KAAK,CAAC,GAAG,CAAC,CAAA;QAEzB,IAAI,EACF,SAAS,EACT,MAAM,GACP,GAAG,KAAK,CAAA;QAET,SAAS,GAAG,IAAA,mBAAO,EAAC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EAAE,YAAK,CAAC,IAAI,CAAC;QACf,IAAI,EAAE,GAAG;KACV,CAAC,IACH"}
|
|
@@ -9,6 +9,7 @@ const node_fs_1 = require("node:fs");
|
|
|
9
9
|
const connector_1 = require("@sw-tsdk/connector");
|
|
10
10
|
const inquirer_1 = tslib_1.__importDefault(require("inquirer"));
|
|
11
11
|
const common_1 = require("../../common");
|
|
12
|
+
const connector_interfaces_1 = require("@swimlane/connector-interfaces");
|
|
12
13
|
const fs_extra_1 = require("fs-extra");
|
|
13
14
|
const js_yaml_1 = tslib_1.__importDefault(require("js-yaml"));
|
|
14
15
|
const snake_case_1 = require("snake-case");
|
|
@@ -118,6 +119,11 @@ class Create extends core_2.Base {
|
|
|
118
119
|
repository: `https://github.com/swimlane/t_${name}`,
|
|
119
120
|
title: await (0, connector_1.titleCaseString)(`${answers.vendor} ${answers.product}`),
|
|
120
121
|
version: '1.0.0',
|
|
122
|
+
runConfig: {
|
|
123
|
+
inputs: {
|
|
124
|
+
type: connector_interfaces_1.ConnectorInputsType.stdin,
|
|
125
|
+
},
|
|
126
|
+
},
|
|
121
127
|
};
|
|
122
128
|
core_1.CliUx.ux.action.start('Generating folder structure.');
|
|
123
129
|
// copy the examples over.
|
|
@@ -160,7 +166,7 @@ Create.flags = Object.assign(Object.assign({}, core_2.Base.flags), { directory:
|
|
|
160
166
|
description: 'client id of the authentication app',
|
|
161
167
|
default: '0d418a5615c458b0b593',
|
|
162
168
|
hidden: true,
|
|
163
|
-
}), vendor: core_1.Flags.string({ description: 'Vendor (e.g. CrowdStrike)' }), product: core_1.Flags.string({ description: 'Product (e.g. Falcon)' }), keywords: core_1.Flags.string({ description: '
|
|
169
|
+
}), vendor: core_1.Flags.string({ description: 'Vendor (e.g. CrowdStrike)' }), product: core_1.Flags.string({ description: 'Product (e.g. Falcon)' }), keywords: core_1.Flags.string({ description: 'Enter keyword (Comma-Separated)' }), description: core_1.Flags.string({ description: 'Description (e.g. CrowdStrike Host Query API)' }), logoPath: core_1.Flags.string({ description: 'URL or absolute path to logo file' }), author: core_1.Flags.string({ description: 'Connector Author' }), authorEmail: core_1.Flags.string({ description: 'Connector Author Email' }), homepage: core_1.Flags.string({ description: 'Connector Author Support URL' }), 'repo-base-template': core_1.Flags.string({
|
|
164
170
|
char: 't',
|
|
165
171
|
description: 'github base template override to create repo from.',
|
|
166
172
|
default: 'connector-python-definition-template',
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"create.js","sourceRoot":"","sources":["../../../src/commands/connector/create.ts"],"names":[],"mappings":";;;;AAAA,sCAAwC;AACxC,wCAAkC;AAClC,yCAAuC;AACvC,qCAAgC;AAChC,kDAA+D;AAC/D,gEAA+B;AAC/B,yCAAoE;
|
|
1
|
+
{"version":3,"file":"create.js","sourceRoot":"","sources":["../../../src/commands/connector/create.ts"],"names":[],"mappings":";;;;AAAA,sCAAwC;AACxC,wCAAkC;AAClC,yCAAuC;AACvC,qCAAgC;AAChC,kDAA+D;AAC/D,gEAA+B;AAC/B,yCAAoE;AACpE,yEAAqF;AAErF,uCAA2D;AAC3D,8DAA0B;AAC1B,2CAAoC;AACpC,2CAAkC;AAElC,qCAAqC;AACrC,MAAa,MAAO,SAAQ,WAAI;IAwC9B,KAAK,CAAC,GAAG;QACP,MAAM,EAAC,KAAK,EAAC,GAAG,MAAM,IAAI,CAAC,KAAK,CAAC,MAAM,CAAC,CAAA;QAExC,IAAI,EAAC,SAAS,EAAC,GAAG,KAAK,CAAA;QACvB,SAAS,GAAG,IAAA,mBAAO,EAAC,SAAS,IAAI,OAAO,CAAC,GAAG,EAAE,CAAC,CAAA;QAE/C,MAAM,EACJ,QAAQ,EAAE,iBAAiB,GAC5B,GAAG,KAAK,CAAA;QAET,IAAI;YACF,MAAM,kBAAQ,CAAC,MAAM,CAAC,SAAS,CAAC,CAAA;SACjC;QAAC,WAAM;YACN,IAAI,CAAC,KAAK,CAAC,oBAAoB,SAAS,EAAE,CAAC,CAAA;SAC5C;QAED,MAAM,eAAe,G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C,EAAC,WAAW,EAAE,uBAAuB,EAAC,CAAC,EAC7D,QAAQ,EAAE,YAAK,CAAC,MAAM,CAAC,EAAC,WAAW,EAAE,iCAAiC,EAAC,CAAC,EACxE,WAAW,EAAE,YAAK,CAAC,MAAM,CAAC,EAAC,WAAW,EAAE,+CAA+C,EAAC,CAAC,EACzF,QAAQ,EAAE,YAAK,CAAC,MAAM,CAAC,EAAC,WAAW,EAAE,mCAAmC,EAAC,CAAC,EAC1E,MAAM,EAAE,YAAK,CAAC,MAAM,CAAC,EAAC,WAAW,EAAE,kBAAkB,EAAC,CAAC,EACvD,WAAW,EAAE,YAAK,CAAC,MAAM,CAAC,EAAC,WAAW,EAAE,wBAAwB,EAAC,CAAC,EAClE,QAAQ,EAAE,YAAK,CAAC,MAAM,CAAC,EAAC,WAAW,EAAE,8BAA8B,EAAC,CAAC,EACrE,oBAAoB,EAAE,YAAK,CAAC,MAAM,CAAC;QACjC,IAAI,EAAE,GAAG;QACT,WAAW,EAAE,oDAAoD;QACjE,OAAO,EAAE,sCAAsC;QAC/C,MAAM,EAAE,IAAI;KACb,CAAC,EACF,IAAI,EAAE,YAAK,CAAC,IAAI,CAAC,EAAC,IAAI,EAAE,GAAG,EAAC,CAAC,IAC9B"}
|
|
@@ -33,7 +33,7 @@ class Sign extends core_2.Base {
|
|
|
33
33
|
if (save) {
|
|
34
34
|
core_1.CliUx.ux.action.start('Saving Image...');
|
|
35
35
|
const { repository, tag } = (0, docker_reference_1.parseQualifiedName)(taggedImage);
|
|
36
|
-
const fileName = (0, node_path_1.join)(directory, `${repository.replace('/', '-')}-${tag}.tar.gz`);
|
|
36
|
+
const fileName = (0, node_path_1.join)(directory, `${(repository !== null && repository !== void 0 ? repository : '').replace('/', '-')}-${tag}.tar.gz`);
|
|
37
37
|
await (0, cosign_1.save)(taggedImage, (0, node_fs_1.createWriteStream)(fileName));
|
|
38
38
|
core_1.CliUx.ux.action.stop();
|
|
39
39
|
}
|
|
@@ -1 +1 @@
|
|
|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,WAAW,EAAE,oBAAoB;QACjC,QAAQ,EAAE,IAAI;KACf,CAAC,EACF,kBAAkB,EAAE,YAAK,CAAC,MAAM,CAAC,EAAC,WAAW,EAAE,mCAAmC,EAAE,OAAO,EAAE,EAAE,EAAC,CAAC,EACjG,IAAI,EAAE,YAAK,CAAC,OAAO,CAAC;QAClB,WAAW,EAAE,+CAA+C;KAC7D,CAAC,EACF,UAAU,EAAE,YAAK,CAAC,MAAM,CAAC,EAAC,WAAW,EAAE,2CAA2C,EAAE,QAAQ,EAAE,IAAI,EAAC,CAAC,EACpG,aAAa,EAAE,YAAK,CAAC,OAAO,CAAC;QAC3B,MAAM,EAAE,IAAI;KACb,CAAC,EACF,QAAQ,EAAE,YAAK,CAAC,MAAM,CAAC,EAAC,WAAW,EAAE,6BAA6B,EAAE,OAAO,EAAE,gBAAgB,EAAC,CAAC,EAC/F,IAAI,EAAE,YAAK,CAAC,IAAI,CAAC;QACf,IAAI,EAAE,GAAG;KACV,CAAC,IACH"}
|
package/lib/common.d.ts
CHANGED
package/lib/common.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.connectorTemplates = exports.connectorCategories = exports.chooseAction = void 0;
|
|
3
|
+
exports.connectorTemplates = exports.connectorCategories = exports.chooseAsset = exports.chooseAction = void 0;
|
|
4
4
|
const tslib_1 = require("tslib");
|
|
5
5
|
const inquirer_1 = tslib_1.__importDefault(require("inquirer"));
|
|
6
6
|
const inquirer_autocomplete_prompt_1 = tslib_1.__importDefault(require("inquirer-autocomplete-prompt"));
|
|
@@ -8,19 +8,35 @@ const connector_1 = require("@sw-tsdk/connector");
|
|
|
8
8
|
async function chooseAction(directory) {
|
|
9
9
|
inquirer_1.default.registerPrompt('autocomplete', inquirer_autocomplete_prompt_1.default);
|
|
10
10
|
const manifests = await (0, connector_1.allManifests)(directory);
|
|
11
|
-
const actions = manifests.
|
|
12
|
-
.
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
const answers = await inquirer_1.default.prompt([{
|
|
11
|
+
const actions = manifests.actionManifests
|
|
12
|
+
.sort((a, b) => a.name < b.name ? -1 : 1);
|
|
13
|
+
const answers = await inquirer_1.default.prompt([
|
|
14
|
+
{
|
|
16
15
|
type: 'autocomplete',
|
|
17
16
|
name: 'name',
|
|
18
|
-
message: 'Choose
|
|
19
|
-
source: () =>
|
|
20
|
-
}
|
|
17
|
+
message: 'Choose a task',
|
|
18
|
+
source: (_, input) => actions.filter((r) => !input || r.name.includes(input)).map((r) => r),
|
|
19
|
+
},
|
|
20
|
+
]);
|
|
21
21
|
return answers.name;
|
|
22
22
|
}
|
|
23
23
|
exports.chooseAction = chooseAction;
|
|
24
|
+
async function chooseAsset(directory) {
|
|
25
|
+
inquirer_1.default.registerPrompt('autocomplete', inquirer_autocomplete_prompt_1.default);
|
|
26
|
+
const manifests = await (0, connector_1.allManifests)(directory);
|
|
27
|
+
const actions = manifests.assetManifests
|
|
28
|
+
.sort((a, b) => a.name < b.name ? -1 : 1);
|
|
29
|
+
const answers = await inquirer_1.default.prompt([
|
|
30
|
+
{
|
|
31
|
+
type: 'autocomplete',
|
|
32
|
+
name: 'name',
|
|
33
|
+
message: 'Choose an asset',
|
|
34
|
+
source: (_, input) => actions.filter((r) => !input || r.name.includes(input)).map((r) => r),
|
|
35
|
+
},
|
|
36
|
+
]);
|
|
37
|
+
return answers.name;
|
|
38
|
+
}
|
|
39
|
+
exports.chooseAsset = chooseAsset;
|
|
24
40
|
exports.connectorCategories = [
|
|
25
41
|
'Investigation',
|
|
26
42
|
'Endpoint Security & Management',
|
package/lib/common.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"common.js","sourceRoot":"","sources":["../src/common.ts"],"names":[],"mappings":";;;;AAAA,gEAA+B;AAC/B,wGAA6D;AAC7D,
|
|
1
|
+
{"version":3,"file":"common.js","sourceRoot":"","sources":["../src/common.ts"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C,IAAI,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAA;IAEzF,MAAM,OAAO,GAAG,MAAM,kBAAQ,CAAC,MAAM,CAAC;QACpC;YACE,IAAI,EAAE,cAAc;YACpB,IAAI,EAAE,MAAM;YACZ,OAAO,EAAE,iBAAiB;YAC1B,MAAM,EAAE,CAAC,CAAU,EAAE,KAAa,EAAE,EAAE,CACpC,OAAO,CAAC,MAAM,CAAC,CAAC,CAAwB,EAAE,EAAE,CAAC,CAAC,KAAK,IAAI,CAAC,CAAC,IAAI,CAAC,QAAQ,CAAC,KAAK,CAAC,CAAC,CAAC,GAAG,CAAC,CAAC,CAAyB,EAAE,EAAE,CAAC,CAAC,CAAC;SACvH;KACF,CAAC,CAAA;IAEF,OAAO,OAAO,CAAC,IAAI,CAAA;AACrB,CAAC;AAjBD,kCAiBC;AAEY,QAAA,mBAAmB,GAAG;IACjC,eAAe;IACf,gCAAgC;IAChC,+BAA+B;IAC/B,eAAe;IACf,uBAAuB;IACvB,8BAA8B;IAC9B,kCAAkC;IAClC,mBAAmB;IACnB,+BAA+B;IAC/B,8BAA8B;IAC9B,gBAAgB;IAChB,eAAe;CAChB,CAAA;AAEY,QAAA,kBAAkB,GAAG;IAChC,uBAAuB;IACvB,SAAS;IACT,qBAAqB;CACtB,CAAA"}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
schema: asset/1
|
|
2
|
-
name:
|
|
2
|
+
name: http_bearer
|
|
3
3
|
title: HTTP Bearer Authentication
|
|
4
4
|
description: 'Authenticates using bearer token such as a JWT, etc.'
|
|
5
5
|
inputs:
|
|
@@ -28,7 +28,6 @@ inputs:
|
|
|
28
28
|
- username
|
|
29
29
|
- password
|
|
30
30
|
meta:
|
|
31
|
-
asset_url_key: url
|
|
32
31
|
security:
|
|
33
32
|
type: http
|
|
34
33
|
scheme: bearer
|
|
@@ -0,0 +1,59 @@
|
|
|
1
|
+
schema: asset/1
|
|
2
|
+
name: oauth2_password
|
|
3
|
+
title: Oauth 2.0 Password Grant
|
|
4
|
+
description: 'Authenticates using oauth 2.0 client credentials'
|
|
5
|
+
inputs:
|
|
6
|
+
type: object
|
|
7
|
+
properties:
|
|
8
|
+
url:
|
|
9
|
+
title: URL
|
|
10
|
+
description: A URL to the target host.
|
|
11
|
+
type: string
|
|
12
|
+
default: https://www.example.com # change if it has a default cloud URL or remove if always custom.
|
|
13
|
+
token_url:
|
|
14
|
+
title: Token URL
|
|
15
|
+
type: string
|
|
16
|
+
default: https://www.example.com/oauth/token # remove if this is static. Graph API requires tenant ID and would need the user input.
|
|
17
|
+
oauth2_username:
|
|
18
|
+
title: OAuth2 Username
|
|
19
|
+
description: The username for authentication
|
|
20
|
+
type: string
|
|
21
|
+
oauth2_password:
|
|
22
|
+
title: OAuth2 Password
|
|
23
|
+
description: The password for authentication
|
|
24
|
+
type: string
|
|
25
|
+
format: password
|
|
26
|
+
client_id:
|
|
27
|
+
title: Client ID
|
|
28
|
+
description: The client ID
|
|
29
|
+
type: string
|
|
30
|
+
client_secret:
|
|
31
|
+
title: Client Secret
|
|
32
|
+
description: The client secret.
|
|
33
|
+
type: string
|
|
34
|
+
format: password
|
|
35
|
+
scope:
|
|
36
|
+
title: Scopes
|
|
37
|
+
description: Permission scopes for this action.
|
|
38
|
+
type: array
|
|
39
|
+
items:
|
|
40
|
+
type: string
|
|
41
|
+
default: [] # Add array of scopes we think are needed for the action.
|
|
42
|
+
verify_ssl:
|
|
43
|
+
title: Verify SSL Certificates
|
|
44
|
+
description: Verify SSL certificate
|
|
45
|
+
type: boolean
|
|
46
|
+
http_proxy:
|
|
47
|
+
title: HTTP(s) Proxy
|
|
48
|
+
description: A proxy to route requests through.
|
|
49
|
+
type: string
|
|
50
|
+
required:
|
|
51
|
+
- url
|
|
52
|
+
- oauth2_username
|
|
53
|
+
- oauth2_password
|
|
54
|
+
- token_url
|
|
55
|
+
meta:
|
|
56
|
+
security:
|
|
57
|
+
token_endpoint: "api/oauth2/token"
|
|
58
|
+
type: oauth2
|
|
59
|
+
flow: password
|
|
@@ -36,5 +36,5 @@ output: # use the SDK to autogenerate the output schema. This can be 'object' or
|
|
|
36
36
|
properties:
|
|
37
37
|
additionalProperties: true
|
|
38
38
|
meta:
|
|
39
|
-
endpoint: api/v3/turbine # full path to endpoint after host.
|
|
39
|
+
endpoint: turbine-api/v3/turbine # full path to endpoint after host.
|
|
40
40
|
method: GET
|
package/oclif.manifest.json
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":"2.0.1-next.47+7fbdb67","commands":{"action:add":{"id":"action:add","description":"Update a connector action.","strict":true,"pluginName":"@sw-tsdk/plugin-connector","pluginAlias":"@sw-tsdk/plugin-connector","pluginType":"core","aliases":[],"flags":{"directory":{"name":"directory","type":"option","char":"d","description":"Root directory of the repository.","multiple":false,"default":"./"},"template":{"name":"template","type":"option","char":"t","description":"action template to scaffold","multiple":false,"options":["node_18","python_310_definition","python_3.7_swimlane"],"default":"python_310_definition"},"help":{"name":"help","type":"boolean","char":"h","description":"Show CLI help.","allowNo":false}},"args":[]},"action:input":{"id":"action:input","description":"Update action input schema.","strict":true,"pluginName":"@sw-tsdk/plugin-connector","pluginAlias":"@sw-tsdk/plugin-connector","pluginType":"core","aliases":[],"flags":{"action":{"name":"action","type":"option","char":"a","description":"Action name to run","multiple":false},"directory":{"name":"directory","type":"option","char":"d","description":"Root directory of the repository.","multiple":false,"default":"./"},"amend":{"name":"amend","type":"boolean","description":"Merge with existing schema.","allowNo":false},"action-config-path":{"name":"action-config-path","type":"option","description":"Override path to action configuration file. Defaults to /connector/config/actions/<action>.yaml","multiple":false},"input-path":{"name":"input-path","type":"option","description":"Relative path to the output data JSON file, defaults to the task name under the data folder. ie: /data/<taskName>_output.json","multiple":false,"dependsOn":["update-output-schema"]},"help":{"name":"help","type":"boolean","char":"h","description":"Show CLI help.","allowNo":false}},"args":[]},"action:output":{"id":"action:output","description":"Update a connector action.","strict":true,"pluginName":"@sw-tsdk/plugin-connector","pluginAlias":"@sw-tsdk/plugin-connector","pluginType":"core","aliases":[],"flags":{"action":{"name":"action","type":"option","char":"a","description":"Action name to run","multiple":false},"directory":{"name":"directory","type":"option","char":"d","description":"Root directory of the repository.","multiple":false,"default":"./"},"action-config-path":{"name":"action-config-path","type":"option","description":"Override path to action configuration file. Defaults to /connector/config/<action>.yaml","multiple":false},"amend":{"name":"amend","type":"boolean","description":"Merge with existing schema.","allowNo":false},"output-path":{"name":"output-path","type":"option","description":"Relative path to the output data JSON file, defaults to the task name under the data folder. ie: /data/<taskName>_output.json","multiple":false,"dependsOn":["update-output-schema"]},"help":{"name":"help","type":"boolean","char":"h","description":"Show CLI help.","allowNo":false}},"args":[]},"asset:add":{"id":"asset:add","description":"Update a connector action.","strict":true,"pluginName":"@sw-tsdk/plugin-connector","pluginAlias":"@sw-tsdk/plugin-connector","pluginType":"core","aliases":[],"flags":{"directory":{"name":"directory","type":"option","char":"d","description":"Root directory of the repository.","multiple":false,"default":"./"},"scheme":{"name":"scheme","type":"option","char":"s","description":"asset template to scaffold","multiple":false,"options":["custom","apikey","client_credentials","basic","bearer"]},"help":{"name":"help","type":"boolean","char":"h","description":"Show CLI help.","allowNo":false}},"args":[]},"connector:build":{"id":"connector:build","description":"Builds a local docker image of the connector.","strict":true,"pluginName":"@sw-tsdk/plugin-connector","pluginAlias":"@sw-tsdk/plugin-connector","pluginType":"core","aliases":[],"flags":{"template":{"name":"template","type":"option","description":"connector language","required":true,"multiple":false,"options":["python_3.7_swimlane","node_18","python_310_definition"],"default":"python_310_definition"},"compile-override":{"name":"compile-override","type":"option","hidden":true,"multiple":false,"default":"Compile.Dockerfile"},"runner-override":{"name":"runner-override","type":"option","hidden":true,"multiple":false,"default":"Runner.Dockerfile"},"runtime-override":{"name":"runtime-override","type":"option","hidden":true,"multiple":false},"directory":{"name":"directory","type":"option","char":"d","description":"root directory of the repository.","multiple":false,"default":"./"},"save":{"name":"save","type":"boolean","description":"saves a signed docker image as tar in local directory.","allowNo":false},"squash":{"name":"squash","type":"boolean","description":"squashes the docker layers.","hidden":true,"allowNo":false},"force-rebuild":{"name":"force-rebuild","type":"boolean","char":"f","description":"forces nocache on the image build","allowNo":false},"platform":{"name":"platform","type":"option","hidden":true,"multiple":false,"default":"linux/amd64"},"signing-password":{"name":"signing-password","type":"option","description":"password used for the private key","multiple":false,"default":""},"key-name":{"name":"key-name","type":"option","description":"name used for the key (default: username)","multiple":false},"skip-upload":{"name":"skip-upload","type":"boolean","hidden":true,"allowNo":false},"registry":{"name":"registry","type":"option","description":"registry to use for signing","multiple":false,"default":"localhost:5000"},"help":{"name":"help","type":"boolean","char":"h","description":"Show CLI help.","allowNo":false}},"args":[]},"connector:create-source":{"id":"connector:create-source","description":"Generates 11x source from 10x","strict":true,"pluginName":"@sw-tsdk/plugin-connector","pluginAlias":"@sw-tsdk/plugin-connector","pluginType":"core","aliases":[],"flags":{"directory":{"name":"directory","type":"option","char":"d","description":"root directory of the repository.","multiple":false,"default":"./"},"help":{"name":"help","type":"boolean","char":"h","description":"Show CLI help.","allowNo":false}},"args":[]},"connector:create":{"id":"connector:create","description":"Scaffold a new connector","strict":true,"pluginName":"@sw-tsdk/plugin-connector","pluginAlias":"@sw-tsdk/plugin-connector","pluginType":"core","aliases":[],"flags":{"directory":{"name":"directory","type":"option","char":"d","description":"root directory for where to store connectors, the connector directory will be generated.","multiple":false,"default":"./"},"template":{"name":"template","type":"option","char":"t","description":"connector template to scaffold","multiple":false,"options":["node_18","python_310_definition","python_3.7_swimlane"],"default":"python_310_definition"},"skip-repo":{"name":"skip-repo","type":"boolean","description":"skips the repository creation process","allowNo":false},"clientId":{"name":"clientId","type":"option","char":"c","description":"client id of the authentication app","hidden":true,"multiple":false,"default":"0d418a5615c458b0b593"},"vendor":{"name":"vendor","type":"option","description":"Vendor (e.g. CrowdStrike)","multiple":false},"product":{"name":"product","type":"option","description":"Product (e.g. Falcon)","multiple":false},"keywords":{"name":"keywords","type":"option","description":"Please enter keyword (Comma-Separated)","multiple":false},"description":{"name":"description","type":"option","description":"Description (e.g. CrowdStrike Host Query API)","multiple":false},"logoPath":{"name":"logoPath","type":"option","description":"URL or absolute path to logo file","multiple":false},"author":{"name":"author","type":"option","description":"Connector Author","multiple":false},"authorEmail":{"name":"authorEmail","type":"option","description":"Connector Author Email","multiple":false},"homepage":{"name":"homepage","type":"option","description":"Connector Author Support URL","multiple":false},"repo-base-template":{"name":"repo-base-template","type":"option","char":"t","description":"github base template override to create repo from.","hidden":true,"multiple":false,"default":"connector-python-definition-template"},"help":{"name":"help","type":"boolean","char":"h","description":"Show CLI help.","allowNo":false}},"args":[]},"connector:logo":{"id":"connector:logo","description":"Update a connector.","strict":true,"pluginName":"@sw-tsdk/plugin-connector","pluginAlias":"@sw-tsdk/plugin-connector","pluginType":"core","aliases":[],"flags":{"directory":{"name":"directory","type":"option","char":"d","description":"root directory of the connector folder.","multiple":false,"default":"."},"path":{"name":"path","type":"option","char":"p","description":"path or URL to product logo in PNG format.","required":true,"multiple":false},"help":{"name":"help","type":"boolean","char":"h","description":"Show CLI help.","allowNo":false}},"args":[]},"connector:save":{"id":"connector:save","description":"Save a docker image locally as .tar.gz","strict":true,"pluginName":"@sw-tsdk/plugin-connector","pluginAlias":"@sw-tsdk/plugin-connector","pluginType":"core","aliases":[],"flags":{"directory":{"name":"directory","type":"option","char":"d","description":"Root directory of the repo.","multiple":false,"default":"."},"output":{"name":"output","type":"option","char":"o","description":"output file to where to store the image.","required":true,"multiple":false},"image":{"name":"image","type":"option","char":"i","description":"image to save.","required":true,"multiple":false},"skip-pull":{"name":"skip-pull","type":"boolean","char":"s","description":"skips pulling the image","allowNo":false},"help":{"name":"help","type":"boolean","char":"h","description":"Show CLI help.","allowNo":false}},"args":[]},"connector:sign":{"id":"connector:sign","description":"Builds a local docker image of the connector.","strict":true,"pluginName":"@sw-tsdk/plugin-connector","pluginAlias":"@sw-tsdk/plugin-connector","pluginType":"core","aliases":[],"flags":{"directory":{"name":"directory","type":"option","char":"d","description":"root directory of the repository.","multiple":false,"default":"./"},"image":{"name":"image","type":"option","description":"image name to sign","required":true,"multiple":false},"signing-password":{"name":"signing-password","type":"option","description":"password used for the private key","multiple":false,"default":""},"save":{"name":"save","type":"boolean","description":"saves docker image as tar in local directory.","allowNo":false},"key-name":{"name":"key-name","type":"option","description":"name used for the key (default: username)","required":true,"multiple":false},"skip-upload":{"name":"skip-upload","type":"boolean","hidden":true,"allowNo":false},"registry":{"name":"registry","type":"option","description":"registry to use for signing","multiple":false,"default":"localhost:5000"},"help":{"name":"help","type":"boolean","char":"h","description":"Show CLI help.","allowNo":false}},"args":[]},"connector:update":{"id":"connector:update","description":"Update a connector.","strict":true,"pluginName":"@sw-tsdk/plugin-connector","pluginAlias":"@sw-tsdk/plugin-connector","pluginType":"core","aliases":[],"flags":{"directory":{"name":"directory","type":"option","char":"d","description":"root directory of the connector folder.","multiple":false,"default":"."},"version":{"name":"version","type":"option","char":"v","description":"new version of the connector.","multiple":false},"manifest-path":{"name":"manifest-path","type":"option","char":"f","description":"connector manifest path relative to directory.","multiple":false,"default":"/connector/connector.yaml"},"help":{"name":"help","type":"boolean","char":"h","description":"Show CLI help.","allowNo":false}},"args":[]},"connector:validate":{"id":"connector:validate","description":"Use to validate an integration","strict":true,"pluginName":"@sw-tsdk/plugin-connector","pluginAlias":"@sw-tsdk/plugin-connector","pluginType":"core","aliases":[],"flags":{"help":{"name":"help","type":"boolean","char":"h","description":"Show CLI help.","allowNo":false},"image":{"name":"image","type":"option","char":"i","description":"image to use","multiple":false},"connector":{"name":"connector","type":"option","char":"c","description":"connector to validate (relative to directory)","required":true,"multiple":false,"default":"connector"},"signed":{"name":"signed","type":"boolean","description":"validates a signed connector","allowNo":false},"key":{"name":"key","type":"option","description":"public key for verfication","multiple":false,"dependsOn":["signed"],"exclusive":["skip-verification"]},"skip-pull":{"name":"skip-pull","type":"boolean","char":"s","description":"skips pulling the image","allowNo":false},"directory":{"name":"directory","type":"option","char":"d","description":"current directory to mount","multiple":false,"default":"./"}},"args":[]},"action:generate:data":{"id":"action:generate:data","description":"Use to test a task in an integration","strict":true,"pluginName":"@sw-tsdk/plugin-connector","pluginAlias":"@sw-tsdk/plugin-connector","pluginType":"core","aliases":[],"flags":{"help":{"name":"help","type":"boolean","char":"h","description":"Show CLI help.","allowNo":false},"name":{"name":"name","type":"option","char":"n","description":"task name to run","multiple":false},"asset":{"name":"asset","type":"option","description":"asset json","required":true,"multiple":false,"default":"data/asset.json"},"inputs":{"name":"inputs","type":"option","description":"Filename for JSON inputs, defaults to the task name under the data folder. ie: data/my_task.json","multiple":false},"directory":{"name":"directory","type":"option","char":"d","description":"current directory to mount","multiple":false,"default":"./"}},"args":[]},"action:run:image":{"id":"action:run:image","description":"Runs a connector action. (Defaults to current image version in local repository).","strict":true,"pluginName":"@sw-tsdk/plugin-connector","pluginAlias":"@sw-tsdk/plugin-connector","pluginType":"core","hidden":true,"aliases":[],"flags":{"action":{"name":"action","type":"option","char":"a","description":"Action name to run","required":true,"multiple":false},"directory":{"name":"directory","type":"option","char":"d","description":"Root directory of the repository.","multiple":false,"default":"./"},"input-path":{"name":"input-path","type":"option","description":"File to input data JSON file, defaults to /data/<action>.json","multiple":false},"output-path":{"name":"output-path","type":"option","description":"File to write the outputs to, defaults to /data/<action>_output.json","multiple":false},"error-path":{"name":"error-path","type":"option","description":"File to write the errors to, defaults to /data/<action>_error.json","multiple":false},"asset-path":{"name":"asset-path","type":"option","description":"File to asset data JSON file, defaults to /data/asset.json","multiple":false},"repository":{"name":"repository","type":"option","char":"r","description":"The connector image repository to run.","multiple":false},"version":{"name":"version","type":"option","description":"Use the latest release image from quay.","multiple":false,"default":"latest"},"platform":{"name":"platform","type":"option","hidden":true,"multiple":false,"default":"linux/amd64"},"help":{"name":"help","type":"boolean","char":"h","description":"Show CLI help.","allowNo":false}},"args":[]},"action:run:local":{"id":"action:run:local","description":"Runs a connector action. (Defaults to current image version in local repository).","strict":true,"pluginName":"@sw-tsdk/plugin-connector","pluginAlias":"@sw-tsdk/plugin-connector","pluginType":"core","aliases":[],"flags":{"action":{"name":"action","type":"option","char":"a","description":"Action name to run","multiple":false},"directory":{"name":"directory","type":"option","char":"d","description":"Root directory of the repository.","multiple":false,"default":"./"},"input-path":{"name":"input-path","type":"option","description":"File to input data JSON file, defaults to /data/<action>.json","multiple":false},"output-path":{"name":"output-path","type":"option","description":"File to write the outputs to, defaults to /data/<action>_output.json","multiple":false},"error-path":{"name":"error-path","type":"option","description":"File to write the errors to, defaults to /data/<action>_error.json","multiple":false},"asset-path":{"name":"asset-path","type":"option","description":"File to asset data JSON file, defaults to /data/asset.json","multiple":false},"template":{"name":"template","type":"option","description":"connector template","multiple":false,"options":["python_3.7_swimlane","node_18","python_310_definition"],"default":"python_310_definition"},"compile-override":{"name":"compile-override","type":"option","hidden":true,"multiple":false,"default":"Compile.Dockerfile"},"runner-override":{"name":"runner-override","type":"option","hidden":true,"multiple":false,"default":"Runner.Dockerfile"},"runtime-override":{"name":"runtime-override","type":"option","hidden":true,"multiple":false},"force-rebuild":{"name":"force-rebuild","type":"boolean","char":"f","description":"forces nocache on the image build","allowNo":false},"platform":{"name":"platform","type":"option","hidden":true,"multiple":false,"default":"linux/amd64"},"help":{"name":"help","type":"boolean","char":"h","description":"Show CLI help.","allowNo":false}},"args":[]}}}
|
|
1
|
+
{"version":"2.0.1-next.68+0b70370","commands":{"action:add":{"id":"action:add","description":"Update a connector action.","strict":true,"pluginName":"@sw-tsdk/plugin-connector","pluginAlias":"@sw-tsdk/plugin-connector","pluginType":"core","aliases":[],"flags":{"directory":{"name":"directory","type":"option","char":"d","description":"Root directory of the repository.","multiple":false,"default":"./"},"template":{"name":"template","type":"option","char":"t","description":"action template to scaffold","multiple":false,"options":["node_18","python_310_definition","python_3.7_swimlane"],"default":"python_310_definition"},"help":{"name":"help","type":"boolean","char":"h","description":"Show CLI help.","allowNo":false}},"args":[]},"asset:add":{"id":"asset:add","description":"Update a connector action.","strict":true,"pluginName":"@sw-tsdk/plugin-connector","pluginAlias":"@sw-tsdk/plugin-connector","pluginType":"core","aliases":[],"flags":{"directory":{"name":"directory","type":"option","char":"d","description":"Root directory of the repository.","multiple":false,"default":"./"},"scheme":{"name":"scheme","type":"option","char":"s","description":"asset template to scaffold","multiple":false,"options":["custom","apikey","oauth2_client_credentials","http_basic","http_bearer"]},"help":{"name":"help","type":"boolean","char":"h","description":"Show CLI help.","allowNo":false}},"args":[]},"connector:build":{"id":"connector:build","description":"Builds a local docker image of the connector.","strict":true,"pluginName":"@sw-tsdk/plugin-connector","pluginAlias":"@sw-tsdk/plugin-connector","pluginType":"core","aliases":[],"flags":{"template":{"name":"template","type":"option","description":"connector language","required":true,"multiple":false,"options":["python_3.7_swimlane","node_18","python_310_definition"],"default":"python_310_definition"},"compile-override":{"name":"compile-override","type":"option","hidden":true,"multiple":false,"default":"Compile.Dockerfile"},"runner-override":{"name":"runner-override","type":"option","hidden":true,"multiple":false,"default":"Runner.Dockerfile"},"runtime-override":{"name":"runtime-override","type":"option","hidden":true,"multiple":false},"directory":{"name":"directory","type":"option","char":"d","description":"root directory of the repository.","multiple":false,"default":"./"},"save":{"name":"save","type":"boolean","description":"saves a signed docker image as tar in local directory.","allowNo":false,"relationships":[{"type":"all","flags":["signing-password","key-name"]},{"type":"some","flags":["registry"]}]},"squash":{"name":"squash","type":"boolean","description":"squashes the docker layers.","hidden":true,"allowNo":false},"force-rebuild":{"name":"force-rebuild","type":"boolean","char":"f","description":"forces nocache on the image build","allowNo":false},"platform":{"name":"platform","type":"option","hidden":true,"multiple":false,"default":"linux/amd64"},"signing-password":{"name":"signing-password","type":"option","description":"password used for the private key","multiple":false,"default":""},"key-name":{"name":"key-name","type":"option","description":"name used for the key (default: username)","multiple":false},"skip-upload":{"name":"skip-upload","type":"boolean","hidden":true,"allowNo":false},"registry":{"name":"registry","type":"option","description":"registry to use for signing","multiple":false,"default":"localhost:5000"},"help":{"name":"help","type":"boolean","char":"h","description":"Show CLI help.","allowNo":false}},"args":[]},"connector:create-source":{"id":"connector:create-source","description":"Generates 11x source from 10x","strict":true,"pluginName":"@sw-tsdk/plugin-connector","pluginAlias":"@sw-tsdk/plugin-connector","pluginType":"core","aliases":[],"flags":{"directory":{"name":"directory","type":"option","char":"d","description":"root directory of the repository.","multiple":false,"default":"./"},"help":{"name":"help","type":"boolean","char":"h","description":"Show CLI help.","allowNo":false}},"args":[]},"connector:create":{"id":"connector:create","description":"Scaffold a new connector","strict":true,"pluginName":"@sw-tsdk/plugin-connector","pluginAlias":"@sw-tsdk/plugin-connector","pluginType":"core","aliases":[],"flags":{"directory":{"name":"directory","type":"option","char":"d","description":"root directory for where to store connectors, the connector directory will be generated.","multiple":false,"default":"./"},"template":{"name":"template","type":"option","char":"t","description":"connector template to scaffold","multiple":false,"options":["node_18","python_310_definition","python_3.7_swimlane"],"default":"python_310_definition"},"skip-repo":{"name":"skip-repo","type":"boolean","description":"skips the repository creation process","allowNo":false},"clientId":{"name":"clientId","type":"option","char":"c","description":"client id of the authentication app","hidden":true,"multiple":false,"default":"0d418a5615c458b0b593"},"vendor":{"name":"vendor","type":"option","description":"Vendor (e.g. CrowdStrike)","multiple":false},"product":{"name":"product","type":"option","description":"Product (e.g. Falcon)","multiple":false},"keywords":{"name":"keywords","type":"option","description":"Enter keyword (Comma-Separated)","multiple":false},"description":{"name":"description","type":"option","description":"Description (e.g. CrowdStrike Host Query API)","multiple":false},"logoPath":{"name":"logoPath","type":"option","description":"URL or absolute path to logo file","multiple":false},"author":{"name":"author","type":"option","description":"Connector Author","multiple":false},"authorEmail":{"name":"authorEmail","type":"option","description":"Connector Author Email","multiple":false},"homepage":{"name":"homepage","type":"option","description":"Connector Author Support URL","multiple":false},"repo-base-template":{"name":"repo-base-template","type":"option","char":"t","description":"github base template override to create repo from.","hidden":true,"multiple":false,"default":"connector-python-definition-template"},"help":{"name":"help","type":"boolean","char":"h","description":"Show CLI help.","allowNo":false}},"args":[]},"connector:logo":{"id":"connector:logo","description":"Update a connector.","strict":true,"pluginName":"@sw-tsdk/plugin-connector","pluginAlias":"@sw-tsdk/plugin-connector","pluginType":"core","aliases":[],"flags":{"directory":{"name":"directory","type":"option","char":"d","description":"root directory of the connector folder.","multiple":false,"default":"."},"path":{"name":"path","type":"option","char":"p","description":"path or URL to product logo in PNG format.","required":true,"multiple":false},"help":{"name":"help","type":"boolean","char":"h","description":"Show CLI help.","allowNo":false}},"args":[]},"connector:save":{"id":"connector:save","description":"Save a docker image locally as .tar.gz","strict":true,"pluginName":"@sw-tsdk/plugin-connector","pluginAlias":"@sw-tsdk/plugin-connector","pluginType":"core","aliases":[],"flags":{"directory":{"name":"directory","type":"option","char":"d","description":"Root directory of the repo.","multiple":false,"default":"."},"output":{"name":"output","type":"option","char":"o","description":"output file to where to store the image.","required":true,"multiple":false},"image":{"name":"image","type":"option","char":"i","description":"image to save.","required":true,"multiple":false},"skip-pull":{"name":"skip-pull","type":"boolean","char":"s","description":"skips pulling the image","allowNo":false},"help":{"name":"help","type":"boolean","char":"h","description":"Show CLI help.","allowNo":false}},"args":[]},"connector:sign":{"id":"connector:sign","description":"Builds a local docker image of the connector.","strict":true,"pluginName":"@sw-tsdk/plugin-connector","pluginAlias":"@sw-tsdk/plugin-connector","pluginType":"core","aliases":[],"flags":{"directory":{"name":"directory","type":"option","char":"d","description":"root directory of the repository.","multiple":false,"default":"./"},"image":{"name":"image","type":"option","description":"image name to sign","required":true,"multiple":false},"signing-password":{"name":"signing-password","type":"option","description":"password used for the private key","multiple":false,"default":""},"save":{"name":"save","type":"boolean","description":"saves docker image as tar in local directory.","allowNo":false},"key-name":{"name":"key-name","type":"option","description":"name used for the key (default: username)","required":true,"multiple":false},"skip-upload":{"name":"skip-upload","type":"boolean","hidden":true,"allowNo":false},"registry":{"name":"registry","type":"option","description":"registry to use for signing","multiple":false,"default":"localhost:5000"},"help":{"name":"help","type":"boolean","char":"h","description":"Show CLI help.","allowNo":false}},"args":[]},"connector:update":{"id":"connector:update","description":"Update a connector.","strict":true,"pluginName":"@sw-tsdk/plugin-connector","pluginAlias":"@sw-tsdk/plugin-connector","pluginType":"core","aliases":[],"flags":{"directory":{"name":"directory","type":"option","char":"d","description":"root directory of the connector folder.","multiple":false,"default":"."},"version":{"name":"version","type":"option","char":"v","description":"new version of the connector.","multiple":false},"manifest-path":{"name":"manifest-path","type":"option","char":"f","description":"connector manifest path relative to directory.","multiple":false,"default":"/connector/connector.yaml"},"help":{"name":"help","type":"boolean","char":"h","description":"Show CLI help.","allowNo":false}},"args":[]},"connector:validate":{"id":"connector:validate","description":"Use to validate an integration","strict":true,"pluginName":"@sw-tsdk/plugin-connector","pluginAlias":"@sw-tsdk/plugin-connector","pluginType":"core","aliases":[],"flags":{"help":{"name":"help","type":"boolean","char":"h","description":"Show CLI help.","allowNo":false},"image":{"name":"image","type":"option","char":"i","description":"image to use","multiple":false},"connector":{"name":"connector","type":"option","char":"c","description":"connector to validate (relative to directory)","required":true,"multiple":false,"default":"connector"},"signed":{"name":"signed","type":"boolean","description":"validates a signed connector","allowNo":false},"key":{"name":"key","type":"option","description":"public key for verfication","multiple":false,"dependsOn":["signed"],"exclusive":["skip-verification"]},"skip-pull":{"name":"skip-pull","type":"boolean","char":"s","description":"skips pulling the image","allowNo":false},"directory":{"name":"directory","type":"option","char":"d","description":"current directory to mount","multiple":false,"default":"./"}},"args":[]},"action:generate:data":{"id":"action:generate:data","description":"Use to test a task in an integration","strict":true,"pluginName":"@sw-tsdk/plugin-connector","pluginAlias":"@sw-tsdk/plugin-connector","pluginType":"core","aliases":[],"flags":{"help":{"name":"help","type":"boolean","char":"h","description":"Show CLI help.","allowNo":false},"action":{"name":"action","type":"option","char":"a","description":"action to generate data","multiple":false},"asset":{"name":"asset","type":"option","description":"Filename for asset, defaults to the task name under the data folder. ie: data/asset_name.json","multiple":false},"inputs":{"name":"inputs","type":"option","description":"Filename for JSON inputs, defaults to the task name under the data folder. ie: data/my_task.json","multiple":false},"directory":{"name":"directory","type":"option","char":"d","description":"current directory to mount","multiple":false,"default":"./"},"include-optional":{"name":"include-optional","type":"boolean","description":"used to only generate required properties","allowNo":false},"force":{"name":"force","type":"boolean","description":"overwrites current files","allowNo":false}},"args":[]},"action:generate:input":{"id":"action:generate:input","description":"Update action input schema.","strict":true,"pluginName":"@sw-tsdk/plugin-connector","pluginAlias":"@sw-tsdk/plugin-connector","pluginType":"core","aliases":[],"flags":{"action":{"name":"action","type":"option","char":"a","description":"Action name to run","multiple":false},"directory":{"name":"directory","type":"option","char":"d","description":"Root directory of the repository.","multiple":false,"default":"./"},"amend":{"name":"amend","type":"boolean","description":"Merge with existing schema.","allowNo":false},"action-config-path":{"name":"action-config-path","type":"option","description":"Override path to action configuration file. Defaults to /connector/config/actions/<action>.yaml","multiple":false},"input-path":{"name":"input-path","type":"option","description":"Relative path to the output data JSON file, defaults to the task name under the data folder. ie: /data/<taskName>_output.json","multiple":false},"help":{"name":"help","type":"boolean","char":"h","description":"Show CLI help.","allowNo":false}},"args":[]},"action:generate:output":{"id":"action:generate:output","description":"Update a connector action.","strict":true,"pluginName":"@sw-tsdk/plugin-connector","pluginAlias":"@sw-tsdk/plugin-connector","pluginType":"core","aliases":[],"flags":{"action":{"name":"action","type":"option","char":"a","description":"Action name to run","multiple":false},"directory":{"name":"directory","type":"option","char":"d","description":"Root directory of the repository.","multiple":false,"default":"./"},"action-config-path":{"name":"action-config-path","type":"option","description":"Override path to action configuration file. Defaults to /connector/config/<action>.yaml","multiple":false},"amend":{"name":"amend","type":"boolean","description":"Merge with existing schema.","allowNo":false},"output-path":{"name":"output-path","type":"option","description":"Relative path to the output data JSON file, defaults to the task name under the data folder. ie: /data/<taskName>_output.json","multiple":false},"help":{"name":"help","type":"boolean","char":"h","description":"Show CLI help.","allowNo":false}},"args":[]},"action:run:image":{"id":"action:run:image","description":"Runs a connector action. (Defaults to current image version in local repository).","strict":true,"pluginName":"@sw-tsdk/plugin-connector","pluginAlias":"@sw-tsdk/plugin-connector","pluginType":"core","hidden":true,"aliases":[],"flags":{"action":{"name":"action","type":"option","char":"a","description":"Action name to run","required":true,"multiple":false},"directory":{"name":"directory","type":"option","char":"d","description":"Root directory of the repository.","multiple":false,"default":"./"},"input-path":{"name":"input-path","type":"option","description":"File to input data JSON file","required":true,"multiple":false},"output-path":{"name":"output-path","type":"option","description":"File to write the outputs to, defaults to /data/<action>_output.json","multiple":false},"error-path":{"name":"error-path","type":"option","description":"File to write the errors to, defaults to /data/<action>_error.json","multiple":false},"asset-path":{"name":"asset-path","type":"option","description":"File to asset data JSON file, defaults to /data/asset.json","multiple":false},"repository":{"name":"repository","type":"option","char":"r","description":"The connector image repository to run.","multiple":false},"version":{"name":"version","type":"option","description":"Use the latest release image from quay.","multiple":false,"default":"latest"},"stdin":{"name":"stdin","type":"boolean","description":"Send the inputs through stdin instead of an environment variable.","allowNo":false},"platform":{"name":"platform","type":"option","hidden":true,"multiple":false,"default":"linux/amd64"},"help":{"name":"help","type":"boolean","char":"h","description":"Show CLI help.","allowNo":false}},"args":[]},"action:run:local":{"id":"action:run:local","description":"Runs a connector action. (Defaults to current image version in local repository).","strict":true,"pluginName":"@sw-tsdk/plugin-connector","pluginAlias":"@sw-tsdk/plugin-connector","pluginType":"core","aliases":[],"flags":{"action":{"name":"action","type":"option","char":"a","description":"Action name to run","multiple":false},"directory":{"name":"directory","type":"option","char":"d","description":"Root directory of the repository.","multiple":false,"default":"./"},"input-path":{"name":"input-path","type":"option","description":"File to input data JSON file, defaults to /data/<action>.json","multiple":false},"output-path":{"name":"output-path","type":"option","description":"File to write the outputs to, defaults to /data/<action>_output.json","multiple":false},"error-path":{"name":"error-path","type":"option","description":"File to write the errors to, defaults to /data/<action>_error.json","multiple":false},"asset-path":{"name":"asset-path","type":"option","description":"File to asset data JSON file, defaults to /data/asset.json","multiple":false},"template":{"name":"template","type":"option","description":"connector template","multiple":false,"options":["python_3.7_swimlane","node_18","python_310_definition"],"default":"python_310_definition"},"compile-override":{"name":"compile-override","type":"option","hidden":true,"multiple":false,"default":"Compile.Dockerfile"},"runner-override":{"name":"runner-override","type":"option","hidden":true,"multiple":false,"default":"Runner.Dockerfile"},"runtime-override":{"name":"runtime-override","type":"option","hidden":true,"multiple":false},"force-rebuild":{"name":"force-rebuild","type":"boolean","char":"f","description":"forces nocache on the image build","allowNo":false},"platform":{"name":"platform","type":"option","hidden":true,"multiple":false,"default":"linux/amd64"},"help":{"name":"help","type":"boolean","char":"h","description":"Show CLI help.","allowNo":false}},"args":[]}}}
|
package/package.json
CHANGED
|
@@ -5,18 +5,19 @@
|
|
|
5
5
|
},
|
|
6
6
|
"dependencies": {
|
|
7
7
|
"@oclif/core": "1.16.4",
|
|
8
|
-
"@sw-tsdk/common": "^2.0.1-next.
|
|
9
|
-
"@sw-tsdk/connector": "^2.0.1-next.
|
|
10
|
-
"@sw-tsdk/core": "^2.0.1-next.
|
|
11
|
-
"@sw-tsdk/docker": "^2.0.1-next.
|
|
12
|
-
"@swimlane/connector-interfaces": "1.8.5-
|
|
8
|
+
"@sw-tsdk/common": "^2.0.1-next.68+0b70370",
|
|
9
|
+
"@sw-tsdk/connector": "^2.0.1-next.68+0b70370",
|
|
10
|
+
"@sw-tsdk/core": "^2.0.1-next.68+0b70370",
|
|
11
|
+
"@sw-tsdk/docker": "^2.0.1-next.68+0b70370",
|
|
12
|
+
"@swimlane/connector-interfaces": "1.8.5-rc5",
|
|
13
13
|
"@swimlane/cosign": "1.3.1",
|
|
14
|
-
"@swimlane/docker-reference": "0.0
|
|
14
|
+
"@swimlane/docker-reference": "2.0.0",
|
|
15
15
|
"fs-extra": "10.0.1",
|
|
16
16
|
"handlebars": "4.7.7",
|
|
17
17
|
"inquirer": "8.2.2",
|
|
18
18
|
"inquirer-autocomplete-prompt": "2.0.0",
|
|
19
19
|
"js-yaml": "4.1.0",
|
|
20
|
+
"json-schema-faker": "0.5.0-rcv.46",
|
|
20
21
|
"json-schema-typed": "7.0.3",
|
|
21
22
|
"listr2": "4.0.5",
|
|
22
23
|
"noop-stream": "1.0.0",
|
|
@@ -77,16 +78,16 @@
|
|
|
77
78
|
},
|
|
78
79
|
"scripts": {
|
|
79
80
|
"build": "rm -rf lib && tsc && yarn copy-files",
|
|
81
|
+
"postbuild": "oclif manifest && yarn docs",
|
|
80
82
|
"lint": "eslint . --ext .ts --config .eslintrc",
|
|
81
83
|
"copy-files": "recursive-copy **/templates/ lib/templates",
|
|
82
|
-
"pretest": "tsc -p test --noEmit",
|
|
83
84
|
"postpack": "shx rm -f oclif.manifest.json",
|
|
84
85
|
"prepack": "yarn build && oclif manifest && oclif readme",
|
|
85
|
-
"
|
|
86
|
-
"test": "
|
|
86
|
+
"docs": "oclif readme",
|
|
87
|
+
"test": "jest --passWithNoTests",
|
|
87
88
|
"posttest": "yarn lint",
|
|
88
89
|
"dev:setup": "npm link"
|
|
89
90
|
},
|
|
90
|
-
"version": "2.0.1-next.
|
|
91
|
-
"gitHead": "
|
|
91
|
+
"version": "2.0.1-next.68+0b70370",
|
|
92
|
+
"gitHead": "0b70370ed4e350fbe09ed4b97947ebdfefba6f3e"
|
|
92
93
|
}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"input.js","sourceRoot":"","sources":["../../../src/commands/action/input.ts"],"names":[],"mappings":";;;;AAAA,sCAAwC;AACxC,wCAAkC;AAClC,yCAAuC;AACvC,uCAAgE;AAChE,wEAAkC;AAClC,8DAA0B;AAK1B,kDAAiE;AACjE,yCAAyC;AAEzC,qCAAqC;AACrC,MAAa,KAAM,SAAQ,WAAI;IA6B7B,KAAK,CAAC,GAAG;QACP,MAAM,EACJ,KAAK,GACN,GAAG,MAAM,IAAI,CAAC,KAAK,CAAC,KAAK,CAAC,CAAA;QAE3B,IAAI,EACF,SAAS,EACT,YAAY,EAAE,SAAS,EACvB,oBAAoB,EAAE,gBAAgB,EACtC,MAAM,GACP,GAAG,KAAK,CAAA;QAET,MAAM,EACJ,KAAK,GACN,GAAG,KAAK,CAAA;QAET,SAAS,GAAG,IAAA,mBAAO,EAAC,SAAS,IAAI,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