Anlage des Repos
This commit is contained in:
18
test/Get-MailboxRights-from-Exchange-for-MailStore.ps1
Normal file
18
test/Get-MailboxRights-from-Exchange-for-MailStore.ps1
Normal file
@@ -0,0 +1,18 @@
|
||||
$UserCredential = Get-Credential
|
||||
$Session = New-PSSession -ConfigurationName Microsoft.Exchange -ConnectionUri http://mc2-vmx01-com01.mc2.local/PowerShell/ -Authentication Kerberos -Credential $UserCredential
|
||||
Import-PSSession $Session
|
||||
|
||||
$test = Get-Mailbox mkaufmann_hp | Get-MailboxPermission | ?{($_.IsInherited -eq $False) -and -not ($_.User -match “NT AUTHORITY”) -and -not ($_.User -match “NT-AUTORITÄT”)} | Select User,@{Name=”AccessRights”;Expression={$_.AccessRights}}
|
||||
$test = Get-Mailbox "hkeller" | Get-MailboxPermission | ?{($_.IsInherited -eq $False) -and -not ($_.User -match “NT AUTHORITY”) -and -not ($_.User -match “NT-AUTORITÄT”)} | Select User,@{Name=”AccessRights”;Expression={$_.AccessRights}}
|
||||
|
||||
#Get-Mailbox {Zu überprüfende Mailbox} | Get-MailboxPermission -User {AD-Benutzer}
|
||||
#Get-Mailbox -ResultSize Unlimited |Get-MailboxPermission -User {ADBenutzer} | Format-Table Identity,AccessRights, Deny
|
||||
|
||||
#$user =”Krishna.k” get-mailbox -identity $user| Get-MailboxPermission | ?{($_.IsInherited -eq $False) -and -not ($_.User -match “NT AUTHORITY”)}
|
||||
#Get-mailbox | Get-MailboxPermission | ?{($_.IsInherited -eq $False) -and -not ($_.User -match “NT AUTHORITY”)} |Select User,Identity,@{Name=”AccessRights”;Expression={$_.AccessRights}} | Export-csv C:\mailboxPermission.csv
|
||||
|
||||
#im MailStore:
|
||||
#users-list
|
||||
#SetUserPrivilegesOnFolder --userName=nvo --folder=mkaufmann --privileges=read
|
||||
|
||||
#Remove-PSSession $Session
|
||||
Reference in New Issue
Block a user