In the IP Address field, enter the IP address, either as an IP version 4 or IP Click the Enable check box to enable the rule; deselect the check box to disable In the URL field, based on the URL Type you select, enter an optional URL

4-8 Oracle Fusion Middleware Administrators Guide for Oracle Web Cache

2. From the Web Cache menu, select Administration and then Request Filters.

The Request Filters Summary page displays.

3. From the Site list, select the site to apply the filter. See

Section 2.11.3 and Section 2.11.4 to create additional sites. You can configure filters and filter rules for specific sites or Undefined Sites. Oracle Web Cache directs client requests that do not match a defined site to the request filters configured for Undefined Sites.

4. Click the Method link.

The Method Request Filter page displays.

5. From the Audit list, select the level of action for Oracle Web Cache to include in

the audit log for the request filter.

6. From the Response to deny list, select the HTTP response for Oracle Web Cache to

return to browsers for requests that are denied by this request filter. The Close Connection option does not return any HTTP responses. It just closes the connection.

7. In the Defined Rules section, create a new rule:

a. Click Create to create a row in the table.

b. In the Method field, enter the HTTP request method, such as GET, POST, or

PUT.

c. Click the Enable check box to enable the rule; deselect the check box to disable

the rule temporarily without losing the rule definition.

d. In the URL field, based on the URL Type you select, enter an optional URL

string. If no URLs are specified, then all requests are checked. It is equivalent to specifying a URL with a prefix . - Path Prefix: Enter the path prefix of the objects. Start the path with ; do not start the path with http:host_name:port. The prefix is interpreted literally, including reserved regular expression characters. These characters include periods ., question marks ?, asterisks , brackets [], curly braces {}, carets , dollar signs , and backslashes \. - File Extension: Enter the file extension. Because Oracle Web Cache internally starts the file extension with a period ., it is not necessary to enter it. - Regular Expression: Enter the regular expression of the objects. Remember to use to denote the start of the URL and to denote the end of the URL.

e. From the URL Type list, select an option to determine how the rules URL is

compared to the requests URL: - Path Prefix: Select to allow or deny access to requests matching a path prefix. - File Extension: Select to allow or deny access to requests matching a particular file extension. - Regular Expression: Select to allow or deny access to requests matching regular expression syntax.

f. Click the Case Insensitive Match check box to match requests regardless of

the case. If you do not select this check box, the rule bases the match on the case. Configuring Request Filtering 4-9

g. Select the Allow check box for Oracle Web Cache to allow requests matching

the method and URL fields; deselect the check box for Oracle Web Cache to deny requests matching the method and URL fields.

h. Click the Monitor Only check box to see the match activity of the rule without

enforcing the rule. When results are expected, then disable Monitor Only to enforce the rule. See Section 4.4 for further information about the Monitor Only option.

i. Click Apply to save the rule settings.

8. Perform Step 7 for any additional rules. You can also add learned rules, as described in Section 4.7.1 .

9. Modify the Catch All rule, keeping in mind it is applied to all requests that do not

match a defined rule. Oracle recommends creating allow rules, followed by a Catch All deny rule. 10. Use the Move Up and Move Down icons to change the order in which the rules are matched against requests. The order of the rules is important. Oracle Web Cache matches higher priority rules first.

11. Click the Request Filters Summary breadcrumb at the top of the page, or from the

Web Cache menu, select Administration and then Request Filters to navigate back to the Request Filters Summary page.

12. In the Method row, click Enable to enable the filter.

If you do not click Enable, Oracle Web Cache ignores any configured filter rules for this filter.

13. Click Apply to save the configuration for the request filter.

4.7.1 Activating Learned Rules for the Method Request Filter

See Section 4.3 for further information about how learned rules are collected from the Catch All rule. You can add learned rules to the method request filter. To enable learned rules for the method request filter: 1. Navigate to the Method Request Filter page.

2. In the Learned Rules section, if you see that some learned rules have been

suggested, monitor the statistics for these rules by watching this page for awhile. When you decide that one or more learned rules make sense, proceed. If no learned rules display under Catch All Rule, then there are no learned rules. 3. Select the row, and click Add Rule to Defined Rules to activate the rule and move it the Defined Rules section.

4. Use the Move Up and Move Down icons to change the order in which the rules

are matched against requests.

5. Click Apply to save the configuration for the request filter.

4.8 Configuring Rules for the URL Request Filter

The URL request filter enables Oracle Web Cache to allow or deny access to a specific site URL.