Kubernetes Anonymous User Create/Update/Patch Pods Request

Last updated 9 days ago on 2026-02-02
Created 9 days ago on 2026-02-02

About

This rule detects attempts to create, update, or patch pods by an anonymous user. An anonymous user is a user that is not authenticated or authorized to access the Kubernetes API server. Creating, updating, or patching pods is a common activity for attackers to gain access to the cluster and execute commands.
Tags
Data Source: KubernetesDomain: KubernetesUse Case: Threat DetectionTactic: ExecutionLanguage: eql
Severity
medium
Risk Score
47
MITRE ATT&CK™

Execution (TA0002)(external, opens in a new tab or window)

License
Elastic License v2(external, opens in a new tab or window)

Definition

Rule Type
Event Correlation Rule
Integration Pack
Prebuilt Security Detection Rules
Index Patterns
logs-kubernetes.audit_logs-*
Related Integrations

kubernetes(external, opens in a new tab or window)

Query
text code block:
any where event.dataset == "kubernetes.audit_logs" and ( kubernetes.audit.user.username in ("system:anonymous", "system:unauthenticated") or kubernetes.audit.user.username == null or kubernetes.audit.user.username == "" ) and kubernetes.audit.level in ("RequestResponse", "ResponseComplete", "Request") and kubernetes.audit.verb in ("create", "update", "patch") and kubernetes.audit.objectRef.resource == "pods"

Install detection rules in Elastic Security

Detect Kubernetes Anonymous User Create/Update/Patch Pods Request in the Elastic Security detection engine by installing this rule into your Elastic Stack.

To setup this rule, check out the installation guide for Prebuilt Security Detection Rules(external, opens in a new tab or window).