diff options
Diffstat (limited to 'docs/dev')
-rw-r--r-- | docs/dev/architecture.rst | 14 | ||||
-rw-r--r-- | docs/dev/sslkeylogfile.rst | 14 | ||||
-rw-r--r-- | docs/dev/testing.rst | 46 |
3 files changed, 74 insertions, 0 deletions
diff --git a/docs/dev/architecture.rst b/docs/dev/architecture.rst new file mode 100644 index 00000000..ba902fab --- /dev/null +++ b/docs/dev/architecture.rst @@ -0,0 +1,14 @@ +.. _architecture: + +Architecture +============ + +To give you a better understanding of how mitmproxy works, mitmproxy's +high-level architecture is detailed in the following graphic: + +.. image:: ../schematics/architecture.png + +:download:`architecture.pdf <../schematics/architecture.pdf>` + +Please don't refrain from asking any further +questions on the mailing list, the Slack channel or the GitHub issue tracker.
\ No newline at end of file diff --git a/docs/dev/sslkeylogfile.rst b/docs/dev/sslkeylogfile.rst new file mode 100644 index 00000000..d61a10c0 --- /dev/null +++ b/docs/dev/sslkeylogfile.rst @@ -0,0 +1,14 @@ +.. _sslkeylogfile: + +TLS Master Secrets +================== + +The SSL master keys can be logged by mitmproxy so that external programs can decrypt TLS connections +both from and to the proxy. Key logging is enabled by setting the environment variable +:envvar:`SSLKEYLOGFILE` so that it points to a writable text file. +Recent versions of WireShark can use these log files to decrypt packets. +You can specify the key file path in WireShark via +:samp:`Edit -> Preferences -> Protocols -> SSL -> (Pre)-Master-Secret log filename`. + +Note that :envvar:`SSLKEYLOGFILE` is respected by other programs as well, e.g. Firefox and Chrome. +If this creates any issues, you can set :envvar:`MITMPROXY_SSLKEYLOGFILE` alternatively.
\ No newline at end of file diff --git a/docs/dev/testing.rst b/docs/dev/testing.rst new file mode 100644 index 00000000..242e0584 --- /dev/null +++ b/docs/dev/testing.rst @@ -0,0 +1,46 @@ +.. _testing: + +Testing +======= + +All the mitmproxy projects strive to maintain 100% code coverage. In general, +patches and pull requests will be declined unless they're accompanied by a +suitable extension to the test suite. + +Our tests are written for the nose_ test framework. +At the point where you send your pull request, a command like this: + +>>> nosetests --with-cov --cov-report term-missing ./test + +Should give output something like this: + +.. code-block:: none + + > ---------- coverage: platform darwin, python 2.7.2-final-0 -- + > Name Stmts Miss Cover Missing + > ---------------------------------------------------- + > libmproxy/__init__ 0 0 100% + > libmproxy/app 4 0 100% + > libmproxy/cmdline 100 0 100% + > libmproxy/controller 69 0 100% + > libmproxy/dump 150 0 100% + > libmproxy/encoding 39 0 100% + > libmproxy/filt 201 0 100% + > libmproxy/flow 891 0 100% + > libmproxy/proxy 427 0 100% + > libmproxy/script 27 0 100% + > libmproxy/utils 133 0 100% + > libmproxy/version 4 0 100% + > ---------------------------------------------------- + > TOTAL 2045 0 100% + > ---------------------------------------------------- + > Ran 251 tests in 11.864s + + +There are exceptions to the coverage requirement - for instance, much of the +console interface code can't sensibly be unit tested. These portions are +excluded from coverage analysis either in the **.coveragerc** file, or using +**#pragma no-cover** directives. To keep our coverage analysis relevant, we use +these measures as sparingly as possible. + +.. _nose: https://nose.readthedocs.org/en/latest/
\ No newline at end of file |