org.apache.shindig.auth
Interface SecurityToken

All Known Implementing Classes:
AbstractSecurityToken, AnonymousSecurityToken, BasicSecurityToken, BlobCrypterSecurityToken, ForwardingSecurityToken

public interface SecurityToken

An abstract representation of a signing token. Use in conjunction with @code SecurityTokenCodec.


Method Summary
 String getActiveUrl()
           
 String getAppId()
           
 String getAppUrl()
           
 String getAuthenticationMode()
           
 String getContainer()
           
 String getDomain()
           
 Long getExpiresAt()
           
 long getModuleId()
           
 String getOwnerId()
           
 String getTrustedJson()
           
 String getUpdatedToken()
           
 String getViewerId()
           
 boolean isAnonymous()
           
 boolean isExpired()
           
 

Method Detail

getOwnerId

String getOwnerId()
Returns:
the owner from the token, or null if there is none.

getViewerId

String getViewerId()
Returns:
the viewer from the token, or null if there is none.

getAppId

String getAppId()
Returns:
the application id from the token, or null if there is none.

getDomain

String getDomain()
Returns:
the domain from the token, or null if there is none.

getContainer

String getContainer()
Returns:
The container.

getAppUrl

String getAppUrl()
Returns:
the URL of the application

getModuleId

long getModuleId()
Returns:
the module ID of the application

getExpiresAt

Long getExpiresAt()
Returns:
the timestamp that this token expires or null if unknown or indeterminate

isExpired

boolean isExpired()
Returns:
true if the token is no longer valid

getUpdatedToken

String getUpdatedToken()
Returns:
an updated version of the token to return to the gadget, or null if there is no need to update the token.

getAuthenticationMode

String getAuthenticationMode()
Returns:
the authentication mechanism used to generate this security token
See Also:
AuthenticationMode

getTrustedJson

String getTrustedJson()
Returns:
a string formatted JSON object from the container, or null if there is no JSON from the container.

isAnonymous

boolean isAnonymous()
Returns:
true if the token is for an anonymous viewer/owner

getActiveUrl

String getActiveUrl()
Returns:
the URL being used by the current request The returned URL must contain at least protocol, host, and port. The returned URL may contain path or query parameters.
Throws:
UnsupportedOperationException - if the URL is not available.


Copyright © 2007-2012. All Rights Reserved.