summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorNathan Walp <nwalp@pidgin.im>2007-05-11 00:36:25 +0000
committerNathan Walp <nwalp@pidgin.im>2007-05-11 00:36:25 +0000
commit1a64c15f6639c47019359d2326eeb53f3c994c9f (patch)
tree05c2f3d7cc176de1f4763a7797a36d6ac8f83e4a
parent2ad70ec91fa6eb3a1c7a3784e634918d032a8f2f (diff)
parent8ca23a86814957aa3e4361a3dcf53d69a281dda0 (diff)
downloadpidgin-1a64c15f6639c47019359d2326eeb53f3c994c9f.tar.gz
merge of 'bc1afb8032d045cc066e44cfeb50cb3e18c19093'
and '3d500bca56224a1c1ce4d41fdb88ba8c2fc18d32'
-rw-r--r--ChangeLog4
-rw-r--r--libpurple/protocols/jabber/auth.c10
-rw-r--r--libpurple/protocols/jabber/buddy.c2
-rw-r--r--libpurple/protocols/jabber/jabber.c14
-rw-r--r--libpurple/protocols/jabber/presence.c2
5 files changed, 21 insertions, 11 deletions
diff --git a/ChangeLog b/ChangeLog
index eb925bbb39..176acf0045 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -20,6 +20,10 @@ version 2.0.1 (??/??/????):
messages
* Fix the typing animation so it doesn't stop animating once a conversation
has gone from typing -> not typing -> typing
+ * Fix error messages when joing XMPP chats
+ * Identify the account when warning about plaintext auth over an
+ unencrypted channel
+ * Fix XMPP SASL authentication error when using Cyrus and a connect server
Finch:
* Userlist in chat windows, which can be turned on or off using
diff --git a/libpurple/protocols/jabber/auth.c b/libpurple/protocols/jabber/auth.c
index 1d00d0d9eb..4e78bf92c4 100644
--- a/libpurple/protocols/jabber/auth.c
+++ b/libpurple/protocols/jabber/auth.c
@@ -291,12 +291,15 @@ static void jabber_auth_start_cyrus(JabberStream *js)
* plaintext auth
*/
} else if (!plaintext) {
+ char *msg = g_strdup_printf(_("%s requires plaintext authentication over an unencrypted connection. Allow this and continue authentication?"),
+ js->gc->account->username);
purple_request_yes_no(js->gc, _("Plaintext Authentication"),
_("Plaintext Authentication"),
- _("This server requires plaintext authentication over an unencrypted connection. Allow this and continue authentication?"),
+ msg,
2, js->gc->account, NULL, NULL, NULL,
allow_cyrus_plaintext_auth,
disallow_plaintext_auth);
+ g_free(msg);
return;
/* Everything else has failed, so fail the
* connection. Should probably have a better
@@ -477,13 +480,16 @@ jabber_auth_start(JabberStream *js, xmlnode *packet)
js->auth_type = JABBER_AUTH_PLAIN;
if(js->gsc == NULL && !purple_account_get_bool(js->gc->account, "auth_plain_in_clear", FALSE)) {
+ char *msg = g_strdup_printf(_("%s requires plaintext authentication over an unencrypted connection. Allow this and continue authentication?"),
+ js->gc->account->username);
purple_request_yes_no(js->gc, _("Plaintext Authentication"),
_("Plaintext Authentication"),
- _("This server requires plaintext authentication over an unencrypted connection. Allow this and continue authentication?"),
+ msg,
2,
purple_connection_get_account(js->gc), NULL, NULL,
purple_connection_get_account(js->gc), allow_plaintext_auth,
disallow_plaintext_auth);
+ g_free(msg);
return;
}
finish_plaintext_authentication(js);
diff --git a/libpurple/protocols/jabber/buddy.c b/libpurple/protocols/jabber/buddy.c
index 709aec0897..109c6d1016 100644
--- a/libpurple/protocols/jabber/buddy.c
+++ b/libpurple/protocols/jabber/buddy.c
@@ -1195,7 +1195,7 @@ static void jabber_buddy_get_info_for_jid(JabberStream *js, const char *jid)
/* this is to fix the feeling of irritation I get when trying
* to get info on a friend running Trillian, which doesn't
- * respont (with an error or otherwise) to jabber:iq:last
+ * respond (with an error or otherwise) to jabber:iq:last
* requests. There are a number of Trillian users in my
* office. */
if(!_client_is_blacklisted(jbr, "jabber:iq:last")) {
diff --git a/libpurple/protocols/jabber/jabber.c b/libpurple/protocols/jabber/jabber.c
index 91022e7a90..db4a338a35 100644
--- a/libpurple/protocols/jabber/jabber.c
+++ b/libpurple/protocols/jabber/jabber.c
@@ -508,13 +508,13 @@ static void tls_init(JabberStream *js)
jabber_login_callback_ssl, jabber_ssl_connect_failure, js->gc);
}
-static void jabber_login_connect(JabberStream *js, const char *server, int port)
+static void jabber_login_connect(JabberStream *js, const char *fqdn, const char *host, int port)
{
#ifdef HAVE_CYRUS_SASL
- js->serverFQDN = g_strdup(server);
+ js->serverFQDN = g_strdup(fqdn);
#endif
- if (purple_proxy_connect(js->gc, js->gc->account, server,
+ if (purple_proxy_connect(js->gc, js->gc->account, host,
port, jabber_login_callback, js->gc) == NULL)
purple_connection_error(js->gc, _("Unable to create socket"));
}
@@ -527,10 +527,10 @@ static void srv_resolved_cb(PurpleSrvResponse *resp, int results, gpointer data)
js->srv_query_data = NULL;
if(results) {
- jabber_login_connect(js, resp->hostname, resp->port);
+ jabber_login_connect(js, resp->hostname, resp->hostname, resp->port);
g_free(resp);
} else {
- jabber_login_connect(js, js->user->domain,
+ jabber_login_connect(js, js->user->domain, js->user->domain,
purple_account_get_int(js->gc->account, "port", 5222));
}
}
@@ -604,7 +604,7 @@ jabber_login(PurpleAccount *account)
* invoke the magic of SRV lookups, to figure out host and port */
if(!js->gsc) {
if(connect_server[0]) {
- jabber_login_connect(js, connect_server, purple_account_get_int(account, "port", 5222));
+ jabber_login_connect(js, js->user->domain, connect_server, purple_account_get_int(account, "port", 5222));
} else {
js->srv_query_data = purple_srv_resolve("xmpp-client",
"tcp", js->user->domain, srv_resolved_cb, js);
@@ -949,7 +949,7 @@ void jabber_register_account(PurpleAccount *account)
if(!js->gsc) {
if (connect_server[0]) {
- jabber_login_connect(js, server,
+ jabber_login_connect(js, js->user->domain, server,
purple_account_get_int(account,
"port", 5222));
} else {
diff --git a/libpurple/protocols/jabber/presence.c b/libpurple/protocols/jabber/presence.c
index 849ac311ce..bb36a8666c 100644
--- a/libpurple/protocols/jabber/presence.c
+++ b/libpurple/protocols/jabber/presence.c
@@ -391,7 +391,7 @@ void jabber_presence_parse(JabberStream *js, xmlnode *packet)
static int i = 1;
char *room_jid = g_strdup_printf("%s@%s", jid->node, jid->domain);
- if(state == JABBER_BUDDY_STATE_ERROR && jid->resource == NULL) {
+ if(state == JABBER_BUDDY_STATE_ERROR) {
char *title, *msg = jabber_parse_error(js, packet);
if(chat->conv) {