Вики IT-KB

Пошаговые руководства, шпаргалки, полезные ссылки...

Инструменты пользователя

Инструменты сайта


powershell:file-system:find-directories-with-specific-security-group-in-acl-using-powershell

Различия

Показаны различия между двумя версиями страницы.

Ссылка на это сравнение

Следующая версия
Предыдущая версия
powershell:file-system:find-directories-with-specific-security-group-in-acl-using-powershell [10.10.2024 12:00] – создано Алексей Максимовpowershell:file-system:find-directories-with-specific-security-group-in-acl-using-powershell [10.10.2024 13:53] (текущий) Виталий Якоб
Строка 22: Строка 22:
     $acl = Get-Acl -Path $Path     $acl = Get-Acl -Path $Path
     $acl.Access | Where-Object { $_.IdentityReference -like "*$Group*" } | ForEach-Object {     $acl.Access | Where-Object { $_.IdentityReference -like "*$Group*" } | ForEach-Object {
-        Write-Output "$Path : Установлена группа '$Group' с разрешениями: $($_.FileSystemRights)"+    Write-Output "$Path : Установлена группа '$Group' с правами: $($_.FileSystemRights)"
     }     }
 } }
Строка 36: Строка 36:
     Check-AclForGroup -Path $Path -Group $Group     Check-AclForGroup -Path $Path -Group $Group
  
-    # Возврат, если достигнута максимальная глубина+    # Останавливаем рекурсию при достижении макс глубины
     if ($MaxDepth -le 0) { return }     if ($MaxDepth -le 0) { return }
  
powershell/file-system/find-directories-with-specific-security-group-in-acl-using-powershell.1728550839.txt.gz · Последнее изменение: Алексей Максимов

Donate Powered by PHP Valid HTML5 Valid CSS Driven by DokuWiki