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

[Security Solution][Endpoint] Add Event Filters api validations get, find, delete, export, summary and import #124071

Conversation

paul-tavares
Copy link
Contributor

Summary

  • introduces API validations for get, find, delete, export, summary and import Lists APIs for Endpoint Event Filters

Checklist

@paul-tavares paul-tavares added release_note:skip Skip the PR/issue when compiling release notes Team:Defend Workflows “EDR Workflows” sub-team of Security Solution OLM Sprint v8.1.0 labels Jan 29, 2022
@paul-tavares paul-tavares self-assigned this Jan 29, 2022
@paul-tavares paul-tavares requested a review from a team as a code owner January 29, 2022 17:20
@elasticmachine
Copy link
Contributor

Pinging @elastic/security-onboarding-and-lifecycle-mgt (Team:Onboarding and Lifecycle Mgt)

@paul-tavares paul-tavares requested review from joeypoon and removed request for dasansol92 January 29, 2022 17:20
…vent-filters-validations-get-find-delete-export-summary

# Conflicts:
#	x-pack/plugins/security_solution/server/lists_integration/endpoint/handlers/exceptions_pre_delete_item_handler.ts
#	x-pack/plugins/security_solution/server/lists_integration/endpoint/handlers/exceptions_pre_export_handler.ts
#	x-pack/plugins/security_solution/server/lists_integration/endpoint/handlers/exceptions_pre_get_one_handler.ts
#	x-pack/plugins/security_solution/server/lists_integration/endpoint/handlers/exceptions_pre_multi_list_find_handler.ts
#	x-pack/plugins/security_solution/server/lists_integration/endpoint/handlers/exceptions_pre_single_list_find_handler.ts
#	x-pack/plugins/security_solution/server/lists_integration/endpoint/handlers/exceptions_pre_summary_handler.ts
Copy link
Member

@ashokaditya ashokaditya left a comment

Choose a reason for hiding this comment

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

NIce! 🚢 it

Comment on lines 41 to 47
return data;
}

// Event Filter validation
if (EventFilterValidator.isEventFilter({ listId })) {
await new EventFilterValidator(endpointAppContext, request).validatePreDeleteItem();
return data;
Copy link
Member

@ashokaditya ashokaditya Jan 31, 2022

Choose a reason for hiding this comment

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

Nice! I added this change to some of the validators in my PR as well as you suggested.

@@ -5,7 +5,7 @@
* 2.0.
Copy link
Member

@ashokaditya ashokaditya Jan 31, 2022

Choose a reason for hiding this comment

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

I've renamed this file to event_filters.ts and also moved host isolation tests to endpoint_artifacts/host_isolation_exceptions.ts

…vent-filters-validations-get-find-delete-export-summary

# Conflicts:
#	x-pack/plugins/security_solution/server/lists_integration/endpoint/handlers/exceptions_pre_delete_item_handler.ts
#	x-pack/plugins/security_solution/server/lists_integration/endpoint/handlers/exceptions_pre_get_one_handler.ts
#	x-pack/plugins/security_solution/server/lists_integration/endpoint/handlers/exceptions_pre_multi_list_find_handler.ts
#	x-pack/plugins/security_solution/server/lists_integration/endpoint/handlers/exceptions_pre_single_list_find_handler.ts
#	x-pack/test/security_solution_endpoint_api_int/apis/endpoint_artifacts/event_filters.ts
@paul-tavares paul-tavares enabled auto-merge (squash) January 31, 2022 22:05
@paul-tavares paul-tavares merged commit ddb3f4f into elastic:main Jan 31, 2022
@kibana-ci
Copy link
Collaborator

💚 Build Succeeded

Metrics [docs]

✅ unchanged

History

To update your PR or re-run it, just comment with:
@elasticmachine merge upstream

cc @paul-tavares

@kibanamachine kibanamachine added the backport:skip This commit does not require backporting label Jan 31, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
backport:skip This commit does not require backporting OLM Sprint release_note:skip Skip the PR/issue when compiling release notes Team:Defend Workflows “EDR Workflows” sub-team of Security Solution v8.1.0
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants