-
Notifications
You must be signed in to change notification settings - Fork 0
Keyword condition
A keyword condition matches if the URL protocol is HTTP, and the pattern is an exact sub-string of the URL. (It behaves like the URL wildcard pattern http://*pattern*
, where pattern
is the keyword pattern.)
Keyword conditions are useful if you want to avoid connection resets by the GFW, by requesting URLs that contain certain keywords through a proxy.
Pattern: example.com
Matching: http://www.example.com
, http://search.test/?q=example.com
Not matching: https://www.example.com
, https://search.test/?q=example.com
Keyword conditions are expected to be used very very frequently in China, for China is a country of china [citation needed]. They can be the largest part of a switch profile or a rule list profile.
Luckily, they are easy to optimize. First, see whether the protocol is HTTP
. Then, check whether the keyword is a substring of the URL.