Revert "Code looks for an auth element below the returned streams:feature"
authorFrank Zschockelt <lm@freakysoft.de>
Tue, 13 Apr 2010 23:21:01 +0200
changeset 619 a3facd81de25
parent 618 21918b7512b9
child 620 2e344ed4140b
Revert "Code looks for an auth element below the returned streams:feature" This reverts commit b94583bb7db80803c48add517a5559d45b6f3a58. Do not try to hack around bugs of the server...
loudmouth/lm-connection.c
--- a/loudmouth/lm-connection.c	Sat Mar 20 09:44:29 2010 +0100
+++ b/loudmouth/lm-connection.c	Tue Apr 13 23:21:01 2010 +0200
@@ -1085,6 +1085,7 @@
 {
     LmMessageNode *bind_node;
     LmMessageNode *starttls_node;
+    LmMessageNode *old_auth;
     LmMessageNode *sasl_mechanisms;
 
     starttls_node = lm_message_node_find_child (message->node, "starttls");
@@ -1156,8 +1157,10 @@
         }
     }
 
+    old_auth = lm_message_node_find_child (message->node, "auth");
+
     sasl_mechanisms = lm_message_node_find_child (message->node, "mechanisms");
-    if (connection->use_sasl && sasl_mechanisms == NULL) {
+    if (connection->use_sasl && old_auth != NULL && sasl_mechanisms == NULL) {
         g_log (LM_LOG_DOMAIN, LM_LOG_LEVEL_SASL,
                "Server uses XEP-0078 (jabber iq auth) instead of SASL\n");
         /* So the server is XMPP1.0, but doesn't support SASL and uses