Issue with LMTP proxying and port number

Stephan Bosch stephan at rename-it.nl
Sun Jan 20 15:16:22 EET 2019



Op 06/01/2019 om 19:35 schreef Stephan Bosch:
> Op 06/01/2019 om 17:02 schreef Steven Craig:
>> On 1/6/2019 8:00 AM, Stephan Bosch wrote:
>>> Op 06/01/2019 om 11:50 schreef Stephan Bosch:
>>>> Op 31/12/2018 om 23:59 schreef Steven Craig:
>>>>> Hello there,
>>>>>
>>>>> Everything was working fine on Dovecot 2.2.10 (on CentOS 7), but 
>>>>> after updating to version 2.2.36, our director servers are not 
>>>>> able to proxy LMTP.
>>>>>
>>>>> We are sending mail from exim to the local Dovecot LMTP socket, 
>>>>> which then used to send it to our internal mail servers on port 24.
>>>>>
>>>>> Besides the update, nothing has changed in the config files. The 
>>>>> configuration has been working great for months … Then we had a 
>>>>> great idea of doing holiday maintenance.
>>>>>
>>>>> (Currently, we are working around this issue by having exim send 
>>>>> mail to the IP and port, instead of the socket.)
>>>>>
>>>>> Doing a tcpdump capture shows no TCP traffic either.  The logs 
>>>>> seem to say that it is trying to go to port 0, so my guess is that 
>>>>> it’s not getting the port directive from either static or sql — 
>>>>> since the docs state that if these settings aren't specified, it 
>>>>> will always use the same connection type for the proxy that it 
>>>>> received the connection on.
>>>>>
>>>>> Any thoughts?  I can share config if necessary.
>>>>
>>>> Yes, output from `dovecot -n` could be helpful.
>>>> Also a literal dump of those errors in the log could help.
>>>
>>> Never mind, I can reproduce it here, even with master.
>>> We'll get back to you.
>
> Actually, this is equally problematic for Dovecot v2.2.10. I could 
> reproduce this there too by my method (after some considerable 
> difficulty to get that compiled on a modern system). So, first of all, 
> I am wondering why this worked at your end in the first place and why 
> it finally failed upon upgrade.
>
> The problem is that services like imap, pop3, managesieve, and 
> submission define a literal default port for proxying, while lmtp 
> really doesn't. Instead, LMTP uses the local port of the server as the 
> default for the outgoing proxy connection. With unix services, there 
> is no local port and hence no default, which instead results in using 
> an (erroneous) port 0.
>
> Arguably, it would be useful to define a lmtp_proxy_port setting to 
> have a default for situations when none other can be obtained. LMTP 
> has no properly registered standard port, so hard-coding the default 
> to 24 could be a bad idea.

Tracking internally as DOP-868.

Regards,

Stephan.



More information about the dovecot mailing list