Take the 2-minute tour ×
Server Fault is a question and answer site for system and network administrators. It's 100% free, no registration required.

I have followed the ISPMail tutorial on how to set up a Debian mail server.

I can log into the dovecot server through telnet like this:

[root@{hostname}: /home/{user}]# telnet {hostname}.{TLD} 143
Trying 127.0.1.1...
Connected to {hostname}.{TLD}.
Escape character is '^]'.
* OK [CAPABILITY IMAP4rev1 LITERAL+ SASL-IR LOGIN-REFERRALS ID ENABLE STARTTLS     AUTH=PLAIN] Dovecot ready.
1 LOGIN {user}@{hostname}.{TLD} {password}
1 OK [CAPABILITY IMAP4rev1 LITERAL+ SASL-IR LOGIN-REFERRALS ID ENABLE SORT SORT=DISPLAY     THREAD=REFERENCES THREAD=REFS MULTIAPPEND UNSELECT IDLE CHILDREN NAMESPACE UIDPLUS LIST-    EXTENDED I18NLEVEL=1 CONDSTORE QRESYNC ESEARCH ESORT SEARCHRES WITHIN CONTEXT=SEARCH LIST-    STATUS] Logged in

(Sidenote) should not these 2 commands be identical?

[root@{hostname}: /home/{user}]# telnet {hostname}.{TLD} imaps
Trying 127.0.1.1...
Connected to {hostname}.{TLD}.
Escape character is '^]'.
1 LOGIN {user}@{hostname}.{TLD} {password}
Connection closed by foreign host.

But when I try to access the server with a mailprogram (mutt) like this:

mutt -f imaps://{hostname}.{TLD}
Username at {hostname}.{TLD}: {user}@{domain}
Password for {user}@{domain}@{hostname}.{TLD}: {password}
Logging in.
Login failed.
Closing connection to {hostname}.{TLD}

Here is /var/log/mail.log:

Jan  2 00:50:55 {hostname} dovecot: imap-login: Login: user=<{user}@{domain}>, method=PLAIN, rip=127.0.1.1, lip=127.0.1.1, secured
Jan  2 00:51:03 {hostname} dovecot: IMAP({user}@{domain}): Disconnected: Too many invalid IMAP commands. bytes=38/1284
Jan  2 00:51:26 {hostname} dovecot: imap-login: Disconnected (no auth attempts): rip=127.0.1.1, lip=127.0.1.1, TLS handshaking: SSL_accept() failed: error:140760FC:SSL routines:SSL23_GET_CLIENT_HELLO:unknown protocol
Jan  2 00:51:55 {hostname} dovecot: imap-login: Aborted login (auth failed, 1 attempts): user=<{user}@{domain}>, method=PLAIN, rip=127.0.1.1, lip=127.0.1.1, TLS
Jan  2 00:52:15 {hostname} dovecot: imap-login: Aborted login (auth failed, 1 attempts): user=<{user}>, method=PLAIN, rip=127.0.1.1, lip=127.0.1.1, TLS

Thunderbird and my iPhone' mail program can't login either.

What could be causing this problem?

share|improve this question

1 Answer 1

up vote 0 down vote accepted

Num-Lock / Num-Pad

the number pad or num-lock maybe causing problem in password and maybe difficult to spot. Use number keys on top of keyboard.

Telnet

IMAP(IMAP4) port is 143. Traffic is in plain text. That why you can connect with telnet.

IMAPS(IMAP4 over SSL) port is 993. A SSL channel has to be established first. It is expecting SSL hand shake. That is why your telnet to imaps failed.

Mutt

mutt -f imap://{hostname}.{TLD}

Test imap authentication, username, password with plain imap 1st. That let you know if the account is actually working or not.

mutt -f imaps://{hostname}.{TLD}

If imaps is setup properly with self-signed certificate, mutt will ask for certificate confirmation. You will have to option to reject, accept once or accept always.

Thunderbird

To test IMAPS, use Thunderbird with manual config. If your dns is not fully setup, enter IP address of your imap server, pick IMAPS and port 993. When checking imaps email, it should pop up a window for accepting the self signed ssl cert.

share|improve this answer
    
It still fails. And I also need imaps and not imap. –  Akke Jan 1 '13 at 23:30
    
It is very very difficult to test imaps with telnet, if not impossible. I will check mutt in an hour. –  John Siu Jan 1 '13 at 23:34
    
I'll be waiting here for you then, thank you :) –  Akke Jan 1 '13 at 23:38
1  
Those lines will show up before you accept the cert. in thunderbird. Close Thunderbird, open again, click inbox, the cert. windows should pop up (or pop under). –  John Siu Jan 2 '13 at 1:28
1  
You welcome :) Happy 2013!! –  John Siu Jan 2 '13 at 1:34

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.