## Summary
Fixes error toaster on signals upgrades as well as creation of new signals if you have a user without a cluster manage privilege.
Simplest way to manually test both situations of a user on creating a new signal as well as upgrade is to first create a new role like so in dev tools:
```ts
PUT _security/role/reduced_permissions
{
"indices":[
{
"names":[
".siem-signals-*",
".lists-*",
".items-*"
],
"privileges":[
"all"
],
"field_security":{
"grant":[
"*"
]
},
"allow_restricted_indices":false
}
],
"applications":[
{
"application":"kibana-.kibana",
"privileges":[
"space_all"
],
"resources":[
"space:default"
]
}
]
}
```
You might have to change this line above to match what your `kibana.index` is set to if it is set:
```ts
"application" : "kibana-.kibana-hassanabad8",
```
Double check things in Stack Management to ensure you have access to at least default space:
<img width="1304" alt="Screen Shot 2021-02-01 at 5 45 54 PM" src="https://user-images.githubusercontent.com/1151048/106536383-906f3f00-64b5-11eb-97d3-060fa6f6206e.png">
Next add a user which has this role of `reduced_permissions` to login as that user. Next for testing that this causes an error toaster when there is no signals index is to either manually delete your signals index or change your `kibana.dev.yml` so that it thinks you have a new index:
```ts
xpack.securitySolution.signalsIndex: .siem-signals-some-new-index-name
```
Start up Kibana, login with the new user and visit any page and notice you get an error toaster like below:
<img width="808" alt="Screen Shot 2021-02-01 at 5 04 17 PM" src="https://user-images.githubusercontent.com/1151048/106535815-4afe4200-64b4-11eb-89b3-947b0e4ff7d5.png">
And also notice that you are blocked from viewing signals at this point:
<img width="1195" alt="Screen Shot 2021-02-01 at 5 04 43 PM" src="https://user-images.githubusercontent.com/1151048/106535835-56516d80-64b4-11eb-883c-2745b68843cf.png">
For upgrading signals manually, you can change the version number from dev tools or increment the number directly within this file and restart Kibana:
https://github.com/elastic/kibana/blob/master/x-pack/plugins/security_solution/server/lib/detection_engine/routes/index/get_signals_template.ts#L10
When you visit the detection page you will see the same error toaster and also be blocked. With this PR you will no longer be blocked.
### Checklist
Delete any items that are not applicable to this PR.
- [ ] [Unit or functional tests](https://www.elastic.co/guide/en/kibana/master/development-tests.html) were updated or added to match the most common scenarios
* Add desired hover functionality and a test.
* Switch render from img to EuiImage for step view.
* Create new module for ping_timestamp. Extract a function. Add a test.
* Extract nav buttons, translations. Add tests.
* Fix a typo.
* Extract caption to own file. Add tests.
* Extract no image display to dedicated file. Add aria label. Add tests.
* Make import path more explicit.
* Move step image popover to dedicated file. Add tests.
* Clean up inline code in timestamp component.
* Explicit var names.
* Simplicity.
* Fix refactoring issues in test files.
* Move translations to central file.
* Rename test for better accuracy.
* [maps] Top hits per entity--change to title to use recent, minor edits
* Updated TopHitsPerEntity title and description to use the term relevant
* Change create multi-layer map tutorial title to be use-case driven
* reverting change to TopHits topic
* Updated title of getting started with maps tutorial
* Updated title of getting started with maps tutorial
Co-authored-by: Kent Marten <kmartastic@users.noreply.github.com>
Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
* Move `getTraceUrl` in the APM plugin to `getApmTraceUrl` in the observability plugin and use that instead in infra.
* Remove unused APM plugin depenency in infra.
* Use `pathname` instead of `hash` in infra to apm link to avoid unnecessary redirect.
* Add support for custom alert ids
* UUID v4 also supported
* Change ESO custom id error message
* Update api integration test
* Use errors.createBadRequestError
* get midpoint of max and min instead of half of max number
* remove middle tick from stepped gradient legend
* use value instead of max values to calculate bounds
Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
* Update data streams mappings directly instead of querying for backing indices, update integration tests to test with multiple namespaces
* Add flag to only update mappings of the current write index
Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
resolves https://github.com/elastic/kibana/issues/88367
Prior to this PR, the KQL node_builder code was using recursion to generate
"and" & "or" expressions. Eg, `and(foo1=bar1, foo2=bar2, foo3=bar3)` would
be generated as if was specified as `and(foo1=bar1, and(foo2=bar2, foo3=bar3))`.
Calls to the builder with long lists of expressions would generate nested JSON
as deep as the lists are long. This is problematic, as Elasticsearch is
changing the default limit on nested bools to 20 levels, and alerting already
generates nested bools greater than that limit.
See: https://github.com/elastic/elasticsearch/issues/55303
This PR changes the generated shape of above, so that all the nodes are at the
same level, instead of the previous "recursive" treatment.
* init push case
* fix connectorToUpdate
* add unit test
* revert change
* remove useEffect after case created
* add unit test
* add cancel flag
* update unit test
Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
* Migrations V2 on by default
* esArchiver delete migrations v2 indices
* Fix saved_objects_management api_integration tests
* Try to fix v2 migrations for pre-release builds
* esArchiver delete auto-created v2 migration indices like .kibana_8.0.0
* Try to fix v2 migrations for pre-release builds
* Use require_alias to prevent auto-created saved objects index
* Wrap SO routes until core logs all internal errors
* Fix api_integration tests requiring an empty kibana index
* Delete corrupt saved object from lens archives
* Update docs
* Fix ui_settings tests
* Fix core jest tests
* Fix type errors
* Fix accessibility tests
* Fix plugin functional tests
* Fix api_integration tests after merging in master
* Fix plugin functional tests #2
* EsArchiver: Don't reset ui settings after the .kibana index was deleted
* Fix functional management/visualize tests
* Fix oss security functional tests
* EsArchiver clean task manager indices to fix alerting api integration tests
* migrationsv2 correctly handle unknown saved object type mappings
* Revert "Try to fix v2 migrations for pre-release builds"
This reverts commit a1a1567501.
* Revert "Try to fix v2 migrations for pre-release builds"
This reverts commit a9a935558c.
* Re-enable v2 migrations in tests after merging in master
* Try to fix async dashboard functional test
* Restore UiSettings defaults after emptyKibanaIndex()
* Review feedback: rename test to match behaviour
- Adds support for scatterplot matrices to regression/classification results pages
- Lazy loads the scatterplot matrix including Vega code using Suspense. The approach is taken from the Kibana Vega plugin, creating this separate bundle means you'll load the 600kb+ Vega code only on pages where actually needed and not e.g. already on the analytics job list. Note for reviews: The file scatterplot_matrix_view.tsx did not change besides the default export, it just shows up as a new file because of the refactoring to support lazy loading.
- Adds support for analytics configuration that use the excludes instead of includes field list.
- Adds the field used for color legends to tooltips.