In Active Directory, what is a resource?

怎甘沉沦 提交于 2019-12-22 05:54:10

问题


In the examples and tests for the AAD node.js library, 00000002-0000-0000-c000-000000000000 is always passed as the resource. What is 00000002-0000-0000-c000-000000000000?

The documentation just says that a resource is "A URI that identifies the resource for which the token is valid." But 00000002-0000-0000-c000-000000000000 is a UUID. What is a resource, and what can the value here be?


回答1:


Just to answer one part of your question, 00000002-0000-0000-c000-000000000000 is the app id of the Graph API in all tenants. If you do not pass in a resource parameter when requesting an OAuth 2.0 token it defaults to this. Source: Azure Active Directory application model




回答2:


00000002-0000-0000-c000-000000000000 is a resourceAppId. Add: If you already have a web app, Click "Download Manifest", you could find the resourceAppId in the JSON Manifest file.

You could find these apps in Permissions to other applications as below picture, config your web app permission to other application, if the resource application is selected, it will display in Manifest.

If you want to know more information, pls refer to https://azure.microsoft.com/en-us/documentation/articles/active-directory-application-manifest/




回答3:


To answer the other half of my question, a resource is any kind of entity that can be accessed by an application. In Azure, they are referenced via their URI. Examples include:

  • https://graph.microsoft.com
  • http://localhost:8080
  • https://mydevapp.azurewebsites.net
  • spn:d13730c8-d56f-4d9e-9e1a-9e2afebbca46

00000002-0000-0000-c000-000000000000 is merely a short form of the URI spn:00000002-0000-0000-c000-000000000000, which, as mentioned, is the app id of the Graph API in all tenants



来源:https://stackoverflow.com/questions/36297546/in-active-directory-what-is-a-resource

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!