Reorganize MessageEncryptor::_encrypt

According to OpenSSL's documentation, cipher.random_iv must be called after cipher.encrypt and will set the generated IV on the cipher.