com.sun.identity.saml.common
Class SAMLSiteID

java.lang.Object
  extended by com.sun.identity.saml.common.SAMLSiteID

public class SAMLSiteID
extends Object

This class is used to generate SAML Site ID.


Method Summary
static String generateID()
          Returns an ID String with length of SAMLConstants.ID_LENGTH.
static String generateSourceID(String siteURL)
          Returns SAML site ID based on siteURL, this will return a Base64 encoded SHA-1 digest.
static void main(String[] args)
          Obtains site ID based on the host name.
 

Method Detail

generateID

public static String generateID()
Returns an ID String with length of SAMLConstants.ID_LENGTH.

Returns:
ID String or null if it fails.

generateSourceID

public static String generateSourceID(String siteURL)
Returns SAML site ID based on siteURL, this will return a Base64 encoded SHA-1 digest.

Parameters:
siteURL - site URL for example: http://host.sun.com:58080.
Returns:
Base64 encoded site ID

main

public static void main(String[] args)
Obtains site ID based on the host name. This method will print out site ID to the standard output.

Parameters:
args - host name