Symptoms

Horde is configured to use IMAP protocol on my Plesk server. The following error appears when trying to log in to webmail:

Login failed because your username or password was entered incorrectly.

The /var/log/psa-horde/psa-horde.log log can contain the following error:

HORDE [error] [imp] FAILED LOGIN

Cause

Plain text authentication is, most likely, disabled in the Courier IMAP configuration file.

Diagnostics

On the Plesk server, try connecting to localhost via IMAP using telnet:

# telnet localhost 143
Trying 127.0.0.1...
Connected to localhost.
Escape character is '^]'.
* OK [CAPABILITY IMAP4rev1 UIDPLUS CHILDREN NAMESPACE THREAD=ORDEREDSUBJECT THREAD=REFERENCES SORT QUOTA IDLE ACL ACL2=UNION STARTTLS] Courier-IMAP ready. Copyright 1998-2004 Double Precision, Inc. See COPYING for distribution information.
01 login mailname@example.com <password>
01 NO PLAIN text authentication does not support

If the connection is successful, please refer to the following article:

6781 Horde Webmail login fails: How to troubleshoot

If not, and you see the "01 NO PLAIN text authentication does not support" message, proceed to the resolution below.

If you are not able to connect through Telnet and seeing message as "Connection refused", then ensure that "courier-imap" service is running. If it is not running, start it with command:

  # /etc/init.d/courier-imap start

Resolution

Enable plain text authentication by editing /etc/courier-imap/imapd:

Add the AUTH=PLAIN parameter to the values of the IMAP_CAPABILITY variable.

For example:

IMAP_CAPABILITY="IMAP4rev1 UIDPLUS CHILDREN NAMESPACE THREAD=ORDEREDSUBJECT AUTH=PLAIN THREAD=REFERENCES SORT QUOTA IDLE"

Do not forget to restart courier-imap service:

# /etc/init.d/courier-imap restart

Internal content