Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/rofl0r/proxychains-ng.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAlexandre Viau <alexandre@alexandreviau.net>2020-12-12 11:25:36 +0300
committerGitHub <noreply@github.com>2020-12-12 11:25:36 +0300
commit159ab946351a5370a81b19ab718e64f98e05404a (patch)
tree361cd2e0c58572f924b1530881a7113a574e136b
parent583343a2ef46f5d3fd7be10dc59ae55689cc732d (diff)
support 'raw' proxy type (#348)
-rw-r--r--src/core.c4
-rw-r--r--src/core.h3
-rw-r--r--src/libproxychains.c2
-rw-r--r--src/proxychains.conf3
4 files changed, 10 insertions, 2 deletions
diff --git a/src/core.c b/src/core.c
index fb26292..ade82f1 100644
--- a/src/core.c
+++ b/src/core.c
@@ -222,6 +222,10 @@ static int tunnel_to(int sock, ip_type ip, unsigned short port, proxy_type pt, c
int v6 = ip.is_v6;
switch (pt) {
+ case RAW_TYPE: {
+ return SUCCESS;
+ }
+ break;
case HTTP_TYPE:{
if(!dns_len) {
if(!inet_ntop(v6?AF_INET6:AF_INET,ip.addr.v6,ip_buf,sizeof ip_buf)) {
diff --git a/src/core.h b/src/core.h
index fd9b6c8..5f446e9 100644
--- a/src/core.h
+++ b/src/core.h
@@ -41,7 +41,8 @@ typedef enum {
typedef enum {
HTTP_TYPE,
SOCKS4_TYPE,
- SOCKS5_TYPE
+ SOCKS5_TYPE,
+ RAW_TYPE
} proxy_type;
typedef enum {
diff --git a/src/libproxychains.c b/src/libproxychains.c
index fc6880f..4edcd86 100644
--- a/src/libproxychains.c
+++ b/src/libproxychains.c
@@ -354,6 +354,8 @@ inv_host:
if(!strcmp(type, "http")) {
pd[count].pt = HTTP_TYPE;
+ } else if(!strcmp(type, "raw")) {
+ pd[count].pt = RAW_TYPE;
} else if(!strcmp(type, "socks4")) {
pd[count].pt = SOCKS4_TYPE;
} else if(!strcmp(type, "socks5")) {
diff --git a/src/proxychains.conf b/src/proxychains.conf
index ecb9164..52c0986 100644
--- a/src/proxychains.conf
+++ b/src/proxychains.conf
@@ -145,7 +145,8 @@ tcp_connect_time_out 8000
# http 192.168.39.93 8080
#
#
-# proxy types: http, socks4, socks5
+# proxy types: http, socks4, socks5, raw
+# * raw: The traffic is simply forwarded to the proxy without modification.
# ( auth types supported: "basic"-http "user/pass"-socks )
#
[ProxyList]