Re: [exim] My IP in smtp transport?

Pàgina inicial
Delete this message
Reply to this message
Autor: Wakko Warner
Data:  
A: exim-users
Assumpte: Re: [exim] My IP in smtp transport?
Philip Hazel wrote:
> On Sat, 8 Oct 2005, Wakko Warner wrote:
> > I have looked through the expansion variables and I can't figure out how
> > retrieve the IP that my host is using to connect to another host. I'm doing
> > this so it can set the helo data in the smtp transport.
> >
> > I tried this:
> > smtp:
> >         driver = smtp
> >         helo_data = ${lookup dnsdb{ptr=$interface_address}}

> >
> > Unfortunately that variable is unset.


Thank you Phil. However:

> $interface_address


I did read this one. I just stuck it in just to see what would happen. The
results were not surprising.

> $host_address
>     This variable is set to the remote host's IP address whenever $host is set
>     for a remote connection. It is also set to the IP address that is being
>     checked when the ignore_target_hosts option is being processed.

>
> $host
>     When the smtp transport is expanding its options for encryption using TLS,
>     $host contains the name of the host to which it is connected. Likewise,
>     when used in the client part of an authenticator configuration (see chapter
>     33), $host contains the name of the server to which the client is
>     connected.

>
>     When used in a transport filter (see chapter 24) $host refers to the host
>     involved in the current connection. When a local transport is run as a
>     result of a router that sets up a host list, $host contains the name of the
>     first host.


These do not work for what I wanted. I didn't try these until just now,
they corespond to the host exim is connecting to. Exim is the client in the
case I'm referring to.

I dislike obfuscating, however I don't want the addresses (Publically
available to the internet) to be archived as they are honeypot addresses. I
will give this information privately as long as it doesn't get back to the
list. (I don't want the spammers to know the addresses of my open honey pot
relays and just ignore them.) I have a seperate configuration that is
loaded on the command line when I want the system to send out email which is
why I want this.

I'm wanting to do this so that I can use ip route to give the source address
and have exim lookup the source address to form a proper HELO string. IE:

default via 192.168.2.9 dev eth0 src 10.10.10.27
(192.168.2.9 is real, 10.10.10.27 is fake, however the .27 is real)

here's what I'd like, when exim sends a message, it looks up the ptr record
of 10.10.10.27 and uses the hostname as the HELO. right now, 10.10.10.27 is
card coded in the transport. I could use a MACRO, but it's not quite what I
wanted.

--
Lab tests show that use of micro$oft causes cancer in lab animals
Got Gas???