【OI人生向】科学上网

之前由TYH帮忙,已经搭建起了switchy omega + shadowsocks的科学上网方式
但近日,因为种种原因,switchy omega对于域名的识别有了问题,造成了极不愉快的翻墙体验
经过多方了解,得知直接根据ip地址是否在国内来决定上网方式比较快,于是进行了尝试

因为家里的主路由器是TP-LINK的,所以不能再路由器处处理这件事
于是又打上了switchy omega的主意
经过多方查找,找到了这个项目:https://leaskh.com/blog/2011/12/02/
其中提供了一个很好的思路:使用本地pac
于是说干就干,把上面的python搞下来,改到3.5.1的语言规范(改后的代码:http://paste.ubuntu.com/22663339/
然后生成.pac, 之后再把末尾处的语句改为下图所示,以适应本地的omega:
12348645457854
然后就大功告成啦! 撒花~ *★,°*:.☆( ̄▽ ̄)/$:*.°★* 。

之后测试一下效果,国外的网站都是秒开,国内的网站更是秒开!
4158674865415345
世界瞬间安静了!辣鸡百度去死吧!

—–2016.8.9更新—–
之前的.pac文件是暴力遍历,查找的速度太慢了
后来又看到了这个项目:https://www.v2root.com/gai-jin-ban-de-fan-qiang-pacwen-jian/
所以现在自用的pac已经改成了,上述项目所提供的文件。

4 thoughts to “【OI人生向】科学上网”

  1. I do agree with all the ideas you have presented in your post. They are very convincing and will certainly work. Still, the posts are very short for novices. Could you please extend them a little from next time? Thanks for the post.

Leave a Reply

Your email address will not be published. Required fields are marked *