Advertisement
339r

Ex src

Jul 13th, 2019
605
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
VB.NET 20.05 KB | None | 0 0
  1. Imports System.ComponentModel
  2. Imports System.Text.RegularExpressions, System.Net, System.Text, System.IO
  3. Public Class Form1
  4.     Dim erorrys As String
  5.     Dim Commentid As String
  6.     Dim am As System.Threading.Thread
  7.     Dim posts As New ListBox
  8.     Dim w As New WebClient
  9.     Dim sa As Boolean = False
  10.     Dim min, nub, like_error, like_done, cm_error, cm_done, cm_lkie_done, cm_lkie_error As Single
  11.     Dim cookies, csrftoken, cookies2, csrftoken2 As String
  12.  
  13.     ' Dim idmedia As String
  14.     Public Sub New()
  15.  
  16.         ' This call is required by the designer.
  17.         InitializeComponent()
  18.         Me.Size = New Size("200", "235")
  19.         Control.CheckForIllegalCrossThreadCalls = False
  20.         ' Add any initialization after the InitializeComponent() call.
  21.     End Sub
  22.     Private Sub Button3_Click(sender As Object, e As EventArgs) Handles Button3.Click
  23.         If sa Then
  24.             Try
  25.                 If Button3.Tag = 1 Then
  26.                     am = New Threading.Thread(AddressOf Get_EX)
  27.                     am.IsBackground = True
  28.                     am.Start()
  29.                     Button3.Text = "Stop" : Button3.Tag = 2
  30.                 ElseIf Button3.Tag = 2 Then
  31.                     Button3.Enabled = False : exitam() : Button3.Text = "Start" : Button3.Tag = 1
  32.                 End If
  33.             Catch ex As Exception
  34.  
  35.             End Try
  36.         Else
  37.             MsgBox("Plz, LOGIN fuckers!?")
  38.         End If
  39.     End Sub
  40.     Private Sub Button2_Click(sender As Object, e As EventArgs) Handles Button2.Click
  41.         If Button2.Tag = 1 Then
  42.             Me.Size = New Size("390", "235")
  43.             Button2.Tag = 2 : Button2.Text = Button2.Text.Replace("Open", "Close").Trim
  44.         ElseIf Button2.Tag = 2 Then
  45.             Me.Size = New Size("200", "235")
  46.             Button2.Tag = 1 : Button2.Text = Button2.Text.Replace("Close", "Open").Trim
  47.         End If
  48.     End Sub
  49.     Private Sub Button1_Click(sender As Object, e As EventArgs) Handles Button1.Click
  50.         LinkLabel1.Text = Nothing
  51.         If LOGIN_insta(TextBox1.Text, TextBox2.Text) Then
  52.             LinkLabel1.Text = "DONE LOGIN"
  53.             Button2.Enabled = True
  54.         Else
  55.             LinkLabel1.Text = "FALSE LOGIN"
  56.         End If
  57.     End Sub
  58.  
  59.     Private Sub TextBox2_DoubleClick(sender As Object, e As EventArgs) Handles TextBox2.DoubleClick
  60.         If TextBox2.UseSystemPasswordChar = False Then
  61.             TextBox2.UseSystemPasswordChar = True
  62.         ElseIf TextBox2.UseSystemPasswordChar = True Then
  63.             TextBox2.UseSystemPasswordChar = False
  64.         End If
  65.     End Sub
  66.     Private Sub TextBox5_TextChanged(sender As Object, e As EventArgs) Handles TextBox5.TextChanged
  67.         Try
  68.             If TextBox5.Text > 0.25 Then
  69.                 min = TextBox5.Text
  70.             Else
  71.                 TextBox5.Text = 0.25
  72.                 min = TextBox5.Text
  73.             End If
  74.         Catch ex As Exception
  75.             TextBox5.Text = 0.25
  76.             min = TextBox5.Text
  77.         End Try
  78.     End Sub
  79.  
  80.     Private Sub CheckBox2_CheckedChanged(sender As Object, e As EventArgs) Handles CheckBox2.CheckedChanged
  81.         If CheckBox2.Checked = True And ListBox1.Items.Count = 0 Then
  82.             CheckBox2.Checked = False
  83.             MsgBox("There No COOKIES!?")
  84.         End If
  85.     End Sub
  86.  
  87.     Private Function LOGIN_insta(ByVal user, ByVal pass)
  88.  
  89.         Using w
  90.             Dim datainput As New System.Collections.Specialized.NameValueCollection
  91.             datainput.Add("username", user)
  92.             datainput.Add("password", pass)
  93.             Try
  94.                 w.Headers.Add("user-agent: Mozilla/5.0 (compatible; Googlebot/2.1; +http://www.google.com/bot.html)")
  95.                 w.Headers.Add("KeepAlive: True")
  96.                 w.Headers.Add("x-csrftoken", "messing")
  97.                 w.Headers.Add("accept-language", "en-US,en;q=0.9,ar-SA;q=0.8,ar;q=0.7")
  98.                 w.Headers.Add("content-type", "application/x-www-form-urlencoded")
  99.                 w.Headers.Add("x-instagram-ajax", "1")
  100.                 w.Headers.Add("x-requested-with: XMLHttpRequest")
  101.                 w.UploadValues("https://www.instagram.com/accounts/login/ajax/", "POST", datainput)
  102.                 If w.ResponseHeaders("set-cookie").Contains("sessionid") Then
  103.                     cookies = Regex.Match(w.ResponseHeaders("set-cookie"), "csrftoken=(.*?);").Value & Space(1) & Regex.Match(w.ResponseHeaders("set-cookie"), "ds_user_id=(.*?);").Value & Space(1) & Regex.Match(w.ResponseHeaders("set-cookie"), "mid=(.*?);").Value & Space(1) & Regex.Match(w.ResponseHeaders("set-cookie"), "rur=(.*?);").Value & Space(1) & Regex.Match(w.ResponseHeaders("set-cookie"), "sessionid=(.*?);").Value & Space(1) & Regex.Match(w.ResponseHeaders("set-cookie"), "shbid=(.*?);").Value & Space(1) & Regex.Match(w.ResponseHeaders("set-cookie"), "shbts=(.*?);").Value & Space(1) & Regex.Match(w.ResponseHeaders("set-cookie"), "urlgen=(.*?);").Value & Space(1)
  104.                     csrftoken = Regex.Match(cookies, "csrftoken=(.*?);").Groups(1).Value
  105.                     sa = True : Return True
  106.                 Else
  107.                     Return False
  108.                 End If
  109.  
  110.             Catch ex As Exception
  111.                 Return False
  112.             End Try
  113.         End Using
  114.     End Function
  115.  
  116.     Private Sub CoustomToolStripMenuItem_Click(sender As Object, e As EventArgs) Handles CoustomToolStripMenuItem.Click
  117.         LinkLabel1.Text = Nothing
  118.         TextBox1.Clear()
  119.         TextBox2.Clear()
  120.         Try
  121.             Dim x = InputBox("Your Cookies")
  122.             cookies = Regex.Match(x, "csrftoken=(.*?);").Value & Space(1) & Regex.Match(x, "ds_user_id=(.*?);").Value & Space(1) & Regex.Match(x, "mid=(.*?);").Value & Space(1) & Regex.Match(x, "rur=(.*?);").Value & Space(1) & Regex.Match(x, "sessionid=(.*?);").Value & Space(1) & Regex.Match(x, "shbid=(.*?);").Value & Space(1) & Regex.Match(x, "shbts=(.*?);").Value & Space(1) & Regex.Match(x, "urlgen=(.*?);").Value & Space(1)
  123.             csrftoken = Regex.Match(cookies, "csrftoken=(.*?);").Groups(1).Value
  124.             Try
  125.                 Dim w As New System.Net.WebClient
  126.                 w.Headers.Add("cookie", cookies)
  127.                 'w.Headers.Add("x-csrftoken", csrftoken)
  128.                 Dim dataos As String = w.DownloadString("https://www.instagram.com/accounts/privacy_and_security/?__a=1")
  129.                 If dataos.Contains("form_data") Then
  130.                     Button2.Enabled = True
  131.                     sa = True
  132.                     Dim infostring As String = w.DownloadString("https://i.instagram.com/api/v1/users/" & Regex.Match(cookies, "sessionid=(\d*)").Groups(1).Value & "/info/")
  133.                     TextBox1.Text = Regex.Match(infostring, """username"": ""(\w+)""").Groups(1).Value
  134.                     LinkLabel1.Text = "DONE LOGIN"
  135.                 Else
  136.                     MsgBox("Error Cookies")
  137.                 End If
  138.             Catch ex As Exception
  139.                 MsgBox("Error Cookies")
  140.             End Try
  141.         Catch ex As Exception
  142.             MsgBox("Error")
  143.         End Try
  144.     End Sub
  145.  
  146.     Private Sub AddCustomCOOKIESToolStripMenuItem_Click(sender As Object, e As EventArgs) Handles AddCustomCOOKIESToolStripMenuItem.Click
  147.         Try
  148.             Dim x = InputBox("Your Cookies")
  149.             Dim cookiesy = Regex.Match(x, "csrftoken=(.*?);").Value & Space(1) & Regex.Match(x, "ds_user_id=(.*?);").Value & Space(1) & Regex.Match(x, "mid=(.*?);").Value & Space(1) & Regex.Match(x, "rur=(.*?);").Value & Space(1) & Regex.Match(x, "sessionid=(.*?);").Value & Space(1) & Regex.Match(x, "shbid=(.*?);").Value & Space(1) & Regex.Match(x, "shbts=(.*?);").Value & Space(1) & Regex.Match(x, "urlgen=(.*?);").Value & Space(1)
  150.             'csrftoken = Regex.Match(cookies, "csrftoken=(.*?);").Groups(1).Value
  151.             Try
  152.                 Dim w As New System.Net.WebClient
  153.                 w.Headers.Add("cookie", cookiesy)
  154.                 'w.Headers.Add("x-csrftoken", csrftoken)
  155.                 Dim dataos As String = w.DownloadString("https://www.instagram.com/accounts/privacy_and_security/?__a=1")
  156.                 If dataos.Contains("form_data") Then
  157.                     Dim infostring As String = w.DownloadString("https://i.instagram.com/api/v1/users/" & Regex.Match(cookiesy, "sessionid=(\d*)").Groups(1).Value & "/info/")
  158.                     ListBox1.Items.Add(cookiesy)
  159.                     MsgBox("DONE LOGIN " & Regex.Match(infostring, """username"": ""(\w+)""").Groups(1).Value)
  160.                 Else
  161.                     MsgBox("Error Cookies")
  162.                 End If
  163.             Catch ex As Exception
  164.                 MsgBox("Error Cookies")
  165.             End Try
  166.         Catch ex As Exception
  167.             MsgBox("Error")
  168.         End Try
  169.     End Sub
  170.  
  171.     Private Sub Get_EX()
  172.  
  173.         Do
  174.             Try
  175.                 Dim datay As String
  176.                 Using w As New WebClient
  177.                     w.Headers.Add("user-agent: Mozilla/5.0 (compatible; Googlebot/2.1; +http://www.google.com/bot.html)")
  178.                     w.Headers.Add("Cookie", cookies)
  179.                     datay = Regex.Unescape(w.DownloadString("https://www.instagram.com/graphql/query/?query_hash=ecd67af449fb6edab7c69a205413bfa7&variables={%22first%22:50}"))
  180.                     Dim a = Regex.Matches(datay, "{""text"":"".*?""shortcode"":"".*?""")
  181.                     For Each ma As Match In a
  182.                         Dim b = ma.Value.ToString
  183.                         If CheckBox1.Checked = True Then
  184.                             If HasArabicCharacters(b) Then
  185.                                 Dim c = Regex.Match(b, """shortcode"":""(.*?)""").Groups(1).Value
  186.                                 Dim wbs As New WebClient
  187.                                 Dim texto As String = wbs.DownloadString("https://www.instagram.com/p/" & c.ToString)
  188.                                 Dim mediaid = Regex.Match(texto, "media.?id=(.*?)""").Groups(1).Value
  189.                                 'MsgBox(mediaid.ToString)
  190.                                 posts.Items.Add(mediaid.ToString)
  191.                                 '           ListBox1.Items.Add(mediaid.ToString)
  192.                                 Label4.Text = (posts.Items.Count) : Label4.Refresh()
  193.                             Else
  194.  
  195.                             End If
  196.                         ElseIf Not CheckBox1.Checked = True Then
  197.                             Dim c = Regex.Match(b, """shortcode"":""(.*?)""").Groups(1).Value
  198.                             Dim wbs As New WebClient
  199.                             Dim texto As String = wbs.DownloadString("https://www.instagram.com/p/" & c.ToString)
  200.                             Dim mediaid = Regex.Match(texto, "media.?id=(.*?)""").Groups(1).Value
  201.                             'MsgBox(mediaid.ToString)
  202.                             posts.Items.Add(mediaid.ToString)
  203.                             '      ListBox1.Items.Add(mediaid.ToString)
  204.                             Label4.Text = (posts.Items.Count) : Label4.Refresh()
  205.                         End If
  206.                     Next
  207.                     If do_like(posts.Items(nub)) Then
  208.                         like_done += 1
  209.                     Else
  210.                         like_error += 1
  211.                         MessageBox.Show(erorrys)
  212.                     End If
  213.                     If do_comment(posts.Items(nub)) Then
  214.                         cm_done += 1
  215.                         If CheckBox2.Checked = True Then
  216.  
  217.                             For Each cooke In ListBox1.Items
  218.                                 cookies2 = (cooke)
  219.                                 csrftoken2 = Regex.Match(cooke, "csrftoken=(.*?);").Groups(1).Value
  220.                                 If Like_Comment_ID(Commentid, cookies2) Then
  221.                                     cm_lkie_done += 1
  222.                                 Else
  223.                                     cm_lkie_error += 1
  224.                                 End If
  225.                             Next
  226.                         End If
  227.                     Else
  228.                         cm_error += 1
  229.                     End If
  230.                 End Using
  231.  
  232.             Catch ex As Exception
  233.  
  234.             End Try
  235.             nub += 1
  236.             Label5.Text = "Done like: " & like_done & " Error like: " & like_error & vbNewLine & "Done CM: " & cm_done & " Error CM: " & cm_error
  237.             Label6.Text = "Done like: " & cm_lkie_done & " Error like: " & cm_lkie_error
  238.             Try
  239.                 System.Threading.Thread.Sleep(60000 * TextBox5.Text)
  240.             Catch ex As Exception
  241.  
  242.             End Try
  243.         Loop
  244.     End Sub
  245.  
  246.     Private Sub Button4_Click(sender As Object, e As EventArgs) Handles Button4.Click
  247.         Dim ss As System.Threading.Thread
  248.         ss = New Threading.Thread(Sub()
  249.                                       Dim x, y
  250.                                       x = InputBox("Uesrname:")
  251.                                       y = InputBox("Password")
  252.                                       If LOGIN2_insta(x, y) Then
  253.                                           ListBox1.Items.Add(cookies2)
  254.                                       Else
  255.                                           MsgBox("Error Acconut")
  256.                                       End If
  257.                                       ss.Abort()
  258.                                   End Sub)
  259.         ss.Start()
  260.     End Sub
  261.  
  262.     Friend Function HasArabicCharacters(ByVal text As String) As Boolean
  263.         Dim regex As Regex = New Regex("[\u0600-\u06ff]|[\u0750-\u077f]|[\ufb50-\ufc3f]|[\ufe70-\ufefc]")
  264.         Return regex.IsMatch(text)
  265.     End Function
  266.     Friend Function do_like(ByVal id)
  267.         Dim wb As New WebClient
  268.         Dim rsa As String
  269.         Try
  270.             Using wb
  271.                 wb.Headers.Add("x-csrftoken", csrftoken)
  272.                 wb.Headers.Add("cookie", cookies)
  273.                 rsa = wb.UploadString("https://www.instagram.com/web/likes/" & id & "/like/", "POST")
  274.                 If rsa.Contains("{""status"": ""ok""}") Then
  275.                     Return True
  276.                 Else
  277.                     erorrys = rsa
  278.                     Return False
  279.                 End If
  280.             End Using
  281.         Catch ex As System.Net.WebException
  282.             Return False
  283.         End Try
  284.     End Function
  285.     Friend Function do_comment(ByVal id)
  286.         Dim wbo As New WebClient
  287.         Dim datainput As New System.Collections.Specialized.NameValueCollection
  288.         datainput.Add("comment_text", TextBox3.Text)
  289.         datainput.Add("replied_to_comment_id", "")
  290.         Using wbo
  291.             Try
  292.                 wbo.Headers.Add("x-csrftoken", csrftoken)
  293.                 wbo.Headers.Add("cookie", cookies)
  294.                 Dim rsbo = wbo.UploadValues("https://www.instagram.com/web/comments/" & id & "/add/ ", "POST", datainput)
  295.                 Dim responsebody = (New Text.UTF8Encoding).GetString(rsbo)
  296.                 If responsebody.Contains("""status"": ""ok""") Then
  297.                     Commentid = Regex.Match(responsebody, """id"": ""(.*?)""").Groups(1).Value
  298.                     Return True
  299.                 Else
  300.                     Return False
  301.                 End If
  302.             Catch ex As System.Net.WebException
  303.                 Return False
  304.             End Try
  305.         End Using
  306.  
  307.     End Function
  308.  
  309.     Private Sub Form1_Closing(sender As Object, e As CancelEventArgs) Handles Me.Closing
  310.         Memberships.Close()
  311.         Application.ExitThread()
  312.         Application.Exit()
  313.     End Sub
  314.     Sub exitam()
  315.         Button3.Enabled = True
  316.         am.Abort()
  317.     End Sub
  318.     Friend Function LOGIN2_insta(ByVal user, ByVal pass)
  319.  
  320.         Using w
  321.             w.Headers.Clear()
  322.             Dim datainput As New System.Collections.Specialized.NameValueCollection
  323.             datainput.Add("username", user)
  324.             datainput.Add("password", pass)
  325.             Try
  326.                 w.Headers.Add("user-agent: Mozilla/5.0 (Linux; Android 8.0.0; SAMSUNG SM-J600G Build/R16NW) AppleWebKit/537.36 (KHTML, like Gecko) SamsungBrowser/7.4 Chrome/59.0.3071.125 Mobile Safari/537.36")
  327.                 w.Headers.Add("KeepAlive: True")
  328.                 w.Headers.Add("x-csrftoken", "messing")
  329.                 w.Headers.Add("accept-language", "en-US,en;q=0.9,ar-SA;q=0.8,ar;q=0.7")
  330.                 w.Headers.Add("content-type", "application/x-www-form-urlencoded")
  331.                 w.Headers.Add("x-instagram-ajax", "1")
  332.                 w.Headers.Add("x-requested-with: XMLHttpRequest")
  333.                 w.UploadValues("https://www.instagram.com/accounts/login/ajax/", "POST", datainput)
  334.                 If w.ResponseHeaders("set-cookie").Contains("sessionid") Then
  335.                     cookies2 = Regex.Match(w.ResponseHeaders("set-cookie"), "csrftoken=(.*?);").Value & Space(1) & Regex.Match(w.ResponseHeaders("set-cookie"), "ds_user_id=(.*?);").Value & Space(1) & Regex.Match(w.ResponseHeaders("set-cookie"), "mid=(.*?);").Value & Space(1) & Regex.Match(w.ResponseHeaders("set-cookie"), "rur=(.*?);").Value & Space(1) & Regex.Match(w.ResponseHeaders("set-cookie"), "sessionid=(.*?);").Value & Space(1) & Regex.Match(w.ResponseHeaders("set-cookie"), "shbid=(.*?);").Value & Space(1) & Regex.Match(w.ResponseHeaders("set-cookie"), "shbts=(.*?);").Value & Space(1) & Regex.Match(w.ResponseHeaders("set-cookie"), "urlgen=(.*?);").Value & Space(1)
  336.                     sa = True : Return True
  337.                 Else
  338.                     Return False
  339.                 End If
  340.                 ' hahaha Private api :)))
  341.             Catch ex As Exception
  342.                 Return False
  343.             End Try
  344.         End Using
  345.     End Function
  346.     Public Function Like_Comment_ID(Comment_ID As String, cookiesy As String) As Boolean
  347.  
  348.         Try
  349.  
  350.             If (cookies.Length = 0) Then
  351.                 Return False
  352.             Else
  353.  
  354.                 Dim csrftoken As String = Regex.Match(cookiesy, "csrftoken=(.*?);").Groups(1).Value
  355.                 Dim postData As String = ""
  356.                 Dim tempcook As New CookieContainer
  357.                 Dim en As New UTF8Encoding
  358.                 Dim byteData As Byte() = en.GetBytes(postData)
  359.  
  360.                 Dim httpPost = DirectCast(WebRequest.Create("https://www.instagram.com/web/comments/like/" & Comment_ID & "/"), HttpWebRequest)
  361.  
  362.                 httpPost.Method = "POST"
  363.                 httpPost.KeepAlive = True
  364.                 httpPost.ContentType = "application/x-www-form-urlencoded"
  365.                 httpPost.UserAgent = ("user-agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/74.0.3729.169 Safari/537.36")
  366.                 httpPost.ContentLength = byteData.Length
  367.                 httpPost.Headers.Add("x-csrftoken", csrftoken)
  368.                 httpPost.Headers.Add("X-Instagram-AJAX", "1")
  369.                 httpPost.Headers.Add("x-requested-with", "XMLHttpRequest")
  370.                 httpPost.Headers.Add("Cookie", cookiesy)
  371.  
  372.                 'Send Data
  373.                 Dim poststr As Stream = httpPost.GetRequestStream()
  374.                 poststr.Write(byteData, 0, byteData.Length)
  375.                 poststr.Close()
  376.  
  377.                 'Get Response
  378.                 Dim POST_Response As HttpWebResponse
  379.                 POST_Response = DirectCast(httpPost.GetResponse(), HttpWebResponse)
  380.  
  381.  
  382.                 Dim Post_Reader As New StreamReader(POST_Response.GetResponseStream())
  383.                 Dim Response As String = Post_Reader.ReadToEnd
  384.  
  385.  
  386.                 If Response.Contains("{""status"": ""ok""}") Then
  387.                     Return True
  388.                 Else
  389.                     Return False
  390.                 End If
  391.             End If
  392.  
  393.  
  394.         Catch ex As Exception
  395.             Return False
  396.         End Try
  397.  
  398.     End Function
  399.     Private Sub Form1_Shown(sender As Object, e As EventArgs) Handles Me.Shown
  400.         Dim datay As String
  401.         Try
  402.             Using w As New Net.WebClient
  403.                 w.Proxy = Nothing
  404.                 datay = w.DownloadString("https://339r.blogspot.com/p/memberships.html")
  405.                 'MsgBox(datay)
  406.                 If Not datay.Contains(My.Settings.HWID) Then
  407.                     MsgBox("Error!")
  408.                     Memberships.Close()
  409.                     Application.ExitThread()
  410.                 End If
  411.             End Using
  412.         Catch ex As Exception
  413.  
  414.         End Try
  415.     End Sub
  416. End Class
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement