type: attack-pattern
spec_version: 2.1
id: attack-pattern--b0e54bf7-835e-4f44-bd8e-62f431b9b76a
created: 2024-02-15T13:41:46.784Z
created_by_ref: identity--c78cb6e5-0c4b-4611-8297-d1b8b55e40b5
revoked: no
external_references: source_name: mitre-attack
url: https://attack.mitre.org/techniques/T1543/005
external_id: T1543.005
source_name: AppSecco Kubernetes Namespace Breakout 2020
description: Abhisek Datta. (2020, March 18). Kubernetes Namespace Breakout using Insecure Host Path Volume — Part 1. Retrieved January 16, 2024.
url: https://blog.appsecco.com/kubernetes-namespace-breakout-using-insecure-host-path-volume-part-1-b382f2a6e216
source_name: Docker Systemd
description: Docker. (n.d.). Start containers automatically. Retrieved February 15, 2024.
url: https://docs.docker.com/config/containers/start-containers-automatically/
source_name: GTFOBins Docker
description: GTFOBins. (n.d.). docker. Retrieved February 15, 2024.
url: https://gtfobins.github.io/gtfobins/docker/
source_name: Kubernetes Assigning Pods to Nodes
description: Kubernetes. (n.d.). Assigning Pods to Nodes. Retrieved February 15, 2024.
url: https://kubernetes.io/docs/concepts/scheduling-eviction/assign-pod-node/
source_name: Kubernetes DaemonSet
description: Kubernetes. (n.d.). DaemonSet. Retrieved February 15, 2024.
url: https://kubernetes.io/docs/concepts/workloads/controllers/daemonset/
source_name: Aquasec Kubernetes Attack 2023
description: Michael Katchinskiy, Assaf Morag. (2023, April 21). First-Ever Attack Leveraging Kubernetes RBAC to Backdoor Clusters. Retrieved July 14, 2023.
url: https://blog.aquasec.com/leveraging-kubernetes-rbac-to-backdoor-clusters
source_name: AquaSec TeamTNT 2023
description: Ofek Itach and Assaf Morag. (2023, July 13). TeamTNT Reemerged with New Aggressive Cloud Campaign. Retrieved February 15, 2024.
url: https://blog.aquasec.com/teamtnt-reemerged-with-new-aggressive-cloud-campaign
source_name: Podman Systemd
description: Valentin Rothberg. (2022, March 16). How to run pods as systemd services with Podman. Retrieved February 15, 2024.
url: https://www.redhat.com/sysadmin/podman-run-pods-systemd-services
object_marking_refs: marking-definition--fa42a846-8d90-4e51-bc29-71d5b4802168
modified: 2025-04-15T22:10:00.252Z
name: Container Service
description: Adversaries may create or modify container or container cluster management tools that run as daemons, agents, or services on individual hosts. These include software for creating and managing individual containers, such as Docker and Podman, as well as container cluster node-level agents such as kubelet. By modifying these services, an adversary may be able to achieve persistence or escalate their privileges on a host.

For example, by using the `docker run` or `podman run` command with the `restart=always` directive, a container can be configured to persistently restart on the host.(Citation: AquaSec TeamTNT 2023) A user with access to the (rootful) docker command may also be able to escalate their privileges on the host.(Citation: GTFOBins Docker)

In Kubernetes environments, DaemonSets allow an adversary to persistently [Deploy Container](https://attack.mitre.org/techniques/T1610)s on all nodes, including ones added later to the cluster.(Citation: Aquasec Kubernetes Attack 2023)(Citation: Kubernetes DaemonSet) Pods can also be deployed to specific nodes using the `nodeSelector` or `nodeName` fields in the pod spec.(Citation: Kubernetes Assigning Pods to Nodes)(Citation: AppSecco Kubernetes Namespace Breakout 2020)

Note that containers can also be configured to run as [Systemd Service](https://attack.mitre.org/techniques/T1543/002)s.(Citation: Podman Systemd)(Citation: Docker Systemd)
kill_chain_phases: kill_chain_name: mitre-attack
phase_name: persistence
kill_chain_name: mitre-attack
phase_name: privilege-escalation
x_mitre_attack_spec_version: 3.2.0
x_mitre_deprecated: no
x_mitre_domains: enterprise-attack
x_mitre_is_subtechnique: yes
x_mitre_modified_by_ref: identity--c78cb6e5-0c4b-4611-8297-d1b8b55e40b5
x_mitre_platforms: Containers
x_mitre_version: 1.0