Haven't You Heard Of pfSense?
Too Long; Didn't Read
Pfsense is an open source customized distribution of FreeBSD focused on offering perimeter security controls. It can be installed on-premise, virtualized or in the cloud depending on your needs and your available resources. It has a wide variety of plugins that allow it to work as:Firewall/Router/DNS/DHCP/DCP Proxy (with Squid and SquidGuard) Antivirus (with squid, SquidGuard and ClamAV) and Web filtering (with Snort or Suricata)