Adversaries may break out of a container or virtualized environment to gain access to the underlying host. This can allow an adversary access to other containerized or virtualized resources from the host level or to the host itself. In principle, containerized / virtualized resources should provide a clear separation of application functionality and be isolated from the host environment.[1]

There are multiple ways an adversary may escape from a container to a host environment. Examples include creating a container configured to mount the host’s filesystem using the bind parameter, which allows the adversary to drop payloads and execute control utilities such as cron on the host; utilizing a privileged container to run commands or load a malicious kernel module on the underlying host; or abusing system calls such as unshare and keyctl to escalate privileges and steal secrets.[2],[3],[4],[5],[6],[7]

Additionally, an adversary may be able to exploit a compromised container with a mounted container management socket, such as docker.sock, to break out of the container via a Container Administration Command.[5] Adversaries may also escape via Exploitation for Privilege Escalation, such as exploiting vulnerabilities in global symbolic links in order to access the root directory of a host machine.[8]

In ESXi environments, an adversary may exploit a vulnerability in order to escape from a virtual machine into the hypervisor.[9]

Gaining access to the host may provide the adversary with the opportunity to achieve follow-on objectives, such as establishing persistence, moving laterally within the environment, accessing other containers or virtual machines running on the host, or setting up a command and control channel on the host.

References

  1. Docker. (n.d.). Docker Overview. Retrieved March 30, 2021.
  2. Docker. (n.d.). Use Bind Mounts. Retrieved March 30, 2021.
  3. Fiser, D., Oliveira, A.. (2019, December 20). Why a Privileged Container in Docker is a Bad Idea. Retrieved March 30, 2021.
  4. Fishbein, N., Kajiloti, M.. (2020, July 28). Watch Your Containers: Doki Infecting Docker Servers in the Cloud. Retrieved March 30, 2021.
  5. 0xn3va. (n.d.). Escaping. Retrieved May 27, 2022.
  6. Manoj Ahuje. (2022, January 31). CVE-2022-0185: Kubernetes Container Escape Using Linux Kernel Exploit. Retrieved July 6, 2022.
  7. Mark Manning. (2020, July 23). Keyctl-unmask: "Going Florida" on The State Of Containerizing Linux Keyrings. Retrieved July 6, 2022.
  8. Daniel Prizmant. (2020, July 15). Windows Server Containers Are Open, and Here's How You Can Break Out. Retrieved October 1, 2021.
  9. Broadcom. (2025, March 6). VMSA-2025-0004: Questions & Answers. Retrieved March 26, 2025.

Kwistjonijiet marbuta

Links
Tip ta’ link Kwistjoni
is related to Techniques
is blocked by Update Software
is blocked by Execution Prevention
is blocked by Application Isolation and Sandboxing
is blocked by Privileged Account Management
is blocked by Detection Strategy for Escape to Host
is blocked by Disable or Remove Feature or Program
is blocked by Prohibition Of Changes
is blocked by Configuration Management Program
is blocked by Least Functionality
is blocked by Continuous Monitoring Policy
is blocked by Malicious Code Protection (Antimalware)
is blocked by Documented Endpoint Security Protection Measures
is blocked by Personnel Transfer
is blocked by Identity & Access Management (IAM)
is blocked by Password-Based Authentication
is blocked by Authenticator Feedback
is blocked by Restrictions on Shared Groups / Accounts
is blocked by Boundary Protection
is blocked by Data Flow Enforcement – Access Control Lists (ACLs)
is blocked by Alignment With Enterprise Architecture
is blocked by Security Function Isolation
is blocked by Fail Safe
is blocked by Vulnerability Ranking
is blocked by Access Restriction For Change
is blocked by Secure Baseline Configurations
is blocked by Continuous Monitoring
is blocked by Endpoint File Integrity Monitoring (FIM)
is blocked by Separation of Duties (SoD)
is blocked by Account Management
is blocked by Access Enforcement
is blocked by Least Privilege
is blocked by Identification & Authentication for Organizational Users
is blocked by Application Partitioning
is blocked by Process Isolation
is blocked by Memory Protection
is blocked by Non-Modifiable Executable Programs
is blocked by Software & Firmware Patching