Skip to content

Latest commit

 

History

History
71 lines (47 loc) · 2.19 KB

README.md

File metadata and controls

71 lines (47 loc) · 2.19 KB

MITM Proxy

Man-In-The-Middle Proxy aim at expose NSS Key Log Format (Pre)-Master-Secret for Wireshark analysis.

[TOC]

Implement


+----------+         Self Signed Root Certificate
|  Client  | <-----------------------------------------------+        
+----------+       Certificate Signed by Self Root CA        |
     ^                                                       v
     |                                                  +----------+
     X No more Direct Communicate                       |   MITM   |
     |                                                  +----------+ 
     v                                                       ^
+----------+                                                 |
|  Server  | <-----------------------------------------------+
+----------+    Trusted Communicate as normal Client-Server 

Install

  1. You should guarantee your machine has installed Golang

  2. Clone Repository from GitHub

    git clone [email protected]:ffutop/mitmproxy.git
  3. Build and Install

    cd ${YOUR-PATH-TO-MITMPROXY-DIRECTORY}; go build; go install;
  4. Check Installation Result

    mitmproxy --help

Usage

  1. prepare your Root Certificate OR run mitmproxy to create a new Root Certificate

    newly created Root Certificate will be find at $HOME/.mitm/

  2. make sure your OS trust Root Certificate which prepare at "STEP 1"

  3. find config.yaml.example file, rename to config.yaml and edit

  4. run mitmproxy

    mitmproxy -config ${YOUR-PATH-TO-config-yaml}/config.yaml
  5. follow Wireshark: Using the (Pre)-Master-Secret and config your Wireshark configuration.

Sample ScreenShot

TODO

  • serve both http/https proxy on same port
  • support auto modify MacOS global proxy config