#38 - Port the Twitter middleware from katana

This is a direct port, no surprises.
Or for that matter, is it even needed at all?