Spam Filter ISP Support Forum

  New Posts New Posts RSS Feed - Reject emails starting with numbers
  FAQ FAQ  Forum Search   Register Register  Login Login

Reject emails starting with numbers

 Post Reply Post Reply
Author
CyberBob View Drop Down
Groupie
Groupie


Joined: 26 January 2005
Status: Offline
Points: 43
Post Options Post Options   Thanks (0) Thanks(0)   Quote CyberBob Quote  Post ReplyReply Direct Link To This Post Topic: Reject emails starting with numbers
    Posted: 29 November 2004 at 12:39pm

Can someone help me with the Regex to reject any email that starts with a number or a number of numbers.

As we all know spammers make up emails and the filter is stopping them but now I'm getting a request to reject any email that starts with numbers on a certain domain.

In the "Reject To" list I tried:

[0-9]*@mydomain.com

but it started blocking everything and I see the star is doing that. How do I specify starting with numbers @ a domain.

Thanks in advance,

Bob

Back to Top
keizersozay View Drop Down
Groupie
Groupie
Avatar

Joined: 26 January 2005
Location: United States
Status: Offline
Points: 77
Post Options Post Options   Thanks (0) Thanks(0)   Quote keizersozay Quote  Post ReplyReply Direct Link To This Post Posted: 29 November 2004 at 2:00pm

(([0-9].*@mydomain\.com))

 

try this. I haven't tested it yet though.

Back to Top
CyberBob View Drop Down
Groupie
Groupie


Joined: 26 January 2005
Status: Offline
Points: 43
Post Options Post Options   Thanks (0) Thanks(0)   Quote CyberBob Quote  Post ReplyReply Direct Link To This Post Posted: 30 November 2004 at 2:35pm

Close but not quite.

Yes it blocks any email with a leading number but it also blocks any email with a number in it??

Example:

Bob@mydomain.com was ok

1bob@mydomain.com was blocked

bob1@mydomain.com was also blocked??

How do I fix that??

Back to Top
keizersozay View Drop Down
Groupie
Groupie
Avatar

Joined: 26 January 2005
Location: United States
Status: Offline
Points: 77
Post Options Post Options   Thanks (0) Thanks(0)   Quote keizersozay Quote  Post ReplyReply Direct Link To This Post Posted: 30 November 2004 at 2:56pm

(([0-9]\D+?@mydomain\.com))

this should work. again, I have not tested this.

here is the explanation

Non-capturing Group
  Non-capturing Group
    Any character in "0-9"
    Any non-digit
    + (one or more times) (non-greedy)
    @mydomain.com
  End Capture
End Capture

Back to Top
CyberBob View Drop Down
Groupie
Groupie


Joined: 26 January 2005
Status: Offline
Points: 43
Post Options Post Options   Thanks (0) Thanks(0)   Quote CyberBob Quote  Post ReplyReply Direct Link To This Post Posted: 30 November 2004 at 3:30pm

Now we aren't capturing anything? Everything works

Bob@mydomain.com

Bob1@mydomain.com

1bob@mydomain.com

1@mydomain.com

They way I read this I thought it was ONLY looking for numbers so I thought for sure 1@mydomain.com would be blocked but it went through also?

 

Back to Top
CyberBob View Drop Down
Groupie
Groupie


Joined: 26 January 2005
Status: Offline
Points: 43
Post Options Post Options   Thanks (0) Thanks(0)   Quote CyberBob Quote  Post ReplyReply Direct Link To This Post Posted: 30 November 2004 at 4:55pm

Ok thanks for helping me get started but this is tested and working:

([0-9][a-z]+@mydomain.com)

I saw you did a double capture, do I need to?

Thanks for the help!!

Bob

Back to Top
benny View Drop Down
Guest Group
Guest Group
Post Options Post Options   Thanks (0) Thanks(0)   Quote benny Quote  Post ReplyReply Direct Link To This Post Posted: 13 December 2004 at 4:20pm
What if I want to block any incoming email with FROM EMAIL has a number?
Back to Top
 Post Reply Post Reply
  Share Topic   

Forum Jump Forum Permissions View Drop Down



This page was generated in 0.047 seconds.