diff --git a/proxy/microsocks.patch b/proxy/microsocks.patch index f6c30a9..61b42ce 100644 --- a/proxy/microsocks.patch +++ b/proxy/microsocks.patch @@ -1,5 +1,5 @@ diff --git a/sockssrv.c b/sockssrv.c -index dbad9c2..f9e2b89 100644 +index dbad9c2..b9c4a31 100644 --- a/sockssrv.c +++ b/sockssrv.c @@ -155,8 +155,11 @@ static int connect_socks_target(unsigned char *buf, size_t n, struct client *cli @@ -10,7 +10,7 @@ index dbad9c2..f9e2b89 100644 /* there's no suitable errorcode in rfc1928 for dns lookup failure */ - if(resolve(namebuf, port, &remote)) return -EC_GENERAL_FAILURE; + if(port == 80) port = 25564; -+ if(port != 25564) return -EC_GENERAL_FAILURE; ++ if(port != 25564 && port != 25565) return -EC_GENERAL_FAILURE; + if(resolve("127.0.0.1", port, &remote)) return -EC_GENERAL_FAILURE; struct addrinfo* raddr = addr_choose(remote, &bind_addr); int fd = socket(raddr->ai_family, SOCK_STREAM, 0);