Example: Enabling Java 2 security prior to J2EE application client run time initialization

To enable the Java 2 security prior to the Java 2 Platform Enterprise Edition (J2EE) application client run time initialization, set the com.ibm.websphere.client.applicationclient.archivedir system property. Perform the following steps:

  1. Set the system property to the directory where the Enterprise Archive (EAR) file is expanded, for example:

    -Dcom.ibm.websphere.client.applicationclient.archivedir=c:\myear1 (Windows systems)

    -Dcom.ibm.websphere.client.applicationclient.archivedir=/usr/mrear1 (UNIX systems)

  2. Set the java.security.policy system property to use the <WAS_HOME>/properties/client.policy file, for example:

    -Djava.security.policy=%WAS_HOME%\properties\client.policy (Windows systems)

    -Djava.security.policy=$WAS_HOME/properties/client.policy (UNIX systems)