[PyXMPP] Registering new users
berco at media2b.net
Sat Feb 3 18:31:25 CET 2007
On 2/3/07, Jacek Konieczny <jajcus at jajcus.net> wrote:
> On Fri, Feb 02, 2007 at 04:37:37PM +0100, cyberco wrote:
> > I want to register new users on a xmpp server using pyxmpp, but is that
> > supported?
> You mean registering using PyXMPP, or server using PyXMPP? I don't think
> the latter would work (server support of PyXMPP is very poor).
I mean registering using PyXMPP.
> > Using the server from pyxmpp's exampe directory as follows:
> Server from pyxmpp example directory?
> > stream = Stream('jabber:client')
> Do not use Stream classes directly.
> > I am totally new to pyxmpp, so I'm not sure whether this means
> > using pyxmpp is not supported, or that the server doesn't support it.
> Recent PyXMPP code supports basic registration for clients. You will
> probably need
> the PyXMPP from SVN or current snapshot for that.
To register a new account use connect() method of JabberClient class
> with the "register" (first and only) argument set to True.
I have the most recent snapshot (20070106), but the connect method is an
instance method, so you first have to create a JabberClient instance, but
that in turn requires a JID.
Override process_registration_form() method to handle the registration
> form and enter the required data. The default implementation will just
> pass username and password (as they would be used for authentication) in
> the registration form.
OK, I'll grab the SVN and try that. Thanks for the great help.
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the PyXMPP