Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
39 commits
Select commit Hold shift + click to select a range
7ed7cd5
First draft of Kubernetes Dashboard doc
benironside Aug 3, 2022
5ff6760
Fixes a typo
benironside Aug 3, 2022
feb03b6
Fixes table format bug
benironside Aug 3, 2022
65a30fb
fixes for,attong
benironside Aug 3, 2022
e3f1e6b
Addresses Norrie's feedback
benironside Aug 8, 2022
bc8756c
Adds "kubernetes-specific data in session view" section
benironside Aug 8, 2022
29aeeff
Merge branch 'main' into issue-2213-big
benironside Aug 8, 2022
19ac01d
Addresses Quan's feedback
benironside Aug 8, 2022
3c2a32f
Merge branch 'issue-2213-big' of github.com:elastic/security-docs int…
benironside Aug 8, 2022
545486f
Incorporates Jack's feedback
benironside Aug 8, 2022
5a34aec
Addresses Jack's feedback
benironside Aug 8, 2022
d577e63
Fixes build errors
benironside Aug 8, 2022
3a5bb41
Incorporate Jack's feedback
benironside Aug 9, 2022
70328df
Update docs/dashboards/kubernetes-dashboard.asciidoc
benironside Aug 18, 2022
50ebc3f
Update docs/dashboards/kubernetes-dashboard.asciidoc
benironside Aug 18, 2022
a4b6694
Update docs/dashboards/kubernetes-dashboard.asciidoc
benironside Aug 18, 2022
19538f6
Update docs/dashboards/kubernetes-dashboard.asciidoc
benironside Aug 18, 2022
89ce5ab
Update docs/dashboards/kubernetes-dashboard.asciidoc
benironside Aug 18, 2022
102c60e
Update docs/dashboards/kubernetes-dashboard.asciidoc
benironside Aug 18, 2022
9d3ba69
Update docs/dashboards/kubernetes-dashboard.asciidoc
benironside Aug 18, 2022
257878d
Update docs/dashboards/kubernetes-dashboard.asciidoc
benironside Aug 18, 2022
26032ce
troubleshoot build failure
benironside Aug 22, 2022
4bddd1b
Update docs/dashboards/kubernetes-dashboard.asciidoc
benironside Aug 22, 2022
577d535
Incorporates Nastasha's and Joe's feedback
benironside Aug 22, 2022
6961cb4
Updates the Session View page to mention K8s data
benironside Aug 22, 2022
9342e37
troubleshoot build
benironside Aug 22, 2022
36d05ef
troubleshoot build
benironside Aug 22, 2022
4c87f6b
Merge branch 'main' into issue-2213-big
benironside Aug 22, 2022
3c526c9
Incorporates feedback
benironside Aug 22, 2022
e495573
Merge branch 'main' into issue-2213-big
benironside Aug 24, 2022
c58a8f1
Incorporates Janeen's, Nick's, and Quan's feedback
benironside Aug 24, 2022
3dfaf90
Merge branch 'issue-2213-big' of github.com:elastic/security-docs int…
benironside Aug 24, 2022
922818e
Merge branch 'main' into issue-2213-big
benironside Aug 24, 2022
3c5db4e
Merge branch 'main' into issue-2213-big
benironside Aug 24, 2022
5a2ef8e
Merge branch 'main' into issue-2213-big
benironside Aug 24, 2022
55a8e96
Reorg to better match other dashboards pages
benironside Aug 24, 2022
60ab479
Merge branch 'issue-2213-big' of github.com:elastic/security-docs int…
benironside Aug 24, 2022
214a4e7
Minor edit
benironside Aug 24, 2022
57c87e4
Final nits
benironside Aug 24, 2022
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions docs/dashboards/dashboards-overview.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -8,4 +8,6 @@ include::overview-dashboard.asciidoc[leveloffset=+1]

include::detection-response-dashboard.asciidoc[leveloffset=+1]

include::kubernetes-dashboard.asciidoc[leveloffset=+1]

include::cloud-posture.asciidoc[leveloffset=+1]
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/dashboards/images/metadata-tab.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/dashboards/images/session-data-config.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
81 changes: 81 additions & 0 deletions docs/dashboards/kubernetes-dashboard.asciidoc
Original file line number Diff line number Diff line change
@@ -0,0 +1,81 @@
[[kubernetes-dashboard]]
= Kubernetes dashboard

The Kubernetes dashboard provides insight into Linux process data from your Kubernetes clusters. It shows sessions in detail and in the context of your monitored infrastructure.

image::kubernetes-dashboard.png[The Kubernetes dashboard, with numbered labels 1 through 3 for major sections]
The numbered sections are described below:

1. The charts at the top of the dashboard provide an overview of your monitored Kubernetes infrastructure. You can hide them by clicking *Hide charts*.
2. The tree navigation menu allows you to navigate through your deployments and select the scope of the sessions table to the right. You can select any item in the menu to show its sessions. In Logical view, the menu is organized by Cluster, Namespace, Pod, and Container image. In Infrastructure view, it is organized by Cluster, Node, Pod, and Container image.
3. The sessions table displays sessions collected from the selected element of your Kubernetes infrastructure. You can view it in fullscreen by selecting the button in the table's upper right corner. You can sort the table by any of its fields.

You can filter the data using the KQL search bar and date picker at the top of the page.

From the sessions table's Actions column, you can take the following investigative actions:

- View details
- <<timelines-ui,Open in Timeline>>
- <<alerts-run-osquery, Run Osquery>>
- <<visual-event-analyzer, Analyze event>>
- <<session-view, Open Session View>>

Session View displays Kubernetes metadata under the *Metadata* tab of the Detail panel:

image::metadata-tab.png[The Detail panel's metadata tab]

The *Metadata* tab is organized into these expandable sections:

- *Metadata:* `hostname`, `id`, `ip`, `mac`, `name`, Host OS information
- *Cloud:* `instance.name`, `provider`, `region`, `account.id`, `project.id`
- *Container:* `id`, `name`, `image.name`, `image.tag`, `image.hash.all`
- *Orchestrator:* `resource.ip`, `resource.name`, `resource.type`, `namespace`, `cluster.id`, `cluster.name`, `parent.type`


[discrete]
[[k8s-dash-setup]]
== Setup
To collect session data for the dashboard, you'll deploy a Kubernetes DaemonSet to your clusters that implements the {endpoint-cloud-sec} integration.

**Prerequisites**:

- This feature requires Elastic Stack version 8.4 or newer.
- You need an active {fleet-guide}/fleet-overview.html[{fleet} Server].
- Your Elastic deployment must have the {endpoint-cloud-sec} integration <<install-endpoint,enabled>>.
- The {endpoint-cloud-sec} integration policy must have **Include session data** set to `true`. To modify this setting, go to **Manage -> Policies**, select your policy, and find `Include session data` near the bottom of the `Policy settings` tab.

**Support matrix**: This feature is currently available on GKE and EKS using Linux hosts and Kubernetes versions that match the following specifications:
|=====================
| | **Kubernetes versions** | **Node OSes**
|**EKS**| 1.18; 1.19; 1.20; 1.21 | Amazon Linux 2, Bottlerocket OS
|**GKE**| Regular (default channel): 1.21 and 1.22; Stable: 1.20 and 1.21; Rapid: 1.22 and 1.23 | Container-optimized OS (COS), Ubuntu
|=====================

[discrete]
=== Download and modify the DaemonSet manifest
The DaemonSet integrates {elastic-endpoint} into your Kubernetes cluster. The {agent} is enrolled to a running {fleet-server} using the `FLEET_URL` parameter, and connected to a specific {agent} policy using the `FLEET_ENROLLMENT_TOKEN`.

You first need to download the DaemonSet manifest `.yaml`, then modify it to include your {fleet} URL and Enrollment Token before you deploy it to the clusters you want to monitor.

1. Download the DaemonSet manifest using the command: `curl -L -O https://raw.githubusercontent.com/elastic/main/releases/8.4.0/kubernetes/deploy/elastic-endpoint-security.yaml`
2. Fill in the manifest's `FLEET_URL` field with your {fleet} server's `Host URL`. To find it, go to **{kib} -> Management -> {fleet} -> Settings**. For more information, refer to {fleet-guide}/fleet-settings.html[Fleet UI settings].
3. Fill in the manifest's `FLEET_ENROLLMENT_TOKEN` field with a Fleet enrollment token. To find one, go to **{kib} -> Management -> {fleet} -> Enrollment tokens**. For more information, refer to {fleet-guide}/fleet-enrollment-tokens.html[Fleet enrollment tokens].


[discrete]
=== Apply the modified manifest to your cluster or clusters

To ensure you install {elastic-endpoint} on the desired Kubernetes cluster(s), set the default context using command: `kubectl config use-context <name-of-context>`.
To check which contexts exist, use `kubectl config get-contexts` to list them from your local kubectl config file. An asterisk indicates the current default context.

You can repeat the following steps for multiple contexts.

**Example:**

- Apply the manifest to a cluster: `kubectl apply -f elastic-endpoint-security.yaml`
- Check the DaemonSet’s status: `kubectl get pods -A`

Once the DaemonSet is running, Elastic Endpoint will start sending Linux session data from Kubernetes to {kib}. You can then view that data from the Kubernetes dashboard.


IMPORTANT: This dashboard uses data from the `logs-*` index pattern, which is included by default in the <<advanced-settings,`securitySolution:defaultIndex` advanced setting>>. To collect data from multiple {es} clusters (as in a cross-cluster deployment), update `logs-*` to `*:logs-*`.
4 changes: 3 additions & 1 deletion docs/detections/session-view.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,8 @@ and investigating session activity on your Linux infrastructure and understandin
* *Nested sessions:* Sessions started by processes descended from the entry session.
* *Alerts:* Alerts in the context of the processes which caused them.

NOTE: To view Linux session data from your Kubernetes infrastructure, you'll need to set up the <<kubernetes-dashboard,Kubernetes dashboard>>.

[float]
[[enable-session-view]]
=== Enable Session View data
Expand All @@ -31,7 +33,7 @@ fields collected by {endpoint-cloud-sec} when this setting is enabled, refer to
[float]
[[open-session-view]]
=== Open Session View
Session View is accessible from the **Hosts**, **Alerts**, and **Timelines** pages.
Session View is accessible from the **Hosts**, **Alerts**, and **Timelines** pages, as well as the **Kubernetes** dashboard.
Events and sessions that you can investigate in Session View have a rectangular
*Open Session View* button in the *Actions* column. For example:

Expand Down