Open bbhxwl opened 4 years ago
What is the problem?
What is the problem?
Is this the key code of Socks5? Did I test or couldn't support Socks5?
Yes, that is the code.
After I enable it, I can't connect to Socks5 properly. Is there a bug?
There is a problem. UDP function cannot be proxy
Yes, this is TCP only
Will UDP compatible forwarding be considered in the future?
Could you please translate your screnshot? I can't speak chinese, and can1t copy the characters from an image:)
How do you use UDP Socks from a browser? Or what is the source of your HTTP requests?
The text of the picture is probably that the test TCP passed and UDP failed. If you want to be a proxy server, you can not only speed up HTTP and UDP, but also speed up the game. If it is compatible, it will be a more powerful project.
But TWP is a HTTP proxy... it accepts only HTTP requests in SOCKS protocol.... there are many simple socks proxy on the internet.
Well, I want to integrate.
Can't you make something like a plug-in? Support for UDP will not affect the TCP function of Socks5.
But TWP is a HTTP proxy... it accepts only HTTP requests in SOCKS protocol.... there are many simple socks proxy on the internet.
Does the official version support Socks5 authentication? Hope to consider adding a UDP forwarding.
Yes, it supports authentication, you have to set the ProxyBasicAuthenticateFunc property to authorize the connection.
However i did not found any browser which supprots SOCKS5 authentication. It is possible only with a Firefox addon, FoxyProxy. I tried that, and it was working with TWP.
I want to know HTTP authentication and sock5 authentication. In addition to limiting the account and password, I can get the IP of the client. I want to do the IP restriction
If I don't want to intercept HTTPS and forward data directly, can I not write the onbeforetunnelconnectrequest event? Is the default e.decryptssl = false?
The default is "true".
If you don't want to decrypt any traffic, i suggest you to disable decryption globally in the endpoint constructor.
Currently the client infomration is not available for SOCKS authentication (the SessionEventArgsBase parameter is null)
explicitEndPoint.DecryptSsl is read-only If I don't want to intercept any data and just want to be an HTTP proxy, I can add no events, right? Just add an explicitproxyendpoint.
Set the constructor parameter of the endpoint object.
Sock5 authentication cannot be restricted in proxybasicauthenticatefunc, right?
proxyServer.ProxyBasicAuthenticateFunc = async (args, userName, password) => {
return true;
};
var socksEndPoint = new SocksProxyEndPoint(IPAddress.Any, 1080,false) { // Generic Certificate hostname to use // When SNI is disabled by client GenericCertificateName = "google.com" };
proxyServer.AddEndPoint(socksEndPoint);
It can be restricted as you wrote.
So you can limit sock5? Recommend the author's S5 client program sstap and C ා open source program netch. Is the author not going to support UDP forwarding?
Is there a way that the user can not enter the password? I will judge the authorization according to the IP. If the user enters the account and password, I will judge with the account and password. It seems that after writing proxybasicauthenticatefunc, you must enter the account and password, right?
Yes, if you set the proxybasicauthenticatefunc the user must enter the username and password.
I have written these codes that can be used normally. There are some parameters that I don't understand.
For example, I don't know proxyserver.enablewinauth
What is the function of this parameter? Is args.clientremoteendpoint.address.maptoipv4() in proxyserver.proxybasicauthenticatefunc the IP address of the connector? Is proxyendpoint the IP address of the connected (server)? Should clientlocalendpoint be the server's native IP?
Is proxyserver.forwardtoupstreamgateway important? What will happen if I cancel? Does enabling http2 have any effect on the load?
proxyServer = new ProxyServer(); proxyServer.EnableHttp2 = true; proxyServer.ExceptionFunc = exception => {
};
proxyServer.ForwardToUpstreamGateway = true;
proxyServer.BeforeRequest += onRequest; proxyServer.BeforeResponse += onResponse; proxyServer.EnableWinAuth = true; proxyServer.ProxyBasicAuthenticateFunc = async (args, userName, password) => { return true; }; explicitEndPoint = new ExplicitProxyEndPoint(IPAddress.Any, TcpPort, false); proxyServer.AddEndPoint(explicitEndPoint); proxyServer.Start();
I ran titanium.web.proxy.examples.basic, released the comments of the following code, tested the native 127.0.0.1 and port 1080, unable to run normally?
var socksEndPoint = new SocksProxyEndPoint(IPAddress.Any, 1080, true) { // Generic Certificate hostname to use // When SNI is disabled by client GenericCertificateName = "google.com" };