Home / Blog / Exchange Online
Manage DL Members in OWA Without Allowing DL Creation – A Practical Solution
A group owner needs to update membership in Outlook on the web. Granting the ability to create other groups would give the owner more access than the task requires. This example separates those two permissions.
The Challenge
A client recently encountered a problem where a user was unable to manage Distribution Group (DG) members via OWA. After some investigation, we discovered that the MyDistributionGroups role was not included in their role assignment policy.
While enabling this role would solve the immediate issue, it comes with a significant drawback: it also grants the user the ability to create and delete DLs. For organizations with strict governance policies or those that prefer centralized DL creation, this isn't an ideal scenario.
The Goal
Our objective was clear: Allow users to manage existing Distribution Group (DG) members in OWA, but definitively block them from creating or deleting new DLs.
The Solution: Create a Custom Role
The power of Exchange Online's Role-Based Access Control (RBAC) came to the rescue! Here’s how we solved it, step-by-step:
1. Create a Custom Management Role
We started by creating a new custom management role, basing it on the MyDistributionGroups role. This gives us a copy of all its permissions, which we can then modify.
New-ManagementRole -Name “Edit-Existing-DG-Only” -Parent MyDistributionGroups2. Remove Unwanted Cmdlets
Next, we removed the specific cmdlets that allow for DL creation and deletion from our newly created custom role. This is the core of our solution!
Remove-ManagementRoleEntry Edit-Existing-DG-Only\New-DistributionGroup
Remove-ManagementRoleEntry Edit-Existing-DG-Only\Remove-DistributionGroup3. Verify the Entries
It’s always good practice to verify your changes. This command helps ensure that the creation and deletion rights are indeed gone from your custom role.
Get-ManagementRoleEntry Edit-Existing-DG-Only*You should see that New-DistributionGroup and Remove-DistributionGroup are no longer listed for this role.
4. Create a New Role Assignment Policy
Now, we create a new role assignment policy. This policy will include our custom role along with other standard user roles that provide essential OWA functionalities (like managing contact information, retention policies, etc.).
New-RoleAssignmentPolicy -Name “DG-Management-Members-Only” -Roles Edit-Existing-DG-Only, MyContactInformation, MyRetentionPolicies, MyMailSubscriptions, MyTextMessaging, MyVoiceMail, MyDistributionGroupMembership, MyProfileInformationNote: MyDistributionGroupMembership is important for users to manage their own membership in DGs, which is often desired.
5. Assign the New Policy to a Mailbox
To apply this policy to a specific user, use the Set-Mailbox cmdlet:
Set-Mailbox –Identity john@contoso.com -RoleAssignmentPolicy DG-Management-Members-OnlyRemember to replace john@contoso.com with the actual user's email address.
6. Apply to All Mailboxes (If Needed)
For larger deployments, you can apply this new policy to all existing user mailboxes:
Get-Mailbox -RecipientTypeDetails UserMailbox -ResultSize Unlimited | Set-Mailbox -RoleAssignmentPolicy DG-Management-Members-Only7. Set as the Default Policy (Optional)
To ensure that newly created mailboxes automatically inherit this policy, you can set it as the default role assignment policy for your organization:
Set-RoleAssignmentPolicy -Identity DG-Management-Members-Only -IsDefaultResult: Success!
With these steps implemented, the user can now confidently manage Distribution List members directly from Outlook Web App, just as required, but without any ability to create new groups or delete existing ones.