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

Add Wazuh Analysis plugin files and structure #7242

Open
wants to merge 214 commits into
base: main
Choose a base branch
from

Conversation

guidomodarelli
Copy link
Contributor

@guidomodarelli guidomodarelli commented Jan 15, 2025

Description

We need to create the "Analysis" plugin that will contain all data analysis dashboard applications. Our primary objective is to register this plugin and its applications to establish the scaffolding for future dashboard development.

Menu structure

  • Analysis
    • Endpoint security
      • Configuration assessment
      • Malware detection
      • FIM
    • Threat intelligence
      • Threat hunting
      • Vulnerability detection
      • Mitre ATT&CK
    • Security operations
      • Regulatory compliance (unify)
      • IT Hygiene
      • Incident response
    • Cloud Security
      • Docker
      • AWS
      • Google Cloud
      • Github
      • Office365

Functional requirements

  • The applications must be registered in both the legacy and new navigation menus.

Issues Resolved

wazuh/wazuh-dashboard#484

Evidence

image
image
image
image
image
image
image

Test

  • Test of titles in navigation groups in the sidebar

    image

  • Separated static application configurations into a dedicated file to improve code organization and simplify future maintenance

  • Moved shared logic between different plugins to wazuh-core

  • The applications under "Analysis" should only appear in that section and should not be located elsewhere or repeated.

    image

  • Test the menu structure

    • Analysis
      • Endpoint security
        • Configuration assessment
        • Malware detection
        • FIM
      • Threat intelligence
        • Threat hunting
        • Vulnerability detection
        • Mitre ATT&CK
      • Security operations
        • Regulatory compliance (unify)
        • IT Hygiene
        • Incident response
      • Cloud Security
        • Docker
        • AWS
        • Google Cloud
        • Github
        • Office365
  • The applications must be registered in both the legacy and new navigation menus.

    image

  • The SideNav should only appear in the old menu.

    Legacy menu:
    image

    New menu:
    image

  • The applications must be registered in search command

    image

Check List

  • New functionality includes testing.
  • New functionality has been documented.
  • Update CHANGELOG.md
  • Commits are signed per the DCO using --signoff

Update 2025/02/14

I will make the following changes based on @Desvelao’s review:

Currently, some elements—such as the Layout component, which renders the plugin’s internal sidebar when group navigation (new menu) is disabled, and utility functions like createSideNavItems—would need to be replicated in each plugin individually.

To avoid this duplication, I will evaluate whether these elements can:

  1. Be exposed from Wazuh Core, allowing all plugins to use them without redefining them.
  2. Be handled by Injecta in the app registration process, centralizing their management and simplifying the integration of new plugins.

This will improve maintainability and reduce code redundancy across plugins.

Solved here ff4a1a3, 5b00e82

Solving these comments

Adding in comments in which commit it was resolved

@guidomodarelli guidomodarelli self-assigned this Jan 15, 2025
@guidomodarelli

This comment was marked as resolved.

Copy link
Contributor

Wazuh Core plugin code coverage (Jest) test % values
Statements 27.15% ( 640 / 2357 )
Branches 28.75% ( 335 / 1165 )
Functions 24.84% ( 163 / 656 )
Lines 27.27% ( 635 / 2328 )

Copy link
Contributor

Wazuh Check Updates plugin code coverage (Jest) test % values
Statements 76.44% ( 172 / 225 )
Branches 58.65% ( 61 / 104 )
Functions 61.7% ( 29 / 47 )
Lines 76.44% ( 172 / 225 )

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Create the Analysis plugin and implement the new menu app registration method
3 participants