After publishing some recent articles on RBAC, there was some feedback that a primer on RBAC would also be welcomed. So here it is!
It is not Really Boring Access Control. RBAC = Role Based Access Control. As a concept it is not new, however Exchange 2010 was the first time that it has been natively supported in Exchange. That being said, we still had the concept of roles in Exchange 2007 and older versions.
For example in Exchange 2003 we had these roles:
In Exchange 2007 we had slightly more roles:
As you can see the concept or roles is not new to Exchange, but why this RBAC thing? What’s that all about?
RBAC has many advantages compared to the previous administration model. RBAC allows for:
Access to Exchange 2010/2013 is controlled via RBAC. RBAC determines who can do what to a given object. This applies to both administrators and end users. RBAC will perform the action requested by the user and this will be in the security context of the Exchange Trusted Subsystem (ETS) universal security group. This is a change from previous versions where the credentials of the requesting users were used to access the object and make the necessary changes. As a result previous auditing methodologies need to change, so that we now make use of the Exchange auditing capabilities. ETS is a highly privileged group which contains read and write permissions to all Exchange objects. Nothing else should be added to this group.
RBAC is assigned to administrators to let them perform the necessary tasks on servers, connectors and mailboxes. This is in the form of a Role Assignment. RBAC to end users is delivered as a Role Assignment Policy. They are very similar but are tailored to their respective purpose.
In previous versions when a person was added to the Exchange Organization Administrators or Exchange Full Administrators roles they had every capability in Exchange. This is not the case any more, so become accustomed to not having access to all keys of the kingdom. Now, all the keys can be granted – it’s just that you do not have them by default. Examples of permissions and capabilities that an Org Admin does not have out of the box in Exchange 2010 include:
There are three main points to consider when planning out RBAC -- Where, What and Who.
OK – there is also the glue (role assignment that binds them), but let’s not mess up a nice list!
This is covered in detail by the RBAC Triangle Of Power.
Cutting through the terminology can be beneficial for reviewing RBAC. One frequently heard comment is that the word “role” is overused. When you see the main cmdlets laid out, it’s not bad! These are the core components of RBAC:
I’ll let you browse through the above content at your pleasure!
The end user RBAC roles contain cmdlets related to managing a user’s own mailbox and is scoped as such. Administrator RBAC roles contain the necessary cmdlets to manage the messaging infrastructure. Examples of Management Roles are show below:
They are represented in Active Directory as universal security groups, stored in the Microsoft Exchange Security Groups OU:
The Management Role contains Management Role Entries, which are the individual cmdlets and their parameters that actually let you do tasks. To see the actual Management Role Entries use the Get-ManagementRoleEntry cmdlet. Note that the Management Role Entries are stored within the Management Role, and this is why the syntax looks like Get-ManagementRoleEntry “ManagementRoleName\*”
Other examples to retrieve Management Role Entries could be:
It is fairly simple to understand how the built-in roles map to administrator or end user RBAC as the built in end user roles are prefixed with “My”. Custom roles are not obliged to follow this nomenclature (though it does make life easier if they do). To be sure of a Role type examine its IsEndUserRole property. The first role shown below is for end user RBAC, and the second is for administrators or specialist roles.
You will encounter two types of Role Groups on your travels. When Exchange 2010 or 2013 is installed into an AD forest all the necessary installation steps are executed, one of which is to install a base RBAC platform. If you have a multi forest (Exchange resource forest) environment, since the installation is executed in one forest then there is no knowledge of RBAC in the other forest. If you want to administer Exchange as a user from the account forest then you will need to tell Exchange in the resource forest who gets what administrative permissions in the user forest. In other words you need to roll your own RBAC for the user forest, this is a task that you need to perform as it is not automatically done.
A one way trust is the minimum requirement so the relevant AD objects are visible, and the RBAC roles can be defined. When assigning the roles, RBAC points to a Universal security group in the other forest and a Linked Role Group is created.
You will see this if you look for the RoleGroupType. Standard denotes a regular RBAC RoleGroup in the same forest as Exchange. Linked indicates that this is a linked role group to a remote forest.
Get-RoleGroup "Organization Management" | select Name, RoleGroupType | Format-Table -AutoSize
As the name implies, Management Scope stipulates where a particular set of permissions will apply. This could be scoped to a:
To perform advanced RBAC tasks you will certainly want to get familiar with this concept of management scopes since scopes allow you to control where a particular permission will apply. An example of a couple of scopes in one of my labs:
To create the Executive management scope we could run:
New-ManagementScope -name "Executives" -RecipientRestrictionFilter {memberofgroup -eq "cn=Execs,ou=VIP,dc=contoso,dc=com"}
On a related note, note that in PowerShell the equals character “ = “ is not used to evaluate if values match. The equals operator is text based and is “ –eq “ with the not equals operator being “ –ne “.
There is a handy table on TechNet or you can open PowerShell and review the output of:
Get-Help about_Comparison_Operators | More
Note that there are different aspects to scope, and the reason that I want to mention this is around scoping where users can read. While it is possible to limit the write aspects for both configuration and user scopes, read is at the organisation level.
Some folks like the above triangle of power to represent RBAC, but I personally prefer this graphic to really illustrate the relationships of the RBAC building blocks.
It pulls together all the concepts from Management Role Entries, Role Assignments and Role Assignment Policies.
Please see the previous posts to see how to create a custom RBAC role and then assign it to a group:
Creating RBAC Role To Delegate Contact Management - This one shows an example of using the “Mail Recipient Creation” role to create a customised role.
Allow Users To Manage Distribution Groups Without Creating New Ones - This one shows an example of customising the RBAC role assigned to an end user, and is something that RBC has already implemented in production.
How To Add Or Remove Cmdlet Parameter From RBAC Management Role - illustrates the amazing precision that is possible within RBAC
In case you were wondering about the Wipe Only ActiveSync Role that is shown in a couple of examples, this is discussed in RBAC: Walkthrough of creating a role that can wipe ActiveSync Devices.
Cheers,
Rhoderick
* – Should trademark that!
If you would like to have Microsoft Premier Field Engineering (PFE) visit your company and assist with the topic(s) presented in this blog post, then please contact your Microsoft Premier Technical Account Manager (TAM) for more information on scheduling and our varied offerings!
If you are not currently benefiting from Microsoft Premier support and you’d like more information about Premier, please email the appropriate contact below, and tell them you how you got introduced!
US
Canada
For all other areas please use the US contact point.
Hi, thanks for your article. Now if I have configured RBAC extensively how can I check from a user (service account) perspective in which roles the user is and what permissions are assigned to that user? Thanks! -Peter
Hi Peter, thanks for the feedback - much appreciated! I have another article in draft that should address those very questions - will get that out next week. Cheers, Rhoderick
Thanks for the great info again:)
Peter -- this will go live just after 09:00 Eastern today http://blogs.technet.com/b/rmilne/archive/2014/02/18/exchange-rbac-tips-n-tricks-_2d00_-powershell.aspx Do let us know if that answers your question(s) please! Cheers, Rhoderick
I am trying to figure out how to use my RBAC roles to allow the Helpdesk to make some kinds of changes, but the role groups exist in my empty root domain, and while I can add people in the GUI, they don't work. I can't seem to do anything with them. How do I work across the domains? Thanks for your consideration, Mike
Hey Mike, Can you describe what you mean by "add people in the GUI" please? Also can you add the PowerShell commands that you executed so I can get an idea of the config? Cheers, Rhoderick
thanks for sharing.
I meant that I could add users to the Helpdesk Role Group in ECP, and also assign the Distribution Groups Role to the HelpDesk RoleGroup, and can even see the members I added in the Management Role Group Security group in ADUC (albeit in the empty Root, as that's where those exist), but this didn't appear to give them any additional ability (like to add a member to a DL)
The required steps as I see them; Please let me know If I missed the mark. 1. Management scope = where 2. Management Role = what 3. Role Group = who 4. Role Assignment = puts them all together Suggested names of the things we will create; Scope_DistributionGroups Role_DistributionGroups RoleGroup_DistributionGroups RoleAssign_DistributionGroups 1. Create a Management Scope in our domain to include the OU called Domain/Groups/Mail-Enabled That DN is OU=Mail Enabled,OU=Groups,OU=XXXXXX,DC=XXXXX,DC=corp We will call it Scope_DistributionGroups New-ManagementScope -Name "Scope_DistributionGroups" -RecipientRoot "OurDomain.corp/SomeOU/Groups/mail-enabled" 2. Create a Management Role in our domain that will allow administrators to manage Distribution group membership. We will name it Role_DistributionGroups and set DistributionGroups (from the root) as its parent. (This is the only root stuff needed? New-ManagementRole -Name "Role_DistributionGroups" -Parent " DistributionGroups" 3. Create a Role group whose members will have the right to run the commands allowed by Role_DistributionGroups passed down from the (root) Parent role named DistributionGroups We will name it RoleGroup_DistributionGroups. New-RoleGroup -Name " RoleGroup_DistributionGroups" -Roles "Role_DistributionGroups" –CustomRecipientWriteScope "Scope_DistributionGroups" 4. Create a Management Role Assignment which will tie them together, allowing RoleGroup_DistributionGroups to perform Role_DistributionGroups actions on groups within the Scope of Scope_DistributionGroups We will name it RoleAssign_DistributionGroups New-ManagementRoleAssignment -Name " RoleAssign_DistributionGroups" -SecurityGroup "RoleGroup_DistributionGroups" -Role "Role_DistributionGroups" -RecipientRelativeWriteScope Scope_DistributionGroups 5. Add Role Group Members · Add-RoleGroupMember "RoleGroup_DistributionGroups" -Member "HelpDeskGuy" · Add-RoleGroupMember "RoleGroup_DistributionGroups" -Member "HelpDeskGuy" · Add-RoleGroupMember "RoleGroup_DistributionGroups" -Member "HelpDeskGal" Does this look like a plan? Thanks, Mike
We will need to customize this Role (the new one) to remove some of the abilities, as the native Distribution groups Role is really a "template", which has a lot more abilities than we want to give Remove-ManagementRoleEntry "Role_DistributionGroups\Set-ADServerSettings" Remove-ManagementRoleEntry "Role_DistributionGroups\Remove-DynamicDistributionGroups" Remove-ManagementRoleEntry "Role_DistributionGroups\Remove-DistributionGroup" Remove-ManagementRoleEntry "Role_DistributionGroups\New-DynamicDistributionGroup" Remove-ManagementRoleEntry "Role_DistributionGroups\New-DistributionGroup" Remove-ManagementRoleEntry "Role_DistributionGroups\Set-DistributionGroup" Remove-ManagementRoleEntry "Role_DistributionGroups\Set-DynamicDistributionGroup" Remove-ManagementRoleEntry "Role_DistributionGroups\Set-OrganizationConfig" Remove-ManagementRoleEntry "Role_DistributionGroups\Disable-DistributionGroup" Remove-ManagementRoleEntry "Role_DistributionGroups\Write-AdminAuditLog" Remove-ManagementRoleEntry "Role_DistributionGroups\Get-ResourceConfig"
My default management role groups are all in the empty root domain. Does this mean my Roles are also there? If I do this: New-ManagementRole -Name "Role_DistributionGroups" -Parent "DistributionGroups" Will it find the Parent role without being somehow pointed at the other (root) domain?
Hi Mike - yes they are in the root domain. You will also find the arbitration mailboxes are there as well. Cheers, Rhoderick