Example basic configuration
From PFSenseDocs
This article is part of the HOWTO series.
|
This article is part of the EXAMPLE series.
|
Contents |
[edit]
Summary
This article is designed to help you get acquainted with how pfSense does rule matching and how you can get a basic ruleset going.
[edit]
Caveats
- Always remember that rules are matched on the INCOMING Interface. This is how PF works, and cannot be changed.
- This isn't the most secure approaches, but should get you familiar with how to setup rules.
- Take a look at the page for Aliases, it might make management of ACL's easier.
[edit]
Example of a basic lock down of the LAN and DMZ out going rules
[edit]
Outbound LAN
- Make sure the “Default LAN > any” rule is either disabled or removed.
- Allow all users to browse web pages anywhere.
- Allow TCP 80 (HTTP) from LAN subnet to anywhere
- Allow users to browse secure web pages anywhere.
- Allow TCP 443 (HTTPS) from LAN subnet to anywhere
- Allow users to access FTP sites anywhere.
- Allow TCP 21 (FTP) from LAN subnet to anywhere
- Allow users to access SMTP on a mail server somewhere.
- Allow TCP 25 (SMTP) from LAN subnet to anywhere
- Allow users to access POP3 on a mail server somewhere.
- Allow TCP 110 (POP3) from LAN subnet to anywhere
- Allow users to access IMAP on a mail server somewhere.
- Allow TCP 143 (IMAP) from LAN subnet to anywhere
- If you need to allow remote connection to an outside windows server you will want to configure a rule for Remote administration.
- Allow TCP/UDP 3389 (Terminal server) from LAN subnet to ip of remote server
- If you use windows shares on the DMZ and want LAN users to access these files you need to allow NETBIOS/Microsoft-DS from the LAN to the DMZ
- Allow TCP/UDP 137 from LAN subnet (NETBIOS) to DMZ subnet
- Allow TCP/UDP 138 from LAN subnet (NETBIOS) to DMZ subnet
- Allow TCP/UDP 139 from LAN subnet (NETBIOS) to DMZ subnet
- Allow TCP 445 from LAN subnet (NETBIOS) to DMZ subnet
[edit]
Outbound DMZ
- By default, there are no rules on OPT interfaces.
- To allow your servers to use Windows update or browse the WAN
- Allow TCP 80 from DMZ subnet (HTTP) to anywhere
- If you use an external DNS server you will need to allow the computers to leave the network to connect to a DNS server.
- Allow TCP\UDP 53 from DMZ subnet (DNS) to ip of primary DNS server
- Allow TCP\UDP 53 from DMZ subnet (DNS) to ip of secondary DNS server
- To allow your servers to use a remote time server open port 123.
- Allow UDP 123 from DMZ subnet (NTP) to ip of remote time server
