Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Implement embeddable dashboard on Malware Detection module #6521

Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
19 commits
Select commit Hold shift + click to select a range
6916b39
Replace the dashboard on Malware Detection application
yenienserrano Mar 14, 2024
449da7c
Multiple fixes
yenienserrano Mar 15, 2024
fcb9aa0
Merge branch '3.9.0' into 6520-remove-discover-implement-embeddable-d…
yenienserrano Apr 16, 2024
ac5ca74
feat(malware-detection): use data source on Dashboard and Events tabs
yenienserrano Apr 16, 2024
782b0ca
Chang consts names
yenienserrano Apr 16, 2024
b9ef4db
Merge branch '4.9.0' into 6520-remove-discover-implement-embeddable-d…
yenienserrano Apr 19, 2024
1c72899
Merge branch '4.9.0' into 6520-remove-discover-implement-embeddable-d…
yenienserrano Apr 22, 2024
90c8500
Update dashboard.tsx
yenienserrano Apr 24, 2024
47a6297
Removed unnecessary malware detection in tabFilters in common-data.js
yenienserrano Apr 24, 2024
b2d9114
Merge branch '4.9.0' into 6520-remove-discover-implement-embeddable-d…
yenienserrano Apr 25, 2024
94cd1a2
Conditional rendering sampledatawarning
yenienserrano Apr 25, 2024
900d6ed
Merge branch '4.9.0' into 6520-remove-discover-implement-embeddable-d…
yenienserrano Apr 25, 2024
53cc37f
Conditional rendering sampledatawarning
yenienserrano Apr 25, 2024
faa8d37
Merge branch '4.9.0' into 6520-remove-discover-implement-embeddable-d…
yenienserrano Apr 25, 2024
c5f8802
Merge branch '4.9.0' into 6520-remove-discover-implement-embeddable-d…
yenienserrano Apr 26, 2024
2a52113
Merge branch '4.9.0' into 6520-remove-discover-implement-embeddable-d…
yenienserrano Apr 26, 2024
e15b331
Merge branch '4.9.0' into 6520-remove-discover-implement-embeddable-d…
yenienserrano Apr 30, 2024
d58903f
Change labels
yenienserrano Apr 30, 2024
aaf2e4a
Merge branch '4.9.0' into 6520-remove-discover-implement-embeddable-d…
yenienserrano May 2, 2024
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions plugins/main/common/constants.ts
Original file line number Diff line number Diff line change
Expand Up @@ -233,6 +233,8 @@ export const DATA_SOURCE_FILTER_CONTROLLED_MITRE_ATTACK_RULE_ID =
'hidden-mitre-attack-rule-id';
export const DATA_SOURCE_FILTER_CONTROLLED_VIRUSTOTAL_RULE_GROUP =
'virustotal-rule-group';
export const DATA_SOURCE_FILTER_CONTROLLED_MALWARE_DETECTION_RULE_GROUP =
'malware-detection-rule-group';
export const DATA_SOURCE_FILTER_CONTROLLED_AWS_RULE_GROUP = 'aws-rule-group';
export const DATA_SOURCE_FILTER_CONTROLLED_FIM_RULE_GROUP = 'fim-rule-group';

Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
import { tFilter } from '../../../index';
import { DATA_SOURCE_FILTER_CONTROLLED_MALWARE_DETECTION_RULE_GROUP } from '../../../../../../../common/constants';
import { AlertsDataSource } from '../alerts-data-source';

const MALWARE_DETECTION_GROUP_KEY = 'rule.groups';
const MALWARE_DETECTION_GROUP_VALUE = 'rootcheck';

export class AlertsMalwareDetectionDataSource extends AlertsDataSource {
constructor(id: string, title: string) {
super(id, title);
}

getRuleGroupsFilter() {
return super.getRuleGroupsFilter(
MALWARE_DETECTION_GROUP_KEY,
MALWARE_DETECTION_GROUP_VALUE,
DATA_SOURCE_FILTER_CONTROLLED_MALWARE_DETECTION_RULE_GROUP,
);
}

getFixedFilters(): tFilter[] {
return [...this.getRuleGroupsFilter(), ...super.getFixedFilters()];
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
export * from './alerts-malware-detection-data-source';
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
export * from './alerts-fim';
export * from './alerts-data-source-repository';
export * from './alerts-data-source';
export * from './alerts-malware-detection';
export * from './alerts-aws';
export * from './vulnerabilities';
export * from './mitre-attack';
Expand Down
14 changes: 12 additions & 2 deletions plugins/main/public/components/common/modules/modules-defaults.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -48,13 +48,15 @@ import { mitreAttackColumns } from '../../overview/mitre/events/mitre-attack-col
import { virustotalColumns } from '../../overview/virustotal/events/virustotal-columns';
import { malwareDetectionColumns } from '../../overview/malware-detection/events/malware-detection-columns';
import { WAZUH_VULNERABILITIES_PATTERN } from '../../../../common/constants';
import { DashboardMalwareDetection } from '../../overview/malware-detection/dashboard';
import { DashboardFIM } from '../../overview/fim/dashboard/dashboard';
import { MitreAttackDataSource } from '../data-source/pattern/alerts/mitre-attack/mitre-attack-data-source';
import {
AlertsDataSource,
AlertsVulnerabilitiesDataSource,
AlertsAWSDataSource,
VirusTotalDataSource,
AlertsMalwareDetectionDataSource,
AlertsFIMDataSource,
} from '../data-source';

Expand Down Expand Up @@ -155,8 +157,16 @@ export const ModulesDefaults = {
pm: {
init: 'dashboard',
tabs: [
DashboardTab,
renderDiscoverTab(DEFAULT_INDEX_PATTERN, malwareDetectionColumns),
{
id: 'dashboard',
name: 'Dashboard',
buttons: [ButtonModuleExploreAgent, ButtonModuleGenerateReport],
component: DashboardMalwareDetection,
},
renderDiscoverTab({
tableColumns: malwareDetectionColumns,
DataSource: AlertsMalwareDetectionDataSource,
}),
],
availableFor: ['manager', 'agent'],
},
Expand Down
Loading
Loading