Skip to content
Threat Feed
high advisory

Potential Direct Kubelet Access via Process Arguments

Detection of potential direct Kubelet access via process arguments in Linux containers, which could lead to enumeration, execution, or lateral movement within the Kubernetes cluster.

This rule detects potential direct Kubelet access via process arguments within Linux containers. Attackers may target the Kubelet API to gain unauthorized access to the Kubernetes API server or other sensitive resources within the cluster. Observed requests are often used for reconnaissance, such as enumerating pods and cluster resources, or for executing commands directly on the API server. This activity indicates a potential attempt to move laterally within the Kubernetes environment. The activity is detected by monitoring process arguments for HTTP requests directed at the Kubelet API on ports 10250 or 10255. The detection leverages Elastic Defend for Containers, introduced in version 9.3.0.

Attack Chain

  1. An attacker gains initial access to a container within the Kubernetes cluster, potentially through exploiting a vulnerable application.
  2. The attacker opens an interactive shell within the compromised container.
  3. Using command-line tools such as curl or wget, the attacker crafts an HTTP request targeting the Kubelet API, typically on port 10250 or 10255.
  4. The HTTP request is embedded within the process arguments, including specific Kubelet endpoints such as /pods, /exec, /run, or /logs.
  5. The attacker attempts to enumerate pods and other cluster resources by querying the /pods endpoint.
  6. The attacker attempts to execute commands within containers by leveraging the /exec or /run endpoints.
  7. The attacker attempts to retrieve container logs using the /logs endpoint.
  8. Successful exploitation allows the attacker to move laterally within the Kubernetes cluster, potentially gaining access to sensitive data or control over other resources.

Impact

Successful exploitation of direct Kubelet access can lead to significant compromise within a Kubernetes cluster. Attackers can enumerate sensitive information, execute arbitrary commands within containers, and move laterally to other parts of the cluster. This can result in data exfiltration, denial of service, or complete cluster takeover. Due to the high level of access granted by Kubelet, a successful attack allows the attacker to take complete control over the target node.

Recommendation

Detection coverage 2

Potential Direct Kubelet Access via Process Arguments

high

Detects potential direct Kubelet access via process arguments by monitoring process creations for HTTP requests targeting Kubelet API ports.

sigma tactics: execution, lateral_movement techniques: T1021, T1059.004 sources: process_creation, linux

Potential Direct Kubelet Access via Wget

high

Detects potential direct Kubelet access via process arguments using wget to target Kubelet API ports.

sigma tactics: execution, lateral_movement techniques: T1021, T1059.004 sources: process_creation, linux

Detection queries are kept inside the platform. Get full rules →