EmailDiscussions.com  

Go Back   EmailDiscussions.com > Email Service Provider-specific Forums > FastMail Forum
Register FAQ Members List Calendar Today's Posts
Stay in touch wirelessly

FastMail Forum All posts relating to FastMail.FM should go here: suggestions, comments, requests for help, complaints, technical issues etc.

Reply
 
Thread Tools
Old 25 Aug 2016, 04:00 PM   #1
Prognathous
Master of the @
 
Join Date: Aug 2002
Location: Israel
Posts: 1,060
Sieve script to block emails sent to text.number@my-address? [SOLVED]

I'm getting a lot of backscatter email with this pattern. Is there a way to filter it out? I never use text.number@, but do use text@ so it should be safe enough to filter out the former. The only question is - how?

Thanks!

Last edited by Prognathous : 30 Aug 2016 at 07:31 PM.
Prognathous is offline   Reply With Quote

Old 25 Aug 2016, 09:25 PM   #2
BritTim
The "e" in e-mail
 
Join Date: May 2003
Location: mostly in Thailand
Posts: 3,095
You can filter such addresses using a regular expression. Before doing so, ensure you are using the controls Fastmail already provides to discard backscatter. Adding custom rules is something to avoid until standard controls fail to achieve the desired effect. If you have already enabled discarding of backscatter, such messages are still leaking through, and you need help setting up a rule with a regular expression, please post again.
BritTim is offline   Reply With Quote
Old 26 Aug 2016, 12:33 AM   #3
pjwalsh
Essential Contributor
 
Join Date: Dec 2008
Location: Canada
Posts: 312
A regex suggestion to catch the dominant address type, based on Melomac's in the main Backscatter thread:

\w+\.\d+@sub\.domain\.tld

Quote:
Originally Posted by BritTim View Post
If you have already enabled discarding of backscatter, such messages are still leaking through, and you need help setting up a rule with a regular expression, please post again.
My backscatter rules based on individual samples number about a dozen now, I'd like to use something more effective, which would be a sieve regex.

FirstLast.nn@sub.domain.tld is the consistent format. After name and . there are 2-5 digits, the subdomain always the same, based on my main account address.

This has been beyond annoying. Yes I have Backscatter enabled in Spam protection, there's no 'mark as read' option.

Last edited by pjwalsh : 30 Aug 2016 at 01:58 AM.
pjwalsh is offline   Reply With Quote
Old 28 Aug 2016, 11:42 AM   #4
Prognathous
Master of the @
 
Join Date: Aug 2002
Location: Israel
Posts: 1,060
I just sent a question to Fastmail Support about this. Hopefully they can come up with a solution.
Prognathous is offline   Reply With Quote
Old 30 Aug 2016, 06:19 PM   #5
Prognathous
Master of the @
 
Join Date: Aug 2002
Location: Israel
Posts: 1,060
Kurian from Fastmail Support was very helpful. He suggested a script which I then tweaked a bit, and now this issue is solved. Here's the final script:

Code:
if header :regex "X-Delivered-to" "[a-z]+\\.[0-9]+@(myusername.domain.tld|myusername2.domain2.tld)" {
setflag "\\Seen";fileinto "INBOX.Trash";stop;
}
To quote Kurian:

Quote:
It looks for a one or more alphabetic characters followed by a period followed by one or more digits, followed by @, followed by a list of your domains separated by the | character. You can add any of your missing domains by separating them with |
Prognathous is offline   Reply With Quote
Old 30 Aug 2016, 06:37 PM   #6
Terry
The "e" in e-mail
 
Join Date: Jul 2002
Location: VK4
Posts: 3,029
Interesting thank you....
Terry is offline   Reply With Quote
Old 30 Aug 2016, 07:32 PM   #7
Prognathous
Master of the @
 
Join Date: Aug 2002
Location: Israel
Posts: 1,060
Is there a way to update the title of a thread to mark is as solved?
Prognathous is offline   Reply With Quote
Old 4 Sep 2016, 03:12 AM   #8
Prognathous
Master of the @
 
Join Date: Aug 2002
Location: Israel
Posts: 1,060
I just want to update that this script works perfectly. About 10 spam emails a day now arrive in the trash instead of my mailbox. Hopefully the spammers continue to use the text.number format, because it's easy to filter and is a format I'm not personally using.
Prognathous is offline   Reply With Quote
Old 4 Sep 2016, 09:13 AM   #9
Terry
The "e" in e-mail
 
Join Date: Jul 2002
Location: VK4
Posts: 3,029
You can use discard; stop; } then you wont see them at all...
Terry is offline   Reply With Quote
Old 5 Sep 2016, 06:43 AM   #10
Prognathous
Master of the @
 
Join Date: Aug 2002
Location: Israel
Posts: 1,060
That's what Kurian suggested, but I prefer the script to mark as read and move to trash to be able to better troubleshoot false positives etc.
Prognathous is offline   Reply With Quote
Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Forum Jump


All times are GMT +9. The time now is 10:34 PM.

 

Copyright EmailDiscussions.com 1998-2022. All Rights Reserved. Privacy Policy