aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMatthias Andree <matthias.andree@gmx.de>2009-06-30 08:58:48 +0000
committerMatthias Andree <matthias.andree@gmx.de>2009-06-30 08:58:48 +0000
commit9f4d447990cd59a9e40b9783eddee0987b4cc826 (patch)
tree89c9fea115d9b7f935aa50d956461c46e641b882
parent8b4467e26bbd06808be0855ba2d40fcb4427628f (diff)
downloadfetchmail-9f4d447990cd59a9e40b9783eddee0987b4cc826.tar.gz
fetchmail-9f4d447990cd59a9e40b9783eddee0987b4cc826.tar.bz2
fetchmail-9f4d447990cd59a9e40b9783eddee0987b4cc826.zip
Preliminary Yahoo/Zimbra IMAP ID ("guid" "1") support. Not ready for prime-time.
svn path=/branches/BRANCH_6-3/; revision=5363
-rw-r--r--NEWS5
-rw-r--r--imap.c9
2 files changed, 14 insertions, 0 deletions
diff --git a/NEWS b/NEWS
index a8f1629c..c09e801c 100644
--- a/NEWS
+++ b/NEWS
@@ -111,6 +111,11 @@ fetchmail 6.3.10 (not yet released):
* fetchmail only requests IPv6 addresses via name service if at least one is
configured on the local host, likewise for IPv4. (AI_ADDRCONFIG flag to
getaddrinfo()) Extended version of Redhat's patch.
+* If the server name contains "yahoo.com", offers the "ID" capability, and we're
+ polling via IMAP, send an ID ("guid" "1") transaction first, ignoring its
+ result. This appears needed to be able to log into Yahoo's Zimbra servers, but
+ there are open issues (such as being only able to download one message and
+ server certificate mismatches).
# CHANGES TO CONTRIB
* Fix bashism in contrib/fetchsetup. Fixes Debian Bug#530081.
diff --git a/imap.c b/imap.c
index 53474924..54309f7d 100644
--- a/imap.c
+++ b/imap.c
@@ -478,6 +478,15 @@ static int imap_getauth(int sock, struct query *ctl, char *greeting)
*/
ok = PS_AUTHFAIL;
+ /* Yahoo hack - we'll just try ID if it was offered by the server,
+ * and IGNORE errors. */
+ {
+ char *tmp = strstr(capabilities, " ID");
+ if (tmp && !isalnum(tmp[3]) && strstr(ctl->server.via ? ctl->server.via : ctl->server.pollname, "yahoo.com")) {
+ (void)gen_transact(sock, "ID (\"guid\" \"1\")");
+ }
+ }
+
if ((ctl->server.authenticate == A_ANY
|| ctl->server.authenticate == A_EXTERNAL)
&& strstr(capabilities, "AUTH=EXTERNAL"))