利用shadowsocks做socket代理

项目地址 :

https://github.com/clowwindy/shadowsocks

安装方法:

apt-get install python-pip python-m2crypto supervisor
pip install shadowsocks

配置文件 :

{
    "server":"my ip",
    "server_port":8388,
    "local_port":1080,
    "password":"my password",
    "timeout":600,
    "method":"aes-256-cfb"
}

保存到 /etc/shadowsocks.json,server 与 client 共用一个配置文件 。

然后 在server端启动:

ssserver -c /etc/shadowsocks.json

客户端启动:

sslocal -c /etc/shadowsocks.json

配置supervisor来管理进程:

/etc/supervisor/conf.d/shadowsocks.conf

[program:shadowsocks]
command=ssserver -c /etc/shadowsocks.json
autorestart=true
user=nobody