Début transition vers protocol exchange v2 + correction de bug + mis en place deep search
This commit is contained in:
@@ -1,4 +1,6 @@
|
||||
Get-ExecutionPolicy
|
||||
|
||||
Set-ExecutionPolicy Unrestricted
|
||||
Set-ExecutionPolicy Restricted
|
||||
Set-ExecutionPolicy Restricted
|
||||
|
||||
un objet | Get-Member -MemberType Property
|
||||
@@ -27,4 +27,27 @@ Function DialogSay {
|
||||
[string]$Message
|
||||
)
|
||||
[System.Windows.MessageBox]::Show($Message, $Title, 'OK', 'Information')
|
||||
}
|
||||
|
||||
# Show current permissions for all calandars and users
|
||||
Function DisplayAll {
|
||||
param (
|
||||
[string[]]$CalandarFolders
|
||||
)
|
||||
$Users = Get-EXOMailbox -ResultSize Unlimited -RecipientTypeDetails UserMailbox
|
||||
Write-Host ("[$ScriptName] We found " + $Users.count + " users") -BackgroundColor White -ForegroundColor Black
|
||||
foreach ($User in $Users) {
|
||||
Write-Host $User.Name -BackgroundColor DarkGreen
|
||||
$Calandars = Get-EXOMailboxFolderStatistics $User.Identity -FolderScope Calendar | Where-Object {$_.Name -in $CalandarFolders}
|
||||
foreach ($Calandar in $Calandars) {
|
||||
Write-Host $Calandar.Name.ToString() -BackgroundColor DarkMagenta
|
||||
$CurrCalId = $User.Identity.ToString() + ":\" + $Calandar.Name.ToString()
|
||||
$CurrCalPerms = Get-MailboxFolderPermission -Identity $CurrCalId
|
||||
|
||||
foreach ($CurrCalPerm in $CurrCalPerms) {
|
||||
Write-Host ($CurrCalPerm.User.ToString() +" : " + $CurrCalPerm.AccessRights)
|
||||
}
|
||||
}
|
||||
Write-Host
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user