-
Notifications
You must be signed in to change notification settings - Fork 52
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Infinite stuck #83
Comments
Hi, yes that is known issue in .net framework where it just doesn't timeout for some reason and idk if there is any solution to this but best alternative to this would be using httpclient and use wait method with timeout parameter. |
Without a proxy, is the problem still showing up? |
Is there a problem with .NET Core? |
Yes it is with .net core too, no only with this specific proxy(or any proxy which is also a url) |
@Fonix420 thank you for reporting. I'll try to fix that on the week. |
Fixed by adding var req = new HttpRequest();
req.UserAgent =
"Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/80.0.3987.163 Safari/537.36";
var resp = req.Get("http://77.74.231.21:8028/");
string respStr = resp.ToString(); More URLs needed for tests. |
Look at the image on the main post. The issue is send a request to that specific site while using the url as a proxy. |
|
Should be fixed in v5.2.9. |
On .Get(), only with this specific proxy on this specific site. All proxies which are also urls gets this issue on this url |
If i am not wrong i have faced this issue with webrequests in past as well. I have faced situation with (xNet) where it didn't timeout for hour as well. According to Docs this might be an issue.
https://docs.microsoft.com/en-us/dotnet/api/system.net.httpwebrequest.timeout?view=netframework-4.5 |
@Fonix420 Just tried to use private static void HttpClientTest()
{
var httpHandler = new HttpClientHandler {
Proxy = new WebProxy("77.74.231.21:8028")
};
var httpClient = new HttpClient(httpHandler);
httpClient.DefaultRequestHeaders.ExpectContinue = false;
httpClient.DefaultRequestHeaders.UserAgent.TryParseAdd(
"Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/80.0.3987.163 Safari/537.36"
);
var res = httpClient.GetStringAsync("http://proxydb.net/anon");
var str = res.Result;
}
|
Should be fixed in v5.2.10 without side-effects. |
Same issue, try the exact code i sent before and you will see |
Without proxy? |
With proxy, i need it to timeout in the case that i get another proxy like this when testing. I made a parser which checks proxies from a source and that is why i need it to timeout on these proxies instead of hanging. |
Try using this proxy in any browser and you will realize that it doesn't work. To check the proxy, you must check the response from the proxy server and it must match the requested resource. What Timeout are you talking about if your proxy server is not a proxy server, but is streaming an infinite media stream. |
Yes i know but my tool looks for random proxies on sources and then tests them. So once it finds a proxy like this and tries to test it, it gets stuck. I need it to throw an exception or timeout. |
@Fonix420 Now I get it, thanks for the explanation. Will be fixed soon. |
Thanks, sorry for not explaining it better from the beginning. |
I am also facing the same issue. Getting stuck forever on the Http GET method. POST works fine for me. |
you guys didnt set the proxy type when setting the proxy... |
Not working... |
you probally did it wrong then, cant help |
I switched to xNet and now is working lmao |
I have an issue where it just wont return the response data, like it connects and does all the right things, but when I try to turn it into a string it sits for about 30 sec and returns this error:
|
If you try to make any kind of request with a proxy which is also a url it will get stuck without crashing or ever moving forward
ex. 77.74.231.21:8028 which is also a site
example as it only happens on some sites:
The text was updated successfully, but these errors were encountered: