The idea
You're testing Tidewater Freight, a shipping company, and you already own one of their machines — the server that runs their public website. The records worth taking sit on a different machine deep in their network, one your own computer cannot even reach.
Steps
-
The core is dark from here
Start from where you stand — your Kali machine — and send two requests. The web server is on your own network, so it answers. The core inventory server is on the other network, and your request for it never arrives: a firewall between the two networks throws it away.
That firewall is the wall this whole playbook is about getting around. Watch the difference: same tool, same kind of request, one works and one is dropped. The only thing that changed is which network each machine sits on.
kali:~# curl -s http://10.0.1.20/ kali:~# curl -m4 http://10.0.2.30/
-
Stand on the box you own
You already hold the web server's
deploylogin, so log in and look at its own network connections. A machine reaches another network in one of two ways: it has a second network card plugged into that network, or something on the path lets its traffic across. The first thing to check, then, is how many connections this machine has.It has one, on the edge network —
10.0.1.20. No second card, no direct line into the core. So whatever reach it has into the core is not its own wiring — something else grants it, and the next step finds what.kali:~# ssh webbox hostname kali:~# ssh webbox 'ip -4 -o addr show scope global'
-
Why it reaches across
Ask the machine you own how it would send a packet to the core server. The answer comes back as a next hop: the first machine the packet is handed to. Here that is
10.0.1.2— the firewall — which then forwards the packet into the core because this machine's address is on its trusted list.So the reach is a trusted path, not a second card. That one distinction is the whole lesson: when a firewall trusts a machine by its address, it hands that machine's reach to anyone who takes the machine over. And you have taken this one over.
kali:~# ssh webbox 'ip route get 10.0.2.30'
-
Sweep the core through the foothold
Now use that reach: from the machine you own, knock on the core server the way a real staff member there would — a plain web request through the trusted path. It answers. The core inventory service is there, and the machine you own can touch it even though your Kali machine could not.
This is the move the whole road turns on: a request that dies from your attacker machine lives when it comes from a machine the firewall trusts. Same request, different sender.
kali:~# ssh webbox 'curl -s http://10.0.2.30/'
-
Name the target — and the defender's answer
The prize is the core inventory service at
10.0.2.30, on a network your own machine cannot reach. The one way to it is the web server at10.0.1.20, which the firewall trusts by address. That is the map a break-in is built from, and it is now yours.The defender's answer to this stage. The weak spot is not an open port or a weak password — it is a firewall that trusts an internet-facing machine inward.
A public web server is the most exposed machine on the network, so it should be the least trusted toward the core, not the most. Let the firewall carry only the exact flows the core needs, and never a web server's new connections into it — then a foothold on the edge maps nothing behind the wall.
Run these steps on real machines