Join Date: Nov 2011
Posts: 65
|
mhm...kann immer noch nichts finden (?)
CPP Code: #include "windows.h" #include "stdio.h"; void InjMessage(LPCWSTR Text, LPCWSTR Header) { MessageBox(NULL, Text, Header, MB_OK); } bool bDataCompare(const BYTE* pData, const BYTE* bMask, const char* szMask) { for(;*szMask;++szMask,++pData,++bMask) { if(*szMask=='x' && *pData!=*bMask ) { return false; } } return (*szMask) == NULL; } DWORD FindPattern(DWORD dwAddress, DWORD dwLen, BYTE *bMask,char * szMask) { for(DWORD i=0; i < dwLen; i++) { if(bDataCompare( (BYTE*)( dwAddress+i ),bMask,szMask)) { return (DWORD)(dwAddress+i); } } return 0; } DWORD WINAPI StartSearching() { HMODULE StartAdresse; int Size; DWORD Adress; StartAdresse = GetModuleHandle(NULL); Size = 999999; Adress = FindPattern((DWORD) StartAdresse, (DWORD) Size, (PBYTE) "\x8B\xCE\x90\x90\x90\xE8\x00\x00\x00\x00\x8B\x4C\x24\x00\x8B\xB1\x00\x00\x00\x00\x83\xFE\x00\x0F\x84\x00\x00\x00\x00\x8B\xB1", "xxxxxx????xxx?xx????xxxxx????xx"); Adress += 21; WCHAR cResult[10]; swprintf_s(cResult, 10, L"%X", Adress); InjMessage(cResult,L"Adresse"); return 0; } bool WINAPI DllMain(HINSTANCE hInst, DWORD reason,LPVOID reserved) { if(reason==DLL_PROCESS_ATTACH) { CreateThread(0, 0, (LPTHREAD_START_ROUTINE) StartSearching, 0, 0, 0); } return true; }
|