在安裝mitmproxy包是遇到以下問題。
通過1.pip install mitmproxy 安裝包時,
安裝如下依賴包中出錯。這是安裝cryptography包時缺失了模塊
網上所有方法全試過了,仍然無法解決。
於是我嘗試把之前修改過的全部還原。
解決方法:
去https://pypi.org/project/cryptography找到
自己python對應版本下載輪子。我選擇的是cryptography-2.9.2-cp38-cp38-win_amd64.whl,
最后把這個文件修改成cryptography-2.9.2-cp38-none-win_amd64.whl在執行pip install 這個whl就能安裝了。
2.pip install cryptography-2.9.2-cp38-none-win_amd64.whl
3. pip install pyOpenSSL
因為之前在安裝依賴包的時候出錯中斷了,這時候還有一個openssl沒裝入,在執行pip install openssl就行了。
用4. mitmweb --version測試,彈出版本沒報錯,ok
用國外路勁下載速度慢,推薦使用國內鏡像,即:pip install -i https://tuna.tsinghua.edu.cn/simple 包名.