The Common Access Card is the standard identification for active duty uniformed service
personnel, Selected Reserve, DoD civilian employees, and eligible contractor personnel in the United
States. It is used to enable physical access to buildings and controlled spaces, and provides access
to DoD computer networks and systems. The CAC can be used for access into computers and networks
that are equipped with various smart card readers. When it is inserted into the reader, the device
asks the user for a PIN. This task helps you set up AppScan® Enterprise to allow CAC authentication over LDAP so that users can log in to AppScan® Enterprise without providing a user name and
password.
Before you begin
During installation and configuration, make sure that you select LDAP
authentication in the Authentication Mechanism screen of the
configuration wizard.Note:
- If CAC was enabled before you apply AppScan Enterprise v9.0.3.1 iFix1, disable it before
you run the configuration wizard during the iFix1 installation. Then, you can re-enable CAC and log
in to AppScan Enterprise and complete the following task.
- No user actions are required to enable authentication by using Microsoft™ Edge. For Mozilla Firefox users,
your organization might have specific instructions for enabling CAC in the
browser.
Procedure
- Install AppScan® Enterprise
by using an LDAP server that contains the CAC users.
-
Make sure that the Product Administrator for AppScan Enterprise is also a CAC
user.
-
Log in to AppScan Enterprise as an administrator.
-
Go to , and select Default User from the list.
-
On the Edit User page, select Administrator from the
Type list. Finish configuring the user properties, click
Save, and then log out of AppScan Enterprise.
- Import the full certificate authority chain into the truststore.
- Create a keystore file or use your existing keystore.
Note: To generate a keystore, you can use keytool. AppScan Enterprise includes a keytool, and can be
downloaded from
<install-dir>\AppScan Enterprise\Liberty\jre\bin\
Use this command:
keytool -genkey -alias mydomain.com -keyalg RSA -keystore MyKeystore.jks
-keysize 2048 - keypass storePassword
- Import the full CA certificate chain that signed the
client certificates that exist on the CAC cards.
Note: You can use a Java™ keytool to import certificate to
defaultTrustStore. AppScan Enterprise includes
a keytool, and can be downloaded from
<install-dir>\AppScan
Enterprise\Liberty\jre\bin\. Update the parameters in
the following command with your specific values:
<path-to-certificate>, <install-dir>, <ase
instance name>, <truststore-password> . If any paths
contain spaces, enclose them in double quotes, for example:
"C:\Program Files (x86)\HCL\AppScan
Enterprise\Liberty\usr\servers\ase\resources\security\cacerts".
-
If the certificate has a customized name, update the command to reflect
the custom name. To import the certificate into the truststore, run the
following command in a Command Prompt window:
keytool -importkeystore -srckeystore <path-to-certificate>\certificate.pfx -destkeystore <install-dir>\AppScan Enterprise\Liberty\usr\servers\<ase instance name>\resources\security\cacerts -srcstoretype JKS -deststoretype PKCS12 -deststorepass <truststore-password>
-
If
defaultTrustStore that is available at
location:
<install-dir>\AppScan Enterprise\Liberty\usr\servers\<ase instance name>\resources\security\cacerts
is
used as trustStore, then re-running the configuration wizard will
require certificate chain to be reimported. If this must be avoided,
then before running the configuration wizard import the certificate
chain into the trustStore file, available at
location:
<install-dir>\AppScan Enterprise\Liberty\templates\servers\defaultServer\resources\security\cacerts
- Modify the web.xml file to replace
Form-Based Authentication with Client-Certificate Authentication.
Note: Make a backup of the web.xml file before you modify it.
- Stop the HCL AppScan Enterprise Server service.
- Locate the AppScanServerWeb.war file
of your AppScan® Enterprise
instance that is in: <install-dir>\AppScan Enterprise\Liberty\usr\servers\ase\apps\AppScanServerWeb.war.
- Rename the AppScanServerWeb.war file
to AppScanServerWeb.zip and navigate into the WEB-INF folder
to retrieve the web.xml file for editing.
- Replace the following section of the file:
<login-config>
<auth-method>FORM</auth-method>
<form-login-config>
<form-login-page>/pages/Login.jsp</form-login-page>
<form-error-page>/pages/Login.jsp?Retry=True</form-error-page>
</form-login-config>
</login-config>
with
<login-config>
<auth-method>CLIENT-CERT</auth-method>
</login-config>
- Save the file and rename AppScanServerWeb.zip to AppScanServerWeb.war.
- Modify the server.xml file to enforce
SSL protocol, set the trust keystore and set the LDAP certificate
mapping.
- Locate the server.xml file at <install-dir>\AppScan
Enterprise\Liberty\usr\servers\<ase instance name>\server.xml.
- Make sure that the
<featureManager> section
contains <feature>ssl-1.0</feature>.
- Locate the
<keystore> section of
the file and add this line: <keyStore id="cacTrustKeyStoreID"
password="store password" location="cacTrustKeyStore.jks" type='jks'
/>, where
- id is a string that uniquely identifies the keystore (use
any string)
- password is the password of the keystore (this value can
be stored in clear text or encoded form; use the securityUtility from
Liberty to encode the password)
- location is an absolute or relative path to the keystore
file (the relative path points to <install-dir>\AppScan
Enterprise\Liberty\usr\servers\<ase instance name>\resources\security\
- type is the type of the keystore. jks is
the default value.
-
Locate the
<ssl> section of the file, and make sure
that it includes <sslProtocol="TLSv1.2">.
- Add these attributes to
<ssl>
trustStoreRef="cacTrustKeyStoreID" where cacTrustKeyStoreID is
the ID of the keystore that was configured in the <keystore> section
of the file.
clientAuthenticationSupported="true"
The section might look like this example when you're done editing: <ssl
id="defaultSSLConfig" sslProtocol="TLSv1.2"
keyStoreRef="defaultKeyStore" trustStoreRef="defaultKeyStore"
clientAuthenticationSupported="true" />.
-
Locate the
<ldapRegistry> section of the file and add these
attributes:
One such certificateFilter can
be:
certificateFilter="uid=${SubjectCN}"
The
"uid" attribute in the LDAP record must match the SubjectCN
attribute of the certificate. If the "SubjectCN" of the certificate
is "admin", then the user name (uid) in the LDAP directory must be
"admin".
The following example shows an LDAP registry
configuration that uses IBM® Tivoli® Directory Server. The uid
attribute from the LDAP server match the SubjectCN attribute in the
certificates stored on the CAC card:
<ldapRegistry ldapType="IBM Tivoli Directory Server"
host="<<hostname>>"
port="<<Port no>>" sslEnabled="false" baseDN="o=IBM,c=US
"certificateMapMode="CERTIFICATE_FILTER"
certificateFilter="uid=${SubjectCN}">
<activedFilters userFilter="(objectclass=Person)"
userIdMap="*:uid"/> </ldapRegistry>
- Restart the HCL AppScan Enterprise Server service.
-
Log back in to AppScan Enterprise as an administrator with your CAC authentication.
-
Go to , and change the permissions for the default user back to whatever permissions you
want that role to have. (Typically, you would not want the default user to be an administrator, but
perhaps a Standard User instead).
-
After AppScan Enterprise is configured, there is no other way to create
the Administrator account for the CAC user, except by using a database query. If you did not
complete Step 2, follow these steps:
-
Log in to AppScan Enterprise with your CAC card, and check your permissions to see if you are
an Administrator.
-
If you are not an administrator, run this query against your AppScan Enterprise SQL Server
database:
select *from UserInfo.
-
Locate the CAC user in the query results and note their UserId.
-
Then, run this query:
Update UserInfo set UserTypeId=5, LicenseType=3,
EffectiveType=32768, where UserId is the ID of your CAC admin user.
-
Log out of AppScan Enterprise, and then log in again. You should now be an administrator.
Results
Users that use Common Access Cards are able to log in to AppScan® Enterprise without providing
a user name and password.