You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@spamassassin.apache.org by Chris Santerre <cs...@MerchantsOverseas.com> on 2004/04/23 17:53:58 UTC

RE: Rule to match a from address with more than 5 consecutive con sena nts or numbers in the username

Try /[^aeiou]{5,}\@/i
 
hth
 
--Chris

-----Original Message-----
From: jburzenski@americanhm.com [mailto:jburzenski@americanhm.com]
Sent: Friday, April 23, 2004 11:37 AM
To: spamassassin-users@incubator.apache.org
Subject: Rule to match a from address with more than 5 consecutive consena
nts or numbers in the username



Hi All, 

I was wondering if someone could help me with a rule I am working on.  I
want to score messages that come from addresses like:

        jx8vb@yahoo.com, tgh99f@msn.com and 0149HHf@email.com 

I don't care what domain it comes from, I just want to score based on the
username.  I want to rule to match if there are at least 5 characters with
no vowels occuring.  The regex I have developed so far is:

/[b-dB-Df-hF-Hj-nJ-Np-tP-Tv-zV-Z0-9]{5,}\@/ 

Is there an easier way to do this?  Does anyonkne know about a better rule
to catch these messages? 

Thanks, 

Jason 
(SA 2.55) 


RE: Rule to match a from address with more than 5 consecutive con sena nts or numbers in the username

Posted by "Adam D. Lopresto" <ad...@pubcrawler.org>.
That's going to catch some FPs.  (Not that the original won't, but this will
catch other things, too).  Consider something like

"Jason" <jw...@example.com>

where we've only got two consonants before the @, but we've got six non-vowel
characters.

Also, and I keep saying this in different contexts, but there's no reason to
have the {5,} if you're not going to tag it.  Just use {5}.

Personally, I'd just write it as

/[bcdfghjklmnpqrstvwxyz0-9]{5}\@/i

but that's just because for some reason that feels easier to read to me than
all the ranges.  But that's just me and my whackiness, and I can't justify it.

On Fri, 23 Apr 2004, Chris Santerre wrote:

> Try /[^aeiou]{5,}\@/i
>
> hth
>
> --Chris
>
> -----Original Message-----
> From: jburzenski@americanhm.com [mailto:jburzenski@americanhm.com]
> Sent: Friday, April 23, 2004 11:37 AM
> To: spamassassin-users@incubator.apache.org
> Subject: Rule to match a from address with more than 5 consecutive consena
> nts or numbers in the username
>
>
>
> Hi All,
>
> I was wondering if someone could help me with a rule I am working on.  I
> want to score messages that come from addresses like:
>
>         jx8vb@yahoo.com, tgh99f@msn.com and 0149HHf@email.com
>
> I don't care what domain it comes from, I just want to score based on the
> username.  I want to rule to match if there are at least 5 characters with
> no vowels occuring.  The regex I have developed so far is:
>
> /[b-dB-Df-hF-Hj-nJ-Np-tP-Tv-zV-Z0-9]{5,}\@/
>
> Is there an easier way to do this?  Does anyonkne know about a better rule
> to catch these messages?
>
> Thanks,
>
> Jason
> (SA 2.55)
>
>

-- 
Adam Lopresto
http://cec.wustl.edu/~adam/

Scientists have demonstrated that lab rats who sleep on their sides with
pillows between their legs experience far less back problems than rats
who do not.

--Jamin Gray