Interface FederateCookieRedirector

  • All Known Implementing Classes:
    UtilProxyCookieRedirector

    public interface FederateCookieRedirector
    Interface to describe an object that can check a cookie and then perform SAML2 Redirect based on the result.
    • Method Summary

      All Methods Instance Methods Abstract Methods 
      Modifier and Type Method Description
      boolean ifNoCookieIsSetThenSetTheCookieThenRedirectToANewRequestAndReturnTrue​(jakarta.servlet.http.HttpServletRequest request, jakarta.servlet.http.HttpServletResponse response, boolean isIDP)
      Sets the cookie for the SAML2 Request and redirects the request.
      boolean isCookieSet​(jakarta.servlet.http.HttpServletRequest request, jakarta.servlet.http.HttpServletResponse response, boolean isIDP)
      Establishes whether or not the SAML2 cookie is set.
      boolean needSetLBCookieAndRedirect​(jakarta.servlet.http.HttpServletRequest request, jakarta.servlet.http.HttpServletResponse response, boolean isIDP)
      Sets the cookie if required and then redirects the SAML2 request.
      void setCookieAndRedirect​(jakarta.servlet.http.HttpServletRequest request, jakarta.servlet.http.HttpServletResponse response, boolean isIDP)
      Sets the cookie for the SAML2 Request and redirects the request.
    • Method Detail

      • isCookieSet

        boolean isCookieSet​(jakarta.servlet.http.HttpServletRequest request,
                            jakarta.servlet.http.HttpServletResponse response,
                            boolean isIDP)
        Establishes whether or not the SAML2 cookie is set.
        Parameters:
        request - the SAML2 request
        response - the saml2 Response
        isIDP - whether this request was from an IDP
        Returns:
        true if the cookie is set.
      • setCookieAndRedirect

        void setCookieAndRedirect​(jakarta.servlet.http.HttpServletRequest request,
                                  jakarta.servlet.http.HttpServletResponse response,
                                  boolean isIDP)
                           throws UnableToRedirectException
        Sets the cookie for the SAML2 Request and redirects the request.
        Parameters:
        request - the SAML2 Request object
        response - the SAML2 Resposne object
        isIDP - whether this request was from and idp
        Throws:
        UnableToRedirectException - if there was a problem preforming the redirect.
      • ifNoCookieIsSetThenSetTheCookieThenRedirectToANewRequestAndReturnTrue

        boolean ifNoCookieIsSetThenSetTheCookieThenRedirectToANewRequestAndReturnTrue​(jakarta.servlet.http.HttpServletRequest request,
                                                                                      jakarta.servlet.http.HttpServletResponse response,
                                                                                      boolean isIDP)
        Sets the cookie for the SAML2 Request and redirects the request.
        Parameters:
        request - the SAML2 Request object
        response - the SAML2 Resposne object
        isIDP - whether this request was from and idp
      • needSetLBCookieAndRedirect

        boolean needSetLBCookieAndRedirect​(jakarta.servlet.http.HttpServletRequest request,
                                           jakarta.servlet.http.HttpServletResponse response,
                                           boolean isIDP)
        Sets the cookie if required and then redirects the SAML2 request. Returns a boolean to indicate whether the redirect action was taken.
        Parameters:
        request - the SAML2 Request object
        response - the SAML2 Resposne object
        isIDP - whether this request was from and idp
        Returns:
        true if the redirect action was performed