Closed ingnelson closed 4 years ago
Why not use https proxy? The plain http proxy is designed to use in Intranet, not Internet. Read the usage of sproxy, then set --cafile
, --cert
, --key
, and change the port to 443 finally.
@choury i am a newbie.
the command should be like this ?
docker run -itd --name sproxy --cafile --cert --key --ip 0.0.0.0 -p 443:80 choury/sproxy
or like this :
docker run -itd --name sproxy --cafile --cert --key --ip 0.0.0.0 -p 443:443 choury/sproxy
That command create automatic the cafile , cert and key ? or before run that commnad i have to create those files and add threir path on that command ?
/root/certs
docker run -itd -v /root/certs:/some/path -p 443:443 choury/sproxy sproxy --cafile /some/path/cert.pem --cert /some/path/cert.pem --key /some/path/key.pem
@choury I try HTTPS with port 443 but it doesn't works because the HTTP request that Sproxy begin with the CONNECT method.
Sproxy with HTTPS on port 443 Only works when I am using WIFI ,but if I use my mobile networks sproxy can not pass the firewall.
Could you create a HTTP or HTTPS tunnel using GET method ?
Please provide connect config of android app, and logs of both app and server.
@choury with my mobile networks the Connection is blocked by the ISP provider . Because like I told you my ISP provider blocks all Http request that use CONNECT method . Like you know sproxy app send CONNECT method.
But if I use WIFI the sproxy works well .
Can you create a HTTP tunnel that works only with GET method ??
@choury with my mobile networks the Connection is blocked by the ISP provider . Because like I told you my ISP provider blocks all Http request that use CONNECT method . Like you know sproxy app send CONNECT method.
The date sent by https are encrypted by ssl, your ISP provides CAN NOT even know which method it used, how does it block it?
But if I use WIFI the sproxy works well .
If it works only with WIF, there may be two reasons:
telnet
or nc
or something.Can you create a HTTP tunnel that works only with GET method ??
I will not create a non-standard protocol for this case. If you do want it, please PAY ME to implement this feature.
@choury I would like to pay you if implement a feature that it can bypass my ISP provider.
I will explain to you how I know my ISP block the sproxy connection :
First sproxy app send always http or https request using CONNECT method like this :
HTTP request using SPROXY :
CONNECT sdkconfig.ad.intl.xiaomi.com:443 HTTP/1.1\r\n
Host: sdkconfig.ad.intl.xiaomi.com:443\r\n
Sproxy-Vpn: 48089\r\n
Strategy: proxy\r\n
User-Agent: Sproxy/0.202 (Android 9; Redmi Note 7 Build/1571686662)\r\n\r\n
HTTPS or TLS V1.3 using SPROXY APP my provides blocks it .
Answering your question how I know my providers blocks this connection types ? It is because I have months testing with netcat command or curl and more options , also using other app or programs like Trojan (TLS tunnel ) .
I used this command to test the connections or restrictions :
(echo -en 'GET #abc# HTTP/1.1\r\n ٌُُُُُُّّّّْْْْْْْْْْْْْْْْْْ\r\n\r\n' ; cat ) | nc 172.245.22.211 80
echo -n $'GET #123# HTTP/1.1\r\n\x20\xd9\x8c\xd9\x8f\xd9\x92\xd9\x92\xd9\x92\xd9\x92\xd9\x92\xd9\x92\xd9\x92\xd9\x92\xd9\x92\xd9\x92\xd9\x92\xd9\x92\xd9\x92\xd9\x91\xd9\x91\xd9\x91\xd9\x91\xd9\x92\xd9\x92\xd9\x92\xd9\x92\xd9\x8f\xd9\x8f\xd9\x8f\xd9\x92\xd9\x8f\xd9\x8f\r\n\r\n' | nc --no-shutdown 172.245.22.211 80 > rndtest
So I know for sure my ISP provider blocks CONNECT method and TLS tunnel too.
My ISP provider only allow GET , HEAD , DELETE , POST
Some guy create a tunnel using only GET for Downstream and GET Upstream + shadowsocks to obfuscate the data or create the tunnel . He only let me test it one time , but I captured the packet using TCPDUMP.
My ISP provider restrictions are :
At the and of the first line should end with \r\n ٌُُُُُُّّّّْْْْْْْْْْْْْْْْْْ\r\n\r\n
As you can see this http request do not finish with \r\n\r\n , it finish with \r\n ٌُُُُُُّّّّْْْْْْْْْْْْْْْْْْ\r\n\r\n this has NON-ASCII characters after the first \r\n + space , this NON-ASCII character is the trick to bypass the firewall
The HTTP should be like this:
GET #0=fown&method=1&down=15000# HTTP/1.1\r\n ٌُُُُُُّّّّْْْْْْْْْْْْْْْْْْ\r\n\r\n
or
GET #123# HTTP/1.1\r\n\x20\xd9\x8c\xd9\x8f\xd9\x92\xd9\x92\xd9\x92\xd9\x92\xd9\x92\xd9\x92\xd9\x92\xd9\x92\xd9\x92\xd9\x92\xd9\x92\xd9\x92\xd9\x92\xd9\x91\xd9\x91\xd9\x91\xd9\x91\xd9\x92\xd9\x92\xd9\x92\xd9\x92\xd9\x8f\xd9\x8f\xd9\x8f\xd9\x92\xd9\x8f\xd9\x8f\r\n\r\n
The connection is like this :
HTTP request on port 80 using the NON-ASCII characters > Shadowsocks on port 443 > internet > HTTP server listen on port 80 > shadowsocks server listen on port 443
On wireshark program the connection looks like this :
You can see the packet via WIRESHARK: quantumnica1.zip
Those screenshots are from a android app that create the tunnel like i told you, i just figurate how it works and i want to create the same connection.
Can you create connection like that using GET method ? or Can you modify this next HTTPIERCE shadowsocks plugin to use only GET method for Downstream and GET method for Upstream ? https://github.com/Snawoot/httpierce/
Like I told you I would to pay you for the project. Do you have Telegram to chat more faster ? My telegram : https://t.me/Trader_Nelson
Use telegram to contact you.
Hello my friend.
I am behind a ISP firewall . i use sproxy on port
53
, becuase it is the only port that my ISP allow use CONNECT method , i used this command:docker run -itd --name sproxy --ip 0.0.0.0 -p 53:80 choury/sproxy
The sproxy server (VPS ) recive only the first line of the HTTP request here is the log :
Android log :
But on my android do not open any websites using my mobile network , but if i use my WIFI works fine.
Do you have a idea how to bypass this restricction ? maybe using a server SSH on my VPS (
CONNECT 172.245.22.211:443 HTTP/1.1
) or something else insteadCONNECT youtubei.googleapis.com:443 HTTP/1.1
? to create a better tunnel ?Or modifying something on the app ? you are the master . Please help me with this, because it is the first time after much time i see a request goes to the server using a proxy on my mobile network.
I will wait your answer.