Cisco Cisco Web Security Appliance S170 사용자 가이드

다운로드
페이지 734
 
18-26
Cisco IronPort AsyncOS 7.5.7 for Web User Guide
Chapter 18      URL Filters
Regular Expressions
Regular Expression Character Table
 describes characters that are commonly used to form regular expressions: 
Note
To match the literal version of any of the special characters, the character must be preceded by a 
backslash “\”. For example, to exactly match a period “.” the regular expression must use “\.” as in 
“\.example\.com”. However, the appliance does not support using a backward slash to escape a forward 
slash. If you need to use a forward slash in a regular expression, type the forward slash without a 
backward slash.
Table 18-8
Regular Expression Character Descriptions 
Character
Description
.
Matches a single character.
*
Matches zero or more occurrences of the preceding regular expression. 
For example:
[0-9]* matches any number of digits
“.*” matches any arbitrary string of characters
^
Matches the beginning of a line as the first character of a regular expression.
$
Matches the end of a line as the last character of a regular expression.
+
Matches one or more occurrences of the preceding regular expression.
?
Matches zero or one occurrence of the preceding regular expression.
|
Matches the preceding regular expression or the following regular expression. For 
example:
x|y matches either x or y
abc|xyz matches either of the strings abc or xyz
[ ]
Matches the characters or digits that are enclosed within the brackets. 
For example:
[a-z] matches any character between a and z
[r-u] matches any of the characters r, s, t, or u
[0-3] matches any of the single digits 0, 1, 2, 3
{ }
Specifies the number of times to match the previous pattern. 
For example:
D{1,3} matches one to three occurrences of the letter D
( )
Group characters in a regular expression.
For example:
(abc)* matches abc or abcabcabc
“...”
Literally interprets any characters enclosed within the quotation marks.
\
Escape character.