private void EncryptPassword(string password) { RsaCryptoService.GeneratePrivateKey(RsaPrivateKeyFileName); using (RsaCryptoService cryptoService = new RsaCryptoService()) { string encryptData = cryptoService.EncryptData(RsaPrivateKeyFileName, password); File.WriteAllText(RsaPublicKeyFileName, encryptData); } }
public DatabaseEngineProvider() { _rsaCryptoService = new RsaCryptoService(); _installer = new DatabaseEngineInstaller(); }