インターフェース AuthenticationProvider
- すべての既知の実装クラス:
AbstractJaasAuthenticationProvider、AbstractLdapAuthenticationProvider、AbstractUserDetailsAuthenticationProvider、ActiveDirectoryLdapAuthenticationProvider、AnonymousAuthenticationProvider、AuthenticationManagerBeanDefinitionParser.NullAuthenticationProvider、CasAuthenticationProvider、ClientSecretAuthenticationProvider、DaoAuthenticationProvider、DefaultJaasAuthenticationProvider、DPoPAuthenticationProvider、JaasAuthenticationProvider、JwtAuthenticationProvider、JwtClientAssertionAuthenticationProvider、KerberosAuthenticationProvider、KerberosServiceAuthenticationProvider、LdapAuthenticationProvider、OAuth2AuthorizationCodeAuthenticationProvider、OAuth2AuthorizationCodeAuthenticationProvider、OAuth2AuthorizationCodeRequestAuthenticationProvider、OAuth2AuthorizationConsentAuthenticationProvider、OAuth2ClientCredentialsAuthenticationProvider、OAuth2ClientRegistrationAuthenticationProvider、OAuth2DeviceAuthorizationConsentAuthenticationProvider、OAuth2DeviceAuthorizationRequestAuthenticationProvider、OAuth2DeviceCodeAuthenticationProvider、OAuth2DeviceVerificationAuthenticationProvider、OAuth2LoginAuthenticationProvider、OAuth2PushedAuthorizationRequestAuthenticationProvider、OAuth2RefreshTokenAuthenticationProvider、OAuth2TokenExchangeAuthenticationProvider、OAuth2TokenIntrospectionAuthenticationProvider、OAuth2TokenRevocationAuthenticationProvider、OidcAuthorizationCodeAuthenticationProvider、OidcClientConfigurationAuthenticationProvider、OidcClientRegistrationAuthenticationProvider、OidcLogoutAuthenticationProvider、OidcUserInfoAuthenticationProvider、OneTimeTokenAuthenticationProvider、OpaqueTokenAuthenticationProvider、PreAuthenticatedAuthenticationProvider、PublicClientAuthenticationProvider、RememberMeAuthenticationProvider、RunAsImplAuthenticationProvider、TestingAuthenticationProvider、WebAuthnAuthenticationProvider、X509ClientCertificateAuthenticationProvider
public interface AuthenticationProvider
クラスが特定の
Authentication 実装を処理できることを示します。メソッドのサマリー
修飾子と型メソッド説明@Nullable Authenticationauthenticate(Authentication authentication) AuthenticationManager.authenticate(Authentication)と同じ契約で認証を実行します。booleanこのAuthenticationProviderが指定されたAuthenticationオブジェクトをサポートしている場合は、trueを返します。
メソッドの詳細
authenticate
AuthenticationManager.authenticate(Authentication)と同じ契約で認証を実行します。- パラメーター:
authentication- 認証リクエストオブジェクト。- 戻り値:
- 資格情報を含む完全に認証されたオブジェクト。
AuthenticationProviderが、渡されたAuthenticationオブジェクトの認証をサポートできない場合、nullを返すことがあります。そのような場合、提示されたAuthenticationクラスをサポートする次のAuthenticationProviderが試行されます。 - 例外:
AuthenticationException- 認証が失敗した場合。
supports
このAuthenticationProviderが指定されたAuthenticationオブジェクトをサポートする場合、trueを返します。trueを返しても、AuthenticationProviderが提示されたAuthenticationオブジェクトを認証できることは保証されません。これは単に、より詳細な評価をサポートできることを示しているだけです。AuthenticationProviderは、authenticate(Authentication)メソッドからnullを返して、別のAuthenticationProviderを試す必要があることを示すことができます。認証を実行できる
AuthenticationProviderの選択は、実行時にProviderManagerによって行われます。- パラメーター:
authentication-- 戻り値:
- 実装が提示された
Authenticationクラスをより厳密に評価できる場合はtrue