Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- public class ProxyShit
- {
- public List<ProxyList> ProxyList = new List<ProxyList>();
- private async void loadProxys()
- {
- await Task.Run(() =>
- {
- using (WebClient wc = new WebClient())
- {
- try
- {
- string resp = wc.DownloadString("https://hidester.com/proxydata/php/data.php?mykey=csv&country=&port=&type=1&anonymity=7&ping=1&gproxy=2");
- dynamic Json = JsonConvert.DeserializeObject(resp);
- int ProxyAmount = Json.Count;
- Parallel.For(0, ProxyAmount, new ParallelOptions() { MaxDegreeOfParallelism = 1000000 }, ProxyInfo =>
- { ProxyList.Add(new proxies { IP = Json[ProxyInfo].IP, Port = Json[ProxyInfo].PORT }); });
- }
- catch (Exception ex)
- {
- }
- }
- });
- }
- }
- public class ProxyList
- {
- public string IP { get; set; }
- public int Port { get; set; }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement