0
0
Dockerdevops~20 mins

Why container security matters in Docker - Challenge Your Understanding

Choose your learning style9 modes available
Challenge - 5 Problems
🎖️
Container Security Master
Get all challenges correct to earn this badge!
Test your skills under time pressure!
🧠 Conceptual
intermediate
2:00remaining
Why is container security important?

Containers share the host OS kernel. What risk does this create if a container is compromised?

AThe attacker can only access that container's files and nothing else.
BThe attacker can potentially access the host system and other containers.
CThe container will automatically shut down to prevent damage.
DThe container will lose network connectivity but remain running.
Attempts:
2 left
💡 Hint

Think about what sharing the OS kernel means for isolation.

💻 Command Output
intermediate
2:00remaining
Output of scanning a vulnerable Docker image

What output will the following command produce when scanning an image with known vulnerabilities?

docker scan alpine:3.12
Docker
docker scan alpine:3.12
AVulnerabilities found with severity levels and fix suggestions.
BNo vulnerabilities found. Image is secure.
CSyntax error: 'scan' is not a valid docker command.
DImage not found error.
Attempts:
2 left
💡 Hint

Docker scan uses vulnerability databases to check images.

Configuration
advanced
2:00remaining
Configuring Docker to run containers with least privilege

Which Docker run option helps improve container security by limiting privileges?

Adocker run --read-only alpine
Bdocker run --network=host alpine
Cdocker run --privileged alpine
Ddocker run --rm alpine
Attempts:
2 left
💡 Hint

Think about restricting write access inside the container.

Troubleshoot
advanced
2:00remaining
Troubleshooting a container escape vulnerability

A container runs with '--privileged' flag and an attacker escapes to the host. What is the main cause?

AThe container was using a read-only filesystem.
BThe container was missing environment variables.
CThe container image was too large.
DThe container was running with too many privileges.
Attempts:
2 left
💡 Hint

Consider what '--privileged' does to container permissions.

Best Practice
expert
2:00remaining
Best practice to reduce container image vulnerabilities

Which practice best reduces vulnerabilities in container images?

AInstall all packages and tools inside the image for flexibility.
BRun containers as root user for easier management.
CUse minimal base images and regularly update them.
DDisable image scanning to speed up deployment.
Attempts:
2 left
💡 Hint

Think about minimizing attack surface and keeping software current.