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 " | $acl.Access | Where-Object { $_.IdentityReference -like " | ||
- | | + | |
} | } | ||
} | } | ||
Строка 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 · Последнее изменение: — Алексей Максимов