On 9/10/20 3:13 PM, Dennis Putnam wrote: > On 9/10/2020 2:56 PM, Richard Damon wrote: >> On 9/10/20 2:37 PM, Dennis Putnam wrote: >>> On 9/10/2020 2:01 PM, Richard Damon wrote: >>>> On 9/10/20 12:47 PM, Dennis Putnam wrote: >>>>> I am getting email from entities with From: no-reply headers. Is there a >>>>> way to filter those and just dump them in the bit bucket rather than go >>>>> through bounce processing? TIA. >>>>> >>>> If you can write a regex for them, you could put it into Privacy / Spam >>>> Filters with result discard. Might want to test with Hold to see if you >>>> get false positives with your regex first. >>>> >>> Thanks for the reply. I'm not a regex expert so I am struggling with >>> this a bit. I can get this much to work: >>> >>> (?i)no-reply@ >>> >>> However, I have to make sure this occurs in the 'From' header and that >>> is the part I don't know how to add. Does the filter parse the entire >>> raw message? It appears there is some character I cannot seem to catch >>> after the 'From:'. >>> >>> This does not work: >>> >>> From:\s.?(?i)no-reply >> \s.? says a space followed by 0 or 1 occurance of any character. >> >> I would use something like: >> >> From:\s.*no-reply >> > Thanks again for the reply. Unfortunately that doesn't work either. > That is very much what I use (though I omit the \s, figuring that the space isn't that important for choosing the header
Try: ^From.*no-reply The ^ say it must start there, that matches sort of one of the filters I have that works. When you say "doesn't work", are you not catching something it should, or catching stuff it shouldn't Like I said, I would start with setting the behavior to Hold to start. -- Richard Damon ------------------------------------------------------ Mailman-Users mailing list -- mailman-users@python.org To unsubscribe send an email to mailman-users-le...@python.org https://mail.python.org/mailman3/lists/mailman-users.python.org/ Mailman FAQ: http://wiki.list.org/x/AgA3 Security Policy: http://wiki.list.org/x/QIA9 Searchable Archives: https://www.mail-archive.com/mailman-users@python.org/ https://mail.python.org/archives/list/mailman-users@python.org/