| Client Certificate Authentication Sample Application |
Client Certificate Authentication Sample Application
This document describes how to use the Client Certificate Authentication sample application with Sun Java System Web Server.This sample application document contains the following sections:
- Overview
- Compiling and Assembling the Sample Application
- Deploying the Sample Application
- Running the Sample Application
- Troubleshooting
Overview
The Client Certificate Authentication sample application is a simple web application that demonstrates the Client Certificate Authentication feature.
Before running the sample, you must create and install the client certificate using the admin GUI. Please refer to the Sun Java System Web Server Administrator's Guide.
Compiling and Assembling the Sample Application
To compile and assemble the Client Certificate security web sample application:
- Compile and assemble the WAR file by changing to the source directory at install_root/samples/java/webapps/security/client-cert/src and running the ant command.
Note- Make sure that the necessary parameters for running the samples are specified in the install_root/samples/java/webapps/common.properties file.
- Deploy the application.
- After you have created the sample application from scratch, you can proceed to Deploying the Sample Application.
- (Optional.) Clean the web application project area.
Deploying the Sample Application
To deploy the Client Certificate security sample application:If you want to verify the registration of the application, proceed to Verifying Deployment. Otherwise, proceed to Running the Sample Application.
- Change to the source directory at install_root/samples/java/webapps/security/client-cert/src.
- Run the ant tool using the deploy task.
To verify the registration and deployment of the application, complete the following steps:
Change to the source directory at install_root/samples/java/webapps/security/client-cert/src.
Run the ant tool using the list_apps task.
# ant list_apps
The webapps-certificatebased-security module is listed as one of the components.
Running the Sample Application
You can run the application through the following URL:http://Sun_Java_System_Web_Server_hostname:port/webapps-certificatebased-security
The message "Welcome to our CERTIFICATE secure zone!" is displayed.
Undeploying the Sample Application
After successfully deploying and running the application, you might decide to undeploy it and remove the files. To undeploy the application, complete the following steps:
- Change to the source directory at install_root/samples/java/webapps/security/client-cert/src.
- Run the ant tool using the undeploy task.
Troubleshooting
- Close all browser instances before you try to log in again. If you are using Netscape, you must also close the email session. Otherwise, session information from the previous logins will be picked up to grant access for you.
- If you encounter problems when running the application, review the log files at instance_root/logs/errors to determine what went wrong.