[sieve][regex] Matching multiple strings in the "Received" header

Adi Pircalabu adi at ddns.com.au
Tue May 8 04:38:44 EEST 2018


On 08-05-2018 2:43, Benny Pedersen wrote:
> Adi Pircalabu skrev den 2018-05-07 05:10:
> 
>> How should I write it to also match the space character at both the
>> beginning and end of the expression?
> 
> use \ before space char

Tks. Just tried these two, unsuccessfully:
"\.from.*(outbound.protection.outlook.com|.google.com|.yahoo.com|mx.aol.com)\."
"\ 
from.*(outbound.protection.outlook.com|.google.com|.yahoo.com|mx.aol.com)\ 
"

However, this expression always matches:
"from.*(outbound.protection.outlook.com|.google.com|.yahoo.com|mx.aol.com)"

What am I missing?

---
Adi Pircalabu


More information about the dovecot mailing list