Fixes to allow in-band registration.
With the current implementation of SASL authentication, in-band registration (XEP-0077) will fail if it doesn't finish before the client is rejected.
This patch does the following:
- A new 'SKIP' SASL mechanism is added, that simply does not send any credential. Registration plugin requests it when enabled.
- Authentication processing blocks until it is finished, so registration does not race with it.
- Registration stanza processing is moved after authentication, so the registration handler knows whether the authentication failed.
There are 2 ways of using the registration plugin:
- Authentication is performed first, and if it fails, registration is attempted. This is the default.
- Authentication is not performed, registration is attempted on the anonymous stream. To use it, add