A firewall is a means of controlling network access to one or more computers. The internet is really one large network, which includes your computer. A firewall protects your computer by acting as a gate through which all data pass. By blocking certain kinds of traffic, the firewall protects your computer or network from unauthorized users and safeguards your data from attack.
A firewall blocks evil packets from being permitted to reach a place where they can do harm. The key issue is not whether to block harmful packets but where to block them. The individual system’s operating system-based firewall can be configured to provide a great deal of security.