docs(sso): say what a directory role name needs from Microsoft Graph - #499
Merged
Conversation
entraid.permission.fields is described as naming group/role fields, and the advice for security groups is to add displayName because they carry no mail. Applied to a directory role that does nothing. With the permissions this page asks for -- User.Read plus GroupMember.Read.All, or the Group.Read.All / Directory.Read.All substitutes named in the note above -- Microsoft Graph answers /me/memberOf with displayName null for a #microsoft.graph.directoryRole entry, so a directory role only ever contributes its GUID, and it does so silently: a missing field is not an error. Granting RoleManagement.Read.Directory, or Directory.Read.All, makes Graph return the name, and the role's displayName then becomes a permission value. Both were confirmed against a live tenant. Say so where the permissions are listed, in all seven languages.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Problem
entraid.permission.fieldsis described as naming group/role fields, and the guidanceunder it tells the reader to add
displayNamebecause security groups carry nomail.Applied to a directory role, that does nothing.
With the permissions this page asks for —
User.ReadplusGroupMember.Read.All, or theGroup.Read.All/Directory.Read.Allsubstitutes named in the note above it — Microsoft Graphanswers
/me/memberOfwithdisplayNamenull for a#microsoft.graph.directoryRoleentry:So a directory role only ever contributes its GUID as a permission — and it does so silently,
because a permission field that is absent is not an error. An administrator who grants access by
role name sees the documented setting have no effect and no message anywhere.
What fixes it
Granting
RoleManagement.Read.Directory, orDirectory.Read.All, makes Graph return the name:and the role's
displayNamebecomes a permission value, so a document scoped to{role}Global Administratorbecomes visible to members of that role.Verification
Checked against a live tenant on 15.8, with a document scoped to the role's name and another to
the role's GUID:
User.Read+Group.Read.AllUser.Read+Group.Read.All+RoleManagement.Read.DirectoryGlobal AdministratorUser.Read+Directory.Read.AllGlobal AdministratorChange
One note, where the permissions are listed, in all seven languages. No behaviour claim outside
what the table above measured.