クラス AuthorizationManagerWebInvocationPrivilegeEvaluator
java.lang.ObjectSE
org.springframework.security.web.access.AuthorizationManagerWebInvocationPrivilegeEvaluator
- 実装されたすべてのインターフェース:
org.springframework.beans.factory.Aware
、WebInvocationPrivilegeEvaluator
、org.springframework.web.context.ServletContextAware
public final class AuthorizationManagerWebInvocationPrivilegeEvaluator
extends ObjectSE
implements WebInvocationPrivilegeEvaluator, org.springframework.web.context.ServletContextAware
チェックを
AuthorizationManager
のインスタンスに委譲する WebInvocationPrivilegeEvaluator
の実装 - 導入:
- 5.5.5
ネストされたクラスのサマリー
ネストされたクラスコンストラクターの概要
コンストラクターコンストラクター説明AuthorizationManagerWebInvocationPrivilegeEvaluator
(AuthorizationManager<jakarta.servlet.http.HttpServletRequest> authorizationManager) メソッドのサマリー
修飾子と型メソッド説明boolean
isAllowed
(StringSE contextPath, StringSE uri, StringSE method, Authentication authentication) 指定された Authentication オブジェクトによって表されるユーザーが、指定されたパラメーターを使用して指定された URI を呼び出すことができるかどうかを決定します。boolean
isAllowed
(StringSE uri, Authentication authentication) 指定された Authentication オブジェクトによって表されるユーザーが、指定された URI を呼び出すことができるかどうかを決定します。void
setRequestTransformer
(AuthorizationManagerWebInvocationPrivilegeEvaluator.HttpServletRequestTransformer requestTransformer) void
setServletContext
(jakarta.servlet.ServletContext servletContext)
コンストラクターの詳細
AuthorizationManagerWebInvocationPrivilegeEvaluator
public AuthorizationManagerWebInvocationPrivilegeEvaluator(AuthorizationManager<jakarta.servlet.http.HttpServletRequest> authorizationManager)
メソッドの詳細
isAllowed
インターフェースからコピーされた説明:WebInvocationPrivilegeEvaluator
指定された Authentication オブジェクトによって表されるユーザーが、指定された URI を呼び出すことができるかどうかを決定します。これは、特定の
HttpMethod
を必要としない認可ルールにのみ一致することに注意してください。- 次で指定:
- インターフェース
WebInvocationPrivilegeEvaluator
のisAllowed
- パラメーター:
uri
- コンテキストパスを除く URI (デフォルトのコンテキストパス設定が使用されます)
isAllowed
public boolean isAllowed(StringSE contextPath, StringSE uri, StringSE method, Authentication authentication) インターフェースからコピーされた説明:WebInvocationPrivilegeEvaluator
指定された Authentication オブジェクトによって表されるユーザーが、指定されたパラメーターを使用して指定された URI を呼び出すことができるかどうかを決定します。注:
- FilterInvocationSecurityMetadataSource のデフォルト実装では、特定のリクエスト URI に適用されるセキュアオブジェクトメタデータを評価するときに
contextPath
は無視されるため、カスタムFilterInvocationSecurityMetadataSource
を使用している場合を除き、通常、contextPath
は重要ではありません。 - これは、特定の
HttpMethod
を必要としない認可ルールにのみ一致します。
- 次で指定:
- インターフェース
WebInvocationPrivilegeEvaluator
のisAllowed
- パラメーター:
contextPath
- コンテキストパス(null の場合があります)。uri
- コンテキストパスを除く URImethod
- HTTP メソッド (または null、任意のメソッド)authentication
- Authentication インスタンス。その権限は、アクセスを許可するかどうかの評価に使用する必要があります。- 戻り値:
- アクセスが許可されている場合は true、拒否されている場合は false
- FilterInvocationSecurityMetadataSource のデフォルト実装では、特定のリクエスト URI に適用されるセキュアオブジェクトメタデータを評価するときに
setServletContext
public void setServletContext(jakarta.servlet.ServletContext servletContext) - 次で指定:
- インターフェース
org.springframework.web.context.ServletContextAware
のsetServletContext
setRequestTransformer
public void setRequestTransformer(AuthorizationManagerWebInvocationPrivilegeEvaluator.HttpServletRequestTransformer requestTransformer) AuthorizationManager
に渡す前に使用するAuthorizationManagerWebInvocationPrivilegeEvaluator.HttpServletRequestTransformer
を設定します。- パラメーター:
requestTransformer
- 使用するAuthorizationManagerWebInvocationPrivilegeEvaluator.HttpServletRequestTransformer
。