Host filters for chained proxies
You can specify a set of hosts for which requests should be routed through the chained proxy.
Overview
Specify the filter as an attribute of the HTTP or HTTPS chained proxy definition. The filter
contains a list of hostnames for which requests should be routed through the chained proxy. The
following special characters are permitted in a filter:
Character | Meaning |
---|---|
| | Combines rules into a single filter. |
* | Wildcard character. The asterisk can only appear at the beginning or end of a hostname. |
~ | Reverses the rule that follows the character. |
Processing
Filters are evaluated from right to left. An entire filter is considered matched when the request destination host matches a positive rule. An entire filter is considered not to match when a negative rule is matched.
A positive rule lists the only hosts that will be directed to the proxy. A negative rule (beginning with a "~" character) lists the only hosts that will *not* be directed to the proxy.
No spaces are permitted in a filter string.
Examples
- Use the chained proxy for requests to "myHost.myCompany.com"
only
filter="myHost.myCompany.com"
- Use the chained proxy for all hosts whose names end in
"myCompany.com"
filter="*.myCompany.com"
- Use the chained proxy for all hosts other than
"myHost.myCompany.com"
filter="~myHost.myCompany.com"
- Use the chained proxy for requests to either "myHost.myCompany.com" or
"myOtherHost.myCompany.com"
filter="myHost.myCompany.com|myOtherHost.myCompany.com"
- Use the chained proxy for all hosts whose names begin with
"testMachine"
filter="testMachine*"
- Use the chained proxy for all hosts except those whose names end in
"myCompany.com"
filter="~*.myCompany.com"
- Use the chained proxy for all hosts whose names end in "myCompany.com" except for
"myBadHost.myCompany.com"
filter="*.myCompany.com|~myBadHost.myCompany.com"
- Filter out all hosts whose names end in "myCompany.com" except for
"myTestMachine.myCompany.com"
filter="~*.myCompany.com|myTestMachine.myCompany.com"
- Temporarily disable the previous filter for testing purposes, allowing requests for all host
names to be passed to the
proxy
filter="~*.myCompany.com|myTestMachine.myCompany.com|*"