private bool ValidateAVCodes() { bool isValid = false; HAR_StringEncrypter encrypter = new HAR_StringEncrypter(); AwareAppSettings appSettings = new AwareAppSettings(); AwareHelpers awHelpers = new AwareHelpers(appSettings.GetAwareDbConnectionString); if (true == awHelpers.AwareSecurity.VerifyUserCredentials(tboxUserName.Text, encrypter.EncryptString(tboxPassword.Text))) { isValid = true; } return(isValid); }
private bool ValidateGroupMembership() { bool validated = false; List <GroupPrincipal> grpMemberships = new List <GroupPrincipal>(); grpMemberships = GetUserGroups(tboxUserName.Text); AwareAppSettings appSettings = new AwareAppSettings(); AwareHelpers awHelpers = new AwareHelpers(appSettings.GetAwareDbConnectionString); foreach (GroupPrincipal grp in grpMemberships) { awHelpers.AwareSecurity.IsGroupPermittedAccess(grp.Name); } return(validated); }
private bool ValidateSUlogon() { bool isSu = false; AwareAppSettings appSettings = new AwareAppSettings(); string suList = appSettings.GetSuperUserList; if (0 < suList.Length) { foreach (string su in suList.Split(';')) { if (tboxUserName.Text.ToUpper() == su) { isSu = true; break; } } } return(isSu); }