Skip to content

Commit

Permalink
Added Win7, Win8, Win8.1, Win10 1507 - 21H1 and Win11 21H2 support, m…
Browse files Browse the repository at this point in the history
…any bug fixes and reworks
  • Loading branch information
Broihon committed Aug 8, 2021
1 parent d8f3220 commit d9a8a19
Show file tree
Hide file tree
Showing 38 changed files with 4,456 additions and 1,809 deletions.
6 changes: 3 additions & 3 deletions GH Injector Library/Download Manager.h
Original file line number Diff line number Diff line change
Expand Up @@ -20,9 +20,9 @@ class DownloadManager : public IBindStatusCallback

HRESULT __stdcall QueryInterface(const IID & riid, void ** ppvObject);

ULONG STDMETHODCALLTYPE AddRef(void);
ULONG STDMETHODCALLTYPE AddRef();

ULONG STDMETHODCALLTYPE Release(void);
ULONG STDMETHODCALLTYPE Release();

virtual HRESULT STDMETHODCALLTYPE OnStartBinding(DWORD dwReserved, IBinding * pib);

Expand All @@ -32,7 +32,7 @@ class DownloadManager : public IBindStatusCallback

virtual HRESULT STDMETHODCALLTYPE OnStopBinding(HRESULT hresult, LPCWSTR szError);

virtual HRESULT STDMETHODCALLTYPE GetBindInfo(DWORD * grfBINDF, BINDINFO *pbindinfo);
virtual HRESULT STDMETHODCALLTYPE GetBindInfo(DWORD * grfBINDF, BINDINFO * pbindinfo);

virtual HRESULT STDMETHODCALLTYPE OnDataAvailable(DWORD grfBSCF, DWORD dwSize, FORMATETC * pformatetc, STGMEDIUM * pstgmed);

Expand Down
9 changes: 8 additions & 1 deletion GH Injector Library/Error.h
Original file line number Diff line number Diff line change
Expand Up @@ -77,6 +77,13 @@
#define INJ_ERR_WCSRCHR_FAILED 0x00000038 //wcsrchr : - : wcsrchr failed to find a character in a string (usually '\\' in a path)
#define INJ_ERR_TARGET_EXE_NAME_IS_NULL 0x00000039 //internal error : - : the length of the name of the specified process is 0
#define INJ_ERR_LDR_ENTRY_IS_NULL 0x0000003A //internal error : - : LdrpLoadDll(Internal) didn't return a valid LDR_DATA_TABLE_ENTRY pointer
#define INJ_ERR_NOT_SUPPORTED 0x0000003B //internal error : - : the requested operation is not supported on the current operating system
#define INJ_ERR_CREATE_EVENT_FAILED 0x0000003C //CreateEventEx : win32 error : failed to create an event for wow64 process
#define INJ_ERR_CREATE_PROCESS_FAILED 0x0000003D //CreateProcessW : win32 error : failed to create process for wow64 module addresses
#define INJ_ERR_WAIT_FAILED 0x0000003E //WaitForSingleObject : win32 error : failed to wait for an event to trigger
#define INJ_ERR_WAIT_TIMEOUT 0x0000003F //WaitForSingleObject : - : event timed out
#define INJ_ERR_WINDOWS_VERSION 0x00000040 //internal error : - : failed to resolve the version number of the operating system
#define INJ_ERR_WINDOWS_TOO_OLD 0x00000041 //internal error : - : the injection library only runs on Windows 7 or higher


///////////////////
Expand Down Expand Up @@ -298,7 +305,7 @@
#define SYMBOL_CANT_OPEN_PROCESS 0x40000014 //OpenProcess : can't get PROCESS_QUERY_LIMITED_INFORMATION handle to current process
#define SYMBOL_ERR_COPYFILE_FAILED 0x40000015 //CopyFileA : copying the file from the cache directory failed
#define SYMBOL_ERR_INTERRUPT 0x40000016 //internal error : download has been interrupted

#define SYMBOL_ERR_CANNOT_CONNECT 0x40000017 //InternetCheckConnectionW : GetLastError returned ERROR_INTERNET_CANNOT_CONNECT which might be caused by a firewall rule


/// ///////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
Expand Down
12 changes: 10 additions & 2 deletions GH Injector Library/GH Injector Library.vcxproj
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@
<VCProjectVersion>15.0</VCProjectVersion>
<ProjectGuid>{AC732425-E265-40FF-842F-C59CECE9A96C}</ProjectGuid>
<RootNamespace>GHInjectorLibrary</RootNamespace>
<WindowsTargetPlatformVersion>10.0.19041.0</WindowsTargetPlatformVersion>
<WindowsTargetPlatformVersion>10.0.22000.0</WindowsTargetPlatformVersion>
</PropertyGroup>
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" />
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="Configuration">
Expand Down Expand Up @@ -174,13 +174,20 @@
<ClInclude Include="Injection Internal.h" />
<ClInclude Include="Injection.h" />
<ClInclude Include="Manual Mapping.h" />
<ClInclude Include="NT Stuff.h" />
<ClInclude Include="NT Defs.h" />
<ClInclude Include="NT Funcs.h" />
<ClInclude Include="pch.h" />
<ClInclude Include="Process Info.h" />
<ClInclude Include="resource.h" />
<ClInclude Include="Start Routine.h" />
<ClInclude Include="Symbol Parser.h" />
<ClInclude Include="Tools.h" />
<ClInclude Include="VEH Shell.h" />
<ClInclude Include="Win10.h" />
<ClInclude Include="Win11.h" />
<ClInclude Include="Win7.h" />
<ClInclude Include="Win8.h" />
<ClInclude Include="Win81.h" />
<ClInclude Include="WOW64 Shells.h" />
</ItemGroup>
<ItemGroup>
Expand Down Expand Up @@ -222,6 +229,7 @@
<ClCompile Include="Thread Hijacking WOW64.cpp" />
<ClCompile Include="Thread Hijacking.cpp" />
<ClCompile Include="Tools.cpp" />
<ClCompile Include="VEH Shell.cpp" />
</ItemGroup>
<ItemGroup>
<ResourceCompile Include="GH Injector Library.rc" />
Expand Down
33 changes: 30 additions & 3 deletions GH Injector Library/GH Injector Library.vcxproj.filters
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,9 @@
<Filter Include="Headerdateien\Injection Methods">
<UniqueIdentifier>{d3c5e067-fa7b-4ff9-9579-418c449c7978}</UniqueIdentifier>
</Filter>
<Filter Include="Headerdateien\NT">
<UniqueIdentifier>{844b590b-6d34-422e-8d4f-d27e3e5defb5}</UniqueIdentifier>
</Filter>
</ItemGroup>
<ItemGroup>
<ClInclude Include="Handle Hijacking.h">
Expand All @@ -45,9 +48,6 @@
<ClInclude Include="Injection.h">
<Filter>Headerdateien</Filter>
</ClInclude>
<ClInclude Include="NT Stuff.h">
<Filter>Headerdateien</Filter>
</ClInclude>
<ClInclude Include="Process Info.h">
<Filter>Headerdateien</Filter>
</ClInclude>
Expand Down Expand Up @@ -87,6 +87,30 @@
<ClInclude Include="resource.h">
<Filter>Headerdateien</Filter>
</ClInclude>
<ClInclude Include="NT Funcs.h">
<Filter>Headerdateien\NT</Filter>
</ClInclude>
<ClInclude Include="Win7.h">
<Filter>Headerdateien\NT</Filter>
</ClInclude>
<ClInclude Include="Win8.h">
<Filter>Headerdateien\NT</Filter>
</ClInclude>
<ClInclude Include="Win81.h">
<Filter>Headerdateien\NT</Filter>
</ClInclude>
<ClInclude Include="Win10.h">
<Filter>Headerdateien\NT</Filter>
</ClInclude>
<ClInclude Include="NT Defs.h">
<Filter>Headerdateien\NT</Filter>
</ClInclude>
<ClInclude Include="Win11.h">
<Filter>Headerdateien\NT</Filter>
</ClInclude>
<ClInclude Include="VEH Shell.h">
<Filter>Headerdateien\Injection Methods</Filter>
</ClInclude>
</ItemGroup>
<ItemGroup>
<ClCompile Include="Handle Hijacking.cpp">
Expand Down Expand Up @@ -176,6 +200,9 @@
<ClCompile Include="KernelCallback WOW64.cpp">
<Filter>Quelldateien\wow64\Start Routine Methods</Filter>
</ClCompile>
<ClCompile Include="VEH Shell.cpp">
<Filter>Quelldateien\native\Injection Methods</Filter>
</ClCompile>
</ItemGroup>
<ItemGroup>
<ResourceCompile Include="GH Injector Library.rc">
Expand Down
Loading

0 comments on commit d9a8a19

Please sign in to comment.