The NAF Authentication Filter will proxy incoming requests to URLs under the path /rem/authproxy/ to a defined set of external NAF hosts. The choice of which hosts to map to is configured using the properties file ${rem.home}/sentinel.gaa.proxy-host-mapping.properties.

The default location for ${rem.home} is the rem_home directory in your Apache Tomcat installation, see UNRESOLVABLE BXREF: standalone-installation-of-the-naf-filter#set-up-tomcat[Set up Tomcat].

For example, if Tomcat is installed in /home/user/RhinoSDK/apache-tomcat-8.0.30, the filter will load the file /home/user/RhinoSDK/apache-tomcat-8.0.30/rem_home/sentinel.gaa.proxy-host-mapping.properties.

If the sentinel.gaa.proxy-host-mapping.properties file is not found, no mapping to external NAF hosts will be performed, and a 404 Not Found response will be returned to requests received under /rem/authproxy/.

Configuration Format

Example
# Map incoming requests to "gas.proxy" on port 8443 to internal "gas"
# host on port 443.
gas.proxy.opencloud.co.nz = gas.opencloud.co.nz:443
gas.proxy.opencloud.co.nz\:8443 = gas.opencloud.co.nz:443

Entries in the host mapping file are configured in the format incoming host name = destination host name. Port numbers may be specified, but if they appear before the = sign, they must be escaped with a \ character, as shown in the example. Lines beginning with # character denote comments, and are ignored.

Request Processing

The NAF Authentication Filter looks at incoming proxying requests, and examines the Host HTTP header. It then looks for a matching value on the left hand side of the = symbol of each configuration line. If it finds one, then it will proxy the request to the value found on the right hand side.

If no match is found, the NAF Authentication Filter will return a 404 Not found response to the client.

Note Some clients will supply a port number in their Host header, and some will not. It’s advisable to supply both variants in the mapping configuration file, as shown in the example.

Modifying configuration

Changes to this file take effect when Tomcat is restarted.

Previous page Next page