[imp] How to specify HELO address ??

Jon Parise jon@horde.org
Mon, 29 Jul 2002 14:03:04 -0400


On Mon, Jul 29, 2002 at 01:40:13PM -0400, Derek J. Balling wrote:

> This appears to be set in /usr/share/pear/Net/SMTP.php on my system:
> 
>         /**
>      * The value to give when sending EHLO or HELO.
>      * @var string
>      */
>         var $localhost = 'localhost';
> 
> Which, to me, is a bug in that code, because it should be determining 
> the gethostbyaddr() for itself, etc.  Using localhost in SMTP any time 
> other than when connecting to localhost, is invalid.
 
I think the larger problem is that the Mail::SMTP interface does not
allow the third optional parameter (which overrides the above
$localhost default) to be set in the Net::SMTP constructor.

Using gethostbyaddr(), as you suggest, does seem like a more
reasonable default.

-- 
Jon Parise (jon@horde.org) :: The Horde Project (http://horde.org/)