Licensed to the Apache Software Foundation (ASF) under one or more contributor license agreements. See the NOTICE file distributed with this work for additional information regarding copyright ownership. The ASF licenses this file to you under the Apache License, Version 2.0 (the “License”); you may not use this file except in compliance with the License. You may obtain a copy of the License at

 http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an “AS IS” BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.

README-QUICKSTART for Apache Fortress Web

  • Version 2.0.0-RC1

Table of Contents

  • Document Overview
  • SECTION 1. Prerequisites
  • SECTION 2. Configure Tomcat and Deploy Fortress Web
  • SECTION 3. Load Sample Security Policy
  • SECTION 4. Test

Document Overview

This document contains instructions to deploy a pre-built Fortress Web instance to Apache Tomcat.


SECTION 1. Prerequisites

Minimum software requirements:


SECTION 2. Configure Tomcat and Deploy Fortress Web

Set the java system properties in tomcat with the target ldap server's coordinates.

  1. Edit the startup script for Tomcat

  2. Set the java opts

a. For OpenLDAP:

JAVA_OPTS="-Dversion=2.0.0-RC1 -Dfortress.admin.user=cn=Manager,dc=example,dc=com -Dfortress.admin.pw=secret -Dfortress.config.root=ou=Config,dc=example,dc=com"

b. For ApacheDS:

JAVA_OPTS="$JAVA_OPTS -Dfortress.admin.user=uid=admin,ou=system -Dfortress.admin.pw=secret -Dfortress.config.root=ou=Config,dc=example,dc=com -Dfortress.port=10389"
  1. Verify these settings match your target LDAP server.

  2. Download the fortress realm proxy jar into tomcat/lib folder:

wget http://repo.maven.apache.org/maven2/org/apache/directory/fortress/fortress-realm-proxy/2.0.0-RC1/fortress-realm-proxy-2.0.0-RC1.jar -P $TOMCAT_HOME/lib

where TOMCAT_HOME matches your target env.

  1. Download the fortress web war into tomcat/webapps folder:
wget http://repo.maven.apache.org/maven2/org/apache/directory/fortress/fortress-web/2.0.0-RC1/fortress-web-2.0.0-RC1.war -P $TOMCAT_HOME/webapps

where TOMCAT_HOME matches your target env.

  1. Restart tomcat for new settings to take effect.

SECTION 3. Load Sample Security Policy

From the Fortress Core package perform the following steps:

  1. Download the fortress web sample security policy from git:
wget https://github.com/apache/directory-fortress-commander/blob/master/src/main/resources/FortressWebDemoUsers.xml -P ldap/setup
  1. Run maven install with -Dload.file file:
mvn install -Dload.file=ldap/setup/FortressWebDemoUsers.xml

Note: This step must be completed before tests can be successfully run.


SECTION 4. Test

  1. Open browser and test (creds: test/password):
http://hostname:8080/fortress-web
  1. Click on the links, to pull up various views on the data stored in the directory.

  2. Run the Selenium Web driver integration tests with Firefox (default):

mvn test -Dtest=FortressWebSeleniumITCase
  1. Run the tests using Chrome:
mvn test -Dtest=FortressWebSeleniumITCase -Dweb.driver=chrome

Note: The Selenium tests require that:

  • Either Firefox or Chrome installed to target machine.
  • FORTRESS_CORE_HOME/FortressJUnitTest successfully run. This will load some test data to grind on.
  • FortressWebDemoUsers policy loaded into target LDAP server.

END OF README-QUICKSTART