Re: [exim] Checking the "local_part" of a Sender

Top Page
Delete this message
Reply to this message
Author: Brian Spraker
Date:  
To: exim-users
Subject: Re: [exim] Checking the "local_part" of a Sender


--- On Fri, 8/3/12, Duane Hill <duihi77@???> wrote:

> From: Duane Hill <duihi77@???>
> Subject: Re: [exim] Checking the "local_part" of a Sender
> To: exim-users@???
> Date: Friday, August 3, 2012, 9:29 PM
> On Saturday, August 04, 2012 at
> 02:19:05 UTC, spraker@???
> confabulated:
>
> > Hello all,
>
> > I know that you can check the "local_part" of a
> recipient, but how can you check this for a sender?
>
> > In essence, there seems to be a lot of spam e-mail
> coming in.  They
> > all have the same "local_part" but the domain name is
> different.
>
> > So it would be nice if there is a way to block this.
>
> > I've seen where people setup something like:
>
> > deny
> > senders = sender@*
>
> > Where a wildcard is used.
>
> > But, I have a MySQL database that is setup for checking
> sender
> > addresses.  This means it has to be an exact
> match.
>
> > Is there already a variable that is used to hold the
> "local_part"
> > of a sender?  I've done a lot of digging and am
> unable to find one.
>
> From an answer posted to a question on  this list a
> couple days ago:
>
> $sender_address_local_part
>
> See http://www.exim.org/exim-html-current/doc/html/spec_html/ch11.html


Thank you, Duane. I actually was looking at that exact page just about five minutes ago and completely overlooked that. Certainly is my fault.

So I got it setup to look for the sender_address_local_part but it still seems like it isn't working. I did a debug:

exim -bh <IP_address>

And the below line, exim thinks it is trying to compare the domain name with the local part:

senders = ${lookup mysql{select sender from exim_sender_blacklist where `sender` LIKE '${quotemysql:$sender_address_local_part}'}}

I tried using e-mail address "trustedservices@???" and the debug showed:

does "me.com" match "trustedservices" - no

Brian S.