@sectester/repeater 0.22.0 → 0.23.1

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 CHANGED
@@ -48,11 +48,13 @@ const repeater = await repeaterFactory.createRepeater({
48
48
 
49
49
  The `createRepeater` method accepts the options described below:
50
50
 
51
- | Option | Description |
52
- | :--------------------- | ----------------------------------------------------------------------------------------------------- |
53
- | `namePrefix` | Enter a name prefix that will be used as a constant part of the unique name. By default, `sectester`. |
54
- | `description` | Set a short description of the Repeater. |
55
- | `requestRunnerOptions` | Custom the request runner settings that will be used to execute requests to your application. |
51
+ | Option | Description |
52
+ | :---------------------------- | ----------------------------------------------------------------------------------------------------- |
53
+ | `namePrefix` | Enter a name prefix that will be used as a constant part of the unique name. By default, `sectester`. |
54
+ | `description` | Set a short description of the Repeater. |
55
+ | `requestRunnerOptions` | Custom the request runner settings that will be used to execute requests to your application. |
56
+ | `projectId` | Specify the project ID to associate the Repeater with. |
57
+ | `disableRandomNameGeneration` | Disable random name generation for the Repeater's name. |
56
58
 
57
59
  The default `requestRunnerOptions` is as follows:
58
60
 
@@ -93,6 +95,33 @@ export interface RequestRunnerOptions {
93
95
  }
94
96
  ```
95
97
 
98
+ The `RepeaterFactory` also provides a method to create a `Repeater` instance using an existing repeater ID. You can use the `createRepeaterFromExisting` method to accomplish this:
99
+
100
+ ```ts
101
+ const existingRepeaterId = '<your repater ID>';
102
+ const repeater = await repeaterFactory.createRepeaterFromExisting(
103
+ existingRepeaterId
104
+ );
105
+ ```
106
+
107
+ This method retrieves the existing repeater's details from the cloud using its ID and returns a `Repeater` instance associated with the specified ID.
108
+
109
+ You can also customize the request runner options for the existing repeater by passing them as options:
110
+
111
+ ```ts
112
+ const existingRepeaterId = '<your repater ID>';
113
+ const repeater = await repeaterFactory.createRepeaterFromExisting(
114
+ existingRepeaterId,
115
+ {
116
+ requestRunnerOptions: {
117
+ timeout: 10000,
118
+ maxContentLength: 200,
119
+ allowedMimes: ['text/html']
120
+ }
121
+ }
122
+ );
123
+ ```
124
+
96
125
  The `Repeater` instance provides the `start` method. This method is required to establish a connection with the Bright cloud engine and interact with other services.
97
126
 
98
127
  ```ts
@@ -164,7 +193,7 @@ container.register(RequestRunner, {
164
193
  ## Limitations
165
194
 
166
195
  Custom scripts and self-signed certificates
167
- (see [NexPloit CLI](https://www.npmjs.com/package/@neuralegion/nexploit-cli)) are not supported yet.
196
+ (see [Bright CLI](https://www.npmjs.com/package/@brightsec/cli)) are not supported yet.
168
197
 
169
198
  ## License
170
199
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@sectester/repeater",
3
- "version": "0.22.0",
3
+ "version": "0.23.1",
4
4
  "description": "Package for managing repeaters, which are mandatory for scanning targets on a local network.",
5
5
  "repository": {
6
6
  "type": "git",
@@ -47,9 +47,9 @@
47
47
  "chalk": "^4.1.2",
48
48
  "form-data": "^4.0.0",
49
49
  "axios": "^0.26.1",
50
- "amqp-connection-manager": "^4.1.1",
50
+ "amqp-connection-manager": "^4.1.13",
51
51
  "axios-rate-limit": "^1.3.0",
52
- "amqplib": "^0.8.0",
52
+ "amqplib": "^0.10.3",
53
53
  "semver": "^7.3.7",
54
54
  "socks-proxy-agent": "^6.2.0-beta.0",
55
55
  "content-type": "^1.0.4",
@@ -3,6 +3,9 @@ import { CommandDispatcher } from '@sectester/core';
3
3
  export declare class DefaultRepeatersManager implements RepeatersManager {
4
4
  private readonly commandDispatcher;
5
5
  constructor(commandDispatcher: CommandDispatcher);
6
+ getRepeater(repeaterId: string): Promise<{
7
+ repeaterId: string;
8
+ }>;
6
9
  createRepeater({ projectId, ...options }: {
7
10
  name: string;
8
11
  description?: string;
@@ -9,13 +9,20 @@ let DefaultRepeatersManager = class DefaultRepeatersManager {
9
9
  constructor(commandDispatcher) {
10
10
  this.commandDispatcher = commandDispatcher;
11
11
  }
12
+ async getRepeater(repeaterId) {
13
+ const repeater = await this.commandDispatcher.execute(new commands_1.GetRepeaterRequest(repeaterId));
14
+ if (!(repeater === null || repeater === void 0 ? void 0 : repeater.id)) {
15
+ throw new Error('Cannot find repeater');
16
+ }
17
+ return { repeaterId: repeater.id };
18
+ }
12
19
  async createRepeater({ projectId, ...options }) {
13
20
  const repeater = await this.commandDispatcher.execute(new commands_1.CreateRepeaterRequest({
14
21
  ...options,
15
22
  ...(projectId ? { projectIds: [projectId] } : {})
16
23
  }));
17
24
  if (!(repeater === null || repeater === void 0 ? void 0 : repeater.id)) {
18
- throw new Error('Cannot find created repeater id');
25
+ throw new Error('Cannot create a new repeater.');
19
26
  }
20
27
  return { repeaterId: repeater.id };
21
28
  }
@@ -1 +1 @@
1
- {"version":3,"file":"DefaultRepeatersManager.js","sourceRoot":"","sources":["../../../../../packages/repeater/src/api/DefaultRepeatersManager.ts"],"names":[],"mappings":";;;;AACA,yCAA0E;AAC1E,uCAA8C;AAC9C,0CAAoD;AAGpD,IAAa,uBAAuB,GAApC,MAAa,uBAAuB;IAClC,YAEmB,iBAAoC;QAApC,sBAAiB,GAAjB,iBAAiB,CAAmB;IACpD,CAAC;IAEG,KAAK,CAAC,cAAc,CAAC,EAC1B,SAAS,EACT,GAAG,OAAO,EAKX;QACC,MAAM,QAAQ,GAAG,MAAM,IAAI,CAAC,iBAAiB,CAAC,OAAO,CACnD,IAAI,gCAAqB,CAAC;YACxB,GAAG,OAAO;YACV,GAAG,CAAC,SAAS,CAAC,CAAC,CAAC,EAAE,UAAU,EAAE,CAAC,SAAS,CAAC,EAAE,CAAC,CAAC,CAAC,EAAE,CAAC;SAClD,CAAC,CACH,CAAC;QAEF,IAAI,CAAC,CAAA,QAAQ,aAAR,QAAQ,uBAAR,QAAQ,CAAE,EAAE,CAAA,EAAE;YACjB,MAAM,IAAI,KAAK,CAAC,iCAAiC,CAAC,CAAC;SACpD;QAED,OAAO,EAAE,UAAU,EAAE,QAAQ,CAAC,EAAE,EAAE,CAAC;IACrC,CAAC;IAEM,KAAK,CAAC,cAAc,CAAC,UAAkB;QAC5C,OAAO,IAAI,CAAC,iBAAiB,CAAC,OAAO,CACnC,IAAI,gCAAqB,CAAC,EAAE,UAAU,EAAE,CAAC,CAC1C,CAAC;IACJ,CAAC;CACF,CAAA;AAjCY,uBAAuB;IADnC,IAAA,qBAAU,GAAE;IAGR,mBAAA,IAAA,iBAAM,EAAC,wBAAiB,CAAC,CAAA;;GAFjB,uBAAuB,CAiCnC;AAjCY,0DAAuB"}
1
+ {"version":3,"file":"DefaultRepeatersManager.js","sourceRoot":"","sources":["../../../../../packages/repeater/src/api/DefaultRepeatersManager.ts"],"names":[],"mappings":";;;;AACA,yCAIoB;AACpB,uCAA8C;AAC9C,0CAAoD;AAGpD,IAAa,uBAAuB,GAApC,MAAa,uBAAuB;IAClC,YAEmB,iBAAoC;QAApC,sBAAiB,GAAjB,iBAAiB,CAAmB;IACpD,CAAC;IAEG,KAAK,CAAC,WAAW,CACtB,UAAkB;QAElB,MAAM,QAAQ,GAAG,MAAM,IAAI,CAAC,iBAAiB,CAAC,OAAO,CACnD,IAAI,6BAAkB,CAAC,UAAU,CAAC,CACnC,CAAC;QAEF,IAAI,CAAC,CAAA,QAAQ,aAAR,QAAQ,uBAAR,QAAQ,CAAE,EAAE,CAAA,EAAE;YACjB,MAAM,IAAI,KAAK,CAAC,sBAAsB,CAAC,CAAC;SACzC;QAED,OAAO,EAAE,UAAU,EAAE,QAAQ,CAAC,EAAE,EAAE,CAAC;IACrC,CAAC;IAEM,KAAK,CAAC,cAAc,CAAC,EAC1B,SAAS,EACT,GAAG,OAAO,EAKX;QACC,MAAM,QAAQ,GAAG,MAAM,IAAI,CAAC,iBAAiB,CAAC,OAAO,CACnD,IAAI,gCAAqB,CAAC;YACxB,GAAG,OAAO;YACV,GAAG,CAAC,SAAS,CAAC,CAAC,CAAC,EAAE,UAAU,EAAE,CAAC,SAAS,CAAC,EAAE,CAAC,CAAC,CAAC,EAAE,CAAC;SAClD,CAAC,CACH,CAAC;QAEF,IAAI,CAAC,CAAA,QAAQ,aAAR,QAAQ,uBAAR,QAAQ,CAAE,EAAE,CAAA,EAAE;YACjB,MAAM,IAAI,KAAK,CAAC,+BAA+B,CAAC,CAAC;SAClD;QAED,OAAO,EAAE,UAAU,EAAE,QAAQ,CAAC,EAAE,EAAE,CAAC;IACrC,CAAC;IAEM,KAAK,CAAC,cAAc,CAAC,UAAkB;QAC5C,OAAO,IAAI,CAAC,iBAAiB,CAAC,OAAO,CACnC,IAAI,gCAAqB,CAAC,EAAE,UAAU,EAAE,CAAC,CAC1C,CAAC;IACJ,CAAC;CACF,CAAA;AA/CY,uBAAuB;IADnC,IAAA,qBAAU,GAAE;IAGR,mBAAA,IAAA,iBAAM,EAAC,wBAAiB,CAAC,CAAA;;GAFjB,uBAAuB,CA+CnC;AA/CY,0DAAuB"}
@@ -1,4 +1,7 @@
1
1
  export interface RepeatersManager {
2
+ getRepeater(repeaterId: string): Promise<{
3
+ repeaterId: string;
4
+ }>;
2
5
  createRepeater(options: {
3
6
  name: string;
4
7
  projectId?: string;
@@ -1 +1 @@
1
- {"version":3,"file":"RepeatersManager.js","sourceRoot":"","sources":["../../../../../packages/repeater/src/api/RepeatersManager.ts"],"names":[],"mappings":";;;AAUa,QAAA,gBAAgB,GAAkB,MAAM,CAAC,kBAAkB,CAAC,CAAC"}
1
+ {"version":3,"file":"RepeatersManager.js","sourceRoot":"","sources":["../../../../../packages/repeater/src/api/RepeatersManager.ts"],"names":[],"mappings":";;;AAYa,QAAA,gBAAgB,GAAkB,MAAM,CAAC,kBAAkB,CAAC,CAAC"}
@@ -0,0 +1,9 @@
1
+ import { HttpRequest } from '@sectester/bus';
2
+ export interface GetRepeaterResponsePayload {
3
+ id: string;
4
+ name: string;
5
+ projectIds: string[];
6
+ }
7
+ export declare class GetRepeaterRequest extends HttpRequest<undefined, GetRepeaterResponsePayload> {
8
+ constructor(repeaterId: string);
9
+ }
@@ -0,0 +1,15 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.GetRepeaterRequest = void 0;
4
+ const bus_1 = require("@sectester/bus");
5
+ class GetRepeaterRequest extends bus_1.HttpRequest {
6
+ constructor(repeaterId) {
7
+ super({
8
+ url: `/api/v1/repeaters/${repeaterId}`,
9
+ method: 'GET',
10
+ payload: undefined
11
+ });
12
+ }
13
+ }
14
+ exports.GetRepeaterRequest = GetRepeaterRequest;
15
+ //# sourceMappingURL=GetRepeaterRequest.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"GetRepeaterRequest.js","sourceRoot":"","sources":["../../../../../../packages/repeater/src/api/commands/GetRepeaterRequest.ts"],"names":[],"mappings":";;;AAAA,wCAA6C;AAQ7C,MAAa,kBAAmB,SAAQ,iBAGvC;IACC,YAAY,UAAkB;QAC5B,KAAK,CAAC;YACJ,GAAG,EAAE,qBAAqB,UAAU,EAAE;YACtC,MAAM,EAAE,KAAK;YACb,OAAO,EAAE,SAAS;SACnB,CAAC,CAAC;IACL,CAAC;CACF;AAXD,gDAWC"}
@@ -1,2 +1,3 @@
1
1
  export { CreateRepeaterRequest } from './CreateRepeaterRequest';
2
2
  export { DeleteRepeaterRequest } from './DeleteRepeaterRequest';
3
+ export { GetRepeaterRequest } from './GetRepeaterRequest';
@@ -1,8 +1,10 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.DeleteRepeaterRequest = exports.CreateRepeaterRequest = void 0;
3
+ exports.GetRepeaterRequest = exports.DeleteRepeaterRequest = exports.CreateRepeaterRequest = void 0;
4
4
  var CreateRepeaterRequest_1 = require("./CreateRepeaterRequest");
5
5
  Object.defineProperty(exports, "CreateRepeaterRequest", { enumerable: true, get: function () { return CreateRepeaterRequest_1.CreateRepeaterRequest; } });
6
6
  var DeleteRepeaterRequest_1 = require("./DeleteRepeaterRequest");
7
7
  Object.defineProperty(exports, "DeleteRepeaterRequest", { enumerable: true, get: function () { return DeleteRepeaterRequest_1.DeleteRepeaterRequest; } });
8
+ var GetRepeaterRequest_1 = require("./GetRepeaterRequest");
9
+ Object.defineProperty(exports, "GetRepeaterRequest", { enumerable: true, get: function () { return GetRepeaterRequest_1.GetRepeaterRequest; } });
8
10
  //# sourceMappingURL=index.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../../../packages/repeater/src/api/commands/index.ts"],"names":[],"mappings":";;;AAAA,iEAAgE;AAAvD,8HAAA,qBAAqB,OAAA;AAC9B,iEAAgE;AAAvD,8HAAA,qBAAqB,OAAA"}
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../../../packages/repeater/src/api/commands/index.ts"],"names":[],"mappings":";;;AAAA,iEAAgE;AAAvD,8HAAA,qBAAqB,OAAA;AAC9B,iEAAgE;AAAvD,8HAAA,qBAAqB,OAAA;AAC9B,2DAA0D;AAAjD,wHAAA,kBAAkB,OAAA"}
@@ -1,5 +1,6 @@
1
1
  import { Repeater } from './Repeater';
2
2
  import { RepeaterOptions } from './RepeaterOptions';
3
+ import { RepeaterRequestRunnerOptions } from './RepeaterRequestRunnerOptions';
3
4
  import { Configuration } from '@sectester/core';
4
5
  /**
5
6
  * A factory that is able to create a dedicated instance of the repeater with a bus and other dependencies.
@@ -12,7 +13,9 @@ export declare class RepeaterFactory {
12
13
  private readonly repeatersManager;
13
14
  private readonly eventBusFactory;
14
15
  constructor(configuration: Configuration);
15
- createRepeater({ projectId, description, disableRandomNameGeneration, requestRunnerOptions, namePrefix, requestRunners }?: RepeaterOptions): Promise<Repeater>;
16
+ createRepeater({ projectId, description, disableRandomNameGeneration, namePrefix, ...requestRunnerOptions }?: RepeaterOptions): Promise<Repeater>;
17
+ createRepeaterFromExisting(repeaterId: string, options?: RepeaterRequestRunnerOptions): Promise<Repeater>;
18
+ private createRepeaterInstance;
16
19
  private generateName;
17
20
  private registerRequestRunners;
18
21
  private registerRequestRunnerOptions;
@@ -43,15 +43,22 @@ let RepeaterFactory = class RepeaterFactory {
43
43
  this.eventBusFactory =
44
44
  this.container.resolve(bus_1.EventBusFactory);
45
45
  }
46
- async createRepeater({ projectId, description, disableRandomNameGeneration, requestRunnerOptions, namePrefix = 'sectester', requestRunners = [request_runner_1.HttpRequestRunner, request_runner_1.WsRequestRunner] } = {}) {
47
- var _a;
48
- this.registerRequestRunners(requestRunners, requestRunnerOptions);
46
+ async createRepeater({ projectId, description, disableRandomNameGeneration, namePrefix = 'sectester', ...requestRunnerOptions } = {}) {
49
47
  const name = this.generateName(namePrefix, disableRandomNameGeneration);
50
48
  const { repeaterId } = await this.repeatersManager.createRepeater({
51
49
  description,
52
50
  projectId,
53
51
  name
54
52
  });
53
+ return this.createRepeaterInstance(repeaterId, requestRunnerOptions);
54
+ }
55
+ async createRepeaterFromExisting(repeaterId, options) {
56
+ await this.repeatersManager.getRepeater(repeaterId);
57
+ return this.createRepeaterInstance(repeaterId, options);
58
+ }
59
+ async createRepeaterInstance(repeaterId, { requestRunnerOptions, requestRunners = [request_runner_1.HttpRequestRunner, request_runner_1.WsRequestRunner] } = {}) {
60
+ var _a;
61
+ this.registerRequestRunners(requestRunners, requestRunnerOptions);
55
62
  const bus = await this.eventBusFactory.create(repeaterId);
56
63
  await ((_a = bus.init) === null || _a === void 0 ? void 0 : _a.call(bus));
57
64
  return new Repeater_1.Repeater({
@@ -1 +1 @@
1
- {"version":3,"file":"RepeaterFactory.js","sourceRoot":"","sources":["../../../../../packages/repeater/src/lib/RepeaterFactory.ts"],"names":[],"mappings":";;;;AAAA,yCAAsC;AACtC,sDAK2B;AAE3B,gCAA0C;AAC1C,gCAAyC;AACzC,0CAAgD;AAChD,+BAAoC;AACpC,uCAA2D;AAE3D;;GAEG;AAEH,IAAa,eAAe,GAA5B,MAAa,eAAe;IA2B1B,YAA6B,aAA4B;QAA5B,kBAAa,GAAb,aAAa,CAAe;QA1BxC,oBAAe,GAAG,EAAE,CAAC;QACrB,2BAAsB,GAAmC;YACxE,OAAO,EAAE,KAAK;YACd,gBAAgB,EAAE,GAAG;YACrB,eAAe,EAAE,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CAAC,QAAQ,CAAC,8BAAa,EAAE;gBACrC,QAAQ,EAAE,MAAM;aACjB,CAAC,CAAC;SACJ;IACH,CAAC;CACF,CAAA;AAvHY,eAAe;IAD3B,IAAA,qBAAU,GAAE;6CA4BiC,oBAAa;GA3B9C,eAAe,CAuH3B;AAvHY,0CAAe"}
1
+ {"version":3,"file":"RepeaterFactory.js","sourceRoot":"","sources":["../../../../../packages/repeater/src/lib/RepeaterFactory.ts"],"names":[],"mappings":";;;;AAAA,yCAAsC;AACtC,sDAK2B;AAE3B,gCAA0C;AAC1C,gCAAyC;AAEzC,0CAAgD;AAChD,+BAAoC;AACpC,uCAA2D;AAE3D;;GAEG;AAEH,IAAa,eAAe,GAA5B,MAAa,eAAe;IA2B1B,YAA6B,aAA4B;QAA5B,kBAAa,GAAb,aAAa,CAAe;QA1BxC,oBAAe,GAAG,EAAE,CAAC;QACrB,2BAAsB,GAAmC;YACxE,OAAO,EAAE,KAAK;YACd,gBAAgB,EAAE,GAAG;YACrB,eAAe,EAAE,KAAK;YACtB,YAAY,EAAE;gBACZ,WAAW;gBACX,YAAY;gBACZ,UAAU;gBACV,iBAAiB;gBACjB,eAAe;gBACf,UAAU;gBACV,wBAAwB;gBACxB,0BAA0B;gBAC1B,kBAAkB;gBAClB,iBAAiB;gBACjB,mCAAmC;gBACnC,qBAAqB;gBACrB,qBAAqB;gBACrB,qBAAqB;aACtB;SACF,CAAC;QAMA,IAAI,CAAC,SAAS,GAAG,IAAI,CAAC,aAAa,CAAC,SAAS,CAAC,oBAAoB,EAAE,CAAC;QAErE,IAAI,CAAC,gBAAgB;YACnB,IAAI,CAAC,SAAS,CAAC,OAAO,CAAmB,sBAAgB,CAAC,CAAC;QAC7D,IAAI,CAAC,eAAe;YAClB,IAAI,CAAC,SAAS,CAAC,OAAO,CAAkB,qBAAe,CAAC,CAAC;IAC7D,CAAC;IAEM,KAAK,CAAC,cAAc,CAAC,EAC1B,SAAS,EACT,WAAW,EACX,2BAA2B,EAC3B,U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unner, RequestRunnerOptions } from '../request-runner';
2
- export interface RepeaterOptions {
1
+ import { RepeaterRequestRunnerOptions } from './RepeaterRequestRunnerOptions';
2
+ export interface RepeaterOptions extends RepeaterRequestRunnerOptions {
3
3
  namePrefix?: string;
4
4
  projectId?: string;
5
5
  description?: string;
6
6
  disableRandomNameGeneration?: boolean;
7
- requestRunnerOptions?: RequestRunnerOptions;
8
- requestRunners?: (RequestRunner | {
9
- new (...args: any[]): RequestRunner;
10
- })[];
11
7
  }
@@ -0,0 +1,7 @@
1
+ import { RequestRunner, RequestRunnerOptions } from '../request-runner';
2
+ export interface RepeaterRequestRunnerOptions {
3
+ requestRunnerOptions?: RequestRunnerOptions;
4
+ requestRunners?: (RequestRunner | {
5
+ new (...args: any[]): RequestRunner;
6
+ })[];
7
+ }
@@ -0,0 +1,3 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ //# sourceMappingURL=RepeaterRequestRunnerOptions.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"RepeaterRequestRunnerOptions.js","sourceRoot":"","sources":["../../../../../packages/repeater/src/lib/RepeaterRequestRunnerOptions.ts"],"names":[],"mappings":""}
@@ -2,4 +2,5 @@ import './register';
2
2
  export { Repeater, RunningStatus } from './Repeater';
3
3
  export { RepeaterFactory } from './RepeaterFactory';
4
4
  export { RepeaterOptions } from './RepeaterOptions';
5
+ export { RepeaterRequestRunnerOptions } from './RepeaterRequestRunnerOptions';
5
6
  export { RepeaterStatus } from '../models/RepeaterStatus';