Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[DOCS-8012] Update configuration of encoded slashes for Enterprise Viewer 4.0 #1617

Merged
merged 1 commit into from
Feb 11, 2025
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
28 changes: 12 additions & 16 deletions enterprise-viewer/latest/install/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -542,27 +542,13 @@ This section walks through how to install the web applications on a separate Tom

You'll find the WAR file in the `Web Applications` folder of the `alfresco-enterprise-viewer-package` zip.

3. Configure Tomcat for shared classpath loader as well as encoded slashes (if not already configured in the Content Accelerator installation):
3. Configure Tomcat for shared classpath loader (if not already configured in the Content Accelerator installation):

Edit the `TOMCAT_HOME/conf/catalina.properties` file and enable the `shared.loader` by adding the following line (if not already there):

`shared.loader=${catalina.base}/shared/classes,${catalina.base}/shared/lib/*.jar`

ACA has some routes that are formatted like:

```text
/hpi/{aca-module}/{object-id}
```

In the above case, the object ID is URL encoded. This means that forward slashes in the object ID are URL encoded to `%2F`. By default, Tomcat does not serve any URLs with a URL encoded forward (or back) slash.

To work around the issue, edit the `TOMCAT_HOME/conf/catalina.properties` file and add the following line (if not already there):

```java
org.apache.tomcat.util.buf.UDecoder.ALLOW_ENCODED_SLASH=true
```

4. (If not already configured in the ACA install) - Configure Tomcat ports in the `TOMCAT_HOME/conf/server.xml`:
4. (If not already configured in the ACA install) - Configure Tomcat ports as well as encoded slashes in the `TOMCAT_HOME/conf/server.xml`:

Configure the connector, server, and redirect ports to not conflict with Alfresco Tomcat’s (example below):

Expand All @@ -572,6 +558,16 @@ This section walks through how to install the web applications on a separate Tom

Note that you will need to ensure that the port chosen (i.e. `9090`) is open to the end user.

ACA has some routes that are formatted like:

```text
/hpi/{aca-module}/{object-id}
```

In the above case, the object ID is URL encoded. This means that forward slashes in the object ID are URL encoded to `%2F`. By default, Tomcat does not serve any URLs with a URL encoded forward (or back) slash.

To work around this issue, add `encodedSolidusHandling="decode"` to your `server.xml` file.

5. (If not already configured in the ACA install) - Create a `classes` directory:

Create the path `TOMCAT_HOME/shared/classes`, if it does not already exist.
Expand Down