|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--com.iplanet.sso.SSOTokenManager
The class SSOTokenManager
is a final
class
that provides interfaces to create and validate SSOToken
s.
It is a
singleton class; an instance of this class can be obtained by
calling SSOTokenManager.getInstance()
.
Having obtained an instance of SSOTokenManager
,
its methods can be called to create SSOToken
, get
SSOToken
given the SSOTokenID
in string
format, and to validate SSOToken
s.
Field Summary | |
static Debug |
debug
|
Method Summary | |
SSOToken |
createSSOToken(HttpServletRequest request)
Creates an SSOToken from HttpServletRequest |
SSOToken |
createSSOToken(java.security.Principal user,
java.lang.String password)
Creates an SSOToken after authenticating the principal with the given password. |
SSOToken |
createSSOToken(java.lang.String tokenId)
Creates an SSOToken from the SSOtoken ID. |
SSOToken |
createSSOToken(java.lang.String tokenId,
java.lang.String clientIP)
Creates an SSOToken from the SSOtoken ID. |
void |
destroyToken(SSOToken token)
Destroys an SSOToken. |
void |
destroyToken(SSOToken destroyer,
SSOToken destroyed)
Destroys an SSOToken. |
static SSOTokenManager |
getInstance()
Gets the singleton instance of SSOTokenManager. |
java.util.Set |
getValidSessions(SSOToken requester,
java.lang.String server)
Returns a list of SSOToken objects which correspond to valid Sessions accessible to requester. |
boolean |
isValidToken(SSOToken token)
Checks if an SSOToken is valid or not. |
void |
refreshSession(SSOToken token)
Refresh the Session corresponding to the SSOToken from the Session Server. |
void |
validateToken(SSOToken token)
Checks if the SSOToken is valid. |
Methods inherited from class java.lang.Object |
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
public static Debug debug
Method Detail |
public static SSOTokenManager getInstance() throws SSOException
SSOException
- if unable to get the singleton SSOTokenManager
instancepublic SSOToken createSSOToken(HttpServletRequest request) throws java.lang.UnsupportedOperationException, SSOException
request
- The HttpServletRequest object which contains the
session string.An
- SSOException is thrown if the SSOToken cannot be
created.public SSOToken createSSOToken(java.security.Principal user, java.lang.String password) throws java.lang.UnsupportedOperationException, SSOException
Principal
- representing a user or servicePassword
- the password supplied for the principalAn
- SSOException is thrown if the SSOToken cannot be
created.public SSOToken createSSOToken(java.lang.String tokenId) throws java.lang.UnsupportedOperationException, SSOException
String
- TokenID of the SSOTokenan
- SSOException is thrown if the SSOToken cannot be
created.
Note:-If you want to do Client's IP address validation for the SSOToken
then use creatSSOToken(String tokenid, String ClientIP) OR
createSSOToken(HttpServletRequest request).public SSOToken createSSOToken(java.lang.String tokenId, java.lang.String clientIP) throws java.lang.UnsupportedOperationException, SSOException
String
- TokenID of the SSOTokenString
- Client IP address. This must be the IP address of the
client/user who is accessing the application.an
- SSOException is thrown if the SSOToken cannot be
created.public boolean isValidToken(SSOToken token)
token
- The SSOToken object to be validated.public void validateToken(SSOToken token) throws SSOException
token
- The SSOToken object to be validated.an
- SSOException if the SSOToken is not valid.public void destroyToken(SSOToken token) throws SSOException
token
- The SSOToken object to be destroyed.an
- SSOException if there was an error while destroying
the token. If the session was destroyed already, no exception
will be thrown.public void refreshSession(SSOToken token) throws SSOException
ssoToken
- SSOTokenan
- SSOException if the session reached its maximum
session time, or the session was destroyed, or there was
an error while refreshing the session.public void destroyToken(SSOToken destroyer, SSOToken destroyed) throws SSOException
destroyer
- The SSOToken object used to authorize the operationdestroyed
- The SSOToken object to be destroyed.A
- SSOException is thrown if the there was an error during
communication with session service.public java.util.Set getValidSessions(SSOToken requester, java.lang.String server) throws SSOException
requester
- The SSOToken object used to authorize the operationserver
- The server for which the valid sessions are to be retrievedA
- SSOException is thrown if the there was an error during
communication with session service.
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |