Beispiel #1
0
        public virtual string EncryptCredentials(string username, string password, string administrativePassword)
        {
            var certificate    = new X509Certificate2(modSicConnection.GetCertificate());
            var CryptoProvider = new ClientCryptoProvider();

            var resolvedUsername = this.ResolveUsername(username);

            return(CryptoProvider.EncryptCredential(certificate, resolvedUsername.Key, resolvedUsername.Value, password, administrativePassword));
        }
Beispiel #2
0
        public virtual string EncryptCredentials(string username, string password, string administrativePassword)
        {
            var certificate = new X509Certificate2(modSicConnection.GetCertificate());
            var CryptoProvider = new ClientCryptoProvider();

            var resolvedUsername = this.ResolveUsername(username);
            return CryptoProvider.EncryptCredential(certificate, resolvedUsername.Key, resolvedUsername.Value, password, administrativePassword);
        }