Author Topic: Login Error: Authenticate using CRAM-MD5 Fails  (Read 10654 times)

Offline snowweb

  • Jr. Member
  • **
  • Posts: 35
Login Error: Authenticate using CRAM-MD5 Fails
« on: August 11, 2012, 07:44:33 AM »
I get the following error when trying to login:
Code: [Select]
IMAP Error in /usr/share/roundcubemail/program/include/rcube_imap.php (205): Login failed for peter@localhost from 112.201.176.57. AUTHENTICATE CRAM-MD5: A0001 NO [AUTHENTICATIONFAILED] Authentication failed.
I've setup Dovecot to use CRAM-MD5 in the following line in the dovecot config
Code: [Select]
auth_mechanisms = cram-md5
and in /etc/roundcube/main.inc.php
Code: [Select]
$rcmail_config['imap_auth_type'] = '';According to the documentation, this should cause it to choose the best supported authentication mechanism.

What am I doing wrong please.

Many thanks in advance.

Peter

Offline SKaero

  • Administrator
  • Hero Member
  • *****
  • Posts: 5,876
    • SKaero - Custom Roundcube development
Re: Login Error: Authenticate using CRAM-MD5 Fails
« Reply #1 on: August 11, 2012, 04:13:19 PM »
Can you enable imap_debug and post the log of the attempted login?

Offline snowweb

  • Jr. Member
  • **
  • Posts: 35
Re: Login Error: Authenticate using CRAM-MD5 Fails
« Reply #2 on: August 11, 2012, 08:10:33 PM »
Appreciate your reply SKaero. Sorry for the delayed response, but 4am in the morning here when you replied!!

I've enabled imap_debug and tried again to login and this is what it logged
Code: [Select]
[12-Aug-2012 08:04:37 +0800]: [60FA] S: * OK [CAPABILITY IMAP4rev1 LITERAL+ SASL-IR LOGIN-REFERRALS ID ENABLE IDLE AUTH=CRAM-MD5] Dovecot ready.
[12-Aug-2012 08:04:37 +0800]: [60FA] C: A0001 ID ("name" "Roundcube Webmail" "version" "0.7.2" "php" "5.3.3" "os" "Linux" "command" "/rc/")
[12-Aug-2012 08:04:37 +0800]: [60FA] S: * ID NIL
[12-Aug-2012 08:04:37 +0800]: [60FA] S: A0001 OK ID completed.
[12-Aug-2012 08:04:37 +0800]: [60FA] C: A0002 AUTHENTICATE CRAM-MD5
[12-Aug-2012 08:04:37 +0800]: [60FA] S: + PDkxNzgzMTk0NTMyNjAyNzMuMTM0NDcyOTg3N0BiazEuc2VydmVyPg==
[12-Aug-2012 08:04:37 +0800]: [60FA] C: cGV0ZXIgMTEwYWZhMmI0ZDIwNmMwYzg1MGE1NmU4YzRkZDhmOWQ=
[12-Aug-2012 08:04:39 +0800]: [60FA] S: A0002 NO [AUTHENTICATIONFAILED] Authentication failed.
[12-Aug-2012 08:04:39 +0800]: [60FA] C: A0003 LOGOUT
[12-Aug-2012 08:04:39 +0800]: [60FA] S: * BYE Logging out
[12-Aug-2012 08:04:39 +0800]: [60FA] S: A0003 OK Logout completed.

I know it looks like I simply input the incorrect password, but I can assure you that I didn't and it does work, if I set /etc/dovecot/dovecot.conf to "authenticate = plain".

Thanks for your attention to this.

Peter

Offline SKaero

  • Administrator
  • Hero Member
  • *****
  • Posts: 5,876
    • SKaero - Custom Roundcube development
Re: Login Error: Authenticate using CRAM-MD5 Fails
« Reply #3 on: August 12, 2012, 07:12:46 AM »
RoundCube appears to be sending the login information correctly so if it is the correct password then it a Dovecot problem.