cpw.darkrain42.xmpp.scram: 9796b72f: jabber: Interop with Prosody (via Tobias...
darkrain42 at pidgin.im
darkrain42 at pidgin.im
Tue Nov 17 16:41:36 EST 2009
-----------------------------------------------------------------
Revision: 9796b72fa5337bb6633b04a951900135c323a2e8
Ancestor: d5600ec1009b66055f8b23a2c25c4af71cd8c033
Author: darkrain42 at pidgin.im
Date: 2009-11-17T21:37:14
Branch: im.pidgin.cpw.darkrain42.xmpp.scram
URL: http://d.pidgin.im/viewmtn/revision/info/9796b72fa5337bb6633b04a951900135c323a2e8
Modified files:
libpurple/protocols/jabber/auth_scram.c
ChangeLog:
jabber: Interop with Prosody (via Tobias' code). Hooray!
-------------- next part --------------
============================================================
--- libpurple/protocols/jabber/auth_scram.c 12f4ddd5958431737a7194095d733c085b2f6628
+++ libpurple/protocols/jabber/auth_scram.c 1980c9ed827e25c56fcff1641a375393ae10175d
@@ -32,7 +32,7 @@ static const struct {
const char *mech_substr;
const char *hash;
} mech_hashes[] = {
- { "-SHA-1-", "sha1" },
+ { "-SHA-1", "sha1" },
};
static const struct {
@@ -53,6 +53,8 @@ static const gchar *mech_to_hash(const c
return mech_hashes[i].hash;
}
+ purple_debug_error("jabber", "Unknown SCRAM mechanism %s\n", mech);
+
return NULL;
}
@@ -375,7 +377,7 @@ static xmlnode *scram_start(JabberStream
data->channel_binding = TRUE;
#endif
cnonce = ((guint64)g_random_int() << 32) | g_random_int();
- data->cnonce = purple_base64_encode((guchar *)cnonce, sizeof(cnonce));
+ data->cnonce = purple_base64_encode((guchar *)&cnonce, sizeof(cnonce));
data->auth_message = g_string_new(NULL);
g_string_printf(data->auth_message, "n=%s,r=%s",
More information about the Commits
mailing list