diff options
author | Aldo Cortesi <aldo@nullcube.com> | 2011-08-05 10:23:32 +1200 |
---|---|---|
committer | Aldo Cortesi <aldo@nullcube.com> | 2011-08-05 10:23:32 +1200 |
commit | 98a7aaca182ce6b879329bbaeb06efca284c6220 (patch) | |
tree | a9afa1dae76d3206990cc49a30c2433ea6077609 /doc-src/mitmproxy.html | |
parent | ce48cb4debab8caa518ea54e36dee722aaabb8a5 (diff) | |
download | mitmproxy-98a7aaca182ce6b879329bbaeb06efca284c6220.tar.gz mitmproxy-98a7aaca182ce6b879329bbaeb06efca284c6220.tar.bz2 mitmproxy-98a7aaca182ce6b879329bbaeb06efca284c6220.zip |
Documentation.
Diffstat (limited to 'doc-src/mitmproxy.html')
-rw-r--r-- | doc-src/mitmproxy.html | 60 |
1 files changed, 51 insertions, 9 deletions
diff --git a/doc-src/mitmproxy.html b/doc-src/mitmproxy.html index da4c2a82..ef0b242d 100644 --- a/doc-src/mitmproxy.html +++ b/doc-src/mitmproxy.html @@ -1,16 +1,58 @@ __mitmproxy__ is a console tool that allows interactive examination and -modification of HTTP traffic. +modification of HTTP traffic. The _?_ shortcut key shows complete documentation +on __mitmproxy__'s functionality. -## Connection list + +## The interface: connection list <img src="@!urlTo("screenshots/mitmproxy.png")!@"/> -- Looking at the connection list, we can see that we visited __gmail.com__, -which then returned a 301 redirect. -- The statusbar tells us that there are 11 flows in the list, and that we're -currently using the "pretty" view mode. -- Also visible is the __Event log__, which can be toggled on and off with the -__v__ keyboard shortcut. This displays events like client connection -information, errors, and script output. +The connection list shows an index of captured flows in chronological order. +So, in this case, we can we can see that we visited __gmail.com__, which then +returned a 301 redirect to mail.google.com. + +The statusbar at the bottom tells us that there are 11 flows in the view, that +we are using the "pretty" view mode (more on that below), and that the proxy is +bound to port 8080 of all interfaces. + +Also visible is the __Event log__, which can be toggled on and off with the _v_ +keyboard shortcut. This displays events like client connection information, +errors, and script output. + + +## Example: Interception + +__mitmproxy__'s interception functionality lets you pause an HTTP request or +response, inspect and modify it, and then accept it to send it on to the server +or client. + + +### 1: Set an interception pattern + +<img src="@!urlTo('intercept-filt.png')!@"/> + +We press _i_ to set an interception pattern. In this case, the __~q__ filter +pattern tells __mitmproxy__ to intercept all requests. For complete filter +syntax, see the [Filter expressions](@!urlTo("filters.html")!@) section of this +document, or the built-in help function in __mitmproxy__. + +### 2: Intercepted connections are indicated with a red exclamation mark: + +<img src="@!urlTo('intercept-mid.png')!@"/> + +### 3: You can now view and modify the request: + +<img src="@!urlTo('intercept-options.png')!@"/> + +In this case, we viewed the request by selecting it, pressed _e_ for "edit" +and _m_ for "method" to change the HTTP request method. + +### 4: Accept the intercept to continue + +<img src="@!urlTo('intercept-result.png')!@"/> + +Finally, we press _a_ to accept the modified request, which is then sent on to +the server. In this case, we changed the request from an HTTP GET to to +OPTIONS, and Google's server has responded with a 405 "Method not allowed". |