Commit graph

15997 commits

Author SHA1 Message Date
Marshall Main 7f6d7b3642
[Security Solution] Improve find rule and find rule status route performance (#99678)
* Fetch rule statuses using single aggregation instead of N separate requests

* Optimize _find API and _find_statuses

* Merge alerting framework errors into rule statuses

* Add sortSchema for top hits agg, update terms.order schema

Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
2021-05-28 11:49:49 -04:00
Nicolas Chaulet a0622d51da
[Fleet] Improve combo box for fleet settings (#100603) 2021-05-28 11:25:20 -04:00
Paul Tavares e3517edd22
[Security Solution][Endpoint] Endpoint generator and data loader support for Host Isolation (#100813)
Re-introduces the changes from #100727 which was backed out due to a bug. Changes included:

* Generate random isolation values for endpoint metadata
* Generator for Fleet Actions
* Added creation of actions to the index test data loader

Plus:

* Fix generator `randomBoolean()` to ensure it works with seeded random numbers
* Update resolver snapshots due to additional call to randomizer
2021-05-28 10:40:34 -04:00
ymao1 c0f9970a55
[Alerting] Adding feature flag for enabling/disabling rule import and export (#100718)
* Adding feature flag for enabling rule import and export

* Removing item from docs

Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
2021-05-28 09:52:58 -04:00
Marco Liberati 51616e1b8d
[Lens] Adds dynamic table cell coloring (#95217)
Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
Co-authored-by: Greg Thompson <thompson.glowe@gmail.com>
Co-authored-by: Michael Marcialis <michael@marcial.is>
2021-05-28 15:24:28 +02:00
Esteban Beltran 4b486d3d1a
[Security Solution][Endpoint] Do not display searchbar in security-trusted apps if there are no items (#100853)
Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
2021-05-28 15:19:15 +02:00
Alison Goryachev 90e43431a5
[Infra] Update LogStream component docs (#100795) 2021-05-28 08:42:44 -04:00
Søren Louv-Jansen 79945fe027
[Observability] Fix typo in readme for new navigation (#100861)
* [Observability] Fix typo in readme for new navigation

* Add rxjs dep
2021-05-28 14:41:42 +02:00
Marta Bondyra a4f6d43783
[Lens] Move app state to redux toolkit (#100338) 2021-05-28 10:06:06 +02:00
Spencer 9538788611
[ftr] migrate "MenuToggle" service to FtrService class (#100608)
Co-authored-by: spalger <spalger@users.noreply.github.com>
Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
2021-05-28 07:10:32 +02:00
Marta Bondyra 48f7a479b5
[Lens] fix error when adding a new layer (#100766)
Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
2021-05-28 00:24:38 +02:00
Yuliia Naumenko 134a3def03
[Actions] Converted rejectUnauthorized config usages to verificationMode. (#100179)
* [Actions] Converted `rejectUnauthorized` config usages to `verificationMode`.

* added new verificationMode config options for tls, proxy tls and custom hosts

* added unit tests

* added unit tests

* added kibana docker

* Apply suggestions from code review

Co-authored-by: gchaps <33642766+gchaps@users.noreply.github.com>

* Update alert-action-settings.asciidoc

* Apply suggestions from code review

Co-authored-by: Joe Portner <5295965+jportner@users.noreply.github.com>

* removed legacyRegectUnauthorized logic from getNodeTLSOptions

* added deprecations

* fixed doc links

* fixed docs

* Update x-pack/plugins/actions/server/builtin_action_types/lib/send_email.ts

Co-authored-by: Joe Portner <5295965+jportner@users.noreply.github.com>

* [DOCS] Fixes build error

* fixed deprecations to set custom message

* fixed doc

* changed to not throw exception on non existing verification mode

* added tests

* fixed tests

* fixed tests

* added integration tests for legacy rejectUnauthorized fale

* fixed tests

Co-authored-by: gchaps <33642766+gchaps@users.noreply.github.com>
Co-authored-by: Joe Portner <5295965+jportner@users.noreply.github.com>
Co-authored-by: lcawl <lcawley@elastic.co>
Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
2021-05-27 14:20:57 -07:00
spalger a6bbf1b219 skip suite failing es promotion (#100697) 2021-05-27 14:10:49 -07:00
Craig Chamberlain 697b00f7d5
Fixes Field used in RDP ML job to event.type (#100000)
* Update datafeed_windows_rare_user_type10_remote_login.json

refactor df query to work with newer field values

* Update datafeed_windows_rare_user_type10_remote_login.json

remove event.code test - was failing a test on the build server using the original data b/c this field was not there when the query was first developed.

Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
2021-05-27 16:45:56 -04:00
Zacqary Adam Xeper 780d23e7af
[Fleet] Link to docs for Fleet Server and ES hosts (#100698)
* [Fleet] Link to docs for Fleet Server and ES hosts

* Fix CN/JP i18n

Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
2021-05-27 15:11:58 -05:00
Jason Stoltzfus be001f2aa6
[App Search] Added a query tester button (#100560) 2021-05-27 15:39:16 -04:00
Devon Thomson ca82b9b10a
[Lens] By Value Migrations for 7.13 (#100622)
* quick fix for 7.13 lens migration not being run on by value panels

Co-authored-by: Joe Reuter <johannes.reuter@elastic.co>
2021-05-27 15:37:58 -04:00
Casper Hübertz de2f3c468a
[Observability] Fix README.md link to component (#100801) 2021-05-27 21:27:16 +02:00
Pete Hampton 3149d46301
Remove / Consolidate legacy usage adoption metrics (#100480)
* Remove legacydetection rule stat summaries

* Remove ML usage summary and consolidate with ML metric telemetry.

* Remove ML usage summary and consolidate with ML metric telemetry.

* Move legacy helper constructs into index.

* Separate rule logic from ml logic. Add ml unit tests.

* Abstract types away into their own file.

* Update telemetry schema.

Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
2021-05-27 20:10:01 +01:00
ymao1 71379b755a
[Alerting] Split alerting feature privilege between rules and alerts and handle subfeature privilege specification (#100127)
* WIP - creating alerting authorization client factory and exposing authorization client on plugin start contract

* Updating alerting feature privilege builder to handle different alerting types

* Passing in alerting authorization type to AlertingActions class string builder

* Passing in authorization type in each function call

* Passing in exempt consumer ids. Adding authorization type to audit logger

* Changing alertType to ruleType

* Changing alertType to ruleType

* Updating unit tests

* Updating unit tests

* Passing field names into authorization query builder. Adding kql/es dsl option

* Converting to es query if requested

* Fixing functional tests

* Removing ability to specify feature privilege name in constructor

* Fixing some types and tests

* Consolidating alerting authorization kuery filter options

* Cleanup and tests

* Cleanup and tests

* Initial commit with changes needed for subfeature privilege

* Throwing error when AlertingAuthorizationClientFactory is not defined

* Renaming authorizationType to entity

* Renaming AlertsAuthorization to AlertingAuthorization

* Fixing unit tests

* Changing schema of alerting feature privilege

* Changing schema of alerting feature privilege

* Updating feature privilege iterator

* Updating feature privilege builder

* Fixing types check

* Updating privilege string terminology

* Updating privilege string terminology

* Wip

* Fixing unit tests

* Unit tests

* Updating README and removing stack subfeature privilege changes

* Fixing README

Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
2021-05-27 14:59:02 -04:00
Jonathan Budzenski f0e11bcd1b
Automated package testing (#88900)
Co-authored-by: Tyler Smalley <tylersmalley@me.com>
Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
2021-05-27 13:37:43 -05:00
Nathan Reese 8420605352
[Maps] timeslider (#99661)
* [Maps timeslider]

* just arrowLeft and arrowRight icons

* tslint

* color icon when timeslider is open, auto select first section on open

* increase width to prevent timeslider from changing sizes during interaction

* fix filters disappearing when timeslice advances

* use shorter date format for ticks

* review feedback

* do not show timeslider button when map is embedded

Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
2021-05-27 12:32:13 -06:00
Jonathan Budzenski 5dde07ff6f Revert "[Security solution][Endpoint] Add Host Isolation related data to the endpoint generator and test data loader (#100727)"
This reverts commit 57f59bd15d.
2021-05-27 12:21:48 -05:00
Paul Tavares 57f59bd15d
[Security solution][Endpoint] Add Host Isolation related data to the endpoint generator and test data loader (#100727)
* Generate random isolation values for endpoint metadata
* Generator for Fleet Actions
* Added creation of actions to the index test data loader
2021-05-27 11:55:50 -04:00
Georgii Gorbachev 7fd6539dca
[RAC] Rule monitoring: Event Log for Rule Registry (#98353)
**Needed for:** rule execution log for Security https://github.com/elastic/kibana/pull/94143
**Related to:**

- alerts-as-data: https://github.com/elastic/kibana/issues/93728, https://github.com/elastic/kibana/issues/93729, https://github.com/elastic/kibana/issues/93730
- RFC for index naming https://github.com/elastic/kibana/issues/98912

## Summary

This PR adds a mechanism for writing to / reading from / bootstrapping indices for RAC project into the `rule_registry` plugin. Particularly, indices for alerts-as-data and rule execution events. This implementation is similar to existing implementations like `event_log` plugin (see https://github.com/elastic/kibana/pull/98353#issuecomment-833045980 for historical perspective), but we're going to converge all of them into 1 or 2 implementations. At least we should have a single one in `rule_registry` itself.

In this PR I tried to incorporate most of the feedback received in the RFC (https://github.com/elastic/kibana/issues/98912), but if you notice I missed/forgot something, please let me know in the comments.

Done in this PR:

- [x] Schema-agnostic APIs for working with Elasticsearch.
- [x] Schema-aware log definition and bootstrapping API (creating hierarchical logs).
- [x] Schema-aware write API (logging events).
- [x] Schema-aware read API (searching logs, filtering, sorting, pagination, aggregation).
- [x] Support for Kibana spaces, space-aware index bootstrapping (either at rule creation or rule execution time).

As for reviewing this PR, perhaps it might be easier to start with:

- checking description of https://github.com/elastic/kibana/issues/98912
- checking usage examples https://github.com/elastic/kibana/pull/98353/files#diff-c049ff2198cc69bd50a69e92d29e88da7e10b9a152bdaceaf3d41826e712c12b
- checking public api https://github.com/elastic/kibana/pull/98353/files#diff-8e9ef0dbcbc60b1861d492a03865b2ae76a56ec38ada61898c991d3a74bd6268

## Next steps

Next steps towards rule execution log in Security (https://github.com/elastic/kibana/pull/94143):

- define actual schema for rule execution events
- inject instance of rule execution log into Security rule executors and route handlers
- implement actual execution logging in rule executors
- update route handlers to start fetching execution events and metrics from the log instead of custom saved objects

Next steps in the context of RAC and unified implementation:

- converge this implementation with `RuleDataService` implementation
  - implement robust index bootstrapping
  - reconsider using FieldMap as a generic type parameter
  - implement validation for documents being indexed
- cover the final implementation with tests
- write comprehensive docs: update plugin README, add JSDoc comments to all public interfaces
2021-05-27 18:28:19 +03:00
Shahzad 413132008b
[Uptime] Waterfall use different styling for number (#97216)
Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
2021-05-27 17:01:52 +02:00
Felix Stürmer 06d276e060
[Logs UI] Add shared observability page template and navigation (#99380)
Co-authored-by: Kerry Gallagher <471693+Kerry350@users.noreply.github.com>
Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
2021-05-27 16:58:15 +02:00
Nathan L Smith 7fc4a1f80f
Add kibana.yml configuration for cases (#100583)
Make it so `xpack.observability.unsafe.alertingExperience.enabled` only shows and hides the Alerts page, and `xpack.observability.unsafe.cases.enabled` show and hides the Cases page.
2021-05-27 09:43:12 -05:00
Anton Dosov 806566c62e
[Index Patterns] Migrate tests to the new es client (#100760) 2021-05-27 15:47:30 +02:00
Candace Park 1c4d338668
[Security Solution][Endpoint][Host Isolation] User can unisolate host from alert details (#100401) 2021-05-27 09:32:32 -04:00
Joe Reuter f6266c431b
[Lens] Improve caching with more stable Elasticsearch requests (#100414) 2021-05-27 15:25:10 +02:00
Patrick Mueller 11b3ab167d
[alerting] add ignore_above to alerts params mappings to handle immense params (#100726)
resolves https://github.com/elastic/kibana/issues/100607

This fixes a problem when very large parameters (over 32K bytes) are saved with
an alert.  Before this fix, an error from elasticsearch would be thrown with
the following message, and a 400 returned from create (and presumably update).

    Document contains at least one immense term in field=\"alert.params\"
    (whose UTF8 encoding is longer than the max length 32766), all of which
    were skipped.

After the fix, alerts with immense params can be saved and executed.

Note that the immense params will not be searchable, since they won't be indexed,
but that seems both unavoidable, and not a severe issue.
2021-05-27 09:17:12 -04:00
Alejandro Fernández Gómez 83e5b6c689
[Fleet] Remove beats management plugin (#99789) 2021-05-27 11:30:15 +02:00
Thomas Neirynck 5da329a809
[Maps] Isolate mapbox-gl types and align downstream package versions. (#100610) 2021-05-26 21:09:38 -04:00
Tim Sullivan 417c06b9a1
[Reporting] Use the deprecations service to advise critical config changes (#100427)
Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
2021-05-26 17:31:55 -07:00
Mikhail Shustov 881d89fba7
remove src/legacy and src/optimizer from configs (#100538)
* cleanup removed dirs

* delete removed folders from other places in the repo

Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
2021-05-26 22:01:33 +02:00
Justin Kambic b189d05bc3
[Uptime] Move uptime actions to Header Actions Menu (#100298)
* Move uptime actions to Kibana's HeaderActionsMenu.

* Delete a comment.

* Extract ActionMenu content to dedicated component to make testing easier.

* Add tests.

* Use `EuiHeaderLinks` instead of `EuiFlexItem`.

* Clean up tests.

* Prefer `getByRole` for a test.

* Fix copy mistake.

* Fix a test broken by the previous commit.

* Prefer `EuiHeaderSectionItem` over `EuiHeaderSectionLink` to avoid nesting `button`s within `buttons`.

* Reverse "Settings" and "Alerts" menu options to make them uniform with APM.

Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
2021-05-26 15:31:15 -04:00
Jen Huang ba7c0275ca
[Fleet] Support browsing granular integrations (#99866)
* Manual cherry pick of work to support integration tiles and package-level vars

* Fix types

* Remove registry input group typings

* Show integration-specific readme, title, and icon in package details page

* Revert unnecessary changes

* Add package-level `vars` field to package policy SO mappings

* Fix types

* Fix test

Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
2021-05-26 09:59:09 -07:00
Pete Harverson f77ff2d396
[ML] Adds functional tests for anomaly detection job custom URLs (#100455)
* [ML] Adds functional tests for anomaly detection job custom URLs

* [ML] Remove debug test tag from custom URL tests

* [ML] Update custom URL editor Jest snapshots

* [ML] Clean up in embeddables tests to fix dashboard test

* [ML] Delete test dashboard after test suites complete

* [ML] Edits to custom URL tests following review

Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
2021-05-26 17:48:03 +01:00
Ignacio Rivas ae63fb1c17
[Ingest pipelines] add support for fingerprint processor (#100541) 2021-05-26 18:29:05 +02:00
Thomas Neirynck c5aa39835d
[Maps] Add draw wizard (#100278) 2021-05-26 11:21:38 -04:00
Nathan Reese e49db7127d
[Maps] filter dashboard by map extent (#99860)
* [Maps] filter dashboard by map extent

* clean up

* remove warning from filter pill

* tslint

* API doc updates, i18n fixes, tslint

* only show context menu option in edit mode

* add functional test

* review feedback

* do not use search session when filtering by map bounds

Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
2021-05-26 08:51:39 -06:00
Sandra Gonzales ce6f923bb4
fix anomaly functional test (#100504)
Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
2021-05-26 10:25:39 -04:00
Stratoula Kalafateli 638ab8247b
[Gauge] Fixes wrong translations on ranges less than symbol (#100535) 2021-05-26 16:02:28 +03:00
Larry Gregory 5d5cc55b3a
Fix spaces test flakyness (#100605) 2021-05-26 06:47:28 -04:00
Ignacio Rivas 93acfb4d43
[Ingest pipelines] add support for ip type in convert processor (#100531)
* add ip option type to convert processor

* remove duped option

* small CR changes

Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
2021-05-26 11:36:06 +02:00
Mikhail Shustov f915b6fe73
[telemetry] report config deprecations (#99887)
* return the list of changes config keys during deprecation

* gather changed config keys in the core

* adjust Security plugin deprecations tests

* update docs

* update interface

* update telemetry schema

* update spaces tests

* update tests in other x-pack plugins

* remove testing instruction

* improve tests. get rid of snapshots
2021-05-26 10:57:01 +02:00
Yuliia Naumenko 5ebded2105
[triggersActionsUi] Reduce page load bundle to under 100kB (#97770)
* [triggersActionsUi] Reduce page load bundle to under 100kB

* removed old code

* removed fragment

* changed svg logo to lazy react components

* fixed type checks and translations

* fixed type checks

* fixed type checks

* fixed type checks

* fixed tests

* fixed tests

* fixed iconClass

* fixed due to comments

* added info about new IconType to readme file

* fixed key errors
2021-05-25 19:00:29 -07:00
Nathan Reese b30d96e7f2
[Maps] convert LayerPanel to typescript (#100481)
* [Maps] convert LayerPanel to typescript

* layer_errors

* style panel

* layer_panel component

* rename to EditLayerPanel

* clean up

* fix scss imports for rename

* one more scss path clean up

* fix EditLayerPanel errors
2021-05-25 13:25:18 -06:00
Alison Goryachev a0ddca8b07
[Upgrade Assistant] Address copy feedback (#99632) 2021-05-25 14:14:08 -04:00