Mercurial > pidgin
changeset 30449:ec12d2883266
jabber: Make the reliance on stream ID laxer. Closes #12331
The requirement that there be an ID on the responder's header was
underspecified/just a SHOULD (depending on how you read it)
in rfc3920.
author | Paul Aurich <paul@darkrain42.org> |
---|---|
date | Fri, 27 Aug 2010 05:14:08 +0000 |
parents | a5131a257967 |
children | 014dbe36b722 |
files | ChangeLog libpurple/protocols/jabber/parser.c |
diffstat | 2 files changed, 15 insertions(+), 1 deletions(-) [+] |
line wrap: on
line diff
--- a/ChangeLog Fri Aug 27 04:30:23 2010 +0000 +++ b/ChangeLog Fri Aug 27 05:14:08 2010 +0000 @@ -16,6 +16,8 @@ * Fix a crash when multiple accounts are simultaneously performing SASL authentication when built with Cyrus SASL support. (thanks to Jan Kaluza) (#11560) + * Restore the ability to connect to XMPP servers that do not offer + Stream ID. (#12331) Yahoo/Yahoo JAPAN: * Stop doing unnecessary lookups of certain alias information. This
--- a/libpurple/protocols/jabber/parser.c Fri Aug 27 04:30:23 2010 +0000 +++ b/libpurple/protocols/jabber/parser.c Fri Aug 27 05:14:08 2010 +0000 @@ -93,10 +93,22 @@ } } - if (js->stream_id == NULL) + if (js->stream_id == NULL) { +#if 0 + /* This was underspecified in rfc3920 as only being a SHOULD, so + * we cannot rely on it. See #12331 and Oracle's server. + */ purple_connection_error_reason(js->gc, PURPLE_CONNECTION_ERROR_AUTHENTICATION_IMPOSSIBLE, _("XMPP stream missing ID")); +#else + /* Instead, let's make up a fancy-schmancy stream ID, which + * we need to do because we flag on js->stream_id == NULL being + * a special case in this function. + */ + js->stream_id = purple_uuid_random(); +#endif + } } else { if(js->current)