SMTP server in node.js - smtpd

One of the things I think node.js is very useful for is a SMTP server. In particular in the SPAM protection I see useful applications. I already had some experience with writing a SMTP client, but still, it's been quite a while. Luckily I found SMTP: Simple Mail Transfer Protocol to freshen things up a bit.

The result of a night toying around with Mail.app and MacVim resulted in node-smtpd.

EHLO [127.0.0.1]
MAIL FROM:<tom@spam.net>
RCPT TO:<tom@spam.net>
DATA
Message:
{ from: '<tom@spam.net>'
, to: '<tom@spam.net>'
, data: 
   [ 'From: Tom de Grunt <tom@spam.net>'
   , 'Content-Type: text/plain; charset=us-ascii'
   , 'Content-Transfer-Encoding: 7bit'
   , 'Subject: Test email'
   , 'Date: Fri, 8 Oct 2010 21:49:17 +0200'
   , 'Message-Id: <37A261DB-0A41-46CC-956A-C55B7CB942F3@spam.net>'
   , 'To: tom@spam.net'
   , 'Mime-Version: 1.0 (Apple Message framework v1081)'
   , 'X-Mailer: Apple Mail (2.1081)'
   , ''
   , 'Hi,'
   , ''
   , 'This is a test email.'
   , ''
   , 'Cheers,'
   , 'Tom.'
   , ''
   ]
}
--------

Repository is on GitHub. Hopefully I'll have the time to expand it beyond it's current state.