Container With A hostPath Mount Created

 Original Source: [Sigma source]
Title: Container With A hostPath Mount Created
Status: test
Description:Detects creation of a container with a hostPath mount. A hostPath volume mounts a directory or a file from the node to the container. Attackers who have permissions to create a new pod in the cluster may create one with a writable hostPath volume and chroot to escape to the underlying node.
References:
  -https://microsoft.github.io/Threat-Matrix-for-Kubernetes/techniques/Writable%20hostPath%20mount/
  -https://blog.appsecco.com/kubernetes-namespace-breakout-using-insecure-host-path-volume-part-1-b382f2a6e216
Author: Leo Tsaousis (@laripping)
Date: 2024-03-26
modified:None
Tags:
  • -'attack.t1611'
  • -'attack.privilege-escalation'
Logsource:
  • category: application
  • product: kubernetes
  • service: audit
Detection:
  selection:
    verb: 'create'
    objectRef.resource: 'pods'
    hostPath: '*'
  condition:selection
Falsepositives:
  -The DaemonSet controller creates pods with hostPath volumes within the kube-system namespace.
Level: low