-
Notifications
You must be signed in to change notification settings - Fork 8.3k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[Security Solution] UEBA Spacetime Project (#104973)
Merging with known issues documented here: #106648
- Loading branch information
1 parent
3e4b64b
commit c0ceb06
Showing
121 changed files
with
5,143 additions
and
117 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
52 changes: 52 additions & 0 deletions
52
...k/plugins/security_solution/common/search_strategy/security_solution/ueba/common/index.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,52 @@ | ||
/* | ||
* Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one | ||
* or more contributor license agreements. Licensed under the Elastic License | ||
* 2.0; you may not use this file except in compliance with the Elastic License | ||
* 2.0. | ||
*/ | ||
|
||
import { Maybe } from '../../../common'; | ||
|
||
export enum RiskScoreFields { | ||
hostName = 'host_name', | ||
riskKeyword = 'risk_keyword', | ||
riskScore = 'risk_score', | ||
} | ||
export interface RiskScoreItem { | ||
_id?: Maybe<string>; | ||
[RiskScoreFields.hostName]: Maybe<string>; | ||
[RiskScoreFields.riskKeyword]: Maybe<string>; | ||
[RiskScoreFields.riskScore]: Maybe<number>; | ||
} | ||
export enum HostRulesFields { | ||
hits = 'hits', | ||
riskScore = 'risk_score', | ||
ruleName = 'rule_name', | ||
ruleType = 'rule_type', | ||
} | ||
export interface HostRulesItem { | ||
_id?: Maybe<string>; | ||
[HostRulesFields.hits]: Maybe<number>; | ||
[HostRulesFields.riskScore]: Maybe<number>; | ||
[HostRulesFields.ruleName]: Maybe<string>; | ||
[HostRulesFields.ruleType]: Maybe<string>; | ||
} | ||
export enum UserRulesFields { | ||
userName = 'user_name', | ||
riskScore = 'risk_score', | ||
rules = 'rules', | ||
ruleCount = 'rule_count', | ||
} | ||
export enum HostTacticsFields { | ||
hits = 'hits', | ||
riskScore = 'risk_score', | ||
tactic = 'tactic', | ||
technique = 'technique', | ||
} | ||
export interface HostTacticsItem { | ||
_id?: Maybe<string>; | ||
[HostTacticsFields.hits]: Maybe<number>; | ||
[HostTacticsFields.riskScore]: Maybe<number>; | ||
[HostTacticsFields.tactic]: Maybe<string>; | ||
[HostTacticsFields.technique]: Maybe<string>; | ||
} |
48 changes: 48 additions & 0 deletions
48
...ugins/security_solution/common/search_strategy/security_solution/ueba/host_rules/index.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,48 @@ | ||
/* | ||
* Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one | ||
* or more contributor license agreements. Licensed under the Elastic License | ||
* 2.0; you may not use this file except in compliance with the Elastic License | ||
* 2.0. | ||
*/ | ||
|
||
import { IEsSearchResponse } from '../../../../../../../../src/plugins/data/common'; | ||
|
||
import { HostRulesItem, HostRulesFields } from '../common'; | ||
import { CursorType, Hit, Inspect, Maybe, PageInfoPaginated, SortField } from '../../../common'; | ||
import { RequestOptionsPaginated } from '../..'; | ||
|
||
export interface HostRulesHit extends Hit { | ||
key: string; | ||
doc_count: number; | ||
risk_score: { | ||
value?: number; | ||
}; | ||
rule_type: { | ||
buckets?: Array<{ | ||
key: string; | ||
doc_count: number; | ||
}>; | ||
}; | ||
rule_count: { | ||
value: number; | ||
}; | ||
} | ||
|
||
export interface HostRulesEdges { | ||
node: HostRulesItem; | ||
cursor: CursorType; | ||
} | ||
|
||
export interface HostRulesStrategyResponse extends IEsSearchResponse { | ||
edges: HostRulesEdges[]; | ||
totalCount: number; | ||
pageInfo: PageInfoPaginated; | ||
inspect?: Maybe<Inspect>; | ||
} | ||
|
||
export interface HostRulesRequestOptions extends RequestOptionsPaginated<HostRulesFields> { | ||
defaultIndex: string[]; | ||
hostName: string; | ||
} | ||
|
||
export type HostRulesSortField = SortField<HostRulesFields>; |
52 changes: 52 additions & 0 deletions
52
...ins/security_solution/common/search_strategy/security_solution/ueba/host_tactics/index.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,52 @@ | ||
/* | ||
* Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one | ||
* or more contributor license agreements. Licensed under the Elastic License | ||
* 2.0; you may not use this file except in compliance with the Elastic License | ||
* 2.0. | ||
*/ | ||
|
||
import { IEsSearchResponse } from '../../../../../../../../src/plugins/data/common'; | ||
|
||
import { HostTacticsItem, HostTacticsFields } from '../common'; | ||
import { CursorType, Hit, Inspect, Maybe, PageInfoPaginated, SortField } from '../../../common'; | ||
import { RequestOptionsPaginated } from '../..'; | ||
export interface HostTechniqueHit { | ||
key: string; | ||
doc_count: number; | ||
risk_score: { | ||
value?: number; | ||
}; | ||
} | ||
export interface HostTacticsHit extends Hit { | ||
key: string; | ||
doc_count: number; | ||
risk_score: { | ||
value?: number; | ||
}; | ||
technique: { | ||
buckets?: HostTechniqueHit[]; | ||
}; | ||
tactic_count: { | ||
value: number; | ||
}; | ||
} | ||
|
||
export interface HostTacticsEdges { | ||
node: HostTacticsItem; | ||
cursor: CursorType; | ||
} | ||
|
||
export interface HostTacticsStrategyResponse extends IEsSearchResponse { | ||
edges: HostTacticsEdges[]; | ||
techniqueCount: number; | ||
totalCount: number; | ||
pageInfo: PageInfoPaginated; | ||
inspect?: Maybe<Inspect>; | ||
} | ||
|
||
export interface HostTacticsRequestOptions extends RequestOptionsPaginated<HostTacticsFields> { | ||
defaultIndex: string[]; | ||
hostName: string; | ||
} | ||
|
||
export type HostTacticsSortField = SortField<HostTacticsFields>; |
19 changes: 19 additions & 0 deletions
19
x-pack/plugins/security_solution/common/search_strategy/security_solution/ueba/index.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
/* | ||
* Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one | ||
* or more contributor license agreements. Licensed under the Elastic License | ||
* 2.0; you may not use this file except in compliance with the Elastic License | ||
* 2.0. | ||
*/ | ||
|
||
export * from './common'; | ||
export * from './host_rules'; | ||
export * from './host_tactics'; | ||
export * from './risk_score'; | ||
export * from './user_rules'; | ||
|
||
export enum UebaQueries { | ||
hostRules = 'hostRules', | ||
hostTactics = 'hostTactics', | ||
riskScore = 'riskScore', | ||
userRules = 'userRules', | ||
} |
47 changes: 47 additions & 0 deletions
47
...ugins/security_solution/common/search_strategy/security_solution/ueba/risk_score/index.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,47 @@ | ||
/* | ||
* Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one | ||
* or more contributor license agreements. Licensed under the Elastic License | ||
* 2.0; you may not use this file except in compliance with the Elastic License | ||
* 2.0. | ||
*/ | ||
|
||
import { IEsSearchResponse } from '../../../../../../../../src/plugins/data/common'; | ||
|
||
import { RiskScoreItem, RiskScoreFields } from '../common'; | ||
import { CursorType, Hit, Inspect, Maybe, PageInfoPaginated, SortField } from '../../../common'; | ||
import { RequestOptionsPaginated } from '../..'; | ||
|
||
export interface RiskScoreHit extends Hit { | ||
_source: { | ||
'@timestamp': string; | ||
}; | ||
key: string; | ||
doc_count: number; | ||
risk_score: { | ||
value?: number; | ||
}; | ||
risk_keyword: { | ||
buckets?: Array<{ | ||
key: string; | ||
doc_count: number; | ||
}>; | ||
}; | ||
} | ||
|
||
export interface RiskScoreEdges { | ||
node: RiskScoreItem; | ||
cursor: CursorType; | ||
} | ||
|
||
export interface RiskScoreStrategyResponse extends IEsSearchResponse { | ||
edges: RiskScoreEdges[]; | ||
totalCount: number; | ||
pageInfo: PageInfoPaginated; | ||
inspect?: Maybe<Inspect>; | ||
} | ||
|
||
export interface RiskScoreRequestOptions extends RequestOptionsPaginated<RiskScoreFields> { | ||
defaultIndex: string[]; | ||
} | ||
|
||
export type RiskScoreSortField = SortField<RiskScoreFields>; |
Oops, something went wrong.