I ran into a couple of issues with 2.0.13. I was able to work around them,
but I suspect they need to be addressed.

1. master crashes if the LMTP socket specified is in a nonexistent path.
Yes, this is a misconfiguration, but master appears to work until it accepts
the first imap/pop/whatever connection, then it crashes. The origin of the
crash is in master.c at line 1296.

y is set above to Services[i].socket. Since that socket couldn't be
opened properly, it is == -1. In line 1296, the code performs an
FD_ISSET(y, &rfds). This goes bonkers. If the LMTP socket couldn't
be created, then either master should bomb with a suitable error message
or not try and do an FD_ISSET with a negative number.

2. imapd loses its "-s" argument the 2nd time around. I suspect this is a
setproctitle issue, but I haven't tried to prove it. If I do
'openssl s_client -connect localhost:imaps', then '. logout' and then
very quickly 'telnet localhost imaps', I get a non-SSLed imapd.
Further research shows that when this happens the 'imaps' variable in the
code is set to 0, which can only be because the argv[][] given to
service_main() does not have a "-s" in it.

A workaround is to set MAX_USE to -1 in master/service.h. This is obviously
a punitive measure, but it can be ameliorated by preforking a bunch of
service handlers in cyrus.conf.

All of this was observed with cyrus-imap 2.0.13 running on FreeBSD 4.3
built straight from the ports tree.

Reply via email to