RE: Regular Expressions

From: Scott Morris (swm@emanon.com)
Date: Sat Jan 10 2004 - 19:05:02 GMT-3


Your first one there matches all prefixes ORIGINATING in AS 900 (that will
be the end of the string, or the oldest AS).

Your third one, I'm not entirely sure what it accomplishes other than going
through SOMETHING! :)

Your last one, you have to remember that the _ character represents a comma,
{, }, (, ), beginning, end or space within a string. For AS paths, we
primarily think of this as the space between AS numbers in the path. So you
are mathing something transiting 99 and 0 or 1 other AS, but originating
from 75. Not the last two digits of 75, but 75 itself.

If you had the last string as ...75 (since 5 characters is the max set
anyway), then that would be great for anything ending in 75. But the
"(_|_.*_)" refers to the single space or anything within that one AS set
(between spaces). If you wanted to have it pass through multiple (as many
as necessary) systems, you woul duse the "(_|_.*_)*" instead. That * on the
outside of the parentheses treats the entire thing as a "0 or more of"
match.

Regurlar expressions are enough to make your brain hurt. :)

 
Scott Morris, CCIE4 (R&S/ISP-Dial/Security/Service Provider) #4713, CISSP,
JNCIS, et al.
IPExpert CCIE Program Manager
IPExpert Sr. Technical Instructor
swm@emanon.com/smorris@ipexpert.net
http://www.ipexpert.net

-----Original Message-----
From: nobody@groupstudy.com [mailto:nobody@groupstudy.com] On Behalf Of
Nathasha Aleyevka
Sent: Saturday, January 10, 2004 4:46 PM
To: ccielab@groupstudy.com
Subject: Regular Expressions

Hi,
I have created the following 4 REs:
Would you please go over'em and advise me:
 
1) _900$ matches all the prefixes learned from BB1(900)
 
2) _500_ matches all the prefixes which transited AS500 :
 
3) _|.* any neighbor or AS using my terms
 
4) _99(_|_.*_)75$ matches any path that goes through AS99 and ends
with an AS# whos the last 2 digits are 75

I used the infot from
http://www.cisco.com/univercd/cc/td/doc/product/software/ios122/122cgcr/fdia
l_c/fnsprt13/dafaapre.htm
 
Thank you very much
Nathasha

---------------------------------
Do you Yahoo!?
Yahoo! Hotjobs: Enter the "Signing Bonus" Sweepstakes



This archive was generated by hypermail 2.1.4 : Mon Feb 02 2004 - 09:07:39 GMT-3