aboutsummaryrefslogtreecommitdiffstats
path: root/mitmproxy/utils
Commit message (Collapse)AuthorAgeFilesLines
* Merge pull request #3691 from mhils/sans-io-adjustmentsMaximilian Hils2019-11-122-9/+10
|\ | | | | Update mypy, sans-io adjustments
| * update mypyMaximilian Hils2019-11-122-9/+10
| |
* | make duration formatting more forgivingMaximilian Hils2019-11-071-1/+3
|/
* Fix several DeprecationWarning: invalid escape sequenceMickaël Schoentgen2019-01-051-2/+2
| | | | Signed-off-by: Mickaël Schoentgen <contact@tiger-222.fr>
* Such CI, Very Wow. (#3182)Maximilian Hils2018-06-021-14/+2
|
* cadir -> confdirAldo Cortesi2018-05-101-3/+3
| | | | | We store a lot more than just the CAs in our configuration directory. Clarify the option name.
* Python 3.5 is dead -- long live Python 3.6!Thomas Kriechbaumer2018-03-311-12/+3
| | | | fixes #2266
* don't crash if server address is unknown, fix #2969Maximilian Hils2018-03-231-1/+3
|
* Fix --socks option deprecated info in command line args check.Deepesh Pathak2018-02-251-2/+3
|
* stateobject: use typing, enable tuples and more complex datatypesMaximilian Hils2018-01-131-19/+37
|
* Fix #2762 (#2763)Samoilenko Roman2018-01-061-2/+2
| | | | s/console_order/view_order s/console_order_reversed/view_order_reversed
* Merge pull request #2733 from mitmproxy/pyinstallerMaximilian Hils2017-12-301-30/+11
|\ | | | | Update PyInstaller, add dev version info to builds.
| * single-source version processingMaximilian Hils2017-12-301-30/+11
| |
* | Display "*" when listening on all interfacesMaximilian Hils2017-12-261-0/+2
|/ | | | | | | | | | The set of people who understand "0.0.0.0" (and/or "::") is a subset of the set of people who understand "*", so we can make things easier to understand by using the less technical notation. Empirical Evidence: - https://discourse.mitmproxy.org/t/unable-to-use-mitmproxy-on-windows/735 - https://discourse.mitmproxy.org/t/how-to-view-the-proxy-servers-url/23
* types: use new type validation mechanism in commandsAldo Cortesi2017-12-191-35/+0
|
* introduce @command.argumentMaximilian Hils2017-12-141-1/+1
| | | | | | This makes it possible to specify more specific type annotations at runtime, so that both mypy and our command system are happy. The .argument(name, type=) syntax is similar to click's, so it should be fairly extensible if we need it.
* commands: formalise a Choice typeAldo Cortesi2017-12-131-1/+1
| | | | | | | | | This resolves as a string during MyPy checks, but at runtime has an additional attribute that is a command that returns valid options. This is very ugly and clumsy, basically because MyPy is super restrictive about what it accepts as a type. Almost any attempt to construct these types in a more sophisticated way fails in one way or another. I'm open to suggestions.
* simplify version outputMaximilian Hils2017-10-242-54/+33
|
* make split_special_areas more flexible, refs #2537Maximilian Hils2017-09-031-12/+10
| | | | (cherry picked from commit 31ef7f149e4553eb9403634c0eec6de4d0123386)
* fix strutils.split_special_areasMaximilian Hils2017-08-261-2/+2
|
* add strutils.escape_special_areasMaximilian Hils2017-08-241-1/+86
|
* Improve options UXUjjwal Verma2017-08-071-0/+148
|
* remove OptManager._processedMaximilian Hils2017-07-311-1/+10
| | | | | | | | | | | | Instead of having the core addon do postprocessing on body_size_limit, we add a cache to the parsing function. First, this avoids any potential issues with options and _processed getting out of sync. As anecdotal evidence, the previous implementation did not clear _processed when body_size_limit was reset to None. Second, it achieves the same end result without introducing a new concept of a "_processed" scratch space. Third, it works even if addons aren't present, and does not require workarounds as previously present in test_http2.py. refs https://github.com/mitmproxy/mitmproxy/pull/2484#pullrequestreview-53101507
* nuke old opensslThomas Kriechbaumer2017-07-251-42/+0
|
* update mypyMaximilian Hils2017-07-201-1/+1
|
* Minor Update for /options API of mitmweb.Matthew Shao2017-06-241-2/+2
|
* Add typesepc_to_str function to mitmproxy/utils/typechck.pyMatthew Shao2017-06-131-0/+12
|
* commands: support *args for commandsAldo Cortesi2017-04-301-3/+3
| | | | | | Use this to simplify meta-commands in console, and to create a console_choose command that prompts the user for a choice, and then executes a command with variable substitution.
* Introduce cuts: a flow dissectorAldo Cortesi2017-04-292-3/+14
| | | | | | | | | | | | | | | | | This PR introduces the cuts addon, a flow dissector that allows you to select and operate on specific components of flows. It also adds the first consumer for cuts - the cuts.save command. Save the content of the focus to /tmp/foo: cuts.save s.content|@focus /tmp/foo Save the URL and response content-type headers for all flows currently shown to file, comma-separated, one flow per line: cuts.save s.url,q.header[content-type]|@focus /tmp/foo We also use this to replace the body save shortcut in the console flowlist.
* Merge pull request #2273 from cortesi/commandsAldo Cortesi2017-04-281-14/+30
|\ | | | | Commands
| * command: save.file flowspec path -> NoneAldo Cortesi2017-04-271-0/+2
| | | | | | | | | | | | | | | | | | Our first user-facing command. The following commands do the obvious things: save.file @marked /tmp/flows save.file @focus /tmp/flows save.file @hidden /tmp/flows save.file "~m get" /tmp/flows
| * console: flow resolution commandAldo Cortesi2017-04-271-0/+14
| | | | | | | | | | | | | | This is our first built-in command, which will be used by very many other commands. Also add a --commands option to dump all commands, analogous to --options.
| * Basic outline of the command subsystemAldo Cortesi2017-04-271-14/+14
| | | | | | | | | | - Add a command manager - Sketch out the type system with a few simple supported types
* | Merge pull request #2277 from Kriechi/bump-cryptographyThomas Kriechbaumer2017-04-271-7/+7
|\ \ | |/ |/| bump cryptography min-version
| * bump cryptography min-versionThomas Kriechbaumer2017-04-271-7/+7
| | | | | | | | This removes OpenSSL v0.9.8 support.
* | typecheck: add support for typing.AnyMaximilian Hils2017-04-261-0/+2
|/
* Fixes #2109Ujjwal Verma2017-04-091-1/+18
|
* Fix sliding window type specsAldo Cortesi2017-03-201-2/+2
|
* Make mypy succeed with imports on master.pyAldo Cortesi2017-03-191-1/+1
| | | | | | | | | | | | | | | | | | We get little benefit from our mypy QA checks at the moment, because we skip imports. This patch is what's needed to make mypy succeed with imports on a single file: master.py It also updates mypy to the current version, and enables a QA check. Mypy bugs I encountered: dict.update with kwargs not supported: https://github.com/python/mypy/issues/1031 property setters and getters must be adjacent: https://github.com/python/mypy/issues/1465
* Make mypy succeed with imports on master.pyAldo Cortesi2017-03-172-9/+9
| | | | | | | | | | | | | | | | | | We get little benefit from our mypy QA checks at the moment, because we skip imports. This patch is what's needed to make mypy succeed with imports on a single file: master.py It also updates mypy to the current version, and enables a QA check. Mypy bugs I encountered: dict.update with kwargs not supported: https://github.com/python/mypy/issues/1031 property setters and getters must be adjacent: https://github.com/python/mypy/issues/1465
* Revamp optionsAldo Cortesi2017-03-051-14/+5
| | | | | - Options are now explicitly initialized with an add_option method - We have one canonical Options class - ditch dump.Options
* Adds PyInstaller build indicator to --version argumentNikhil Soni2017-02-181-1/+5
|
* increase test coverageThomas Kriechbaumer2017-02-022-5/+6
|
* improve version specifiersThomas Kriechbaumer2017-01-231-1/+15
|
* provide git information with --versionThomas Kriechbaumer2017-01-193-7/+26
| | | | fixes #1848
* Revert "add strutils.replace_surrogates"Maximilian Hils2017-01-071-11/+0
| | | | This reverts commit 15ae88db08dbf2725c8c9f945f2006c4b2a10d46.
* add strutils.replace_surrogatesMaximilian Hils2017-01-071-0/+11
|
* minor encoding fixesMaximilian Hils2017-01-071-17/+17
| | | | | | - native() -> always_str() The old function name does not make sense on Python 3 only. - Inline utility functions in message.py.
* fix IO type checkingMaximilian Hils2016-12-281-0/+2
|
* fix compat with Python 3.5.0Maximilian Hils2016-12-281-8/+13
|