aboutsummaryrefslogtreecommitdiffstats
path: root/test/netlib/http
Commit message (Collapse)AuthorAgeFilesLines
* add quote/unquote testsMaximilian Hils2016-07-241-2/+42
|
* remove content caching in netlib.http.MessageMaximilian Hils2016-07-231-33/+0
|
* fix content view cache invalidationMaximilian Hils2016-07-211-4/+0
|
* Fix netlib.utils.is_valid_hostAldo Cortesi2016-07-211-0/+9
| | | | | | | | - Don't crash when passed an empty string. This translated into an actual core crash, discovered while fuzzing with afl. - Taking a slice of length one out of bytes returns an integer, so the check for trailing period in this function never worked on Python3. - Add unit tests.
* fix-1366Thomas Kriechbaumer2016-07-161-4/+22
|
* preserve content-type parameter orderMaximilian Hils2016-07-151-1/+3
|
* Merge remote-tracking branch 'origin/master' into message-body-encodingMaximilian Hils2016-07-154-8/+29
|\
| * Test cookies.is_expired separatelyShadab Zafar2016-07-101-0/+21
| |
| * py3++Maximilian Hils2016-07-072-3/+3
| |
| * py3++Maximilian Hils2016-07-071-4/+4
| |
* | improve message content semanticsMaximilian Hils2016-07-152-13/+73
| |
* | raise ValueError if content-encoding is invalidMaximilian Hils2016-07-041-8/+10
| |
* | tests++Maximilian Hils2016-07-021-1/+43
| |
* | message.content -> .raw_content, implement .textMaximilian Hils2016-07-021-33/+84
|/ | | | | | | | | | | | | | | This PR improves our handling of HTTP message body encodings: - The unaltered message body is now accessible as `.raw_content` - The "content-encoding"-decoded content (i.e. gzip removed) content is not `.content`, as this is what we want in 99% of the cases. - `.text` now provides the "content-encoding"-decoded and then "content-type charset"-decoded message body. - The decoded values for `.content` and `.text` are cached, so that repeated access and `x.text = x.text` is cheap. - The `decoded()` decorator is now deprecated, as we can now just use `.content`. Similarly `HTTPMessage.get_decoded_content()` is deprecated.
* move custom HTTP/2 stack from netlib to pathodThomas Kriechbaumer2016-06-172-544/+1
|
* Use handlers in http2 test suiteAldo Cortesi2016-06-141-100/+100
|
* be more strict about module namespacesMaximilian Hils2016-05-311-2/+1
|
* http2.frame -> http2.framereaderAldo Cortesi2016-05-311-3/+3
|
* Fix test failuresAldo Cortesi2016-05-311-1/+1
|
* Satisfy flake8Aldo Cortesi2016-05-312-0/+2
|
* utils.multipartdecode -> http.multipart.decodeAldo Cortesi2016-05-312-0/+33
| | | | | | also utils.parse_content_type -> http.headers.parse_content_type
* netlib.utils.get_header_tokens -> netlib.http1.read.get_header_tokensAldo Cortesi2016-05-311-1/+12
| | | | Placing this next to its only use.
* Module is part of the name - url.decode, not url.urldecodeAldo Cortesi2016-05-311-20/+20
| | | | A pattern we need to use far more often in the codebase
* Extract url functions from netlib.utils and move to netlib.http.urlAldo Cortesi2016-05-311-0/+65
|
* Start cleaning up netlib.utilsAldo Cortesi2016-05-311-13/+13
| | | | | - Remove http2 functions, move to http2.frame - Remove Serializable, move to netlib.basetypes
* Improve handling of pseudo-headersAldo Cortesi2016-05-311-1/+4
| | | | | | | | | - The canonical source for :method, :scheme and :path are the .method, .scheme and .path attributes on the request object. - These pseudo-headers are stripped after reading the request, and re-inserted just before sending. - The :authority header remains, and should be handled analagously to the Host header in HTTP1 with respect to display and user interaction.
* fix headers orderThomas Kriechbaumer2016-05-291-1/+1
|
* more style cleanupThomas Kriechbaumer2016-05-293-3/+4
|
* more style cleanupThomas Kriechbaumer2016-05-293-14/+19
| | | | Use this to check: flake8 --count mitmproxy netlib pathod examples test
* fix testsMaximilian Hils2016-05-283-4/+4
|
* cleanup imports with flake8Thomas Kriechbaumer2016-05-284-6/+2
|
* Clean un-needed importsAldo Cortesi2016-05-211-2/+0
|
* tests++Maximilian Hils2016-05-201-98/+1
|
* improve MultiDict, add ImmutableMultiDict, adjust response.cookiesMaximilian Hils2016-05-183-24/+26
|
* add MultiDictMaximilian Hils2016-05-186-46/+45
| | | | | | | | 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.
* Merge pull request #1121 from Kriechi/fix-cookiesThomas Kriechbaumer2016-05-113-4/+13
|\ | | | | improve cookie parsing
| * improve cookie parsingThomas Kriechbaumer2016-05-103-4/+13
| | | | | | | | | | allows '/' to be within a cookie name removes deprecated cookie getter/setter fixes #1118
* | actually fix testsMaximilian Hils2016-05-101-2/+2
| |
* | Revert "fix tests"Maximilian Hils2016-05-101-2/+2
| | | | | | | | This reverts commit f315dc1eb9f4701548fd57bbb38de1e9caa34e40.
* | fix testsMaximilian Hils2016-05-101-2/+2
|/
* fix #1120Maximilian Hils2016-05-091-0/+12
|
* Merge branch 'better-replace'Maximilian Hils2016-04-031-0/+19
|\
| * improve .replace() and move it into netlibMaximilian Hils2016-04-021-0/+19
| |
* | Merge pull request #1074 from mitmproxy/move-response-refreshThomas Kriechbaumer2016-04-032-0/+39
|\ \ | | | | | | move HTTPResponse.refresh into netlib
| * | move HTTPResponse.refresh into netlibMaximilian Hils2016-04-022-0/+39
| |/
* | Merge pull request #1073 from mitmproxy/first-line-formatThomas Kriechbaumer2016-04-031-6/+6
|\ \ | | | | | | form_(in|out) -> first_line_format
| * | form_(in|out) -> first_line_formatMaximilian Hils2016-04-021-6/+6
| |/
* / response.msg -> response.reasonMaximilian Hils2016-04-021-2/+2
|/
* replace CONTENT_MISSING with None.Matthew Shao2016-03-261-3/+3
|
* netlib: request.path can be NoneMaximilian Hils2016-03-201-1/+6
|