# Scada Network Seg Boundary Validation

> Use when validating that OT network segmentation actually holds on an authorized engagement or lab. Covers Purdue model zone and conduit mapping, firewall rule review between IT and OT, allowed versus blocked path testing, data diode and historian bridge checks, and bypass hunting for dual homed hosts, forgotten VPNs, and vendor remote access. Also use when a flat OT network finding needs proof, not just a diagram.

- Skill: `mizazhaider-ceh/scada-network-seg-boundary-validation` (Agent Skill)
- Install (CLI): `npx get-skill add mizazhaider-ceh/scada-network-seg-boundary-validation`
- Raw SKILL.md: https://api.skillmd.com/api/skills/mizazhaider-ceh/scada-network-seg-boundary-validation/raw
- Safety review: pending
- Works with: Claude Code, Claude.ai, OpenAI Codex
- Category: AI & ML
- Author: mizazhaider-ceh (https://skillmd.com/u/mizazhaider-ceh)
- Updated: 2026-11-22
- Page: https://skillmd.com/skills/mizazhaider-ceh/scada-network-seg-boundary-validation

---


A segmentation diagram is a claim. Validation is the test of that
claim. This sub-skill turns the parent scada-network-seg design work
into evidence. For every boundary, it records what should be allowed,
what should be blocked, what was actually tested, and what the
result was. A boundary that was never tested is reported as
untested, never as secure.

Safety warning. Boundary tests send packets across OT boundaries,
so they need written authorization naming both sides of every
boundary tested. Test from the correct side, use slow scans, and
never test a safety segment. Coordinate with operations and stop at
the first sign of process impact.

## Quick Workflow

1. Get written authorization naming every zone, every boundary, and
   both sides of each test. Safety segments are out of scope unless
   a dedicated safety assessment says otherwise.
2. Draw the as built map from configs and interviews, not from the
   design diagram alone. Place real devices on Purdue levels 0
   through 5 and the industrial DMZ at level 3.5.
3. Define zones and conduits per IEC 62443. Each conduit gets an
   allowed list of sources, destinations, ports, and protocols.
4. Review firewall rules on every boundary before testing. Note
   overly broad rules, any to any rules, and rules with no owner.
5. Build an allowed versus blocked test matrix. Every conduit gets
   at least one allowed test and one blocked test.
6. Run the tests from the correct source zone, slowly, and record
   the result per matrix row.
7. Check the legitimate bridges. Historian replication and data
   diode paths must be the only IT to OT data flows, and they must
   flow in the intended direction only.
8. Hunt bypasses. Dual homed hosts, cellular modems, vendor VPNs,
   forgotten wireless, and jump hosts with two interfaces.
9. Report each boundary as holds, fails, or untested, with the
   exact path a packet took or was stopped on.

## 1. Allowed versus blocked matrix

Write the matrix before testing. Testing without it produces
anecdotes. Testing against it produces a verdict per boundary.

```python
#!/usr/bin/env python3
"""Allowed versus blocked matrix for OT boundary validation."""
tests = [
    {"conduit": "IT to industrial DMZ", "src": "192.168.40.10",
     "dst": "192.168.30.10", "port": 443, "expected": "allowed"},
    {"conduit": "IT to OT control", "src": "192.168.40.10",
     "dst": "192.168.10.20", "port": 502, "expected": "blocked"},
    {"conduit": "OT control to IT", "src": "192.168.10.20",
     "dst": "192.168.40.10", "port": 443, "expected": "blocked"},
    {"conduit": "Industrial DMZ to historian", "src": "192.168.30.10",
     "dst": "192.168.20.10", "port": 5450, "expected": "allowed"},
    {"conduit": "Industrial DMZ to PLC", "src": "192.168.30.10",
     "dst": "192.168.10.20", "port": 502, "expected": "blocked"},
]
for test in tests:
    print("%s: %s -> %s port %d, expected %s, result: to be tested" % (
        test["conduit"], test["src"], test["dst"],
        test["port"], test["expected"]))
```

```bash
# Boundary probe from the authorized source zone only, one port at a time
# Blocked means no response or filtered, allowed means open, anything else needs review
sudo nmap -sS -Pn -p 502 --open -T2 --max-retries 1 \
  192.168.10.20 -oN /tmp/boundary_plc502.txt
cat /tmp/boundary_plc502.txt | grep -E "open|filtered|closed" | head -20

# The same test from a different zone should give a different answer
# if segmentation holds. Record both results side by side in the matrix.
sudo nmap -sS -Pn -p 443 --open -T2 --max-retries 1 \
  192.168.30.10 -oN /tmp/boundary_dmz443.txt
cat /tmp/boundary_dmz443.txt | grep -E "open|filtered|closed" | head -20
```

## 2. Firewall rule review

A firewall rule set that nobody can read is a finding on its own.
Review for breadth, for rules without owners, and for shadowed rules
that never match because an earlier rule already handles the traffic.

```python
#!/usr/bin/env python3
"""Flag overly broad firewall rules in a plain text rule export."""
import re

rules = [
    "allow any any any",
    "allow 192.168.40.0/24 192.168.30.10 tcp 443",
    "allow 192.168.30.0/24 192.168.10.0/24 tcp 502",
    "deny any any any",
]
for rule in rules:
    broad = bool(re.search(r"\bany\s+any\b", rule))
    print("%s%s" % ("BROAD RULE, review first: " if broad else "narrow: ", rule))
print("\nFor each broad rule, record its owner, its business need,")
print("and whether a narrower source, destination, or port would work.")
```

```bash
# Passive check for traffic that should not cross a boundary
# Run on a span port at the boundary during a normal operations window
sudo tshark -i eth0 -f "net 192.168.10.0/24" -w /tmp/boundary_traffic.pcap &
echo $! > /tmp/boundary_traffic.pid
# After a representative window, stop it and review sources
# kill $(cat /tmp/boundary_traffic.pid)
tshark -r /tmp/boundary_traffic.pcap -T fields -e ip.src -e ip.dst -e tcp.dstport \
  | sort | uniq -c | sort -nr | head -40
```

## 3. Bypass hunting

Bypasses are rarely in the firewall config. They live on hosts with
two network paths, on modems nobody documented, and on vendor
remote access accounts that outlived the vendor visit.

```bash
# Dual homed host check on a host you are authorized to inspect
ip -brief addr
ip route
echo "Two default routes, or interfaces in two zones, means a bypass"
echo "candidate. Confirm with the asset owner before calling it a finding."
# Look for listening services that suggest a second path in
ss -tlnp 2>/dev/null | head -40
```

## Edge cases

- Stateful firewall timing. A blocked test that arrives while a
  return session is still open can look allowed. Test blocked paths
  from a cold start, with no prior allowed session to the same host.
- NAT hiding the true source. If addresses are translated at the
  boundary, record both the pre NAT and post NAT address in the
  matrix, or the result cannot be reproduced.
- Data diode direction. A diode that passes data the wrong way is
  not a diode. Verify direction with a test in each direction, not
  with the vendor datasheet alone.
- Historian replication lag. A replica that lags by hours is still
  a bridge, but incident timelines built from it will be wrong.
  Note the lag in the report.
- Jump host scope. Testing from the jump host proves the jump host
  path, not the general IT path. Test both, and label each result
  with its true source.
- Wireless and cellular. A forgotten access point or modem can
  bypass every wired boundary. Include a wireless and modem sweep
  in the bypass hunt, or mark it as not covered.

## Key references

- IEC 62443 zone and conduit model, for how zones, conduits, and
  security levels should be defined and validated.
- NIST SP 800-82 Rev 3, Guide to Operational Technology Security,
  for Purdue model mapping and OT firewall practice.
- Purdue model levels 0 through 5 and the industrial DMZ at level
  3.5, as used in the parent scada-network-seg skill.
- Parent skill scada-network-seg, for the design method this
  validation sub-skill tests against.

