You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+33Lines changed: 33 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -19,10 +19,13 @@
19
19
-[redirect (via NAT and SO_ORIGINAL_DST)](#redirect-via-nat-and-so_original_dst)
20
20
-[tproxy (via MANGLE and IP_TRANSPARENT)](#tproxy-via-mangle-and-ip_transparent)
21
21
-[Links](#links)
22
+
-[Contributing](#contributing)
22
23
-[License](#license)
23
24
24
25
## Introduction
25
26
27
+
[[Back]](#table-of-contents)
28
+
26
29
`GoHPTS` CLI tool is a bridge between HTTP clients and a SOCKS5 proxy server or multiple servers (chain). It listens locally as an HTTP proxy, accepts standard HTTP
27
30
or HTTPS (via CONNECT) requests and forwards the connection through a SOCKS5 proxy. Inspired by [http-proxy-to-socks](https://github.com/oyyd/http-proxy-to-socks) and [Proxychains](https://github.com/rofl0r/proxychains-ng)
28
31
@@ -45,6 +48,8 @@ Specify http server in proxy configuration of Postman
45
48
46
49
## Features
47
50
51
+
[[Back]](#table-of-contents)
52
+
48
53
-**Proxy Chain functionality**
49
54
Supports `strict`, `dynamic`, `random`, `round_robin` chains of SOCKS5 proxy
50
55
@@ -77,6 +82,8 @@ Specify http server in proxy configuration of Postman
77
82
78
83
## Installation
79
84
85
+
[[Back]](#table-of-contents)
86
+
80
87
You can download the binary for your platform from [Releases](https://github.com/shadowy-pycoder/go-http-proxy-to-socks/releases) page.
81
88
82
89
Example:
@@ -104,6 +111,8 @@ make build
104
111
105
112
## Usage
106
113
114
+
[[Back]](#table-of-contents)
115
+
107
116
```shell
108
117
gohpts -h
109
118
_____ _ _ _____ _______ _____
@@ -149,6 +158,8 @@ Options:
149
158
150
159
### Configuration via CLI flags
151
160
161
+
[[Back]](#table-of-contents)
162
+
152
163
```shell
153
164
gohpts -s 1080 -l 8080 -d -j
154
165
```
@@ -205,6 +216,8 @@ kill $(pidof gohpts)
205
216
206
217
### Configuration via YAML file
207
218
219
+
[[Back]](#table-of-contents)
220
+
208
221
Run http proxy in SOCKS5 proxy chain mode (specify server settings via YAML configuration file)
209
222
210
223
```shell
@@ -263,6 +276,8 @@ To learn more about proxy chains visit [Proxychains Github](https://github.com/r
263
276
264
277
## Transparent proxy
265
278
279
+
[[Back]](#table-of-contents)
280
+
266
281
> Also known as an `intercepting proxy`, `inline proxy`, or `forced proxy`, a transparent proxy intercepts normal application layer communication without requiring any special client configuration. Clients need not be aware of the existence of the proxy. A transparent proxy is normally located between the client and the Internet, with the proxy performing some of the functions of a gateway or router
In this mode proxying happens with `iptables``mangle` table and `TPROXY` target. Transparent proxy sees destination address as is, it is not being rewrited by the kernel. For this to work the proxy binds with socket option `IP_TRANSPARENT`, `iptables` intercepts traffic using TPROXY target, routing rules tell marked packets to go to the local proxy without changing their original destination.
350
367
351
368
This mode requires elevated privileges to run `GoHPTS`. You can do that by running the follwing command:
@@ -399,6 +416,8 @@ ip link del veth1
399
416
400
417
## Links
401
418
419
+
[[Back]](#table-of-contents)
420
+
402
421
Learn more about transparent proxies by visiting the following links:
403
422
404
423
-[Transparent proxy support in Linux Kernel](https://docs.kernel.org/networking/tproxy.html)
@@ -407,6 +426,20 @@ Learn more about transparent proxies by visiting the following links:
0 commit comments