Implementation of mime messages with attachments

Still need to do some clean up and improve the documentation, but the
functionality is working