docker-privesc
Fail
Audited by Gen Agent Trust Hub on Nov 10, 2026
Risk Level: HIGHPRIVILEGE_ESCALATIONPERSISTENCECOMMAND_EXECUTIONCREDENTIALS_UNSAFEDATA_EXFILTRATION
Full Analysis
- [PRIVILEGE_ESCALATION]: The skill provides instructions and commands to escape a Docker container and gain root access to the underlying host system.
- Leverages Docker group membership to mount the host root filesystem into the container:
docker run --rm -v /:/host -it alpine chroot /host. - Exploits the Docker socket (
/var/run/docker.sock) to create new privileged containers with host-level permissions. - Utilizes the
--privilegedflag andSYS_ADMINcapabilities for direct host filesystem access and cgroup-based escapes. - [PERSISTENCE]: The skill instructs the agent to establish permanent unauthorized access to the host system that persists across reboots.
- Modifies the host's
/etc/passwdto add a new root-level user:echo "backdoor::0:0::/root:/bin/bash" >> /host_etc/passwd. - Injects unauthorized SSH public keys into the host's
/root/.ssh/authorized_keysfile. - Creates an SUID (Set-User-ID) shell backdoor on the host:
cp /bin/sh /host_bin/.backdoor && chmod u+s /host_bin/.backdoor. - [CREDENTIALS_UNSAFE]: Specifically targets and modifies sensitive system security files.
- Accesses the host's password shadow file:
cat /host_etc/shadow. - Modifies core authentication files including
/etc/passwdand root SSH keys. - [DATA_EXFILTRATION]: Contains routines to discover and read sensitive files from the host environment for extraction.
- Targets system password hashes, root SSH keys, and sudoers configurations.
- [COMMAND_EXECUTION]: Executes high-risk system commands to manipulate the host environment.
- Uses
chrootto change the root directory from the container to the host filesystem. - Uses
chmod u+sto elevate file permissions for backdoors. - Interacts directly with the Docker REST API via Unix sockets using
curl.
Recommendations
- AI detected serious security threats
Audit Metadata