Centos上ShadowSocks搭建Socket5服务器
买的VPN最近好像跑路了,看了下阿里云的国外ECS,超便宜,美国西部做活动一年才300多RMB;
Shadowsock是一个安全的socks5代理软件,提供了服务端和客户端;可以很方便的搭建一个VPN;
服务器端搭建
Section titled “服务器端搭建”$ wget –no-check-certificate https://raw.githubusercontent.com/teddysun/shadowsocks_install/master/shadowsocks.shchmod +x shadowsocks.sh$ ./shadowsocks.sh 2>&1 | tee shadowsocks.log安装成功会显示如下的信息,将下面的信息填写到客户端里面就可以了;
Starting Shadowsocks success
Congratulations, Shadowsocks-python server install completed!Your Server IP : 47.88.56.208Your Server Port : 8989Your Password : xxxxYour Encryption Method: rc4-md5
Welcome to visit:https://teddysun.com/342.htmlEnjoy it! )
这里需要特别注意的是,有些socks5客户端提供了将socks5转为http(s)的功能,这里要选则socks5。
Privoxy配置
Section titled “Privoxy配置”Privoxy可以将socks5转为http(s)协议;
forward-socks5 / 127.0.0.1:1080 .sudo apt-get install privoxy//开启privoxy 服务就行sudo service privoxy start// 设置http 和 https 全局代理export http_proxy='http://localhost:8118'export https_proxy='https://localhost:8118'// 测试一下wget https://www.google.com使用Privoxy将socks5代理转为http代理 Mac上Privoxy将shadowsocks的socks5代理转为http代理(解决SublimeText无法安装插件的问题)