Auteur: Keith G. Murphy
Datum:
Aan: exim-users
Onderwerp: [Exim] Why does '\\d+' not work in condition line?
The following line always works fine for me when testing whether an
E-mail came from a set of hosts:
condition = "${if or {{eq {$received_protocol}{scanned-ok}} {match
{$sender_ho
st_address}{^192\\.168\\.100\\.}}} {0}{1}}"
But this does not ever match anything
condition = "${if or {{eq {$received_protocol}{scanned-ok}} {match
{$sender_ho
st_address}{^192\\.168\\.100\\.\\d+}}} {0}{1}}"
I have tried every variety of backslashing, '{3}' and '\{3\}' rather
than '+', etc., etc., etc.
This seems odd to me as well:
condition = "${if or {{eq {$received_protocol}{scanned-ok}} {match
{$sender_ho
st_address}{^192\\.168\\.100\\.101\$}}} {0}{1}}"
causes:
'$ not followed by letter, digit, or {'
Shouldn't one backslash be sufficient for the '$', since it is not
required within the regular expression?
My real question, I guess, is: does this sort of thing work for you
folks, and could you show me examples?
I'm using version 3.35 of exim.
Thanks in advance.