Configuring Apache 2 (Example)

Note: For a more complete description on how to build the Apache 2 module and Filter see: Installing the Filter

The dist package of mod_unblufilter provides a config directory containing a number of example configurations for various platforms.

The following example is ‘self-contained’. That is: With this configuration, all Apache 2 configurations required to run unblu via this apache server are included. In particular, this includes configuration of a reverse proxy path for /unblu requests, adding mod_unblufilter using the mod_filter Apache 2 module and the mod_unblufilter configuration itself.

Example Configuration

############################################################
# Configure reverse proxy to /unblu of collaboration server

<IfModule !mod_proxy.c>
LoadModule proxy_module modules/mod_proxy.so
<IfModule !mod_proxy_http.c> LoadModule proxy_http_module modules/mod_proxy_http.so
</IfModule>
</IfModule>

ProxyRequests Off

<Proxy *>
Order deny,allow
Allow from all
</Proxy>

ProxyPass /unblu/ http://unbluserver/unblu/
ProxyPassReverse /unblu/ http://unbluserver/unblu/
#############################################################
# Configure unblu
LoadModule unblufilter_module modules/mod_unblufiler.so 
UnbluModule On
UnbluServerUrl http://unbluserver/
UnbluConfigOrigin local
UnbluConfigDirectory /etc/httpd/unblu/unblu.conf
#############################################################
# Advanced Unblu Configuration
# the following settings are defaults - uncomment and adapt them
#UnbluPublicPathPrefix /unblu
#UnbluSystemPathPrefix /sys-unblu       
#UnbluServerAdminBackend rest/filterBackend
#UnbluDefaultCharset ISO-8859-1
#UnbluConfigOrigin local
#UnbluConfigDirectory /etc/httpd/unblu/unblu.conf
#UnbluConfigExpiration 3600
#UnbluMaxResponseSizeResource 100kb
#UnbluMaxResponseSizeInjection 10kb
#############################################################
# Add the filter module to the filter chain

<IfModule !mod_filter.c>
LoadModule filter_module modules/mod_filter.so
</IfModule>

# The following lines require filter_module to be active
# See http://httpd.apache.org/docs/2.1/mod/mod_filter.html
# for details about filters
# FilterProvider Syntax:
# FilterProvider filter-name provider-name  [req|resp|env]=dispatch match
# NOTE: do not change the provider-name (unblufilter) - it is hardcoded
# and connects this configuration to the filter module

FilterProvider unblufilter resp=Content-Type *

# FilterChain Syntax:
# FilterChain [+=-@!]filter-name ...
# NOTE: The @ before the filter-name ensures # that the filter is inserted at # the first position

FilterChain @unblufilter    
#############################################################

Configuration Parameter Description

Reverse proxy server

The following settings are generic and usually need no adaptation:

  • IfModule !mod_proxy.c: loads mod_proxy if not loaded already
  • IfModule !mod_proxy_http.c: loads mod_proxy_http if not loaded already
  • ProxyRequests: Configure this as a reverse proxy (thus set to ‘no’ to disable forward proxy capabilities).
  • Proxy section: configure access control to proxy (allow all).

The following two lines require adaptation: unbluserver must be replaced with the hostname plus port (if non-standard) of the backend collaboration server.

  • ProxyPass: configure /unblu requests to be proxied.
  • ProxyPassReverse: Make sure response headers are adapted to have a transparent reverse proxy unblu configuration.

The following settings are required and must be adapted accordingly:

  • LoadModule: load mod_unblufilter
  • UnbluServerUrl: hostname and path of the backend Collaboration Server or a proxy, where the server can be reached.

The following settings are commented out (in the provided example configuration) because they represent default values:

  • UnbluPublicPathPrefix: Must have a leading slash and otherwise match the setting of com.unblu.identifier.publicPathPrefixPattern in the unblu Collaboration Server ( unblu by default).
  • UnbluSystemPathPrefix: Must have a leading slash and otherwise match the setting of com.unblu.identifier.systemPathPrefixPattern in the unblu Collaboration Server ( sys-unblu by default).
  • UnbluServerAdminBackend: The URL of the admin backend to be used by the Apache 2 filter. Typically fixed to the default rest/filterBackend (unlikely to change).
  • UnbluConfigOrigin: Can be either local or remote (default).

If local, the configuration file must be located at UnbluConfigDirectory (UnbluConfigDirectory is the path and filename in this case).

Note: UnbluConfigExpiration is ignored when local is selected.

If remote, the configuration file will be downloaded from the remote Collaboration Server and stored in the directory given by UnbluConfigDirectory (which must be writable and readable in this case).

  • UnbluDefaultCharset: Character set used if none is specified in an http (text) response.
  • UnbluConfigDirectory: If UnbluConfigOrigin is set to remote, this is not required. If UnbluConfigOrigin is set to local, this must specify the path and filename of the configuration file.
  • UnbluConfigExpiration: Time, in seconds, until the downloaded configuration of the unblu Collaboration Server expires and must be re-downloaded. Ignored if UnbluConfigOrigin is set to local.

mod_filter configuration:

  • FilterProvider: mod_filter specific command to enable mod_unblufilter as a filter in Apache 2
  • FilterChain: Specifies where in the filter chain unblu is called. unblu must be called before any URL transformations are performed (such as URL encryption or decryption).
  • deployonprem

results matching ""

    No results matching ""