Results 1 to 6 of 6
  1. #1
    Invidus's Avatar
    Join Date
    Jan 2010
    Gender
    male
    Posts
    2,167
    Reputation
    23
    Thanks
    650
    My Mood
    Bored

    Code for Injector; Importing DLL into Listbox

    Hey all
    I'm currently working on an injector at the mo', and i need the code for adding the dll to a listbox. I'm Importing the dll from there like this, tell me if its correct;

    Private Sub Timer1_Tick(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Timer1.Tick

    If IO.File.Exists(Application.StartupPath & "\" + ListBox1.Text + ".dll") Then
    Dim TargetProcess As Process() = Process.GetProcessesByName("HSUpdate")
    If TargetProcess.Length = 0 Then

    Else
    Timer1.Stop()
    Call Inject()

  2. The Following User Says Thank You to Invidus For This Useful Post:

    technologicpunk (04-10-2010)

  3. #2
    LegendaryAbbo's Avatar
    Join Date
    Dec 2008
    Gender
    male
    Posts
    5,243
    Reputation
    23
    Thanks
    546
    My Mood
    Relaxed
    Moved to Visual Basic section.

  4. #3
    NextGen1's Avatar
    Join Date
    Dec 2009
    Gender
    male
    Location
    Not sure really.
    Posts
    6,312
    Reputation
    382
    Thanks
    3,019
    My Mood
    Amazed
    On Form Load Or Button Click
    Code:
      Dim fl() As String
            Dim fn As String
            Dim fp As String
            Dim I As Integer
            fp = "directory for dlls"
    
            fn = Dir(fp & "*.dll") ' You can change this to a specific file if you only need one dll (as opposed to *.dll it will be filename.dll
            While fn <> ""
                I = I + 1
                ReDim Preserve fl(0 To I)
                fl(I) = fn
                fn = Dir()
            End While
    
            If I = 0 Then
                MsgBox("Error Control here")
                Exit Sub
            End If
            For I = 1 To UBound(fl)
                ListBox1.Items.Add(fl(I))
            Next


     


     


     



    The Most complete application MPGH will ever offer - 68%




  5. #4
    |-|3|_][({}PT3R12's Avatar
    Join Date
    Nov 2008
    Gender
    male
    Location
    UnkwOwnS
    Posts
    449
    Reputation
    12
    Thanks
    472
    My Mood
    Twisted
    Nextgen your always so confusing lol. Plain and simple


    To Load Items
    Code:
    Dim open As New OpenFileDialog
            open.Multiselect = True
            open.Filter = "DLL Files(*.dll) |*.dll"
            open.CheckFileExists = True
            open.ShowDialog()
    
            If (open.FileName = "") Then
            Else
                For Each item As String In open.FileNames
                    Dim listItem As New ListViewItem
                    listItem.Text = item
                    Dim subItem As New ListViewItem.ListViewSubItem()
                    subItem.Text = My.Computer.FileSystem.GetName(item)
                    listItem.SubItems.Add(subItem)
                    ListView1.Items.Add(listItem)
                Next
            End If

    To Delete Items
    Code:
            For Each lrow As ListViewItem In ListView1.SelectedItems
                ListView1.Items.Remove(lrow)
            Next
    To Inject The Current Items
    Code:
    Private Sub Inject()
            Try
                For Each lrow As ListViewItem In ListView1.Items
                    Timer1.Stop()
                    Dim TargetProcess As Process() = Process.GetProcessesByName(ComboBox1.Text) 'Change to your .exe
                    TargetProcessHandle = OpenProcess(PROCESS_CREATE_THREAD Or PROCESS_VM_OPERATION Or PROCESS_VM_WRITE, False, TargetProcess(0).Id)
                    pszLibFileRemote = lrow.Text
                    pfnStartAddr = GetProcAddress(GetModuleHandle("Kernel32"), "LoadLibraryA")
                    TargetBufferSize = 1 + Len(pszLibFileRemote)
                    Dim Rtn As Integer
                    Dim LoadLibParamAdr As Integer
                    LoadLibParamAdr = VirtualAllocEx(TargetProcessHandle, 0, TargetBufferSize, MEM_COMMIT, PAGE_READWRITE)
                    Rtn = WriteProcessMemory(TargetProcessHandle, LoadLibParamAdr, pszLibFileRemote, TargetBufferSize, 0)
                    CreateRemoteThread(TargetProcessHandle, 0, 0, pfnStartAddr, LoadLibParamAdr, 0, 0)
                    CloseHandle(TargetProcessHandle)
                    Success(1)
                    Me.Close()
                Next
            Catch es As Exception
                Success(2)
                Me.Close()
            End Try

  6. #5
    NextGen1's Avatar
    Join Date
    Dec 2009
    Gender
    male
    Location
    Not sure really.
    Posts
    6,312
    Reputation
    382
    Thanks
    3,019
    My Mood
    Amazed
    Off topic

    I go off my head as far as answering questions to the best I can udnerstand the question, So If I am Always confusing you or you find my answers confusing, feel free to PM me and I will Clear it up.

    I don't take advantage to the luxury of copying and pasting answers found on the net or in others code examples here, so it makes it slightly more "complex" for me.

    On Topic, He wanted to import a single DLL, not a list of dll's, my answer solves importing all dll's so "Yours" may be optimum here.


     


     


     



    The Most complete application MPGH will ever offer - 68%




  7. #6
    hopefordope's Avatar
    Join Date
    Aug 2009
    Gender
    male
    Location
    Herndon,VA
    Posts
    264
    Reputation
    9
    Thanks
    86
    My Mood
    Psychedelic
    wut r u tlkin NG1 is clear as possible

    Press Thank You[IMG]https://i45.tinypic.com/2hg8w0n.jpghttps://img1.UploadScreensho*****m/images/main/2/3203234450.jpg[/IMG]










    My Releases
    Injector 3G
    Injector 2G
    Injector 1G
    Super Spammer
    CA Cleaner
    My Tutorials
    How to Make a real Injector(PerX)
    How to Make a Calculator(leeched)

  8. The Following User Says Thank You to hopefordope For This Useful Post:

    NextGen1 (02-21-2010)

Similar Threads

  1. [Request]code for manual injector
    By /b/oss in forum Visual Basic Programming
    Replies: 3
    Last Post: 03-14-2010, 05:44 AM
  2. [Help] How to pack a .DLL into Injector?
    By Invidus in forum Visual Basic Programming
    Replies: 2
    Last Post: 02-28-2010, 06:12 AM
  3. [Help] Code for ListBox
    By Invidus in forum Visual Basic Programming
    Replies: 5
    Last Post: 02-21-2010, 06:26 AM
  4. DLL Files for injector
    By asassinx1 in forum Combat Arms Europe Hacks
    Replies: 5
    Last Post: 02-02-2010, 09:16 AM
  5. Can someone put this DLL into a tanitum injector?
    By zmansquared in forum Battlefield 2 Hacks & Cheats
    Replies: 2
    Last Post: 08-01-2009, 04:46 PM