public bool Authenticate(string user, string passwordPlainText) { var userObj = _dbManager.User.Get(user); if (user == null) throw new Exception(); return userObj.Credential == EncryptPassword(passwordPlainText); }