Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- private void Hashtags(object eml1)
- {
- Hasht:
- Email eml = (Email)eml1;
- _totalAccs++;
- string prox = "";
- try
- {
- prox = _proxies[new Random().Next(0, _proxies.Count)];
- _proxies.Remove(prox);
- }
- catch
- {
- foreach (var proxy in _proxyBox.Lines)
- {
- _proxies.Add(proxy);
- }
- goto Hasht;
- }
- TwAnswer rd;
- TwAnswer mfsCheck = null;
- Match authenticity_token;
- Login:
- try
- {
- // if (_start)
- // Thread.CurrentThread.Abort();
- //Email eml = (Email)eml1;
- TwiCon _bc = new TwiCon(null);
- //Log(eml.login + " парсим информацию для логина");
- rd = _bc.Proceed("GET", "https://mobile.twitter.com/session/new", null, prox, null, 15);
- mfsCheck = _bc.Proceed("GET", "http://geshout.com/unfollowtool.php", null, prox, null, 15);
- Match m = Regex.Match(mfsCheck.ResponseBody, "<a href=\"https://twitter\\.com/oauth/authorize\\?oauth_token=(.*?)\">");
- string auth_key = m.Groups[1].Value;
- mfsCheck = _bc.Proceed("GET", "https://twitter.com/oauth/authorize?oauth_token=" + auth_key, null, prox, null, 15);
- authenticity_token = Regex.Match(mfsCheck.ResponseBody, @"name=""authenticity_token"" type=""hidden"" value=""(.*?)""");
- //mfsCheck = _bc.Proceed("POST", "https://twitter.com/oauth/authorize", "authenticity_token=" + authenticity_token.Groups[1].Value + "&oauth_token=" + auth_key + "&session%5Busername_or_email%5D=" + eml.login + "&session%5Bpassword%5D=" + eml.password, prox, null, 15);
- //TwAnswer rd = _bc.Proceed("GET", "https://twitter.com", null, prox, null, 15);
- //authenticity_token = Regex.Match(rd.ResponseBody, @"name=""authenticity_token"" type=""hidden"" value=""(.*?)""");
- //Log(eml.login + " авторизуемся");
- //Log(eml.login + " авторизуемся");
- // rd = _bc.Proceed("POST", "https://mobile.twitter.com/session", "authenticity_token=" + authenticity_token.Groups[1].Value + "&username=" + eml.login + "&password=" + eml.password + "&commit=Einloggen", prox, null, 15);
- rd = _bc.Proceed("POST", "https://twitter.com/oauth/authorize", "authenticity_token=" + authenticity_token.Groups[1].Value + "&oauth_token=" + auth_key + "&session%5Busername_or_email%5D=" + eml.login + "&session%5Bpassword%5D=" + eml.password, prox, null, 15);
- //Log(eml.login + " авторизовались");
- rd = _bc.Proceed("GET", "https://twitter.com/AsyncCallback", null, prox, null, 15);
- //rd = rd;
- //RestClient rc = new RestClient();
- //rc.AddDefaultHeader("Accept", "text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8");
- //rc.AddDefaultHeader("Accept-Charset", "ISO-8859-1,utf-8;q=0.7,*;q=0.3");
- //rc.AddDefaultHeader("User-Agent", "Mozilla/5.0 (Windows NT 6.1; WOW64; rv:19.0) Gecko/20100101 Firefox/19.0");
- //rc.AddDefaultHeader("Referrer", "https://twitter.com/oauth/authorize?oauth_token=" + auth_key);
- //rc.CookieContainer = _bc._cookies;
- //IRestRequest req = new RestRequest("https://twitter.com", Method.GET);
- //IRestResponse resp = rc.Execute(req);
- //resp = resp;
- //rd = _bc.Proceed("POST", "https://twitter.com/sessions", "session%5Busername_or_email%5D=" + eml.login + "&session%5Bpassword%5D=" + eml.password + "&return_to_ssl=true&scribe_log=&redirect_after_login=%2F%3Flang%3Dru&authenticity_token=" + authenticity_token.Groups[1].Value, prox, null, 15);
- bool capt = false;
- //if (rd.ResponseBody.Contains("captcha"))
- //{
- // capt = true;
- // //rd = _bc.Proceed("GET", "https://twitter.com/login/captcha?username_or_email" + eml.login, null, prox, null, 15);
- // Match image_link = Regex.Match(rd.ResponseBody, @"src=""https://www.google.com/recaptcha/api/challenge?k=(.*?)&lang=de""></script>");
- // rd = _bc.Proceed("GET", "https://www.google.com/recaptcha/api/challenge?k=" + image_link.Groups[1].Value + "&lang=en", null, null, null, 15);
- // image_link = Regex.Match(rd.ResponseBody, @"challenge : ''(.*?)''");
- // ConnectionManager cm = new ConnectionManager();
- // HttpWebResponse cap = cm.Proceed("GET", "https://www.google.com/recaptcha/api/image?c=" + image_link.Groups[1].Value, null, null, null, 100500);
- // PostData pd = new PostData();
- // pd.AntigateEvent += LogAGEvent;
- // pd.Captcha("3387b524515ce7dcac7cb424bbfb9057", cap, false, null, 0, "captcha.png");
- // string cap_good = pd._captcha;
- // rd = _bc.Proceed("POST", "https://twitter.com/sessions", "session%5Busername_or_email%5D=" + eml.login + "&session%5Bpassword%5D=" + eml.password + "&return_to_ssl=true&scribe_log=&redirect_after_login=%2F%3Flang%3Dru&recaptcha_challenge_field=" + image_link.Groups[1].Value + "&recaptcha_response_field=" + cap_good + "&authenticity_token=" + authenticity_token.Groups[1].Value, prox, null, 15);
- //}
- // TwAnswer rd = _bc.Proceed("POST", "https://mobile.twitter.com/session", "authenticity_token=" + authenticity_token.Groups[1].Value + "&username=" + eml.login + "&password=" + eml.password + "&commit=Einloggen", prox, null, 15);
- //if (!capt)
- //{
- // rd = _bc.Proceed("GET", "https://twitter.com/" + eml.login, null, prox, null, 15);
- //}
- //authenticity_token = Regex.Match(rd.ResponseBody, @"value=""(.*?)"" name=""authenticity_token""");
- //Log(eml.login + " авторизовались");
- //_loggedCount++;
- //Invoke((MethodInvoker)delegate
- //{
- // _loggedLabel.Text = "Залогинено: " + _loggedCount.ToString() + "/" + _totalAccs.ToString();
- //});
- //Log(eml.login + " ретвитим");
- //if (_start)
- // Thread.CurrentThread.Abort();
- // rd = _bc.Proceed("GET", _rtBox.Text, null, prox, null, 15);
- //Match tw_id = Regex.Match(_rtBox.Text, @"/([\d]+)$");
- string twid = eml.twStatus.ToString();
- rd = _bc.Proceed("GET", "https://twitter.com/menko_kirill/status/" + twid, null, prox, null, 15);
- authenticity_token = Regex.Match(rd.ResponseBody, @"type=""hidden"" value=""(.*?)"" name=""authenticity_token""");
- rd = _bc.Proceed("POST", "https://twitter.com/i/tweet/retweet", "authenticity_token=" + authenticity_token.Groups[1].Value + "&id=" + twid, prox, null, 15);
- //_retweets++;
- //Invoke((MethodInvoker)delegate
- //{
- // _rtLabel.Text = "Retweets: " + _retweets.ToString();
- //});
- Log("Success : " + eml.login + " ретвитнули");
- //_retweets++;
- //Invoke((MethodInvoker)delegate
- //{
- // _rtLabel.Text = "Ретвитов: " + _retweets.ToString();
- //});
- //return;
- //for (; ; )
- //{
- // if (_start)
- // {
- // break;
- // }
- // else
- // {
- // Log(eml.login + " залогинены, ждем 5 секунд, пока программу не запустят");
- // Thread.Sleep(5000);
- // }
- //}
- //for (; ; )
- //{
- // Random rand = new Random();
- // string randomTweet = _tweets[rand.Next(0, _tweets.Count)];
- // _tweets.Remove(randomTweet);
- // //TwAnswer rd = _bc.Proceed("GET", "https://mobile.twitter.com/compose/tweet", null, prox, null, 15);
- // TwAnswer rd = _bc.Proceed("GET", "https://twitter.com/AsyncCallback", null, prox, "https://twitter.com/?lang=ru", 15);
- // authenticity_token = Regex.Match(rd.ResponseBody, @"value=""(.*?)"" name=""authenticity_token""");
- // //authenticity_token = Regex.Match(rd.ResponseBody, @"name=""authenticity_token"" type=""hidden"" value=""(.*?)""");
- // Log(eml.login + " пишем твит");
- // rd = _bc.Proceed("POST", "https://twitter.com/i/tweet/create",
- // "authenticity_token=" + authenticity_token.Groups[1].Value + "&place_id=" +
- // eml.geotag + "&status=" +
- // System.Web.HttpUtility.UrlEncode(_hashBox.Text + " " + randomTweet),
- // prox, null, 15);
- // Log(eml.login + " твит отправлен");
- // // rd = _bc.Proceed("POST", "https://mobile.twitter.com", "authenticity_token=" + authenticity_token.Groups[1].Value + "&tweet%5Btext%5D=" + System.Web.HttpUtility.UrlEncode(_hashBox.Text + " " + randomTweet) + "&commit=Tweet", prox, null, 15);
- // //try
- // //{
- // // rd = _bc.Proceed("POST", "https://twitter.com/i/tweet/create", "authenticity_token=" + authenticity_token.Groups[1].Value + "&lang=ru&place_id=&status=" + System.Web.HttpUtility.UrlEncode(randomTweet + " #БольшойТелевизор"), null, null, 15);
- // //}
- // //catch
- // //{
- // // goto Login;
- // //}
- // //rd = _bc.Proceed("GET", "https
- // _hashtags++;
- // Invoke((MethodInvoker)delegate
- // {
- // _htLabel.Text = "Хештегов: " + _hashtags.ToString();
- // });
- // Log(eml.login + " твит отправлен");
- // //Log(eml.login + " ретвитим");
- // //rd = _bc.Proceed("GET", "https://mobile.twitter.com/statuses/315510669753581569/retweet", null, null, null, 15);
- // //authenticity_token = Regex.Match(rd.ResponseBody, @"name=""authenticity_token"" type=""hidden"" value=""(.*?)""");
- // //rd = _bc.Proceed("POST", "https://mobile.twitter.com/statuses/315510669753581569/retweet", "authenticity_token=" + authenticity_token.Groups[1].Value + "&tweet_id=315510669753581569&_method=POST&return_url=%2FAsyncCallback%23tweet_315510669753581569&commit=Retweeten", null, null, 15);
- // //Log(eml.login + " ретвитнули");
- // Log(eml.login + " спим 40 секунд");
- // // return;
- // System.Threading.Thread.Sleep(40000);
- //}
- }
- catch
- {
- try
- {
- prox = _proxies[new Random().Next(0, _proxies.Count)];
- _proxies.Remove(prox);
- }
- catch
- {
- foreach (var proxy in _proxyBox.Lines)
- {
- _proxies.Add(proxy);
- }
- }
- goto Login;
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement