A quick overview of the IP filter
This open-source software package provides firewall functionality as well as network address translation to a number of Unix-like operating systems. FreeBSD, NetBSD, OpenBSD, and Solaris are all supported by this open-source firewall. As a kernel loadable module, IPfilter comes with the basic FreeBSD installation.
The following tutorials will help you troubleshoot IPFilter by providing helpful commands and techniques.
So let’s get start,
# service ipfilter start
Check out the active packet filtering rules
# ipfstat -io
Remove all filtering rules from the ruleset
ipf -F a
Turn off IPfilter
# service ipfilter stop
Permitting SSH but denying everything else
Include the following in /etc/ipf.conf to set up a firewall that blocks everything except SSH on port 22. The example IP address is 126.96.36.199
block in on any all
pass in quick on any proto tcp from any to 188.8.131.52/24 port = 22 keep state
That’s it, We hope this guide was informative for you.
Get the most out of learning with VPSie.com