[jdev] Re: XEP-0070 in PHP

Magnus Henoch mange at freemail.hu
Sun Oct 29 15:38:42 CST 2006

"Norman Rasmussen" <norman at rasmussen.co.za> writes:

> Wierd I've just been fighting with LiveJournal to implement their
> OpenID correctly - which got me into thinking how are OpenID and XMPP
> going to co-exist.
> Then I realised that it should be possible to build an OpenID server that
> should be able to use XEP-0070 as a backend.
> So your process flow would be:
> - Enter your webpage's address as your OpenID on a website that
> allows OpenID for auth,
> - WebSite reads your webpage, and determines OpenID server address,
> - The OpenID server sends a XEP-0070 request to your XMPP client,
> - You auth the request with your client,
> - and log in to the website using your OpenID!
> And the OpenID server doesn't really even need any backend storage.

Yes, I started looking at OpenID, thinking about implementing it in
Erlang for ejabberd, but I realized that all the cryptography needed
was way over my head... maybe an external component could be used,

> On 10/28/06, Magnus Henoch <mange at freemail.hu> wrote:
>> In theory, acting as a client should mean that responses are
>> automagically sent to the correct web server thread, as the user would
>> reply to the same full JID which sent the original stanza.  In
>> practice, some clients (e.g. Gajim) reply to the bare JID.  As my
>> script doesn't send any presence, it won't get such messages...
> Psi doesn't like the comma in the resource name (I think it allows
> multiple recipients seperated with a comma).  You could use date('c')
> or date('U') instead,


> or why not login with SASL plain and allow the server to generate a
> random resource instead.
> Or better yet, why not login with SASL Anonymous, that way even Gajim
> will work :-)

Yes, I would do that if class.jabber.php supported SASL ;)

> What do you think about using type='chat'?  The XEP doesn't dictate
> which message type is used, and I think chat is kinder on the eyes.

I changed that too.

JID: legoscia at jabber.cd.chalmers.se

More information about the JDev mailing list