Velocity Technical Archive
How to limit users access to OWA in Exchange 2007 via powershell
Archived Reference: This is a historical technical article preserved from the Velocity Technologies knowledge base. For current Phoenix and East Valley managed IT services, explore our managed IT services or cybersecurity solutions.
The first thing you're going to want to do is create two users in active directory. \nOWAEnabled and OWADisabled\nYou then need to mail enabled these two groups.\nenable-DistributionGroup -Identity 'domain.internal/OU/OWAEnabled' -Alias 'OWAEnabled'\nenable-DistributionGroup -Identity 'domain.internal/OU/OWADisabled' -Alias 'OWADisabled'\nI would also hide them from the address list\n Set-Distributiongroup 'OWAEnabled' -HiddenFromAddressListsEnabled $true\nSet-Distributiongroup 'OWADisabled' -HiddenFromAddressListsEnabled $true\nFrom there add the users to their respective groups based on if you want their owa enabled or not.\nFinally once you have that all setup run the following powershell commands\nGet-DistributionGroupMember "OWADisabled" | Set-CasMailbox -OWAEnabled $False\nGet-DistributionGroupMember "OWAEnabled" | Set-CasMailbox -OWAEnabled $True