First generation of firewalls, commonly known as packet filter firewalls, were designed to filter the packet on policies based on source, destination, port number etc. The filter rules were drafted in such an order that if a packet follows all the rules defined in policy, it passes the firewall and is rejected otherwise.
A web application firewall secures the TCP/IP port 80/443 from any access attempt made by traffic. It also enhances the level of security with deep packet inspection, data payload inspection to justify the authenticity of the data packet.