Class SecurityTokenManagerImpl
- java.lang.Object
-
- com.sun.identity.liberty.ws.security.SecurityTokenManagerImpl
-
- All Implemented Interfaces:
SecurityTokenManagerIF,Remote
public class SecurityTokenManagerImpl extends Object implements SecurityTokenManagerIF
This class implements theSecurityTokenManagerIF.
-
-
Field Summary
Fields Modifier and Type Field Description protected static booleanisLocal
-
Constructor Summary
Constructors Constructor Description SecurityTokenManagerImpl()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidcheckForLocal()Checks if the service is available locally.StringgetSAMLAuthenticationToken(String senderIdentity)Returns the SAML Authentication Token.StringgetSAMLAuthorizationToken(String senderIdentity, String invocatorSession, String resourceID, boolean encryptedID, boolean includeAuthN, boolean includeResourceAccessStatement, String recipientProviderID)Returns the SAML Authorization Token.StringgetX509CertificateToken()Returns the Certificate Token.voidinitialization(String sessionID)Initializes the SecurityTokenManager.voidsetCertificate(String cert, boolean alias)Sets the Certificate.
-
-
-
Method Detail
-
initialization
public void initialization(String sessionID) throws SecurityTokenException
Initializes the SecurityTokenManager.- Specified by:
initializationin interfaceSecurityTokenManagerIF- Parameters:
sessionID- the session id.- Throws:
SecurityTokenException- if there is an error.
-
setCertificate
public void setCertificate(String cert, boolean alias) throws SecurityTokenException
Sets the Certificate.- Specified by:
setCertificatein interfaceSecurityTokenManagerIF- Parameters:
cert- the Certificate String.alias- if true then Certificate Alias will be set.- Throws:
SecurityTokenException- if there is an error.
-
checkForLocal
public void checkForLocal()
Checks if the service is available locally.- Specified by:
checkForLocalin interfaceSecurityTokenManagerIF
-
getX509CertificateToken
public String getX509CertificateToken() throws SecurityTokenException
Returns the Certificate Token.- Specified by:
getX509CertificateTokenin interfaceSecurityTokenManagerIF- Returns:
- the Certification Token String.
- Throws:
SecurityTokenException- if there is an error.
-
getSAMLAuthenticationToken
public String getSAMLAuthenticationToken(String senderIdentity) throws SecurityTokenException, SAMLException
Returns the SAML Authentication Token.- Specified by:
getSAMLAuthenticationTokenin interfaceSecurityTokenManagerIF- Parameters:
senderIdentity- the sender's identity.- Returns:
- the SAML Authentication Token String.
- Throws:
SecurityTokenException- if there is an error.SAMLException- if there is an error.
-
getSAMLAuthorizationToken
public String getSAMLAuthorizationToken(String senderIdentity, String invocatorSession, String resourceID, boolean encryptedID, boolean includeAuthN, boolean includeResourceAccessStatement, String recipientProviderID) throws SecurityTokenException, SAMLException
Returns the SAML Authorization Token.- Specified by:
getSAMLAuthorizationTokenin interfaceSecurityTokenManagerIF- Parameters:
senderIdentity- the identity of the sender.invocatorSession- the session identifierresourceID- the resource Identifier.encryptedID- boolean value to determine if the identifier is encrypted.includeAuthN- boolean value to deteremine if the authentication information should be included.includeResourceAccessStatement- if true, aResourceAccessStatementwill be included in the Assertion (forAuthorizeRequesterdirective). If false, aSessionContextStatementwill be included i the Assertion (forAuthenticationSessionContextdirective). In the case when bothAuthorizeRequesterAuthenticationSessionContext directive need to be handled, use "true" as parameter here since theSessionContextwill always be included in theResourceAccessStatement.recipientProviderID- recipient's provider ID.- Returns:
- the SAML Authentication Token String.
- Throws:
SecurityTokenException- if there is an error.SAMLException- if there is an error.
-
-