mirror of https://github.com/moparisthebest/k-9
Hopeful (but untested code) to get updated capabilities after
successful CRAM-MD5 authentication.
This commit is contained in:
parent
f6e7d5d4c0
commit
97c7bf1d65
|
@ -1951,6 +1951,16 @@ public class ImapStore extends Store
|
||||||
if (mAuthType == AuthType.CRAM_MD5)
|
if (mAuthType == AuthType.CRAM_MD5)
|
||||||
{
|
{
|
||||||
authCramMD5();
|
authCramMD5();
|
||||||
|
// The authCramMD5 method on the previous line does not allow for handling updated capabilities
|
||||||
|
// sent by the server. So, to make sure we update to the post-authentication capability list
|
||||||
|
// we fetch the capabilities here.
|
||||||
|
Log.i(K9.LOG_TAG, "Updating capabilities after CRAM-MD5 authentication for " + getLogId());
|
||||||
|
List<ImapResponse> responses = receiveCapabilities(executeSimpleCommand(COMMAND_CAPABILITY));
|
||||||
|
if (responses.size() != 2)
|
||||||
|
{
|
||||||
|
throw new MessagingException("Invalid CAPABILITY response received");
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
else if (mAuthType == AuthType.PLAIN)
|
else if (mAuthType == AuthType.PLAIN)
|
||||||
{
|
{
|
||||||
|
|
Loading…
Reference in New Issue