Hierarchical RBAC system for Azure Active Directory - azure-active-directory

I'm looking for a hierarchical RBAC system to be used with Azure Active Directory accounts.
With the hierarchical RBAC system I would like to authorize users to have access and be in roles in a hierarchical structure, e.g.:
Customer 1
role: finance - user G
Shopping mole A
Shop X
role: admin - user U
role: security - user U, user V
role: access - user U, user K, user L
role: finance - user L, user N
Shop Y
role: admin - user Q
...
Customer 2
...
Note that a user could be in a different role for shop X and shop Y.
Any pointers to such a system/library?

• The way you want to use the hierarchical RBAC permissions for the Azure Active Directory accounts in your scenario can be achieved by leveraging the managed identity feature of Identity and Access Management. Through the system assigned managed identity, you can create an identity for the Azure resource that you want to deploy and manage with the user that is assigned to it.
Similarly, if you create a user assigned managed identity for a user, then that user can be assigned varied levels of permissions and privileges relative to the Azure resources that you want to deploy and use such that the same identity can have different permissions and roles for a resource deployed for a particular management group while that same identity assigned to that user can have different permissions and roles for another Aure resource.
• Thus, with regards to Azure AD, there is no such hierarchical system designed as in on-premises Active Directory but the RBAC system in Azure AD is quite robust and useful if used on an optimum basis. As when you said that you want the same user to perform roles in different business units, you can use the user assigned managed identity to a good affect as it will leverage the different RBAC permissions for the same user based on a created and managed identity by Azure that is linked to it thus thereby successfully keeping the user’s original identity discreet and ensuring the RBAC permissions are applied.
For more information, you can surely refer to the documentation link below: -
https://learn.microsoft.com/en-us/azure/active-directory/managed-identities-azure-resources/overview

Related

Azure B2C - granting access to multiple “application tenants”

I am building an application which will use Azure B2C as the identity system. It will include some local accounts, and some federated accounts for Enterprise SSO logins.
The application will have “application tenants”, representing customer organization/company.
I’d like a user to be able to grant users access to one or more application tenants (in case some users will manage multiple company accounts within the app).
There will also be multiple roles within the app (e.g. read only, full admin).
What is the recommended way to map a B2C User to “app tenants” and roles?
Create AAD group per tenant and role and check membership?
Custom attribute for tenantid(s)?
Or must I map users to tenants & roles in app DB/ outside of B2C?
Is this scenario described in any docs that might point me in the right direction?
Thanks!

Power BI Guest users

We have an Azure AD Tenant and External users from different organizations are added as Guest in this tenant.
When sharing content with other users, Guest users from different organization can see each other. Is there a way to prevent this enumeration? I see that a new Feature is comming wherin Guest user cannot be #mentioned
Try to set guest user access is restricted to properties and memberships of their own directory objects. This restriction level is the highest. When guests are restricted, they can only view their own user profiles but not other users. See: restrict guest user access.
Log in to the Azure portal as an administrator, go to User settings>Manage external collaboration settings>Select Guest user access is restricted to properties and memberships of their own directory objects (most restrictive)

Possible to login to Snowflake using SSO without a user account or default role?

I'm working on improving the user experience for our org when logging into snowflake. We have adfs sso enabled and are provisioning mapping users to roles using azure ad. I had a colleague attempt to sign in with SSO who didn't have a user account created in snowflake and they were greeted with
"The signed in user <user#email.com> is not assigned to a role for the application (Snowflake)".
My question is, is it possible to have users sign into snowflake without being mapped to a default role, perhaps only have the public role assigned, and without being synced with azure ad.
If it is, i'd appreciate any pointers to documentation i can reference. The goal is to get all users that can SSO, to by default be able to login
AD group syncing occurs every 40 minutes in Microsoft, and I don't believe it's possible to force a sync or change this time frame. In addition, like the OP mentioned Snowflake cannot connect to an on-prem ADFS server so all users must be in Azure AD.
AD group syncing is somewhat configurable via the "Scope" (see Step 15 of this tutorial)
If your Scope is set to "Sync only assigned users and groups", you can either
Change the scope to "Sync all users and groups" (may cause issues if you don't want to import all this data into Snowflake)
or
Confirm that your desired users' AD group is one of those assigned to be synced to Snowflake (requires manually assigning these users, or that all of these users are part of the same AD group that you choose to sync to Snowflake).
By seeing the error its not allowing user who don't have appropriate role for the application.
In these why can't we create generic stored procedure to assign default role and instance to new user based on the group they belong to.! Each time if we add any new user then we have to run stored procedure to assign default role and object prior to his login to snowflake.

Give storage account access to guest user (External Azure Active Directory)

I am using Redgate Data Platform Studio to transfer data from on-premise SQL Server to Azure-hosted SQL Server. This web-based application has the ability to use an Azure Storage account (for data transfer purpose) simply by logging into my company's ADFS. The web application can successfully see storage accounts inside a subscription (let's call it Subscription A) owned by my ADFS user, when I log in to my company's active directory (via ADFS). Let's call my company's AD Directory A.
I also have subscription B owned by a Microsoft account NOT related to my company's Active Directory. This subscription B is managed by another Azure AD Tenant B, with that Microsoft account as the Service Administrator & Owner. To link the two directories, I used B2B State 3 configuration described here. So in Directory B, my Directory A user shows up as Guest User with the Source=External Azure Active Directory.
For the storage accounts in Directory B, I grant the built-in role "Storage Blob Data Contributor" and "Storage Account Contributor" to the Guest User (source=external AAD Directory A). Therefore, in both Microsoft Azure Storage Explorer as well as in portal.azure.com I can see storage accounts inside Subscription B.
BUT if I log in to the Redgate application using Directory A credential (via my company's ADFS), only storage account inside Subscription A shows up in the Redgate application. I already tried giving the guest user in Directory B the following roles to the user, even at the highest Subscription B level, but no luck:
As Co-Administrator
As Contributor
As Storage Account Contributor
As Storage Blob Data Owner
My question: is this the application's limitation of not being able to access subscription in another directory (B), or is there some configuration either in directory A/B and/or subscription A/B that I need to set?
Is this the application's limitation of not being able to access subscription in another directory?
As per my official document and my understanding you cannot assign your subscription among many directory.
As said on official document "Multiple subscriptions can trust the
same Azure AD directory, but each subscription can only trust a single directory".
See the below screen shot and refer here
Note: When you associate a subscription to a different directory, users that have roles assigned using role-based access control (RBAC)
will lose their access. Classic subscription administrators
(Service Administrator and Co-Administrators) will also lose
access. Please check the Important Note here
If you want to know more details please refer this docs

Azure AD Differential query - Detect change in Directory role assignment for a user

I am using differential query (AzureAD graph API) to detect changes in Azure AD from the last sync. I am getting all users, group memberships, manager changes. Only missing information is Directory Role assignment (e.g Billing administrator, SharePoint administrator etc).
How can I detect a change in roles of any user?
API - https://graph.windows.net/{org}/directoryObjects?api-version=1.5&deltaLink=xxxxxttttxxxxxxxx
First, if you have enabled those Directory Roles, you can use AAD Graph API operations on directory roles to list members of those roles.
GET https://graph.windows.net/myorganization/directoryRoles/{object_id}/$links/members?api-version=1.6
But, This API can also list service principals which assigned this role.

Resources