This device was originally presented at Black Hat Europe 2012. The code is somewhat commented, but it might be somewhat challenging to understand without the background as presented at Black Hat. You should be able to get my white paper and PowerPoint slides from blackhat.com, so I will not repeat that information here.
There are two possible packages for the write blocker. Both use the same code. If you are soldering phobic, you can buy an FTDI Vinco development board for around $30, upload the software, and you are done. If you want to have a much smaller device you should get a FTDI V2DIP1-32 development board (about $18) and an old USB cable to be used for its connector.
Step 1: Get Parts
Step 2: Construct Device
Cut your USB cable. If it has the standard wire colors construction should be very easy. If you are like me, you probably have at least one USB cable with the full size B connector (for a printer or similar) taking up space, so these are good choices for sacrificial cables.
Strip the 4 wires in the cable. Solder them to the board using the table below as a guide:
Pin # Wire Color Function
____ _________ _______
1 Red +5V
4 Green USB D+
5 White USB D-
7 Black Ground
You may want to apply some hot glue AFTER you test the connections to make sure things are nice and rigid and you don't strain the wires by pulling on the cable.
Step 3: Program the Device
Also, please note that a few users have reported problems with 64-bit Windows 7. I'm looking into this, but for the moment I have verified this to work on 32-bit Windows, and both 32-bit and 64-bit Linux without any issues. Speaking of Linux, if you are wanting to build this device to do forensics stuff under Linux, I would recommend you have a look at my instructable for The Deck and in particular have a look at the 4Deck module. The 4Deck will allow you do do write blocker at high speed USB on your Linux system, while the write blocker described here only does full speed.
Step 4: Use It
If you notice any bugs or glitches, please let me know. You can find me on Twitter at @ppolstra.