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

Replace search bar on TableWzAPI component #5442

Merged
merged 89 commits into from
Aug 11, 2023

Conversation

Desvelao
Copy link
Member

@Desvelao Desvelao commented May 15, 2023

Description

This pull request replaces the search bar on the TableWzAPI component and each usage of this.

Affected sections:

  • Modules > Security Configuration Assessment > {policy_id} > Checks
  • Modules > Vulnerabilities > Inventory
  • Modules > MITRE ATT&CK > Intelligence > Groups
  • Modules > MITRE ATT&CK > Intelligence > Mitigations
  • Modules > MITRE ATT&CK > Intelligence > Software
  • Modules > MITRE ATT&CK > Intelligence > Tactics
  • Modules > MITRE ATT&CK > Intelligence > Techniques
  • Management > CDB Lists
  • Management > Decoders
  • Management > Decoders > Files

A new column was added: relative_dirname

  • Management > Rules
  • Management > Rules > Files

A new column was added: relative_dirname

Moreover, the TableWzAPI is enhanced with the feature to select the visible table column. This feature is present in the table in the Agents section. This enables us to replace the current table with this component instead in #5452.

Additional changes:

  • Remove the double toast message when there is an error in the API request to fetch the data in the TableWzAPI component
  • Rename the error name to RequestError to hide AxiosError when there is an error fetching the data in the TableWzAPI component

#5363 should be merged before this.

Issues Resolved

#4312

Evidence

screenshots
  • Modules > Security Configuration Assessment > {policy_id} > Checks
    image
    image

  • Modules/Vulnerabilities
    image
    image

  • Modules >MITRE ATT&CK > Intelligence > Groups
    image
    image

  • Modules >MITRE ATT&CK > Intelligence > Mitigations
    image
    image

  • Modules >MITRE ATT&CK > Intelligence > Software
    image
    image

  • Modules >MITRE ATT&CK > Intelligence > Tactics
    image
    image

  • Modules >MITRE ATT&CK > Intelligence > Techniques
    image
    image

  • Management > CDB Lists
    image
    image

  • Management > Decoders
    image
    image

  • Management > Decoders >Files
    image
    image

  • Management > Rules
    image
    image

  • Management > Rules > Files
    image
    image

Table - Management > CDB Lists
Suggestions:

field get distinct values searchable
filename GET /lists?distinct=true&limit=30&select={field}&sort=+{field}&q={currentValue}
relative_dirname GET /lists?distinct=true&limit=30&select={field}&sort=+{field}&q={currentValue}

Table - Management > Rules
Suggestions:

field get distinct values searchable
status enabled, disabled
groups GET /rules/groups?limit=30&search={currentValue}
level 0-15
filename GET /rules/files?distinct=truelimit=30&select={field}&sort=+{field}&q={currentValue}
relative_dirname GET /rules?distinct=true&limit=30&select={field}&sort=+{field}&q={currentValue}
hipaa GET /rules/requirement/hipaa?limit=30&search={currentValue}
gdpr GET /rules/requirement/gdpr?limit=30&search={currentValue}
gpg13 GET /rules/requirement/gpg13?limit=30&search={currentValue}
nist-800-53 GET /rules/requirement/nist-800-53?limit=30&search={currentValue}
pci_dss GET /rules/requirement/pci_dss?limit=30&search={currentValue}
tsc GET /rules/requirement/tsc?limit=30&search={currentValue}
mitre GET /rules/requirement/mitre?limit=30&search={currentValue}
nist_800_53 GET /rules/requirement/nist_800_53?limit=30&search={currentValue}

Table - Management > Rules > Manage files
Suggestions:

field get distinct values searchable
filename GET /rules/files?distinct=truelimit=30&select={field}&sort=+{field}&q={currentValue}
relative_dirname GET /rules?distinct=true&limit=30&select={field}&sort=+{field}&q={currentValue}

relative_dirname was added to support the filter added by Custom files, if not, a validation error was displayed in the UI despite the request was done, but it was confusing.

Table - Management > Decoders
Suggestions:

field get distinct values searchable
details.order GET /decoders?distinct=true&limit=10&select={field}&q={currentValue}
details.program_name GET /decoders?distinct=true&limit=10&select={field}&q={currentValue}
filename GET /decoders?distinct=true&limit=10&select={field}&sort=+{field}&q={currentValue}
name GET /decoders?distinct=true&limit=10&select={field}&sort=+{field}&q={currentValue}
relative_dirname GET /decoders?distinct=true&limit=10&select={field}&sort=+{field}&q={currentValue}

Problem detected with the details.order and details.program_name
image
To fix this, I added logic to ensure there is a truthy value

Another problem found:

image

UI broken for details.program_name
image

Table - Management > Decoders > Manage files
Suggestions:

field get distinct values searchable
filename GET /decoders?distinct=true&limit=10&select={field}&sort=+{field}&q={currentValue}
relative_dirname GET /decoders?distinct=true&limit=10&select={field}&sort=+{field}&q={currentValue}

relative_dirname was added to support the filter added by Custom files, if not, a validation error was displayed in the UI despite the request was done, but it was confusing.

Table - Modules > MITRE ATTA&CK > Intelligence > Groups
Suggestions:

field get distinct values searchable
description GET /mitre/groups/?distinct=true&limit=30&select={field}&sort=+{field}&q={currentValue}
external_id GET /mitre/groups/?distinct=true&limit=30&select={field}&sort=+{field}&q={currentValue}
name GET /mitre/groups/?distinct=true&limit=30&select={field}&sort=+{field}&q={currentValue}

Table - Modules > MITRE ATTA&CK > Intelligence > Mitigations
Suggestions:

field get distinct values searchable
description GET /mitre/mitigations/?distinct=true&limit=30&select={field}&sort=+{field}&q={currentValue}
external_id GET /mitre/mitigations/?distinct=true&limit=30&select={field}&sort=+{field}&q={currentValue}
name GET /mitre/mitigations/?distinct=true&limit=30&select={field}&sort=+{field}&q={currentValue}

Table - Modules > MITRE ATTA&CK > Intelligence > Software
Suggestions:

field get distinct values searchable
description GET /mitre/software/?distinct=true&limit=30&select={field}&sort=+{field}&q={currentValue}
external_id GET /mitre/software/?distinct=true&limit=30&select={field}&sort=+{field}&q={currentValue}
name GET /mitre/software/?distinct=true&limit=30&select={field}&sort=+{field}&q={currentValue}

Table - Modules > MITRE ATTA&CK > Intelligence > Tactics
Suggestions:

field get distinct values searchable
description GET /mitre/tactics/?distinct=true&limit=30&select={field}&sort=+{field}&q={currentValue}
external_id GET /mitre/tactics/?distinct=true&limit=30&select={field}&sort=+{field}&q={currentValue}
name GET /mitre/tactics/?distinct=true&limit=30&select={field}&sort=+{field}&q={currentValue}

Table - Modules > MITRE ATTA&CK > Intelligence > Techniques
Suggestions:

field get distinct values searchable
description GET /mitre/techniques/?distinct=true&limit=30&select={field}&sort=+{field}&q={currentValue}
external_id GET /mitre/techniques/?distinct=true&limit=30&select={field}&sort=+{field}&q={currentValue}
name GET /mitre/techniques/?distinct=true&limit=30&select={field}&sort=+{field}&q={currentValue}

Table - Modules > Vulnerabilities > Inventory
Suggestions:

field get distinct values searchable
architecture GET /vulnerability/{agent_id}?distinct=true&limit=30&select={field}&sort=+{field}&q=${currentValue}
cve GET /vulnerability/{agent_id}?distinct=true&limit=30&select={field}&sort=+{field}&q=${currentValue}
cvss2_score GET /vulnerability/{agent_id}?distinct=true&limit=30&select={field}&sort=+{field}&q=${currentValue}
cvss3_score GET /vulnerability/{agent_id}?distinct=true&limit=30&select={field}&sort=+{field}&q=${currentValue}
detection_time GET /vulnerability/{agent_id}?distinct=true&limit=30&select={field}&sort=+{field}&q=${currentValue}
name GET /vulnerability/{agent_id}?distinct=true&limit=30&select={field}&sort=+{field}&q=${currentValue}
severity GET /vulnerability/{agent_id}?distinct=true&limit=30&select={field}&sort=+{field}&q=${currentValue}
version GET /vulnerability/{agent_id}?distinct=true&limit=30&select={field}&sort=+{field}&q=${currentValue}

Problem using detection_time
image

Table - Modules > Security configuration assessment > Inventory
Suggestions:

field get distinct values searchable
condition GET /sca/{agent_id}/checks/{policy_id}?distinct=true&limit=30&select={field}&sort=+{field}&q=${currentValue}
description GET /sca/{agent_id}/checks/{policy_id}?distinct=true&limit=30&select={field}&sort=+{field}&q=${currentValue}
file GET /sca/{agent_id}/checks/{policy_id}?distinct=true&limit=30&select={field}&sort=+{field}&q=${currentValue}
rationale GET /sca/{agent_id}/checks/{policy_id}?distinct=true&limit=30&select={field}&sort=+{field}&q=${currentValue}
reason GET /sca/{agent_id}/checks/{policy_id}?distinct=true&limit=30&select={field}&sort=+{field}&q=${currentValue}
registry GET /sca/{agent_id}/checks/{policy_id}?distinct=true&limit=30&select={field}&sort=+{field}&q=${currentValue}
remediation GET /sca/{agent_id}/checks/{policy_id}?distinct=true&limit=30&select={field}&sort=+{field}&q=${currentValue}
result GET /sca/{agent_id}/checks/{policy_id}?distinct=true&limit=30&select={field}&sort=+{field}&q=${currentValue}
title GET /sca/{agent_id}/checks/{policy_id}?distinct=true&limit=30&select={field}&sort=+{field}&q=${currentValue}

Problems

image

Test

Use a Wazuh manager

Legend:
⚫: none
🟢: pass
🟡: warning
🔴: fail
⚪: not applicable

UI

Test Chrome Firefox Safari
Modules > Security Configuration Assessment > {policy_id} > Checks: For each suggested field, check the value suggestion display results or at least doesn't break
Modules > Security Configuration Assessment > {policy_id} > Checks: Using a value suggested should allow to run the search
Modules > Security Configuration Assessment > {policy_id} > Checks: Type a term and run the search should search in each displayed field
Modules > Security Configuration Assessment > {policy_id} > Checks: Type a simple field search and this should return the expected results
Modules > Security Configuration Assessment > {policy_id} > Checks: Type a complex field search and this should return the expected results
Modules > Security Configuration Assessment > {policy_id} > Checks: Click in the result KPI, it should add a filter to the search bar and the table should be filtered
Modules > Vulnerabilities > Inventory: For each suggested field, check the value suggestion display results or at least doesn't break
Modules > Vulnerabilities > Inventory: Using a value suggested should allow to run the search
Modules > Vulnerabilities > Inventory: Type a term and run the search should search in each displayed field
Modules > Vulnerabilities > Inventory: Type a simple field search and this should return the expected results
Modules > Vulnerabilities > Inventory: Type a complex field search and this should return the expected results
Modules > Vulnerabilities > Inventory: Click in the package name of Summary panel, it should add a filter to the search bar and the table should be filtered
Modules > Vulnerabilities > Inventory: Click in the severity KPI of panel, it should add a filter to the search bar and the table should be filtered
Modules > MITRE ATT&CK > Intelligence > Groups: For each suggested field, check the value suggestion display results or at least doesn't break
Modules > MITRE ATT&CK > Intelligence > Groups: Using a value suggested should allow to run the search
Modules > MITRE ATT&CK > Intelligence > Groups: Type a term and run the search should search in each displayed field
Modules > MITRE ATT&CK > Intelligence > Groups: Type a simple field search and this should return the expected results
Modules > MITRE ATT&CK > Intelligence > Groups: Type a complex field search and this should return the expected results
Modules > MITRE ATT&CK > Intelligence > Mitigations: For each suggested field, check the value suggestion display results or at least doesn't break
Modules > MITRE ATT&CK > Intelligence > Mitigations: Using a value suggested should allow to run the search
Modules > MITRE ATT&CK > Intelligence > Mitigations: Type a term and run the search should search in each displayed field
Modules > MITRE ATT&CK > Intelligence > Mitigations: Type a simple field search and this should returns the expected results
Modules > MITRE ATT&CK > Intelligence > Mitigations: Type a complex field search and this should returns the expected results
Modules > MITRE ATT&CK > Intelligence > Software: For each suggested field, check the value suggestion display results or at least doesn't break
Modules > MITRE ATT&CK > Intelligence > Software: Using a value suggested should allow to run the search
Modules > MITRE ATT&CK > Intelligence > Software: Type a term and run the search should search in each displayed field
Modules > MITRE ATT&CK > Intelligence > Software: Type a simple field search and this should returns the expected results
Modules > MITRE ATT&CK > Intelligence > Software: Type a complex field search and this should returns the expected results
Modules > MITRE ATT&CK > Intelligence > Tactics: For each suggested field, check the value suggestion display results or at least doesn't break
Modules > MITRE ATT&CK > Intelligence > Tactics: Using a value suggested should allow to run the search
Modules > MITRE ATT&CK > Intelligence > Tactics: Type a term and run the search should search in each displayed field
Modules > MITRE ATT&CK > Intelligence > Tactics: Type a simple field search and this should returns the expected results
Modules > MITRE ATT&CK > Intelligence > Tactics: Type a complex field search and this should returns the expected results
Modules > MITRE ATT&CK > Intelligence > Techniques: For each suggested field, check the value suggestion display results or at least doesn't break
Modules > MITRE ATT&CK > Intelligence > Techniques: Using a value suggested should allow to run the search
Modules > MITRE ATT&CK > Intelligence > Techniques: Type a term and run the search should search in each displayed field
Modules > MITRE ATT&CK > Intelligence > Techniques: Type a simple field search and this should returns the expected results
Modules > MITRE ATT&CK > Intelligence > Techniques: Type a complex field search and this should returns the expected results
Management > CDB Lists: For each suggested field, check the value suggestion display results or at least doesn't break
Management > CDB Lists: Using a value suggested should allow to run the search
Management > CDB Lists: Type a term and run the search should search in each displayed field
Management > CDB Lists: Type a simple field search and this should returns the expected results
Management > CDB Lists: Type a complex field search and this should returns the expected results
Management > Decoders: For each suggested field, check the value suggestion display results or at least doesn't break
Management > Decoders: Using a value suggested should allow to run the search
Management > Decoders: Type a term and run the search should search in each displayed field
Management > Decoders: Type a simple field search and this should returns the expected results
Management > Decoders: Type a complex field search and this should returns the expected results
Management > Decoders > Files: For each suggested field, check the value suggestion display results or at least doesn't break
Management > Decoders > Files: Using a value suggested should allow to run the search
Management > Decoders > Files: Type a term and run the search should search in each displayed field
Management > Decoders > Files: Type a simple field search and this should returns the expected results
Management > Decoders > Files: Type a complex field search and this should returns the expected results
Management > Rules: For each suggested field, check the value suggestion display results or at least doesn't break
Management > Rules: Using a value suggested should allow to run the search
Management > Rules: Type a term and run the search should search in each displayed field
Management > Rules: Type a simple field search and this should returns the expected results
Management > Rules: Type a complex field search and this should returns the expected results
Management > Rules: Click on a filter from the rule detail flyout, the filter should be added to the search bar and the table should be filtered
Management > Rules > Files: For each suggested field, check the value suggestion display results or at least doesn't break
Management > Rules > Files: Using a value suggested should allow to run the search
Management > Rules > Files: Type a term and run the search should search in each displayed field
Management > Rules > Files: Type a simple field search and this should returns the expected results
Management > Rules > Files: Type a complex field search and this should returns the expected results

Details

⚫ Modules > Security Configuration Assessment > {policy_id} > Checks: For each suggested field, check the value suggestion display results or at least doesn't break

Chrome - ⚫

Firefox - ⚫

Safari - ⚫

⚫ Modules > Security Configuration Assessment > {policy_id} > Checks: Using a value suggested should allow to run the search

Chrome - ⚫

Firefox - ⚫

Safari - ⚫

⚫ Modules > Security Configuration Assessment > {policy_id} > Checks: Type a term and run the search should search in each displayed field

Chrome - ⚫

Firefox - ⚫

Safari - ⚫

⚫ Modules > Security Configuration Assessment > {policy_id} > Checks: Type a simple field search and this should return the expected results

Chrome - ⚫

Firefox - ⚫

Safari - ⚫

⚫ Modules > Security Configuration Assessment > {policy_id} > Checks: Type a complex field search and this should return the expected results

Chrome - ⚫

Firefox - ⚫

Safari - ⚫

⚫ Modules > Security Configuration Assessment > {policy_id} > Checks: Click in the result KPI, it should add a filter to the search bar and the table should be filtered

Chrome - ⚫

Firefox - ⚫

Safari - ⚫

⚫ Modules > Vulnerabilities > Inventory: For each suggested field, check the value suggestion display results or at least doesn't break

Chrome - ⚫

Firefox - ⚫

Safari - ⚫

⚫ Modules > Vulnerabilities > Inventory: Using a value suggested should allow to run the search

Chrome - ⚫

Firefox - ⚫

Safari - ⚫

⚫ Modules > Vulnerabilities > Inventory: Type a term and run the search should search in each displayed field

Chrome - ⚫

Firefox - ⚫

Safari - ⚫

⚫ Modules > Vulnerabilities > Inventory: Type a simple field search and this should return the expected results

Chrome - ⚫

Firefox - ⚫

Safari - ⚫

⚫ Modules > Vulnerabilities > Inventory: Type a complex field search and this should return the expected results

Chrome - ⚫

Firefox - ⚫

Safari - ⚫

⚫ Modules > Vulnerabilities > Inventory: Click in the package name of Summary panel, it should add a filter to the search bar and the table should be filtered

Chrome - ⚫

Firefox - ⚫

Safari - ⚫

⚫ Modules > Vulnerabilities > Inventory: Click in the severity KPI of panel, it should add a filter to the search bar and the table should be filtered

Chrome - ⚫

Firefox - ⚫

Safari - ⚫

⚫ Modules > MITRE ATT&CK > Intelligence > Groups: For each suggested field, check the value suggestion display results or at least doesn't break

Chrome - ⚫

Firefox - ⚫

Safari - ⚫

⚫ Modules > MITRE ATT&CK > Intelligence > Groups: Using a value suggested should allow to run the search

Chrome - ⚫

Firefox - ⚫

Safari - ⚫

⚫ Modules > MITRE ATT&CK > Intelligence > Groups: Type a term and run the search should search in each displayed field

Chrome - ⚫

Firefox - ⚫

Safari - ⚫

⚫ Modules > MITRE ATT&CK > Intelligence > Groups: Type a simple field search and this should return the expected results

Chrome - ⚫

Firefox - ⚫

Safari - ⚫

⚫ Modules > MITRE ATT&CK > Intelligence > Groups: Type a complex field search and this should return the expected results

Chrome - ⚫

Firefox - ⚫

Safari - ⚫

⚫ Modules > MITRE ATT&CK > Intelligence > Mitigations: For each suggested field, check the value suggestion display results or at least doesn't break

Chrome - ⚫

Firefox - ⚫

Safari - ⚫

⚫ Modules > MITRE ATT&CK > Intelligence > Mitigations: Using a value suggested should allow to run the search

Chrome - ⚫

Firefox - ⚫

Safari - ⚫

⚫ Modules > MITRE ATT&CK > Intelligence > Mitigations: Type a term and run the search should search in each displayed field

Chrome - ⚫

Firefox - ⚫

Safari - ⚫

⚫ Modules > MITRE ATT&CK > Intelligence > Mitigations: Type a simple field search and this should returns the expected results

Chrome - ⚫

Firefox - ⚫

Safari - ⚫

⚫ Modules > MITRE ATT&CK > Intelligence > Mitigations: Type a complex field search and this should returns the expected results

Chrome - ⚫

Firefox - ⚫

Safari - ⚫

⚫ Modules > MITRE ATT&CK > Intelligence > Software: For each suggested field, check the value suggestion display results or at least doesn't break

Chrome - ⚫

Firefox - ⚫

Safari - ⚫

⚫ Modules > MITRE ATT&CK > Intelligence > Software: Using a value suggested should allow to run the search

Chrome - ⚫

Firefox - ⚫

Safari - ⚫

⚫ Modules > MITRE ATT&CK > Intelligence > Software: Type a term and run the search should search in each displayed field

Chrome - ⚫

Firefox - ⚫

Safari - ⚫

⚫ Modules > MITRE ATT&CK > Intelligence > Software: Type a simple field search and this should returns the expected results

Chrome - ⚫

Firefox - ⚫

Safari - ⚫

⚫ Modules > MITRE ATT&CK > Intelligence > Software: Type a complex field search and this should returns the expected results

Chrome - ⚫

Firefox - ⚫

Safari - ⚫

⚫ Modules > MITRE ATT&CK > Intelligence > Tactics: For each suggested field, check the value suggestion display results or at least doesn't break

Chrome - ⚫

Firefox - ⚫

Safari - ⚫

⚫ Modules > MITRE ATT&CK > Intelligence > Tactics: Using a value suggested should allow to run the search

Chrome - ⚫

Firefox - ⚫

Safari - ⚫

⚫ Modules > MITRE ATT&CK > Intelligence > Tactics: Type a term and run the search should search in each displayed field

Chrome - ⚫

Firefox - ⚫

Safari - ⚫

⚫ Modules > MITRE ATT&CK > Intelligence > Tactics: Type a simple field search and this should returns the expected results

Chrome - ⚫

Firefox - ⚫

Safari - ⚫

⚫ Modules > MITRE ATT&CK > Intelligence > Tactics: Type a complex field search and this should returns the expected results

Chrome - ⚫

Firefox - ⚫

Safari - ⚫

⚫ Modules > MITRE ATT&CK > Intelligence > Techniques: For each suggested field, check the value suggestion display results or at least doesn't break

Chrome - ⚫

Firefox - ⚫

Safari - ⚫

⚫ Modules > MITRE ATT&CK > Intelligence > Techniques: Using a value suggested should allow to run the search

Chrome - ⚫

Firefox - ⚫

Safari - ⚫

⚫ Modules > MITRE ATT&CK > Intelligence > Techniques: Type a term and run the search should search in each displayed field

Chrome - ⚫

Firefox - ⚫

Safari - ⚫

⚫ Modules > MITRE ATT&CK > Intelligence > Techniques: Type a simple field search and this should returns the expected results

Chrome - ⚫

Firefox - ⚫

Safari - ⚫

⚫ Modules > MITRE ATT&CK > Intelligence > Techniques: Type a complex field search and this should returns the expected results

Chrome - ⚫

Firefox - ⚫

Safari - ⚫

⚫ Management > CDB Lists: For each suggested field, check the value suggestion display results or at least doesn't break

Chrome - ⚫

Firefox - ⚫

Safari - ⚫

⚫ Management > CDB Lists: Using a value suggested should allow to run the search

Chrome - ⚫

Firefox - ⚫

Safari - ⚫

⚫ Management > CDB Lists: Type a term and run the search should search in each displayed field

Chrome - ⚫

Firefox - ⚫

Safari - ⚫

⚫ Management > CDB Lists: Type a simple field search and this should returns the expected results

Chrome - ⚫

Firefox - ⚫

Safari - ⚫

⚫ Management > CDB Lists: Type a complex field search and this should returns the expected results

Chrome - ⚫

Firefox - ⚫

Safari - ⚫

⚫ Management > Decoders: For each suggested field, check the value suggestion display results or at least doesn't break

Chrome - ⚫

Firefox - ⚫

Safari - ⚫

⚫ Management > Decoders: Using a value suggested should allow to run the search

Chrome - ⚫

Firefox - ⚫

Safari - ⚫

⚫ Management > Decoders: Type a term and run the search should search in each displayed field

Chrome - ⚫

Firefox - ⚫

Safari - ⚫

⚫ Management > Decoders: Type a simple field search and this should returns the expected results

Chrome - ⚫

Firefox - ⚫

Safari - ⚫

⚫ Management > Decoders: Type a complex field search and this should returns the expected results

Chrome - ⚫

Firefox - ⚫

Safari - ⚫

⚫ Management > Decoders > Files: For each suggested field, check the value suggestion display results or at least doesn't break

Chrome - ⚫

Firefox - ⚫

Safari - ⚫

⚫ Management > Decoders > Files: Using a value suggested should allow to run the search

Chrome - ⚫

Firefox - ⚫

Safari - ⚫

⚫ Management > Decoders > Files: Type a term and run the search should search in each displayed field

Chrome - ⚫

Firefox - ⚫

Safari - ⚫

⚫ Management > Decoders > Files: Type a simple field search and this should returns the expected results

Chrome - ⚫

Firefox - ⚫

Safari - ⚫

⚫ Management > Decoders > Files: Type a complex field search and this should returns the expected results

Chrome - ⚫

Firefox - ⚫

Safari - ⚫

⚫ Management > Rules: For each suggested field, check the value suggestion display results or at least doesn't break

Chrome - ⚫

Firefox - ⚫

Safari - ⚫

⚫ Management > Rules: Using a value suggested should allow to run the search

Chrome - ⚫

Firefox - ⚫

Safari - ⚫

⚫ Management > Rules: Type a term and run the search should search in each displayed field

Chrome - ⚫

Firefox - ⚫

Safari - ⚫

⚫ Management > Rules: Type a simple field search and this should returns the expected results

Chrome - ⚫

Firefox - ⚫

Safari - ⚫

⚫ Management > Rules: Type a complex field search and this should returns the expected results

Chrome - ⚫

Firefox - ⚫

Safari - ⚫

⚫ Management > Rules: Click on a filter from the rule detail flyout, the filter should be added to the search bar and the table should be filtered

Chrome - ⚫

Firefox - ⚫

Safari - ⚫

⚫ Management > Rules > Files: For each suggested field, check the value suggestion display results or at least doesn't break

Chrome - ⚫

Firefox - ⚫

Safari - ⚫

⚫ Management > Rules > Files: Using a value suggested should allow to run the search

Chrome - ⚫

Firefox - ⚫

Safari - ⚫

⚫ Management > Rules > Files: Type a term and run the search should search in each displayed field

Chrome - ⚫

Firefox - ⚫

Safari - ⚫

⚫ Management > Rules > Files: Type a simple field search and this should returns the expected results

Chrome - ⚫

Firefox - ⚫

Safari - ⚫

⚫ Management > Rules > Files: Type a complex field search and this should returns the expected results

Chrome - ⚫

Firefox - ⚫

Safari - ⚫

Check List

  • All tests pass
    • yarn test:jest
  • New functionality includes testing.
  • New functionality has been documented.
  • Update CHANGELOG.md
  • Commits are signed per the DCO using --signoff

Desvelao and others added 30 commits February 16, 2023 12:50
Features:
- Supports multiple query languages
- Decouple the business logic of query languages of the search bar
  component
- Ability of query language to interact with the search bar

Query language implementations
- AQL: custom implementation of the Wazuh Query Language. Include
  suggestions.
- UIQL: simple implementation (as another example)
…ression used in the Wazuh manager API

- Change the implementation of AQL query language to use the regular
  expression decomposition defined in the Wazuh manager API
- Adapt the tests for the tokenizer and getting the suggestions
- Enchance documentation of search bar
- Add documentation of AQL query language
- Add more fields and values for the use example in Agents section
- Add description to the query language select input
…using the Search suggestion in AQL

- Fixes a problem hidding the suggestion popover when using the Search
  suggestion in AQL
- Fixes a problem of input text with undefined value
- Minor fixes
  - Remove `syntax` property of SearchBar component
  - Add disableFocusTrap property to the custom EuiSuggestInput component to be
    forwarded to the EuiInputPopover
  - Replace the inputRef by a reference instead of a state and pass as
    a parameter in the query language run function
  - Move the rebuiding of input text when using some suggestion that changes
    the input to be done when a related suggestion was clicked instead
    of any suggestion (exclude Search).
implemenation

- Add the ability to update the input of the search bar in the example
  implementation
- Enhance the component documentation
- (AQL) Add the fields and an open operator group when there is no input text
link of query language displayed in the popover
- AQL enhancements:
  - documentation:
    - Enhance some descriptions
    - Enhance input processing
    - Remove intermetiate interface of EuiSuggestItem
  - Remove the intermediate interface of EuiSuggestItem. Now it is
    managed in the internal of query language instead of be built by the
    suggestion handler
  - Display suggestions when the input text is empty
  - Add the unifiedQuery field to the query language output
  - Adapt tests

- Search Bar component:
  - Enhance documentation
- Remove UIQL
- Add HAQL query language that is a high-level implementation of AQL
  - Add the query language interface
  - Add tests for tokenizer, get suggestions and
    transformSpecificQLToUnifiedQL method
  - Add documentation about the language
    - Syntax
    - Options
    - Workflow
- Add tests to HAQL and AQL query languages
- Fix suggestions for HAQL when typing as first element a value entity.
  Now there are no suggestions because the field and operator_compare
  are missing.
- Enhance documentation of HAQL and AQL
- Removed unnecesary returns of suggestion handler in the example
  implementation of search bar on Agents section
- Rename query language HAQL to WQL
- Update tests
- Remove AQL usage from the implementation in the agents section
- Add more use cases to the test of WQL query language
- Replace some literals by constants in the WQL query language
  implementation
- WQL
  - add implicit query mode to WQL
  - enhance query language documentation
  - renamed transformUnifiedQuery to transformUQLToQL
  - now wraps the user input if this is defined and there a implicit
    query string
  - fix a problem with the value suggestions if there is a previous
    conjunction
    - add tests cases
  - update tests
- AQL
  - enhance query language documentation
  - renamed transformUnifiedQuery to transformUQLToQL
  - add warning about the query language implementation is not updated
    to the last changes in the search bar component
  - update tests

- Search Bar
  - renamed transformUnifiedQuery to transformUQLToQL
- Set a width for the syntax options popover
- Unify the description in the suggestions of WQL example implementation
- Update tests
- Fix minor bugs in the WQL example implementation in Agents
- WQL
  - Enhance documentation
  - Add partial and "expanded" input validation
  - Add tests
…feat/4312-poc-search-bar-component-multiple-query-language-api-query-language-implementation
Fix an error when the last token in the input was a value and used
a value suggestion whose label contains whitespaces, the value was
not wrapped with quotes.
…uery-language-api-query-language-implementation
…uery-language-api-query-language-implementation
…earch term fields changed

- Search bar:
  - Add a dependency to run the query language output
  - Adapt search bar documentation to the changes
- WQL
  - Create a new parameter called `options`
  - Moved the `implicitFilter` and `searchTerm` settings to `options`
  - Update tests
  - Update documentation
@Desvelao Desvelao force-pushed the feat/4312-search-bar-replace-tablewzapi branch from 1885985 to eee2bb6 Compare August 8, 2023 08:08
When getting the distinct values for some fields, the value could not
match the regular expression that validates them, and this causes that
the search can not be run. So, we filters the distinct values to ensure
or reduce the suggestions can be used to search. This causes some
possible values are not displayed in the suggestions. To undone this,
then the API should allow these values.
@Desvelao
Copy link
Member Author

Desvelao commented Aug 8, 2023

Changes

  • Add a workaround to the value suggestions. It will only display the values that match the validation regular expression. This mitigates the problems caused when using these values, and they don't match the validation, avoiding the search can be run. Related to New search bar component #4312 (comment).

@Desvelao Desvelao marked this pull request as ready for review August 9, 2023 08:01
@yenienserrano
Copy link
Member

yenienserrano commented Aug 9, 2023

Test

Use a Wazuh manager

Legend:
⚫: none
🟢: pass
🟡: warning
🔴: fail
⚪: not applicable

UI

Test Chrome Firefox Safari
Modules > Security Configuration Assessment > {policy_id} > Checks: For each suggested field, check the value suggestion display results or at least doesn't break 🟡
Modules > Security Configuration Assessment > {policy_id} > Checks: Using a value suggested should allow to run the search 🟡
Modules > Security Configuration Assessment > {policy_id} > Checks: Type a term and run the search should search in each displayed field 🟡
Modules > Security Configuration Assessment > {policy_id} > Checks: Type a simple field search and this should return the expected results 🟡
Modules > Security Configuration Assessment > {policy_id} > Checks: Type a complex field search and this should return the expected results 🟡
Modules > Security Configuration Assessment > {policy_id} > Checks: Click in the result KPI, it should add a filter to the search bar and the table should be filtered 🟢
Modules > Vulnerabilities > Inventory: For each suggested field, check the value suggestion display results or at least doesn't break 🟢
Modules > Vulnerabilities > Inventory: Using a value suggested should allow to run the search 🟢
Modules > Vulnerabilities > Inventory: Type a term and run the search should search in each displayed field 🟢
Modules > Vulnerabilities > Inventory: Type a simple field search and this should return the expected results 🟢
Modules > Vulnerabilities > Inventory: Type a complex field search and this should return the expected results 🟢
Modules > Vulnerabilities > Inventory: Click in the package name of Summary panel, it should add a filter to the search bar and the table should be filtered 🟢
Modules > Vulnerabilities > Inventory: Click in the severity KPI of panel, it should add a filter to the search bar and the table should be filtered 🟢
Modules > MITRE ATT&CK > Intelligence > Groups: For each suggested field, check the value suggestion display results or at least doesn't break 🟢
Modules > MITRE ATT&CK > Intelligence > Groups: Using a value suggested should allow to run the search 🟢
Modules > MITRE ATT&CK > Intelligence > Groups: Type a term and run the search should search in each displayed field 🟢
Modules > MITRE ATT&CK > Intelligence > Groups: Type a simple field search and this should return the expected results 🟢
Modules > MITRE ATT&CK > Intelligence > Groups: Type a complex field search and this should return the expected results 🟢
Modules > MITRE ATT&CK > Intelligence > Mitigations: For each suggested field, check the value suggestion display results or at least doesn't break 🟢
Modules > MITRE ATT&CK > Intelligence > Mitigations: Using a value suggested should allow to run the search 🟢
Modules > MITRE ATT&CK > Intelligence > Mitigations: Type a term and run the search should search in each displayed field 🟢
Modules > MITRE ATT&CK > Intelligence > Mitigations: Type a simple field search and this should returns the expected results 🟢
Modules > MITRE ATT&CK > Intelligence > Mitigations: Type a complex field search and this should returns the expected results 🟢
Modules > MITRE ATT&CK > Intelligence > Software: For each suggested field, check the value suggestion display results or at least doesn't break 🟢
Modules > MITRE ATT&CK > Intelligence > Software: Using a value suggested should allow to run the search 🟢
Modules > MITRE ATT&CK > Intelligence > Software: Type a term and run the search should search in each displayed field 🟢
Modules > MITRE ATT&CK > Intelligence > Software: Type a simple field search and this should returns the expected results 🟡
Modules > MITRE ATT&CK > Intelligence > Software: Type a complex field search and this should returns the expected results 🟡
Modules > MITRE ATT&CK > Intelligence > Tactics: For each suggested field, check the value suggestion display results or at least doesn't break 🟢
Modules > MITRE ATT&CK > Intelligence > Tactics: Using a value suggested should allow to run the search 🟢
Modules > MITRE ATT&CK > Intelligence > Tactics: Type a term and run the search should search in each displayed field 🟢
Modules > MITRE ATT&CK > Intelligence > Tactics: Type a simple field search and this should returns the expected results 🟢
Modules > MITRE ATT&CK > Intelligence > Tactics: Type a complex field search and this should returns the expected results 🟢
Modules > MITRE ATT&CK > Intelligence > Techniques: For each suggested field, check the value suggestion display results or at least doesn't break 🟢
Modules > MITRE ATT&CK > Intelligence > Techniques: Using a value suggested should allow to run the search 🟢
Modules > MITRE ATT&CK > Intelligence > Techniques: Type a term and run the search should search in each displayed field 🟢
Modules > MITRE ATT&CK > Intelligence > Techniques: Type a simple field search and this should returns the expected results 🟢
Modules > MITRE ATT&CK > Intelligence > Techniques: Type a complex field search and this should returns the expected results 🟢
Management > CDB Lists: For each suggested field, check the value suggestion display results or at least doesn't break 🟢
Management > CDB Lists: Using a value suggested should allow to run the search 🟢
Management > CDB Lists: Type a term and run the search should search in each displayed field 🟢
Management > CDB Lists: Type a simple field search and this should returns the expected results 🟢
Management > CDB Lists: Type a complex field search and this should returns the expected results 🟢
Management > Decoders: For each suggested field, check the value suggestion display results or at least doesn't break 🟢
Management > Decoders: Using a value suggested should allow to run the search 🟢
Management > Decoders: Type a term and run the search should search in each displayed field 🟢
Management > Decoders: Type a simple field search and this should returns the expected results 🟢
Management > Decoders: Type a complex field search and this should returns the expected results 🟢
Management > Decoders > Files: For each suggested field, check the value suggestion display results or at least doesn't break 🟢
Management > Decoders > Files: Using a value suggested should allow to run the search 🟢
Management > Decoders > Files: Type a term and run the search should search in each displayed field 🟢
Management > Decoders > Files: Type a simple field search and this should returns the expected results 🟢
Management > Decoders > Files: Type a complex field search and this should returns the expected results 🟢
Management > Rules: For each suggested field, check the value suggestion display results or at least doesn't break 🟢
Management > Rules: Using a value suggested should allow to run the search 🟢
Management > Rules: Type a term and run the search should search in each displayed field 🟢
Management > Rules: Type a simple field search and this should returns the expected results 🟢
Management > Rules: Type a complex field search and this should returns the expected results 🟢
Management > Rules: Click on a filter from the rule detail flyout, the filter should be added to the search bar and the table should be filtered 🟢
Management > Rules > Files: For each suggested field, check the value suggestion display results or at least doesn't break 🟢
Management > Rules > Files: Using a value suggested should allow to run the search 🟢
Management > Rules > Files: Type a term and run the search should search in each displayed field 🟢
Management > Rules > Files: Type a simple field search and this should returns the expected results 🟢
Management > Rules > Files: Type a complex field search and this should returns the expected results 🟢

Details

🟡 Modules > Security Configuration Assessment > {policy_id} > Checks: For each suggested field, check the value suggestion display results or at least doesn't break

Chrome - 🟡

the only field that doesn't work is in condition=all, which is probably from API

Issue: wazuh/wazuh#18314

image

image

Firefox - ⚫

Safari - ⚫

:🟡 Modules > Security Configuration Assessment > {policy_id} > Checks: Using a value suggested should allow to run the search

Chrome - 🟡

the only field that doesn't work is in condition=all, which is probably from API

Issue: wazuh/wazuh#18314

image

image

Firefox - ⚫

Safari - ⚫

🟡 Modules > Security Configuration Assessment > {policy_id} > Checks: Type a term and run the search should search in each displayed field

Chrome - 🟡

the only field that doesn't work is in all, which is probably from API

Issue: wazuh/wazuh#18314

image

image

image

Firefox - ⚫

Safari - ⚫

🟡 Modules > Security Configuration Assessment > {policy_id} > Checks: Type a simple field search and this should return the expected results

Chrome - 🟡

the only field that doesn't work is in all, which is probably from API

Issue: wazuh/wazuh#18314

image

image

Firefox - ⚫

Safari - ⚫

🟡 Modules > Security Configuration Assessment > {policy_id} > Checks: Type a complex field search and this should return the expected results

Chrome - 🟡

the only field that doesn't work is in all, which is probably from API

Issue: wazuh/wazuh#18314

image

image

Firefox - ⚫

Safari - ⚫

🟢 Modules > Security Configuration Assessment > {policy_id} > Checks: Click in the result KPI, it should add a filter to the search bar and the table should be filtered

Chrome - 🟢

image

image

image

Firefox - ⚫

Safari - ⚫

🟢 Modules > Vulnerabilities > Inventory: For each suggested field, check the value suggestion display results or at least doesn't break

Chrome - 🟢

image

Firefox - ⚫

Safari - ⚫

🟢 Modules > Vulnerabilities > Inventory: Using a value suggested should allow to run the search

Chrome - 🟢

image

Firefox - ⚫

Safari - ⚫

🟢 Modules > Vulnerabilities > Inventory: Type a term and run the search should search in each displayed field

Chrome - 🟢

image

Firefox - ⚫

Safari - ⚫

🟢 Modules > Vulnerabilities > Inventory: Type a simple field search and this should return the expected results

Chrome - 🟢

image

Firefox - ⚫

Safari - ⚫

🟢 Modules > Vulnerabilities > Inventory: Type a complex field search and this should return the expected results

Chrome - 🟢

image

Firefox - ⚫

Safari - ⚫

🟢 Modules > Vulnerabilities > Inventory: Click in the package name of Summary panel, it should add a filter to the search bar and the table should be filtered

Chrome - 🟢

image

image

Firefox - ⚫

Safari - ⚫

🟢 Modules > Vulnerabilities > Inventory: Click in the severity KPI of panel, it should add a filter to the search bar and the table should be filtered

Chrome - 🟢

image

image

image

Firefox - ⚫

Safari - ⚫

⚫ Modules > MITRE ATT&CK > Intelligence > Groups: For each suggested field, check the value suggestion display results or at least doesn't break

Chrome - 🟢

image

Firefox - ⚫

Safari - ⚫

🟢 Modules > MITRE ATT&CK > Intelligence > Groups: Using a value suggested should allow to run the search

Chrome - 🟢

image

Firefox - ⚫

Safari - ⚫

🟢 Modules > MITRE ATT&CK > Intelligence > Groups: Type a term and run the search should search in each displayed field

Chrome - 🟢

image

Firefox - ⚫

Safari - ⚫

🟢 Modules > MITRE ATT&CK > Intelligence > Groups: Type a simple field search and this should return the expected results

Chrome - 🟢

image

Firefox - ⚫

Safari - ⚫

🟢 Modules > MITRE ATT&CK > Intelligence > Groups: Type a complex field search and this should return the expected results

Chrome - 🟢

image

Firefox - ⚫

Safari - ⚫

🟢 Modules > MITRE ATT&CK > Intelligence > Mitigations: For each suggested field, check the value suggestion display results or at least doesn't break

Chrome - 🟢

image

Firefox - ⚫

Safari - ⚫

🟢 Modules > MITRE ATT&CK > Intelligence > Mitigations: Using a value suggested should allow to run the search

Chrome - 🟢

image

Firefox - ⚫

Safari - ⚫

🟢 Modules > MITRE ATT&CK > Intelligence > Mitigations: Type a term and run the search should search in each displayed field

Chrome - 🟢

image

Firefox - ⚫

Safari - ⚫

🟢 Modules > MITRE ATT&CK > Intelligence > Mitigations: Type a simple field search and this should returns the expected results

Chrome - 🟢

image

Firefox - ⚫

Safari - ⚫

🟢 Modules > MITRE ATT&CK > Intelligence > Mitigations: Type a complex field search and this should returns the expected results

Chrome - 🟢

image

Firefox - ⚫

Safari - ⚫

🟢 Modules > MITRE ATT&CK > Intelligence > Software: For each suggested field, check the value suggestion display results or at least doesn't break

Chrome - 🟢

image

Firefox - ⚫

Safari - ⚫

🟢 Modules > MITRE ATT&CK > Intelligence > Software: Using a value suggested should allow to run the search

Chrome - 🟢

image

Firefox - ⚫

Safari - ⚫

🟢 Modules > MITRE ATT&CK > Intelligence > Software: Type a term and run the search should search in each displayed field

Chrome - 🟢

image

Firefox - ⚫

Safari - ⚫

🟡 Modules > MITRE ATT&CK > Intelligence > Software: Type a simple field search and this should returns the expected results

Chrome - 🟡

with parenthesis the request fails

image

image

Firefox - ⚫

Safari - ⚫

🟡 Modules > MITRE ATT&CK > Intelligence > Software: Type a complex field search and this should returns the expected results

Chrome - 🟡

with parenthesis the request fails

image

image

Firefox - ⚫

Safari - ⚫

🟢 Modules > MITRE ATT&CK > Intelligence > Tactics: For each suggested field, check the value suggestion display results or at least doesn't break

Chrome - 🟢

image

Firefox - ⚫

Safari - ⚫

🟢 Modules > MITRE ATT&CK > Intelligence > Tactics: Using a value suggested should allow to run the search

Chrome - 🟢

image

Firefox - ⚫

Safari - ⚫

🟢 Modules > MITRE ATT&CK > Intelligence > Tactics: Type a term and run the search should search in each displayed field

Chrome - 🟢

image

Firefox - ⚫

Safari - ⚫

🟢 Modules > MITRE ATT&CK > Intelligence > Tactics: Type a simple field search and this should returns the expected results

Chrome - 🟢

image

Firefox - ⚫

Safari - ⚫

🟢 Modules > MITRE ATT&CK > Intelligence > Tactics: Type a complex field search and this should returns the expected results

Chrome - 🟢

image

Firefox - ⚫

Safari - ⚫

🟢 Modules > MITRE ATT&CK > Intelligence > Techniques: For each suggested field, check the value suggestion display results or at least doesn't break

Chrome - 🟢

image

Firefox - ⚫

Safari - ⚫

🟢 Modules > MITRE ATT&CK > Intelligence > Techniques: Using a value suggested should allow to run the search

Chrome - 🟢

image

Firefox - ⚫

Safari - ⚫

🟢 Modules > MITRE ATT&CK > Intelligence > Techniques: Type a term and run the search should search in each displayed field

Chrome - 🟢

image

Firefox - ⚫

Safari - ⚫

🟢 Modules > MITRE ATT&CK > Intelligence > Techniques: Type a simple field search and this should returns the expected results

Chrome - 🟢

image

Firefox - ⚫

Safari - ⚫

🟢 Modules > MITRE ATT&CK > Intelligence > Techniques: Type a complex field search and this should returns the expected results

Chrome - 🟢

image

Firefox - ⚫

Safari - ⚫

🟢 Management > CDB Lists: For each suggested field, check the value suggestion display results or at least doesn't break

Chrome - 🟢

image

Firefox - ⚫

Safari - ⚫

🟢 Management > CDB Lists: Using a value suggested should allow to run the search

Chrome - 🟢

image

Firefox - ⚫

Safari - ⚫

🟢 Management > CDB Lists: Type a term and run the search should search in each displayed field

Chrome - 🟢

image

Firefox - ⚫

Safari - ⚫

🟢 Management > CDB Lists: Type a simple field search and this should returns the expected results

Chrome - 🟢

image

Firefox - ⚫

Safari - ⚫

🟢 Management > CDB Lists: Type a complex field search and this should returns the expected results

Chrome - 🟢

image

Firefox - ⚫

Safari - ⚫

🟢 Management > Decoders: For each suggested field, check the value suggestion display results or at least doesn't break

Chrome - 🟢

image

Firefox - ⚫

Safari - ⚫

🟢 Management > Decoders: Using a value suggested should allow to run the search

Chrome - 🟢

image

Firefox - ⚫

Safari - ⚫

🟢 Management > Decoders: Type a term and run the search should search in each displayed field

Chrome - 🟢

image

Firefox - ⚫

Safari - ⚫

🟢 Management > Decoders: Type a simple field search and this should returns the expected results

Chrome - 🟢

image

Firefox - ⚫

Safari - ⚫

🟢 Management > Decoders: Type a complex field search and this should returns the expected results

Chrome - 🟢

image

Firefox - ⚫

Safari - ⚫

🟢 Management > Decoders > Files: For each suggested field, check the value suggestion display results or at least doesn't break

Chrome - 🟢

image

Firefox - ⚫

Safari - ⚫

🟢 Management > Decoders > Files: Using a value suggested should allow to run the search

Chrome - 🟢

image

Firefox - ⚫

Safari - ⚫

🟢 Management > Decoders > Files: Type a term and run the search should search in each displayed field

Chrome - 🟢

image

Firefox - ⚫

Safari - ⚫

🟢 Management > Decoders > Files: Type a simple field search and this should returns the expected results

Chrome - 🟢

image

Firefox - ⚫

Safari - ⚫

🟢 Management > Decoders > Files: Type a complex field search and this should returns the expected results

Chrome - 🟢

image

Firefox - ⚫

Safari - ⚫

🟢 Management > Rules: For each suggested field, check the value suggestion display results or at least doesn't break

Chrome - 🟢

image

Firefox - ⚫

Safari - ⚫

🟢 Management > Rules: Using a value suggested should allow to run the search

Chrome - 🟢

image

Firefox - ⚫

Safari - ⚫

🟢 Management > Rules: Type a term and run the search should search in each displayed field

Chrome - 🟢

image

Firefox - ⚫

Safari - ⚫

🟢 Management > Rules: Type a simple field search and this should returns the expected results

Chrome - 🟢

image

Firefox - ⚫

Safari - ⚫

🟢 Management > Rules: Type a complex field search and this should returns the expected results

Chrome - 🟢

image

Firefox - ⚫

Safari - ⚫

🟢 Management > Rules: Click on a filter from the rule detail flyout, the filter should be added to the search bar and the table should be filtered

Chrome - 🟢

image

Firefox - ⚫

Safari - ⚫

🟢 Management > Rules > Files: For each suggested field, check the value suggestion display results or at least doesn't break

Chrome - 🟢

image

Firefox - ⚫

Safari - ⚫

🟢 Management > Rules > Files: Using a value suggested should allow to run the search

Chrome - 🟢

image

Firefox - ⚫

Safari - ⚫

🟢 Management > Rules > Files: Type a term and run the search should search in each displayed field

Chrome - 🟢

image

Firefox - ⚫

Safari - ⚫

🟢 Management > Rules > Files: Type a simple field search and this should returns the expected results

Chrome - 🟢

image

Firefox - ⚫

Safari - ⚫

🟢 Management > Rules > Files: Type a complex field search and this should returns the expected results

Chrome - 🟢

image

Firefox - ⚫

Safari - ⚫

@JuanGarriuz JuanGarriuz self-requested a review August 9, 2023 10:07
@JuanGarriuz
Copy link
Member

JuanGarriuz commented Aug 9, 2023

Test

Use a Wazuh manager

Legend:
⚫: none
🟢: pass
🟡: warning
🔴: fail
⚪: not applicable

UI

Test Chrome Firefox Safari
Modules > Security Configuration Assessment > {policy_id} > Checks: For each suggested field, check the value suggestion display results or at least doesn't break 🟢
Modules > Security Configuration Assessment > {policy_id} > Checks: Using a value suggested should allow to run the search 🟢
Modules > Security Configuration Assessment > {policy_id} > Checks: Type a term and run the search should search in each displayed field 🟢
Modules > Security Configuration Assessment > {policy_id} > Checks: Type a simple field search and this should return the expected results 🟢
Modules > Security Configuration Assessment > {policy_id} > Checks: Type a complex field search and this should return the expected results 🟢
Modules > Security Configuration Assessment > {policy_id} > Checks: Click in the result KPI, it should add a filter to the search bar and the table should be filtered 🟢
Modules > Vulnerabilities > Inventory: For each suggested field, check the value suggestion display results or at least doesn't break 🟡
Modules > Vulnerabilities > Inventory: Using a value suggested should allow to run the search 🟢
Modules > Vulnerabilities > Inventory: Type a term and run the search should search in each displayed field 🟢
Modules > Vulnerabilities > Inventory: Type a simple field search and this should return the expected results 🟢
Modules > Vulnerabilities > Inventory: Type a complex field search and this should return the expected results 🟢
Modules > Vulnerabilities > Inventory: Click in the package name of Summary panel, it should add a filter to the search bar and the table should be filtered 🟢
Modules > Vulnerabilities > Inventory: Click in the severity KPI of panel, it should add a filter to the search bar and the table should be filtered 🟢
Modules > MITRE ATT&CK > Intelligence > Groups: For each suggested field, check the value suggestion display results or at least doesn't break 🟢
Modules > MITRE ATT&CK > Intelligence > Groups: Using a value suggested should allow to run the search 🟢
Modules > MITRE ATT&CK > Intelligence > Groups: Type a term and run the search should search in each displayed field 🟢
Modules > MITRE ATT&CK > Intelligence > Groups: Type a simple field search and this should return the expected results 🟢
Modules > MITRE ATT&CK > Intelligence > Groups: Type a complex field search and this should return the expected results 🟡
Modules > MITRE ATT&CK > Intelligence > Mitigations: For each suggested field, check the value suggestion display results or at least doesn't break 🟢
Modules > MITRE ATT&CK > Intelligence > Mitigations: Using a value suggested should allow to run the search 🟢
Modules > MITRE ATT&CK > Intelligence > Mitigations: Type a term and run the search should search in each displayed field 🟢
Modules > MITRE ATT&CK > Intelligence > Mitigations: Type a simple field search and this should returns the expected results 🟢
Modules > MITRE ATT&CK > Intelligence > Mitigations: Type a complex field search and this should returns the expected results 🟡
Modules > MITRE ATT&CK > Intelligence > Software: For each suggested field, check the value suggestion display results or at least doesn't break 🟢
Modules > MITRE ATT&CK > Intelligence > Software: Using a value suggested should allow to run the search 🟢
Modules > MITRE ATT&CK > Intelligence > Software: Type a term and run the search should search in each displayed field 🟢
Modules > MITRE ATT&CK > Intelligence > Software: Type a simple field search and this should returns the expected results 🟢
Modules > MITRE ATT&CK > Intelligence > Software: Type a complex field search and this should returns the expected results 🟡
Modules > MITRE ATT&CK > Intelligence > Tactics: For each suggested field, check the value suggestion display results or at least doesn't break 🟢
Modules > MITRE ATT&CK > Intelligence > Tactics: Using a value suggested should allow to run the search 🟢
Modules > MITRE ATT&CK > Intelligence > Tactics: Type a term and run the search should search in each displayed field 🟢
Modules > MITRE ATT&CK > Intelligence > Tactics: Type a simple field search and this should returns the expected results 🟢
Modules > MITRE ATT&CK > Intelligence > Tactics: Type a complex field search and this should returns the expected results 🟡
Modules > MITRE ATT&CK > Intelligence > Techniques: For each suggested field, check the value suggestion display results or at least doesn't break 🟢
Modules > MITRE ATT&CK > Intelligence > Techniques: Using a value suggested should allow to run the search 🟢
Modules > MITRE ATT&CK > Intelligence > Techniques: Type a term and run the search should search in each displayed field 🟢
Modules > MITRE ATT&CK > Intelligence > Techniques: Type a simple field search and this should returns the expected results 🟢
Modules > MITRE ATT&CK > Intelligence > Techniques: Type a complex field search and this should returns the expected results 🟡
Management > CDB Lists: For each suggested field, check the value suggestion display results or at least doesn't break 🟢
Management > CDB Lists: Using a value suggested should allow to run the search 🟢
Management > CDB Lists: Type a term and run the search should search in each displayed field 🟢
Management > CDB Lists: Type a simple field search and this should returns the expected results 🟢
Management > CDB Lists: Type a complex field search and this should returns the expected results 🟡
Management > Decoders: For each suggested field, check the value suggestion display results or at least doesn't break 🟢
Management > Decoders: Using a value suggested should allow to run the search 🟢
Management > Decoders: Type a term and run the search should search in each displayed field 🟢
Management > Decoders: Type a simple field search and this should returns the expected results 🟢
Management > Decoders: Type a complex field search and this should returns the expected results 🟡
Management > Decoders > Files: For each suggested field, check the value suggestion display results or at least doesn't break 🟢
Management > Decoders > Files: Using a value suggested should allow to run the search 🟢
Management > Decoders > Files: Type a term and run the search should search in each displayed field 🟢
Management > Decoders > Files: Type a simple field search and this should returns the expected results 🟢
Management > Decoders > Files: Type a complex field search and this should returns the expected results 🟡
Management > Rules: For each suggested field, check the value suggestion display results or at least doesn't break 🟢
Management > Rules: Using a value suggested should allow to run the search 🟢
Management > Rules: Type a term and run the search should search in each displayed field 🟢
Management > Rules: Type a simple field search and this should returns the expected results :🟢
Management > Rules: Type a complex field search and this should returns the expected results 🟡
Management > Rules: Click on a filter from the rule detail flyout, the filter should be added to the search bar and the table should be filtered 🟢
Management > Rules > Files: For each suggested field, check the value suggestion display results or at least doesn't break 🟢
Management > Rules > Files: Using a value suggested should allow to run the search 🟢
Management > Rules > Files: Type a term and run the search should search in each displayed field 🟢
Management > Rules > Files: Type a simple field search and this should returns the expected results 🟢
Management > Rules > Files: Type a complex field search and this should returns the expected results 🟡

Details

🟢 Modules > Security Configuration Assessment > {policy_id} > Checks: For each suggested field, check the value suggestion display results or at least doesn't break

Chrome - 🟢
image

Firefox - ⚫

Safari - ⚫

🟢 Modules > Security Configuration Assessment > {policy_id} > Checks: Using a value suggested should allow to run the search

Chrome - 🟢
image

Firefox - ⚫

Safari - ⚫

🟢 Modules > Security Configuration Assessment > {policy_id} > Checks: Type a term and run the search should search in each displayed field

Chrome - 🟢
image

🟢 Modules > Security Configuration Assessment > {policy_id} > Checks: Type a simple field search and this should return the expected results

Chrome - 🟢
image

Firefox - ⚫

Safari - ⚫

🟢 Modules > Security Configuration Assessment > {policy_id} > Checks: Type a complex field search and this should return the expected results

Chrome - 🟢
image

Firefox - ⚫

Safari - ⚫

🟢 Modules > Security Configuration Assessment > {policy_id} > Checks: Click in the result KPI, it should add a filter to the search bar and the table should be filtered

Chrome - 🟢
image

Firefox - ⚫

Safari - ⚫

🟡 Modules > Vulnerabilities > Inventory: For each suggested field, check the value suggestion display results or at least doesn't break

Chrome - 🟡
No suggested field values.
image

Firefox - ⚫

Safari - ⚫

🟢 Modules > Vulnerabilities > Inventory: Using a value suggested should allow to run the search

Chrome - 🟢
image

Firefox - ⚫

Safari - ⚫

🟢 Modules > Vulnerabilities > Inventory: Type a term and run the search should search in each displayed field

Chrome - 🟢
image

Firefox - ⚫

Safari - ⚫

🟢 Modules > Vulnerabilities > Inventory: Type a simple field search and this should return the expected results

Chrome - 🟢
image

Firefox - ⚫

Safari - ⚫

🟢 Modules > Vulnerabilities > Inventory: Type a complex field search and this should return the expected results

Chrome - 🟢
image

Firefox - ⚫

Safari - ⚫

🟢 Modules > Vulnerabilities > Inventory: Click in the package name of Summary panel, it should add a filter to the search bar and the table should be filtered

Chrome - 🟢
image

Firefox - ⚫

Safari - ⚫

🟢 Modules > Vulnerabilities > Inventory: Click in the severity KPI of panel, it should add a filter to the search bar and the table should be filtered

Chrome - 🟢
image

Firefox - ⚫

Safari - ⚫

🟢 Modules > MITRE ATT&CK > Intelligence > Groups: For each suggested field, check the value suggestion display results or at least doesn't break

Chrome - 🟢
image
image
Firefox - ⚫

Safari - ⚫

🟢 Modules > MITRE ATT&CK > Intelligence > Groups: Using a value suggested should allow to run the search

Chrome - 🟢
image

Firefox - ⚫

Safari - ⚫

🟢 Modules > MITRE ATT&CK > Intelligence > Groups: Type a term and run the search should search in each displayed field

Chrome - 🟢
image

Firefox - ⚫

Safari - ⚫

🟢 Modules > MITRE ATT&CK > Intelligence > Groups: Type a simple field search and this should return the expected results

Chrome - 🟢
image
Firefox - ⚫

Safari - ⚫

🟡 Modules > MITRE ATT&CK > Intelligence > Groups: Type a complex field search and this should return the expected results

Chrome - 🟡
Error in the query when I use parenthesis.

image

Firefox - ⚫

Safari - ⚫

🟢 Modules > MITRE ATT&CK > Intelligence > Mitigations: For each suggested field, check the value suggestion display results or at least doesn't break

Chrome - 🟢

Firefox - ⚫

Safari - ⚫

🟢 Modules > MITRE ATT&CK > Intelligence > Mitigations: Using a value suggested should allow to run the search

Chrome - 🟢
image

Firefox - ⚫

Safari - ⚫

🟢 Modules > MITRE ATT&CK > Intelligence > Mitigations: Type a term and run the search should search in each displayed field

Chrome - 🟢
image

Firefox - ⚫

Safari - ⚫

🟢 Modules > MITRE ATT&CK > Intelligence > Mitigations: Type a simple field search and this should returns the expected results

Chrome - 🟢

Firefox - ⚫

Safari - ⚫

🟡 Modules > MITRE ATT&CK > Intelligence > Mitigations: Type a complex field search and this should returns the expected results

Chrome - 🟡
Error in the query when I use parenthesis.
image
Firefox - ⚫

Safari - ⚫

🟢 Modules > MITRE ATT&CK > Intelligence > Software: For each suggested field, check the value suggestion display results or at least doesn't break

Chrome - 🟢

Firefox - ⚫

Safari - ⚫

🟢 Modules > MITRE ATT&CK > Intelligence > Software: Using a value suggested should allow to run the search

Chrome - 🟢
image

Firefox - ⚫

Safari - ⚫

🟢 Modules > MITRE ATT&CK > Intelligence > Software: Type a term and run the search should search in each displayed field

Chrome - 🟢

image

Firefox - ⚫

Safari - ⚫

🟢 Modules > MITRE ATT&CK > Intelligence > Software: Type a simple field search and this should returns the expected results

Chrome - 🟢
image

Firefox - ⚫

Safari - ⚫

🟡 Modules > MITRE ATT&CK > Intelligence > Software: Type a complex field search and this should returns the expected results

Chrome - 🟡
Error in the query when I use parenthesis.
image

Firefox - ⚫

Safari - ⚫

🟢 Modules > MITRE ATT&CK > Intelligence > Tactics: For each suggested field, check the value suggestion display results or at least doesn't break

Chrome - 🟢

Firefox - ⚫

Safari - ⚫

🟢 Modules > MITRE ATT&CK > Intelligence > Tactics: Using a value suggested should allow to run the search

Chrome - 🟢
image

Firefox - ⚫

Safari - ⚫

🟢 Modules > MITRE ATT&CK > Intelligence > Tactics: Type a term and run the search should search in each displayed field

Chrome - 🟢
image

Firefox - ⚫

Safari - ⚫

🟢 Modules > MITRE ATT&CK > Intelligence > Tactics: Type a simple field search and this should returns the expected results

Chrome - 🟢
image

Firefox - ⚫

Safari - ⚫

🟡 Modules > MITRE ATT&CK > Intelligence > Tactics: Type a complex field search and this should returns the expected results

Chrome - 🟡
Error in the query when I use parenthesis.
image

Firefox - ⚫

Safari - ⚫

🟢 Modules > MITRE ATT&CK > Intelligence > Techniques: For each suggested field, check the value suggestion display results or at least doesn't break

Chrome - 🟢
image

Firefox - ⚫

Safari - ⚫

🟢 Modules > MITRE ATT&CK > Intelligence > Techniques: Using a value suggested should allow to run the search

Chrome - 🟢
image

Firefox - ⚫

Safari - ⚫

🟢 Modules > MITRE ATT&CK > Intelligence > Techniques: Type a term and run the search should search in each displayed field

Chrome - 🟢
image

Firefox - ⚫

Safari - ⚫

🟢 Modules > MITRE ATT&CK > Intelligence > Techniques: Type a simple field search and this should returns the expected results

Chrome - 🟢
image

Firefox - ⚫

Safari - ⚫

🟡 Modules > MITRE ATT&CK > Intelligence > Techniques: Type a complex field search and this should returns the expected results

Chrome - 🟡
Error in the query when I use parenthesis.
image

Firefox - ⚫

Safari - ⚫

🟢 Management > CDB Lists: For each suggested field, check the value suggestion display results or at least doesn't break

Chrome - 🟢
image

Firefox - ⚫

Safari - ⚫

🟢 Management > CDB Lists: Using a value suggested should allow to run the search

Chrome - 🟢
image

Firefox - ⚫

Safari - ⚫

🟢 Management > CDB Lists: Type a term and run the search should search in each displayed field

Chrome - 🟢
image

Firefox - ⚫

Safari - ⚫

🟢 Management > CDB Lists: Type a simple field search and this should returns the expected results

Chrome - 🟢
image

Firefox - ⚫

Safari - ⚫

🟢 Management > CDB Lists: Type a complex field search and this should returns the expected results

Chrome - 🟢
image

Firefox - ⚫

Safari - ⚫

🟢 Management > Decoders: For each suggested field, check the value suggestion display results or at least doesn't break

Chrome - 🟢
image

Firefox - ⚫

Safari - ⚫

🟡 Management > Decoders: Using a value suggested should allow to run the search

Chrome - 🟡
Program name isn't a valid field.
image

Firefox - ⚫

Safari - ⚫

🟢 Management > Decoders: Type a term and run the search should search in each displayed field

Chrome - 🟢
image

Firefox - ⚫

Safari - ⚫

🟢 Management > Decoders: Type a simple field search and this should returns the expected results

Chrome - 🟢
image

Firefox - ⚫

Safari - ⚫

🟡 Management > Decoders: Type a complex field search and this should returns the expected results

Chrome - 🟡
Error in the query when I use parenthesis.
image

Firefox - ⚫

Safari - ⚫

🟢 Management > Decoders > Files: For each suggested field, check the value suggestion display results or at least doesn't break

Chrome - 🟢
image

Firefox - ⚫

Safari - ⚫

🟢 Management > Decoders > Files: Using a value suggested should allow to run the search

Chrome - 🟢
image

Firefox - ⚫

Safari - ⚫

🟢 Management > Decoders > Files: Type a term and run the search should search in each displayed field

Chrome - 🟢
image

Firefox - ⚫

Safari - ⚫

🟢 Management > Decoders > Files: Type a simple field search and this should returns the expected results

Chrome - 🟢
image

Firefox - ⚫

Safari - ⚫

🟡 Management > Decoders > Files: Type a complex field search and this should returns the expected results

Chrome - 🟡
image

Firefox - ⚫

Safari - ⚫

🟢 Management > Rules: For each suggested field, check the value suggestion display results or at least doesn't break

Chrome - 🟢
image

Firefox - ⚫

Safari - ⚫

🟢 Management > Rules: Using a value suggested should allow to run the search

Chrome - 🟢
image

Firefox - ⚫

Safari - ⚫

🟢 Management > Rules: Type a term and run the search should search in each displayed field

Chrome - 🟢
image

Firefox - ⚫

Safari - ⚫

🟢 Management > Rules: Type a simple field search and this should returns the expected results

Chrome - 🟢
image

Firefox - ⚫

Safari - ⚫

🟡 Management > Rules: Type a complex field search and this should returns the expected results

Chrome - 🟡
image

Firefox - ⚫

Safari - ⚫

🟢 Management > Rules: Click on a filter from the rule detail flyout, the filter should be added to the search bar and the table should be filtered

Chrome - 🟢
image

Firefox - ⚫

Safari - ⚫

🟢 Management > Rules > Files: For each suggested field, check the value suggestion display results or at least doesn't break

Chrome - 🟢
image

Firefox - ⚫

Safari - ⚫

🟢 Management > Rules > Files: Using a value suggested should allow to run the search

Chrome - 🟢
image

Firefox - ⚫

Safari - ⚫

🟢 Management > Rules > Files: Type a term and run the search should search in each displayed field

Chrome - 🟢
image

Firefox - ⚫

Safari - ⚫

🟢 Management > Rules > Files: Type a simple field search and this should returns the expected results

Chrome - 🟢
image

Firefox - ⚫

Safari - ⚫

🟡 Management > Rules > Files: Type a complex field search and this should returns the expected results

Chrome - 🟡
image

Firefox - ⚫

Safari - ⚫

Copy link
Member

@yenienserrano yenienserrano left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM
Test: #5442 (comment)

@asteriscos asteriscos self-requested a review August 10, 2023 15:17
Copy link
Member

@JuanGarriuz JuanGarriuz left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM
Tests: #5442 (comment)

@github-actions
Copy link
Contributor

Code coverage (Jest) % values
Statements 11.33% ( 3962 / 34962 )
Branches 7.47% ( 1775 / 23742 )
Functions 10.68% ( 896 / 8386 )
Lines 11.5% ( 3849 / 33450 )

@Desvelao Desvelao merged commit f987351 into 4.6.0 Aug 11, 2023
2 checks passed
@Desvelao Desvelao deleted the feat/4312-search-bar-replace-tablewzapi branch August 11, 2023 13:22
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.

New search bar component
4 participants