Class SessionManager

java.lang.Object
com.pingidentity.sdk.session.SessionManager

public class SessionManager extends Object
A utility class for managing sessions.
Since:
12.1
  • Constructor Summary

    Constructors
    Constructor
    Description
     
  • Method Summary

    Modifier and Type
    Method
    Description
    void
    Revokes a session identified by the given SRI (Session Reference Identifier).
    void
    Revokes all sessions for the user identified by the unique user key.
    void
    revokeOtherSessionsFor(String uniqueUserKey, javax.servlet.http.HttpServletRequest req, javax.servlet.http.HttpServletResponse resp)
    Revokes all sessions for the user identified by the unique user key, except for the current session.

    Methods inherited from class java.lang.Object

    equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Constructor Details

    • SessionManager

      public SessionManager()
  • Method Details

    • revokeAllSessionsFor

      public void revokeAllSessionsFor(String uniqueUserKey)
      Revokes all sessions for the user identified by the unique user key. Sessions including the current session will be revoked.
      Parameters:
      uniqueUserKey - the unique user key to revoke sessions for.
    • revokeOtherSessionsFor

      public void revokeOtherSessionsFor(String uniqueUserKey, javax.servlet.http.HttpServletRequest req, javax.servlet.http.HttpServletResponse resp)
      Revokes all sessions for the user identified by the unique user key, except for the current session.
      Parameters:
      uniqueUserKey - the unique user key to revoke sessions for.
      req - the HttpServletRequest passed into the adapters IdpAuthenticationAdapter#lookupAuthN method
      resp - the HttpServletResponse passed into the adapters IdpAuthenticationAdapter#lookupAuthN method
    • revoke

      public void revoke(String sri)
      Revokes a session identified by the given SRI (Session Reference Identifier).
      Parameters:
      sri - - The Session Reference Identifier to be revoked.