aboutsummaryrefslogtreecommitdiffstats
path: root/protocols/jabber/io.c
diff options
context:
space:
mode:
authorWilmer van der Gaast <wilmer@gaast.net>2006-10-01 11:40:55 +0200
committerWilmer van der Gaast <wilmer@gaast.net>2006-10-01 11:40:55 +0200
commit0e2d97f6b3bcffd5637eafa9a687e42a7c134f57 (patch)
treeaba6bea70836ee1bd422d9a7df3103b80a6a73b4 /protocols/jabber/io.c
parent6baca2a2910d0b6663b54ef302820d9ffbbf5eee (diff)
Can now log in to the jabber.com server (which pretends to support XMPP 1.0
but does NOT (seem to) support SASL authentication).
Diffstat (limited to 'protocols/jabber/io.c')
-rw-r--r--protocols/jabber/io.c12
1 files changed, 12 insertions, 0 deletions
diff --git a/protocols/jabber/io.c b/protocols/jabber/io.c
index f62e059a..3dbc6faa 100644
--- a/protocols/jabber/io.c
+++ b/protocols/jabber/io.c
@@ -300,8 +300,20 @@ static xt_status jabber_pkt_features( struct xt_node *node, gpointer data )
from here to make sure the TLS session will be initialized
properly before we attempt SASL authentication. */
if( ( c = xt_find_node( node->children, "mechanisms" ) ) )
+ {
if( sasl_pkt_mechanisms( c, data ) == XT_ABORT )
return XT_ABORT;
+ }
+ else
+ {
+ /* If the server *SEEMS* to support SASL authentication but
+ doesn't support it after all, we should try to do
+ authentication the other way. jabber.com doesn't seem to
+ do SASL while it pretends to be XMPP 1.0 compliant! */
+ if( sasl_supported( gc ) )
+ if( !jabber_start_iq_auth( gc ) )
+ return XT_ABORT;
+ }
if( ( c = xt_find_node( node->children, "bind" ) ) )
{