[horde] SOLVED: set bind address for outbound smtp connections

A. Schulze sca at andreasschulze.de
Tue May 26 18:57:34 UTC 2015


Jan Schneider:

> Ah, there is some 'socket' missing. It should read then:
> $conf['mailer']['params']['socket']['bindto'] = ...
nearly.

On a host with multiple IP addresses users could set the preferred IP address
Horde use as source address for outbound SMTP connections by adding  
the following to
~horde/config/conf.local.php:

    <?php
    $conf['mailer']['params']['context']['socket']['bindto'] =  
'192.0.2.1:0';      for IPv4
    $conf['mailer']['params']['context']['socket']['bindto'] =  
'[2001:db8::1]:0'   for IPv6

see http://php.net/manual/de/context.socket.php


together with
    $conf['mailer']['params']['host'] = 'mail.example.org';
    $conf['mailer']['params']['localhost'] = 'horde.example.org';

Submitted messages will be seen and logged by the SMTP Server in the  
perfect matching way:

     Received: from horde.example.org (horde.example.org [IPv6:2001:db8::1])
         ...
	by mail.example.org (Postfix) with ESMTPSA id 3lx49K4nkBzDcJ
	for <...>; Tue, 26 May 2015 20:50:13 +0200 (CEST)

Jan, thanks for pointing the right direction :-)
Andreas




More information about the horde mailing list