Results 1 to 6 of 6
  1. #1
    yewshyangying's Avatar
    Join Date
    Mar 2014
    Gender
    male
    Posts
    94
    Reputation
    10
    Thanks
    44
    My Mood
    Amazed

    Try to make own injector .

    Hey,i am trying to make my own injector, and i am complete my injector but when i test inject it wont. i don't know injector inject or not so i try to ask did anyone know how to put massage when it done inject?

    i will post the code please help me check.

    using System.Diagnostics;
    using System;
    using System.Windows.Forms;
    using System.Runtime.InteropServices;



    [DllImport("kernel32", ExactSpelling = true, CharSet = CharSet.Ansi, SetLastError = true)]
    public static extern int ReadProcessMemory(int hProcess, int lpBaseAddress, string lpBuffer, int nSize, ref int lpNumberOfBytesWritten);

    [DllImport("kernel32", EntryPoint = "LoadLibraryA", ExactSpelling = true, CharSet = CharSet.Ansi, SetLastError = true)]
    public static extern int LoadLibrary(string lpLibFileName);

    [DllImport("kernel32", ExactSpelling = true, CharSet = CharSet.Ansi, SetLastError = true)]
    public static extern int WriteProcessMemory(System.IntPtr hProcess, int lpBaseAddress, string lpBuffer, int nSize, int lpNumberOfBytesWritten);

    [DllImport("kernel32", ExactSpelling = true, CharSet = CharSet.Ansi, SetLastError = true)]
    public static extern int VirtualAllocEx(System.IntPtr hProcess, int lpAddress, int dwSize, int flAllocationType, int flProtect);

    [DllImport("kernel32", ExactSpelling = true, CharSet = CharSet.Ansi, SetLastError = true)]
    public static extern int GetProcAddress(int hModule, string lpProcName);

    [DllImport("kernel32", ExactSpelling = true, CharSet = CharSet.Ansi, SetLastError = true)]
    public static extern int CreateRemoteThread(System.IntPtr hProcess, int lpThreadAttributes, int dwStackSize, int lpStartAddress, int lpParameter, int dwCreationFlags, int lpThreadId);

    [DllImport("Kernel32", EntryPoint = "GetModuleHandleA", ExactSpelling = true, CharSet = CharSet.Ansi, SetLastError = true)]
    private static extern int GetModuleHandle(string lpModuleName);

    [DllImport("kernel32.dll")]
    public static extern IntPtr OpenProcess(int dwDesiredAccess, bool bInheritHandle, int dwProcessId);

    [DllImport("kernel32", EntryPoint = "CloseHandle")]
    private static extern int CloseHandle(System.IntPtr hObject);

    [DllImport("user32", EntryPoint = "FindWindowA", ExactSpelling = true, CharSet = CharSet.Ansi, SetLastError = true)]
    private static extern int FindWindow(string lpClassName, string lpWindowName);

    void Inject()
    {
    System.IntPtr TargetProcessHandle;
    int TargetBufferSize;
    String pszLibFileRemote;
    int pfnStartAddr;
    Process[] TargetProcess = Process.GetProcessesByName("BlackShot");
    TargetProcessHandle = OpenProcess(0x1F0FFF, false, TargetProcess[0].Id);
    pszLibFileRemote = Application.StartupPath + ("\\SILK.dll");
    pfnStartAddr = GetProcAddress(GetModuleHandle("Kernel32.dll"), "LoadLibraryA");
    TargetBufferSize = 1 + pszLibFileRemote.Length;
    int Rtn;
    int LoadLibParamAdr;
    LoadLibParamAdr = VirtualAllocEx(TargetProcessHandle, 0, TargetBufferSize, 4096, 4);
    Rtn = WriteProcessMemory(TargetProcessHandle, LoadLibParamAdr, pszLibFileRemote, TargetBufferSize, 0);
    CreateRemoteThread(TargetProcessHandle, 0, 0, pfnStartAddr, LoadLibParamAdr, 0, 0);
    CloseHandle(TargetProcessHandle);
    }

    private void timer1_Tick(object sender, EventArgs e)
    {
    Process[] TargetProcess = Process.GetProcessesByName("BlackShot");
    if (TargetProcess.Length == 0)
    { }
    else
    {
    Inject();
    timer1.Stop();
    this.Close();
    }
    }

    this code was search on >> https://www.mpgh.net/forum/showthread.php?t=1151586

    - - - Updated - - -

    sorry for my bad english
    Subscribe To My Youtube :Click On Me !

    ---------------------------------------------------------------------------------------------------------------------------------------------------------------------



  2. #2
    RuShi's Avatar
    Join Date
    Jan 2016
    Gender
    male
    Location
    File Not Found 404!
    Posts
    2,531
    Reputation
    210
    Thanks
    13,008
    My Mood
    Innocent
    Inject any DLL with MsgBox. If MsgBox pop out after Injection means your Injector is complete.


    MPGH History:
    Member: 02/1/2016
    Contributor: 29/6/2016
    Minion: 25/8/2016
    Former Staff: 07/02/2017
    Minion: 21/9/2017

  3. #3
    yewshyangying's Avatar
    Join Date
    Mar 2014
    Gender
    male
    Posts
    94
    Reputation
    10
    Thanks
    44
    My Mood
    Amazed
    Quote Originally Posted by Luffy View Post
    Inject any DLL with MsgBox. If MsgBox pop out after Injection means your Injector is complete.
    I test the injector now i know what problem on my injector! i think my injector wasn't target BS.i open like 10 time still not inject do you know how to fix it?
    Subscribe To My Youtube :Click On Me !

    ---------------------------------------------------------------------------------------------------------------------------------------------------------------------



  4. #4
    MafiaBoy BlackShit's Avatar
    Join Date
    Jun 2016
    Gender
    male
    Location
    Secret
    Posts
    629
    Reputation
    10
    Thanks
    2,433
    My Mood
    Amazed
    pszLibFileRemote = Application.StartupPath + ("\\SILK.dll");
    The DLL must be name SILK.dll - Because the injector only inject SILK.dll -
    And I Think this injector only work for Windows 8 and 10
    Run as Administrator and Try again
    We're Anonymous
    We're Hacker, We're Not Going To Stop!
    Bcaus We're Hacker!

    AOA Music

  5. #5
    yewshyangying's Avatar
    Join Date
    Mar 2014
    Gender
    male
    Posts
    94
    Reputation
    10
    Thanks
    44
    My Mood
    Amazed
    Quote Originally Posted by MafiaBoy BlackShit View Post
    The DLL must be name SILK.dll - Because the injector only inject SILK.dll -
    And I Think this injector only work for Windows 8 and 10
    Run as Administrator and Try again
    oh ok thanks you! i will try
    Subscribe To My Youtube :Click On Me !

    ---------------------------------------------------------------------------------------------------------------------------------------------------------------------



  6. #6
    RuShi's Avatar
    Join Date
    Jan 2016
    Gender
    male
    Location
    File Not Found 404!
    Posts
    2,531
    Reputation
    210
    Thanks
    13,008
    My Mood
    Innocent
    The problem has been solved by MafiaBoy BlackShit.

    /Closed.


    MPGH History:
    Member: 02/1/2016
    Contributor: 29/6/2016
    Minion: 25/8/2016
    Former Staff: 07/02/2017
    Minion: 21/9/2017

Similar Threads

  1. [Help] Trying to make own hack
    By Captain_Vonno in forum Garry's Mod Discussions & Help
    Replies: 2
    Last Post: 01-07-2015, 11:12 AM
  2. [Release] How to make own injector !
    By tmadmin01 in forum C# Programming
    Replies: 6
    Last Post: 05-10-2013, 06:29 AM
  3. [Tutorial] Make own injector - click here
    By danialterbaik in forum Blackshot Hacks & Cheats
    Replies: 9
    Last Post: 12-31-2012, 05:47 PM
  4. [Help] Trying to make an Injector
    By ipwno0bs1 in forum Visual Basic Programming
    Replies: 3
    Last Post: 06-25-2011, 01:36 AM
  5. Custom sounds. Trying to make my own
    By willieG in forum Call of Duty Modern Warfare 2 Help
    Replies: 1
    Last Post: 07-12-2010, 08:03 AM