├── README.md └── testproxy.js /README.md: -------------------------------------------------------------------------------- 1 | ### Usage 2 | ``` 3 | run 'node testproxy.js proxy' on your VPS. 4 | ``` 5 | ``` 6 | run 'node testproxy.js VPS_IP' on your local PC. 7 | ``` 8 | ``` 9 | set Proxy IP/port in web browser to 127.0.0.1/8893 on your local PC. 10 | ``` 11 | ``` 12 | run 'node testproxy.js standalone' on your server if you only need a normal proxy instead of a double-steps-proxy. 13 | ``` 14 | 15 | ### Basic idea and code 16 | Basic idea and code comes from this article. Thanks to the poster and the original author. 17 | http://cnodejs.org/topic/4f16442ccae1f4aa27001101 18 | 19 | ### License 20 | 21 | >The MIT License (MIT) 22 | > 23 | >Copyright (c) 2014 simpleproxy. 24 | > 25 | >Permission is hereby granted, free of charge, to any person obtaining a copy 26 | >of this software and associated documentation files (the "Software"), to deal 27 | >in the Software without restriction, including without limitation the rights 28 | >to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 29 | >copies of the Software, and to permit persons to whom the Software is 30 | >furnished to do so, subject to the following conditions: 31 | > 32 | >The above copyright notice and this permission notice shall be included in 33 | >all copies or substantial portions of the Software. 34 | > 35 | >THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 36 | >IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 37 | >FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 38 | >AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 39 | >LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 40 | >OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 41 | >THE SOFTWARE. 42 | -------------------------------------------------------------------------------- /testproxy.js: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xuduo35/simpleproxy/6c9aef3fb9a4be61cdca562ed8132ded91c48083/testproxy.js --------------------------------------------------------------------------------