fetchmail-friends
[Top] [All Lists]

Re: [fetchmail]Fetchmail Received line

2001-11-18 11:23:07
--On Friday, November 16, 2001 7:04 AM +0000 Rob MacGregor <rob_macgregor(_at_)hotmail(_dot_)com> wrote:

From: Jeff Tucker <jefft(_at_)wciatl(_dot_)com>

The second localhost appears to be the argument of the "smtphost"
command, so I can make that be whatever I want. The first localhost is
my mystery. The "hostname" program returns a reasonable name. I assume
that the gethostname syscall does also.

I seem to remember that fetchmail tries to deliver to the MTA on
localhost if you don't tell it otherwise.  If you told it to use your
mail server address it should solve your problem:

smtphost: mailhost.my.domain


No, as I said above, that affects the second localhost, not the first. The first localhost appears as "Received ... by localhost".

I looked at the source and it appears that the string "localhost" is hard-coded into the software. Only if you use a couple protocols (ETRN was one) does the fetchmail program even attempt to put anything else there. I simply replaced the code that sets the local hostname to "localhost" with a call to the routine that looks up the correct hostname and all my problems went away.

Jeff



--
Jeff Tucker
Williams Consulting, Inc.
jefft(_at_)wciatl(_dot_)com


<Prev in Thread] Current Thread [Next in Thread>