Commit graph

17955 commits

Author SHA1 Message Date
Brandon Kobel
15e3e59249
Switching from jade to pug (#21047)
* Upgrading pug

* Switching .jade to .pug and fixing templates

* Renaming the I18N usages of jade to pug

* No more jade in I18N
2018-07-27 07:21:27 -04:00
Tim Roes
bd03506736
Wait for visualizations to render in tests (#21258)
* Wait for visualizations to render

* Use Visualize.waitForRender on dashboard

* Enable previously flaky dashboard tests again

* Add data-loading for initial render

* Remove unnecessary timeout
2018-07-27 13:10:25 +02:00
James Gowdy
6c46e3b1d9
[ML] Updating invalid model memory limit message (#21329)
* [ ML] Updating invalid modal memory limit message

* changing to use template literal
2018-07-27 11:14:30 +01:00
Walter Rafelsberger
3b6c9e3195
[ML] Improves bucket span estimator stability. (#21282)
- Fixes the bucket span estimator when median is selected as a detector function. agg.type.name is median and therefor not usable for an Elasticsearch aggregation. agg.type.dslName is percentile and is the correct mapping. .dslName is also used for the aggregations used for the preview charts.
- 7.0 will introduce a search.max_buckets setting which defaults to 10000. This could lead to failing bucket estimations because the values used for creating the required aggregations could result in more buckets. This PR fixes it by taking search.max_buckets into account when calculating the time range used for the bucket estimation. (Since 6.2 that setting is available so backporting this to current unreleased minor releases 6.4 and 6.5)
2018-07-27 10:43:59 +02:00
Søren Louv-Jansen
256954259b
[APM] Fix duplicate service calls (#21271) 2018-07-27 10:43:11 +02:00
Pete Harverson
0ef0369569
[ML] Adds missing tooltips to custom URL editor buttons (#21279) 2018-07-27 09:39:07 +01:00
James Gowdy
60706bf77a
[ML] Better model memory limit validation (#21270) 2018-07-27 07:49:17 +01:00
CJ Cenizal
b328bd0e3d
Verify that we've navigated to Settings by checking the title. (#21245)
* Fail the consuming test if navigation to settings is unsuccessful.
* Add testSubjects.existOrFail helper.
2018-07-26 19:07:42 -07:00
CJ Cenizal
5fcd10ef71
Reenable import objects tests (#21250)
* Reenable import objects tests. Refine their assertions. Add primary callout to indicate completion of import process when the user has opted to not import anything.
2018-07-26 18:23:19 -07:00
Tyler Smalley
489e5bbbe6
[kbn-es] Only enable security for trial (#20803)
Signed-off-by: Tyler Smalley <tyler.smalley@elastic.co>
2018-07-26 14:41:06 -07:00
Matt Bargar
5eabdd530f
fix quote vs backtick typo (#21285) 2018-07-26 17:25:40 -04:00
James Gowdy
d1f6f8f71d
[ML] Displaying edit job save failures in error bar (#21268) 2018-07-26 21:09:36 +01:00
Thomas Neirynck
99d17292ab
Add EMS hot link (#21154)
Adds a dynamic hyperlink to the EMS landing page for EMS vector layers selected in the vector layer drop down of region maps.
2018-07-26 14:22:05 -04:00
Thomas Neirynck
27e8500b55
Always use EMS production url, even in dev (#21237)
This makes usage of EMS more predictable in Kibana, showing vetted production-ready data consistently
2018-07-26 14:03:16 -04:00
Rashmi Kulkarni
0499205f41
rbac functional ui test (#21188) 2018-07-26 08:56:20 -07:00
Pete Harverson
c16a82176d
[ML] Fixes enabled state of detector rule scope options (#21263)
* [ML] Fixes enabled state of detector rule scope options

* [ML] Edit to rule scope enabled check following review
2018-07-26 15:50:43 +01:00
Walter Rafelsberger
a121550791
[ML] Improved job validation messages. (#21191)
Improvements to job validation messages:
- Changed cardinality_over_field_low "might be less suitable" to "might not be suitable".
- Fixed documentation URLs.
- Extended categorization_filters_invalid message + documentation URL.
2018-07-26 16:32:44 +02:00
James Gowdy
a99140dad4
[ML] Clear bucket span invalid label (#21262) 2018-07-26 14:09:37 +01:00
Stacey Gammon
38dcda0e6b
Fix refreshed dashboard losing time range (#20858)
* Add test that would have caught the bug

* Initialize global state with current time range

* Fix issue with failing tests - need to remove added "t" parameter to the url in the new tests

* remove unneccessary extra call

* Fix tests that failed due to globally added time in new tests

* Update home page test to not care about any state.
2018-07-26 08:53:18 -04:00
Pete Harverson
124ec66676
[ML] Fix saving of custom URLs for job created in Advanced page (#21207)
* [ML] Fix saving of custom URLs for job created in Advanced page

* [ML] Edit to custom URL save custom_settings following review
2018-07-26 09:23:22 +01:00
dave.snider@gmail.com
58eefb88b8
Add bolilerplate sass for Kibana core (#21185)
* Add bolilerplate sass for Kibana core
2018-07-25 18:23:04 -07:00
Tim Sullivan
72b779c350
[Test] Add Reporting in test on kibana_stats telemetry (#21118) 2018-07-25 16:48:06 -07:00
Lukas Olson
8a6c531c69
fix: kuery autocomplete in apm (#21249) 2018-07-25 16:39:34 -07:00
dave.snider@gmail.com
b831ecf000
Prune our usage of bootstrap (#21186)
* remove bootstrap glyphicons

* remove bootstrap scaffolding

* prune type, remove code from bootstrap

* remove bootstrap breadcrumb

* remove normalize from bootstrap

* remove thumbnail from bootstrap

* remove jumbotron from bootstrap

* remove wells from bootstrap

* remove bootstrap badge
2018-07-25 15:10:56 -07:00
Lee Drengenberg
43d41f7205
Add method to wait for loading to complete in Add Panel table (#21109)
* Add method to wait for loading to complete in Add Panel table

* remove extra retry loop
2018-07-25 15:04:24 -05:00
James Gowdy
f87ef518b3
[ML] Fix start datafeed start time selection (#21203)
* [ML] Fix start datafeed start time selection

* disabling start button if start and end are the same

* adding comment
2018-07-25 20:24:18 +01:00
Tyler Smalley
f82b9717c0
Adds 6.4 branch to backports config (#21217)
Signed-off-by: Tyler Smalley <tyler.smalley@elastic.co>
2018-07-25 11:02:58 -07:00
Caroline Horn
09d16b3d62
Fix page layout on Reporting page (#21218)
fixes #21212
2018-07-25 13:44:13 -04:00
Tyler Smalley
1d1c9e8b1a
Updates status page to reflect /api/stats changes (#21055)
Signed-off-by: Tyler Smalley <tyler.smalley@elastic.co>
2018-07-25 10:40:50 -07:00
Tyler Smalley
1cc4673f15
Updates messaging when X-Pack is unavailable (#21221)
Signed-off-by: Tyler Smalley <tyler.smalley@elastic.co>
2018-07-25 10:37:51 -07:00
Brandon Kobel
cde20fca60
Fixing issue with the edit user overwriting user input (#21206) 2018-07-25 12:50:47 -04:00
Walter Rafelsberger
d4efed5842
[ML] Make script_fields available on dropdowns of the advanced wirzard's detectors modal. (#21205)
- If a job configuration's datafeed contains script_fields, they are now available in the field dropdowns of the advanced wizard's detector modal.
- Additionally, job validation now considers script_fields and doesn't report them as non aggregatable anymore.
2018-07-25 18:46:10 +02:00
Nathan Reese
d933175297
decouple x-pack security tests from dashboard_mode tests (#21043) 2018-07-25 10:15:23 -06:00
James Gowdy
50b9630748
[ML] Disabling results buttons on job multi-select (#21209) 2018-07-25 16:40:49 +01:00
James Gowdy
cd605e5bc1
[ML] Fixing min and max data picker options (#21197) 2018-07-25 12:52:37 +01:00
Pete Harverson
755409d31d
[ML] Prevents conditions on rules for rare, metric and lat_long (#21198) 2018-07-25 12:49:03 +01:00
Tim Roes
967cb4e7fb
TypeScriptify visualize loader (#21025)
* TypeScriptify Vis loaders

* Fix issue with undefined timeRange

* Fix chrome typing

* Fix unit tests

* Fix this issue

* Add missing uiState to request handler

* Implement Felix's suggestions

* Add timefilter listener
2018-07-25 07:56:31 +02:00
Tyler Smalley
716d6e2b8f
[security] Improve communication for ES/X-Pack being unavailable (#21124)
Previously if Elasticsearch was unavailable in the Kibana default distribution,
you would be prompted with a disabled login screen stating "Login is currently
disabled. Administrators should consult the Kibana logs for more details". This
was rather confusing for users who have a Basic license.

This now provides the user with a screen providing only the required
messaging.

Additionally, if you were using Kibana with a Basic license with an OSS
distribution of Elasticsearch, you would see the same disabled login
screen as mentioned previously.

This also separates the messaging there to provide clear details for the
user to resolve the issue.
2018-07-24 16:48:51 -07:00
Spencer
e117ae2169 [esArchiver] replace windows line-endings on parse (#21111)
* [esArchiver] replace windows line-endings on parse

* [esArchiver/parse/tests] feed a little extra data so replaceStream buffer is flushed
2018-07-24 17:31:34 -04:00
Chris Earle
2f082208f6
[Monitoring] Ignore Duplicate Shards (#21057)
[Monitoring] Ignore Duplicate Shards

This eliminates duplicate shards from the shard table by actively ignoring
them from the response.
2018-07-24 16:04:11 -04:00
Lukas Olson
ecc0f5e6e4
Extract KQL autocomplete to a plugin (#20747)
* fix: move autocomplete to x-pack basic

* fix: apm support

* fix: renames

* [uiExports] switch to new autocompleteProviders export type

* fix: remove unnecessary stuff from the plugin spec
2018-07-24 12:33:15 -07:00
Aaron Zhao
a56c856e0d Fix the dashboard start screen not centered bug on IE11 (#21066) 2018-07-24 12:17:22 -07:00
Nathan Reese
6c61abab0d
highlight sample data section for new users (#20953)
* highlight sample data section for new users

* do not set state on unmounted component

* do not block render of home component

* add jest tests for isNewKibanaInstance

* remove unneeded async from home jest test
2018-07-24 13:16:47 -06:00
Stacey Gammon
f471aaadf5
bump reporting timeout (#20833) 2018-07-24 14:36:33 -04:00
Felix Stürmer
146977fa99
Extend Chrome TypeScript type (#21076) 2018-07-24 20:30:50 +02:00
Chris Davies
b94dafa344
Add detection of invalid JSON searchSource to saved_object and dashboard (#20379) 2018-07-24 13:30:21 -04:00
James Gowdy
f3d88c9fbf
[ML] Disabling results buttons on row select (#21144) 2018-07-24 18:15:53 +01:00
Chris Roberson
92dd341f5c
[Monitoring] Use 0 as the default for shard count if the node is not found (#21000)
* Use 0 as the default for shard count if the node is not found

* Remove debug

* Updating snapshot tests

* Update api integration test
2018-07-24 12:56:10 -04:00
Brandon Kobel
248b124339
RBAC Phase 1 (#19723)
* partial implementation for OLS Phase 1

* Allow Saved Objects Client to be wrapped

* Add placeholder "kibana.namespace" configuration property

* revert changes to saved objects client

* Remove circular dependency

* Removing namespace setting, we're using xpack.security.rbac.application

* Adding config.getDefault

* Expose SavedObjectsClientProvider on the server for easy plugin consumption

* migrate x-pack changes into kibana

* Beginning to use the ES APIs to insert/check privileges (#18645)

* Beginning to use the ES APIs to insert/check privileges

* Removing todo comment, I think we're good with the current check

* Adding ability to edit kibana application privileges

* Introducing DEFAULT_RESOURCE constant

* Removing unused arguments when performing saved objects auth check

* Performing bulkCreate auth more efficiently

* Throwing error in SavedObjectClient.find if type isn't provided

* Fixing Reporting and removing errant console.log

* Introducing a separate hasPrivileges "service"

* Adding tests and fleshing out the has privileges "service"

* Fixing error message

* You can now edit whatever roles you want

* We're gonna throw the find error in another PR

* Changing conflicting version detection to work when user has no
application privileges

* Throwing correct error when user is forbidden

* Removing unused interceptor

* Adding warning if they're editing a role with application privileges we
can't edit

* Fixing filter...

* Beginning to only update privileges when they need to be

* More tests

* One more test...

* Restricting the rbac application name that can be chosen

* Removing DEFAULT_RESOURCE check

* Supporting 1024 characters for the role name

* Renaming some variables, fixing issue with role w/ no kibana privileges

* Throwing decorated general error when appropriate

* Fixing test description

* Dedent does nothing...

* Renaming some functions

* Adding built-in types and alphabetizing (#19306)

* Filtering out non-default resource Kibana privileges (#19321)

* Removing unused file

* Adding kibana_rbac_dashboard_only_user to dashboard only mode roles (#19511)

* Adding create default roles test (#19505)

* RBAC - SecurityAuditLogger (#19571)

* Manually porting over the AuditLogger for use within the security audit
logger

* HasPrivileges now returns the user from the request

* Has privileges returns username from privilegeCheck

* Adding first eventType to the security audit logger

* Adding authorization success message

* Logging arguments when authorization success

* Fixing test description

* Logging args during audit failures

* RBAC Integration Tests (#19647)

* Porting over the saved objects tests, a bunch are failing, I believe
because security is preventing the requests

* Running saved objects tests with rbac and xsrf disabled

* Adding users

* BulkGet now tests under 3 users

* Adding create tests

* Adding delete tests

* Adding find tests

* Adding get tests

* Adding bulkGet forbidden tests

* Adding not a kibana user tests

* Update tests

* Renaming the actions/privileges to be closer to the functions on the
saved object client itself

* Cleaning up tests and removing without index tests

I'm considering the without index tests to be out of scope for the RBAC
API testing, and we already have unit coverage for these and integration
coverage via the OSS Saved Objects API tests.

* Fixing misspelling

* Fixing "conflicts" after merging master

* Removing some white-space differences

* Deleting files that got left behind in a merge

* Adding the RBAC API Integration Tests

* SavedObjectClient.find filtering (#19708)

* Adding ability to specify filters when calling the repository

* Implementing find filtering

* Revert "Adding ability to specify filters when calling the repository"

This reverts commit 9da30a15db.

* Adding integration tests for find filtering

* Adding forbidden auth logging

* Adding asserts to make sure some audit log isn't used

* Adding more audit log specific tests

* Necessarly is not a work, unfortunately

* Fixing test

* More descriptive name than "result"

* Better unauthorized find message?

* Adding getTypes tests

* Trying to isolate cause of rbac test failures

* Adding .toLowerCase() to work around capitalization issue

* No longer exposing the auditLogger, we don't need it like that right now

* Removing some unused code

* Removing defaultSettings from test that doesn't utilize them

* Fixing misspelling

* Don't need an explicit login privilege when we have them all

* Removing unused code, fixing misspelling, adding comment

* Putting a file back

* No longer creating the roles on start-up (#19799)

* Removing kibana_rbac_dashboard_only_user from dashboard only role
defaults

* Fixing small issue with editing Kibana privileges

* [RBAC Phase 1] - Update application privileges when XPack license changes (#19839)

* Adding start to supporting basic license and switching to plat/gold

* Initialize application privilages on XPack license change

* restore mirror_status_and_initialize

* additional tests and peer review updates

* Introducing watchStatusAndLicenseToInitialize

* Adding some tests

* One more test

* Even better tests

* Removing unused mirrorStatusAndInitialize

* Throwing an error if the wrong status function is called

* RBAC Legacy Fallback (#19818)

* Basic implementation, rather sloppy

* Cleaning stuff up a bit

* Beginning to write tests, going to refactor how we build the privileges

* Making the buildPrivilegesMap no longer return application name as the
main key

* Using real privileges since we need to use them for the legacy fallback

* Adding more tests

* Fixing spelling

* Fixing test description

* Fixing comment description

* Adding similar line breaks in the has privilege calls

* No more settings

* No more rbac enabled setting, we just do RBAC

* Using describe to cleanup the test cases

* Logging deprecations when using the legacy fallback

* Cleaning up a bit...

* Using the privilegeMap for the legacy fallback tests

* Now with even less duplication

* Removing stray `rbacEnabled` from angularjs

* Fixing checkLicenses tests since we added RBAC

* [Flaky Test] - wait for page load to complete (#19895)

@kobelb this seems unrelated to our RBAC Phase 1 work, but I was able to consistently reproduce this on my machine.

* [Flaky Test] Fixes flaky role test (#19899)

Here's a fix for the latest flaky test @kobelb

* Now with even easier repository access

* Sample was including login/version privileges, which was occasionally (#19915)

causing issues that were really hard to replicate

* Dynamic types (#19925)

No more hard-coded types! This will make it so that plugins that register their own mappings just transparently work.

* start to address feedback

* Fix RBAC Phase 1 merge from master (#20226)

This updates RBAC Phase 1 to work against the latest master. Specifically:
1. Removes `xpack_main`'s `registerLicenseChangeCallback`, which we introduced in `security-app-privs`, in favor of `onLicenseInfoChange`, which was recently added to master
2. Updated `x-pack/plugins/security/server/lib/watch_status_and_license_to_initialize.js` to be compliant with rxjs v6

* Retrying initialize 20 times with a scaling backoff (#20297)

* Retrying initialize 20 times with a scaling backoff

* Logging error when we are registering the privileges

* Alternate legacy fallback (#20322)

* Beginning to use alternate callWithRequest fallback

* Only use legacy fallback when user has "some" privileges on index

* Logging useLegacyFallback when there's an authorization failure

* Adding tests, logging failure during find no types fallback

* Switching to using an enum instead of success/useLegacyFallback

* Using _execute to share some of the structure

* Moving comment to where it belongs

* No longer audit logging when we use the legacy fallback

* Setting the status to red on the first error then continually (#20343)

initializing

* Renaming get*Privilege to get*Action

* Adding "instance" to alert about other application privileges

* Revising some of the naming for the edit roles screen

* One more edit role variable renamed

* hasPrivileges is now checkPrivileges

* Revising check_license tests

* Adding 2 more privileges tests

* Moving the other _find method to be near his friend

* Spelling "returning" correctly, whoops

* Adding Privileges tests

* tests for Elasticsearch's privileges APIs

* Switching the hard-coded resource from 'default' to *

* Throw error before we  execute a POST privilege call that won't work

* Resolving issue when initially registering privileges

* Logging legacy fallback deprecation warning on login (#20493)

* Logging legacy fallback deprecation on login

* Consolidation the privileges/authorization folder

* Exposing rudimentary authorization service and fixing authenticate tests

* Moving authorization services configuration to initAuthorization

* Adding "actions" service exposed by the authorization

* Fixing misspelling

* Removing invalid and unused exports

* Adding note about only adding privileges

* Calling it initAuthorizationService

* Throwing explicit validation  error in actions.getSavedObjectAction

* Deep freezing authorization service

* Adding deepFreeze tests

* Checking privileges in one call and cleaning up tests

* Deriving application from Kibana index (#20614)

* Specifying the application on the "authorization service"

* Moving watchStatusAndLicenseToInitialize to be below initAuthorizationService

* Using short-hand propery assignment

* Validate ES has_privileges response before trusting it (#20682)

* validate elasticsearch has_privileges response before trusting it

* address feedback

* Removing unused setting

* Public Role APIs (#20732)

* Beginning to work on external role management APIs

* Refactoring GET tests and adding more permutations

* Adding test for excluding other resources

* Adding get role tests

* Splitting out the endpoints, or else it's gonna get overwhelming

* Splitting out the post and delete actions

* Beginning to work on POST and the tests

* Posting the updated role

* Adding update tests

* Modifying the UI to use the new public APIs

* Removing internal roles API

* Moving the rbac api integration setup tests to use the public role apis

* Testing field_security and query

* Adding create role tests

* We can't update the transient_metadata...

* Removing debugger

* Update and delete tests

* Returning a 204 when POSTing a Role.

* Switching POST to PUT and roles to role

* We don't need the rbacApplication client-side anymore

* Adding delete route tests

* Using not found instead of not acceptable, as that's more likely

* Only allowing us to PUT known Kibana privileges

* Removing transient_metadata

* Removing one letter variable names

* Using PUT instead of POST when saving roles

* Fixing broken tests

* Adding setting to allow the user to turn off the legacy fallback (#20766)

* Pulling the version from the kibana server

* Deleting unused file

* Add API integration tests for roles with index and app privileges (#21033)

* Rbac phase1 functional UI tests (#20949)

* rbac functional tests

*  changes to the test file

* RBAC_functional test

*  incorporating review feedback

* slight modification to the addPriv() to cover all tests

* removed the @ in secure roles and perm file in the describe block  and made it look more relevant

* Fixing role management API from users

* Set a timeout when we try/catch a find, so it doesn't pause a long time

* Changing the way we detect if a user is reserved for the ftr

* Skipping flaky test
2018-07-24 12:40:50 -04:00
Brandon Kobel
cbe9d389ce
Modifying the displayed URL when we can't connect to Elasticsearch (#21133)
The test has been modified to no longer rely upon @kbn/test as it was
providing very little benefit, and introduced some variability in
ensuring we were displaying the proper URL.
2018-07-24 12:07:25 -04:00