Quiz Entry - updated: 2026.11.10
What risks come with starting a container from an unknown third-party image on Docker Hub?
You run someone else's code with whatever behaviour they built in: hidden malware or crypto-miners, root privileges, unwanted outbound connections, restart loops and outdated, vulnerable software.
Anyone with an account can publish images to Docker Hub, and an image's behaviour is not obvious from its name. Questions to ask before running one:
- What does it run at start? The
CMD/ENTRYPOINTcould launch anything. In 2018 Docker Hub removed a set of images that had been pulled millions of times; they ran a Monero crypto-miner as soon as a container was started withrun. - Does it run as root? Many images do by default, which makes any container escape far more dangerous.
- Does it connect to external hosts? It could exfiltrate data or fetch further payloads.
- Does it restart itself endlessly? Or does it consume resources unchecked?
- Is it maintained? An abandoned image carries old libraries with known CVEs.
- Typosquatting.
ngnixinstead ofnginx.
Mitigations: prefer Docker Official Images and Verified Publishers; read the image's Dockerfile and docker image history/inspect; pin a tag or digest; scan images (Docker Scout, Trivy); and run containers as a non-root user with limited privileges.
Go deeper:
TechCrunch: Tainted, crypto-mining containers pulled from Docker Hub — the 2018 Monero-mining images and how long they stayed up.
Docker Docs: Docker Official Images — the curated images to prefer.
Trivy — an open-source scanner for vulnerabilities and secrets in images.