Commit Graph

743 Commits

Author SHA1 Message Date
Aldo Cortesi
853e03a5e7 netlib.tutils -> mitmproxy.test.tutils
There's a LOT more to be done refactoring our different conflicting test utils.
2016-10-20 11:42:55 +13:00
Aldo Cortesi
01a449b5cb netlib.exceptions.* -> mitmproxy.exceptions 2016-10-20 11:27:05 +13:00
Aldo Cortesi
301d52d9d0 netlib.encoding -> netlib.http.encoding
Encoding is highly specific to http, and only used within this module.
2016-10-20 11:06:57 +13:00
Aldo Cortesi
f964d49853 netlib.certutils -> mitmproxy.certs 2016-10-20 11:02:52 +13:00
Aldo Cortesi
9870844b38 netlib.utils -> netlib.check
Now only contains is_valid_[host,port]

Intermediate step - this will be in mitproxy.net soon.
2016-10-20 10:46:47 +13:00
Aldo Cortesi
e0f3cce14c netlib.utils.[get,set]bit -> mitmproxy.utils.bits 2016-10-20 10:38:57 +13:00
Aldo Cortesi
9555126585 netlib.utils.BiDi -> mitmproxy.types.bidi.BiDi 2016-10-20 10:32:09 +13:00
Aldo Cortesi
a684585e7c netlib.debug -> mitmproxy.utils.debug 2016-10-20 10:25:36 +13:00
Aldo Cortesi
1ecb25cdc1 mitmproxy.types.[basethread,multidict,serializable] 2016-10-20 10:22:23 +13:00
Aldo Cortesi
f45f4e677e netlib.strutils -> mitmproxy.utils.strutils 2016-10-20 10:11:58 +13:00
Aldo Cortesi
1407830280 netlib.human -> mitmproxy.utils.human 2016-10-20 09:45:18 +13:00
Aldo Cortesi
069119364d Create mitmproxy.utils hierarchy
- Add mitproxy.utils.lrucache, mitproxy.utils.data
2016-10-20 09:35:55 +13:00
Aldo Cortesi
7440232f60 netlib.version -> mitmproxy.version 2016-10-20 09:20:44 +13:00
Aldo Cortesi
25e866b669 debug: add missing print output file paramater 2016-10-19 21:53:58 +13:00
Thomas Kriechbaumer
94c9dd66e6 remove empty lines at beginning of file 2016-10-17 10:32:12 +02:00
Aldo Cortesi
c774a9fec9 python3: clean up super and __future__ 2016-10-17 18:03:07 +13:00
Aldo Cortesi
a647b30365 python3: clean up class brackets 2016-10-17 17:37:08 +13:00
Aldo Cortesi
fb22f2ff4f Zap object base class 2016-10-17 17:37:08 +13:00
Maximilian Hils
5a07892bfc py2--: inline type info 2016-10-16 20:56:46 -07:00
Aldo Cortesi
8360f70024 First-order conversion to Python3-only
- Zap various occurrences of Python2 in docs and scripts
- Remove six from netlib, and some other places where obvious project-wide
search and replace works.
2016-10-17 15:18:47 +13:00
Aldo Cortesi
dcbb968b1b Bump version post release 2016-10-17 00:29:49 +13:00
Aldo Cortesi
5db860a334 Bump to 0.18.1 to fix pypi obstreperousness
Also include contriburors update.
2016-10-16 23:52:47 +13:00
Aldo Cortesi
89d36713e3 certutils: cap the cert store size at 100 by default
This should be enough to give us reuse without growing infinitely. This is part
of fixing the memory situation in mitmdump.

TODO: There's an opportunity here for a better algorithm, that expires certs
based on least-recently-accessed time, rather than oldest generated time.
2016-10-05 10:44:31 +11:00
Aldo Cortesi
6d343c7ca3 debug: use correct fp for memory object output 2016-10-05 09:54:23 +11:00
Aldo Cortesi
882c363ec5 debug: Hard exit after debug signal 2016-10-04 16:48:13 +11:00
Aldo Cortesi
3318e531a6 debug: add a dump of objects in memory 2016-10-04 16:22:01 +11:00
Ryan Laughlin
fbf8567a79 Fix SSL error
This fixes an issue that occurs when a user supplies a custom SSL cert w/ intermediate certs that contradict the default certifi set of root certificates. In particular, this addressed an issue where the "COMODO RSA Certification Authority" cert in certifi is NOT trusted on OS X by default as of OS X 10.11.6. Even when the user manually supplied a different valid "COMODO RSA Certification Authority" cert in their custom SSL cert .pem file, that cert would be overridden by certifi's default cert.
2016-09-30 16:39:44 -04:00
Aldo Cortesi
070aa27cf5 parse_set_cookie header returns an empty list if no cookies are found
This matches parse_cookie, and is more idiomatic.
2016-09-28 15:10:31 +10:00
Shadab Zafar
fba7fe101e Clarify that 'expires' values MUST have a comma now 2016-09-27 21:28:54 +05:30
Shadab Zafar
6e6ed35e3e Modify format_set_cookie_header to take cookie list
and return a comma separated string of cookies
2016-09-27 21:28:51 +05:30
Shadab Zafar
a104d65851 Fixup an error with indices 2016-09-27 16:44:09 +05:30
Shadab Zafar
fd4f662871 Refactor functions 2016-09-27 16:44:09 +05:30
Shadab Zafar
06804e5448 Add a new pairs reader for SetCookie headers 2016-09-27 16:44:09 +05:30
Shadab Zafar
7802a0ba22 Rename _read_pairs to _read_cookie_pairs
We will have a separate _read_set_cookie_pairs
2016-09-27 16:44:09 +05:30
Shadab Zafar
90a48ccc06 Rename _read_token to _read_key
Since we also have a _read_value
2016-09-27 16:44:09 +05:30
Shadab Zafar
29046e6b48 Move CookieAttrs and SetCookie to top 2016-09-27 16:44:09 +05:30
Shadab Zafar
734a7d8a68 Minor refactor 2016-09-27 16:44:09 +05:30
Shadab Zafar
e80b2af4ae Add support for comma separated cookies 2016-09-27 16:44:08 +05:30
Maximilian Hils
24ceb0f7ac allow socket creation monkeypatchs 2016-09-27 00:46:54 -07:00
Maximilian Hils
f59ae4a57f Merge branch 'fully_transparent' 2016-09-22 01:58:08 -07:00
Maximilian Hils
e5b79a6d72 minor cleanup 2016-09-22 01:58:01 -07:00
smill@cuckoo.sh
ab546a7348 Introduced comment regarding socket manipulation through the server_conn stub. 2016-09-22 08:29:07 +00:00
smill@cuckoo.sh
3962a11575 Commented on IP_TRANSPARENT and changed an exception type. 2016-09-22 08:15:34 +00:00
Maximilian Hils
9e0b935fa2 Merge pull request #1564 from mhils/issue-1554
Fix Response.make content-length header
2016-09-21 21:49:14 -07:00
Maximilian Hils
0b532789a0 fix Response.make content-length header 2016-09-21 20:34:01 -07:00
Maximilian Hils
770936f1f9 raise TypeError on invalid header assignment, fix #1562 2016-09-21 19:21:32 -07:00
smill
83a28021ad Fixed travis-ci issues. 2016-09-14 19:11:57 +00:00
smill
9429f1bc7b Prevent crash in case of a connection timeout. 2016-09-14 19:10:13 +00:00
Schamper
5728a1c900 Make 'none' synonymous to 'identity' 2016-09-06 17:00:08 +02:00
Schamper
c16417248c Also fix for encoding 2016-09-06 10:37:24 +02:00