Class SingleSignOnSessionKey

java.lang.Object
org.apache.catalina.authenticator.SingleSignOnSessionKey
All Implemented Interfaces:
Serializable

public class SingleSignOnSessionKey extends Object implements Serializable
Key used by SSO to identify a session. This key is used rather than the actual session to facilitate the replication of the SSO information across a cluster where replicating the entire session would generate significant, unnecessary overhead.
See Also:
  • Constructor Details

    • SingleSignOnSessionKey

      public SingleSignOnSessionKey(Session session)
      Creates a session key from the given session, using the session's current ID.
      Parameters:
      session - the session from which to extract the key information
    • SingleSignOnSessionKey

      public SingleSignOnSessionKey(Session session, String sessionId)
      Creates a session key using the given session context and an explicit session ID.
      Parameters:
      session - the session from which to extract context and host information
      sessionId - the session ID to use for this key
  • Method Details

    • getSessionId

      public String getSessionId()
      Returns the session ID associated with this key.
      Returns:
      the session ID
    • getContextName

      public String getContextName()
      Returns the context name associated with this key.
      Returns:
      the context name
    • getHostName

      public String getHostName()
      Returns the host name associated with this key.
      Returns:
      the host name
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class Object
    • equals

      public boolean equals(Object obj)
      Overrides:
      equals in class Object
    • toString

      public String toString()
      Overrides:
      toString in class Object