@shieldiot/pulse-lib 1.0.5 → 1.0.7
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/dist/index.d.ts +4 -2
- package/dist/index.js +4 -2
- package/dist/index.js.map +1 -1
- package/dist/lib/common/SeverityIntervalTuple.d.ts +1 -1
- package/dist/lib/common/TimeSeriesOfFloat.d.ts +1 -1
- package/dist/lib/common/TokenData.d.ts +1 -1
- package/dist/lib/entities/Account.d.ts +1 -1
- package/dist/lib/entities/Account.js.map +1 -1
- package/dist/lib/entities/AccountDTO.d.ts +3 -3
- package/dist/lib/entities/AccountDTO.js.map +1 -1
- package/dist/lib/entities/AccountSettings.d.ts +1 -1
- package/dist/lib/entities/Alert.d.ts +4 -4
- package/dist/lib/entities/Alert.js.map +1 -1
- package/dist/lib/entities/AlertWithDevice.d.ts +4 -4
- package/dist/lib/entities/AlertWithDevice.js.map +1 -1
- package/dist/lib/entities/ApiKey.d.ts +1 -1
- package/dist/lib/entities/ApiKey.js.map +1 -1
- package/dist/lib/entities/DeviceWithEvents.d.ts +2 -2
- package/dist/lib/entities/DeviceWithEvents.js.map +1 -1
- package/dist/lib/entities/Event.d.ts +3 -3
- package/dist/lib/entities/Event.js.map +1 -1
- package/dist/lib/entities/EventWithDevice.d.ts +7 -7
- package/dist/lib/entities/EventWithDevice.js.map +1 -1
- package/dist/lib/entities/Feature.d.ts +1 -1
- package/dist/lib/entities/Feature.js.map +1 -1
- package/dist/lib/entities/Insight.d.ts +1 -1
- package/dist/lib/entities/Insight.js.map +1 -1
- package/dist/lib/entities/Integration.d.ts +2 -2
- package/dist/lib/entities/Integration.js.map +1 -1
- package/dist/lib/entities/Rule.d.ts +1 -1
- package/dist/lib/entities/Rule.js.map +1 -1
- package/dist/lib/entities/RuleTemplate.d.ts +1 -1
- package/dist/lib/entities/RuleTemplate.js.map +1 -1
- package/dist/lib/entities/StreamAnalyticsConfig.d.ts +2 -2
- package/dist/lib/entities/StreamAnalyticsConfig.js.map +1 -1
- package/dist/lib/entities/StreamConfig.d.ts +2 -2
- package/dist/lib/services/sysAccountsService.d.ts +2 -2
- package/dist/lib/services/sysFeaturesService.d.ts +1 -1
- package/dist/lib/services/sysRulesService.d.ts +1 -1
- package/dist/lib/services/sysUsersService.d.ts +2 -2
- package/dist/lib/services/usrAlertsService.d.ts +9 -9
- package/dist/lib/services/usrDevicesService.d.ts +7 -7
- package/dist/lib/services/usrEventsService.d.ts +8 -8
- package/dist/lib/services/usrRulesService.d.ts +1 -1
- package/dist/lib/services/usrUserService.d.ts +1 -1
- package/package.json +1 -1
- package/src/index.ts +4 -3
- package/dist/public-api.d.ts +0 -3
- package/dist/public-api.js +0 -7
- package/dist/public-api.js.map +0 -1
- package/src/config.d.ts +0 -6
- package/src/config.d.ts.map +0 -1
- package/src/config.js +0 -6
- package/src/config.js.map +0 -1
- package/src/index.d.ts +0 -3
- package/src/index.d.ts.map +0 -1
- package/src/index.js +0 -3
- package/src/index.js.map +0 -1
- package/src/lib/common/AccountRole.ts +0 -25
- package/src/lib/common/ConsumptionData.ts +0 -24
- package/src/lib/common/ConsumptionTimeDataPoint.ts +0 -21
- package/src/lib/common/DeviceConfig.ts +0 -22
- package/src/lib/common/DeviceScoreConfig.ts +0 -24
- package/src/lib/common/DevicesAtRiskConfig.ts +0 -16
- package/src/lib/common/EventSeverityConfig.ts +0 -17
- package/src/lib/common/FloatKeyValue.ts +0 -20
- package/src/lib/common/GeoData.ts +0 -38
- package/src/lib/common/GraphSeries.ts +0 -21
- package/src/lib/common/Indicator.ts +0 -32
- package/src/lib/common/IntKeySeriesDataValue.ts +0 -21
- package/src/lib/common/IntKeyValue.ts +0 -20
- package/src/lib/common/Interval.ts +0 -20
- package/src/lib/common/Link.ts +0 -41
- package/src/lib/common/Location.ts +0 -20
- package/src/lib/common/LoginParams.ts +0 -24
- package/src/lib/common/MaliciousIPCard.ts +0 -45
- package/src/lib/common/MaliciousIPData.ts +0 -28
- package/src/lib/common/NetworkMap.ts +0 -22
- package/src/lib/common/Node.ts +0 -54
- package/src/lib/common/SeriesData.ts +0 -22
- package/src/lib/common/SessionTransform.ts +0 -29
- package/src/lib/common/SeverityIntervalTuple.ts +0 -22
- package/src/lib/common/ShieldexConfig.ts +0 -36
- package/src/lib/common/StringIntValue.ts +0 -20
- package/src/lib/common/StringKeyIntValue.ts +0 -20
- package/src/lib/common/StringKeyValue.ts +0 -20
- package/src/lib/common/Thresholds.ts +0 -16
- package/src/lib/common/TimeDataPoint.ts +0 -20
- package/src/lib/common/TimeDataPoint2D.ts +0 -21
- package/src/lib/common/TimeDataPointFloat.ts +0 -20
- package/src/lib/common/TimeFrame.ts +0 -20
- package/src/lib/common/TimeSeries.ts +0 -26
- package/src/lib/common/TimeSeriesOf2D.ts +0 -26
- package/src/lib/common/TimeSeriesOfDataConsumption.ts +0 -26
- package/src/lib/common/TimeSeriesOfFloat.ts +0 -26
- package/src/lib/common/TokenData.ts +0 -39
- package/src/lib/common/Tuple.ts +0 -20
- package/src/lib/common/UsageTransform.ts +0 -37
- package/src/lib/common/ZScore.ts +0 -20
- package/src/lib/common/index.ts +0 -41
- package/src/lib/entities/Account.ts +0 -45
- package/src/lib/entities/AccountDTO.ts +0 -49
- package/src/lib/entities/AccountSettings.ts +0 -31
- package/src/lib/entities/Action.ts +0 -30
- package/src/lib/entities/Alert.ts +0 -91
- package/src/lib/entities/AlertWithDevice.ts +0 -92
- package/src/lib/entities/ApiKey.ts +0 -33
- package/src/lib/entities/AuditLog.ts +0 -39
- package/src/lib/entities/BaseEntity.ts +0 -24
- package/src/lib/entities/BulkDevices.ts +0 -17
- package/src/lib/entities/Checkpoint.ts +0 -71
- package/src/lib/entities/ComplianceReportSettings.ts +0 -28
- package/src/lib/entities/Condition.ts +0 -28
- package/src/lib/entities/ConfigParam.ts +0 -15
- package/src/lib/entities/DNSRecord.ts +0 -40
- package/src/lib/entities/DataIngestion.ts +0 -63
- package/src/lib/entities/DataPointOfDeviceReport.ts +0 -21
- package/src/lib/entities/Device.ts +0 -82
- package/src/lib/entities/DeviceReport.ts +0 -29
- package/src/lib/entities/DeviceWithEvents.ts +0 -86
- package/src/lib/entities/Distribution.ts +0 -25
- package/src/lib/entities/Event.ts +0 -98
- package/src/lib/entities/EventOccurrence.ts +0 -34
- package/src/lib/entities/EventWithDevice.ts +0 -97
- package/src/lib/entities/Feature.ts +0 -18
- package/src/lib/entities/FeaturesGroup.ts +0 -18
- package/src/lib/entities/Group.ts +0 -24
- package/src/lib/entities/Image.ts +0 -18
- package/src/lib/entities/Insight.ts +0 -49
- package/src/lib/entities/InsightQuery.ts +0 -29
- package/src/lib/entities/InsightSpec.ts +0 -28
- package/src/lib/entities/IntDistribution.ts +0 -25
- package/src/lib/entities/Integration.ts +0 -81
- package/src/lib/entities/Member.ts +0 -22
- package/src/lib/entities/Radius.ts +0 -45
- package/src/lib/entities/Report.ts +0 -37
- package/src/lib/entities/Rule.ts +0 -65
- package/src/lib/entities/RuleTemplate.ts +0 -38
- package/src/lib/entities/SIM.ts +0 -32
- package/src/lib/entities/ServiceStatus.ts +0 -26
- package/src/lib/entities/SessionRecord.ts +0 -71
- package/src/lib/entities/Shieldex.ts +0 -23
- package/src/lib/entities/Stream.ts +0 -31
- package/src/lib/entities/StreamAnalyticsConfig.ts +0 -30
- package/src/lib/entities/StreamConfig.ts +0 -52
- package/src/lib/entities/TeaserPopUpSettings.ts +0 -24
- package/src/lib/entities/TimeSeriesOfDeviceReport.ts +0 -26
- package/src/lib/entities/UsageRecord.ts +0 -101
- package/src/lib/entities/User.ts +0 -45
- package/src/lib/entities/UserMembership.ts +0 -38
- package/src/lib/entities/UserMemberships.ts +0 -38
- package/src/lib/entities/index.ts +0 -51
- package/src/lib/enums/AccountStatusCode.ts +0 -35
- package/src/lib/enums/AccountTypeCode.ts +0 -40
- package/src/lib/enums/DataSourceCode.ts +0 -35
- package/src/lib/enums/DeviceActionCode.ts +0 -40
- package/src/lib/enums/DeviceCreationCode.ts +0 -40
- package/src/lib/enums/DeviceIdentityCode.ts +0 -55
- package/src/lib/enums/DeviceStatusCode.ts +0 -40
- package/src/lib/enums/DeviceTypeCode.ts +0 -90
- package/src/lib/enums/DirectionContextCode.ts +0 -40
- package/src/lib/enums/EventCategoryCode.ts +0 -30
- package/src/lib/enums/EventStatusCode.ts +0 -40
- package/src/lib/enums/EventTypeCode.ts +0 -115
- package/src/lib/enums/FeatureCode.ts +0 -70
- package/src/lib/enums/HomePageViewCode.ts +0 -35
- package/src/lib/enums/HttpMethodCode.ts +0 -45
- package/src/lib/enums/InsightStatusCode.ts +0 -35
- package/src/lib/enums/InsightTypeCode.ts +0 -30
- package/src/lib/enums/IntegrationTriggerCode.ts +0 -30
- package/src/lib/enums/IntegrationTypeCode.ts +0 -40
- package/src/lib/enums/MemberRoleCode.ts +0 -40
- package/src/lib/enums/NetworkMapTypeCode.ts +0 -35
- package/src/lib/enums/OperatorCode.ts +0 -75
- package/src/lib/enums/PermissionCode.ts +0 -45
- package/src/lib/enums/ReportTypeCode.ts +0 -35
- package/src/lib/enums/RuleTypeCode.ts +0 -35
- package/src/lib/enums/SeverityTypeCode.ts +0 -40
- package/src/lib/enums/TrafficDirectionCode.ts +0 -35
- package/src/lib/enums/UserStatusCode.ts +0 -40
- package/src/lib/enums/UserTypeCode.ts +0 -40
- package/src/lib/enums/index.ts +0 -29
- package/src/lib/index.ts +0 -4
- package/src/lib/pulse-client.ts +0 -190
- package/src/lib/services/index.ts +0 -26
- package/src/lib/services/services.export.ts +0 -54
- package/src/lib/services/supportStreamAnalyticsConfig.ts +0 -63
- package/src/lib/services/sysAccountsService.ts +0 -90
- package/src/lib/services/sysAuditLogService.ts +0 -72
- package/src/lib/services/sysCheckpointsService.ts +0 -62
- package/src/lib/services/sysConfigService.ts +0 -63
- package/src/lib/services/sysFeaturesService.ts +0 -77
- package/src/lib/services/sysGroupsService.ts +0 -85
- package/src/lib/services/sysInsightsService.ts +0 -122
- package/src/lib/services/sysKeysService.ts +0 -71
- package/src/lib/services/sysMembersService.ts +0 -66
- package/src/lib/services/sysRuleTemplatesService.ts +0 -63
- package/src/lib/services/sysRulesService.ts +0 -79
- package/src/lib/services/sysStatisticsService.ts +0 -50
- package/src/lib/services/sysStreamsService.ts +0 -64
- package/src/lib/services/sysUsersService.ts +0 -89
- package/src/lib/services/usrAlertsService.ts +0 -382
- package/src/lib/services/usrDevicesService.ts +0 -303
- package/src/lib/services/usrEventsService.ts +0 -355
- package/src/lib/services/usrInsightsService.ts +0 -29
- package/src/lib/services/usrIntegrationsService.ts +0 -79
- package/src/lib/services/usrMembersService.ts +0 -77
- package/src/lib/services/usrNetworkService.ts +0 -59
- package/src/lib/services/usrReportsService.ts +0 -114
- package/src/lib/services/usrRulesService.ts +0 -78
- package/src/lib/services/usrUserService.ts +0 -114
- package/src/public-api.d.ts +0 -4
- package/src/public-api.d.ts.map +0 -1
- package/src/public-api.js +0 -7
- package/src/public-api.js.map +0 -1
- package/src/public-api.ts +0 -9
- package/src/utils/ActionResponse.d.ts +0 -6
- package/src/utils/ActionResponse.d.ts.map +0 -1
- package/src/utils/ActionResponse.js +0 -9
- package/src/utils/ActionResponse.js.map +0 -1
- package/src/utils/BaseRestResponse.d.ts +0 -5
- package/src/utils/BaseRestResponse.d.ts.map +0 -1
- package/src/utils/BaseRestResponse.js +0 -8
- package/src/utils/BaseRestResponse.js.map +0 -1
- package/src/utils/EntitiesResponse.d.ts +0 -9
- package/src/utils/EntitiesResponse.d.ts.map +0 -1
- package/src/utils/EntitiesResponse.js +0 -15
- package/src/utils/EntitiesResponse.js.map +0 -1
- package/src/utils/EntityResponse.d.ts +0 -9
- package/src/utils/EntityResponse.d.ts.map +0 -1
- package/src/utils/EntityResponse.js +0 -15
- package/src/utils/EntityResponse.js.map +0 -1
- package/src/utils/index.d.ts +0 -6
- package/src/utils/index.d.ts.map +0 -1
- package/src/utils/index.js +0 -6
- package/src/utils/index.js.map +0 -1
- package/src/utils/rest-axios-setup.d.ts +0 -4
- package/src/utils/rest-axios-setup.d.ts.map +0 -1
- package/src/utils/rest-axios-setup.js +0 -8
- package/src/utils/rest-axios-setup.js.map +0 -1
- package/src/utils/rest-util.d.ts +0 -16
- package/src/utils/rest-util.d.ts.map +0 -1
- package/src/utils/rest-util.js +0 -101
- package/src/utils/rest-util.js.map +0 -1
|
@@ -1,25 +0,0 @@
|
|
|
1
|
-
import { MemberRoleCode } from '../enums';
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
// Account role represents the role of the user in the account
|
|
6
|
-
export class AccountRole {
|
|
7
|
-
|
|
8
|
-
// Account Id
|
|
9
|
-
public accountId: string;
|
|
10
|
-
|
|
11
|
-
// Account Name (for display only)
|
|
12
|
-
public accountName: string;
|
|
13
|
-
|
|
14
|
-
// User role in the account: UNDEFINED | ADMIN | OPERATOR | VIEWER
|
|
15
|
-
public role: MemberRoleCode;
|
|
16
|
-
|
|
17
|
-
constructor(accountId?: string, accountName?: string, role?: MemberRoleCode) {
|
|
18
|
-
if (accountId !== undefined) { this.accountId = accountId; }
|
|
19
|
-
if (accountName !== undefined) { this.accountName = accountName; }
|
|
20
|
-
if (role !== undefined) { this.role = role; }
|
|
21
|
-
}
|
|
22
|
-
|
|
23
|
-
}
|
|
24
|
-
|
|
25
|
-
|
|
@@ -1,24 +0,0 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
// A set of input, output data values
|
|
5
|
-
export class ConsumptionData {
|
|
6
|
-
|
|
7
|
-
// Incoming traffic in Kb
|
|
8
|
-
public dataIn: number;
|
|
9
|
-
|
|
10
|
-
// Outgoing traffic in Kb
|
|
11
|
-
public dataOut: number;
|
|
12
|
-
|
|
13
|
-
// Total traffic in Kb
|
|
14
|
-
public total: number;
|
|
15
|
-
|
|
16
|
-
constructor(dataIn?: number, dataOut?: number, total?: number) {
|
|
17
|
-
if (dataIn !== undefined) { this.dataIn = dataIn; }
|
|
18
|
-
if (dataOut !== undefined) { this.dataOut = dataOut; }
|
|
19
|
-
if (total !== undefined) { this.total = total; }
|
|
20
|
-
}
|
|
21
|
-
|
|
22
|
-
}
|
|
23
|
-
|
|
24
|
-
|
|
@@ -1,21 +0,0 @@
|
|
|
1
|
-
import { ConsumptionData } from '../common';
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
// ConsumptionTimeDataPoint model represents a 2 dimensions datapoint in time
|
|
6
|
-
export class ConsumptionTimeDataPoint {
|
|
7
|
-
|
|
8
|
-
// Sata point timestamp [Epoch milliseconds Timestamp]
|
|
9
|
-
public timestamp: number;
|
|
10
|
-
|
|
11
|
-
// Consumption data
|
|
12
|
-
public value: ConsumptionData;
|
|
13
|
-
|
|
14
|
-
constructor(timestamp?: number, value?: ConsumptionData) {
|
|
15
|
-
if (timestamp !== undefined) { this.timestamp = timestamp; }
|
|
16
|
-
if (value !== undefined) { this.value = value; }
|
|
17
|
-
}
|
|
18
|
-
|
|
19
|
-
}
|
|
20
|
-
|
|
21
|
-
|
|
@@ -1,22 +0,0 @@
|
|
|
1
|
-
import { DevicesAtRiskConfig } from '../common';
|
|
2
|
-
import { DeviceScoreConfig } from '../common';
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
// DeviceConfig is a set of device related configurations
|
|
7
|
-
export class DeviceConfig {
|
|
8
|
-
|
|
9
|
-
// Devices at risk configuration
|
|
10
|
-
public devicesAtRiskConfig: DevicesAtRiskConfig;
|
|
11
|
-
|
|
12
|
-
// Device score configurations
|
|
13
|
-
public deviceScoreConfig: DeviceScoreConfig;
|
|
14
|
-
|
|
15
|
-
constructor(devicesAtRiskConfig?: DevicesAtRiskConfig, deviceScoreConfig?: DeviceScoreConfig) {
|
|
16
|
-
if (devicesAtRiskConfig !== undefined) { this.devicesAtRiskConfig = devicesAtRiskConfig; }
|
|
17
|
-
if (deviceScoreConfig !== undefined) { this.deviceScoreConfig = deviceScoreConfig; }
|
|
18
|
-
}
|
|
19
|
-
|
|
20
|
-
}
|
|
21
|
-
|
|
22
|
-
|
|
@@ -1,24 +0,0 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
// DeviceScoreConfig is a set of parameters for device score config
|
|
5
|
-
export class DeviceScoreConfig {
|
|
6
|
-
|
|
7
|
-
// device score alpha factor
|
|
8
|
-
public deviceScoreAlphaFactor: number;
|
|
9
|
-
|
|
10
|
-
// occurrence threshold
|
|
11
|
-
public occurrenceThreshold: number;
|
|
12
|
-
|
|
13
|
-
// ruleCount threshold
|
|
14
|
-
public ruleCountThreshold: number;
|
|
15
|
-
|
|
16
|
-
constructor(deviceScoreAlphaFactor?: number, occurrenceThreshold?: number, ruleCountThreshold?: number) {
|
|
17
|
-
if (deviceScoreAlphaFactor !== undefined) { this.deviceScoreAlphaFactor = deviceScoreAlphaFactor; }
|
|
18
|
-
if (occurrenceThreshold !== undefined) { this.occurrenceThreshold = occurrenceThreshold; }
|
|
19
|
-
if (ruleCountThreshold !== undefined) { this.ruleCountThreshold = ruleCountThreshold; }
|
|
20
|
-
}
|
|
21
|
-
|
|
22
|
-
}
|
|
23
|
-
|
|
24
|
-
|
|
@@ -1,16 +0,0 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
// DevicesAtRiskConfig is int of minimal score for device to be at risk
|
|
5
|
-
export class DevicesAtRiskConfig {
|
|
6
|
-
|
|
7
|
-
// Minimal score for device to be at risk
|
|
8
|
-
public minScore: number;
|
|
9
|
-
|
|
10
|
-
constructor(minScore?: number) {
|
|
11
|
-
if (minScore !== undefined) { this.minScore = minScore; }
|
|
12
|
-
}
|
|
13
|
-
|
|
14
|
-
}
|
|
15
|
-
|
|
16
|
-
|
|
@@ -1,17 +0,0 @@
|
|
|
1
|
-
import { SeverityIntervalTuple } from '../common';
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
// EventSeverityConfig is a list of event severity configuration
|
|
6
|
-
export class EventSeverityConfig {
|
|
7
|
-
|
|
8
|
-
// List of severity configurations key-value. Value of type Interval
|
|
9
|
-
public severityConfigs: SeverityIntervalTuple[];
|
|
10
|
-
|
|
11
|
-
constructor(severityConfigs?: SeverityIntervalTuple[]) {
|
|
12
|
-
if (severityConfigs !== undefined) { this.severityConfigs = severityConfigs; }
|
|
13
|
-
}
|
|
14
|
-
|
|
15
|
-
}
|
|
16
|
-
|
|
17
|
-
|
|
@@ -1,20 +0,0 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
// Key Value float tuple
|
|
5
|
-
export class FloatKeyValue {
|
|
6
|
-
|
|
7
|
-
// Key of tuple
|
|
8
|
-
public key: number;
|
|
9
|
-
|
|
10
|
-
// Value of tuple
|
|
11
|
-
public value: number;
|
|
12
|
-
|
|
13
|
-
constructor(key?: number, value?: number) {
|
|
14
|
-
if (key !== undefined) { this.key = key; }
|
|
15
|
-
if (value !== undefined) { this.value = value; }
|
|
16
|
-
}
|
|
17
|
-
|
|
18
|
-
}
|
|
19
|
-
|
|
20
|
-
|
|
@@ -1,38 +0,0 @@
|
|
|
1
|
-
import { Location } from '../common';
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
// GeoData model represents Geographic data associated with IP
|
|
6
|
-
// This structure is based on the Elasticsearch GeoIP pipeline fetching data from MaxMind database
|
|
7
|
-
export class GeoData {
|
|
8
|
-
|
|
9
|
-
// Country ISO code
|
|
10
|
-
public country_iso_code: string;
|
|
11
|
-
|
|
12
|
-
// Country name
|
|
13
|
-
public country_name: string;
|
|
14
|
-
|
|
15
|
-
// Region ISO code
|
|
16
|
-
public region_iso_code: string;
|
|
17
|
-
|
|
18
|
-
// Region name
|
|
19
|
-
public region_name: string;
|
|
20
|
-
|
|
21
|
-
// City name
|
|
22
|
-
public city_name: string;
|
|
23
|
-
|
|
24
|
-
// WGS-84 Geo Location
|
|
25
|
-
public location: Location;
|
|
26
|
-
|
|
27
|
-
constructor(countryIsoCode?: string, countryName?: string, regionIsoCode?: string, regionName?: string, cityName?: string, location?: Location) {
|
|
28
|
-
if (countryIsoCode !== undefined) { this.country_iso_code = countryIsoCode; }
|
|
29
|
-
if (countryName !== undefined) { this.country_name = countryName; }
|
|
30
|
-
if (regionIsoCode !== undefined) { this.region_iso_code = regionIsoCode; }
|
|
31
|
-
if (regionName !== undefined) { this.region_name = regionName; }
|
|
32
|
-
if (cityName !== undefined) { this.city_name = cityName; }
|
|
33
|
-
if (location !== undefined) { this.location = location; }
|
|
34
|
-
}
|
|
35
|
-
|
|
36
|
-
}
|
|
37
|
-
|
|
38
|
-
|
|
@@ -1,21 +0,0 @@
|
|
|
1
|
-
import { IntKeySeriesDataValue } from '../common';
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
// GraphSeries model represents a generic set of data points over interval
|
|
6
|
-
export class GraphSeries {
|
|
7
|
-
|
|
8
|
-
// Name of the graph series
|
|
9
|
-
public name: string;
|
|
10
|
-
|
|
11
|
-
// Custom attributes (key-value pairs)
|
|
12
|
-
public values: IntKeySeriesDataValue[];
|
|
13
|
-
|
|
14
|
-
constructor(name?: string, values?: IntKeySeriesDataValue[]) {
|
|
15
|
-
if (name !== undefined) { this.name = name; }
|
|
16
|
-
if (values !== undefined) { this.values = values; }
|
|
17
|
-
}
|
|
18
|
-
|
|
19
|
-
}
|
|
20
|
-
|
|
21
|
-
|
|
@@ -1,32 +0,0 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
// Indicator model represents a feature and feature value within a normal range
|
|
5
|
-
export class Indicator {
|
|
6
|
-
|
|
7
|
-
// Feature name
|
|
8
|
-
public name: string;
|
|
9
|
-
|
|
10
|
-
// Level of Significance
|
|
11
|
-
public significance: number;
|
|
12
|
-
|
|
13
|
-
// Min normal value
|
|
14
|
-
public min: number;
|
|
15
|
-
|
|
16
|
-
// Max normal value
|
|
17
|
-
public max: number;
|
|
18
|
-
|
|
19
|
-
// Actual value of the feature
|
|
20
|
-
public actual: number;
|
|
21
|
-
|
|
22
|
-
constructor(name?: string, significance?: number, min?: number, max?: number, actual?: number) {
|
|
23
|
-
if (name !== undefined) { this.name = name; }
|
|
24
|
-
if (significance !== undefined) { this.significance = significance; }
|
|
25
|
-
if (min !== undefined) { this.min = min; }
|
|
26
|
-
if (max !== undefined) { this.max = max; }
|
|
27
|
-
if (actual !== undefined) { this.actual = actual; }
|
|
28
|
-
}
|
|
29
|
-
|
|
30
|
-
}
|
|
31
|
-
|
|
32
|
-
|
|
@@ -1,21 +0,0 @@
|
|
|
1
|
-
import { SeriesData } from '../common';
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
// Key: int Value SeriesData tuple
|
|
6
|
-
export class IntKeySeriesDataValue {
|
|
7
|
-
|
|
8
|
-
// Key of tuple
|
|
9
|
-
public key: number;
|
|
10
|
-
|
|
11
|
-
// Value of tuple
|
|
12
|
-
public value: SeriesData;
|
|
13
|
-
|
|
14
|
-
constructor(key?: number, value?: SeriesData) {
|
|
15
|
-
if (key !== undefined) { this.key = key; }
|
|
16
|
-
if (value !== undefined) { this.value = value; }
|
|
17
|
-
}
|
|
18
|
-
|
|
19
|
-
}
|
|
20
|
-
|
|
21
|
-
|
|
@@ -1,20 +0,0 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
// Key Value int tuple
|
|
5
|
-
export class IntKeyValue {
|
|
6
|
-
|
|
7
|
-
// Key of tuple
|
|
8
|
-
public key: number;
|
|
9
|
-
|
|
10
|
-
// Value of tuple
|
|
11
|
-
public value: number;
|
|
12
|
-
|
|
13
|
-
constructor(key?: number, value?: number) {
|
|
14
|
-
if (key !== undefined) { this.key = key; }
|
|
15
|
-
if (value !== undefined) { this.value = value; }
|
|
16
|
-
}
|
|
17
|
-
|
|
18
|
-
}
|
|
19
|
-
|
|
20
|
-
|
|
@@ -1,20 +0,0 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
// Interval represents a finite int window (from - to)
|
|
5
|
-
export class Interval {
|
|
6
|
-
|
|
7
|
-
// Start window interval
|
|
8
|
-
public from: number;
|
|
9
|
-
|
|
10
|
-
// End window interval
|
|
11
|
-
public to: number;
|
|
12
|
-
|
|
13
|
-
constructor(from?: number, to?: number) {
|
|
14
|
-
if (from !== undefined) { this.from = from; }
|
|
15
|
-
if (to !== undefined) { this.to = to; }
|
|
16
|
-
}
|
|
17
|
-
|
|
18
|
-
}
|
|
19
|
-
|
|
20
|
-
|
package/src/lib/common/Link.ts
DELETED
|
@@ -1,41 +0,0 @@
|
|
|
1
|
-
import { SeverityTypeCode } from '../enums';
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
// Link represents a relation between two nodes
|
|
6
|
-
export class Link {
|
|
7
|
-
|
|
8
|
-
// Link Id
|
|
9
|
-
public id: string;
|
|
10
|
-
|
|
11
|
-
// Link name
|
|
12
|
-
public name: string;
|
|
13
|
-
|
|
14
|
-
// Source Node Id (from)
|
|
15
|
-
public src: string;
|
|
16
|
-
|
|
17
|
-
// Destination Node Id (to)
|
|
18
|
-
public dst: string;
|
|
19
|
-
|
|
20
|
-
// Link numeric value
|
|
21
|
-
public value: number;
|
|
22
|
-
|
|
23
|
-
// Severity level: UNDEFINED | LOW | MEDIUM | HIGH | CRITICAL
|
|
24
|
-
public severity: SeverityTypeCode;
|
|
25
|
-
|
|
26
|
-
// Number of events for the time period (calculated field)
|
|
27
|
-
public eventCount: number;
|
|
28
|
-
|
|
29
|
-
constructor(id?: string, name?: string, src?: string, dst?: string, value?: number, severity?: SeverityTypeCode, eventCount?: number) {
|
|
30
|
-
if (id !== undefined) { this.id = id; }
|
|
31
|
-
if (name !== undefined) { this.name = name; }
|
|
32
|
-
if (src !== undefined) { this.src = src; }
|
|
33
|
-
if (dst !== undefined) { this.dst = dst; }
|
|
34
|
-
if (value !== undefined) { this.value = value; }
|
|
35
|
-
if (severity !== undefined) { this.severity = severity; }
|
|
36
|
-
if (eventCount !== undefined) { this.eventCount = eventCount; }
|
|
37
|
-
}
|
|
38
|
-
|
|
39
|
-
}
|
|
40
|
-
|
|
41
|
-
|
|
@@ -1,20 +0,0 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
// WGS-84 Geo Location
|
|
5
|
-
export class Location {
|
|
6
|
-
|
|
7
|
-
// Latitude
|
|
8
|
-
public lat: number;
|
|
9
|
-
|
|
10
|
-
// Longitude
|
|
11
|
-
public lon: number;
|
|
12
|
-
|
|
13
|
-
constructor(lat?: number, lon?: number) {
|
|
14
|
-
if (lat !== undefined) { this.lat = lat; }
|
|
15
|
-
if (lon !== undefined) { this.lon = lon; }
|
|
16
|
-
}
|
|
17
|
-
|
|
18
|
-
}
|
|
19
|
-
|
|
20
|
-
|
|
@@ -1,24 +0,0 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
// Login parameters data model
|
|
5
|
-
export class LoginParams {
|
|
6
|
-
|
|
7
|
-
// User email
|
|
8
|
-
public email: string;
|
|
9
|
-
|
|
10
|
-
// User password
|
|
11
|
-
public password: string;
|
|
12
|
-
|
|
13
|
-
// Access token - in case of re-login with existing token
|
|
14
|
-
public accessToken: string;
|
|
15
|
-
|
|
16
|
-
constructor(email?: string, password?: string, accessToken?: string) {
|
|
17
|
-
if (email !== undefined) { this.email = email; }
|
|
18
|
-
if (password !== undefined) { this.password = password; }
|
|
19
|
-
if (accessToken !== undefined) { this.accessToken = accessToken; }
|
|
20
|
-
}
|
|
21
|
-
|
|
22
|
-
}
|
|
23
|
-
|
|
24
|
-
|
|
@@ -1,45 +0,0 @@
|
|
|
1
|
-
import { IntDistribution } from '../entities';
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
// MaliciousIPCard is a data structure representing malicious IP card
|
|
6
|
-
export class MaliciousIPCard {
|
|
7
|
-
|
|
8
|
-
// The malicious IP
|
|
9
|
-
public maliciousIp: string;
|
|
10
|
-
|
|
11
|
-
// The malicious IP DNS name (can be comma-separated list of names)
|
|
12
|
-
public maliciousIpDns: string;
|
|
13
|
-
|
|
14
|
-
// Country code
|
|
15
|
-
public countryCode: string;
|
|
16
|
-
|
|
17
|
-
// Ip description
|
|
18
|
-
public ipDescription: string;
|
|
19
|
-
|
|
20
|
-
// Last Event Time
|
|
21
|
-
public lastEventTime: number;
|
|
22
|
-
|
|
23
|
-
// Attack Categories list
|
|
24
|
-
public attackCategories: string[];
|
|
25
|
-
|
|
26
|
-
// Number Of Devices
|
|
27
|
-
public numberOfDevices: number;
|
|
28
|
-
|
|
29
|
-
// Events By Severity Breakdown
|
|
30
|
-
public eventsBySeverityBreakdown: IntDistribution;
|
|
31
|
-
|
|
32
|
-
constructor(maliciousIp?: string, maliciousIpDns?: string, countryCode?: string, ipDescription?: string, lastEventTime?: number, attackCategories?: string[], numberOfDevices?: number, eventsBySeverityBreakdown?: IntDistribution) {
|
|
33
|
-
if (maliciousIp !== undefined) { this.maliciousIp = maliciousIp; }
|
|
34
|
-
if (maliciousIpDns !== undefined) { this.maliciousIpDns = maliciousIpDns; }
|
|
35
|
-
if (countryCode !== undefined) { this.countryCode = countryCode; }
|
|
36
|
-
if (ipDescription !== undefined) { this.ipDescription = ipDescription; }
|
|
37
|
-
if (lastEventTime !== undefined) { this.lastEventTime = lastEventTime; }
|
|
38
|
-
if (attackCategories !== undefined) { this.attackCategories = attackCategories; }
|
|
39
|
-
if (numberOfDevices !== undefined) { this.numberOfDevices = numberOfDevices; }
|
|
40
|
-
if (eventsBySeverityBreakdown !== undefined) { this.eventsBySeverityBreakdown = eventsBySeverityBreakdown; }
|
|
41
|
-
}
|
|
42
|
-
|
|
43
|
-
}
|
|
44
|
-
|
|
45
|
-
|
|
@@ -1,28 +0,0 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
// MaliciousIPData is a data structure representing malicious IP and its statistics
|
|
5
|
-
export class MaliciousIPData {
|
|
6
|
-
|
|
7
|
-
// The malicious IP
|
|
8
|
-
public ip: string;
|
|
9
|
-
|
|
10
|
-
// Total related events
|
|
11
|
-
public totalEvents: number;
|
|
12
|
-
|
|
13
|
-
// Total related devices
|
|
14
|
-
public totalDevices: number;
|
|
15
|
-
|
|
16
|
-
// Total suspicious IPs
|
|
17
|
-
public totalMaliciousIPs: number;
|
|
18
|
-
|
|
19
|
-
constructor(iP?: string, totalEvents?: number, totalDevices?: number, totalMaliciousIPs?: number) {
|
|
20
|
-
if (iP !== undefined) { this.ip = iP; }
|
|
21
|
-
if (totalEvents !== undefined) { this.totalEvents = totalEvents; }
|
|
22
|
-
if (totalDevices !== undefined) { this.totalDevices = totalDevices; }
|
|
23
|
-
if (totalMaliciousIPs !== undefined) { this.totalMaliciousIPs = totalMaliciousIPs; }
|
|
24
|
-
}
|
|
25
|
-
|
|
26
|
-
}
|
|
27
|
-
|
|
28
|
-
|
|
@@ -1,22 +0,0 @@
|
|
|
1
|
-
import { Node } from '../common';
|
|
2
|
-
import { Link } from '../common';
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
// NetworkMap is a data structure representing a set of nodes and vertex representing a network
|
|
7
|
-
export class NetworkMap {
|
|
8
|
-
|
|
9
|
-
// List of nodes
|
|
10
|
-
public nodes: Node[];
|
|
11
|
-
|
|
12
|
-
// List of links
|
|
13
|
-
public links: Link[];
|
|
14
|
-
|
|
15
|
-
constructor(nodes?: Node[], links?: Link[]) {
|
|
16
|
-
if (nodes !== undefined) { this.nodes = nodes; }
|
|
17
|
-
if (links !== undefined) { this.links = links; }
|
|
18
|
-
}
|
|
19
|
-
|
|
20
|
-
}
|
|
21
|
-
|
|
22
|
-
|
package/src/lib/common/Node.ts
DELETED
|
@@ -1,54 +0,0 @@
|
|
|
1
|
-
import { DeviceTypeCode } from '../enums';
|
|
2
|
-
import { StringKeyValue } from '../common';
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
// Node represents a vertex in a network map
|
|
7
|
-
export class Node {
|
|
8
|
-
|
|
9
|
-
// Node Id
|
|
10
|
-
public id: string;
|
|
11
|
-
|
|
12
|
-
// Node name
|
|
13
|
-
public name: string;
|
|
14
|
-
|
|
15
|
-
// Node IP
|
|
16
|
-
public ip: string;
|
|
17
|
-
|
|
18
|
-
// Device type (for nodes representing a device)
|
|
19
|
-
public type: DeviceTypeCode;
|
|
20
|
-
|
|
21
|
-
// Device current security score
|
|
22
|
-
public score: number;
|
|
23
|
-
|
|
24
|
-
// List of device tags
|
|
25
|
-
public tags: string[];
|
|
26
|
-
|
|
27
|
-
// Custom attributes (key-value pairs)
|
|
28
|
-
public labels: StringKeyValue[];
|
|
29
|
-
|
|
30
|
-
// Number of events for the time period (calculated field)
|
|
31
|
-
public eventCount: number;
|
|
32
|
-
|
|
33
|
-
// Is aggregated node
|
|
34
|
-
public isGroup: boolean;
|
|
35
|
-
|
|
36
|
-
//
|
|
37
|
-
public deviceCount: number;
|
|
38
|
-
|
|
39
|
-
constructor(id?: string, name?: string, ip?: string, type?: DeviceTypeCode, score?: number, tags?: string[], labels?: StringKeyValue[], eventCount?: number, isGroup?: boolean, deviceCount?: number) {
|
|
40
|
-
if (id !== undefined) { this.id = id; }
|
|
41
|
-
if (name !== undefined) { this.name = name; }
|
|
42
|
-
if (ip !== undefined) { this.ip = ip; }
|
|
43
|
-
if (type !== undefined) { this.type = type; }
|
|
44
|
-
if (score !== undefined) { this.score = score; }
|
|
45
|
-
if (tags !== undefined) { this.tags = tags; }
|
|
46
|
-
if (labels !== undefined) { this.labels = labels; }
|
|
47
|
-
if (eventCount !== undefined) { this.eventCount = eventCount; }
|
|
48
|
-
if (isGroup !== undefined) { this.isGroup = isGroup; }
|
|
49
|
-
if (deviceCount !== undefined) { this.deviceCount = deviceCount; }
|
|
50
|
-
}
|
|
51
|
-
|
|
52
|
-
}
|
|
53
|
-
|
|
54
|
-
|
|
@@ -1,22 +0,0 @@
|
|
|
1
|
-
import { Interval } from '../common';
|
|
2
|
-
import { StringKeyIntValue } from '../common';
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
// SeriesData model represents a generic datapoint in interval range
|
|
7
|
-
export class SeriesData {
|
|
8
|
-
|
|
9
|
-
// Data interval
|
|
10
|
-
public interval: Interval;
|
|
11
|
-
|
|
12
|
-
// Custom attributes (key-value pairs)
|
|
13
|
-
public values: StringKeyIntValue[];
|
|
14
|
-
|
|
15
|
-
constructor(interval?: Interval, values?: StringKeyIntValue[]) {
|
|
16
|
-
if (interval !== undefined) { this.interval = interval; }
|
|
17
|
-
if (values !== undefined) { this.values = values; }
|
|
18
|
-
}
|
|
19
|
-
|
|
20
|
-
}
|
|
21
|
-
|
|
22
|
-
|
|
@@ -1,29 +0,0 @@
|
|
|
1
|
-
import { ZScore } from '../common';
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
// Session data transformation parameters (to calculate z-score)
|
|
6
|
-
export class SessionTransform {
|
|
7
|
-
|
|
8
|
-
// ZScore parameters for incoming packets (to the device)
|
|
9
|
-
public packetsIn: ZScore;
|
|
10
|
-
|
|
11
|
-
// ZScore parameters for outgoing packets (from the device)
|
|
12
|
-
public packetsOut: ZScore;
|
|
13
|
-
|
|
14
|
-
// ZScore parameters for total number of incoming bytes (to the device)
|
|
15
|
-
public bytesIn: ZScore;
|
|
16
|
-
|
|
17
|
-
// ZScore parameters for total number of outgoing bytes (from the device)
|
|
18
|
-
public bytesOut: ZScore;
|
|
19
|
-
|
|
20
|
-
constructor(packetsIn?: ZScore, packetsOut?: ZScore, bytesIn?: ZScore, bytesOut?: ZScore) {
|
|
21
|
-
if (packetsIn !== undefined) { this.packetsIn = packetsIn; }
|
|
22
|
-
if (packetsOut !== undefined) { this.packetsOut = packetsOut; }
|
|
23
|
-
if (bytesIn !== undefined) { this.bytesIn = bytesIn; }
|
|
24
|
-
if (bytesOut !== undefined) { this.bytesOut = bytesOut; }
|
|
25
|
-
}
|
|
26
|
-
|
|
27
|
-
}
|
|
28
|
-
|
|
29
|
-
|
|
@@ -1,22 +0,0 @@
|
|
|
1
|
-
import { SeverityTypeCode } from '../enums';
|
|
2
|
-
import { Interval } from '../common';
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
// SeverityIntervalTuple is tuple of SeverityTypeCode and Interval
|
|
7
|
-
export class SeverityIntervalTuple {
|
|
8
|
-
|
|
9
|
-
// Event severity type code
|
|
10
|
-
public severity: SeverityTypeCode;
|
|
11
|
-
|
|
12
|
-
// Severity interval from-to
|
|
13
|
-
public interval: Interval;
|
|
14
|
-
|
|
15
|
-
constructor(severity?: SeverityTypeCode, interval?: Interval) {
|
|
16
|
-
if (severity !== undefined) { this.severity = severity; }
|
|
17
|
-
if (interval !== undefined) { this.interval = interval; }
|
|
18
|
-
}
|
|
19
|
-
|
|
20
|
-
}
|
|
21
|
-
|
|
22
|
-
|