インターフェース AuthenticationEntryPoint

すべての既知の実装クラス:
BasicAuthenticationEntryPointBearerTokenAuthenticationEntryPointCasAuthenticationEntryPointDelegatingAuthenticationEntryPointDigestAuthenticationEntryPointHttp403ForbiddenEntryPointHttpStatusEntryPointLoginUrlAuthenticationEntryPointNoOpAuthenticationEntryPoint

public interface AuthenticationEntryPoint
認証スキームを開始するために ExceptionTranslationFilter によって使用されます。
  • メソッドのサマリー

    修飾子と型
    メソッド
    説明
    void
    commence(jakarta.servlet.http.HttpServletRequest request, jakarta.servlet.http.HttpServletResponse response, AuthenticationException authException)
    認証スキームを開始します。
  • メソッドの詳細

    • commence

      void commence(jakarta.servlet.http.HttpServletRequest request, jakarta.servlet.http.HttpServletResponse response, AuthenticationException authException) throws IOExceptionSE, jakarta.servlet.ServletException
      認証スキームを開始します。

      ExceptionTranslationFilter は、このメソッドを呼び出す前に、AbstractAuthenticationProcessingFilter.SPRING_SECURITY_SAVED_REQUEST_KEY という名前の HttpSession 属性にリクエストされたターゲット URL を入力します。

      実装では、必要に応じて ServletResponse のヘッダーを変更して、認証プロセスを開始する必要があります。

      パラメーター:
      request - AuthenticationException が発生したリクエスト
      response - ユーザーエージェントが認証を開始できるようにする
      authException - 呼び出しの原因となった例外
      例外:
      IOExceptionSE
      jakarta.servlet.ServletException