On 11/14/2013 9:27 AM, Michael P. Demelbauer wrote: > On Thu, Nov 14, 2013 at 08:19:52AM -0600, Noel Jones wrote: >> On 11/14/2013 1:07 AM, tejas sarade wrote: >>> I think .* will match everythig. >>> >>> On Nov 13, 2013 8:32 PM, "Noel Jones" <njo...@megan.vbhcs.org >> >> The expression I posted is correct. >> /^(To|From|Cc|Reply-To): .*[" <]admin@/ DISCARD >> >> This should match headers such as >> From: System admin <ad...@example.com> >> or other variations. >> >> >> -- Noel Jones > > Hallo Noel, > > this might be off topic here, but I'm wondering about the regexp since > yesterday. > > How will this match "<admin@....>" a variant I've already seen in some > clients. If I understand the alternation correctly it searches for " > Blank or < directly followed by admin@. What's my mistake? > > Many thx and sorry for OT, >
Given the case of "<admin@....>", the .* will match the " and the grouping will match the < followed by admin@. -- Noel Jones