Docker Hub Secrets Stolen by Automated Tools
Researchers at Stony Brook University found that credentials in public Docker Hub images are rapidly stolen by automated tools.
DockerCloud & containersData breachesKey points
- Researchers found that credentials in public Docker Hub images are rapidly stolen by automated tools.
- Honeypot images were pulled over 75,000 times, with AWS keys receiving over 140,000 API calls.
- Scanners mostly used static analysis to extract credentials by inspecting image layers or querying registry APIs.
Stony Brook University researchers discovered that credentials in public Docker Hub images are quickly stolen by attackers. To measure how fast secrets are extracted, they published 300 honeypot images across eight container registries. The researchers monitored the usage of these keys and used detection tools to track when images were built, executed, or had shells opened. Their honeypot images were pulled more than 75,000 times, with AWS keys receiving over 140,000 API calls from 5,000 different IP addresses. OpenAI and Anthropic keys were quickly exploited to drain test account balances. Docker Hub was the main source of AWS activity, though Harbor also saw some key abuse. The researchers referred to the automated tools scanning their images as 'ContainerBots,' though they were not coordinated by a single group. Few instances of the honeypot images being run were detected, suggesting scanners often extracted credentials without running the containers. Scanners mostly used static analysis to extract credentials by inspecting image layers or querying registry APIs. The researchers noted that exposing secrets in this way is common in real-world scenarios. Revoking stolen keys requires significant coordination and effort. The researchers recommended that Docker Hub scan images for secrets before allowing them to be published.
What to do
- The researchers recommended that Docker Hub scan images for secrets before allowing them to be published.
- The researchers suggested that Docker Hub limit access to its public feed of recent images to prevent mass-scanning.
Original report
“Cloud keys leaked in Docker Hub images are stolen within seconds”
Credentials and access secrets exposed in public Docker Hub images are being extracted and exploited by attackers within as little as eight seconds of publication.