From: Scott Morris (smorris@internetworkexpert.com)
Date: Thu Dec 18 2008 - 16:10:37 ARST
Since you are specifically looking for things inside a confederation, the
"(" and ")" are the parts we care about.
My only concern about the first one you lise is that you are looking for 0
or 1 (the ?) of ([0-9]*_) which would match none or one AS that must be
inside ( ) for a confederation.
The second one will definitely work with your example below as it's
permitting any characters (numbers or spaces) as long as they are contained
within the ( ) for a confederation.
I don't have a confederation currently setup in my lab, so I can't
specifically test out the first one, but when it came to the AS Path you
listed below with multiple intra-confed ASNs listed, I would be curious as
to whether it matched or not.
Scott Morris, CCIE4 #4713, JNCIE-M #153, JNCIS-ER, CISSP, et al.
CCSI/JNCI-M/JNCI-ER
Senior CCIE Instructor
smorris@internetworkexpert.com
Knowledge is power.
Power corrupts.
Study hard and be Eeeeviiiil......
-----Original Message-----
From: nobody@groupstudy.com [mailto:nobody@groupstudy.com] On Behalf Of Andy
Hogard
Sent: Thursday, December 18, 2008 2:07 AM
To: Cisco certification
Subject: Re: BGP regexp, doubt..?!
Sorry one last final correction, ^\(([0-9]*_)?\)$ <==> ^(\(.+\))?$ . Yep
are the two regexp the same ?! :)
Might have looked like I was just losing my remaning hair over it.. lol.
Greets!
On Thu, Dec 18, 2008 at 12:18 PM, Andy Hogard <andyhogard@gmail.com> wrote:
> Actually looks like I made a small typo, it should be is
> ^(\([0-9]*_)?\)$ <==> ^(\(.+\))?$ ..!? :)
>
>
> Regards,
> Andy,
>
> PS: I will consider regexp done if I get this correct!! :D
>
> On Thu, Dec 18, 2008 at 12:13 PM, Andy Hogard <andyhogard@gmail.com>wrote:
>
>> Hi folks,
>>
>>
>> I just wanted to know whether ^(\([0-9]*_\))?$ <==> ^(\(.+\))?$ ..?!
>> Let me know what you think, my goal was to prevent a confederated AS
>> from becoming a transit path, the reg exp that you see on your left
>> is what I came up with and on the left that's a well know one from
>> the IE blog. To me both seem to be the same,
>>
>> I will try and explain in brief here:
>>
>> (65535 64512 64513) thats how the as path would be like for the
>> routes that originated within the AS. I need to match these and be
>> able to export these out to the external AS ..whereas others which
>> have (65535 64512 64513) 100 200 300 must be blocked.
>>
>> So [0-9] is my atom here, since I can have zero or multiple instances
>> of these will use it with a *
>>
>> Hence arrive at [0-9]* , I need to match ( ) which is a special
>> character so I will use "\", but before that a bracket operation for
>> my atom. And obviously I will encose them within ^$, as thats what I need
in my as path.
>> My doubt here is that do I have to use [0-9]*_ as my atom or is just
>> [0-9]* enough to match the blank spaces separating the two intra confed
as nos. ya.
>>
>>
>> Let your thoughts and comments flow
>>
>>
>> Regards,
>> Andy.
>> --
>> My Blog URL: http://ccieno.blogspot.com/
>>
>
>
>
> --
> My Blog URL: http://ccieno.blogspot.com/
>
-- My Blog URL: http://ccieno.blogspot.com/Blogs and organic groups at http://www.ccie.net
This archive was generated by hypermail 2.1.4 : Thu Jan 01 2009 - 12:53:09 ARST