Qt Code:
  1. while( ! t.eof() )
  2. {
  3. message += t.readLine();
  4. message += "\n";
  5. }
To copy to clipboard, switch view to plain text mode 
I see you add a newline character for each line read from the file.
Why is that? RFC 821 specifies maximum line lengths of 998 bytes.
Do you do this for both encrypted and plain files? Because it is not ok to modify an encrypted file like this. A plain file would work, though.

If you do this for encrypted files, then do you also do you do the reverse process on receiving?

Regards