@ampsec/platform-client 15.1.0 → 17.0.0
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/build/src/dto/enums/category.d.ts +6 -0
- package/build/src/dto/enums/category.js +12 -0
- package/build/src/dto/enums/category.js.map +1 -0
- package/build/src/dto/enums/findingKind.d.ts +9 -0
- package/build/src/dto/enums/findingKind.js +20 -0
- package/build/src/dto/enums/findingKind.js.map +1 -0
- package/build/src/dto/enums/index.d.ts +3 -0
- package/build/src/dto/enums/index.js +3 -0
- package/build/src/dto/enums/index.js.map +1 -1
- package/build/src/dto/enums/saasComponentKind.d.ts +8 -0
- package/build/src/dto/enums/saasComponentKind.js +18 -0
- package/build/src/dto/enums/saasComponentKind.js.map +1 -0
- package/build/src/dto/findings.dto.d.ts +3 -2
- package/build/src/dto/saasComponents.dto.d.ts +15 -3
- package/package.json +2 -2
- package/src/dto/enums/category.ts +7 -0
- package/src/dto/enums/findingKind.ts +19 -0
- package/src/dto/enums/index.ts +3 -0
- package/src/dto/enums/saasComponentKind.ts +16 -0
- package/src/dto/findings.dto.ts +3 -2
- package/src/dto/saasComponents.dto.ts +16 -3
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.Category = void 0;
|
|
4
|
+
/* eslint-disable no-unused-vars */
|
|
5
|
+
var Category;
|
|
6
|
+
(function (Category) {
|
|
7
|
+
Category["EDR"] = "EDR";
|
|
8
|
+
Category["MFA"] = "MFA";
|
|
9
|
+
Category["TRAINING"] = "TRAINING";
|
|
10
|
+
Category["WEB_GATEWAY"] = "WEB_GATEWAY";
|
|
11
|
+
})(Category || (exports.Category = Category = {}));
|
|
12
|
+
//# sourceMappingURL=category.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"category.js","sourceRoot":"","sources":["../../../../src/dto/enums/category.ts"],"names":[],"mappings":";;;AAAA,mCAAmC;AACnC,IAAY,QAKX;AALD,WAAY,QAAQ;IAClB,uBAAW,CAAA;IACX,uBAAW,CAAA;IACX,iCAAqB,CAAA;IACrB,uCAA2B,CAAA;AAC7B,CAAC,EALW,QAAQ,wBAAR,QAAQ,QAKnB"}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
export declare enum FindingKind {
|
|
2
|
+
NO_ACCOUNT = "NO_ACCOUNT",
|
|
3
|
+
MFA_NOT_ENABLED = "MFA_NOT_ENABLED",
|
|
4
|
+
FAILED_PHISHING = "FAILED_PHISHING",
|
|
5
|
+
TRAINING_OVERDUE = "TRAINING_OVERDUE",
|
|
6
|
+
DEVICE_NOT_MANAGED = "DEVICE_NOT_MANAGED",
|
|
7
|
+
VULNERABILITY_OUT_OF_SLA = "VULNERABILITY_OUT_OF_SLA",
|
|
8
|
+
WEB_GATEWAY_NOT_ACTIVE = "WEB_GATEWAY_NOT_ACTIVE"
|
|
9
|
+
}
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.FindingKind = void 0;
|
|
4
|
+
/* eslint-disable no-unused-vars */
|
|
5
|
+
var FindingKind;
|
|
6
|
+
(function (FindingKind) {
|
|
7
|
+
// ALL
|
|
8
|
+
FindingKind["NO_ACCOUNT"] = "NO_ACCOUNT";
|
|
9
|
+
// MFA
|
|
10
|
+
FindingKind["MFA_NOT_ENABLED"] = "MFA_NOT_ENABLED";
|
|
11
|
+
// TRAINING
|
|
12
|
+
FindingKind["FAILED_PHISHING"] = "FAILED_PHISHING";
|
|
13
|
+
FindingKind["TRAINING_OVERDUE"] = "TRAINING_OVERDUE";
|
|
14
|
+
// EDR
|
|
15
|
+
FindingKind["DEVICE_NOT_MANAGED"] = "DEVICE_NOT_MANAGED";
|
|
16
|
+
FindingKind["VULNERABILITY_OUT_OF_SLA"] = "VULNERABILITY_OUT_OF_SLA";
|
|
17
|
+
// WEB_GATEWAY
|
|
18
|
+
FindingKind["WEB_GATEWAY_NOT_ACTIVE"] = "WEB_GATEWAY_NOT_ACTIVE";
|
|
19
|
+
})(FindingKind || (exports.FindingKind = FindingKind = {}));
|
|
20
|
+
//# sourceMappingURL=findingKind.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"findingKind.js","sourceRoot":"","sources":["../../../../src/dto/enums/findingKind.ts"],"names":[],"mappings":";;;AAAA,mCAAmC;AACnC,IAAY,WAiBX;AAjBD,WAAY,WAAW;IACrB,MAAM;IACN,wCAAyB,CAAA;IAEzB,MAAM;IACN,kDAAmC,CAAA;IAEnC,WAAW;IACX,kDAAmC,CAAA;IACnC,oDAAqC,CAAA;IAErC,MAAM;IACN,wDAAyC,CAAA;IACzC,oEAAqD,CAAA;IAErD,cAAc;IACd,gEAAiD,CAAA;AACnD,CAAC,EAjBW,WAAW,2BAAX,WAAW,QAiBtB"}
|
|
@@ -1,6 +1,9 @@
|
|
|
1
1
|
export * from './agent.role';
|
|
2
2
|
export * from './agent.status';
|
|
3
|
+
export * from './category';
|
|
3
4
|
export * from './connector.status';
|
|
5
|
+
export * from './findingKind';
|
|
4
6
|
export * from './finding.severity';
|
|
5
7
|
export * from './finding.status';
|
|
6
8
|
export * from './jobExecution.status';
|
|
9
|
+
export * from './saasComponentKind';
|
|
@@ -16,8 +16,11 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
|
16
16
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
17
|
__exportStar(require("./agent.role"), exports);
|
|
18
18
|
__exportStar(require("./agent.status"), exports);
|
|
19
|
+
__exportStar(require("./category"), exports);
|
|
19
20
|
__exportStar(require("./connector.status"), exports);
|
|
21
|
+
__exportStar(require("./findingKind"), exports);
|
|
20
22
|
__exportStar(require("./finding.severity"), exports);
|
|
21
23
|
__exportStar(require("./finding.status"), exports);
|
|
22
24
|
__exportStar(require("./jobExecution.status"), exports);
|
|
25
|
+
__exportStar(require("./saasComponentKind"), exports);
|
|
23
26
|
//# sourceMappingURL=index.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../src/dto/enums/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,+CAA6B;AAC7B,iDAA+B;AAC/B,qDAAmC;AACnC,qDAAmC;AACnC,mDAAiC;AACjC,wDAAsC"}
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../src/dto/enums/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,+CAA6B;AAC7B,iDAA+B;AAC/B,6CAA2B;AAC3B,qDAAmC;AACnC,gDAA8B;AAC9B,qDAAmC;AACnC,mDAAiC;AACjC,wDAAsC;AACtC,sDAAoC"}
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
export declare enum SaasComponentKind {
|
|
2
|
+
MFA_CONFIG = "MFA_CONFIG",
|
|
3
|
+
PHISHING_RESULT = "PHISHING_RESULT",
|
|
4
|
+
TRAINING_ASSIGNMENT = "TRAINING_ASSIGNMENT",
|
|
5
|
+
EDR_CONFIG = "EDR_CONFIG",
|
|
6
|
+
VULNERABILITY = "VULNERABILITY",
|
|
7
|
+
WEB_GATEWAY_SESSION = "WEB_GATEWAY_SESSION"
|
|
8
|
+
}
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.SaasComponentKind = void 0;
|
|
4
|
+
/* eslint-disable no-unused-vars */
|
|
5
|
+
var SaasComponentKind;
|
|
6
|
+
(function (SaasComponentKind) {
|
|
7
|
+
// MFA
|
|
8
|
+
SaasComponentKind["MFA_CONFIG"] = "MFA_CONFIG";
|
|
9
|
+
// TRAINING
|
|
10
|
+
SaasComponentKind["PHISHING_RESULT"] = "PHISHING_RESULT";
|
|
11
|
+
SaasComponentKind["TRAINING_ASSIGNMENT"] = "TRAINING_ASSIGNMENT";
|
|
12
|
+
// EDR
|
|
13
|
+
SaasComponentKind["EDR_CONFIG"] = "EDR_CONFIG";
|
|
14
|
+
SaasComponentKind["VULNERABILITY"] = "VULNERABILITY";
|
|
15
|
+
// WEB_GATEWAY
|
|
16
|
+
SaasComponentKind["WEB_GATEWAY_SESSION"] = "WEB_GATEWAY_SESSION";
|
|
17
|
+
})(SaasComponentKind || (exports.SaasComponentKind = SaasComponentKind = {}));
|
|
18
|
+
//# sourceMappingURL=saasComponentKind.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"saasComponentKind.js","sourceRoot":"","sources":["../../../../src/dto/enums/saasComponentKind.ts"],"names":[],"mappings":";;;AAAA,mCAAmC;AACnC,IAAY,iBAcX;AAdD,WAAY,iBAAiB;IAC3B,MAAM;IACN,8CAAyB,CAAA;IAEzB,WAAW;IACX,wDAAmC,CAAA;IACnC,gEAA2C,CAAA;IAE3C,MAAM;IACN,8CAAyB,CAAA;IACzB,oDAA+B,CAAA;IAE/B,cAAc;IACd,gEAA2C,CAAA;AAC7C,CAAC,EAdW,iBAAiB,iCAAjB,iBAAiB,QAc5B"}
|
|
@@ -1,13 +1,14 @@
|
|
|
1
1
|
import { BaseDto, BaseUpsertDto } from './base.dto';
|
|
2
|
+
import { Category, FindingKind } from './enums';
|
|
2
3
|
import { FindingSeverity } from './enums/finding.severity';
|
|
3
4
|
import { FindingStatus } from './enums/finding.status';
|
|
4
5
|
export type FindingUpsertDto = BaseUpsertDto & {
|
|
5
6
|
/** Date the finding was closed */
|
|
6
7
|
closedAt?: string;
|
|
7
8
|
/** Category of finding */
|
|
8
|
-
category:
|
|
9
|
+
category: Category;
|
|
9
10
|
/** Type of finding */
|
|
10
|
-
kind:
|
|
11
|
+
kind: FindingKind;
|
|
11
12
|
/** Status of the finding, e.g. OPEN */
|
|
12
13
|
status: FindingStatus;
|
|
13
14
|
/** Severity of the finding, e.g. CRITICAL, HIGH, etc... */
|
|
@@ -1,15 +1,27 @@
|
|
|
1
1
|
import { ChangeAwareDto, ChangeAwareUpsertDto } from './base.dto';
|
|
2
|
+
import { Category, FindingSeverity, SaasComponentKind } from './enums';
|
|
3
|
+
export type SaasComponentMeta = {
|
|
4
|
+
_findings: {
|
|
5
|
+
active?: boolean;
|
|
6
|
+
enabled?: boolean;
|
|
7
|
+
failedPhishing?: boolean;
|
|
8
|
+
loggedIn?: boolean;
|
|
9
|
+
overdue?: boolean;
|
|
10
|
+
severity?: FindingSeverity;
|
|
11
|
+
};
|
|
12
|
+
[propName: string]: unknown;
|
|
13
|
+
};
|
|
2
14
|
export type SaasComponentUpsertDto = ChangeAwareUpsertDto & {
|
|
3
15
|
/** Asset Id */
|
|
4
16
|
aid?: string | undefined;
|
|
5
17
|
/** Category */
|
|
6
|
-
category:
|
|
18
|
+
category: Category;
|
|
7
19
|
/** Connector Id */
|
|
8
20
|
cid: string;
|
|
9
21
|
/** */
|
|
10
|
-
kind:
|
|
22
|
+
kind: SaasComponentKind;
|
|
11
23
|
/** Context specific information related to the Saas Component */
|
|
12
|
-
meta:
|
|
24
|
+
meta: SaasComponentMeta;
|
|
13
25
|
/** User Id of the affected user */
|
|
14
26
|
uid?: string | undefined;
|
|
15
27
|
/** External Id */
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@ampsec/platform-client",
|
|
3
|
-
"version": "
|
|
3
|
+
"version": "17.0.0",
|
|
4
4
|
"description": "",
|
|
5
5
|
"main": "build/src/index.js",
|
|
6
6
|
"runkitExampleFilename": "example/main.js",
|
|
@@ -15,7 +15,7 @@
|
|
|
15
15
|
"clean": "gts clean src",
|
|
16
16
|
"fix": "gts fix",
|
|
17
17
|
"test": "jest",
|
|
18
|
-
"verify": "npm run lint && npm run test && npm run build"
|
|
18
|
+
"verify": "npm run lint && npm run test && npm run build && npm outdated"
|
|
19
19
|
},
|
|
20
20
|
"keywords": [],
|
|
21
21
|
"author": "Amplifier Security <engineering@amplifiersecurity.com>",
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
/* eslint-disable no-unused-vars */
|
|
2
|
+
export enum FindingKind {
|
|
3
|
+
// ALL
|
|
4
|
+
NO_ACCOUNT = 'NO_ACCOUNT',
|
|
5
|
+
|
|
6
|
+
// MFA
|
|
7
|
+
MFA_NOT_ENABLED = 'MFA_NOT_ENABLED',
|
|
8
|
+
|
|
9
|
+
// TRAINING
|
|
10
|
+
FAILED_PHISHING = 'FAILED_PHISHING',
|
|
11
|
+
TRAINING_OVERDUE = 'TRAINING_OVERDUE',
|
|
12
|
+
|
|
13
|
+
// EDR
|
|
14
|
+
DEVICE_NOT_MANAGED = 'DEVICE_NOT_MANAGED',
|
|
15
|
+
VULNERABILITY_OUT_OF_SLA = 'VULNERABILITY_OUT_OF_SLA',
|
|
16
|
+
|
|
17
|
+
// WEB_GATEWAY
|
|
18
|
+
WEB_GATEWAY_NOT_ACTIVE = 'WEB_GATEWAY_NOT_ACTIVE',
|
|
19
|
+
}
|
package/src/dto/enums/index.ts
CHANGED
|
@@ -1,6 +1,9 @@
|
|
|
1
1
|
export * from './agent.role';
|
|
2
2
|
export * from './agent.status';
|
|
3
|
+
export * from './category';
|
|
3
4
|
export * from './connector.status';
|
|
5
|
+
export * from './findingKind';
|
|
4
6
|
export * from './finding.severity';
|
|
5
7
|
export * from './finding.status';
|
|
6
8
|
export * from './jobExecution.status';
|
|
9
|
+
export * from './saasComponentKind';
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
/* eslint-disable no-unused-vars */
|
|
2
|
+
export enum SaasComponentKind {
|
|
3
|
+
// MFA
|
|
4
|
+
MFA_CONFIG = 'MFA_CONFIG',
|
|
5
|
+
|
|
6
|
+
// TRAINING
|
|
7
|
+
PHISHING_RESULT = 'PHISHING_RESULT',
|
|
8
|
+
TRAINING_ASSIGNMENT = 'TRAINING_ASSIGNMENT',
|
|
9
|
+
|
|
10
|
+
// EDR
|
|
11
|
+
EDR_CONFIG = 'EDR_CONFIG',
|
|
12
|
+
VULNERABILITY = 'VULNERABILITY',
|
|
13
|
+
|
|
14
|
+
// WEB_GATEWAY
|
|
15
|
+
WEB_GATEWAY_SESSION = 'WEB_GATEWAY_SESSION',
|
|
16
|
+
}
|
package/src/dto/findings.dto.ts
CHANGED
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import {BaseDto, BaseUpsertDto} from './base.dto';
|
|
2
|
+
import {Category, FindingKind} from './enums';
|
|
2
3
|
import {FindingSeverity} from './enums/finding.severity';
|
|
3
4
|
import {FindingStatus} from './enums/finding.status';
|
|
4
5
|
|
|
@@ -6,9 +7,9 @@ export type FindingUpsertDto = BaseUpsertDto & {
|
|
|
6
7
|
/** Date the finding was closed */
|
|
7
8
|
closedAt?: string;
|
|
8
9
|
/** Category of finding */
|
|
9
|
-
category:
|
|
10
|
+
category: Category;
|
|
10
11
|
/** Type of finding */
|
|
11
|
-
kind:
|
|
12
|
+
kind: FindingKind;
|
|
12
13
|
/** Status of the finding, e.g. OPEN */
|
|
13
14
|
status: FindingStatus;
|
|
14
15
|
/** Severity of the finding, e.g. CRITICAL, HIGH, etc... */
|
|
@@ -1,16 +1,29 @@
|
|
|
1
1
|
import {ChangeAwareDto, ChangeAwareUpsertDto} from './base.dto';
|
|
2
|
+
import {Category, FindingSeverity, SaasComponentKind} from './enums';
|
|
3
|
+
|
|
4
|
+
export type SaasComponentMeta = {
|
|
5
|
+
_findings: {
|
|
6
|
+
active?: boolean;
|
|
7
|
+
enabled?: boolean;
|
|
8
|
+
failedPhishing?: boolean;
|
|
9
|
+
loggedIn?: boolean;
|
|
10
|
+
overdue?: boolean;
|
|
11
|
+
severity?: FindingSeverity;
|
|
12
|
+
};
|
|
13
|
+
[propName: string]: unknown;
|
|
14
|
+
};
|
|
2
15
|
|
|
3
16
|
export type SaasComponentUpsertDto = ChangeAwareUpsertDto & {
|
|
4
17
|
/** Asset Id */
|
|
5
18
|
aid?: string | undefined;
|
|
6
19
|
/** Category */
|
|
7
|
-
category:
|
|
20
|
+
category: Category;
|
|
8
21
|
/** Connector Id */
|
|
9
22
|
cid: string;
|
|
10
23
|
/** */
|
|
11
|
-
kind:
|
|
24
|
+
kind: SaasComponentKind;
|
|
12
25
|
/** Context specific information related to the Saas Component */
|
|
13
|
-
meta:
|
|
26
|
+
meta: SaasComponentMeta;
|
|
14
27
|
/** User Id of the affected user */
|
|
15
28
|
uid?: string | undefined;
|
|
16
29
|
/** External Id */
|