RequiredScopeAttribute クラス
定義
重要
一部の情報は、リリース前に大きく変更される可能性があるプレリリースされた製品に関するものです。 Microsoft は、ここに記載されている情報について、明示または黙示を問わず、一切保証しません。
この属性は、コントローラー、ページ、またはコントローラー アクションで使用され、Web API で必要なスコープを宣言 (および検証) します。 これらのスコープは、ハードコーディングするか、構成で宣言するかの 2 つの方法で宣言できます。 選択に応じて、どちらか一方のコンストラクターを使用します。 詳細については、 https://aka.ms/ms-id-web/required-scope-attributeを参照してください。
[System.AttributeUsage(System.AttributeTargets.Class | System.AttributeTargets.Method)]
public class RequiredScopeAttribute : Attribute, Microsoft.Identity.Web.IAuthRequiredScopeMetadata
[<System.AttributeUsage(System.AttributeTargets.Class | System.AttributeTargets.Method)>]
type RequiredScopeAttribute = class
inherit Attribute
interface IAuthRequiredScopeMetadata
Public Class RequiredScopeAttribute
Inherits Attribute
Implements IAuthRequiredScopeMetadata
- 継承
-
RequiredScopeAttribute
- 属性
- 実装
コンストラクター
| 名前 | 説明 |
|---|---|
| RequiredScopeAttribute() |
既定のコンストラクター |
| RequiredScopeAttribute(String[]) |
Web API が適切なスコープで呼び出されていることを確認します。
この API に対して取得されたトークンがそのスコープ要求にこれらの |
プロパティ
| 名前 | 説明 |
|---|---|
| AcceptedScope |
この Web API で受け入れられるスコープ。 |
| IsReusable |
未使用: 承認フィルターとのインターフェイスの互換性。 |
| RequiredScopesConfigurationKey |
必要なスコープを含む構成キーの完全修飾名 (スペースで区切ります)。 |