クラス RemoteAuthenticationProvider
- java.lang.Object
-
- org.springframework.security.authentication.rcp.RemoteAuthenticationProvider
- 実装されたすべてのインターフェース:
org.springframework.beans.factory.InitializingBean
,AuthenticationProvider
@Deprecated public class RemoteAuthenticationProvider extends java.lang.Object implements AuthenticationProvider, org.springframework.beans.factory.InitializingBean
使用すべきではありません。5.6.0 現在、代替なし認証リクエストを検証するためにRemoteAuthenticationManager
をクエリするクライアント側オブジェクト。新しい
Authentication
オブジェクトは、このクラスによって作成されます。このクラスは、リクエストAuthentication
オブジェクトのprincipal
、credentials
、RemoteAuthenticationManager
によって返されるGrantedAuthority
[] で構成されます。RemoteAuthenticationManager
は、呼び出しを実行するために、リモートクライアントプロキシファクトリで特別なユーザー名やパスワードを設定する必要はありません。代わりに、認証リクエスト全体をAuthentication
リクエストオブジェクト内にのみカプセル化する必要があります。実際には、これはRemoteAuthenticationManager
が BASIC またはその他の HTTP レベル認証によって保護されないことを意味します。認証が失敗した場合、
RemoteAuthenticationException
がスローされます。この例外をキャッチしてユーザーに表示し、ユーザーが別の資格情報で再試行できるようにする必要があります。
コンストラクターのサマリー
コンストラクター コンストラクター 説明 RemoteAuthenticationProvider()
使用すべきではありません。
メソッドのサマリー
すべてのメソッド インスタンスメソッド 具象メソッド 非推奨のメソッド 修飾子と型 メソッド 説明 void
afterPropertiesSet()
使用すべきではありません。Authentication
authenticate(Authentication authentication)
使用すべきではありません。AuthenticationManager.authenticate(Authentication)
と同じ契約で認証を実行します。RemoteAuthenticationManager
getRemoteAuthenticationManager()
使用すべきではありません。void
setRemoteAuthenticationManager(RemoteAuthenticationManager remoteAuthenticationManager)
使用すべきではありません。boolean
supports(java.lang.Class<?> authentication)
使用すべきではありません。このAuthenticationProvider
が指定されたAuthentication
オブジェクトをサポートする場合、true
を返します。
メソッドの詳細
afterPropertiesSet
public void afterPropertiesSet()
使用すべきではありません。- 次で指定:
- インターフェース
org.springframework.beans.factory.InitializingBean
のafterPropertiesSet
authenticate
public Authentication authenticate(Authentication authentication) throws AuthenticationException
使用すべきではありません。インターフェースからコピーされた説明:AuthenticationProvider
AuthenticationManager.authenticate(Authentication)
と同じ契約で認証を実行します。- 次で指定:
- インターフェース
AuthenticationProvider
のauthenticate
- パラメーター:
authentication
- 認証リクエストオブジェクト。- 戻り値:
- 資格情報を含む完全に認証されたオブジェクト。
AuthenticationProvider
が、渡されたAuthentication
オブジェクトの認証をサポートできない場合、null
を返すことがあります。そのような場合、提示されたAuthentication
クラスをサポートする次のAuthenticationProvider
が試行されます。 - 例外:
AuthenticationException
- 認証が失敗した場合。
getRemoteAuthenticationManager
public RemoteAuthenticationManager getRemoteAuthenticationManager()
使用すべきではありません。
setRemoteAuthenticationManager
public void setRemoteAuthenticationManager(RemoteAuthenticationManager remoteAuthenticationManager)
使用すべきではありません。
supports
public boolean supports(java.lang.Class<?> authentication)
使用すべきではありません。インターフェースからコピーされた説明:AuthenticationProvider
このAuthenticationProvider
が指定されたAuthentication
オブジェクトをサポートする場合、true
を返します。true
を返すことは、AuthenticationProvider
がAuthentication
クラスの提示されたインスタンスを認証できることを保証しません。それは、それがより詳細な評価をサポートできることを示しています。AuthenticationProvider
は、AuthenticationProvider.authenticate(Authentication)
メソッドからnull
を返して、別のAuthenticationProvider
を試す必要があることを示すことができます。認証を実行できる
AuthenticationProvider
の選択は、実行時にProviderManager
で行われます。- 次で指定:
- インターフェース
AuthenticationProvider
のsupports
- 戻り値:
- 実装が提示された
Authentication
クラスをより厳密に評価できる場合はtrue