-
Notifications
You must be signed in to change notification settings - Fork 25.5k
backport ms graph plugin docs to 8.19 #130823
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
richard-dennehy
merged 6 commits into
elastic:8.19
from
richard-dennehy:ms-graph-docs-8-19
Aug 29, 2025
Merged
Changes from all commits
Commits
Show all changes
6 commits
Select commit
Hold shift + click to select a range
669ca6b
backport ms graph plugin docs to 8.19
richard-dennehy aae426c
Merge branch '8.19' into ms-graph-docs-8-19
richard-dennehy 2f727ef
incorporate changes from v9 branch
richard-dennehy 3668cfb
address review comments
richard-dennehy ec30efa
fix docs build
richard-dennehy 77d8b78
fix split page
richard-dennehy File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
[[authentication]] | ||
== Authentication plugins | ||
|
||
Authentication plugins extend the functionality provided by the built-in {ref}/realms.html[authentication realms]. | ||
|
||
[discrete] | ||
=== Core authentication plugins | ||
|
||
<<ms-graph-authz,Microsoft Graph Authz>>:: | ||
The Microsoft Graph Authz plugin uses https://learn.microsoft.com/en-us/graph/api/user-list-memberof/[Microsoft Graph] to look up group membership information from Microsoft Entra ID | ||
|
||
include::ms-graph-authz.asciidoc[] |
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
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
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,155 @@ | ||
[[ms-graph-authz]] | ||
=== Microsoft Graph Authz | ||
|
||
The Microsoft Graph Authz plugin uses https://learn.microsoft.com/en-us/graph/api/user-list-memberof[Microsoft Graph] to look up group membership information from Microsoft Entra ID. | ||
|
||
This is primarily intended to work around the Microsoft Entra ID maximum group size limit (see https://learn.microsoft.com/en-us/security/zero-trust/develop/configure-tokens-group-claims-app-roles#group-overages[Group overages]). | ||
|
||
[discrete] | ||
[id="microsoft-graph-authz-install"] | ||
==== Installation | ||
|
||
ifeval::["{release-state}"=="unreleased"] | ||
|
||
WARNING: Version {version} of the Elastic Stack has not yet been released. | ||
|
||
endif::[] | ||
|
||
If you're using a self-managed Elasticsearch cluster, then this plugin can be installed using the plugin manager: | ||
|
||
["source","sh",subs="attributes,callouts"] | ||
---------------------------------------------------------------- | ||
sudo bin/elasticsearch-plugin install microsoft-graph-authz | ||
---------------------------------------------------------------- | ||
|
||
The plugin must be installed on every node in the cluster, and each node must | ||
be restarted after installation. | ||
|
||
You can download this plugin for <<plugin-management-custom-url,offline | ||
install>> from {plugin_url}/microsoft-graph-authz/microsoft-graph-authz-{version}.zip. To verify | ||
the `.zip` file, use the | ||
{plugin_url}/microsoft-graph-authz/microsoft-graph-authz-{version}.zip.sha512[SHA hash] or | ||
{plugin_url}/microsoft-graph-authz/microsoft-graph-authz-{version}.zip.asc[ASC key]. | ||
|
||
For all other deployment types, refer to <<plugin-management,plugin management>>. | ||
|
||
[discrete] | ||
[id="microsoft-graph-authz-remove"] | ||
==== Removal | ||
|
||
The plugin can be removed with the following command: | ||
|
||
["source","sh",subs="attributes,callouts"] | ||
---------------------------------------------------------------- | ||
sudo bin/elasticsearch-plugin remove {plugin_name} | ||
---------------------------------------------------------------- | ||
|
||
The node must be stopped before removing the plugin. | ||
|
||
[discrete] | ||
==== Configuration | ||
To learn how to configure the Microsoft Graph Authz plugin, refer to <<configure-elasticsearch,configuration properties>>. | ||
|
||
[[configure-azure]] | ||
==== Configure Azure | ||
|
||
To make API calls to Microsoft Graph, Elasticsearch requires Azure credentials with the correct permissions. | ||
|
||
[discrete] | ||
==== Create a custom Azure application | ||
|
||
. Log in to the https://portal.azure.com[Azure portal] and go to Microsoft Entra ID. | ||
. To register a new application, click *Enterprise applications* > *New application*. | ||
. Click *Create your own application*, provide a name, and select the *Integrate any other application you don’t find in the gallery* option. | ||
|
||
image::images/01-create-enterprise-application.png["create your own application" page] | ||
|
||
[discrete] | ||
==== Configure the custom Application | ||
|
||
. In the https://portal.azure.com[Azure portal], go to Microsoft Entra ID. | ||
. Under *App registrations*, select the *All applications* tab, and then find the application created in the previous section. | ||
+ | ||
image::images/02-find-app-registration.png[find your app registration] | ||
. Take note of the *Application (client) ID* and *Tenant ID* shown here. | ||
These will be needed to configure Elasticsearch later. | ||
+ | ||
image::images/03-get-application-id.png[get your application ID] | ||
. Under *Manage* > *Certificates & secrets* | ||
- Create a new client secret. | ||
- Take note of your new client secret's *Value*. | ||
This is needed later, and is only displayed once. | ||
+ | ||
image::images/04-create-client-secret.png[get your client secret] | ||
. Under *Manage* > *API permissions*, do the following: | ||
.. Go to *Add a permission*. | ||
.. Choose *Microsoft Graph*. | ||
.. Choose *Application permissions*. | ||
.. Select `Directory.ReadWrite.All`, `Group.ReadWrite.All`, `User.Read.All`. | ||
+ | ||
NOTE: An Azure Admin must approve these permissions before the credentials can be used. | ||
+ | ||
image::images/05-configure-api-permissions.png[configure api permissions] | ||
|
||
[[configure-elasticsearch]] | ||
==== Configuration properties | ||
|
||
After the plugin is installed, the following configuration settings are available: | ||
|
||
xpack.security.authc.realms.microsoft_graph.*.order:: | ||
The priority of the realm within the realm chain. | ||
Realms with a lower order are consulted first. | ||
The value must be unique for each realm. | ||
This setting is required. | ||
|
||
xpack.security.authc.realms.microsoft_graph.*.tenant_id:: | ||
Your Microsoft Entra ID https://learn.microsoft.com/en-us/entra/fundamentals/how-to-find-tenant[Tenant ID]. | ||
This setting is required. | ||
|
||
xpack.security.authc.realms.microsoft_graph.*.client_id:: | ||
The Application ID of the Enterprise Application you registered in the previous section. | ||
This setting is required. | ||
|
||
xpack.security.authc.realms.microsoft_graph.*.client_secret:: | ||
The client secret value for the Application you registered in the previous section. | ||
This is a sensitive setting, and must be configured in the Elasticsearch keystore. | ||
This setting is required. | ||
|
||
xpack.security.authc.realms.microsoft_graph.*.access_token_host:: | ||
A Microsoft login URL. | ||
Defaults to `https://login.microsoftonline.com`. | ||
|
||
xpack.security.authc.realms.microsoft_graph.*.graph_host:: | ||
The Microsoft Graph base address. | ||
Defaults to `https://graph.microsoft.com/v1.0`. | ||
|
||
xpack.security.authc.realms.microsoft_graph.*.http_request_timeout:: | ||
The timeout for individual Graph HTTP requests. | ||
Defaults to `10s`. | ||
|
||
xpack.security.authc.realms.microsoft_graph.*.execution_timeout:: | ||
The overall timeout for authorization requests to this plugin. | ||
Defaults to `30s`. | ||
|
||
Create a Microsoft Graph realm, following the above settings, then configure an existing realm to delegate to it using `authorization_realms`. | ||
|
||
For example, the following configuration authenticates via Microsoft Entra with SAML, and uses the Microsoft Graph plugin to look up group membership: | ||
|
||
[source,yaml] | ||
---- | ||
xpack.security.authc.realms.saml.kibana-realm: | ||
order: 2 | ||
attributes.principal: nameid | ||
attributes.groups: "http://schemas.microsoft.com/ws/2008/06/identity/claims/groups" | ||
idp.metadata.path: "https://login.microsoftonline.com/<Tenant ID>/federationmetadata/2007-06/federationmetadata.xml?appid=<Application_ID>" | ||
idp.entity_id: "https://sts.windows.net/<Tenant_ID>/" | ||
sp.entity_id: "<Kibana_Endpoint_URL>" | ||
sp.acs: "<Kibana_Endpoint_URL>/api/security/saml/callback" | ||
sp.logout: "<Kibana_Endpoint_URL>/logout" | ||
authorization_realms: microsoft_graph1 | ||
|
||
xpack.security.authc.realms.microsoft_graph.microsoft_graph1: | ||
order: 3 | ||
tenant_id: "<Tenant_ID>" | ||
client_id: "<Graph_Application_ID>" | ||
---- |
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.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.