Module 2 · Segmentation and Firewall Policy · Lesson 6 of 9
Firewall policy you can prove
Allow a client to reach a web service, block a second listening service, and correlate the deny with a log.
In this lesson · about 30 minutes
- Write a rule from source, destination, protocol and port
- Explain rule order and the implicit deny
- Prove enforcement with an allowed test, a denied test and a log entry
Whiteboard · watch and try
The guard's checklist
Press Play. The tutor writes a three-line rule list and runs two visitors through it.
Tip: press Pause, then use the pen to work along on the board. Space plays and pauses; Ctrl+Z undoes your last mark.
A firewall rule answers five questions: source, destination, protocol, port, and action (allow or deny). Most firewalls check rules top to bottom and stop at the first match. Anything that matches no rule hits the implicit deny at the bottom.
Where the rule goes
Firewalls like pfSense apply rules on the interface where traffic enters the firewall. Traffic from the guest network to the staff server enters on the guest interface, so the rule belongs there, not on the staff interface.
What counts as proof
A failed connection doesn't prove the firewall blocked it: the service might simply be down. To prove enforcement you need:
- Evidence the blocked service is listening (for example, it works from a permitted source).
- The allowed test succeeds.
- The denied test fails, typically with a timeout.
- A firewall log entry for the denied attempt, matching source, destination, port and time.
Try it · watch it move
A firewall reads its rules top to bottom
Send each test and watch the guard read down the list. Then move rule 3 to the top, or switch rule 2 off, and send the tests again. What changed?
| Order | Action | From guests to… | Door | Move |
|---|---|---|---|---|
| 1 | ✓ Allow | file server 10.10.10.5 | 80 | |
| 2 | ✕ Deny + log | any staff device 10.10.10.0/24 | any | |
| 3 | ✓ Allow | anywhere | 443 | |
| last | ✕ Deny | anything else (the invisible "implicit deny") | ||
Performance-based question (PBQ)
Which rule matches first?
Guest interface rules on the lab firewall, evaluated top to bottom:
| # | Action | Source | Destination | Port |
|---|---|---|---|---|
| 1 | Allow | 10.10.20.0/24 | 10.10.10.5 | 80/TCP |
| 2 | Deny + log | 10.10.20.0/24 | 10.10.10.0/24 | any |
| 3 | Allow | 10.10.20.0/24 | any | 443/TCP |
| — | Implicit deny | any | any | any |
For each connection from a guest, pick the rule that decides it.
- 10.10.20.31 → 10.10.10.5 port 80/TCP
- 10.10.20.31 → 10.10.10.5 port 22/TCP (SSH)
- 10.10.20.31 → 10.10.10.5 port 443/TCP
- 10.10.20.31 → 203.0.113.50 port 443/TCP
- 10.10.20.31 → 203.0.113.50 port 25/TCP
Hands-on lab (simulated terminal)
Lab: prove the policy from the guest
You're on guest-pc1 (10.10.20.31). The staff server 10.10.10.5 runs a web service on 80 and SSH on 22. Earlier, from the staff network, you confirmed both services answer. Now test from the guest side.
Step 1 of 3. Type each command and press Enter. Nothing runs on your computer.
1. Request the web page on 10.10.10.5 with curl, showing only the headers (-I).
Check your understanding0 of 3 correct
Quiz score: 0 of 3
Noviq Academy is free and for learning. Every lab here is simulated with synthetic data and private lab addresses. Only capture traffic and test networks that you own or have written permission to test. Wireshark and pfSense are trademarks of their owners; this course is independent of them.