2011-03-17 20:04:49 +00:00
|
|
|
|
|
|
|
Many commands in __mitmproxy__ and __mitmdump__ take a filter expression.
|
|
|
|
Filter expressions consist of the following operators:
|
|
|
|
|
2013-01-02 01:02:41 +00:00
|
|
|
<table class="table">
|
|
|
|
<tbody>
|
2011-03-17 20:04:49 +00:00
|
|
|
<!--(for i in filt_help)-->
|
|
|
|
<tr>
|
|
|
|
<td class="filt_cmd">@!i[0]!@</td>
|
|
|
|
<td class="filt_help">@!i[1]!@</td>
|
|
|
|
</tr>
|
|
|
|
<!--(end)-->
|
2013-01-02 01:02:41 +00:00
|
|
|
</tbody>
|
2011-03-17 20:04:49 +00:00
|
|
|
</table>
|
|
|
|
|
|
|
|
- Regexes are Python-style
|
|
|
|
- Regexes can be specified as quoted strings
|
|
|
|
- Header matching (~h, ~hq, ~hs) is against a string of the form "name: value".
|
|
|
|
- Strings with no operators are matched against the request URL.
|
|
|
|
- The default binary operator is &.
|
|
|
|
|
|
|
|
Examples
|
|
|
|
========
|
|
|
|
|
2011-03-29 23:05:50 +00:00
|
|
|
URL containing "google.com":
|
2011-03-17 20:04:49 +00:00
|
|
|
|
|
|
|
google\.com
|
|
|
|
|
|
|
|
Requests whose body contains the string "test":
|
|
|
|
|
2011-12-28 21:47:30 +00:00
|
|
|
~q ~b test
|
2011-03-17 20:04:49 +00:00
|
|
|
|
|
|
|
Anything but requests with a text/html content type:
|
|
|
|
|
2011-12-28 21:47:30 +00:00
|
|
|
!(~q & ~t \"text/html\")
|
2011-03-17 20:04:49 +00:00
|
|
|
|