Skocz do zawartości
  • 👋 Witaj na MPCForum!

    Przeglądasz forum jako gość, co oznacza, że wiele świetnych funkcji jest jeszcze przed Tobą! 😎

    • Pełny dostęp do działów i ukrytych treści
    • Możliwość pisania i odpowiadania w tematach
    • System prywatnych wiadomości
    • Zbieranie reputacji i rozwijanie swojego profilu
    • Członkostwo w jednej z największych społeczności graczy

    👉 Dołączenie zajmie Ci mniej niż minutę – a zyskasz znacznie więcej!

    Zarejestruj się teraz

DLL Injector V0.1 PL x64/x86


Rekomendowane odpowiedzi

Opublikowano

Witam

W tym temacie przedstawię DLL INJECTOR.

Program został napisany prze zemnie.

Oto ss:

 

beztytuuhnb.png

 

Oto download:

 

 

Oto scan:

 

 

 

ZAKAZ ROZPOWSZECHNIANIA BEZ MOJEJ ZGODY!

Program musi być uruchomiony jako administrator!

Oto kod:

#RequireAdmin

#Region ;**** Directives created by AutoIt3Wrapper_GUI ****
#AutoIt3Wrapper_Icon=file_dll.ico
#AutoIt3Wrapper_Outfile=DLL INJETOR x86.exe
#AutoIt3Wrapper_Outfile_x64=DLL INJETOR x64.exe
#AutoIt3Wrapper_UseUpx=n
#AutoIt3Wrapper_Compile_Both=y
#EndRegion ;**** Directives created by AutoIt3Wrapper_GUI ****
#include <GUIConstants.au3>
GUICreate("DLL INJECTOR", 275, 100)
GUISetBkColor(0xFFFFFF)
GUICtrlCreateLabel("Proces:", 10, 10, 50, 17)
$I_ProcessName = GUICtrlCreateInput("", 65, 10, 200, 21)
GUICtrlCreateLabel("DLL:", 10, 40, 50, 17)
$I_DllPath = GUICtrlCreateInput("", 65, 40, 150, 21)
$B_SearchDll = GUICtrlCreateButton("...", 225, 40, 40, 25)
$R_Auto = GUICtrlCreateRadio("Automat", 10, 75, 75, 17)
GUICtrlSetState(-1, $GUI_CHECKED)
$R_Man = GUICtrlCreateRadio("Manual", 130, 75, 55, 17)
$B_Inject = GUICtrlCreateButton("Wstrzyknij", 190, 70, 75, 25)
GUICtrlSetState(-1, $GUI_DISABLE)
GUISetState()
$Injected = False
Do
$Msg = GUIGetMsg()
Switch $Msg
Case $B_SearchDll
GUICtrlSetData($I_DllPath, FileOpenDialog("Dll", @HomeDrive, "Dynamic Link Library (*.dll)", 3))
Case $R_Auto
GUICtrlSetState($B_Inject, $GUI_DISABLE)
Case $R_Man
GUICtrlSetState($B_Inject, $GUI_ENABLE)
Case $B_Inject
_InjectDll(ProcessExists(GUICtrlRead($I_ProcessName)), GUICtrlRead($I_DllPath))
_Message(@error)
EndSwitch
If BitAND(GUICtrlRead($R_Auto), $GUI_CHECKED) And Not $Injected Then
$ProcessId = ProcessExists(GUICtrlRead($I_ProcessName))
If $ProcessId > 0 Then
_InjectDll($ProcessId, GUICtrlRead($I_DllPath))
_Message(@error)
$Injected = True
;Exit
EndIf
EndIf
Sleep(10)
Until $Msg == $GUI_EVENT_CLOSE
Func _Message($ErrorCode)
If $ErrorCode <> 0 Then
MsgBox(48, "ERROR", "Wystąpił błąd!" & @CRLF & "Kod błędu: " & @error)
Else
MsgBox(64, "Info", "Wstrzyknięte pomyślnie!")
EndIf
EndFunc
Func _InjectDll($ProcessId, $DllPath)
If $ProcessId == 0 Then Return SetError(1, "", False)
If Not(FileExists($DllPath)) Then Return SetError(2, "", False)
If Not(StringRight($DllPath, 4) == ".dll") Then Return SetError(3, "", False)
$Kernel32 = DllOpen("kernel32.dll")
If @error Then Return SetError(4, "", False)
$DLL_Path = DllStructCreate("char[255]")
DllCall($Kernel32, "DWORD", "GetFullPathNameA", "str", $DllPath, "DWORD", 255, "ptr", DllStructGetPtr($DLL_Path), "int", 0)
If @error Then Return SetError(5, "", False)
$hProcess = DllCall($Kernel32, "DWORD", "OpenProcess", "DWORD", 0x1F0FFF, "int", 0, "DWORD", $ProcessId)
If @error Then Return SetError(6, "", False)
$hModule = DllCall($Kernel32, "DWORD", "GetModuleHandleA", "str", "kernel32.dll")
If @error Then Return SetError(7, "", False)
$lpStartAddress = DllCall($Kernel32, "DWORD", "GetProcAddress", "DWORD", $hModule[0], "str", "LoadLibraryA")
If @error Then Return SetError(8, "", False)
$lpParameter = DllCall($Kernel32, "DWORD", "VirtualAllocEx", "int", $hProcess[0], "int", 0, "ULONG_PTR", DllStructGetSize($DLL_Path), "DWORD", 0x3000, "int", 4)
If @error Then Return SetError(9, "", False)
DllCall("kernel32.dll", "BOOL", "WriteProcessMemory", "int", $hProcess[0], "DWORD", $lpParameter[0], "str", DllStructGetData($DLL_Path, 1), "ULONG_PTR", DllStructGetSize($DLL_Path), "int", 0)
If @error Then Return SetError(10, "", False)
$hThread = DllCall($Kernel32, "int", "CreateRemoteThread", "DWORD", $hProcess[0], "int", 0, "int", 0, "DWORD", $lpStartAddress[0], "DWORD", $lpParameter[0], "int", 0, "int", 0)
If @error Then Return SetError(11, "", False)
DllCall($Kernel32, "BOOL", "CloseHandle", "DWORD", $hProcess[0])
DllClose($Kernel32)
Return SetError(0, "", True)

EndFunc

Gdy wyskakuje error 0 to oznacza że proces nie jest włączony ścieżka źle podana.

Mój stary nick: damian5602
Nick League Of Legends: Sonaes

  • 3 tygodnie później...
Opublikowano

a co to robi ?? :P

 

 

Otwiera pliki .dll , których nie możesz inaczej otworzyć . Zastosowanie ma np. w botach . Wiele z nich jest plikiem .dll , więc to otwiera je ;)

Opublikowano

Ehe, sam napisałeś funkcję do tworzenia wątku w procesie,...

/ GA-970A-UD3 / FX-6300 / Sapphire Xtreme 5830 / OCZ ZS 550W / Brutus M23 /

| MPC Coders Team | MPC Gold Member | C#, C++, PHP, (N)ASM, AutoIT, Python, Java |

Opublikowano

 

#AutoIt3Wrapper_UseUpx=n
#AutoIt3Wrapper_UseX64=n

#RequireAdmin
#include <GUIConstants.au3>

GUICreate("Beispiel", 275, 100)
GUISetBkColor(0xFFFFFF)
GUICtrlCreateLabel("Prozess:", 10, 10, 50, 17)
$I_ProcessName = GUICtrlCreateInput("", 65, 10, 200, 21)
GUICtrlCreateLabel("DLL:", 10, 40, 50, 17)
$I_DllPath = GUICtrlCreateInput("", 65, 40, 150, 21)
$B_SearchDll = GUICtrlCreateButton("...", 225, 40, 40, 25)
$R_Auto = GUICtrlCreateRadio("Automatisch", 10, 75, 75, 17)
GUICtrlSetState(-1, $GUI_CHECKED)
$R_Man = GUICtrlCreateRadio("Manuell", 130, 75, 55, 17)
$B_Inject = GUICtrlCreateButton("Injizieren", 190, 70, 75, 25)
GUICtrlSetState(-1, $GUI_DISABLE)
GUISetState()

$Injected = False

Do
    $Msg = GUIGetMsg()
    Switch $Msg
        Case $B_SearchDll
            GUICtrlSetData($I_DllPath, FileOpenDialog("Dll", @HomeDrive, "Dynamic Link Library (*.dll)", 3))
        Case $R_Auto
            GUICtrlSetState($B_Inject, $GUI_DISABLE)
        Case $R_Man
            GUICtrlSetState($B_Inject, $GUI_ENABLE)
        Case $B_Inject
            _InjectDll(ProcessExists(GUICtrlRead($I_ProcessName)), GUICtrlRead($I_DllPath))
            _Message(@error)
    EndSwitch

    If BitAND(GUICtrlRead($R_Auto), $GUI_CHECKED) And Not $Injected Then
        $ProcessId = ProcessExists(GUICtrlRead($I_ProcessName))
        If $ProcessId > 0 Then
            _InjectDll($ProcessId, GUICtrlRead($I_DllPath))
            _Message(@error)
            $Injected = True
            ;Exit
        EndIf
    EndIf

    Sleep(10)
Until $Msg == $GUI_EVENT_CLOSE



Func _Message($ErrorCode)
    If $ErrorCode <> 0 Then
        MsgBox(48, "Fehler", "Es ist ein Fehler aufgetreten!" & @CRLF & "Fehlercode: " & @error)
    Else
        MsgBox(64, "Info", "Injektion erfolgreich!")
    EndIf
EndFunc


;=================================================================================================
; Function:            _InjectDll($ProcessId, $DllPath)
; Description:        Injects a .dll into a running program.
; Return Value(s):    On Success - Returns true
;                    On Failure - Returns false
;                    @Error - 0 = No error.
;                             1 = Invalid ProcessId.
;                             2 = File does not exist.
;                             3 = File is not a .dll (invalid file).
;                             4 = Failed to open 'Advapi32.dll'.
;                             5 = Failed to get the full path.
;                             6 = Failed to open the process.
;                             7 = Failed to call 'GetModuleHandle'.
;                             8 = Failed to call 'GetProcAddress'.
;                             9 = Failed to call 'VirtualAllocEx'.
;                             10 = Failed to write the memory.
;                             11 = Failed to create the 'RemoteThread'.
; Author(s):        KillerDeluxe
;=================================================================================================

Func _InjectDll($ProcessId, $DllPath)
    If $ProcessId == 0 Then Return SetError(1, "", False)
    If Not(FileExists($DllPath)) Then Return SetError(2, "", False)
    If Not(StringRight($DllPath, 4) == ".dll") Then Return SetError(3, "", False)

    $Kernel32 = DllOpen("kernel32.dll")
    If @error Then Return SetError(4, "", False)

    $DLL_Path = DllStructCreate("char[255]")
    DllCall($Kernel32, "DWORD", "GetFullPathNameA", "str", $DllPath, "DWORD", 255, "ptr", DllStructGetPtr($DLL_Path), "int", 0)
    If @error Then Return SetError(5, "", False)

    $hProcess = DllCall($Kernel32, "DWORD", "OpenProcess", "DWORD", 0x1F0FFF, "int", 0, "DWORD", $ProcessId)
    If @error Then Return SetError(6, "", False)

    $hModule = DllCall($Kernel32, "DWORD", "GetModuleHandleA", "str", "kernel32.dll")
    If @error Then Return SetError(7, "", False)

    $lpStartAddress = DllCall($Kernel32, "DWORD", "GetProcAddress", "DWORD", $hModule[0], "str", "LoadLibraryA")
    If @error Then Return SetError(8, "", False)

    $lpParameter = DllCall($Kernel32, "DWORD", "VirtualAllocEx", "int", $hProcess[0], "int", 0, "ULONG_PTR", DllStructGetSize($DLL_Path), "DWORD", 0x3000, "int", 4)
    If @error Then Return SetError(9, "", False)

    DllCall("kernel32.dll", "BOOL", "WriteProcessMemory", "int", $hProcess[0], "DWORD", $lpParameter[0], "str", DllStructGetData($DLL_Path, 1), "ULONG_PTR", DllStructGetSize($DLL_Path), "int", 0)
    If @error Then Return SetError(10, "", False)

    $hThread = DllCall($Kernel32, "int", "CreateRemoteThread", "DWORD", $hProcess[0], "int", 0, "int", 0, "DWORD", $lpStartAddress[0], "DWORD", $lpParameter[0], "int", 0, "int", 0)
    If @error Then Return SetError(11, "", False)

    DllCall($Kernel32, "BOOL", "CloseHandle", "DWORD", $hProcess[0])
    DllClose($Kernel32)

    Return SetError(0, "", True)
EndFunc

 

Taki tam oryginał z autoitscript.com...

Opublikowano

Po co odświeżasz pracę którą ktoś zrobił, a ty sobie przywłaszczyłeś?

/ GA-970A-UD3 / FX-6300 / Sapphire Xtreme 5830 / OCZ ZS 550W / Brutus M23 /

| MPC Coders Team | MPC Gold Member | C#, C++, PHP, (N)ASM, AutoIT, Python, Java |

Zarchiwizowany

Ten temat przebywa obecnie w archiwum. Dodawanie nowych odpowiedzi zostało zablokowane.

×
×
  • Dodaj nową pozycję...