Skip to content

Commit

Permalink
Merge branch '7.16' into deprecations/os-packages
Browse files Browse the repository at this point in the history
  • Loading branch information
kibanamachine authored Dec 6, 2021
2 parents 79b8afd + 1a063c2 commit c52aecc
Show file tree
Hide file tree
Showing 14 changed files with 494 additions and 89 deletions.
420 changes: 420 additions & 0 deletions docs/CHANGELOG.asciidoc

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion docs/settings/alert-action-settings.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -131,7 +131,7 @@ into a single string. This configuration can be used for environments where
the files cannot be made available.

`xpack.actions.enabledActionTypes` {ess-icon}::
A list of action types that are enabled. It defaults to `[*]`, enabling all types. The names for built-in {kib} action types are prefixed with a `.` and include: `.server-log`, `.slack`, `.email`, `.index`, `.pagerduty`, and `.webhook`. An empty list `[]` will disable all action types.
A list of action types that are enabled. It defaults to `[*]`, enabling all types. The names for built-in {kib} action types are prefixed with a `.` and include: `.email`, `.index`, `.jira`, `.pagerduty`, `.resilient`, `.server-log`, `.servicenow`, .`servicenow-itom`, `.servicenow-sir`, `.slack`, `.swimlane`, `.teams`, and `.webhook`. An empty list `[]` will disable all action types.
+
Disabled action types will not appear as an option when creating new connectors, but existing connectors and actions of that type will remain in {kib} and will not function.

Expand Down
23 changes: 10 additions & 13 deletions docs/settings/url-drilldown-settings.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -6,20 +6,18 @@

Configure the URL drilldown settings in your `kibana.yml` configuration file.

[cols="2*<"]
|===
| [[url-drilldown-enabled]] `url_drilldown.enabled`
| deprecated:[7.16.0,"In 8.0 and later, this setting will no longer be supported."]
When `true`, enables URL drilldowns on your {kib} instance.

| [[external-URL-policy]] `externalUrl.policy`
| Configures the external URL policies. URL drilldowns respect the global *External URL* service, which you can use to deny or allow external URLs.
By default all external URLs are allowed.
|===

For example, to allow external URLs only to the `example.com` domain with the `https` scheme, except for the `danger.example.com` sub-domain,
which is denied even when `https` scheme is used:
[[url-drilldown-enabled]] `url_drilldown.enabled`::
deprecated:[7.16.0,"In 8.0 and later, this setting will no longer be supported."]
When `true`, enables URL drilldowns on your {kib} instance.

[[external-URL-policy]] `externalUrl.policy`::
Configures the external URL policies. URL drilldowns respect the global *External URL* service, which you can use to deny or allow external URLs.
By default all external URLs are allowed.
+
This example allows external URLs only to the `example.com` domain with the `https` scheme, except for the `danger.example.com` sub-domain,
which is denied even when `https` scheme is used.
+
["source","yml"]
-----------
externalUrl.policy:
Expand All @@ -29,4 +27,3 @@ externalUrl.policy:
host: example.com
protocol: https
-----------

2 changes: 1 addition & 1 deletion docs/setup/settings.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -225,7 +225,7 @@ In addition to this setting, trusted certificates may be specified via
<<elasticsearch-ssl-keystore-path, `elasticsearch.ssl.keystore.path`>> and/or
<<elasticsearch-ssl-truststore-path, `elasticsearch.ssl.truststore.path`>>.

| `elasticsearch.ssl.keyPassphrase:`
| [[elasticsearch-ssl-keyPassphrase]] `elasticsearch.ssl.keyPassphrase:`
| The password that decrypts the private key that is specified
via <<elasticsearch-ssl-cert-key, `elasticsearch.ssl.key`>>. This value is optional, as the key may not be
encrypted.
Expand Down
41 changes: 0 additions & 41 deletions docs/user/dashboard/dashboard-troubleshooting.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -26,44 +26,3 @@ To enable *Labs*, contact your administrator, or configure the <<presentation-la

. Click *Close*.

[float]
[[migrate-timelion-app-worksheets]]
=== Migrate Timelion app worksheets

deprecated::[The *Timelion* app is deprecated in 7.0.0, and will be removed in 7.16.0. To prepare for the removal of *Timelion* app, you must migrate *Timelion* app worksheets to a dashboard.

. Open the main menu, then click *Dashboard*.

. On the *Dashboards* page, click *Create dashboard*.

. For each *Timelion* app worksheet, create a visualization with the *Timelion* editor.

.. On the dashboard, click *All types > Aggregation based*, then select *Timelion*.

.. In your browser, open a new tab, the open the *Timelion* app.

.. Select the chart you want to copy, then copy the chart expression.
+
[role="screenshot"]
image::images/timelion-copy-expression.png[Timelion app chart]

.. Go to the *Timelion* editor, paste the chart expression in the *Timelion expression* field, then click *Update*.
+
[role="screenshot"]
image::images/timelion-vis-paste-expression.png[Timelion advanced editor UI]

. Save the visualization.

.. In the toolbar, click *Save to library*.

.. Enter the *Title* and add any applicable <<managing-tags,*Tags*>>.

.. Make sure that *Add to Dashboard after saving* is selected.

.. Click *Save and return*.
+
The Timelion visualization panel appears on the dashboard.
+
[role="screenshot"]
image::user/dashboard/images/timelion-dashboard.png[Final dashboard with saved Timelion app worksheet]

2 changes: 0 additions & 2 deletions docs/user/dashboard/timelion.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,6 @@ The syntax enables some features that classical point series charts don't offer,
[role="screenshot"]
image:dashboard/images/timelion.png[Timelion]

deprecated::[7.0.0,"*Timelion* is still supported. The *Timelion app* is deprecated in 7.0, replaced by dashboard features. In 7.16 and later, the *Timelion app* is removed from {kib}. To prepare for the removal of *Timelion app*, you must migrate *Timelion app* worksheets to a dashboard. For information on how to migrate *Timelion app* worksheets, refer to <<migrate-timelion-app-worksheets,Migrate Timelion app worksheets>>."]

[float]
==== Timelion expressions

Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -193,7 +193,7 @@
"base64-js": "^1.3.1",
"bluebird": "3.5.5",
"brace": "0.11.1",
"broadcast-channel": "^4.2.0",
"broadcast-channel": "^4.7.0",
"chalk": "^4.1.0",
"cheerio": "^1.0.0-rc.10",
"chokidar": "^3.4.3",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,12 @@ describe('InvestigateInResolverAction', () => {
});

test('it does NOT render AddToCase context menu item when timelineId is not in the allowed list', () => {
const wrapper = mount(<AlertContextMenu {...props} timelineId="timeline-test" />, {
// In order to enable alert context menu without a timelineId, event needs to be event.kind === 'event' and agent.type === 'endpoint'
const customProps = {
...props,
ecsRowData: { ...ecsRowData, agent: { type: ['endpoint'] }, event: { kind: ['event'] } },
};
const wrapper = mount(<AlertContextMenu {...customProps} timelineId="timeline-test" />, {
wrappingComponent: TestProviders,
});
wrapper.find(actionMenuButton).simulate('click');
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -164,6 +164,7 @@ const AlertContextMenuComponent: React.FC<AlertContextMenuProps & PropsFromRedux
});
const { eventFilterActionItems } = useEventFilterAction({
onAddEventFilterClick: handleOnAddEventFilterClick,
disabled: !isEvent,
});
const items: React.ReactElement[] = useMemo(
() =>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -227,7 +227,7 @@ describe('take action dropdown', () => {
});
});

test('should disable the "Add Endpoint event filter" button if provided non-event or non-endpoint', async () => {
test('should hide the "Add Endpoint event filter" button if provided no event from endpoint', async () => {
wrapper = mount(
<TestProviders>
<TakeActionDropdown
Expand All @@ -239,9 +239,7 @@ describe('take action dropdown', () => {
);
wrapper.find('button[data-test-subj="take-action-dropdown-btn"]').simulate('click');
await waitFor(() => {
expect(
wrapper.find('[data-test-subj="add-event-filter-menu-item"]').first().getDOMNode()
).toBeDisabled();
expect(wrapper.exists('[data-test-subj="add-event-filter-menu-item"]')).toBeFalsy();
});
});
});
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -91,8 +91,6 @@ export const TakeActionDropdown = React.memo(

const isEndpointEvent = useMemo(() => isEvent && isAgentEndpoint, [isEvent, isAgentEndpoint]);

const disableEventFilterAction = useMemo(() => !isEndpointEvent, [isEndpointEvent]);

const togglePopoverHandler = useCallback(() => {
setIsPopoverOpen(!isPopoverOpen);
}, [isPopoverOpen]);
Expand Down Expand Up @@ -141,7 +139,7 @@ export const TakeActionDropdown = React.memo(

const { eventFilterActionItems } = useEventFilterAction({
onAddEventFilterClick: handleOnAddEventFilterClick,
disabled: disableEventFilterAction,
disabled: !isEndpointEvent,
});

const afterCaseSelection = useCallback(() => {
Expand All @@ -167,8 +165,17 @@ export const TakeActionDropdown = React.memo(
() =>
!isEvent && actionsData.ruleId
? [...statusActionItems, ...exceptionActionItems]
: eventFilterActionItems,
[eventFilterActionItems, exceptionActionItems, statusActionItems, isEvent, actionsData.ruleId]
: isEndpointEvent
? eventFilterActionItems
: [],
[
eventFilterActionItems,
isEndpointEvent,
exceptionActionItems,
statusActionItems,
isEvent,
actionsData.ruleId,
]
);

const { addToCaseActionItems } = useAddToCaseActions({
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -169,7 +169,7 @@ describe('Actions', () => {
wrapper.find('[data-test-subj="timeline-context-menu-button"]').first().prop('isDisabled')
).toBe(false);
});
test('it enables for event.kind: alert and agent.type: endpoint', () => {
test('it disables for event.kind: alert and agent.type: endpoint', () => {
const ecsData = {
...mockTimelineData[0].ecs,
event: { kind: ['alert'] },
Expand All @@ -183,7 +183,7 @@ describe('Actions', () => {

expect(
wrapper.find('[data-test-subj="timeline-context-menu-button"]').first().prop('isDisabled')
).toBe(false);
).toBe(true);
});
test('it shows the analyze event button when the event is from an endpoint', () => {
const ecsData = {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -107,10 +107,7 @@ const ActionsComponent: React.FC<ActionProps> = ({
const isContextMenuDisabled = useMemo(
() =>
eventType !== 'signal' &&
!(
(ecsData.event?.kind?.includes('event') || ecsData.event?.kind?.includes('alert')) &&
ecsData.agent?.type?.includes('endpoint')
),
!(ecsData.event?.kind?.includes('event') && ecsData.agent?.type?.includes('endpoint')),
[eventType, ecsData.event?.kind, ecsData.agent?.type]
);

Expand Down
51 changes: 37 additions & 14 deletions yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -1268,7 +1268,7 @@
core-js-pure "^3.0.0"
regenerator-runtime "^0.13.4"

"@babel/runtime@7.3.1", "@babel/runtime@^7.0.0", "@babel/runtime@^7.1.2", "@babel/runtime@^7.10.2", "@babel/runtime@^7.11.2", "@babel/runtime@^7.12.5", "@babel/runtime@^7.13.10", "@babel/runtime@^7.14.0", "@babel/runtime@^7.16.3", "@babel/runtime@^7.3.1", "@babel/runtime@^7.4.4", "@babel/runtime@^7.4.5", "@babel/runtime@^7.5.0", "@babel/runtime@^7.5.5", "@babel/runtime@^7.6.2", "@babel/runtime@^7.6.3", "@babel/runtime@^7.7.2", "@babel/runtime@^7.7.6", "@babel/runtime@^7.8.4", "@babel/runtime@^7.8.7", "@babel/runtime@^7.9.2":
"@babel/runtime@7.3.1", "@babel/runtime@^7.0.0", "@babel/runtime@^7.1.2", "@babel/runtime@^7.10.2", "@babel/runtime@^7.11.2", "@babel/runtime@^7.12.5", "@babel/runtime@^7.13.10", "@babel/runtime@^7.14.0", "@babel/runtime@^7.16.0", "@babel/runtime@^7.16.3", "@babel/runtime@^7.3.1", "@babel/runtime@^7.4.4", "@babel/runtime@^7.4.5", "@babel/runtime@^7.5.0", "@babel/runtime@^7.5.5", "@babel/runtime@^7.6.2", "@babel/runtime@^7.6.3", "@babel/runtime@^7.7.2", "@babel/runtime@^7.7.6", "@babel/runtime@^7.8.4", "@babel/runtime@^7.8.7", "@babel/runtime@^7.9.2":
version "7.16.3"
resolved "https://registry.yarnpkg.com/@babel/runtime/-/runtime-7.16.3.tgz#b86f0db02a04187a3c17caa77de69840165d42d5"
integrity sha512-WBwekcqacdY2e9AF/Q7WLFUWmdJGJTkbjqTjoMDgXkVZ3ZRUvOPsLb5KdwISoQVsbP+DQzVZW4Zhci0DvpbNTQ==
Expand Down Expand Up @@ -8746,19 +8746,19 @@ broadcast-channel@^3.4.1:
rimraf "3.0.2"
unload "2.2.0"

broadcast-channel@^4.2.0:
version "4.2.0"
resolved "https://registry.yarnpkg.com/broadcast-channel/-/broadcast-channel-4.2.0.tgz#9ca93a23a31036266c2c9b0f8f55bd21594b8f82"
integrity sha512-XX9yNnIy/v2T+HR5EKIH7ziM2mYTefsrzZ2lkCmFZxwCDG7Ns7HLIooUXA114sCeFRJ4MEXEgdMapxfPDh9Xkg==
broadcast-channel@^4.7.0:
version "4.7.0"
resolved "https://registry.yarnpkg.com/broadcast-channel/-/broadcast-channel-4.7.0.tgz#4f5c31982f627eae4ffe463623ba36a9e7da1992"
integrity sha512-1C7wDPqeiKkwpScqFP044MsPAtxxDNKZzOnJmkHaTuOlUdaMLo11op56NrCOMiRh8dzktstcNsiHELGeTMKnNQ==
dependencies:
"@babel/runtime" "^7.7.2"
"@babel/runtime" "^7.16.0"
detect-node "^2.1.0"
js-sha3 "0.8.0"
microseconds "0.2.0"
nano-time "1.0.0"
oblivious-set "1.0.0"
p-queue "6.6.2"
rimraf "3.0.2"
unload "2.2.0"
unload "2.3.1"

brorand@^1.0.1, brorand@^1.1.0:
version "1.1.0"
Expand Down Expand Up @@ -11921,16 +11921,16 @@ detect-newline@3.1.0, detect-newline@^3.0.0:
resolved "https://registry.yarnpkg.com/detect-newline/-/detect-newline-3.1.0.tgz#576f5dfc63ae1a192ff192d8ad3af6308991b651"
integrity sha512-TLz+x/vEXm/Y7P7wn1EJFNLxYpUD4TgMosxY6fAVJUnJMbupHBOncxyWUG9OpTaH9EBD7uFI5LfEgmMOc54DsA==

detect-node@2.1.0, detect-node@^2.1.0:
version "2.1.0"
resolved "https://registry.yarnpkg.com/detect-node/-/detect-node-2.1.0.tgz#c9c70775a49c3d03bc2c06d9a73be550f978f8b1"
integrity sha512-T0NIuQpnTvFDATNuHN5roPwSBG83rFsuO+MXXH9/3N1eFbn4wcPjttvjMLEPWJ0RGUYgQE7cGgS3tNxbqCGM7g==

detect-node@^2.0.4:
version "2.0.4"
resolved "https://registry.yarnpkg.com/detect-node/-/detect-node-2.0.4.tgz#014ee8f8f669c5c58023da64b8179c083a28c46c"
integrity sha512-ZIzRpLJrOj7jjP2miAtgqIfmzbxa4ZOr5jJc601zklsfEx9oTzmmj2nVpIPRpNlRTIh8lc1kyViIY7BWSGNmKw==

detect-node@^2.1.0:
version "2.1.0"
resolved "https://registry.yarnpkg.com/detect-node/-/detect-node-2.1.0.tgz#c9c70775a49c3d03bc2c06d9a73be550f978f8b1"
integrity sha512-T0NIuQpnTvFDATNuHN5roPwSBG83rFsuO+MXXH9/3N1eFbn4wcPjttvjMLEPWJ0RGUYgQE7cGgS3tNxbqCGM7g==

detect-port-alt@1.1.6:
version "1.1.6"
resolved "https://registry.yarnpkg.com/detect-port-alt/-/detect-port-alt-1.1.6.tgz#24707deabe932d4a3cf621302027c2b266568275"
Expand Down Expand Up @@ -13361,7 +13361,7 @@ eventemitter2@^6.4.3:
resolved "https://registry.yarnpkg.com/eventemitter2/-/eventemitter2-6.4.3.tgz#35c563619b13f3681e7eb05cbdaf50f56ba58820"
integrity sha512-t0A2msp6BzOf+QAcI6z9XMktLj52OjGQg+8SJH6v5+3uxNpWYRR3wQmfA+6xtMU9kOC59qk9licus5dYcrYkMQ==

eventemitter3@^4.0.0:
eventemitter3@^4.0.0, eventemitter3@^4.0.4:
version "4.0.7"
resolved "https://registry.yarnpkg.com/eventemitter3/-/eventemitter3-4.0.7.tgz#2de9b68f6528d5644ef5c59526a1b4a07306169f"
integrity sha512-8guHBZCwKnFhYdHr2ysuRWErTwhoN2X8XELRlrRwpmfeY2jjuUN4taQMsULKUVo1K4DvZl+0pgfyoysHxvmvEw==
Expand Down Expand Up @@ -21299,6 +21299,14 @@ p-map@^4.0.0:
dependencies:
aggregate-error "^3.0.0"

p-queue@6.6.2:
version "6.6.2"
resolved "https://registry.yarnpkg.com/p-queue/-/p-queue-6.6.2.tgz#2068a9dcf8e67dd0ec3e7a2bcb76810faa85e426"
integrity sha512-RwFpb72c/BhQLEXIZ5K2e+AhgNVmIejGlTgiB9MzZ0e93GRvqZ7uSi0dvRF7/XIXDeNkra2fNHBxTyPDGySpjQ==
dependencies:
eventemitter3 "^4.0.4"
p-timeout "^3.2.0"

p-retry@^3.0.1:
version "3.0.1"
resolved "https://registry.yarnpkg.com/p-retry/-/p-retry-3.0.1.tgz#316b4c8893e2c8dc1cfa891f406c4b422bebf328"
Expand All @@ -21321,6 +21329,13 @@ p-timeout@^2.0.1:
dependencies:
p-finally "^1.0.0"

p-timeout@^3.2.0:
version "3.2.0"
resolved "https://registry.yarnpkg.com/p-timeout/-/p-timeout-3.2.0.tgz#c7e17abc971d2a7962ef83626b35d635acf23dfe"
integrity sha512-rhIwUycgwwKcP9yTOOFK/AKsAopjjCakVqLHePO3CC6Mir1Z99xT+R63jZxAT5lFZLa2inS5h+ZS2GvR99/FBg==
dependencies:
p-finally "^1.0.0"

p-try@^1.0.0:
version "1.0.0"
resolved "https://registry.yarnpkg.com/p-try/-/p-try-1.0.0.tgz#cbc79cdbaf8fd4228e13f621f2b1a237c1b207b3"
Expand Down Expand Up @@ -28323,6 +28338,14 @@ unload@2.2.0:
"@babel/runtime" "^7.6.2"
detect-node "^2.0.4"

unload@2.3.1:
version "2.3.1"
resolved "https://registry.yarnpkg.com/unload/-/unload-2.3.1.tgz#9d16862d372a5ce5cb630ad1309c2fd6e35dacfe"
integrity sha512-MUZEiDqvAN9AIDRbbBnVYVvfcR6DrjCqeU2YQMmliFZl9uaBUjTkhuDQkBiyAy8ad5bx1TXVbqZ3gg7namsWjA==
dependencies:
"@babel/runtime" "^7.6.2"
detect-node "2.1.0"

unpipe@1.0.0, unpipe@~1.0.0:
version "1.0.0"
resolved "https://registry.yarnpkg.com/unpipe/-/unpipe-1.0.0.tgz#b2bf4ee8514aae6165b4817829d21b2ef49904ec"
Expand Down

0 comments on commit c52aecc

Please sign in to comment.