General Issues with Gateways Registration

Hello all,

working with wildfire 3.1.1 and this new IM-plugin (until last beta version), I have noticed about some issues during the registration process. I have also readed many questions of other peope in this community about the registration process.

· First of all, many people talk about they can’'t recognize error responses. In a client application, we need to alert a user about three errors:

  1. a username/password have a wrong format.

  2. username/password are not valid and you can’'t authenticate.

  3. Server loses connection or can not connect with remote service.

First error should be notified to the client application in the registration “iq” stanza.

Second error can be detected when the client application receives an “unavailable” “presence” stanza where the sender is the gateway’'s jid (For example “msn.wildfire”).

Third error can be detected with an error stanza or error in stanza of “remote-connection-failed”.

Working with wildfire 3.1.1 and IM-gateway plugin I found the following:

  1. With first error I found the following: If I try to register an invalid formated username in MSN (for example without the domain part), I receive two responses to the registration “iq” stanza, the first one notifies that registration has been successful, and the second that an error has happened in the registration process. I didn’‘t found anything in XMPP Core specification ( that says that an “iq” stanza can have two responses with the same stanza identifier. I also didn’'t found anything like that in “In-Band Registration” specification ( I tried this kind of wrong registration with two XMPP clients (GAIM and PSI). They both, only recognize the first response, and discard the second one, so the user is not notified about any error. By all of the previous facts I think this is a bug in IM-gateways plug-in. Can anyone confirm my supposition?

I looked at the code, and I have located the where the two respones are sended, and I need to fix it, but I’‘m not sure If i’'m right or wrong.

  1. With second error I found the following: I have registered a valid formatted MSN account, but this account doesn’‘t exists (, passwordn doesn’‘t matter in this test (can be any). When I first log-in in the wildfire server, the server tries to open a MSN session, and because it cann’‘t doit (because of the wrong username), and return’‘s me an “unavailable” “presence” stanza. Until this step, everithing is rigth. If I try to send a “presence” stanza to the gateway to login again (described in gateway XEP, after 5 minutes nothing happens, and the wildfire server didn’'t send any error about the login request. The same thing happens if the MSN username is right but the password is wrong. Is this an IM-gateway plugin error or am I wrong with my supposition?

  2. With the third error the same thing happens. If I deny connection with MSN servers with my firewall, wildfire server didn’'t notify me about the connection lost. It only detects it in the first login to the wildfire server.

I know that this is a beta versión of IM-gateways, but, are those issues a bug or functionality that is not supported yet?

or if I am wrong, please, let me know and tell me in what am I wrong?

I need to fix it, so if I am right with my suppositions, let me know, and if my patch helps you, I’'ll send it to you.


I do not have a lot of time to type at the moment, but please do email me whatever patches you have. I will try to reply more thoroughly later.