π Quick Study Guide
π Firewall rules are fundamental for web security, acting as gatekeepers controlling network traffic.
π‘οΈ Each rule typically consists of source/destination IP addresses, ports, and protocols (TCP/UDP).
π¦ The main actions are `ACCEPT`, `DROP`, and `REJECT`. `ACCEPT` allows traffic, `DROP` silently discards it, and `REJECT` sends an error message.
π Web applications commonly use firewalls to protect against attacks like SQL injection, Cross-Site Scripting (XSS), and DDoS.
π‘ The principle of least privilege should be applied, only allowing necessary traffic.
β±οΈ Regularly review and update firewall rules to adapt to evolving security threats.
π« Default policies usually deny all traffic, requiring specific rules to allow access.
π§ͺ Practice Quiz
1. Which action does a firewall take when configured with a rule to `DROP` traffic?
A. Allows the traffic to pass through.
B. Silently discards the traffic without notification.
C. Sends an error message back to the source.
D. Redirects the traffic to another port.
2. What is the primary purpose of a firewall rule?
A. To encrypt all network traffic.
B. To control network traffic based on defined criteria.
C. To speed up network connections.
D. To monitor user activity on the network.
3. Which of the following is NOT a typical component of a firewall rule?
A. Source IP Address
B. Destination Port
C. Protocol (TCP/UDP)
D. Content of the HTTP request body.
4. What is the best practice when configuring firewall rules for a web server?
A. Allow all incoming traffic for simplicity.
B. Deny all incoming traffic and selectively allow only necessary traffic.
C. Allow all outgoing traffic.
D. Regularly disable the firewall to improve performance.
5. Which type of attack can a firewall, configured with appropriate rules, help to mitigate?
A. Phishing attacks via email.
B. Distributed Denial of Service (DDoS) attacks.
C. Insider threats involving physical access to servers.
D. Malware infections spread through USB drives.
6. What is the difference between `REJECT` and `DROP` actions in a firewall rule?
A. `REJECT` allows traffic, while `DROP` denies it.
B. `DROP` allows traffic, while `REJECT` denies it.
C. `REJECT` sends an ICMP error message back to the source, while `DROP` silently discards the traffic.
D. There is no difference; both perform the same action.
7. Why should firewall rules be regularly reviewed and updated?
A. To improve the server's aesthetic appeal.
B. To ensure compatibility with new hardware.
C. To adapt to evolving security threats and vulnerabilities.
D. To reduce the server's power consumption.
Click to see Answers
- B
- B
- D
- B
- B
- C
- C