Heiko Schlittermann <h...@schlittermann.de> (So 23 Feb 2025 10:13:11 CET): > Viktor Ustiuhov via Exim-users <exim-users@lists.exim.org> (So 23 Feb 2025 > 03:02:30 CET): > > As mentioned in a previous message, DMARC forces us to have not more > than one address in the From: header (and Outlook365(?) seems to force > us too, not sure, if related to domains using DMARC). At least, recently > I saw rejections of messages with more than one address in the From: > header.
This would work for multiple from addresses, it checks the domains of the sender and the from addresses. ${if and{ {match{$h_x-bogosity:}{(?i)^spam,}} { !forany{$sender_address_domain:${map{${addresses:$h_from:}}{${domain:$item}}}} {bool{${lookup{$item}lsearch{/tmp/x.bogook}{yes}}}} } } {spam}{ham} } If you want to check full addresses, use lsearch*@ and $sender_address instead of $sender_address_domain and drop the mapping from the from-addresses to their domains: ${if and{ {match{$h_x-bogosity:}{(?i)^spam,}} { !forany{$sender_address:${addresses:$h_from:}} {bool{${lookup{$item}lsearch*@{/tmp/x.bogook}{yes}}}} } } {spam}{ham} } -- Heiko
signature.asc
Description: PGP signature
-- ## subscription configuration (requires account): ## https://lists.exim.org/mailman3/postorius/lists/exim-users.lists.exim.org/ ## unsubscribe (doesn't require an account): ## exim-users-unsubscr...@lists.exim.org ## Exim details at http://www.exim.org/ ## Please use the Wiki with this list - http://wiki.exim.org/