# HG changeset patch # User Nathan Walp # Date 1069743404 0 # Node ID 2df4d470c12a592d6ae46f8d39a354d6a1ffb18f # Parent 778624d3fced25eb4d775d87142416a789d5718b [gaim-migrate @ 8254] i heart jabber committer: Tailor Script diff -r 778624d3fced -r 2df4d470c12a src/protocols/jabber/.todo --- a/src/protocols/jabber/.todo Tue Nov 25 05:26:17 2003 +0000 +++ b/src/protocols/jabber/.todo Tue Nov 25 06:56:44 2003 +0000 @@ -3,39 +3,21 @@ problem seeing buddies with long blist? - - make password change take effect w/out restart - - - some way to figure out which resource you are talking to - Browsing - - Bug: Opening/closing/reopening conferences (to the same "room"?) and changing conf. room nicks results in wrong nick reappearing (to other clients) and crash on close of conference dialog. - Server Admin operations (messages, etc.) Add option for user info to be published or not in JUD. - - Ability to "IM" conference room "buddies" - - - Some way to see/list roster items to which you have no subscription yourself? Some way to delete them or subscribe to them if you want? - Show self on buddylist Delete server account. - - Messaging an "Away" Jabber user doesn't get an away message back? - Permit/Deny buddy support. @@ -45,15 +27,6 @@ a populate roster from local blist. most useful if you want to migrate a blist from one account to another, also useful if something freaky happens and the server blist is lost. - - conferencing needs straightening out in general - - some s2s issues, maybe - - - join room 2x issues, maybe - - info @@ -63,12 +36,6 @@ have set info pre-fill values from the server when no local vcard exists. this will help people migrating to gaim - - SSL support (priority 4 because its not really doable right now) - - faceprint added this - - *sigh* file transfer (do we really need/want this?) diff -r 778624d3fced -r 2df4d470c12a src/protocols/jabber/JEPS --- a/src/protocols/jabber/JEPS Tue Nov 25 05:26:17 2003 +0000 +++ b/src/protocols/jabber/JEPS Tue Nov 25 06:56:44 2003 +0000 @@ -1,54 +1,30 @@ 0004: NEED Data Gathering and Reporting -0012: DONE - Last Activity -0018: DONE (Is it?) - Presence (Invisible) -0022: DONE (replace?) - Message Events -0030: DONE - Service Discovery -0045: DONE +0045: IN PROGRESS Multi-User Chat -0047: DONE +0047: IN PROGRESS In-Band Bytestreams -0054: DONE (ugly) - vCard 0060: NEED Pub-Sub -0065: DONE +0065: IN PROGRESS SOCKS5 Bytestreams -0071: DONE (needs spec confirmation) +0071: AWAITING FINAL SPEC XHTML-IM 0073: NEED Basic IM Protocol Suite -0077: DONE - In-Band Registration -0078: DONE - Non-SASL Authentication 0080: NEED (Do we?) Geographic Location Information -0082: DONE - Jabber Date and Time Profiles 0084: NEED User Avatars in Jabber 0085: NEED Chat State Notifications -0086: DONE - Legacy Errors 0089: WATCH Generic Alerts -0090: DONE - Entity Time -0091: DONE - Delayed Delivery -0092: DONE - Software Version 0093: NEED Roster Item Exchange -0095: DONE +0095: IN PROGRESS Stream Initiation -0096: DONE +0096: IN PROGRESS File Transfer Stream Initiation Profile 0100: NEED Gateway Interaction (Transports) diff -r 778624d3fced -r 2df4d470c12a src/protocols/jabber/auth.c --- a/src/protocols/jabber/auth.c Tue Nov 25 05:26:17 2003 +0000 +++ b/src/protocols/jabber/auth.c Tue Nov 25 06:56:44 2003 +0000 @@ -43,7 +43,8 @@ gboolean digest_md5 = FALSE, plain=FALSE; if((starttls = xmlnode_get_child(packet, "starttls"))) { - if(gaim_ssl_is_supported()) { + if(gaim_account_get_bool(js->gc->account, "use_tls", TRUE) && + gaim_ssl_is_supported()) { jabber_send_raw(js, ""); return; diff -r 778624d3fced -r 2df4d470c12a src/protocols/jabber/jabber.c --- a/src/protocols/jabber/jabber.c Tue Nov 25 05:26:17 2003 +0000 +++ b/src/protocols/jabber/jabber.c Tue Nov 25 06:56:44 2003 +0000 @@ -20,17 +20,6 @@ */ #include "internal.h" -/* -#include "conversation.h" -#include "ft.h" -#include "multi.h" -#include "notify.h" -#include "proxy.h" -#include "request.h" -#include "util.h" - -*/ - #include "account.h" #include "accountopt.h" #include "debug.h" @@ -411,11 +400,15 @@ jabber_stream_set_state(js, JABBER_STREAM_CONNECTING); - if(gaim_account_get_bool(account, "old_ssl", FALSE) - && gaim_ssl_is_supported()) { - js->gsc = gaim_ssl_connect(account, server, - gaim_account_get_int(account, "port", 5222), - jabber_login_callback_ssl, jabber_ssl_connect_failure, gc); + + if(gaim_account_get_bool(account, "old_ssl", FALSE)) { + if(gaim_ssl_is_supported()) { + js->gsc = gaim_ssl_connect(account, server, + gaim_account_get_int(account, "port", 5222), + jabber_login_callback_ssl, jabber_ssl_connect_failure, gc); + } else { + gaim_connection_error(gc, _("SSL support unavailable")); + } } if(!js->gsc) { @@ -705,11 +698,14 @@ jabber_stream_set_state(js, JABBER_STREAM_CONNECTING); - if(gaim_account_get_bool(account, "old_ssl", FALSE) - && gaim_ssl_is_supported()) { - js->gsc = gaim_ssl_connect(account, server, - gaim_account_get_int(account, "port", 5222), - jabber_login_callback_ssl, NULL, gc); + if(gaim_account_get_bool(account, "old_ssl", FALSE)) { + if(gaim_ssl_is_supported()) { + js->gsc = gaim_ssl_connect(account, server, + gaim_account_get_int(account, "port", 5222), + jabber_login_callback_ssl, jabber_ssl_connect_failure, gc); + } else { + gaim_connection_error(gc, _("SSL support unavailable")); + } } if(!js->gsc) { @@ -1146,7 +1142,12 @@ split = gaim_account_user_split_new(_("Resource"), "Gaim", '/'); prpl_info.user_splits = g_list_append(prpl_info.user_splits, split); - option = gaim_account_option_bool_new(_("Force Old SSL"), "old_ssl", FALSE); + option = gaim_account_option_bool_new(_("Use TLS if available"), "use_tls", + TRUE); + prpl_info.protocol_options = g_list_append(prpl_info.protocol_options, + option); + + option = gaim_account_option_bool_new(_("Force old SSL"), "old_ssl", FALSE); prpl_info.protocol_options = g_list_append(prpl_info.protocol_options, option); diff -r 778624d3fced -r 2df4d470c12a src/protocols/jabber/message.c --- a/src/protocols/jabber/message.c Tue Nov 25 05:26:17 2003 +0000 +++ b/src/protocols/jabber/message.c Tue Nov 25 06:56:44 2003 +0000 @@ -182,9 +182,16 @@ gaim_conv_chat_set_topic(GAIM_CONV_CHAT(chat->conv), jid->resource, jm->subject); - if(jm->xhtml || jm->body) - serv_got_chat_in(jm->js->gc, chat->id, jid->resource, - 0, jm->xhtml ? jm->xhtml : jm->body, jm->sent); + if(jm->xhtml || jm->body) { + if(jid->resource) + serv_got_chat_in(jm->js->gc, chat->id, jid->resource, 0, + jm->xhtml ? jm->xhtml : jm->body, jm->sent); + else if(chat->muc) + gaim_conv_chat_write(GAIM_CONV_CHAT(chat->conv), "", + jm->xhtml ? jm->xhtml : jm->body, + GAIM_MESSAGE_SYSTEM, jm->sent); + } + jabber_id_free(jid); } diff -r 778624d3fced -r 2df4d470c12a src/protocols/jabber/presence.c --- a/src/protocols/jabber/presence.c Tue Nov 25 05:26:17 2003 +0000 +++ b/src/protocols/jabber/presence.c Tue Nov 25 06:56:44 2003 +0000 @@ -242,12 +242,17 @@ JabberIq *iq = jabber_iq_new_query(js, JABBER_IQ_SET, "http://jabber.org/protocol/muc#owner"); xmlnode *query = xmlnode_get_child(iq->node, "query"); + xmlnode *x = xmlnode_new_child(query, "x"); + char *room_jid = g_strdup_printf("%s@%s", jid->node, + jid->domain); - xmlnode *x = xmlnode_new_child(query, "x"); + xmlnode_set_attrib(iq->node, "to", room_jid); xmlnode_set_attrib(x, "xmlns", "jabber:x:data"); xmlnode_set_attrib(x, "type", "submit"); jabber_iq_send(iq); + + g_free(room_jid); } } }