This project can take you through a Firewall via Socks5 proxy.
with the great erlang, the project has the following features:
-
Robustness. never down.
-
Scalable. handle thousands requests at the same time easily.
-
Fast.
-
Lightweight. only takes less than 20MB memories.
In my daily use,
-
When server is idle, It only takes about 10MB memories.
-
Play a youtube 1080P video, It only takes 12MB memories.
Below is the system status when play a youtube 1080P video. Notice the
beam.smp
process.Linode 8 cpus, 1G RAM VPS.
+-----------+ +--------------+ encrypt
| local app | <=======> | proxy client | <#######
+-----------+ decrypt +--------------+ #
#
#
# encrypted data
#
#
+-------------+ +--------------+ #
| target host | <=======> | proxy server | <#####
+-------------+ decrypt +--------------+ encrypt
-
proxy client
is running at your local computer.It receive your app (like a browser) request, encrypt the data, send to
proxy server
-
proxy server
receive the request fromproxy client
, decrypt it, and sent to the target host. -
proxy server
got the response from target host, and encrypt response, send back toproxy client
. -
proxy client
decrypt response received fromproxy server
, and send to local app. -
the circle done.
mp_sup
is the application's top supervisor,
mp_accept
block on gen_tcp:accept
, when new connection comes,
mp_child_sup
will start a new child, this child communicate with
the connected client, and die after connection closed, or error ocurred.
-
git clone https://github.com/yueyoum/make-proxy.git
or directly download. -
cd make-proxy
-
cp server.config.example server.config
, and change the port what you want.server will listen on this port.
-
make server
-
./start_server.sh
-
Done.
-
same as the Server side, checkout the code.
-
cd make-proxy
-
cp client.config.example client.config
- remote_addr: IP of the compute where
make-proxy
server runs - remote_port: PORT that make-proxy server using. SAME as the defination of
server.config
. - local_addr: "127.0.0.1" or "0.0.0.0" or some specified address.
- port: which port the make-proxy client will listen on.
- remote_addr: IP of the compute where
-
make client
-
./start_client.sh
-
Done
Now, you can set your apps (e.g. Browser) Using socks5 proxy.
IP = 127.0.0.1
PORT = 7070
(if not changed in the client.config)
- Support HTTP Proxy