Iris and iChat

Ok, so we can do this now:

That’s presence using Link-Local Messaging (a.k.a. Apple’s Bonjour Chat protocol, now documented in JEP-0174). Presence is delivered via local DNS Service Discovery. Chat is done via peer-to-peer Jabber.

Doing Bonjour presence is not all that new actually. The JDNS subsystem has been able to do it since last year. What is notable this time around is that I’m doing it via the new Iris DNS API, which is an abstraction layer, and JDNS is just one possible backend. And there’s also an avatar / buddy icon. That’s good old icon_32.png from Psi. :)

If you want to try it yourself, have a look at the irisnet command-line tool (now committed to the CVS). Quite a few rough edges remain, but it should work. Here is what I ran:

./irisnet pserv justin@ubuntu _presence._tcp 5298
"txtvers=1,1st=Justin,port.p2pj=5298,status=dnd,
msg=coding on iris stuff,
phsh=b12eebe7b5a2f2673aba2f6eb0f3264939a78f67"
-a null:icon_32.png

Yeah, it’s pretty long. :) It is supposed to be a single line, but I’ve broken it up for readability. “irisnet pserv” means to publish a service. Then it goes: JID, service type, port, list of attributes. The -a means to add an extra DNS record, in this case the avatar image (yeah, iChat delivers avatars over DNS, don’t ask questions).

The value of the phsh attribute is the SHA1 hash of the avatar image in hexidecimal. I used the ’sha1sum’ program to do this, which is present on most Linux installations at least:

$ sha1sum icon_32.png
b12eebe7b5a2f2673aba2f6eb0f3264939a78f67  icon_32.png

I don’t know when we’ll see Link-Local Messaging in Psi, but it shouldn’t be too hard to do at this point.

8 Comments »

  1. Adam said,

    February 9, 2007 @ 8:59 am

    The screenshot appears to be from Leapfrog. I’ve tried to dig up information about this client — I love Psi in general, but it just Does The Wrong Things under OS X. The roadmap from last April has a planned release on the short-term plan.

    Are you still working on Leapfrog, or has that work been abandoned? I’d love to have a native OS X Jabber client that doesn’t suck — and there simply isn’t one available yet.

  2. justin said,

    February 11, 2007 @ 11:51 am

    The screenshot above is iChat. I was just showing how the code I’m working on is compatible with iChat’s Bonjour feature.

    Leapfrog is still an active project, however my participation is currently in limbo. Portugal Telecom changed their policy about international employment (I’m in the USA), and we have yet to resolve this. The project continues on though, and you might see a release in the next few months. If you brush up on your Portuguese, you might keep an eye on http://messenger.sapo.pt/

  3. fabieuse said,

    March 4, 2007 @ 11:12 am

    Now that the Sapo Messenger for Mac is released, is there any chance to see a version of the client that connects to other (non Sapo) servers?

  4. justin said,

    March 4, 2007 @ 5:55 pm

    Try fiddling in the config files.

    The original plan was to have Leapfrog be a generic XMPP client, and managed like a typical open source project, with SAPO Messenger simply a branding that is applied to Leapfrog. I don’t know if that is still the plan. In any case, SAPO Messenger will be GPL, and the source should be available very soon if anyone wanted to make changes.

  5. fabieuse said,

    March 5, 2007 @ 2:13 am

    Strange: I registered for a SAPO account, but i can’t even connect to their server with the SAPO client. I always get a Connection Error. It works with other clients though, so i’m sure i didn’t make any misstakes on the trial-and-error registring procedure.

  6. fabieuse said,

    March 5, 2007 @ 12:40 pm

    is there a place where i can submit bugreports for the sapo/ leapfrog client rather than in this talkback? i am experiencing an odd bug with the client: in one of my two mac os user accounts i am not able to log in with the sapo client. the other one works fine. first i thought i have to have administrator rights to log in, but giving the account admin rights doesn’t help. what could that be?

  7. justin said,

    March 5, 2007 @ 12:57 pm

    This thread is definitely the wrong place for this discussion, since the post wasn’t even about Leapfrog in the first place. :)

    Please write to the Delta Mailing List. Info here: http://lists.affinix.com/listinfo.cgi/delta-affinix.com

  8. Pedro Melo said,

    May 11, 2007 @ 4:17 am

    Hi,

    just in case people land here looking for Leapfrog / SAPO MSG for Mac. The project is now open, go to http://trac.softwarelivre.sapo.pt/sapo_msg_mac/ for code and other docs.

    Best regards, and justin sorry for intruding :)

RSS feed for comments on this post · TrackBack URI

Leave a Comment

Bad Behavior has blocked 321 access attempts in the last 7 days.