Reorganize MessageEncryptor's _encrypt

According to OpenSSL's documentation cipher.random_iv must be called after cipher.encrypt and already sets the generated IV on the cipher.