共用方式為


圖形最少權限指導插件

比較傳送至 Microsoft Graph 之 JWT 令牌中所使用的許可權,與記錄 Proxy 的要求所需的最低必要範圍進行比較,並顯示差異。

命令提示字元的螢幕快照,其中顯示一組 Microsoft Graph API 要求的最低許可權。

外掛程式實例定義

{
  "name": "GraphMinimalPermissionsGuidancePlugin",
  "enabled": true,
  "pluginPath": "~appFolder/plugins/DevProxy.Plugins.dll",
  "configSection": "graphMinimalPermissionsGuidancePlugin"
}

設定範例

{
  "graphMinimalPermissionsGuidancePlugin": {
   "$schema": "https://raw.githubusercontent.com/dotnet/dev-proxy/main/schemas/v1.0.0/graphminimalpermissionsguidanceplugin.schema.json",
    "permissionsToExclude": [ 
      "profile", 
      "openid", 
      "offline_access", 
      "email"
    ]
  }
}

設定屬性

屬性 說明 預設
permissionsToExclude 要忽略且不包含在報表中的範圍。 profile openid offline_access email

命令列選項

後續步驟