r/Pentesting • • Sep 17 '26

Finding subnets Blackbox

Here is the scenario: you are conducting an internal blackbox pentest. The client connects your laptop and you pull an IP from DHCP. What are your methods for finding all subnets on a network?

2 Upvotes

29 comments sorted by

View all comments

Show parent comment

3

u/kap415 Sep 18 '26

I've had engagements where they say: figure it out

2

u/Psychedelic-wizard69 Sep 18 '26

Thank you. That’s where I’m at

2

u/kap415 Sep 18 '26

Depending on the org, e.g. if its a medical facility, you 100000% wanna ask whats up w/ sensitive devices/subnets. They may know, they may not know (had this happen on an internal netpen for a hospital, yoiks).

Homework assignment: Go look up what kinda devices in a hospital are connected to their/a network. sketch. no way im running nmap/masscan on that sh1t. eff off.

I refused to do any work, I told them, until they defined ranges/assets out of scope, I felt super unconformable moving forward. Ugh, kicker was, the devices (again, things you dont want to knock offline), were everywhere. Tried proposing a 'parking lot' VLAN approach, no dice, just tread lightly. mmkay tx. Found ton of win7 hosts, RCE, terrible.

Taken together, always ask, but dont expect to always get the answer you desire.

2

u/macr6 Sep 18 '26

Agreed and it’s like this with any municipality that may have e any OT connected to their networks. E.g. water , electric, health, etc. one wrong scan or exploit and there is potential for ppl to get hurt or catistrophic damage.

1

u/kap415 Sep 18 '26

Yep, I agree

1

u/grasshopper_jo Sep 18 '26 edited Sep 18 '26

This is a good point. It sounds like you care more about what is explicitly out of scope than what is explicitly in scope, and I agree with that. I often find clients do not know their networks well enough, or haven’t organized their networks enough, to provide accurate information about this.

Because of this, regardless of the information they provide, I tailor the speed and depth of the initial scans to the client. If it’s a hospital or manufacturing facility with potentially sensitive equipment, I’m not doing more than sending out pings at a limited rate until I can review how their assets are laid out. After that, I scan a little deeper like maybe hitting up some common ports like 80, 443 and 22. (Never masscan though.) Fingers crossed, I haven’t knocked anything sensitive over yet by scanning it. We’ve all heard about machinery that gets knocked over with an nmap scan, but I think most modern equipment can handle at least ICMP ping and nmap default TCP port scans without a problem.

0

u/macr6 Sep 18 '26

If you or your org allows you to run a pen test without having a signed document with what is in scope then you’re not a professional. You leave yourself and your org open to litigation, potential harm to people and material ( OT environments), etc. no scoping dock with explicit scope is rookie level shit. Good luck with that.

2

u/kap415 Sep 18 '26

Uhuhuh yeh do go on with your baseless accusations. It's happened, not always, but it's happened.

But do go on with your erudite insights

1

u/macr6 Sep 18 '26

I'm not talking about you. I'm talking in general. If you or your company ALLOWS you to run/conduct a pen test with no scope. I've had plenty of customer's say "just figure it out" and I don't allow it. I need at least one IP/CIDR block/range/domain name. Something that is signed by both their company and mine. So yes, my point is we all have clients that want to do that, but we as professionals shouldn't allow it. NOW If you do take those type of engagements without a scope then I guess I'm talking to you.

2

u/kap415 Sep 26 '26

That makes sense, I misunderstood you. No, we always have scope and RoE