Parrot 3.6 安装mitmproxy

最近需要实现高度自定义的代理,要满足HTTP、HTTPS请求和响应的修改,跨平台,尽可能的轻量和使用简单,最终选定使用mitmproxy.

mitmproxy是一款支持HTTP(S)的中间人代理工具。不同于Fiddler2,burpsuite等类似功能工具,mitmproxy可在终端下运行。mitmproxy使用Python开发,是辅助web开发&测试,移动端调试,***测试的工具。

安装

  • python3.5 -m pip install mitmproxy

报异常: /usr/bin/python3.5: No module named pip
解决: sudo apt-get install python3-pip
然后重复执行 python3.5 -m pip install mitmproxy

  • 报异常: 比较关键的内容

1, error: command 'x86_64-linux-gnu-gcc' failed with exit status 1
2, fatal error: openssl/opensslv.h: No such file or directory
3, Failed building wheel for cryptography
4, Command "/usr/bin/python3.5 -u -c "import setuptools,tokenize;file='/tmp/pip-build-ozmfhujz/cryptography/setup.py';f=getattr(tokenize, 'open',open)(file);code=f.read().replace('\r\n', '\n');f.close();exec(compile(code, file, 'exec'))" > install --record /tmp/pip-iuzqegy5-record/install-record.txt --single-version-externally-managed --compile > --user --prefix=" failed with error code 1 in /tmp/pip-build-ozmfhujz/cryptography/
解决方式: sudo apt-get install libssl-dev