this a simple and stupid http proxy.
this a simple and stupid http proxy server. it supports HTTP tunnel, and HTTP keep-alive
this a simple and stupid http proxy server. it supports HTTP tunnel, and HTTP keep-alive
go get github.com/wynemo/kiss-proxy/httpproxy
$GOPATH/bin/httpproxy &
默认监听的端口为8118.
from https://github.com/wynemo/kiss-proxy ----补充说明:该程序在服务器上,默认监听端口8118,且监听的地址是0.0.0.0,监听0.0.0.0这很不安全。所以我们要先在本地机器上,访问https://github.com/wynemo/kiss-proxy ,把它fork为自己的项目,我就把它fork为了https://github.com/luckypoem/kiss-proxy,然后修改httpproxy目录里的httpproxy.go文件,修改httpproxy.go文件里的第18行,把8118端口改为其他端口,比如7118。把0.0.0.0改为127.0.0.1 。如这里https://github.com/luckypoem/kiss-proxy/blob/master/httpproxy/httpproxy.go所示。修改httpproxy.go文件里的第13行,修改wynemo为你的用户名。删除go.mod
在Linux vps上,安装go环境。然后,cd $GOPATHgo get -u -v github.com/luckypoem/kiss-proxy/httpproxy/得到的可执行文件为$GOPATH/bin/里面的httpproxy。
cd ~
httpproxy
显示:
listen on 127.0.0.1:7118
httpproxy是运行在前台的,我们可以利用jinbe,让httpproxy命令随vps的重启而自动运行并运行在后台:
jinbe httpproxy && reboot
项目地址:https://github.com/luckypoem/kiss-proxy
No comments:
Post a Comment