pidgin: 8f2d6c51: jabber: Properly parse realm="" in DIGES...
darkrain42 at pidgin.im
darkrain42 at pidgin.im
Wed Feb 2 00:55:47 EST 2011
----------------------------------------------------------------------
Revision: 8f2d6c5138602b96aef4fbfbc5b47c202951201b
Parent: 1a66fe9f8b86d69adad25c8f61b8fcbad648a8bf
Author: darkrain42 at pidgin.im
Date: 02/02/11 00:51:09
Branch: im.pidgin.pidgin
URL: http://d.pidgin.im/viewmtn/revision/info/8f2d6c5138602b96aef4fbfbc5b47c202951201b
Changelog:
jabber: Properly parse realm="" in DIGEST-MD5, which is apparently valid.
On a marginally related note, the ABNF in this RFC is really ugly.
Refs #a14514.
Changes against parent 1a66fe9f8b86d69adad25c8f61b8fcbad648a8bf
patched ChangeLog
patched libpurple/protocols/jabber/auth_digest_md5.c
-------------- next part --------------
============================================================
--- ChangeLog 3097905b3e4f824fa13be5aad738c075c424d8de
+++ ChangeLog e9fb89eede65b46eac2452f9f4b6fd80102621d2
@@ -58,6 +58,8 @@ version 2.7.10 (??/??/????):
(Nikita Kozlov) (#13136)
* Handle Connection: Close headers for BOSH, when the server does not
terminate the connection itself. (#13008)
+ * Improved parsing for DIGEST-MD5, which should resolve issues
+ connecting to some jabberd2 servers. (#a14514)
Yahoo!/Yahoo! JAPAN:
* Fix a crash when an account disconnects before a p2p session is
============================================================
--- libpurple/protocols/jabber/auth_digest_md5.c b191c64248fdc92be9eb9994f3c93d9e1fef042a
+++ libpurple/protocols/jabber/auth_digest_md5.c 180fca893988900aaa6bf35dc126a508fdd61318
@@ -78,12 +78,12 @@ GHashTable* jabber_auth_digest_md5_parse
val_start++;
val_end = cur;
- while (val_end != val_start && (*val_end == ' ' || *val_end == ',' || *val_end == '\t'
+ while (val_end >= val_start && (*val_end == ' ' || *val_end == ',' || *val_end == '\t'
|| *val_end == '\r' || *val_end == '\n'
|| *val_end == '"' || *val_end == '\0'))
val_end--;
- if (val_start != val_end)
+ if (val_end - val_start + 1 >= 0)
value = g_strndup(val_start, val_end - val_start + 1);
}
More information about the Commits
mailing list