[Pidgin] #16757: Fix jabber password dialog infinite loop with SASL

Pidgin trac at pidgin.im
Thu Sep 3 09:55:03 EDT 2015


#16757: Fix jabber password dialog infinite loop with SASL
---------------------+---------------------------------------------------
 Reporter:  haakon   |      Owner:  deryni
     Type:  patch    |     Status:  new
Milestone:           |  Component:  XMPP
  Version:  3.0.0hg  |   Keywords:  jabber xmpp sasl password dialog loop
---------------------+---------------------------------------------------
 When connecting a Jabber account that doesn't have any stored password,
 Pidgin compiled with --enable-cyrus-sasl went into an infinite loop of
 dialogs requesting user to enter the password.

 This was happening because jabber_auth_start_cyrus() was calling
 purple_connection_get_password() in order to check if the connection has
 some password stored and when the returned value was NULL, it fired
 purple_account_request_password(), let the user enter the password and
 called itself again in a loop.

 However, password once set (or left NULL) on PurpleConnection construction
 can't be changed and auth_pass_cb() called by
 purple_account_request_password() is storing the password into
 PurpleAccount (purple_account_set_password()), not the connection.
 Consequently, when jabber_auth_start_cyrus() got fired again, it still
 read the old NULL value from purple_connection_get_password() and thus
 kept popping up the password dialog over and over again.

 As a fix, the SASL password is now kept in JabberStream structure. It is
 initialized once by purple_connection_get_password() and auth_pass_cb()
 updates both PurpleAccount password and the JabberStream value.

--
Ticket URL: <https://developer.pidgin.im/ticket/16757>
Pidgin <https://pidgin.im>
Pidgin


More information about the Tracker mailing list