A few days ago, a small tool was released to prevent GFWDNS pollution. Unexpectedly, enthusiastic netizens quickly followed up and developed better tools based on similar principles. Click here for details. So I wrote such a small thing with painstaking efforts, hoping to play a role in attracting others. Source Code address: github. comexamplecodemproxy about mproxy
A few days ago, a small tool was released to prevent GFWDNS pollution. Unexpectedly, enthusiastic netizens quickly followed up and developed better tools based on similar principles. Click here for details. So I wrote such a small thing with painstaking efforts, hoping to play a role in attracting others. Source Code address: https://github.com/examplecode/mproxy about mproxy
A few days ago, a small tool was released to prevent GFWDNS pollution. Unexpectedly, enthusiastic netizens quickly followed up and developed better tools based on similar principles. Click here for details. So I wrote such a small thing with painstaking efforts, hoping to play a role in attracting others.
Source Code address: https://github.com/examplecode/mproxy
What is mproxymproxy?
This is a very small http proxy implemented in C language that does not rely on any third-party library CORE code less than 500 lines.
What is the role of mproxy?
I personally think it has two functions:
- Mproxy has a small amount of code and is easy to implement. It can be used to understand the basic working principle of http proxy.
- If you have a need to flip the wall, it can help solve this problem. At least you can access websites such as google, youtube, facebook, and twitter.
The principle of turning over the wall can be understood in one sentence.
Browser --> mproxy (local proxy) --> mproxy (remte proxy)-> worlds
Does mproxy need independent server resources?
Yes, you need to deploy an independent server outside of the local proxy as a transit to achieve the purpose of turning the wall. Unlike some wall flip software, mproxy uses GAE as a service (the GAE service does not allow socket creation). The following are the resources you need.
- A foreign server or VPS (vps in foreign countries are relatively cheap now, my test environment is to use digitalocean vps for only $5 a month, the website operation experience is better than lindoe, performance stability seems to be almost the same, but the price is different after all ).
- A unix like local server serves as your http proxy.
How to install and deploy mproxy?
For mproxy installation and deployment, refer to the following website:
Https://github.com/examplecode/mproxy
What is the difference between mproxy and other wall flip software?
In fact, there is no major difference in the basic principle, but mproxy is easier to implement, without using third-party libraries such as openssl, asynchronous socket, and http lib. Only the minimum code is used to demonstrate the basic principle of the wall.
How is mproxy used?
Mproxy has just been developed, and its implementation has not undergone a lot of tests. There is still a gap with mature and stable wall flip software. Its main purpose is to learn and study the principle of wall flip. At present, this product level has not been reached, if you like tossing, try again as a toy. Otherwise, stop it, lest you complain that I am releasing a spam. It has been tested to access websites such as google, twitter, facebook, and youtube.
How can I view the program output when mproxy is running on the background?
Use the redirection command directly.
./mproxy -l 8081 -D -d > out_8081.log 2>&1
About test Server
The following is the server I used to test (which cannot be closed someday). If you have a unix like system, you can first install a local mproxy, connect to the test server provided by me to check the wall flip effect. The vps virtual instance from digitalocean has a low performance and only MB of memory. Therefore, the response may be slow when many users are tested.
- Ip Address: 162.243.247.187
- Port: 8080,8081 (currently, two mproxy instances are running on my server, which can be connected)
Start mproxy on your local server and run the following command:
./mproxy -h 162.243.247.187:8080 -E -d
About vps
If you want to purchase digitalocean vps, click the following link, you know :).
Https://www.digitalocean.com /? Refcode = 0340b5e32fde
Original article address: The smallest http proxy C language implementation-supports wall-over, thanks to the original author for sharing.