Need filter for long return addresses

Whether you're a MailWasher veteran or complete newbie, all users are welcome to get together. Discussions include usage and possible problems.
us035976
Student Sheep
Posts: 12
Joined: Mon Nov 10, 2008 5:46 pm

Need filter for long return addresses

Tue Aug 14, 2012 12:57 am

A lot of my spam recently has had a return email address with a series of random lower case letters before the @ symbol. The common thing is that they are all a long series of characters (>12-15). Is there a way I can filter them out based on more than a certain number of characters before the @ symbol?
Rich
User avatar
stan_qaz
Omniscient Kiwi
Location: Gilbert, Arizona
Posts: 8671
Joined: Fri Jul 25, 2008 5:13 am

Re: Need filter for long return addresses

Wed Aug 15, 2012 4:39 am

Yes use a regex filter that looks for more than the number of good lower case letters. I don't have my old v6 documentation around but if you search the forum you might find it. The v2012 version of MW has a similar regex engine so you might try their documentation to see if it is close enough.

http://www.regexlab.com/en/deelx/syntax.htm
I am not a Firetrust employee just a MW user.
--
First rule of computer consulting: Sell a customer a Linux computer and you'll eat for a day,
sell a customer a Windows computer and you'll eat for a lifetime.
us035976
Student Sheep
Posts: 12
Joined: Mon Nov 10, 2008 5:46 pm

Re: Need filter for long return addresses

Wed Aug 15, 2012 12:09 pm

I can figure out the RegExpr to count the number of characters. How do I make it only look at before the @ symbol in the 'From' field?
User avatar
stan_qaz
Omniscient Kiwi
Location: Gilbert, Arizona
Posts: 8671
Joined: Fri Jul 25, 2008 5:13 am

Re: Need filter for long return addresses

Wed Aug 15, 2012 1:17 pm

To speed it up I'd look for a beginning of the line, the string "From:" ignore the colon and space (the ..) then your character count and finally the "@" which is a normal character. Something like this would probably work, I didn't test it though.

Code: Select all

^From..[:lower:]{12, }+@
I am not a Firetrust employee just a MW user.
--
First rule of computer consulting: Sell a customer a Linux computer and you'll eat for a day,
sell a customer a Windows computer and you'll eat for a lifetime.

Return to “Troubleshooting and Help for MailWasher 5 and 6”