Skip to content

Commit 356f01e

Browse files
committed
add new article
1 parent 1770110 commit 356f01e

3 files changed

Lines changed: 119 additions & 5 deletions

File tree

support/entra/entra-id/app-integration/error-code-aadsts7500514-supported-type-saml-response-not-found.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@ The error typically occurs in the following environment:
3838

3939
Since [ADAL has been deprecated](/entra/identity/monitoring-health/recommendation-migrate-from-adal-to-msal), this article focuses on the MSAL.
4040

41-
This issue occurs if the SAML response from PingFederate does not contain the SAML version or uses a format that MSAL cannot recognize. This typically results from a misconfiguration on the PingFederate side for Microsoft Entra ID.
41+
This issue occurs if the SAML response from PingFederate doesn't contain the SAML version or uses a format that MSAL can't recognize. This typically results from a misconfiguration on the PingFederate side for Microsoft Entra ID.
4242

4343
### Root cause analysis: SAML token version detection
4444

@@ -67,7 +67,7 @@ Example of PingFederate SAML response (SAML Assertion Grant flow step 1):
6767

6868
:::image type="content" source="media/error-code-aadsts7500514-supported-type-saml-response-not-found/pingid-saml-response.png" alt-text="A screenshot of PingFederate SAML Response for SAML Assertion Grant flow step 1" lightbox="media/error-code-aadsts7500514-supported-type-saml-response-not-found/pingid-saml-response.png":::
6969

70-
After you compare these two responses, you will find PingFederate returns a different TokenType value: `http://docs.oasis-open.org/wss/oasis-wss-saml-token-profile-1.1#SAMLV1.1` for the same SAML 1.1 token. However, MSAL does not support any TokenType value other than `urn:oasis:names:tc:SAML:1.0:assertion`.
70+
After you compare these two responses, you will find PingFederate returns a different TokenType value: `http://docs.oasis-open.org/wss/oasis-wss-saml-token-profile-1.1#SAMLV1.1` for the same SAML 1.1 token. However, MSAL doesn't support any TokenType value other than `urn:oasis:names:tc:SAML:1.0:assertion`.
7171

7272
When the identity provider returns a different or unexpected value in the SAML response, MSAL may incorrectly interpret the token as SAML 2.0. As a result, it uses the corresponding `grant_type` value during step 2 of the SAML Assertion Grant flow.
7373

@@ -79,12 +79,12 @@ Example of the request sent from MSAL application with AD FS :
7979

8080
:::image type="content" source="media/error-code-aadsts7500514-supported-type-saml-response-not-found/pingid-saml-response-3.png" alt-text="A screenshot of request sent from MSAL application with AD FS in SAML Assertion Grant flow step 2." lightbox="media/error-code-aadsts7500514-supported-type-saml-response-not-found/pingid-saml-response-3.png":::
8181

82-
In this step, the value of the `grant_type` parameter must align with the actual version of the SAML token. The following values are used:
82+
In this step, the value of the `grant_type` parameter must align with the actual version of the SAML token. One of the following values are used by MSAL application:
8383

8484
- urn:ietf:params:oauth:grant-type:saml2-bearer - for SAML 2.0 tokens
8585
- urn:ietf:params:oauth:grant-type:saml1_1-bearer - for SAML 1.1 tokens
8686

87-
In the case of a PingFederate account, MSAL uses the `saml2-bearer` as the `grant_type` based on its misinterpretation of the SAML version. This results in a version mismatch between the `grant_type` parameter and the SAML token included in the assertion that causes the authentication error.
87+
In the PingFederate example, MSAL uses the `saml2-bearer` as the `grant_type` based on its misinterpretation of the SAML version. This results in a version mismatch between the `grant_type` parameter and the SAML token included in the assertion that causes the authentication error.
8888

8989
## Solution
9090

support/entra/entra-id/toc.yml

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -294,7 +294,8 @@
294294
href: users-groups-entra-apis/identity-of-calling-application-not-established.md
295295
- name: Add an owner to an application
296296
href: users-groups-entra-apis/add-owner-for-application-microsoft-graph.md
297-
297+
- name: 403 error when adding a user to a group
298+
href: users-groups-entra-apis/authorization-requestdenied-403-error-add-user-group.md
298299
- name: Microsoft Entra User Provisioning and Synchronization
299300
items:
300301
- name: User Sign-in or password Problems
Lines changed: 113 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,113 @@
1+
---
2+
title: Troubleshoot 403 error when adding a user to a group using Microsoft Graph API
3+
description: Provides solutions to 403 Authorization_RequestDenied error that occurs when you add a user to a group using Microsoft Graph API.
4+
ms.date: 04/21/2025
5+
ms.service: entra-id
6+
ms.author: bachoang
7+
ms.custom: sap:Getting access denied errors (Authorization)
8+
---
9+
10+
# Troubleshoot 403 error when adding a user to a group using Microsoft Graph API
11+
12+
This article provides guidance on troubleshooting a 403 Authorization_RequestDenied error when you try to add a user to a group using the Microsoft Graph API.
13+
14+
## Symptoms
15+
16+
When you try to add a user to a group using Microsoft Graph API, you receive the 403 error with the following error message:
17+
18+
```output
19+
{
20+
"error": {
21+
"code": "Authorization\_RequestDenied",
22+
"message": "Insufficient privileges to complete the operation.",
23+
"innerError": {
24+
"date": "2024-05-07T15:39:39",
25+
"request-id": "aa324f0f-b4a3-4af6-9c4f-996e195xxxx",
26+
"client-request-id": "aa324f0f-b4a3-4af6-9c4f-996e1959074e"
27+
}
28+
}
29+
}
30+
```
31+
32+
## Cause
33+
34+
This issue might occur if the group you tried to add the use to can't be managed by Microsoft Graph. Microsoft Graph only supports Microsoft 365 groups and Security groups.
35+
36+
For the Microsoft Graph supported group types, see [Working with groups in Microsoft Graph](/graph/api/resources/groups-overview?view=graph-rest-1.0&tabs=http#group-types-in-microsoft-entra-id-and-microsoft-graph)
37+
38+
## Solution
39+
40+
### Step 1: Check the group type
41+
42+
Make sure that the group you are working is supported by Microsoft Graph.
43+
44+
1. In Microsoft Graph, the type of group can be identified by the settings of its `groupTypes`, `mailEnabled`, and `securityEnabled` properties. Use the [Microsoft Graph Explorer](https://developer.microsoft.com/graph/graph-explorer) tool to check the group's attributes:
45+
46+
```http
47+
https://graph.microsoft.com/v1.0/groups/<Group Object ID>?$select=displayName,groupTypes,mailEnabled,securityEnable
48+
```
49+
50+
Example response:
51+
52+
```output
53+
{
54+
"@odata.context": "https://graph.microsoft.com/v1.0/$metadata#groups(displayName,groupTypes,mailEnabled,securityEnabled)/$entity",
55+
"displayName": "Test group A",
56+
"groupTypes": [],
57+
"mailEnabled": true,
58+
"securityEnabled": false
59+
}
60+
61+
```
62+
63+
2. Review the following table to verify if the group type is supported by Microsoft Graph API. In the example response, the "Test group A" group is a security group. For more information, see [Working with groups in Microsoft Graph](/graph/api/resources/groups-overview?view=graph-rest-1.0&tabs=http#group-types-in-microsoft-entra-id-and-microsoft-graph).
64+
65+
| Type |groupTypes | mailEnabled | securityEnabled | Created and managed via the groups APIs |
66+
|--|--|--|--|--|
67+
| [Microsoft 365 groups](#microsoft-365-groups) | `["Unified"]` | `true` | `true` or `false` | Yes |
68+
| [Security groups](#security-groups-and-mail-enabled-security-groups) | `[]` | `false` | `true` | Yes |
69+
| [Mail-enabled security groups](#security-groups-and-mail-enabled-security-groups) | `[]` | `true` | `true` | No; read-only through Microsoft Graph |
70+
| Distribution groups | `[]` | `true` | `false` | No; read-only through Microsoft Graph |
71+
72+
> [!NOTE]
73+
> - Group type cannot be changed after creation. For more information, see [Edit group settings](/entra/fundamentals/how-to-manage-groups#edit-group-settings).
74+
> - Dynamic groups (groupTypes contains "DynamicMembership") cannot have their membership managed via Microsoft Graph.
75+
76+
### Step 2: Verify required permissions
77+
78+
Different group member types require specific permissions. For user-type membership, ensure that the application or account performing the operation has the `GroupMember.ReadWrite.All` permission.
79+
80+
Refer to the [Add members documentation](https://learn.microsoft.com/en-us/graph/api/group-post-members?view=graph-rest-1.0&amp;tabs=http) for detailed permission requirements.
81+
82+
### Step 3: Check if the group is a role-assignable group
83+
84+
1. Role-assignable groups require additional permissions to manage their members. You can confirm if the group is role-assignable using Azure Portal or Microsoft Graph Explorer:
85+
86+
**Azure Portal**
87+
88+
1. In the [Azure portal](https://portal.azure.com), go to **Microsoft Entra ID**, select **Groups**, and then select **All groups**.
89+
1. Locate the group that you are working on, select **Properties**. Review the **Microsoft Entra role can be assigned to the group** option.
90+
91+
**Microsoft Graph Explorer:**
92+
93+
Perform the following query and check the `isAssignableToRoles` value.
94+
95+
```http
96+
GET https://graph.microsoft.com/v1.0/groups/<group object="" id="">?$select=displayName,groupTypes,mailEnabled,securityEnabled,isAssignableToRole
97+
```
98+
Example response:
99+
100+
```output
101+
{
102+
"@odata.context": "https://graph.microsoft.com/v1.0/$metadata#groups(displayName,groupTypes,mailEnabled,securityEnabled,isAssignableToRole)/$entity",
103+
"displayName": "Test group B",
104+
"groupTypes": [],
105+
"mailEnabled": false,
106+
"securityEnabled": true,
107+
"isAssignableToRole": true
108+
}
109+
```
110+
111+
2. If the group is role-assignable, you need the `RoleManagement.ReadWrite.Directory` permission in addition to `GroupMember.ReadWrite.All`. Fore more information, see [Add members documentation](/graph/api/group-post-members?view=graph-rest-1.0&amp;tabs=http#permissions).
112+
113+
[!INCLUDE [Azure Help Support](../../../includes/azure-help-support.md)]

0 commit comments

Comments
 (0)