Aldo Cortesi
fe4bab2e6f
Cleanup: fix unit tests, simpler app test, remove print statements
2014-02-08 12:33:59 +13:00
Maximilian Hils
33b10da57c
fix tests
2014-02-07 18:26:42 +01:00
Maximilian Hils
735e4400c4
add tests for reconnect to upstream proxy, ensure that server_reconnect is always hooked
2014-02-07 18:14:15 +01:00
Maximilian Hils
545fc2506b
Achievement Unlocked: Proxy Chain
2014-02-07 07:08:59 +01:00
Maximilian Hils
9526c5d565
fix race conditions in test suite
2014-02-07 04:15:24 +01:00
Maximilian Hils
d07029d575
coverage++
2014-02-07 03:56:57 +01:00
Maximilian Hils
9f5f2b7071
test libmproxy.app, increase coverage
2014-02-07 02:36:39 +01:00
Maximilian Hils
cb397ec788
fix bugs, expose timestamp information to console ui
2014-02-06 00:53:39 +01:00
Maximilian Hils
80683e77bc
mock urwid to run console tests on windows, push failing testcases down to 0. :-)
2014-02-05 23:17:26 +01:00
Maximilian Hils
f26d91cb81
add skeleton to change destinatin server during intercept, fix all testcases on windows
2014-02-05 20:26:47 +01:00
Maximilian Hils
d864a326d2
fix all tests except those using set_url and get_url
2014-02-05 14:33:17 +01:00
Maximilian Hils
6a53ae5fd3
push failing tests down to 43
2014-02-04 05:02:17 +01:00
Maximilian Hils
2db5f9de26
bring failing tests back into the double-digit range
2014-01-31 04:45:39 +01:00
Maximilian Hils
7d96ff00ef
remove _flow_map from state, improve logging
2014-01-31 03:01:51 +01:00
Maximilian Hils
607f777811
fix most testsuite errors, improve proxy error handling
2014-01-29 02:49:11 +01:00
Maximilian Hils
1e3e0dd127
merge master
2014-01-28 17:29:28 +01:00
Maximilian Hils
17f09aa0af
unify ipv4/ipv6 address handling
2014-01-28 17:28:20 +01:00
Maximilian Hils
125166020b
move test requirements out of main requirements.txt
2014-01-28 03:09:21 +01:00
Aldo Cortesi
069aca1df4
Deprecate Flow.unload_script in favor of Flow.unload_scripts
...
In the presence of arguments, unloading a single script is clumsy and
less useful.
2014-01-13 14:20:34 +13:00
Aldo Cortesi
4f69eef8f3
Extract command parsing and use in script grid editor
2014-01-13 14:15:17 +13:00
Aldo Cortesi
42d4a2fae9
Script refactoring: move script command parsing into script module.
2014-01-12 23:02:29 +13:00
Aldo Cortesi
e5776b8be3
Clean up and clarify script API
2014-01-12 13:59:32 +13:00
Aldo Cortesi
58e1b3a47f
Start refactoring scripts
...
- Move ScriptContext into script module
- Use mock module instead of hand-rolled mock objects in tests
2014-01-12 12:49:19 +13:00
Maximilian Hils
2f63da99c9
ignore console test utilities on windows
2014-01-10 01:39:16 +01:00
Aldo Cortesi
d5f9b02615
Merge pull request #192 from mitmproxy/refactor_read_http_body
...
move CONTINUE checks into mitmproxy
2014-01-04 14:37:47 -08:00
Aldo Cortesi
7d37e0ce10
Merge pull request #193 from droope/search-functionality
...
Search functionality
2014-01-04 14:34:20 -08:00
Aldo Cortesi
ac31039ad3
Merge pull request #198 from Kami/add_css_view
...
Add CSS view which beautifies minified CSS files
2014-01-04 14:04:02 -08:00
Tomaz Muraus
e9f6302ec7
Add CSS view which beautifies CSS files if cssutils library is available,
...
otherwise it acts as a no-op.
2014-01-04 04:49:50 +01:00
Aldo Cortesi
45eab17e0c
Decouple message type from message class name.
2014-01-04 14:42:32 +13:00
Aldo Cortesi
1e07d9e6e7
Move app mechanism to flow.py
...
Disable apps while message passing is improved.
2014-01-04 14:35:11 +13:00
Pedro Worcel
799c877676
now really fix it + test
2013-12-26 22:18:34 +13:00
Pedro Worcel
21efe2f2c8
add looping around
2013-12-26 17:04:18 +13:00
Pedro Worcel
9cf8a1a89d
fix failing test
2013-12-25 21:08:20 +13:00
root
95406bd119
Add focusing, and fixes non-clearance of prev searches. Add
...
documentation.
2013-12-25 16:50:29 +13:00
root
932464d0a0
test passing, UI still not working
2013-12-24 14:28:20 +13:00
Maximilian Hils
e643759ef6
merge smurfix/fix2, add serverconnect hook docs, adjust tests
2013-12-16 22:10:06 +01:00
Maximilian Hils
f4b58ba495
move CONTINUE checks into mitmproxy
2013-12-15 06:33:18 +01:00
Maximilian Hils
6ec2e6f24f
fix script path error in tests
2013-12-15 02:51:35 +01:00
Maximilian Hils
605950bfdf
add @concurrent decorator for inline scripts, fixes #176
2013-12-15 02:43:16 +01:00
Maximilian Hils
39ffe10334
add content-length 0 if we remove header for chunked encoding, fixes #186
2013-12-12 04:42:29 +01:00
Maximilian Hils
7db1430ee7
ignore missing CN in certificates. fixes #169
2013-12-12 03:24:17 +01:00
Maximilian Hils
28a234e28b
store resolved ip addresses, fixes #187
2013-12-12 02:11:22 +01:00
Maximilian Hils
3bd238de37
backport changes to fix tests
2013-12-08 15:46:11 +01:00
Maximilian Hils
a509a9037b
Merge branch 'master' into 0.10
2013-12-08 14:14:57 +01:00
Aldo Cortesi
3a1d85ab18
Merge pull request #134 from mhils/scripts_improvements
...
Support multiple scripts and script arguments. refs #76
2013-12-08 01:14:12 -08:00
Aldo Cortesi
7aeaf9d448
Merge pull request #161 from mitmproxy/external_webapp
...
External webapp
2013-12-08 01:09:46 -08:00
Aldo Cortesi
cb3a4a0f3c
Remove obsolete test.
2013-12-08 21:58:55 +13:00
Maximilian Hils
2956c144d3
Merge branch 'master' into 0.10
2013-09-14 23:47:04 +02:00
Aldo Cortesi
aaba940dea
Fix pretty_size unit tests.
2013-08-23 10:28:16 +12:00
Maximilian Hils
bb4748fb8f
add option to expose webapp externally, remove distinct ip setting
2013-08-18 20:03:53 +02:00
Maximilian Hils
729677cd85
Merge branch 'master' into 0.10
2013-08-17 13:30:36 +02:00
Aldo Cortesi
f850bdd848
Revamp dummy cert store
...
We no longer keep these on disk. This is for a number of reasons, including
some race conditions and the fact that some valid IDNA-encoded domain names are
not valid file names on Windows.
2013-08-12 16:04:02 +12:00
Aldo Cortesi
439d9a294c
Make use of a change to netlib.tcp that clarifies error conditions for flush and close.
...
Should fix #144 .
2013-07-30 09:42:29 +12:00
Aldo Cortesi
10a9e3365f
Some refactoring of the console inteface.
...
Reduce some state duplication, by removing currentflow variable.
Fixes #141
2013-07-28 18:00:49 +12:00
Aldo Cortesi
5c1157ddaf
Move app instantiation out of proxy.py.
2013-07-24 10:32:56 +12:00
Maximilian Hils
6fe175913e
fix request_timestamps test case
2013-06-18 00:54:07 +02:00
Maximilian Hils
ca9740df20
skip tests on windows that don't make sense
2013-06-18 00:53:38 +02:00
Maximilian Hils
d462b444b7
update tests to reflect changes to options.scripts
2013-06-17 16:48:06 +02:00
Maximilian Hils
fd36142018
Merge remote-tracking branch 'origin/scripts_improvements' into 0.10
2013-06-16 00:41:43 +02:00
Maximilian Hils
ba47690a03
always read files in binary mode
2013-06-16 00:23:44 +02:00
Maximilian Hils
b4f6f09c83
update test script
2013-06-16 00:10:53 +02:00
Maximilian Hils
2b4af8d475
add support for multiple scripts and script arguments. refs #76
2013-06-13 16:09:38 +02:00
Aldo Cortesi
11cc48ca25
Adapt for new request_client_cert option in netlib.
2013-05-13 09:08:24 +12:00
Aldo Cortesi
5cd7563d12
Minor coverage.
2013-04-30 09:13:33 +12:00
Aldo Cortesi
61c794e08f
Merge pull request #107 from rouli/master
...
Adding remote TCP and SSL setup timestamps
2013-04-19 17:19:26 -07:00
Nicolas Esteves
d4cfbbb822
Adds a new view for protocol buffers
...
The view uses protoc from the Google protocol buffer
tools. If the tool isn't installed, the view isn't
shown.
Google protobuf repo:
https://code.google.com/p/protobuf/
2013-04-06 19:21:13 +01:00
Aldo Cortesi
51b775cfd4
Merge pull request #101 from eentzel/keep-blank-params
...
Keep blank URL parameters
2013-04-04 15:55:51 -07:00
Aldo Cortesi
e3fd0e838d
Add a basic built-in web app.
2013-03-25 09:20:26 +13:00
Rouli
c6bf28f3f7
adding tcp and ssl setup timestamps to get better resolution on flows performance
2013-03-19 18:21:52 +02:00
Aldo Cortesi
d2d3eb6490
Un-break unit tests. Tsk tsk.
2013-03-17 17:53:48 +13:00
Aldo Cortesi
0e993bec6f
Add the --host option, which uses the value in the Host header for dispaly URLs.
...
- Can be toggled with "o" then "h" in mitmproxy
- Useful for transparent mode
2013-03-17 17:37:54 +13:00
Aldo Cortesi
cfb5ba89ce
Introduce a filtered flow writer, and use it in dump.py
...
Fixes #104
2013-03-14 09:19:43 +13:00
Aldo Cortesi
8a850dc8e6
Few more fuzzing commands, exclude console app from coverage.
2013-03-03 22:39:26 +13:00
Aldo Cortesi
cde66cd584
Fuzzing, and fixes for errors found with fuzzing.
2013-03-03 22:03:27 +13:00
Aldo Cortesi
8216801728
Three more errors turned up with fuzzing.
...
These are fixed in netlib, regression tests added here.
2013-03-03 15:14:49 +13:00
Aldo Cortesi
7835e0c2c7
Begin some simple fuzzing with pathod.
...
Finally doing what I started writing pathod for in the first place...
2013-03-03 14:56:56 +13:00
Aldo Cortesi
e608d10f45
Remove __slots__ to make it possible to inherit from Options classes.
2013-03-03 12:26:20 +13:00
Aldo Cortesi
2465b8a376
100% unit test coverage on proxy.py. Hallelujah!
2013-03-03 12:13:33 +13:00
Aldo Cortesi
d5876a12ed
Unit test proxy option parsing.
2013-03-03 11:58:57 +13:00
Aldo Cortesi
33cdd5d083
Unit test proxy auth.
2013-03-03 11:04:33 +13:00
Aldo Cortesi
5c6587d4a8
Move HTTP auth module to netlib.
2013-03-03 10:37:06 +13:00
Aldo Cortesi
bbdb59b9f9
Test controller message default reply.
2013-03-03 09:33:22 +13:00
Aldo Cortesi
c20d1d7d32
Extend unit tests for proxy.py to some tricky cases.
2013-03-02 22:42:36 +13:00
Aldo Cortesi
415844511c
Test cert generation errors.
2013-03-02 16:59:16 +13:00
Aldo Cortesi
09c73019c5
Remove human_curl requirement for the test suite - it's pathoc all the way, baby.
2013-03-02 15:09:22 +13:00
Aldo Cortesi
a95d78438c
Test SNI for transparent mode.
2013-03-02 15:06:49 +13:00
Aldo Cortesi
10db82e9a0
Test SNI for ordinary proxy connections.
2013-03-02 14:52:05 +13:00
Aldo Cortesi
ba674ad551
New SNI handling mechanism.
2013-03-01 09:05:39 +13:00
Aldo Cortesi
b077189dd5
Test cert file specification, spruce up server testing truss a bit.
2013-02-24 22:52:59 +13:00
Aldo Cortesi
0257815141
Significantly simplify server connection handling, and test.
2013-02-24 22:24:21 +13:00
Aldo Cortesi
705559d65e
Refactor to prepare for SNI fixes.
2013-02-24 17:35:24 +13:00
Aldo Cortesi
d0639e8925
Handle server disconnects better.
...
Server connections can be closed for legitimate reasons, like timeouts. If
we've already pumped data over a server connection, we reconnect on error. If
not, we treat it as a legitimate error and pass it on to the client.
Fixes #85
2013-02-24 14:04:56 +13:00
Aldo Cortesi
64285140f9
Test a difficult-to-trigger IOError, fix cert generation in test suite.
2013-02-24 11:34:01 +13:00
Aldo Cortesi
51de9f9fdf
Test client connection close conditions.
2013-02-24 10:51:14 +13:00
Aldo Cortesi
05e4d4468e
Test request and response kill functionality.
2013-02-23 21:59:25 +13:00
Aldo Cortesi
269780c577
Unit test dummy response functions.
2013-02-23 16:34:59 +13:00
Aldo Cortesi
aaf892e3af
Significantly refactor the master/slave message passing interface.
2013-02-17 12:42:48 +13:00
Aldo Cortesi
1ccb2c5dea
Test WSGI app calling.
...
- Factor out test servers into a separate file
- Adjust docs to note new Flask dependency
2013-02-16 16:46:16 +13:00
Eric Entzel
6bcf29c0ed
Keep blank URL parameters
...
TODO: This should probably be configurable
2013-02-11 13:22:25 +11:00
Aldo Cortesi
782bbee8c0
Unit tests for ServerConnectionPool
2013-01-29 11:35:57 +13:00
Aldo Cortesi
53792a5a28
Beef up unit tests for HAR utility functions - flow.py coverage now 100%.
2013-01-29 10:41:45 +13:00
Aldo Cortesi
6f157d936f
Merge pull request #99 from rouli/master
...
Adding helper functions to make HAR export easier
2013-01-28 13:28:49 -08:00
Rouli
330fbfe8cc
adding helper functions to make HAR export easier
2013-01-28 17:37:25 +02:00
Aldo Cortesi
57f01ffb07
Test suite, remove extraneous code.
2013-01-28 21:59:03 +13:00
Aldo Cortesi
25cb9471f0
Add tests for client certificate support.
2013-01-20 22:39:28 +13:00
Aldo Cortesi
6600c589ab
Rudimentary testing for client certs.
2013-01-18 17:08:30 +13:00
Aldo Cortesi
0f406e9daa
Speed up the test suite by reducing time sleeping in tests.
2013-01-18 14:52:19 +13:00
Aldo Cortesi
7a79eeb143
Merge branch 'master' of ssh.github.com:cortesi/mitmproxy
...
Conflicts:
test/test_server.py
2013-01-18 14:50:31 +13:00
Rouli
6212b69fb4
fixes due to merge with master
2013-01-17 17:36:18 +02:00
Rouli
446f9f0a0f
Merge remote-tracking branch 'upstream/master'
2013-01-17 17:33:29 +02:00
Rouli
20fa6a3083
changing requests and responses to have two timestamps, one marking their initiation, and the other their complete
2013-01-17 17:32:56 +02:00
Aldo Cortesi
d0ee4d60d0
Unit tests and minor code refactoring for ServerConnection.
2013-01-05 19:44:12 -08:00
Aldo Cortesi
891c441a6d
Use new netlib certificate store implementation.
2013-01-06 01:16:08 +13:00
Aldo Cortesi
9cfc785cd3
Unit test love - 100% for flow.py, dump.py
2013-01-05 21:56:33 +13:00
Aldo Cortesi
46ab6ed491
Minor cleanups of proxy request handling.
2013-01-04 14:19:32 +13:00
Aldo Cortesi
f5e49ef598
First draft of "How mitmproxy works", a complete guide to the mechanics of the proxy process
2013-01-03 17:26:59 +13:00
Aldo Cortesi
e2dc7ba09d
First draft of OSX transparent proxy mode.
2013-01-01 11:13:56 +13:00
Aldo Cortesi
5347cb9c26
More work on proxy auth
...
- Strip auth header if auth succeeds, so it's not passed upstream
- Actually use realm specification to BasicProxyAuth, and make it mandatory
- Cleanups and unit tests
2012-12-31 10:56:44 +13:00
Aldo Cortesi
3b84111493
Test and robustify BasicProxyAuth.parse_auth_value
...
- This is partly in preparation for moving the implementation to netlib
- Also add an unparse_auth_value for testing (and use in pathod once the move is done)
2012-12-31 10:34:25 +13:00
Aldo Cortesi
018c229ae4
Start solidifying proxy authentication
...
- Add a unit test file
- Remove some extraneous methods
- Change the auth API to make the authenticate method take a header object.
2012-12-31 09:15:56 +13:00
Aldo Cortesi
8c976ac7f0
Substantially rewrite AMF decoding.
...
This is tricky, but we should now handle a lot more corner-cases.
2012-11-26 13:25:07 +13:00
Aldo Cortesi
0d59fd7e01
Move cleanBin and hexdump into netutils.
2012-09-24 11:21:12 +12:00
Aldo Cortesi
d115b5ae70
Expand Flow.match to accept either a string or a compiled filter expression.
2012-09-14 09:41:01 +12:00
Aldo Cortesi
a77ccc406d
Getter and setter for path component on Requests.
2012-08-19 13:03:21 +12:00
Aldo Cortesi
60659a89c3
Little bit of love for the unit tests.
2012-08-19 00:22:42 +12:00
Aldo Cortesi
1b7990897e
Command-line options for header setting.
2012-08-19 00:14:16 +12:00
Aldo Cortesi
3e96015e61
Add SetHeaders, analogous to ReplaceHooks, with a graphical editor in mitmproxy (H shortcut).
...
SetHeaders defines headers that are set on flows, based on a matching pattern.
Existing headers are over-ridden.
2012-08-18 23:41:04 +12:00
Aldo Cortesi
b70e91bbd4
Send tracebacks from content viewers to event log.
...
Also, 100% test coverage for content viewers.
2012-08-18 17:42:40 +12:00
Aldo Cortesi
e8553f966f
Further simplifcation and testing of contentviews.
2012-08-18 17:29:29 +12:00
Aldo Cortesi
11c63dcb9f
Huge cleanup of content viewers.
2012-08-18 17:08:17 +12:00
Sahn Lam
3189d144a5
Optional AMF decoding support
...
If PyAMF is installed, enable AMF decoding.
2012-08-17 18:45:26 -07:00
Aldo Cortesi
a66d018363
Fix unit tests after argparse conversion.
2012-08-18 10:27:31 +12:00
Aldo Cortesi
32ad26f8bf
Add a size() method to flow.Request and flow.Response.
2012-08-04 13:18:05 +12:00
Aldo Cortesi
84bffad3fc
Fix flow read unit test to accomodate more tolerant dumpfile parsing.
2012-07-24 15:30:52 +12:00
András Veres-Szentkirályi
1a26f8215d
removed assigned but unread variables
2012-07-15 22:42:59 +02:00
András Veres-Szentkirályi
da496669c2
removed unused imports
2012-07-15 22:42:45 +02:00
Aldo Cortesi
e4079aa746
Add an ~a filter expression, matching an asset content type in responses.
...
Asset content types are Javascript, images, Flash and CSS. This is useful
because doing a quick "!~a" while auditing an app will filter out the majority
of the static asset cruft, letting you focus on what matters.
2012-07-14 16:55:21 +12:00
Aldo Cortesi
01b8b0d876
Refine semantics of replay_request method.
2012-07-10 23:29:33 +12:00
Aldo Cortesi
04d9ec8c3c
Make WSGI apps work in transparent mode.
2012-07-10 15:53:53 +12:00
Aldo Cortesi
79af9e89c4
Test replay corner cases. Fix discovered bugs.
2012-07-09 11:18:03 +12:00
Aldo Cortesi
aab45078ad
Unit test request replay thread.
...
This is a small patch, but is the culmination of lots of work: we can now unit
test the deep innards of mitmproxy, with coverage. There's a lot more to come
in this vein.
2012-07-09 11:03:55 +12:00
Aldo Cortesi
e49c920d16
Refator server tests to use flow.FlowMaster and flow.State
2012-07-09 10:58:28 +12:00
Aldo Cortesi
572e8a4962
Add streaming to FlowMaster
2012-07-09 10:18:37 +12:00
Aldo Cortesi
4b6fdc92dc
Remove ODict tests. ODict is now in netlib.
2012-07-09 09:54:15 +12:00
Aldo Cortesi
d02bcade3a
Add a domain match filter (~d regex)
2012-07-06 22:21:44 +12:00
Aldo Cortesi
aa708a2d28
Fix error when serializing reverted SSL flows.
2012-07-05 11:52:56 +12:00
Aldo Cortesi
90365e270e
Catch and handle SSL connection errors.
2012-07-01 12:10:32 +12:00
Aldo Cortesi
d74a341e5d
Beef up logging substantially.
2012-07-01 00:15:03 +12:00
Aldo Cortesi
f070e4523a
Handle invalid data more gracefully.
...
Fixes #47
2012-06-30 15:59:42 +12:00
Aldo Cortesi
47651b1ff2
Serialization and de-serialization of new cert format.
2012-06-28 14:29:15 +12:00