Re: [exim] regex assistance sought

Startseite
Nachricht löschen
Nachricht beantworten
Autor: Stephen Gran
Datum:  
To: Justin Koivisto, exim-users
CC: 
Betreff: Re: [exim] regex assistance sought
On Tue, Sep 28, 2004 at 04:54:09PM -0500, Justin Koivisto said:
> Stephen Gran wrote:
> >Another is the antispam*@??? ones - since there are
> >literally hundreds of numeric combinations, I'm going to need a
> >regex.
> >
> >Has anybody already done this work, or care to offer pointers to
> >writing working regex's for this kind fo thing? Any other know
> >callout addresses would also be helpful, of course.
> >
> >Thanks in advance,
>
> Total n00b here, and I don't know if this is is always quite (my first
> day), but I'll pipe in here...
>
> If you're expecting "antispam*@???" to be a regex (exim
> uses perl style, right?), then you are going to match:
>
> antispa[0 or more 'm' characters]@west[any character]verizon[any
> character]net
>
> if the * in your string represents any number of digits, then you may
> want to try this:
>
> antispam[0-9]*@west\.verizon\.net
>
> (the "\." means literal "." character.)
>
> If you know that there are only going to be 4 digits, try:
>
> antispam[0-9]{4}@west\.verizon\.net
>
> If I'm just littering the list, tell me - I've just started the whole
> exim thing in the last few days...


Right, I was kind of scribbling my thoughts out, which is something I
try to avoid - blame too much beer tonight while emailing :)

My initial thought was antispam.*@west\.verizon\.net - that is because I
have seen only digits, but I wanted to keep it simple on the off chance
I missed some that had letters.

My idea didn't work, and neither do yours (thanks though) and neither
does antispam\d+@west\.verizon\.net, which I would have thought would
work. Maybe I'm just not wrapping it right?

Not sure, but thanks anyway.
--
--------------------------------------------------------------------------
|  Stephen Gran                  | Be free and open and breezy!  Enjoy!    |
|  steve@???             | Things won't get any better so get used |
|  http://www.lobefin.net/~steve | to it.                                  |

--------------------------------------------------------------------------