https://www.techtarget.com/searchsecurity/definition/Web-application-firewall-WAF
A web application firewall (WAF) is a firewall that is meant to protect web applications against common web-based threats. A WAF monitors, filters and blocks Hypertext Transfer Protocol (HTTP) traffic as it travels to and from a website or web application.
Web application firewalls are a common security control enterprises use to protect web systems against zero-day exploits, malware infections, impersonation, and other known and unknown threats and vulnerabilities.
A WAF can be network-, host- or cloud-based. It is often deployed through a reverse proxy and placed in front of one or more websites or applications. Running as a network appliance, server plugin or cloud service, the WAF inspects each packet and uses a rule base to analyze Layer 7 web application logic and filter out potentially harmful traffic that can facilitate web exploits.
Through customized inspections, a WAF can detect and immediately prevent several of the most dangerous web application security flaws, which traditional network firewalls and other intrusion detection systems (IDSes) and intrusion prevention systems (IPSes) might not be capable of doing. WAFs are especially useful for companies that provide products or services over the Internet, such as e-commerce shopping, online banking and other interactions between customers or business partners.
A WAF has an advantage over traditional firewalls, as it offers greater visibility into sensitive application data that's communicated using the HTTP application layer.
A WAF can be software, an appliance or a service. It analyzes HTTP requests and applies rules that define what parts of the conversation are benign and what parts are malicious.
The main parts of HTTP conversations that a WAF analyzes are GET and POST requests. GET requests are used to retrieve data from the server, and POST requests are used to send data to a server to change its state. WAFs can also analyze PUT and DELETE requests as well, which are requests that send data to a server for updating and requests for data deletion, respectively.
A WAF can take one of the following three approaches to analyze and filter the content contained in these HTTP requests:
Regardless of the security model a WAF uses, it analyzes HTTP interactions and reduces or, ideally, eliminates malicious activity or traffic before it reaches a server for processing. Most WAFs require their policies to be updated regularly to tackle new vulnerabilities. However, recent advancements in machine learning have enabled some WAFs to update automatically.
A WAF is important for the growing number of enterprises that provide products over the internet -- including online banking, social media platform providers and mobile application developers -- because it helps prevent data leakage. A lot of sensitive data, such as credit card information and customer records, is stored in back-end databases accessible through web applications. Attackers frequently target these applications to gain access to the associated data.
Banks, for instance, might use a WAF to help them meet the Payment Card Industry Data Security Standard (PCI DSS), a set of policies to protect cardholder data (CHD). Installing a firewall is one of the 12 requirements of PCI DSS compliance and applies to any enterprise that handles CHD. Since many companies employ mobile applications and the growing internet of things, an increasing number of transactions take place at the application layer using the web. For this reason, a WAF is an important part of a modern business's security model.
When it comes to an enterprise security model, a WAF is most effective in conjunction with other security components, including IPSes, IDSes, and classic or next-generation firewalls (NGFWs).
Web application firewalls are typically defined by how they are deployed. The following are commonly appearing WAF deployment methods:
Network-based WAFs. These are usually hardware-based and can reduce latency because they're installed locally on-premises using a dedicated appliance, as close to the application as possible. Most major network-based WAF vendors enable replication of rules and settings across multiple appliances, thereby making large-scale deployment, configuration and management possible. The biggest drawback of this type of WAF is cost -- there's an upfront capital expenditure and ongoing maintenance costs.
Host-based WAFs. These can be fully integrated into the application code itself. The benefits of a host-based WAF include lower cost and increased customization options. However, host-based WAFs can be challenging to manage because they require application libraries and depend on local server resources to run effectively. These WAFs might also require more staff resources -- including developers, system analysts, and DevOps or DevSecOps -- to manage.
Cloud-hosted WAFs. These offer a low-cost option for organizations that want a turnkey product that requires minimal management resources. Cloud WAFs are easy to deploy, are available on a subscription basis, and often require only a simple domain name system (DNS) or proxy change to redirect application traffic. Although it can be challenging to place responsibility for filtering an organization's web application traffic with a third-party provider, this strategy lets applications be protected across a broad spectrum of hosting locations and use similar policies to protect against application layer attacks. Additionally, these third parties have the most current threat intelligence and can help identify and block the latest application security threats.
Hybrid WAFs. These are a combination of on-premises and cloud-based options. The WAF is put into place on-site, and a cloud-based service is used to support it. They provide the control of an on-premise WAF while also providing the scalability of a cloud-hosted WAF. Hybrid deployment options, however, come with the added complexity of managing both local and cloud components.
Typically, WAFs offer the following features and protection against common attacks:
There are commercial and open-source WAF options. Given that commercial WAFs can be pricey, open-source WAFs can be useful if an organization is looking for a cost-effective way to secure its website.
Popular commercial vendors include the following:
Popular open source vendors include the following:
Security technologies -- including WAFs, IPSes, NGFWs and Runtime Application Self-Protection (RASP) -- safeguard systems and networks. However, their approaches to security and the type of threats they mitigate, are different.
The following highlights the main differences among these technologies:
Firewall is a broad term for firmware that defends a computer network by filtering incoming data packets. Within that broad definition, several categories are differentiated by what kind of protection they provide and how they provide it. Those designations include packet filtering, stateful inspection, proxy and NGFW.
A WAF is another category of firewall, differentiated by how it specifically filters data packets. The WAF is unique because it focuses solely on web-based hackers at the application layer, whereas other types of firewalls -- such as packet filtering and stateful inspection -- might not be able to defend against these attacks. A WAF is similar to a proxy firewall but with a specific focus on Layer 7 application logic.
The threat to mobile security is growing as remote work becomes more widespread. Find out what a mobile firewall is and how it can defend against certain threat vectors.
26 Mar 2025