public void AddUser(string groupSid, string userSid)
        {
            var adPath = _activeDirectoryPathProvider.GetPath();

            if (_activeDirectoryClient.IsInGroup(adPath, userSid, groupSid))
            {
                return;
            }

            _activeDirectoryClient.Add(adPath, userSid, groupSid);
        }
Пример #2
0
 public IEnumerable <string> GetUsersByGroup(string groupSid) =>
 _activeDirectoryClient.GetUsersByGroup(_activeDirectoryPathProvider.GetPath(), groupSid);