Firewall Types by Inspection Method
Packet filtering firewall (stateless): inspects each packet independently based on source/destination IP, port, and protocol against a rule set (ACL). Fast, simple, lowest overhead. Cannot track connection state — cannot distinguish a response packet from an initiated attack. Does not understand application context. Layer 3–4.
Stateful inspection firewall: tracks the state of TCP connections in a state table. Only allows response packets matching established connections — a reply packet is only allowed if there was an outbound request that established the session. The most fundamental improvement over packet filtering. Operates at Layers 3–4. Virtually all modern firewalls are at least stateful.
Application-layer firewall (proxy firewall): terminates connections and rebuilds them — inspects Layer 7 content. Can enforce application-specific policies: block specific HTTP methods, inspect FTP commands, block file attachments by content type. Slower than stateful (application-layer processing) but far more capable for application control.
Next-Generation Firewall (NGFW): combines stateful inspection with deep packet inspection (DPI), application identification and control, user identity awareness (integrates with AD/LDAP), IPS, URL filtering, SSL inspection (decrypts HTTPS to inspect content), and threat intelligence. Examples: Palo Alto, Cisco Firepower, Fortinet FortiGate, Check Point.
Specialized Firewall Types
WAF (Web Application Firewall): specifically protects web applications from attacks targeting HTTP/HTTPS — SQL injection, XSS (Cross-Site Scripting), CSRF, and OWASP Top 10 vulnerabilities. Operates at Layer 7. Positioned in front of web servers. Different from a network firewall (which protects infrastructure); a WAF protects the application logic.
UTM (Unified Threat Management): a single appliance combining multiple security functions — firewall, IPS, VPN, web filtering, antivirus, DLP, and email filtering. Cost-effective for SMBs. Potential performance bottleneck when all functions are active. Modern UTM devices handle multi-gigabit throughput.
Host-based firewall: software firewall running on individual endpoints (Windows Firewall, iptables/nftables on Linux). Protects the host from network attacks regardless of network location — even when connected to untrusted networks (hotels, coffee shops). Layer 4 (port filtering) with some application awareness.