0 votes
by (120 points)
edited

Hi all, i'm trying rebex library. When using ImapBrowser sample (or ImapConsoleClient) in Implicit Security mode, i can connect with almost all servers but one, thath respond ERROR 119 invalid user or password err 2 (NO). User and password are correct, as i can connect via web mail and mailbee libraries too. Any suggestion, plz? Thx Diego

Applies to: Rebex Secure Mail
by (148k points)
Please check out http://www.rebex.net/kb/logging.aspx, add logging capabilities to one of the samples and produce a log showing this error. Then mail the log to us (support@rebex.net) or edit your question to include it. We should be able to tell more then.
by (148k points)
Explicitly specifying an authentication method in the Imap.Login call might help - it is possible that default one doesn't work on this server and using a different method might be a usable workaround.
by (148k points)
Is there any news on this? Have you been able to solve this or produce the communication log?
by (120 points)
Thx, we have purchased source, and debugging at login function, we found that in standard sequence, the library (imap.cs line 2534) execute first the line if (Array.IndexOf(_authTypes, ImapAuthentication.CramMD5, 0, _authTypes.Length) >= 0){ LoginInternal(userName, password, ImapAuthentication.CramMD5, null); return; and in log we read: Response: R00002 NO ERROR 119 invalid user or password err 2 but if we move ahead the line if (Array.IndexOf(_authTypes, ImapAuthentication.ClearText, 0, _authTypes.Length) >= 0) the login is OK. Is it a Server issue? Thx Diego

1 Answer

0 votes
by (148k points)

Based on the latest comment, I would say it's indeed a server issue. The server announces support for CRAM-MD5 authentication method, but when the client actually tries using it, it fails. The server should be either fixed or configured not to announce CRAM-MD5 support.

Rebex IMAP prefers CRAM-MD5 to ClearText because it's slightly more secure. To work around this issue, you don't need to modify any source code, just call the following variant of the Login method to force ClearText authentication:

imap.Login(userName, password, ImapAuthentication.ClearText);
...