Question

Difficulty: HardFirewalls and Access Control Lists (ACLs)

A network administrator is configuring an extended IPv4 Access Control List (ACL) on a router interface to control traffic from the client workstation subnet (172.16.10.0/24172.16.10.0/24) targeting the corporate server farm subnet (10.5.0.0/2410.5.0.0/24). The security policy specifies the following requirements for traffic destined for the database server (10.5.0.2010.5.0.20) and the rest of the server farm:

1. SSH administrative access (TCP port 22) to host 10.5.0.2010.5.0.20 must be permitted ONLY from the primary administrator workstation at IP address 172.16.10.5172.16.10.5.
2. All other SSH traffic (TCP port 22) to host 10.5.0.2010.5.0.20 originating from subnet 172.16.10.0/24172.16.10.0/24 must be explicitly blocked.
3. All non-SSH TCP traffic from subnet 172.16.10.0/24172.16.10.0/24 to host 10.5.0.2010.5.0.20 must be permitted.
4. Non-TCP IP traffic from subnet 172.16.10.0/24172.16.10.0/24 to host 10.5.0.2010.5.0.20 must be blocked.
5. All IP traffic from subnet 172.16.10.0/24172.16.10.0/24 to all other servers in subnet 10.5.0.0/2410.5.0.0/24 must be permitted.

In what top-to-bottom sequential order must the ACL entries be placed on the interface to enforce this security policy without rule shadowing?

  1. 1access-list 102 permit tcp host 172.16.10.5 host 10.5.0.20 eq 22
  2. 2access-list 102 deny tcp 172.16.10.0 0.0.0.255 host 10.5.0.20 eq 22
  3. 3access-list 102 permit tcp 172.16.10.0 0.0.0.255 host 10.5.0.20
  4. 4access-list 102 deny ip 172.16.10.0 0.0.0.255 host 10.5.0.20
  5. 5access-list 102 permit ip 172.16.10.0 0.0.0.255 10.5.0.0 0.0.0.255

Answer

The correct sequence from top to bottom is: permit SSH for host 172.16.10.5 -> deny SSH for subnet 172.16.10.0/24 -> permit all TCP for subnet 172.16.10.0/24 to host 10.5.0.20 -> deny all IP for subnet 172.16.10.0/24 to host 10.5.0.20 -> permit all IP for subnet 172.16.10.0/24 to subnet 10.5.0.0/24.
Extended Access Control Lists evaluate entries sequentially from top to bottom, stopping at the first match. To enforce granular control without rule shadowing, rules must be ordered from most specific to least specific: (1) Host-specific SSH permit for host 172.16.10.5, (2) Subnet-wide SSH deny for host 10.5.0.20, (3) Subnet-wide TCP permit for host 10.5.0.20, (4) Subnet-wide IP deny for host 10.5.0.20, and (5) Subnet-wide IP permit for the entire 10.5.0.0/24 destination network.

Step-by-Step Solution

1
Place the specific host SSH permit statement first.
access-list 102 permit tcp host 172.16.10.5 host 10.5.0.20 eq 22 is evaluated first.
ACLs process rules sequentially top-to-bottom. Placing host 172.16.10.5 first allows the administrator's workstation to connect over SSH before any broader deny rules take effect.
2
Place the subnet SSH deny statement second.
access-list 102 deny tcp 172.16.10.0 0.0.0.255 host 10.5.0.20 eq 22 is evaluated second.
Placing this rule immediately below the host SSH permit entry blocks SSH access for all other hosts in subnet 172.16.10.0/24 while preventing it from shadowing the permit entry above.
3
Place the general TCP permit statement for host 10.5.0.20 third.
access-list 102 permit tcp 172.16.10.0 0.0.0.255 host 10.5.0.20 is evaluated third.
Because SSH (port 22) has already been filtered by the top two rules, this rule permits all other TCP traffic (e.g., HTTP/HTTPS) to host 10.5.0.20. If placed above rule 2, it would incorrectly permit SSH for the entire subnet.
4
Place the full IP deny statement for host 10.5.0.20 fourth.
access-list 102 deny ip 172.16.10.0 0.0.0.255 host 10.5.0.20 is evaluated fourth.
This blocks all non-TCP IP traffic (such as ICMP or UDP) targeting host 10.5.0.20. Placing it below the TCP permit rule ensures TCP traffic to host 10.5.0.20 is allowed first.
5
Place the subnet-wide IP permit statement fifth.
access-list 102 permit ip 172.16.10.0 0.0.0.255 10.5.0.0 0.0.0.255 is evaluated fifth.
This allows traffic to all other servers in subnet 10.5.0.0/24. Placing it at the bottom prevents it from permitting unauthorized traffic to host 10.5.0.20.

Key Concept

ACL Rule Evaluation Order and Shadowing Prevention
Rate this question