vprotect patch机器码如何打补丁??
遇到一个软件vprotect加壳验证,已经替换机器码,但是不知如何用大白打补丁,求解?以下是步骤:载入程序,首先查询机器码存放点位置,然后重新载入程序bp VirtualAlloc下断点,运行软件
断在断点处继续运行,直到右下角堆栈窗口出现机器码所在内存大小,单步运行一次解码,然后找到刚才查找到内存地址
下内存写入断点,继续运行,知道机器码都出来,
然后替换即可
现在在od已经破解替换机器码了,请教大神们,如何才能用大白给这个软件打补丁,求解。
注:软件地址https://fuwei.lanzouy.com/iUAJZyj2m4b
压缩包内有能用的机器码和KEY,我用的是虚拟机(请把虚拟机时间调至2018年12月29日)替换的机器码
按你这描述,自己写个dll会很好解决 机器码地址变来变去,没法补丁 谢谢分享,支持 飘云 发表于 2022-1-23 15:39
按你这描述,自己写个dll会很好解决
这个不会啊
劫持搞不了
HANDLE g_handle = GetCurrentProcess();
//HANDLE hModule2 = OpenProcess(PROCESS_ALL_ACCESS, FALSE, GetCurrentProcessId());
//
//LPVOID Pointer_GetVaService = (void*)GetProcAddress(GetModuleHandle(TEXT("卡7复制数据导出V1.11P.exe"), "EntryPoint");
//LPVOIDag_handle = (byte*)Pointer_GetVaService + 0x30E3A;
DWORD dwBaseAddr, JmpRet;
BYTE data = {
0x36, 0x32, 0x39, 0x36, 0x34, 0x32, 0x30, 0x36, 0x41, 0x41, 0x46, 0x42, 0x43, 0x43, 0x45, 0x41,
0x41, 0x30, 0x36, 0x41, 0x41, 0x42, 0x45, 0x39, 0x46, 0x34, 0x34, 0x37, 0x32, 0x31, 0x45, 0x33
};
BYTE data2 = {0xE8, 0x00, 0x00, 0x00, 0x00};//原始字节,还原Hook用
BOOL WriteMem(LPVOID addr, LPVOID data, DWORD lenth)
{
DWORD old;
VirtualProtectEx(g_handle, addr, 1024, 64, &old);
BOOL result = WriteProcessMemory(g_handle, addr, data, lenth, 0);
VirtualProtectEx(g_handle, addr, 1024, (DWORD)old, &old);
return result;
}
void inlineHook(void* MyBase, void* My_code)
{
DWORD old;
VirtualProtectEx(g_handle, MyBase, 10, 64, &old);
UCHAR Mycode = { 0xE9 };
*(INT*)(Mycode + 0x1) = (INT)My_code - (INT)MyBase - 0x5;
WriteProcessMemory(g_handle, MyBase, Mycode, 0x5, NULL);
VirtualProtectEx(g_handle, MyBase, 10, (DWORD)old, &old);
}
void wMacp() {
WriteMem((void*)(dwBaseAddr + 0x1CF68), data, 33);
WriteMem((void*)0x007F123A, data2, 6);//还原Hook
}
void _declspec(naked) Vp_GetBase() {
__asm {
push eax
mov eax, DWORD PTR SS :
mov dwBaseAddr, eax
pop eax
pushad
call wMacp
popad
mov esp, ebp
pop ebp
ret 4
}
} BPsend 发表于 2022-2-19 15:04
HANDLE g_handle = GetCurrentProcess();
//HANDLE hModule2 = OpenProcess(PROCESS_ ...
我的哥,这个不会用呀
获取模块地址加偏移就可以得到不变地址,然后判断指针数据啥时候出现,可以用
do
{
VirtualProtect((LPVOID)Jmp_Pointer, sizeof(&Jmp_Pointer), PAGE_EXECUTE_READWRITE, &dwOldProtect);
if (*(byte*)Jmp_Pointer = 0x85)
{
RtlCopyMemory(&DataJudgment, LPVOID(Jmp_Pointer), sizeof(DataJudgment));//复制0x84进行判断
}
} while (DataJudgment == 0x84);
难后执行补丁就行了
页:
[1]