Having gotten OpenID delegation going I had to go and play some more.. 🙂
Now I was a bit puzzled about the
OpenID XRDS Url mentioned in Eran’s plugin, I don’t see if being created at WordPress.com and the thought of just putting a URL in there and hoping is a bit, well, unsatisfying. Now that isn’t Evan’s fault, it’s just the fact that the WordPress service isn’t that well documented for delegation and I was hoping for something that would go a little bit further.
Before I found Evan’s OpenID Delegation plugin I came across Will Norris’s WP-Yadis plugin (originally wp-xrds) but it didn’t really work under PHP5 and so I had quickly skipped over it. Having found myself not quite happy with the outcome of using Evan’s (again, not his fault) I decided to go back and see if I could fix up the PHP4 code that wasn’t happy with PHP5.
Now it turns out it wasn’t that hard to fix, just 3 instances of foreach() where a variable needed casting to Array. That let me put in the
OpenID Server Url and
OpenID Delegate Server Url that I had been using previously and magically created a XRDS (aka Yadis) document. Brilliant I thought.
But wp-yadis could do more, it already had a set of definitions for a number of providers so that you could just pick the one you wanted and give it your username and let it automatically generate the URLs, but there wasn’t anything for WordPress. A bit more hacking later (to add a substitution to the server URL that was previously only happening on the delegation URL) and it was working!
I’ve sent Will the patch by email, but as the licensing isn’t clear I can’t really make it available here without Will’s approval.