1. Update yum
yum update
2. Install gcc
yum install gcc
3. Install c++
yum install gcc-c++
4. Install Python 3.7.3
Modify the default Python version of Centos7
5. Install mitmproxy
pip install mitmproxy
6. Check if the installation is successful
[root@iZ7etebl1lxmysZ ~]# mitmproxy --version
Mitmproxy: 5.1.1
Python: 3.7.4
OpenSSL: OpenSSL 1.1.1g 21 Apr 2020
Platform: Linux-3.10.0-862.14.4.el7.x86_64-x86_64-with-centos-7.8.2003-Core