What is the primary purpose of a firewall?

  1. Control incoming and outgoing network traffic based on security policies ✓
  2. Prevent malware from spreading
  3. Assign IP addresses
  4. Encrypt all data

Correct answer: Control incoming and outgoing network traffic based on security policies

Option A is correct because a firewall's primary function is to inspect network packets and control which traffic is permitted or denied based on defined security rules and policies, effectively enforcing a boundary between trusted and untrusted network segments. Option B is wrong because preventing malware from spreading is primarily the role of endpoint protection platforms and network segmentation tools, not a traditional firewall's core function. Option C is wrong because assigning IP addresses is the function of DHCP servers, which is unrelated to firewall operations. Option D is wrong because encrypting all data is performed by protocols such as TLS and IPsec or by dedicated encryption appliances, not by firewalls.

Topic: Security Operations · firewall, network security, access control, security controls

Practice CompTIA Security+ (SY0-701) Questions Free