Archlinux 添加 GoAgent 代理
sudo使用命令补全功能

GoAgent_Linux

Sandy posted @ Jan 11, 2014 01:00:44 PM in Ubuntu with tags ubuntu GoAgent , 4439 阅读

这里以ubuntu系统为例,其他Linux系统自行根据对应系统安装命令安装所需模组 ××××简化版××××

Notice: 其他系统可能需要自行解决相关依赖问题

MAC用户可以使用GoAgentXBreakWall

依赖Dependence

  • 必选
    1. python2(建议安装python2.7,如需在Linux上传或安装gevent需先安装python-dev)
  • 可选
    1. gevent 1.0(提升多线程性能,强烈建议安装)
    2. greenlet (gevent的依赖,一般安装gevent会自动安装)
    3. python-vte(基于GTK的简单GUI所需)
    4. python-openssl(生成证书所需,强烈建议安装,如删除了goagent自动证书则必须安装)
    5. pycrypto(RC4加密所需,建议安装)
    6. python-appindicator(Unity桌面下的托盘组件,其他桌面不必安装)

Ubuntu

sudo apt-get libnss3-tools install python-dev python-greenlet python-gevent python-vte python-openssl python-crypto python-appindicator
  • 如果gevent版本是0.13则需要用下面的方法安装1.0版,python-appindicator为ubuntu专有,其他系统用户不用管,python-vte 位gtk托盘窗口所需,其他发行版请自行根据对应系统安装所需软件

 

安装gevent

需要在安装 python-dev 之后才能正确安装gevent和上传server,安装gevent需要安装了 gcc(Linux/Unix) 或 xcode(Mac OSX)。

sudo apt-get install python-dev python-pip && sudo pip install gevent --upgrade
如果greenlet版本低于0.4.0会导致gevent装不上,请先使用以下命令安装greenlet(0.4.2)
wget http://mirrors.aliyun.com/pypi/packages/source/g/greenlet/greenlet-0.4.2.zip# && unzip greenlet-0.4.2.zip && cd greenlet-0.4.2 && sudo python setup.py install
安装gevent(1.0)
wget http://mirrors.aliyun.com/pypi/packages/source/g/gevent/gevent-1.0.tar.gz && tar xvzpf gevent-1.0.tar.gz && cd gevent-1.0 && sudo python setup.py install
  • 也可以手动编译安装

如果不想安装gevent可以下载gevent-1.0dev-linux-x86.egg gevent-1.0dev-macosx-intel.egg放local文件夹

上传

下载goagent,解压,终端cd至goagent所在目录

python uploader.zip
  • 在server目录下,终端执行
  • 根据提示输入你自己创建的appid(若要同时上传多appid在appid之间用|隔开)和你的Gmail帐号和密码(如果开启了两步验证,密码为16位的应用程序专用密码)

运行客户端

在local目录下,终端执行

python proxy.py

也可以赋予proxy.py可执行权限之后直接双击proxy.py。(在proxy.py上面右击,属性的权限中勾选允许以程序执行文件)

直接运行goagent-gtk.py可以使用gtk托盘方式运行goagent。 运行addto-startup.py即可加入开机启动。也可以自行添加一个启动项,命令为

python /path/to/goagent/local/goagent-gtk.py

其中路径修改为自己系统中goagent-gtk.py的路径 使用sudo提权之后可以自动导入证书,部分浏览器请自行手动导入证书

退出

如 果是直接终端使用"python proxy.py"运行,在终端按"Ctrl+C"组合键可终止运行;如果使用gtk托盘,在托盘图标上右键菜单有退出选项。直接关闭终端窗口也会退出。 如果以后台进程运行,先用"ps aux | grep proxy.py"找到goagent的PID,然后直接kill对应的PID 。

ps aux|grep proxy.py|grep -v "grep"|awk '{print $2}'|xargs kill

How to install goagent in CentOS (include gevent) ?

see Issue 9400

 

浏览器设置

参见:https://code.google.com/p/goagent/wiki/InstallGuide#附:浏览器设置方法


以下内容一般不会用到

安装pyopenssl

  • PyOpenSSL是OpenSSL的python接口,用于提供加密传输支持(SSL),如果没用该模组,会导致goagent无法生成证书而影响使用。
    wget http://www.openssl.org/source/openssl-1.0.1c.tar.gz
    tar zxvf openssl-1.0.1c.tar.gz
    cd openssl-1.0.1c
    #设定Openssl 安装,( --prefix )参数为欲安装之目录,也就是安装后的档案会出现在该目录下
    ./config --prefix=/root/openssl 
    make && make install
    • 若系统没有openssl,先安装openssl,****一般系统都已安装,可以忽略此步****
  • 安装pyopenssl(0.13)(以下方法选择一种合适的即可)
    sudo apt-get install python-openssl
    sudo apt-get install python-pip
    sudo pip install pyOpenSSL
    wget http://pypi.python.org/packages/source/p/pyOpenSSL/pyOpenSSL-0.13.tar.gz && tar zxvf pyOpenSSL-0.13.tar.gz && cd pyOpenSSL-0.13 && sudo python setup.py install
    1. 从源安装,如果源中有的话
    2. 通过python包管理器pip安装
    3. 从源码编译安装

解决 GoAgent install certificate failed, Please run proxy.py by administrator/root/sudo

rm -rf ~/.pki  
mkdir -p ~/.pki/nssdb  
certutil -d ~/.pki/nssdb -N   

 

how to check CIBIL s 说:
2022年8月06日 03:30

Before we show you how you can check CIBIL score, first know that TransUnion CIBIL is an organization and an entity gathers all the consumer’s loan, credit, payment and money related transaction, and this gives a general behavior example and statics allowing to generate a score for each customer also calls as CIBIL score. In simple words, every individual based on their payment choices, credit decisions and money pertains may rank and given CIBIL score points which range up to 900 points. how to check CIBIL score In the sense, if the customer receives anything above 750 – 900, then they have high credit affinity. With this the banks and loan facilities may happy to lend credit to them. But in case if the CIBIL score for you is anywhere less than 750 or even worse then there are high chances that you will reject any loans, EMI, or credit requests. Because loan facilities and banks would consider your CIBIL Score as a baseline for approving those requests.

AP 10th General Scie 说:
2022年9月17日 07:19

All Andhra Pradesh State Class 10th (SSC) Students can download AP SSC Science model paper 2023 with Answer solutions in Chapter by Chapter for Physical Science, Chemistry, Biological Science and Environmental science for AP SSC Science Model Paper 2023 examination test for Unit Test-1, Unit Test-2, AP 10th General Science Question Paper Unit Test-3, Unit Test-4, and Quarterly, Half Yearly, Pre-Final with Annual final examination tests 2023. The Andhra Pradesh State Board of Secondary Education has published the General Science model paper with study material with practice paper with mock test question bank as AP 10th Biology, PS, Chemistry Model Paper 2023 for all examination tests conducted by BSEAP.


登录 *


loading captcha image...
(输入验证码)
or Ctrl+Enter