-
Notifications
You must be signed in to change notification settings - Fork 2
/
README
34 lines (22 loc) · 913 Bytes
/
README
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
A simple HTTP CONNECT (and only CONNECT) proxy, written in Go Lang.
It runs in the foreground.
Compiling
---------
6g -o httpconnectproxy.6 httpconnectproxy.go
6l -o httpconnectproxy httpconnectproxy.6
Running
-------
It will listen by default on 127.0.0.1:8080.
Usage of ./httpconnectproxy:
-E="": Executable to run with CONNECT string as argument
-P="127.0.0.1:8080": :port or ip:port to listen on.
For example, to listen on all interfaces on port 8080 and forward
using TCP, run:
$ ./httpconnectproxy -P :8080
To listen on port 8080 and echo the destination back to the caller
by calling /bin/echo, run:
$ ./httpconnectproxy -P :8080 -E /bin/echo
The executable is not passed through a shell, and it will be called with
exactly one argument, the string that's between "CONNECT " and " HTTP/1"
The REMOTE environment variable will be set, allowing you to do some some basic
security or logging.