Class BaseSingleLogoutServiceMessageHandler

  • All Implemented Interfaces:
    org.apereo.cas.logout.slo.SingleLogoutServiceMessageHandler, org.springframework.core.Ordered
    Direct Known Subclasses:
    DefaultSingleLogoutServiceMessageHandler

    public abstract class BaseSingleLogoutServiceMessageHandler
    extends java.lang.Object
    implements org.apereo.cas.logout.slo.SingleLogoutServiceMessageHandler
    Since:
    6.0.0
    • Field Summary

      • Fields inherited from interface org.springframework.core.Ordered

        HIGHEST_PRECEDENCE, LOWEST_PRECEDENCE
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      protected org.apereo.cas.logout.slo.SingleLogoutRequestContext createLogoutRequest​(java.lang.String ticketId, org.apereo.cas.authentication.principal.WebApplicationService selectedService, org.apereo.cas.services.RegisteredService registeredService, org.apereo.cas.logout.slo.SingleLogoutUrl logoutUrl, org.apereo.cas.logout.SingleLogoutExecutionRequest context)
      Create logout request logout request.
      protected java.util.Collection<org.apereo.cas.logout.slo.SingleLogoutRequestContext> createLogoutRequests​(java.lang.String ticketId, org.apereo.cas.authentication.principal.WebApplicationService selectedService, org.apereo.cas.services.RegisteredService registeredService, java.util.Collection<org.apereo.cas.logout.slo.SingleLogoutUrl> logoutUrls, org.apereo.cas.logout.SingleLogoutExecutionRequest context)
      Create logout requests collection.
      org.apereo.cas.logout.slo.SingleLogoutMessage createSingleLogoutMessage​(org.apereo.cas.logout.slo.SingleLogoutRequestContext logoutRequest)  
      protected LogoutHttpMessage getLogoutHttpMessageToSend​(org.apereo.cas.logout.slo.SingleLogoutRequestContext request, org.apereo.cas.logout.slo.SingleLogoutMessage logoutMessage)
      Gets logout http message to send.
      java.util.Collection<org.apereo.cas.logout.slo.SingleLogoutRequestContext> handle​(org.apereo.cas.authentication.principal.WebApplicationService singleLogoutService, java.lang.String ticketId, org.apereo.cas.logout.SingleLogoutExecutionRequest context)  
      boolean performBackChannelLogout​(org.apereo.cas.logout.slo.SingleLogoutRequestContext request)  
      protected boolean sendMessageToEndpoint​(LogoutHttpMessage msg, org.apereo.cas.logout.slo.SingleLogoutRequestContext request, org.apereo.cas.logout.slo.SingleLogoutMessage logoutMessage)
      Send message to endpoint.
      protected boolean sendSingleLogoutMessage​(org.apereo.cas.logout.slo.SingleLogoutRequestContext request, org.apereo.cas.logout.slo.SingleLogoutMessage logoutMessage)
      Send single logout message.
      boolean supports​(org.apereo.cas.logout.SingleLogoutExecutionRequest context, org.apereo.cas.authentication.principal.WebApplicationService singleLogoutService)  
      protected boolean supportsInternal​(org.apereo.cas.authentication.principal.WebApplicationService singleLogoutService, org.apereo.cas.services.RegisteredService registeredService, org.apereo.cas.logout.SingleLogoutExecutionRequest context)
      Supports internal.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
      • Methods inherited from interface org.apereo.cas.logout.slo.SingleLogoutServiceMessageHandler

        getName, getOrder
    • Constructor Detail

      • BaseSingleLogoutServiceMessageHandler

        public BaseSingleLogoutServiceMessageHandler()
    • Method Detail

      • handle

        public java.util.Collection<org.apereo.cas.logout.slo.SingleLogoutRequestContext> handle​(org.apereo.cas.authentication.principal.WebApplicationService singleLogoutService,
                                                                                                 java.lang.String ticketId,
                                                                                                 org.apereo.cas.logout.SingleLogoutExecutionRequest context)
        Specified by:
        handle in interface org.apereo.cas.logout.slo.SingleLogoutServiceMessageHandler
      • supports

        public boolean supports​(org.apereo.cas.logout.SingleLogoutExecutionRequest context,
                                org.apereo.cas.authentication.principal.WebApplicationService singleLogoutService)
        Specified by:
        supports in interface org.apereo.cas.logout.slo.SingleLogoutServiceMessageHandler
      • performBackChannelLogout

        public boolean performBackChannelLogout​(org.apereo.cas.logout.slo.SingleLogoutRequestContext request)
        Specified by:
        performBackChannelLogout in interface org.apereo.cas.logout.slo.SingleLogoutServiceMessageHandler
      • createSingleLogoutMessage

        public org.apereo.cas.logout.slo.SingleLogoutMessage createSingleLogoutMessage​(org.apereo.cas.logout.slo.SingleLogoutRequestContext logoutRequest)
        Specified by:
        createSingleLogoutMessage in interface org.apereo.cas.logout.slo.SingleLogoutServiceMessageHandler
      • supportsInternal

        protected boolean supportsInternal​(org.apereo.cas.authentication.principal.WebApplicationService singleLogoutService,
                                           org.apereo.cas.services.RegisteredService registeredService,
                                           org.apereo.cas.logout.SingleLogoutExecutionRequest context)
        Supports internal.
        Parameters:
        singleLogoutService - the single logout service
        registeredService - the registered service
        context - the context
        Returns:
        true /false
      • createLogoutRequests

        protected java.util.Collection<org.apereo.cas.logout.slo.SingleLogoutRequestContext> createLogoutRequests​(java.lang.String ticketId,
                                                                                                                  org.apereo.cas.authentication.principal.WebApplicationService selectedService,
                                                                                                                  org.apereo.cas.services.RegisteredService registeredService,
                                                                                                                  java.util.Collection<org.apereo.cas.logout.slo.SingleLogoutUrl> logoutUrls,
                                                                                                                  org.apereo.cas.logout.SingleLogoutExecutionRequest context)
        Create logout requests collection.
        Parameters:
        ticketId - the ticket id
        selectedService - the selected service
        registeredService - the registered service
        logoutUrls - the logout urls
        context - the context
        Returns:
        the collection
      • createLogoutRequest

        protected org.apereo.cas.logout.slo.SingleLogoutRequestContext createLogoutRequest​(java.lang.String ticketId,
                                                                                           org.apereo.cas.authentication.principal.WebApplicationService selectedService,
                                                                                           org.apereo.cas.services.RegisteredService registeredService,
                                                                                           org.apereo.cas.logout.slo.SingleLogoutUrl logoutUrl,
                                                                                           org.apereo.cas.logout.SingleLogoutExecutionRequest context)
        Create logout request logout request.
        Parameters:
        ticketId - the ticket id
        selectedService - the selected service
        registeredService - the registered service
        logoutUrl - the logout url
        context - the context
        Returns:
        the logout request
      • sendSingleLogoutMessage

        protected boolean sendSingleLogoutMessage​(org.apereo.cas.logout.slo.SingleLogoutRequestContext request,
                                                  org.apereo.cas.logout.slo.SingleLogoutMessage logoutMessage)
        Send single logout message.
        Parameters:
        request - the request
        logoutMessage - the logout request
        Returns:
        true if the message was successfully sent.
      • sendMessageToEndpoint

        protected boolean sendMessageToEndpoint​(LogoutHttpMessage msg,
                                                org.apereo.cas.logout.slo.SingleLogoutRequestContext request,
                                                org.apereo.cas.logout.slo.SingleLogoutMessage logoutMessage)
        Send message to endpoint.
        Parameters:
        msg - the msg
        request - the request
        logoutMessage - the logout message
        Returns:
        true/false
      • getLogoutHttpMessageToSend

        protected LogoutHttpMessage getLogoutHttpMessageToSend​(org.apereo.cas.logout.slo.SingleLogoutRequestContext request,
                                                               org.apereo.cas.logout.slo.SingleLogoutMessage logoutMessage)
        Gets logout http message to send.
        Parameters:
        request - the request
        logoutMessage - the logout message
        Returns:
        the logout http message to send