Commit graph

668 commits

Author SHA1 Message Date
Tim Roes 8c14c256b7
New visualization type selection (#23833)
* First version of new visualization selection

* Extract some components

* Remove visualization category

* Remove old wizard code

* Fix i18n ids

* Fix tests

* Fix tag cloud tests

* Fix broken test method

* Fix wrong method call

* Fix TSVB navigation in tests

* Restructure components

* Fix for lab removal

* Add tests

* Timroes/eui vis type selection (#4)

* Added background graphic from welcome screen to modal

* Fixed up responsiveness

* Change wording

* Fix test snapshot

* Create VisTypeIcon

* Implement suggestions

* Change experimental wording

* Use regular quotes for i18n engine
2018-11-22 12:52:05 +01:00
Lisa Cawley f56579d553
[DOCS] Adds screenshot for monitoring jobs (#25904) 2018-11-21 09:35:11 -08:00
Sarah Hersh 7fbac45ec7
[DOCS]fix typo in link to source code (#25968) 2018-11-20 15:49:51 -05:00
Tim Roes a5e096ecf6
Remove lab stage for visualizations (#25702)
* Remove lab stage for visualizations

* Fix typo

Co-Authored-By: timroes <mail@timroes.de>

* Remove dead code
2018-11-19 16:28:01 +01:00
Shaunak Kashyap 0c6e619237
[Monitoring] Adding security note about first-time setup (#25823)
* Adding security note

* Mention the built-in superuser role

* Making edits per review feedback
2018-11-19 05:14:38 -08:00
Tim Sullivan dd5d245dcd
[Docs/Reporting] Include working config example for multiple kibana.index (#25410)
* [Docs] Include working config example for multiple kibana.index in the cluster

* updates
2018-11-16 10:08:58 -07:00
debadair c21cf21e89
[DOCS] Removed coming tags for 7.0.0-alpha1 (#25750) 2018-11-15 11:36:48 -08:00
Karen Metts 393fa6a0b9
Add infrastructure and logs doc (#25407) 2018-11-15 14:05:04 -05:00
gchaps 22a4fed51d
[DOCS] Adds Release Notes for 7.0.0-alpha1 (#25583)
* [DOCS] Adds Release Notes for 7.0.0-alpha1

* [DOCS] Incorporated review comments into 7.0.0-alpha1 release notes

* [DOCS] Updated text about K7 design
2018-11-14 13:34:14 -08:00
Court Ewing c48cea9265
[DOCS] Saved object migrations (#25558)
* Add a note about index migrations to the kibana setup docs

* Tewak the migrations asciidocs for clarity

* docs: refine saved object migration details

Breaking down the migration process into sections helps people find
and link to relevant information more easily.

The focus is on ongoing maintenance of Kibana, whereas the initial new
experience in 6.5.0 is treated as a note of clarification.

Error handling should be expanded in the future to include details about
specific known error cases.
2018-11-13 18:38:10 -05:00
gchaps f183363361
[DOCS] Adds known limitation for exporting a data table (#25561) 2018-11-13 09:07:22 -08:00
gchaps 83369770c6
[DOCS] Adds docs for managing, creating, and visualizing rollups (#25450)
* [DOCS] Adds docs for managing, creating, and visualizing rollups

* [DOCS] Fixed broken link]

* [DOCS] Updates docs based on review feedback
2018-11-09 12:57:59 -08:00
Lisa Cawley 588d6a3622
[DOCS] Refreshes ML job creation screenshots (#25417) 2018-11-09 12:13:02 -08:00
Sarah Hersh bd85286d0a
Docs/canvas get started (#25476)
* edits to canvas getting started docs

* edit to canvas workpad docs
2018-11-09 14:31:01 -05:00
gchaps 9eda63f719
[DOCS] Updates information regarding usage of sample data indices (#25424) 2018-11-08 13:18:16 -08:00
Lisa Cawley 72ac1a9b8b
[DOCS] Clarify security requirements for monitoring (#24881) 2018-11-08 12:03:48 -08:00
gchaps eb923430ae
[DOCS] Adds early draft of Canvas docs (#25395)
* [DOCS] Adds early draft of Canvas docs

* [DOCS] Added images and beta label to Canvas docs
2018-11-08 11:50:51 -08:00
Lisa Cawley a0db3c4ca8
[DOCS] Adds data visualizer restriction (#25399) 2018-11-08 09:26:50 -08:00
Lisa Cawley 1c86dbdd9d
[DOCS] Fixes typo in Kibana create role example (#25345) 2018-11-08 08:54:35 -08:00
Lisa Cawley ac8ee26f77
[DOCS] Fixes typo in create role API (#25314) 2018-11-07 13:13:25 -08:00
Lisa Cawley 6c7d14a4dc
[DOCS] Adds screenshot for Data Visualizer (#25182) 2018-11-07 08:11:39 -08:00
Lisa Cawley feae892dcc
[DOCS] Updates Elasticsearch and Kibana monitoring screenshots (#25035) 2018-11-06 14:21:34 -08:00
Tim Roes b74f286961
Fix dashboard export documentation (#24701) 2018-11-06 09:59:59 +01:00
Matt Bargar c21b2ee73f
Add more accurate details on scripted field querying 2018-11-01 09:13:37 -04:00
Lisa Cawley b06b177eaa
[DOCS] Updates monitoring diagram (#24851) 2018-10-31 09:42:58 -07:00
Aaron Caldwell ad10c758c0
Default scroll wheel zoom to false on vega maps. Update docs (#21169)
* Default scroll wheel zoom to false on vega maps. Update docs

* Update scroll wheel to false in tests
2018-10-29 15:31:16 -06:00
Casper Hübertz 9850f1150c
[Docs] Remove beta notes for ML and Query bar (#24718) 2018-10-29 14:04:59 +01:00
Josh Dover 27e5406d7a
Upgrade Hapi in legacy platform to v17 (#21707)
* Disable even-better monitoring

* Upgrade to Hapi v15

* Upgrade to Hapi v16

* Handle optional req params correctly

* Update http and kbnServer

* Get mocha tests passing

* Convert `reply` usages [wip]

* Fix Joi and Plugin incompatibilities

* Get server up and running

* Get basic logging working

* Fix optimizer

* Fix recent route handlers

* Various fixes

* Fix recent routes

* Upgrade wreck for async/await

* Fix mocha tests

* Fix joi issues

* Fix xpack jest tests

* Fix recent routes

* Fix tests

* Fix index setup

* Decouple monitoring stats collection from good plugin

* Update reload logging test to work

* Reimplement logging with updated good plugin

* Fix unit tests

* Fix getConnections back

* Make LegacyLoggingServer compatible with Hapi v17

* Update joi types

* Fix x-pack unit tests

* Remove stray debugger

* Remove hapi-compat

* Fix API integrations

* Upgrade boom

* Fix security plugin

* Misc fixes

* bump

* Fix licensePreRoutingFactory

* Fix failing integration tests

* Remove unnecessary test change

* Remove hapi-latest package

* fx

* Various cleanup

* Fix race condition in oppsy events

* Use elastic/good fork

* Fix boom.wrap and hapi-latest changes

* Simplify LegacyLoggingServer updates

* package.json cleanup + test fix

* yarn.lock cleanup

* Change good tag

* Fixes

* Change return err -> throw err in routes

* Fix await returns

* Fix new load_data test

* Make cookie security flags consistent

* tmp doc

* Fix types

* Fix tests

* Upgrade canvas plugin

* Move good package to published @elastic/good one

* Fix SO test

* Fix logging reloading

* Update APM apis

* Fix error logging

* Fix logging test

* Convert spaces plugin

* Add validation error shim

* Remove 7.0 release notes

* Await renderApp

* Fix ccr routes

* Prevent header popovers from scrolling with page content (#23850)

* Fix spaces test

* new yarn.lock-s

* Fix spaces tests

* Remove h2o2-latest

* Fix @types/hapi

* Upgrade InfraOps plugin

* Fix package.json

* Add back isSameSite: false

* Upgrade beats_management plugin

* Update snapshot

* Fix InfraOps

* Upgrade kql_telemetry

* Merge upstream/master

* Upgrade apm and ml

* Put snapshot test back

* Fx beats

* Upgrade rollups

* Update boom usages in new plugins
2018-10-25 16:01:12 -05:00
Lisa Cawley 62e92a223e
[DOCS] Fixes broken links to Stack Overview (#24592) 2018-10-25 09:16:40 -07:00
Lisa Cawley 055aa0a73e
[DOCS] Adds security for monitoring steps (#24052) 2018-10-25 08:12:03 -07:00
Tim Sullivan 6084acc8b6
[Reporting] queue.pollEnabled setting adds ability to disable polling for idle jobs (#24295)
* [Reporting] New queue.pollEnabled setting adds ability to disable polling for idle jobs

* add an info log line

* note in docs
2018-10-24 08:03:54 -07:00
Lisa Cawley 831d1581fa
[DOCS] Clarify description of xpack.reporting.roles.allow (#23974) 2018-10-24 07:48:22 -07:00
Brandon Kobel 9e86a04f21
Adding option to always present the certificate when connecting to ES (#24304)
* Adding option to always present the certificate when connecting to ES

* Updating docs

* Adding some more tests

* Adding alwaysPresentCertificate option to monitoring
2018-10-23 07:12:27 -07:00
Tim Sullivan bd3f840b82
[docs/reporting] note about data table pdf (#23921) 2018-10-19 15:00:38 -07:00
Tim Roes 9bab09a0e0
Remove queryManager from vis docs (#23923) 2018-10-17 09:51:18 +02:00
lcawl 85c62afc2f [DOCS] Fixes broken link in monitoring page 2018-10-04 13:13:34 -07:00
Lisa Cawley 3a9deb0850
[DOCS] Update Kibana monitoring tasks (#23736) 2018-10-04 11:31:15 -07:00
Brandon Kobel 937e07c5f1
Limiting maximum number of Spaces (#23673)
* Limiting the number of spaces

* Adding docs

* Adding forgotten fixture

* Fixing tslint error

* Adjusting docs

* Changing test descriptions from Boom.badRequest to bad request

* Updating error snapshots
2018-10-03 09:09:12 -07:00
Court Ewing fd050fbcd3
docs: note about permissions for grok debugger (#23664) 2018-10-03 11:35:46 -04:00
Larry Gregory 1f38026731
Spaces Phase 1 (#21408)
### Review notes
This is generally ready for review. We are awaiting https://github.com/elastic/elasticsearch/issues/32777 to improve handling when users do not have any access to Kibana, but this should not hold up the overall review for this PR.

This PR is massive, there's no denying that. Here's what to focus on:
1) `x-pack/plugins/spaces`: This is, well, the Spaces plugin. Everything in here is brand new. The server code is arguably more important, but feel free to review whatever you see fit.
2) `x-pack/plugins/security`: There are large and significant changes here to allow Spaces to be securable. To save a bit of time, you are free to ignore changes in `x-pack/plugins/security/public`: These are the UI changes for the role management screen, which were previously reviewed by both us and the design team.
3) `x-pack/test/saved_object_api_integration` and `x-pack/test/spaces_api_integration`: These are the API test suites which verify functionality for:
     a) Both security and spaces enabled
     b) Only security enabled
     c) Only spaces enabled

What to ignore:
1) As mentioned above, you are free to ignore changes in `x-pack/plugins/security/public`
2) Changes to `kibana/src/server/*`: These changes are part of a [different PR that we're targeting against master](https://github.com/elastic/kibana/pull/23378) for easier review.

## Saved Objects Client Extensions
A bulk of the changes to the saved objects service are in the namespaces PR, but we have a couple of important changes included here.

### Priority Queue for wrappers
We have implemented a priority queue which allows plugins to specify the order in which their SOC wrapper should be applied: `kibana/src/server/saved_objects/service/lib/priority_collection.ts`. We are leveraging this to ensure that both the security SOC wrapper and the spaces SOC wrapper are applied in the correct order (more details below).

### Spaces SOC Wrapper
This wrapper is very simple, and it is only responsible for two things:
1) Prevent users from interacting with any `space` objects (use the Spaces client instead, described below)
2) Provide a `namespace` to the underlying Saved Objects Client, and ensure that no other wrappers/callers have provided a namespace. In order to accomplish this, the Spaces wrapper uses the priority queue to ensure that it is the last wrapper invoked before calling the underlying client.

### Security SOC Wrapper
This wrapper is responsible for performing authorization checks. It uses the priority queue to ensure that it is the first wrapper invoked. To say another way, if the authorization checks fail, then no other wrappers will be called, and the base client will not be called either. This wrapper authorizes users in one of two ways: RBAC or Legacy. More details on this are below.


### Examples:
`GET /s/marketing/api/saved_objects/index-pattern/foo`

**When both Security and Spaces are enabled:**
1) Saved objects API retrieves an instance of the SOC via `savedObjects.getScopedClient()`, and invokes its `get` function
2) The Security wrapper is invoked.
    a) Authorization checks are performed to ensure user can access this particular saved object at this space.
3) The Spaces wrapper is invoked.
   a) Spaces applies a `namespace` to be used by the underlying client
4) The underlying client/repository are invoked to retrieve the object from ES.

**When only Spaces are enabled:**
1) Saved objects API retrieves an instance of the SOC via `savedObjects.getScopedClient()`, and invokes its `get` function
2) The Spaces wrapper is invoked.
   a) Spaces applies a `namespace` to be used by the underlying client
3) The underlying client/repository are invoked to retrieve the object from ES.

**When only Security is enabled:**
(assume `/s/marketing` is no longer part of the request)
1) Saved objects API retrieves an instance of the SOC via `savedObjects.getScopedClient()`, and invokes its `get` function
2) The Security wrapper is invoked.
   a) Authorization checks are performed to ensure user can access this particular saved object globally.
3) The underlying client/repository are invoked to retrieve the object from ES.

## Authorization
Authorization changes for this project are centered around Saved Objects, and builds on the work introduced in RBAC Phase 1.

### Saved objects client
#### Security without spaces
When security is enabled, but spaces is disabled, then the authorization model behaves the same way as before: If the user is taking advantage of Kibana Privileges, then we check their privileges "globally" before proceeding. A "global" privilege check specifies `resources: ['*']` when calling the [ES _has_privileges api.](https://www.elastic.co/guide/en/elasticsearch/reference/current/security-api-has-privileges.html). Legacy users (non-rbac) will continue to use the underlying index privileges for authorization.

#### Security with spaces
When both plugins are enabled, then the authorization model becomes more fine-tuned. Rather than checking privileges globally, the privileges are checked against a specific resource that matches the user's active space. In order to accomplish this, the Security plugin needs to know if Spaces is enabled, and if so, it needs to ask Spaces for the user's active space. The subsequent call to the `ES _has_privileges api` would use `resources: ['space:marketing']` to verify that the user is authorized at the `marketing` space. Legacy users (non-rbac) will continue to use the underlying index privileges for authorization. **NOTE** The legacy behavior implies that those users will have access to all spaces. The read/write restrictions are still enforced, but there is no way to restrict access to a specific space for legacy auth users.

#### Spaces without security
No authorization performed. Everyone can access everything.

### Spaces client
Spaces, when enabled, prevents saved objects of type `space` from being CRUD'd via the Saved Objects Client. Instead, the only "approved" way to work with these objects is through the new Spaces client (`kibana/x-pack/plugins/spaces/lib/spaces_client.ts`).

When security is enabled, the Spaces client performs its own set of authorization checks before allowing the request to proceed. The Spaces client knows which authorization checks need to happen for a particular request, but it doesn't know _how_ to check privileges. To accomplish this, the spaces client will delegate the check security's authorization service.

#### FAQ: Why oh why can't you used the Saved Objects Client instead!?
That's a great question! We did this primarily to simplify the authorization model (at least for our initial release). Accessing regular saved objects follows a predictible authorization pattern (described above). Spaces themselves inform the authorization model, and this interplay would have greatly increased the complexity. We are brainstorming ideas to obselete the Spaces client in favor of using the Saved Objects Client everywhere, but that's certainly out of scope for this release.



## Test Coverage
### Saved Objects API
A bulk of the changes to enable spaces are centered around saved objects, so we have spent a majority of our time automating tests against the saved objects api.

**`x-pack/test/saved_object_api_integration/`** contains the test suites for the saved objects api. There is a `common/suites` subfolder which contains a bulk of the test logic. The suites defined here are used in the following test configurations:
1) Spaces only: `./spaces_only`
2) Security and spaces: `./security_and_spaces`
3) Security only: `./security_only`

Each of these test configurations will start up ES/Kibana with the appropriate license and plugin set. Each set runs through the entire test suite described in `common/suites`. Each test with in each suite is run multiple times with different inputs, to test the various permutations of authentication, authorization type (legacy vs RBAC), space-level privileges, and the user's active space.  

### Spaces API
Spaces provides an experimental public API.

**`x-pack/test/spaces_api_integration`** contains the test suites for the Spaces API. Similar to the Saved Objects API tests described above, there is a `common/suites` folder which contains a bulk of the test logic. The suites defined here are used in the following test configurations:
1) Spaces only: `./spaces_only`
2) Security and spaces: `./security_and_spaces`


### Role Management UI
We did not provide any new functional UI tests for role management, but the existing suite was updated to accomidate the screen rewrite.

We do have a decent suite of jest unit tests for the various components that make up the new role management screen. They're nested within `kibana/x-pack/plugins/security/public/views/management/edit_role`

### Spaces Management UI
We did not provide any new functional UI tests for spaces management, but the components that make up the screens are well-tested, and can be found within `kibana/x-pack/plugins/spaces/public/views/management/edit_space`

### Spaces Functional UI Tests
There are a couple of UI tests that verify _basic_ functionality. They assert that a user can login, select a space, and then choose a different space once inside: `kibana/x-pack/test/functional/apps/spaces`



## Reference

Notable child PRs are listed below for easier digesting. Note that some of these PRs are built on other PRs, so the deltas in the links below may be outdated. Cross reference with this PR when in doubt.

### UI
- Reactify Role Management Screen: https://github.com/elastic/kibana/pull/19035
- Space Aware Privileges UI: https://github.com/elastic/kibana/pull/21049
- Space Selector (in Kibana Nav): https://github.com/elastic/kibana/pull/19497
- Recently viewed Widget: https://github.com/elastic/kibana/pull/22492
- Support Space rename/delete: https://github.com/elastic/kibana/pull/22586

### Saved Objects Client
- ~~Space Aware Saved Objects: https://github.com/elastic/kibana/pull/18862~~
- ~~Add Space ID to document id: https://github.com/elastic/kibana/pull/21372~~
- Saved object namespaces (supercedes #18862 and #21372):  https://github.com/elastic/kibana/pull/22357
- Securing saved objects: https://github.com/elastic/kibana/pull/21995
- Dedicated Spaces client (w/ security): https://github.com/elastic/kibana/pull/21995

### Other
- Public Spaces API (experimental): https://github.com/elastic/kibana/pull/22501
- Telemetry: https://github.com/elastic/kibana/pull/20581
- Reporting: https://github.com/elastic/kibana/pull/21457
- Spencer's original Spaces work: https://github.com/elastic/kibana/pull/18664
- Expose `spaceId` to "Add Data" tutorials: https://github.com/elastic/kibana/pull/22760

Closes #18948 

"Release Note: Create spaces within Kibana to organize dashboards, visualizations, and other saved objects. Secure access to each space when X-Pack Security is enabled"
2018-10-01 07:09:33 -04:00
Martijn Rondeel 7f1ee07405 Add ElastAlert Kibana Plugin to known plugins list (#23598)
* Add ElastAlert Kibana Plugin to known plugins list

* Add author of ElastAlert plugin
2018-09-28 10:47:27 +02:00
Lisa Cawley 186cea2d74
[DOCS] Adds TLS info to licensing page (#20638) 2018-09-27 10:09:14 -07:00
Tim Roes 832b896877
Remove last mentions of spy panels (#23527) 2018-09-26 16:53:23 +02:00
Matt Bargar fceddf8610
Mention license change for autocomplete 2018-09-25 12:45:22 -04:00
Larry Gregory 33acd60f9f
Remove ability to implicitly find across all types (#23198) 2018-09-19 07:22:43 -04:00
Lisa Cawley 428ee421ee
[DOCS] Adds troubleshooting info for monitoring (#21005) 2018-09-17 18:27:36 -07:00
Jonathan Budzenski f5d44f6d9f
Add optimize and --no-optimize flags (#16302)
* Add optimize flags

* update docs to --no-optimize

* docs

* extra newline

* lint

* update mocks

* update default config

* update snapshots
2018-09-17 12:45:51 -05:00
Jonathan Budzenski cc10fc02f6
[es] set default port based on protocol (#21564)
* [es] set default port based on protocol

* explicit https/http check

* url parses port as string

* breaking changes docs

* remove 9200 fallback
2018-09-17 09:54:05 -05:00
Caroline Horn 9c83f81f08
Visualize LESS to SASS (#22679) 2018-09-14 13:25:03 -04:00
Lisa Cawley 8ed6084db9
[DOCS] Synchronize location of Breaking Changes (#22939) 2018-09-12 09:19:38 -07:00