

Java SDK Guide › Using the CA SiteMinder® Federation Standalone Java SDK › Java SDK Sample Application Deployment
Java SDK Sample Application Deployment
Deployment of the Java SDK sample application requires installing Tomcat and CA SiteMinder® Federation Standalone at the relying party.
Follow these steps:
- Install the Java SDK package at any preferred location.
- Set the environment variable FEDSDKROOT to the installation Directory of Java SDK.
Note: The value of FEDSDKROOT points to the location of the SDK directory. Example: C:\Program Files\CA\Federation Standalone\sdk.
This environment variable is set automatically on Windows, but must be exported manually on UNIX platforms.
- Install Tomcat 5.0 and set the TOMCAT_HOME environment variable to point to the Tomcat root folder.
Note: Tomcat must be installed on a different system from the one CA SiteMinder® Federation Standalone is installed on.
- Deploy FEDSDKROOT\sample\javasdk/war to the Web server by copying it to the TOMCAT_HOME\webapps\ folder.
- Start the Tomcat server.
- Try accessing the link “http://<FQDN of Tomcat Host>:<port num>/” to determine whether Tomcat is up and running.
- If you are using the legacy (FEDPROFILE) cookie, update fedsample.properties in the TOMCAT_HOME\webapps\javasdk\WEB-INF\classes folder as follows:
- RedirectMode is the value of redirect mode. Use LEGACY for the legacy cookie.
Default value: OPEN
- CookieZone is the value of CookieZone as set in the CA SiteMinder® Federation Standalone Administrative UI in the Deployment Settings dialog.
Default value: FED
- EncryptionPassword is the value of the password as set in the CA SiteMinder® Federation Standalone Administrative UI in the Deployment Settings dialog.
Default value: blank
- ProviderId is the value of provider identifier as set in the Create Partnership dialog
Default value: blank
- CharsetEncoding is the Charset Encoding of the response that is displayed on the screen.
Default value: UTF-8
- ShowAttributeMap specifies whether the data in the Assertion Mapis displayed. The value is no when data in the Assertion Map is not to be displayed/ The value is yes when all the data in the Assertion Map is to be displayed. This value is configured in the Create Partnership dialog. If the value is set to no, only the list of attributes mentioned in SpSideAttributeKey parameter are displayed.
Default value: no
- SpSideAttributeKey specifies the attribute or attributes (comma separated) from the request that are displayed.
Default value: blank
- If you are using the open format cookie, update fedsample.properties in the TOMCAT_HOME\webapps\javasdk\WEB-INF\classes folder as follows:
- RedirectMode is the value redirect mode. Use OPEN for the open format cookie.
- CookieDomain is the value of cookie domain as set in the Create Partnership dialog.
- CookieName is the value of the cookie name as set in the Create Partnership dialog.
- CryptoInstance is the value of the encryption transformation, which is configured in the Create Partnership dialog.
- UseHmac specifies the value of the Enable HMAC check box as set in the Create Partnership dialog. Use the value no when the check box is not checked, or the value yes when the check box is checked.
- ShowAttributeMap specifies whether the data in the Assertion Mapis displayed. The value is no when data in the Assertion Map is not to be displayed/ The value is yes when all the data in the Assertion Map is to be displayed. This value is configured in the Create Partnership dialog. If the value is set to no, only the list of attributes mentioned in SpSideAttributeKey parameter are displayed.
- SpSideAttributeKey specifies the attribute or attributes (comma separated) from the request that are displayed.
- CharsetEncoding specifies the charset encoding of the response that is displayed on the screen.
- The following parameters must be updated if you are testing light weight provisioning:
- EnableProvisioningTest specifies whether light weight provisioning is enabled. Use the value no if provisioning is not enabled. Use the value yes to enable testing light-weight provisioning.
- AssertionConsumerUrl specifies the supply Assertion Consumer URL.
- UDType specifies odbc or ldap, depending on the User Directory type. The connection parameters associated with the type must be specified.
- Update the sdkloggingconfig.properties file to enable logging. Logging is disabled by default.
- Install CA SiteMinder® Federation Standalone at the relying party of a Federation partnership and define an asserting party-relying party partnership.
- Select appropriate Redirect mode.
- Specify the Target URL of the partnership. Enter one of the following:
- The URL of the SDK Sample App, such as http://<FQDN of target machine>:<Tomcat port>/javasdk/SpSideAttributeServlet.
- The url of the relying party, http://<FQDN of SP>:CA Portal and in proxyrules.xml(location: %FEDROOT%\ proxy-engine\conf\proxyrules.xml make the entry http://<FQDN of target machine>:<Tomcat port>/javasdk/SpSideAttributeServlet.
The sample application is now deployed and ready to run.
Java SDK Sample Application Execution
After you have installed Tomcat and CA SiteMinder® Federation Standalone, you can run the Java SDK sample application.
To run the Java SDK sample application
- Start the Tomcat Server where the sample application is deployed:
- On Windows, use the services control panel.
- On UNIX, use the startup script of Tomcat.
- Run the configured federation transaction to redirect to the SDK Sample Application.
The sample application decodes the cookie and displays the user identity information.
Java SDK Sample Application Customization
The sample application can be modified using build.bat or build.sh scripts to regenerate the fedsdksample.jar.
To customize the sample Java application
- Modify SpSideServlet or SpSideAttributeServlet.java as desired.
- Verify that the JDK is installed and JAVA_HOME is set appropriately for your JDK installation.
- Run build.bat (Windows) or build.sh (UNIX) to build the fedsdksample.jar file.
The customized version of the sample application is ready to run.
Copyright © 2014 CA.
All rights reserved.
 
|
|