Commit Graph

4274 Commits

Author SHA1 Message Date
Maximilian Hils
56b9ec0974 docs++ 2016-05-18 22:50:45 -07:00
Maximilian Hils
6f8db2d7eb improve MultiDict, add ImmutableMultiDict, adjust response.cookies 2016-05-18 22:50:19 -07:00
Maximilian Hils
8e39b7bf38 test flow export with duplicate query string 2016-05-18 19:28:23 -07:00
Maximilian Hils
d1fc694952 clean up odict 2016-05-18 19:01:49 -07:00
Maximilian Hils
44ac64aa72 add MultiDict
This commit introduces MultiDict, a multi-dictionary similar to
ODict, but with improved semantics (as in the Headers class).
MultiDict fixes a few issues that were present in the Request/Response
API. In particular, `request.cookies["foo"] = "bar"` has previously been a
no-op, as the cookies property returned a mutable _copy_ of the cookies.
2016-05-18 18:46:42 -07:00
Maximilian Hils
4c3fb8f509 tests: xfail -> skip 2016-05-18 18:42:35 -07:00
Thomas Kriechbaumer
09b90fce9e remove debug print 2016-05-17 22:45:09 -07:00
Thomas Kriechbaumer
eeccb2faa0 http2: cleanup 2016-05-17 22:44:38 -07:00
Maximilian Hils
9a280119d2 Merge pull request #1126 from Kriechi/safeguard
Safeguard
2016-05-17 22:03:32 -07:00
Thomas Kriechbaumer
43ab9f7bd0 http2: properly handle connection errors 2016-05-17 21:26:06 -07:00
Thomas Kriechbaumer
e61014d203 http2: add connection-lost test 2016-05-17 21:25:10 -07:00
Aldo Cortesi
d27fd55657 Fix broken test_flow_export tests
- Make the tests safe for concurrency
- Fix a test that only passed due to prior modification of global state

This also fixes the project generally for parallel test execution.
2016-05-18 12:34:45 +12:00
Aldo Cortesi
00cc836470 Clean up flow export tests
- Externalise test data
- Define a less finicky comparator for Python code
2016-05-18 12:16:50 +12:00
Yoginski
b155dfd771 Updated the docstring (#1150) 2016-05-17 11:15:18 -07:00
Thomas Kriechbaumer
55a17b2ed3 fix encoding error on *too* random bytes
This should fix things like:

def __init__(self, val):
    self.val = val.decode("string_escape")
ValueError: Trailing \ in string
pathod/language/base.py:108: ValueError

test/pathod/test_language_websocket.py:83: in fr
    return netlib.websockets.Frame.from_bytes(tutils.render(wf, settings))
test/pathod/tutils.py:123: in render
    r = r.resolve(settings)
pathod/language/websockets.py:179: in resolve
    Key(base.TokValueLiteral(os.urandom(4)))
2016-05-15 10:41:54 -07:00
Thomas Kriechbaumer
2887480bcb fix naming which caused overwriting of functions 2016-05-15 10:39:39 -07:00
Thomas Kriechbaumer
f4a13d6f9f http2: improve header tests (#1143) (#1144) 2016-05-14 10:14:42 -07:00
Kostya Esmukov
7fdc0a94db Fixed HTTP2 headers being folded. (#1143) (#1144) 2016-05-14 04:59:21 -07:00
Clemens Brunner
902cd255d4 added UI for options menu (#1130)
* added UI for options menu

* update UI for options menu

* update UI for options v2

* update UI for options v2

* added new btn class

* little changes

* little changes

* merge

* deleted branch

* change menu button class
2016-05-14 05:40:11 -06:00
Jonathan Jones
551fafd451 showing url for terminals that support clickable links when starting mitmweb (#1141) 2016-05-14 05:39:17 -06:00
Thomas Kriechbaumer
f969c70015 bump python-hyper dependencies (#1139) 2016-05-12 13:01:54 -06:00
Maximilian Hils
f1c922c652 Sanitize Print (#1135)
* sanitize strings with shell control characters

* netlib: add utilities to safe-print bytes

* escaped str: add TODO for multi-byte chars
2016-05-12 11:03:57 -06:00
Thomas Kriechbaumer
518cc78454 Merge pull request #1137 from Kriechi/h2-header-encoding
disable http2 header encoding, use bytes everywhere
2016-05-11 23:19:12 -05:00
Thomas Kriechbaumer
7a813936c6 disable http2 header encoding, use bytes everywhere 2016-05-11 16:47:58 -05:00
Jason Pepas
b174fd5e1f Adding example which turns every reponse into an HTTP 500. (#1136)
* Adding example which turns every reponse into an HTTP 500.

* Prefer b"" over None for response.content.
2016-05-11 15:26:17 -06:00
Thomas Kriechbaumer
bbf7b6f690 Merge pull request #1134 from mhils/fix-versions
Fix `version.NAME`
2016-05-11 13:27:58 -05:00
Maximilian Hils
acab4fea5a fix version.NAME 2016-05-11 13:02:19 -06:00
Thomas Kriechbaumer
bef72c1b02 Merge pull request #1121 from Kriechi/fix-cookies
improve cookie parsing
2016-05-11 12:30:44 -05:00
Thomas Kriechbaumer
e2ee48a0ee replace SimpleCookie with our own parser lib 2016-05-11 12:20:21 -05:00
Maximilian Hils
67a37e6d1f improve script loading 2016-05-11 11:15:36 -06:00
Thomas Kriechbaumer
e34b2d7e65 Merge pull request #1132 from mhils/improve-script-loading
Improve script loading
2016-05-11 11:58:44 -05:00
Maximilian Hils
4c8e334642 actually fix tests 2016-05-10 12:19:26 -06:00
Maximilian Hils
bb4f9611f5 Revert "fix tests"
This reverts commit f315dc1eb9.
2016-05-10 12:18:05 -06:00
Maximilian Hils
f315dc1eb9 fix tests 2016-05-10 12:17:25 -06:00
Thomas Kriechbaumer
08002282e8 improve cookie parsing
allows '/' to be within a cookie name
removes deprecated cookie getter/setter
fixes #1118
2016-05-10 11:13:12 -05:00
Thomas Kriechbaumer
595a01de4e Merge pull request #1086 from Kriechi/h2-improv
cleanup h2
2016-05-10 11:09:11 -05:00
Thomas Kriechbaumer
73a5d479bb cleanup h2 layer 2016-05-10 10:57:25 -05:00
Maximilian Hils
9d47d3b1ec fix #1120 2016-05-09 12:15:20 -06:00
Maximilian Hils
01f52ee56a fix mitmdump shutdown 2016-05-08 16:54:30 -06:00
Maximilian Hils
3c644274e9 mitmdump: make sure to always call done() in inline scripts 2016-05-08 16:49:36 -06:00
Maximilian Hils
9ac9df82c4 actually fix #1115 2016-05-06 12:48:44 -07:00
Maximilian Hils
99178c57db issue-1115 2016-05-06 12:39:00 -07:00
Maximilian Hils
ff53e7a6eb scripts: allow package imports 2016-05-03 19:54:16 -07:00
Maximilian Hils
7e633d8a8a fix ClientHello.__repr__ 2016-05-02 19:05:14 -07:00
Maximilian Hils
a91d8d9d26 improve server tls handshake behaviour 2016-05-02 18:53:08 -07:00
Maximilian Hils
67537ee614 simplify ClientHello handling 2016-05-02 18:18:20 -07:00
Maximilian Hils
626f7e1017 improve tls handling, separate set_server and set_server_tls 2016-05-02 18:18:20 -07:00
Maximilian Hils
7f894c131b speed up TLS handshake if SNI is present 2016-05-02 18:18:20 -07:00
Maximilian Hils
714ba16111 disable py.test timeout by default, this breaks interactive debuggers 2016-05-02 16:51:49 -07:00
Maximilian Hils
b5e5917f7f web: update dependencies 2016-05-02 14:33:43 -07:00