A firewall sits between networks and decides which traffic to let through and which to block. Here is how firewalls work, what a next-generation firewall (NGFW) adds, and how to choose and configure one for a company.
What a firewall is
A firewall controls traffic between networks, or between a network and a single device, according to a set of rules: what is allowed and what is denied. Rules usually describe where traffic comes from and goes to, and through which port and protocol.
Where firewalls are placed:
- At the perimeter — between the office or data centre network and the internet.
- Between segments inside the network — for example, so that guest Wi-Fi cannot reach servers and accounting cannot reach the development network.
- On devices themselves — firewalls built into operating systems protect an individual computer or server.
How firewalls work
NIST’s firewall guidelines (SP 800-41 Rev. 1) describe several technologies:
- Packet filtering — each packet is judged on its own by addresses, ports and protocol.
- Stateful inspection — the firewall remembers established connections and lets through only the replies to them.
- Application-level inspection and proxies — the content of specific protocols is analysed, not just the headers.
A classic firewall answers “from which address to which port” well, but “what exactly is happening in this connection” poorly.
What an NGFW is
A next-generation firewall combines classic filtering with deeper traffic inspection. According to Fortinet’s description, an NGFW adds, among other things:
- application awareness regardless of port and protocol;
- intrusion prevention (IPS) — blocking attempts to exploit vulnerabilities;
- threat intelligence and malware protection;
- inspection of encrypted traffic (SSL/TLS);
- anomaly detection and analysis of suspicious files;
- user- and device-based policies, not only IP addresses.
| Classic firewall | NGFW | |
|---|---|---|
| Rules based on | addresses, ports, protocols | also applications, users, devices |
| Traffic content | barely analysed | deep inspection, IPS, malware protection |
| Encrypted traffic | passed through “blind” | can be inspected |
| Remote access and branches | separate tools | usually built-in VPN and multi-link management (SD-WAN) |
| Logs | who connected where | what actually happened, tied to users and applications |
A WAF is not an NGFW
A web application firewall (WAF) protects specific websites and APIs against application-level attacks — for example, the OWASP Top 10 categories. An NGFW protects the network as a whole. A company with public web services needs both — more on WAF.
Does a small company need an NGFW?
Usually yes, if at least one of these applies:
- employees connect remotely or there are several offices;
- the company’s servers or services are reachable from the internet;
- the network needs to be split into segments;
- there are regulatory requirements. For example, NBU Resolution No. 143 for non-bank financial institutions requires network segmentation with access between segments restricted by firewalls, a minimal number of controlled access points to external networks and protection against DoS attacks — see “NBU Resolution 143: cybersecurity rules for NBFIs”.
How to choose an NGFW
- Throughput with protection enabled. Vendors usually quote raw firewall throughput and throughput with security features on separately — go by the second.
- Number of users and VPN connections, with room to grow.
- Security service subscriptions. IPS, antivirus and filtering databases are updated by subscription — when it ends, protection stops updating.
- High availability. A clustered pair if network downtime is critical.
- Management and logs. Central management and sending logs to an analysis system or a SOC.
How to configure it
- Deny everything not explicitly allowed.
- A minimum of entry points from the internet and a clear list of published services.
- Segments: servers, workplaces, accounting, guest Wi-Fi, administration.
- Admin access to the firewall only from a separate network and with multi-factor authentication.
- Regular firmware updates following the vendor’s security advisories — the firewall itself is an attractive target.
- Logs to a central system, with alerts on suspicious events.
- Rule reviews — regularly, so that temporary exceptions do not become permanent.
Checklist
- The perimeter is protected by an NGFW, not just the provider’s router
- The network is segmented, access between segments is restricted
- A “deny everything not allowed” policy
- The list of internet-facing services is current and minimal
- Administration only from a separate network and with multi-factor authentication
- Security service subscriptions are active
- Firmware is updated following vendor advisories
- Logs go to an analysis system, alerts are set up
- Rules are reviewed regularly
- Public web applications are also protected by a WAF
How Bereg-IT can help
We deliver network security and NGFW end to end: perimeter protection, internet access control and traffic filtering, secure access for offices and remote staff, licensing and supply of Fortinet hardware and software. Firewall logs can be connected to SOC as a Service monitoring, and the office network designed together with your IT infrastructure.
The first consultation is free. Send a request and an information security specialist will get in touch.
Sources
- NIST SP 800-41 Rev. 1, Guidelines on Firewalls and Firewall Policy (2009): https://csrc.nist.gov/pubs/sp/800/41/r1/final
- Fortinet, What Is a Next-Generation Firewall (NGFW)?: https://www.fortinet.com/resources/cyberglossary/next-generation-firewall
- Resolution of the Board of the National Bank of Ukraine of 09.12.2025 No. 143 — network protection requirements (in Ukrainian): https://bank.gov.ua/admin_uploads/law/09122025_143.pdf