Encoding files in base64

This works regardless of the file type (be it plain text or some weird
binary format)
Extracted the whole base64 gibberish in a new method
Extracted the reading part into a method
Added a method to deal with text files
Treating text files differently
Writing only the number of bytes I read

This prevents me from adding a bunch of zero's at the end
of the file
Moved the knownTextFiles field to the COPE plugin

I will need it later in the replayer
Merge pull request #116 from caiusb/binary-files

Sanely recording Binary files