Database ports published to the world
A Compose file publishes ports for five services. Work out which ones listen on every interface, which are bound to localhost only, and why the host firewall does not save you.
- Terminal mission
- Beginner
- 4 questions
- 0 of 4 solved
Your goal
Your goalWork out which container ports are open to the internet even though the firewall says no.
A cloud provider abuse notice says Redis on your staging VM answered from the internet. The VM runs a Compose stack from /srv/stack.
A ports entry of "6379:6379" binds to 0.0.0.0, every interface. "127.0.0.1:8081:8081" binds only to loopback. Docker inserts its own iptables rules for published ports, so ufw rules do not filter them.
What’s on screen
- Briefing
- the story: what happened and what evidence you were handed.
- Terminal
- the dark box. It is a pretend Linux shell that runs in your browser. Type a command and press Enter. Nothing you type touches a real system.
- Walkthrough
- the numbered path. Each step says what to type and what you should see. Hints open one at a time.
- Answer boxes
- under each question step. Type what you found and press Check.
Words to know
- VM
- virtual machine
- TCP
- Transmission Control Protocol, the connection most network traffic uses
staging-01 · Container audit
Type help for the command list and objectives for your tasks. Everything runs in this browser.
Up and down arrows walk your history. Ctrl+L clears the screen. Try help, ls, and objectives.
More in Container audit
The whole walkthrough
Every step in order: 295 words, about 2 min. It gives away every answer, so try the steps first.