ZMX - IT技术交流论坛 - 无限Perfect,追求梦想 - itzmx.com

标题: 本项目主要介绍如何利用国外Linux VPS搭建多协议代理服务,squid PAC代理服务器,25端口翻墙 [打印本页]

作者: 小樱    时间: 2015/4/19 00:02
标题: 本项目主要介绍如何利用国外Linux VPS搭建多协议代理服务,squid PAC代理服务器,25端口翻墙
[PAC](http://pac.itzmx.com/)
=======
本项目主要介绍如何利用国外Linux VPS搭建多协议代理服务。

GFW 封锁了 HTTP/Socks5 代理,HTTP 代理是关键词过滤,Socks5 代理则是封锁协议。不过某些特殊的低端口并没有这么处理,已知的有 21,25。

20端口已经被封杀,21端口目前会被限速400Kbps,换算后约合50KB/S,建议使用25端口,不限速。

[这里](http://pac.itzmx.com/) 提供了我在 [vultr](http://pac.itzmx.com/abc.pac) 上搭建的公共代理。

更新SQ防扫认证,登录信息为
帐号:root
密码:pac.itzmx.com


搭建代理服务器
==============
在 25 端口搭建 http/https 代理。

[dplayer=https://att.itzmx.com/1/pac.mp4]auto[/dplayer]


Ubuntu 16.10 x64(需要一行一行复制安装,默认密码admin123):
-------
  1. apt-get -y install squid
  2. curl http://github.itzmx.com/1265578519/PAC/master/squid/ubuntu-squid.conf > /etc/squid/squid.conf
  3. echo "root:ssbiY3prCJLxU" >> /etc/squid/passwd
  4. mkdir -p /var/cache/squid
  5. chmod -R 777 /var/cache/squid
  6. service squid stop
  7. squid -z
  8. service squid restart
复制代码



CentOS 6.8 x64(推荐用此系统):
-------
  1. setenforce 0
  2. ulimit -n 655350
  3. echo "* soft nofile 655350" >> /etc/security/limits.conf
  4. echo "* hard nofile 655350" >> /etc/security/limits.conf
  5. echo "alias net-pf-10 off" >> /etc/modprobe.d/dist.conf
  6. echo "alias ipv6 off" >> /etc/modprobe.d/dist.conf
  7. killall -9 sendmail
  8. /etc/init.d/postfix stop
  9. chkconfig --level 2345 postfix off
  10. chkconfig --level 2345 sendmail off
  11. yum -y install squid wget
  12. wget http://github.itzmx.com/1265578519/PAC/master/squid/centos-squid.conf -O /etc/squid/squid.conf
  13. echo "root:W10fM8VWO04aM" >> /etc/squid/passwd
  14. mkdir -p /var/cache/squid
  15. chmod -R 777 /var/cache/squid
  16. squid -z
  17. service squid restart
  18. chkconfig --level 2345 squid on
  19. iptables -t nat -F
  20. iptables -t nat -X
  21. iptables -t nat -P PREROUTING ACCEPT
  22. iptables -t nat -P POSTROUTING ACCEPT
  23. iptables -t nat -P OUTPUT ACCEPT
  24. iptables -t mangle -F
  25. iptables -t mangle -X
  26. iptables -t mangle -P PREROUTING ACCEPT
  27. iptables -t mangle -P INPUT ACCEPT
  28. iptables -t mangle -P FORWARD ACCEPT
  29. iptables -t mangle -P OUTPUT ACCEPT
  30. iptables -t mangle -P POSTROUTING ACCEPT
  31. iptables -F
  32. iptables -X
  33. iptables -P FORWARD ACCEPT
  34. iptables -P INPUT ACCEPT
  35. iptables -P OUTPUT ACCEPT
  36. iptables -t raw -F
  37. iptables -t raw -X
  38. iptables -t raw -P PREROUTING ACCEPT
  39. iptables -t raw -P OUTPUT ACCEPT
  40. service iptables save
复制代码


装完后记得reboot重启下服务器确保生效。

然后使用 [PAC](http://pac.itzmx.com/abc.pac) 右键另存为 PAC 文件后修改其中的server01.pac.itzmx.com为你的服务器IP即可。

转载注明出处:http://bbs.itzmx.com/thread-8815-1-1.html


推荐服务器:http://www.vultr.com/
优惠码:OWNCLOUD SSDVPS
赠送的20刀期限30天,注意使用。
注意点击小尾巴,才能享受到优惠哦


捐赠:http://pac.itzmx.com/donate/index.html


作者: 他笑颜如花    时间: 2015/4/19 00:02
提示: 作者被禁止或删除 内容自动屏蔽
作者: liuda    时间: 2015/4/19 16:48
我擦!我要2階!
作者: jinglinghuoer    时间: 2015/6/16 01:01
试下发言功能
作者: jinglinghuoer    时间: 2015/6/16 01:03
你的方法确实有效 不过pac文件使用了国内一个普通主机代理国内网址 难道访问速度更快?
作者: jinglinghuoer    时间: 2015/6/16 01:06
对了,看了pac文件感觉网址收集的还是很全的嘛,怎么弄的?请教下
作者: 小樱    时间: 2015/6/16 13:48
jinglinghuoer 发表于 2015/6/16 01:06
对了,看了pac文件感觉网址收集的还是很全的嘛,怎么弄的?请教下

https://github.com/clowwindy/gfwlist2pac
这里可以获取pac文件每日更新,当然一般不需要,更新一次就可以了,然后有什么需要的网址自己手动补充一下即可
作者: 小樱    时间: 2015/6/16 13:50
jinglinghuoer 发表于 2015/6/16 01:03
你的方法确实有效 不过pac文件使用了国内一个普通主机代理国内网址 难道访问速度更快?

squid来说不具备缓存功能。可以尝试使用kangle等支持存储缓冲器的web server
作者: 幻想飞的鱼    时间: 2015/6/17 11:56
先感谢lz提供了这个简单实用的翻墙方法.
不过今天突然就用不了了,很多网站都是连接超时,例如批评空间 getchu.想请问下lz有什么补救办法吗
作者: 小樱    时间: 2015/6/17 12:39
幻想飞的鱼 发表于 2015/6/17 11:56
先感谢lz提供了这个简单实用的翻墙方法.
不过今天突然就用不了了,很多网站都是连接超时,例如批评空间 getc ...

服务器有DDOS攻击,刚上电脑,稍后进行修复
(, 下载次数: 573)