We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
whistle 支持通过 域名、路径、正则、通配符 等方式匹配请求URL外,也支持通过 filter 实现通过 请求方法、请求头、请求内容、响应状态码、响应头 等方式实现更复杂的匹配,如:
* reqHeaders://`x-test=${reqCookies.test}` includeFilter://reqH:cookies=/test=\d+;/
上述表示匹配请求头cookie里面包含 test=数字 的请求,且将cookie里面的 test 字段值设置到请求头里面。
test=数字
test
除了上面的 excludeFilter 和 includeFilter 是通过 url、请求方法、请求头、请求内容、响应状态码、响应头 等过滤当前匹配的规则,whistle 也支持通过 ignore 忽略指定规则协议,如:
excludeFilter
includeFilter
# 忽略 ke.qq.com 的所有 whistle 规则 ke.qq.com ignore://* # 忽略 fudao.qq.com 的 host 规则 fudao.qq.com ignore://host # 只保留 abcmouse.qq.com/path/to 的修改请求头规则 abcmouse.qq.com ignore://* abcmouse.qq.com/path/to reqHeaders://x-test=abc ignore://-reqHeaders
更多内容参考:
The text was updated successfully, but these errors were encountered:
No branches or pull requests
whistle 支持通过 域名、路径、正则、通配符 等方式匹配请求URL外,也支持通过 filter 实现通过 请求方法、请求头、请求内容、响应状态码、响应头 等方式实现更复杂的匹配,如:
除了上面的
excludeFilter
和includeFilter
是通过 url、请求方法、请求头、请求内容、响应状态码、响应头 等过滤当前匹配的规则,whistle 也支持通过 ignore 忽略指定规则协议,如:更多内容参考:
The text was updated successfully, but these errors were encountered: