On Wed, Sep 16, 2009 at 07:53:51AM -0600, LuKreme wrote: > On 16-Sep-2009, at 05:28, Laurence Moughan wrote: >> postmap -q "boarding" regexp:/etc/postfix/headerchecks >> >> This comes back with nothing - i thought it might coma back with a >> match ? > >> /^From:(.*)boarding_...@domain\.com/ REJECT junk >> /^From:(*)boarding(*)\...@adomain\.com/ REJECT junk >> /^From: *boardin...@domain\.com/ REJECT junk >> /^From: (.*)boarding(.)*...@domain\.com/ REJECT junk > > Your regex all require an '@domain\.com. > > First, change them to one line as Martijn suggested: > > /^From: .*boarding...@domain\.com$/ REJECT junk > > Note the $ at the end of the match, that is quite important. > > then > > postmap -q "board...@doamin.com" regexp:/etc/postfix/headerchecks
Naturally that won't match, since regex has start anchored. postmap -q "From: board...@domain.com" regexp:/etc/postfix/headerchecks