01-04-2007 03:38 PM - edited 03-05-2019 01:35 PM
Hi,
I have seen the following ACL entries in a running config of a router, are they valid ACLs? And what do they mean? Thanks.
permit tcp 10.16.8.0 0.0.0.64 host 10.1.2.16 eq telnet
Permit 10.16.0.0 0.4.255.255
permit ip 10.16.0.0 0.3.255.127 10.16.8.0 0.0.7.255 (27423670 matches)
01-04-2007 07:39 PM
andrew
All 3 statements are unusual and not standard ways of writing access list entries. But as far as I can tell they are valid - if they are configured on a router I think it would not generate a syntax error. But the non-standard masks used make it very difficult to determine what will match.
Bear in mind that in the access list mask a binary 0 means that the bits must match and a binary 1 means that the bits do not need to match. So in the first statement:
permit tcp 10.16.8.0 0.0.0.64 host 10.1.2.16
the mask of 0.0.0.64 for the source address has 31 binary 0 and a single binary 1. So effectively there are 2 addresses that will match this: 10.16.8.0 and 10.16.8.64.
The second statement seems to be for a standard access list rather than an extended access list since there is a single address and a single mask. Again the mask used is quite unusual and what it will match is irregular. The statement is:
Permit 10.16.0.0 0.4.255.255
and with this mask the first octet must be 10, the last 2 octets can be anything and since the second octet of the mask has a single binary 1 it will match 2 addresses - 16 and 20.
The last statement is even more unusual. It is:
permit ip 10.16.0.0 0.3.255.127 10.16.8.0 0.0.7.255
The mask of 0.3.255.127 indicates that the first octet must be 10, the second octet can be 16, or 17, or 18, or 19. The third octet can be anything. The fourth octet can be anytung except 0 and 128.
HTH
Rick
01-04-2007 07:57 PM
Yes, they are all valid
permit tcp 10.16.8.0 0.0.0.64 host 10.1.2.16 eq telnet:
permit telnet session with the ip source address = 10.16.8.0 or 10.16.8.64 and ip destinaion address = 10.1.2.16
permit 10.16.0.0 0.4.255.255
permit ip packet with source address = 10.16.x.x or 10.20.x.x, where x=0~255
permit ip 10.16.0.0 0.3.255.127 10.16.8.0 0.0.7.255
permit ip packet with source address 10.x.y.z, where x=16~19 , y=0~255, z=0~127,
and destination address = 10.16.a.b, where a=8~15, b=0~255
hope this help
SSLIN
01-07-2007 02:12 AM
Thanks.
Discover and save your favorite ideas. Come back to expert answers, step-by-step guides, recent topics, and more.
New here? Get started with these tips. How to use Community New member guide