I was wondering if I can make an artificial firewall by using two routers (Referred as Router 1 and Router 2). My server will be on router #1 while router #2 hosts all the other devices on my network. I was thinking that router #2 could be a total separate "entity" and appear as a singular device on the network. So if people breach the server only router #1 will be breached, and router #2 could still stay protected. Ill try to show you in a more visual way.

Router#1 ( /Server "FreeBSD 10.0" (, Router#2 (

As you can see Router #2 would look like any normal device to Router #1

(it will look like to router #1) Router #2 ( PC "Windows 7" (, PC "Windows 8.1" (

Will this setup work, has it been done before, these are my questions. What can I do to make this work?

  • The configuration you propose is nothing unusual, however to get an answer from a security perspective you should provide at least information what do you try to protect and from what threats.
    – techraf
    Commented May 31, 2016 at 4:54
  • I will probably edit my question to have a visual picture Commented May 31, 2016 at 14:07

2 Answers 2


Assuming the routers you are using have stateful access lists then they can be used as basic network firewalls and the design you have will provide some very basic defense in-depth benefits. If it's a possibility you may want to block all inbound packets initiated by the Free-BSD server entering the second router (clients behind the second router can still access the server but not vice-versa because TCP ACK 0 packets inbound to the internal network will be blocked).

Will it work ? yes but it might be easier if you segment the network ranges so they don't overlap. Maybe use a 192.168.1.x network and a 192.168.2.x network (there's a LOT of ways to do this, I'm just throwing out a really basic example)...

Has this been done before ? Yes, a long time ago before firewalls were popular and inexpensive this is one way people segmented networks.

Note: Just because this works doesn't mean it's a good idea. Some routers temporarily drop their filtering rules when under duress and allow "all" traffic through. Firewalls don't generally behave this way. Likewise almost any firewall will offer a lot of additional features that the routers won't be able to offer you.

If you are on a budget I would highly recommend simply using something like IPTables or PFSense.

As a side note if your First router has 3 interfaces you can also use one interface to connect to the Internet, a second for your Free-BSD server and then use the third for your internal network and not need the second router to create the same type of segmentation. (think Y-shaped network diagram)

  • The OS I'm using (FreeBSD 10.0) does not have IPTables, it has PF, IPFILTER, IPFW. As you might see, I am fairly new to security. Which one of these firewalls is good for Basic Security, I believe PF is somewhat like IPTables but I'm not sure.Click here for the documentation Commented May 31, 2016 at 16:14
  • IPTables was just a general suggestion. As mkin also mentioned you can use ipfw. I recommend deploying host-based firewalls on all systems this configuration is sometimes called a Zero-Trust firewall configuration and it helps reduce connections between systems to only those connections that are absolutely required. Commented May 31, 2016 at 16:59

Since you have freebsd, you can use ipfw for firewall usage. Though, if you understand how breaches work, they don't start from the outside in, they're mostly inside out.

Firewalls can stop outside scanning to internal networks, but internal hosts get compromised and that is a different kettle of fish.

  • Your answer could use more details and I'm confused about the beaches reference Commented May 31, 2016 at 4:16
  • 2
    Confusing formatting, there's no need to edit your post with pseudo editing regsubs, just make the edit.
    – Johnny
    Commented May 31, 2016 at 4:53
  • I think he meant breaches not beaches. Commented May 31, 2016 at 5:21

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .