textmode.cpp: patch 2nd IsSecureServerAllowed function

Improve patch for 1st IsSecureServerAllowed
This commit is contained in:
Unnamed 2019-03-22 14:57:43 +00:00 committed by TotallyNotElite
parent a1782629ac
commit c775a71a20

View File

@ -16,11 +16,14 @@ void EXPOSED_Epic_VACBypass_1337_DoNotSteal_xXx_$1_xXx_MLG()
((ICommandLine * (*) (void) ) dlsym(sharedobj::tier0().lmap, "CommandLine_Tier0"))()->RemoveParm("-textmode");
((ICommandLine * (*) (void) ) dlsym(sharedobj::tier0().lmap, "CommandLine_Tier0"))()->RemoveParm("-insecure");
uintptr_t Host_IsSecureServerAllowed_addr = gSignatures.GetEngineSignature("55 89 E5 83 EC ? E8 ? ? ? ? 8B 10 C7 44 24 ? ? ? ? ? 89 04 24 FF 52 ? 85 C0 74 ? C6 05");
uintptr_t Host_IsSecureServerAllowed2_addr = gSignatures.GetEngineSignature("55 89 E5 83 EC ? E8 ? ? ? ? 8B 10 C7 44 24 ? ? ? ? ? 89 04 24 FF 52 ? 85 C0 0F");
// +0x21 = allowSecureServers
// logging::Info("1337 VAC bypass: 0x%08x",
// Host_IsSecureServerAllowed_addr);
static BytePatch HostSecureServer(Host_IsSecureServerAllowed_addr, { 0x55, 0x89, 0xE5, 0x83, 0xEC, 0x18, 0xB8, 0x01, 0x00, 0x00, 0x00, 0xC9, 0xC3 });
static BytePatch HostSecureServer(Host_IsSecureServerAllowed_addr, {0x55, 0x89, 0xE5, 0x83, 0xEC, 0x18, 0x31, 0xC0, 0x40, 0xC9, 0xC3});
static BytePatch HostSecureServer2(Host_IsSecureServerAllowed2_addr, {0x31, 0xC0, 0x40, 0xC3});
HostSecureServer.Patch();
HostSecureServer2.Patch();
uintptr_t allowSecureServers_addr = Host_IsSecureServerAllowed_addr + 0x21;
allowSecureServers = *(bool **) (allowSecureServers_addr);