Find all Exchange mailboxes a list of users have access to with PowerShell
To find all Exchange mailboxes a list of users have access to put the mailboxes in a TXT file. One mailbox per line, e.g.:
myname@domain.com
mynewname@domain.com
etc.
Save the file as 'users.txt' and put the file on your desktop.
Run this code to create a TXT file with all the mailboxes a user has access to:
myname@domain.com
mynewname@domain.com
etc.
Save the file as 'users.txt' and put the file on your desktop.
Run this code to create a TXT file with all the mailboxes a user has access to:
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Get-Mailbox | Get-MailboxPermission -User $line | Select-Object Identity,User,AccessRights | ft -AutoSize | Tee-Object C:\users\$env:UserName\desktop\mailboxesUsersHasAccessTo.txt -Append | |
} |
Kommentarer
Send en kommentar