private IEnumerable <PlainTextLogin> LoginsFromReader(DbDataReader reader)
 {
     while (reader.Read())
     {
         var    passwordBuffer = reader.GetValue(1) as byte[];
         string password       = _crypto.DecryptString(passwordBuffer);
         yield return(new PlainTextLogin(
                          reader.GetString(0),
                          passwordBuffer,
                          reader.GetString(2),
                          reader.GetBoolean(3),
                          password));
     }
 }
Example #2
0
 public string DecryptString(string text)
 {
     return(_crypto.DecryptString(text, _parameters));
 }