public interface TokenManager
Modifier and Type | Method and Description |
---|---|
void |
cancelToken(TokenContext context)
This method cancels a valid security token that was issued earlier.
|
TokenContext |
createTokenContext(java.lang.String protocol)
Creates a
TokenContext instance based on the protocol. |
TokenContext |
createTokenContext(java.lang.String protocol, boolean populateClaims)
Creates a
TokenContext instance based on the protocol and sets the derivable claims picked from the trust configurations if populateClaims is set. |
void |
issueToken(TokenContext context)
This method issues a security token based on the information provided via input context.
|
oracle.security.crypto.token.Token |
issueTrustToken(TokenContext context)
This method issues a security token based on the information provided via input context.
|
void |
renewToken(TokenContext context)
This method renews a valid security token that was issued earlier.
|
void |
validateToken(TokenContext context)
This method determines validity of a given security token.
|
TokenContext createTokenContext(java.lang.String protocol) throws TokenException
TokenContext
instance based on the protocol.protocol
- The protocol that will be used with the STS for token management operations.TokenContext
that contains token. specific information.TokenException
- This exception is thrown when token context creation fails. Exception message may contain diagnostic information.TokenContext createTokenContext(java.lang.String protocol, boolean populateClaims) throws TokenException
TokenContext
instance based on the protocol and sets the derivable claims picked from the trust configurations if populateClaims is set.protocol
- The protocol that will be used with the STS for token management operations. See TokenConfiguration
populateClaims
- if true, the following claims are set :
TokenContext
that contains token. specific information and the additional claims listed above if populateClaims is set.TokenException
- This exception is thrown when the protocol is incorrect or if populateClaims is set and there is an error while fetching the claims listed earliervoid issueToken(TokenContext context) throws TokenException
context
- Token context that contains token specific information.TokenException
- This exception is thrown when issue operation fails. Exception message may contain diagnostic information.void renewToken(TokenContext context) throws TokenException
context
- Token context that contains token related information.TokenException
- This exception is thrown when token cancel operation fails. Exception message may contain diagnostic information.void cancelToken(TokenContext context) throws TokenException
context
- Token context that contains token specific information.TokenException
- This exception is thrown when issue operation fails. Exception message may contain diagnostic information.void validateToken(TokenContext context) throws TokenException
context
- Token context that contains token specific information.TokenException
- This exception is thrown when token validate operation fails. Exception message may contain diagnostic information.oracle.security.crypto.token.Token issueTrustToken(TokenContext context) throws TokenException
Token
depending upon whether the token was of type : JWT , SAML1 or SAML2. This method should be used when an OSDT token is required.context
- The TokenContext that contains all the necessary token specific informationToken
TokenException
- This exception is thrown when issue operation fails. Exception message may contain diagnostic information.