So I've fixed never-ending SSL problem with courier imap and pop by replacing them with dovecot. It was surprisingly easy to setup, install dovecot-imap and dovecot-pop3 with apt-get, and then set up dovecot's ldap and maildir settings and it was up and running. (I'll post a seperate howto).
Problem is removing courier also removed ebox-mail, which means I can't add/change mail accounts from ebox anymore. Is there any way to reinstall ebox-mail plugin without it automatically reinstalling courier?
Cheers,
Andrew