翻墙七种武器之霸王枪:Shadowsocks

文/
Vergil

古龙先生在《七种武器之霸王枪》一文中是这样描述这把神兵利刃的,“霸王。力拔山兮气盖世。枪,百兵之祖是为枪,霸王枪长一丈三尺七寸三分,重七十三斤七两三钱。江湖中其实很少有人亲眼见到这霸王枪。可是江湖中每个人都知道,世上最霸道的七种兵器,就有一种是霸王枪。普天之下,独一无二的霸王枪。”

随着今年六月以来大陆网络环境进一步恶化,Google 全系列产品再次被干扰至今无法正常使用,导致依托于 Google App Agine的 Goagent 也变得不听使唤,而Lantern 被墙之后一直未能恢复元气,免费翻墙工具们第一次遇到全方位的威胁。

如果实在不想掏钱去买那些专业的商用翻墙服务,同时自己或身边的朋友手头上空闲一台 VPS,如果对 Linux 系统命令行有一个基本的认识,那么你可以尝试在VPS服务器上自行搭建 Shadowsocks(Goagent是搭建在Google服务器上的)。或者说你不愿意耗费精力搭建,可以直接跳过本文中“服务器设置端”的内容,直接看“本地客户端”设置,然后填入公共服务器的地址,同样可以享受到免费快速的翻墙服务。

Shadowssocks采用socks代理,设置虽然复杂,但翻墙效果稳定流畅,比Http代理更难以识别,多平台支持,目前难以为GFW所屏蔽。正如霸王枪一样,虽然沉重无比难以施展,但如果被具备天生神力的西楚霸王项羽所用,则立时化成一柄横扫千军、所向披靡无往不胜的百兵之王。

一、配置环境准备

  • 一台闲置的VPS,可以使用免费试用一年的 Amazon EC2主机,也可以使用便宜的 DigitalOcean最低配的新加坡主机
  • VPS上预装好 linux 系统,可以是 Debain 或 Ubuntu,我们这里以流行的 Ubuntu 为例;
  • 具备基本的命令行基础和纯文本编辑能力。

二、服务器端设置

首先确保系统安装了 Python 2.6 或2.7:

1

python –version

下面开始安装软件包:

1

2

apt-get install build-essential python-pip python-m2crypto python-dev

pip install gevent shadowsocks

创建一个配置文件 /etc/shadowsocks.json

1

2

3

4

5

6

7

8

9

    "server":"服务器 IP 地址",     #VPS的IP地址

    "server_port":8388,     #监听的端口

    "local_address": "127.0.0.1",     #本地监听的IP地址,默认为主机

    "local_port":1080,                #本地监听的端口

    "password":"mypassword",          #服务密码

    "timeout":300,                    #用于加密的密码

    "method":"aes-256-cfb",           #加密方法,推荐 "aes-256-cfb"

    "fast_open": false,               #是否使用 TCP_FASTOPEN, true / false

    "workers": 1     #worker 数量,Unix/Linux 可用,如果不理解含义请不要改

设置完毕保存配置文件,然后在命令行下输入:

1

ssserver -c /etc/shadowsocks.json

为了保证此项服务一直在后台运行,可以使用 Supervisor 工具:

1

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

新建 Supervisor 的配置文件shadowsocks.conf

1

2

3

4

[program:shadowsocks]

command=ssserver -c /etc/shadowsocks.json

autorestart=true

user=nobody

继续编辑这个文件/etc/default/supervisor,并在文件末尾添加如下代码:

1

ulimit -n 51200

更新服务,开始运行:

1

2

service supervisor start

supervisorctl reload

下面的命令告诉你如何结束以及重新启动 Shadowsocks 服务:

1

2

supervisorctl stop shadowsocks

supervisorctl start shadowsocks

你也可以通过下面命令来查看此进程的日志文件:

1

supervisorctl tail -f shadowsocks stderr

你也可以通过访问 VPS 的9001端口查看系统运行状态,关于 Supervisor 更多的命令使用可以访问它的官方网站

好了,服务器端的设置完毕了,下面进入客户端(本地)设置环节:

三、本地设置

服务器正常运行后,我们还需要在本地电脑上安装客户端进行转发,和使用 SSH 翻墙的原理如出一辙,首先根据本地电脑系统的情况进入此页面下载对应的客户端:

下载完成后运行,然后依次填入上面 shadowsocks.json 配置文件中的选项,然后保存,可以看到客户端提示已连接:

接下来我们需要再 Firefox 和 Chrome 客户端上安装好 AutoProxy 或 Proxy SwitchySharp 插件,然后进行如下设置:

1

2

3

协议: socks5

地址: 127.0.0.1

端口: 你填的 local_port 默认是1080

四、手机平台设置

Shadowsocks不仅仅局限于PC桌面应用,它还可以在例如 IOS 和 Android 平台上广泛应用,IOS平台上直接在 Appstore 里搜索“shadowsocks”,app打开之后是一个浏览器,内置了免费的公共服务器,如果公共服务器出现运行不稳定的情况,这时就可以按照上述的方法在VPS中安装好 shadowssocks 就可以翻墙访问了。当然要想全面使用 Socks 代理最好是先越狱。

Andorid 平台也是如法炮制,只不过在 GooglePlay 里要改为搜索“影梭”,具体使用方法和IOS平台基本一致,只不过不是在浏览器而是在专有客户端中进行设置。

虽然整个设置过程比较繁琐,特别是还需要租用VPS并和枯燥的命令行打交道(我估计现在没有几个非专业的计算机课程还在讲DOS了),但只要热爱互联网,乐于接受新鲜事物,特别是对于自由互联网空间的渴望,那么一切都不会成为障碍,还是用《霸王枪》里的一句话送给各位共勉:

霸王枪是勇气,一个人只要有勇气去冒险,天下就绝没有不能解决的事。”

评论

做了个免费ssh帐号分享网
http://nionpay.com/
求支持,求分享......................

现在goagent也靠不住了,shadowsock应该还可以,就是搭建过程太复杂了

vps还是最好的选择,墙高一尺,道高一丈,技术是永远都无法完全封锁的。shadowsock确实不错

I can see that your content probably doesn't have much traffic.
Your posts are interesting, you only need more new readers.
I know a method that can cause a viral effect on your site.

Search in google: dracko's tricks make your content go viral

Look at my website: <a href="https://Daltonfat.blogspot.se">99Numbers</a>

It's awesome to pay a quick visit this site and reading
the views of all colleagues on the topic of this piece of writing, while
I am also keen of getting knowledge.

my site ... store bryster - https://bigboobsdaily.blogspot.com/search/label/store%20bryster

A Clever Way to Find Free Adult Chat Rooms!

Chatting over the web is hugely popular. The problem is you can find
few free adult chat rooms where we can discuss adult topics.
Due to their popularity, web owners increasingly choose to charge for your service.
In this article, you will see how to locate fairly easily a huge selection of these chat
communities, many of which are entirely free.
It is becoming hard to find good places for adults to speak.

Most of this is due to spread of instant messengers, virtual worlds, and social support
systems. The few good chat sites available are generally full or,
worse still, full and intent on asking you to pay a regular membership fee.
To most of us, it appears purchasing of proper, fun, lively free
places for adults to have an adult chat have died. Thankfully, there is certainly a significant clever method for us to still find good rooms.

All in the big dating communities offer their members free adult forums.
Now, I'm sure you're thinking, "Yes, that paid dating sites also ask you for a subscription of those free rooms!" This is not
always true. Many such chat communities cost nothing, others
have the freedom but have limited features for the non-paying members, yet others
still give you a free of charge service for ladies.
The great thing about joining a large, well-known dating community is that
you get given entry to a tremendous adult chatting community containing hundreds, sometimes lots of people utilizing it at anybody
time. Better yet, their rooms tend to offer users the opportunity to hook in their webcams.
So you could be chatting away in a very room and have the ability to click a user profile and view them on his or her webcam, too!

Free Adult Chat Rooms : https://goo.gl/ETrLYm

my blog - <a href="https://goo.gl/XBfzsn">sex chat</a>

pao-pao.net is interesting, but you must improve
graphics design

My web site https://www.youtube.com/watch?v=wI_GUT3TgTo - https://www.youtube.com/watch?v=wI_GUT3TgTo

I have noticed you don't monetize your website, don't waste your
traffic, you can earn extra bucks every month.
You can use the best adsense alternative for any
type of website (they approve all websites), for more details simply search
in gooogle: boorfe's tips monetize your website

my web-site: <a href="https://MightyAugustina.blogspot.co.uk">BestCollin</a>

A person essentially lend a hand to make seriously posts
I would state. This is the very first time I frequented your web page and so far?

I surprised with the analysis you made to make this particular submit amazing.

Fantastic task!

My blog - wtfuck303 - https://twitter.com/wtfuck303

Hey, I think your site might be having browser compatibility issues.
When I look at your blog in Opera, it looks fine but when opening in Internet Explorer, it has
some overlapping. I just wanted to give you a quick heads up!

Other then that, superb blog!

my blog :: sex oferty - https://www.xvideos.com/tags/sex-anonse

My programmer is trying to persuade me to move to .net from PHP.
I have always disliked the idea because of the expenses.
But he's tryiong none the less. I've been using WordPress on a number of websites for about a year and am worried about switching to
another platform. I have heard very good things about
blogengine.net. Is there a way I can import all my wordpress posts into it?
Any kind of help would be greatly appreciated!

Feel free to visit my web page: <a href="https://is.gd/e4b8nL">cambabe</a>

I think what you said was actually very logical. But, what
about this? suppose you were to create a awesome headline?
I mean, I don't want to tell you how to run your blog, but what if you added a headline
that makes people want more? I mean 冒个泡吧! | 泡泡 is a little vanilla.
You could look at Yahoo's front page and watch how they create news titles to get viewers interested.
You might try adding a video or a pic or two to grab people excited about everything've written. In my opinion, it could make your blog a little livelier.

Here is my web blog buy bitcoins with paysafecard - https://www.youtube.com/watch?v=kr2hTUnEwI4

Hello. I have checked your pao-pao.net and i see you've got some duplicate content
so probably it is the reason that you don't rank high in google.
But you can fix this issue fast. There is a tool that creates content like
human, just search in google: miftolo's tools

My blog - <a href="https://JulianFix.blogspot.com">GenevaBig</a>

The Positive Effects of Reiki around the Human Body

Reiki is known for its positive results about the human body.

However, many individuals of those that never have yet experienced its power determine what exactly Reiki does and what its effects are.
If you are considering the way in which Reiki can assist
you, then please read on to see what Reiki are capable of
doing for your body, mind and soul.
1. Increases one's body's capacity to heal itself.
Normally, one's body includes a defense system which functions good providing the Ki flow just isn't interrupted.
When the Ki is no longer capable of flow through one's
body, illnesses and diseases can appear. Reiki stimulates the flow of positive energy, thus enabling one's body to heal
itself and fight the external and internal attacks
more efficiently.
2. Cleans one's body coming from all toxins. Because
it acts on the physique, it can be one of the few complete detox programs you can follow.

In addition to that it doesn't involve refraining from food or other type
of activity. Yet, mental poison have to be banned through the individual's mind while they may have a negative impact upon the treatment.

3. Promotes health, positive thoughts and relaxation.
The principles of Reiki depend upon positive thinking, thus
a peace of mind and relaxation is induced towards the individual.
By removing negative energy and promoting a sense of peace, the recovery process will probably be
easier and shorter, whatever the illness or disease from which the consumer suffers.

4. Works on the digestive tract and improves the benefic connection between every thing somebody ingests,
from food and water to medicines and curative herbs.
Thus, it could be used successfully as a complementary therapy for the
people already taking medicine, but simultaneously it can be perfect for maintain the individual's health in good parameters.

5. Works on personal feelings, helping people defeat negative
experiences from their lives and coping with unexpected or unpleasant situations from other lives.
People with depressions, anxieties or struggling with stress are able to see dramatic improvements of these conditions
following the Reiki sessions.
6. Makes the transition from life to death less difficult.
It helps the soul transcend into immortality and one's
body feel less suffering from this transformation. This is why many
Reiki adepts use the Ki to create their transition in one world to a different smoother.

Reiki offers healing for many types of bodily
conditions, as well as for the spiritual problems. It is like a
best friend for those those people short of funds, however it can also relieve healthy people from quotidian stress and problems.

You can see more information here on website : https://new-giveaways.win/ - https://new-giveaways.win/

ss用起来体验不错!
还在愁账号的大大,搜索“倚天剑shadow”吧
只能帮你到这里了

What's Going down i am new to this, I stumbled upon this I have discovered It
absolutely useful and it has helped me out loads.
I am hoping to give a contribution & assist other customers
like its aided me. Good job.

Here is my weblog: <a href="https://twitter.com/xxxlovers2015">xxxlovers2015</a>

Hi I am so happy I found your site, I really found you by error, while I was looking on Yahoo for something else,
Anyhow I am here now and would just like
to say kudos for a fantastic post and a all round
enjoyable blog (I also love the theme/design), I don't have time to browse it all at
the minute but I have bookmarked it and also added in your RSS feeds,
so when I have time I will be back to read more, Please do keep up the superb job.

Check out my blog post - isot tissit - https://bigboobsdaily.blogspot.com/search/label/isot%20tissit

I seriously love your site.. Great colors & theme.
Did you create this amazing site yourself?

Please reply back as I'm planning to create my own personal website
and would love to know where you got this from or
just what the theme is called. Kudos!

Look at my homepage :: seo london - http://digitalseoserviceslondon.com

Hi admin. It was hard to find this site in google.
It's not even in top10. You should focus on hq
links from top websites in your niche. I know of a very effective free method
to get high quality links and instant traffic.

The best thing about this method is that you start getting
clicks right away. For more info search in google for:
masitsu's tricks

Feel free to visit my web site ... <a href="https://CleverAline1.blogspot.com">XBeatris</a>

Thank you a bunch for sharing this with all people you actually recognize what
you are speaking about! Bookmarked. Please also seek advice from my web site =).
We can have a hyperlink exchange agreement among us

my site: <a href="https://twitter.com/hashtag/storepupper">store pupper</a>

goagent已经进化成了xx-net了

别折腾了,时间也是有成本的,直接上挖墙脚http://waqiangjiao.org
注册ss账号,免费试用,按需购买流量,不强制包月,流量永不过期。价格便宜,1元1G,5元10G,40元100G。
邀请码:http://waqiangjiao.org/code

Hello. I see that you don't update your website too often. I know that writing articles is boring and time consuming.
But did you know that there is a tool that allows
you to create new posts using existing content (from article directories or
other websites from your niche)? And it does
it very well. The new articles are unique and pass the copyscape test.
You should try miftolo's tools

My web page; <a href="https://FredricBad.blogspot.com">MurrayJuicy</a>

挖墙脚waqiangjiao.org
注册shadowsocks账号,免费试用,按需购买流量,不强制包月,流量永不过期。速度快,价格便宜,1元1G,5元10G,40元100G。玩Pokemon翻墙必备。

Viagra Plus Generic Cialis 10 Mg <a href=http://cheaplevi.com>viagra vs cialis vs levitra samples</a> Discount Free Shipping Clobetasol Cheap Legally Online Cialis Diario Argentina Lasix Without A Script

The 2 Week Diet is an extreme rapid weight loss system that can help you lose up to 16 pounds of pure body fat in just 2 weeks!
Get your personalized diet plan for 2 week weight loss, our 14 day diet, and how to lose weight in 2 weeks from our official website.

Get Plan == >> http://bit.ly/The_2_Week_Diet_Ok

Propecia Testicle Cancer Viagra Venta Cordoba Viagra Cialis Efficacia <a href=http://drugslr.com>cialis from canada</a> Best Price For Diflucan Generic Propecia Scalp Pain Ed Drugs Discount Isotretinoin Acne For Sale Best Website Visa <a href=http://sildenaf75mg.com>viagra</a> Propecia Generic Viagra Online

Sertralina Medicamento Effects Of Keflex Antibiotic <a href=http://buyoxys.com>viagra cialis levitra combo packs</a> Generic Topiramate Online 200 Buy Doxycycline In Bali Comprare Levitra Online Kamagra Jelly 100 Mg <a href=http://avdrug.com>levitra medicament generique</a> Levitra Dosierung Erfahrung Canadian Drugs Cialis Topills Online Pharmacy Cialis In Hong Kong <a href=http://arealot.com>buy zoloft</a> Acheter Du Ciprofloxacin En Suisse Amoxicillin Nausea Cats Venta Viagra En Espana Amoxicillin With Breast Feeding <a href=http://realviaonline.com>cheapest cialis 20mg</a> Doxycycline Online Cheap Compare Canadian Pharcharmy Online Generic Cialis 200mg Forum Cialis France <a href=http://curerxshop.com>cialis vs viagra</a> Acheter Cialis Occasion Tab Online Isotretinoin Delivered On Saturday Florida

Levitra O Viagra Best Price For Propecia Online <a href=http://staminamen.com>п»їcialis</a> Viagra Et Cialis Pas Cher Viagra Prix Ligne Generique Kamagra France Kamagra Oral Comprar Cialis 20 Generico <a href=http://euhomme.com>canadian cialis</a> Diflucan Online Rx Drugs Pills 365 Cialis Natural Generique Propecia Buy Amoxicillin 500mg With Mastercard <a href=http://mdsmeds.com>cialis</a> Uk Generic Propecia 5 Mg Canada Kamagra

冒个泡吧!

Plain text

  • 不允许HTML标记。
  • 自动将网址与电子邮件地址转变为链接。
  • 自动断行和分段。