01.01.2013 Views

Web Gateway 7.1.5 Product Guide - McAfee

Web Gateway 7.1.5 Product Guide - McAfee

Web Gateway 7.1.5 Product Guide - McAfee

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

8<br />

Monitoring<br />

Logging<br />

The settings of the blocking action specify a message to the requesting user. They also include an<br />

ID for the block reason, which is recorded in the entry that is written into the Access Log for the<br />

request.<br />

To configure action settings for the rule, you need to create these settings before you create the rule.<br />

If you want to set the text contained in the body of the web object as the value of the<br />

User-defined.listOfWords property, you must use another rule to set the value. This rule, which must be<br />

placed and executed before the blocking rule, could look as follows:<br />

Set User-Defined.listOfWords<br />

Always –> Continue — Set User-Defined.listofWords = String.ToStringList (Body.Text “ ” “.,;:‘’!?”)<br />

When this rule is processed, it is always executed. It uses an event to set the User-Defined.listOf<br />

Words property to a value, which is the list of words in a text. To provide this list, the String.To<br />

StringListProperty converts the words from the text contained in the body of a web object into a<br />

list. The web object is the one that is currently being requested by a user.<br />

The Body.Text property is the first parameter of the String.ToStringList property. It is a string<br />

containing the text in the body of the requested web object. The other two parameters specify a<br />

list delimiter and a character that has all its occurrences deleted in the list, which is the whitespace<br />

in this case.<br />

The Continue action lets processing continue with the next rule.<br />

For information on how to configure a user-defined property for the blocking rule, see Create a<br />

user-defined property of the list type.<br />

For creating a rule set to contain the two rules, see Create a rule set for new rules.<br />

For creating the rules, see Create a rule for setting text as the value of a user-defined property and<br />

Create a rule for blocking text with bad key words.<br />

Addition to a default logging rule<br />

You can use the Rule Sets tab to work with the default logging rules. To let a logging rule write key<br />

words that have been identified by a suitable rule into the Access Log, you need to add the value of the<br />

List.LastMatches property to the log line used by the log.<br />

The value of the List.LastMatches property is a string containing all elements that have been found to<br />

match when two lists are compared using an operator such as at least one in list or all in list.<br />

After adding this value to the log line of the Access Log, you will see in this log the word or words that<br />

the blocking rule has identified as the reason for blocking access to a web object.<br />

For example, the blocking rule compares a keyword list containing the words “shopping”, “travel”, and<br />

“games” to a list of words created by converting the text in question. If the comparison uses the<br />

at-least-one-in-list operator, the occurrence of the word “shopping” is sufficient for blocking access to<br />

this text. The log line then includes this word. This way you not only know why access was blocked, but<br />

also the key word that triggered the blocking.<br />

If you use a different operator, for example, the all-in-list operator, the blocking rule is only executed if<br />

all key words are matched within the text in question. All key words are then recorded.<br />

After adding the value of the List.LastMatches property to the log line of the Access Log, the default<br />

logging rule that writes this line into the log could look as follows:<br />

Write access.log<br />

Always –> Continue —<br />

Set User-Defined.logLine =<br />

DateTime.To<strong>Web</strong>ReporterString + “ ”<br />

+ Authentication.Username + “ ”<br />

...<br />

284 <strong>McAfee</strong> <strong>Web</strong> <strong>Gateway</strong> <strong>7.1.5</strong> <strong>Product</strong> <strong>Guide</strong>

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!