wazuh / wazuh-dashboard-plugins

Plugins for Wazuh Dashboard
https://wazuh.com/
GNU General Public License v2.0
427 stars 176 forks source link

[Update dashboards] Update `security events` dashboard #5838

Closed Machi3mfl closed 12 months ago

Machi3mfl commented 1 year ago

Description

Update the current security events dashboard

Dashboard mock

image

The dashboard mock serves as a design prototype (the information shown is only an example)

Tasks

chantal-kelm commented 1 year ago

I did some research and found that Opensearch currently only offers the option to color static data. As we want to put colors to dynamic data I have come up with a solution that when implemented does not work on some types of graphs. We decided not to use the solution as it only works on area charts.

const numberOfDataPoints = 20;
const colors = [
  '#38d1ba',
  '#009ac3',
  '#8335c6',
  '#fc33c9',
  '#d10062',
];
const colorRepetitions = Math.ceil(numberOfDataPoints / colors.length);

export const repeatedColors = [];
for (let i = 0; i < colorRepetitions; i++) {
  repeatedColors.push(...colors);

uiStateJSON: JSON.stringify({
        vis: {
          colors: repeatedColors,
        },
      }),

I am currently investigating why the solution does not work on some chart types.

chantal-kelm commented 1 year ago

🟢 It is on the dashboard 🔴 It is not in the dashboard

Title Current plugin dashboard New dashboard
Total marker 🟢 🟢
Level 12 or above alerts marker 🟢 🟢
Authentication failure flag 🟢 🟢
Authentication success flag 🟢 🟢
Alert level evolution 🟢 🔴
Top MITRE ATT&CKS 🟢 🟢 It is the same visualisation that is in the current dashboard but unlike the current dashboard visualisation, this one shows the top 5. Also in the current plugin it is a donut type and in the new dashboard it is a foot type.
Top 5 agents 🟢 🔴
Alerts evolution - Top 5 agents 🟢 🟢
Security Alerts Table 🟢 🟢

Current plugin dashboard

Captura de pantalla 2023-09-07 a la(s) 15 13 57

New dashboard

Captura de pantalla 2023-09-07 a la(s) 15 14 24