Building simplicidade.org: notes, projects, and ocasional rants

Notes

last update:

CPAN::Mini::Webserver++

The CPAN::Mini::Webserver module is getting a lot of love in the last few weeks. The most recent 0.40 version includes a lot of goodies including: act as a true CPAN mirror so that you can point you cpan client to it;syntax highlight of Perl code;Bonjour registration: easy to find on a local lan;shows which modules are installed locally;A lot more meta information shown about each module.Getting everything right is easy.

HTML5 and event loops

Interesting stuff: HTML5 gained a event loop this week. I like event loops. I'm still reading the draft spec, but it seems very nice.

XMPP for carbon lovers

If you happen to be a dead-tree-addict, and interested in XMPP like me, then I'm happy to tell you that you will have a present next year. Kevin, Peter and Remko are hard at work for O'Reilly to brings us the XMPP missing book. Entitled "XMPP: The Definitive Guide", it should hit the shelfs in 2009. Shameless offer: if you need technical reviewers, you know my JID :).

Framing protocols

I've been playing with framing protocols. I need a protocol with: low overhead: it will be used for mobile communications and some of us pay for each byte;multiplex streams: you should be able to open channels inside the same TCP connection;restartable: each session has an ID and I need to restart all of the channels inside it very quickly if my TCP connection dies.I've looked at AMQP wire protocol, BLIP, BEEP and some others.

Parallax

I've talked a bit about Freebase over the last few months. I understand that a rich, semantic, structured database of knowledge is not something other people get excited about, but that happens to be my thing. In the hope to excite others with Freebase, I recommend that you spend 8 minutes watching the Parallax browser in action. That kind of research tool is only possible with something like Freebase on the bottom.

Updated Search In Project with Ack

I've updated my own Search In Project with ack TextMate command. Changes: search in selected files is optional now: start your query with a : to search only in the selected files;fixed search for words with a initial dash in them.You can find the current version at GitHub or download the tmCommand file directly. This is a very simple ack interface. For a more complex and feature-full, see the ack TextMate bundle by Trevor Squires.

I spent the last 30 minutes chasing down this bug. The following tests should all pass but the last one doesn't: use strict; use warnings; use Test::More 'no_plan'; use XML::LibXML; use XML::LibXML::XPathContext; my $parser = XML::LibXML->new; ok($parser, 'XML::LibXML parser created'); my $xml = '<x:me xmlns:x="some_namespace" />'; my $xdoc = $parser->parse_string($xml); ok($xdoc, 'Valid XML parsed'); $xdoc = XML::LibXML::XPathContext->new($xdoc); ok($xdoc, 'Converted to XPathContext'); my ($node) = $xdoc->findnodes('/me'); ok(!$node, 'Not found because no prefix means NULL namespace'); ($node) = $xdoc->findnodes('/x:me'); ok($node, 'Found because using document prefix'); $xdoc->registerNs( new => 'some_namespace' ); ($node) = $xdoc->findnodes('/new:me'); ok($node, 'Found because using new specific prefix'); # Notice the change of namespace my $uri = $xdoc->lookupNs('x'); is($uri, 'some_namespace', 'x prefix is some_namespace'); $xdoc->registerNs( x => 'other_namespace' ); $uri = $xdoc->lookupNs('x'); is($uri, 'some_namespace', 'x prefix is still some_namespace'); ($node) = $xdoc->findnodes('/x:me'); ok(!

The DNS wars

The recent DNS bugs sent me reading the cr.yp.to site for old stories, long forgotten. djbdns is one of the DNS server softwares that was immune to this problem from the start. Some pearls: a Usenet posting of 2001 comparing the attack space of crypto-secure DNS request vs the alternatives;a page about DNS forgery;a blurb about the recent attacks;(not in the cr.yp.to site but still...) djb credited in original post about this latest exploit (search for DJB).

STFU

So you have a friend who is going to spend some time traveling and that journey includes the United States. Usually you would buying him a travel guide. But our times require something different. I recommend that you send your fiend the link to Professor James Duane talk entitled "Don't talk to the Police". In a country where habeas corpus is no longer controlled by the court system, those 26 minutes could save your friend a lot of trouble (as confirmed in the follow up presentation by a police officer).