A firewall is a network security device that monitors incoming and outgoing network traffic and decides whether to allow or block specific traffic based on a defined set of security rules. Firewalls are often categorized as either network firewalls or host-based firewalls.
Moreover, network firewalls filter traffic between two or more networks and run on network hardware. Host-based firewalls run on host computers and control traffic in and out of those machines