Oracle iPlanet Web Proxy Server 4.0.14 Configuration File Reference

Filter

The Filter directive runs an external command and then pipes the data through the external command before processing that data in the proxy by using the pre-filter function.

Syntax

Filter fn="pre-filter" path="/your/filter/prog"

The Filter directive performs these tasks:

  1. Runs the program /your/filter/prog as a separate process.

  2. Establishes pipes between the proxy and the external program.

  3. Writes the response data from the remote server to the stdin of the external program.

  4. Reads the stdout of the program as if it were the response generated by the server.

    This process is equivalent to this command:

    Filter fn="pre-filter" path="/your/filter/prog" headers="stdin"

    The following Filter functions are described in detail in this section:

filter-ct

Applicable in Filter-class directives.

filter-ct can be used to block response content that matches a certain MIME type.

Parameters

The following table describes the parameter for the filter-ct function.

Table 5–134 filter-ct Parameters

Parameter  

Description  

regexp

Regular expression of the mime type to be filtered. 

Example


Filter fn="filter-ct" regexp="(application/octet-stream)"

filter-html

Applicable in Filter-class directives.

filter-html can be used to filter out HTML tags from the response content before sending it to the client.

Parameters

The following table describes parameters for the filter-html function.

Table 5–135 filter-html Parameters

Parameter  

Description  

start

HTML start tag 

end

HTML end tag 

Example


Filter fn="filter-html" start="APPLET" end="APPLET"

pre-filter

Applicable in Filter-class directives.

pre-filter is used to run external filter programs before returning response content to the client.

Parameters

The following table describes the parameter for the pre-filter function.

Table 5–136 pre-filter Parameters

Parameter  

Description  

path

absolute path to external filter program. 

Example

Filter fn="pre-filter" path="/your/filter/prog"