To better understand why this works: In the very first octet, the following applies:
class A addresses start with the first bit = 0 class B addresses start with the first two bits = 10 class C addresses start with the first three bits = 110 So the 0.0.0.0/1 means look for a network address of 0.0.0.0, but only pay attention to the very first bit (and make sure that it is a zero). So 0.0.0.0/1 identifies all class A networks - from 0.0.0.0 to 127.255.255.255. The ge 8 le 8 says only accept routes with a mask of 255.0.0.0. The combination of these two identifies all classful class A networks (0.0.0.0/8 to 127.0.0.0/8). Same with the 128.0.0.0/2 - that means make sure the first two bits are 10, but then ignore everything else. So this includes all class B addresses - from 128.0.0.0 to 191.255.255.255. Rob. ""Rob Webber"" wrote in message [EMAIL PROTECTED]">news:[EMAIL PROTECTED]... > I believe this will do what you are looking for. I did a little testing and > it seemed to work well: > > ip prefix-list classful seq 5 permit 0.0.0.0/1 ge 8 le 8 > ip prefix-list classful seq 10 permit 128.0.0.0/2 ge 16 le 16 > ip prefix-list classful seq 15 permit 192.0.0.0/3 ge 24 le 24 > > Hope that helps, Rob. > CCIE 6922 > > ""William Lijewski"" wrote in message > [EMAIL PROTECTED]">news:[EMAIL PROTECTED]... > > Can someone tell me how to create a Prefix-list to only alow classful > routes > > for BGP. I know you can do the following with an extended access-list: > > > > access-list 100 permit ip 0.0.0.0 127.0.0.0 host 255.0.0.0 > > access-list 100 permit ip 128.0.0.0 63.255.0.0 host 255.255.0.0 > > access-list 100 permit ip 192.0.0.0 31.255.255.0 host 255.255.255.0 > > > > Is there way to do it? Any good reading material on Prefix-lists? > > > > Thanks in advance. Message Posted at: http://www.groupstudy.com/form/read.php?f=7&i=39204&t=39113 -------------------------------------------------- FAQ, list archives, and subscription info: http://www.groupstudy.com/list/cisco.html Report misconduct and Nondisclosure violations to [EMAIL PROTECTED]