You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: articles/active-directory/app-provisioning/use-scim-to-provision-users-and-groups.md
+1-156Lines changed: 1 addition & 156 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -757,7 +757,7 @@ TLS 1.2 Cipher Suites minimum bar:
757
757
Now that you have desidned your schema and understood the Azure AD SCIM implementation, you can get started developing your SCIM endpoint. Rather than starting from scratch and building the implementation completely on your own, you can rely on a number of open source SCIM libraries published by the SCIM commuinty.
758
758
The open source .NET Core [reference code](https://aka.ms/SCIMReferenceCode) published by the Azure AD provisioning team is one such resource that can jump start your development. Once you've built your SCIM endpoint, you'll want to test it out. You can use the collection of [postman tests](https://github.com/AzureAD/SCIMReferenceCode/wiki/Test-Your-SCIM-Endpoint) provided as part of the reference code or run through the sample requests / responses provided [above](https://docs.microsoft.com/azure/active-directory/app-provisioning/use-scim-to-provision-users-and-groups#user-operations).
759
759
760
-
Here’s how it works:
760
+
Here’s how it works:
761
761
762
762
1. Azure AD provides a common language infrastructure (CLI) library named Microsoft.SystemForCrossDomainIdentityManagement, included with the code samples describe below. System integrators and developers can use this library to create and deploy a SCIM-based web service endpoint that can connect Azure AD to any application’s identity store.
763
763
2. Mappings are implemented in the web service to map the standardized user schema to the user schema and protocol required by the application.
@@ -822,7 +822,6 @@ The easiest way to implement a SCIM endpoint that can accept provisioning reques
822
822
1. Once your configuration is complete, set the **Provisioning Status** to **On**.
823
823
1. Select **Save** to start the Azure AD provisioning service.
824
824
1. If syncing only assigned users and groups (recommended), be sure to select the **Users and groups** tab and assign the users or groups you want to sync.
825
-
826
825
Once the initial cycle has started, you can select **Audit logs** in the left panel to monitor progress, which shows all actions done by the provisioning service on your app. For more information on how to read the Azure AD provisioning logs, see [Reporting on automatic user account provisioning](check-status-user-account-provisioning.md).
827
826
828
827
The final step in verifying the sample is to open the TargetFile.csv file in the \AzureAD-BYOA-Provisioning-Samples\ProvisioningAgent\bin\Debug folder on your Windows machine. Once the provisioning process is run, this file shows the details of all assigned and provisioned users and groups.
@@ -960,7 +959,6 @@ Requests from Azure Active Directory include an OAuth 2.0 bearer token. Any se
960
959
> [!NOTE]
961
960
> It's ***not*** recommended to leave this field blank and rely on a token generated by Azure AD. This option is primarily available for testing purposes.
962
961
Developers using the CLI libraries provided by Microsoft for building a SCIM service can authenticate requests from Azure Active Directory using the Microsoft.Owin.Security.ActiveDirectory package by following these steps:
963
-
964
962
First, in a provider, implement the Microsoft.SystemForCrossDomainIdentityManagement.IProvider.StartupBehavior property by having it return a method to be called whenever the service is started:
965
963
966
964
```csharp
@@ -1008,159 +1006,6 @@ Next, add the following code to that method to have any request to any of the se
1008
1006
}
1009
1007
```
1010
1008
1011
-
### Handling provisioning and deprovisioning of users
1012
-
1013
-
***Example 1. Query the service for a matching user***
1014
-
1015
-
Azure Active Directory queries the service for a user with an externalId attribute value matching the mailNickname attribute value of a user in Azure AD. The query is expressed as a Hypertext Transfer Protocol (HTTP) request such as this example, wherein jyoung is a sample of a mailNickname of a user in Azure Active Directory.
1016
-
1017
-
>[!NOTE]
1018
-
> This is an example only. Not all users will have a mailNickname attribute, and the value a user has may not be unique in the directory. Also, the attribute used for matching (which in this case is externalId) is configurable in the [Azure AD attribute mappings](customize-application-attributes.md).
1019
-
```
1020
-
GET https://.../scim/Users?filter=externalId eq jyoung HTTP/1.1
1021
-
Authorization: Bearer ...
1022
-
```
1023
-
1024
-
If the service was built using the CLI libraries provided by Microsoft for implementing SCIM services, then the request is translated into a call to the Query method of the service’s provider. Here is the signature of that method:
1025
-
1026
-
```csharp
1027
-
// System.Threading.Tasks.Tasks is defined in mscorlib.dll.
1028
-
// Microsoft.SystemForCrossDomainIdentityManagement.Resource is defined in
GET https://.../scim/Users?filter=externalId eq jyoung HTTP/1.1
1059
-
Authorization: Bearer ...
1060
-
```
1061
-
1062
-
If the service was built using the Common Language Infrastructure libraries provided by Microsoft for implementing SCIM services, then the request is translated into a call to the Query method of the service’s provider. Here is the signature of that method:
1063
-
1064
-
```csharp
1065
-
// System.Threading.Tasks.Tasks is defined in mscorlib.dll.
1066
-
// Microsoft.SystemForCrossDomainIdentityManagement.Resource is defined in
If the response to a query to the web service for a user with an externalId attribute value that matches the mailNickname attribute value of a user doesn't return any users, then Azure Active Directory requests that the service provision a user corresponding to the one in Azure Active Directory. Here is an example of such a request:
The CLI libraries provided by Microsoft for implementing SCIM services would translate that request into a call to the Create method of the service’s provider. The Create method has this signature:
1153
-
1154
-
```csharp
1155
-
// System.Threading.Tasks.Tasks is defined in mscorlib.dll.
1156
-
// Microsoft.SystemForCrossDomainIdentityManagement.Resource is defined in
In a request to provision a user, the value of the resource argument is an instance of the Microsoft.SystemForCrossDomainIdentityManagement. Core2EnterpriseUser class, defined in the Microsoft.SystemForCrossDomainIdentityManagement.Schemas library. If the request to provision the user succeeds, then the implementation of the method is expected to return an instance of the Microsoft.SystemForCrossDomainIdentityManagement. Core2EnterpriseUser class, with the value of the Identifier property set to the unique identifier of the newly provisioned user.
1164
1009
1165
1010
## Step 4: Integrate your SCIM endpoint with the Azure AD SCIM client
0 commit comments