Ejemplo n.º 1
0
DWORD __stdcall FindPattern(unsigned char* lpData, unsigned int nDataSize, const unsigned char* lpPattern, const char* pszMask) 
{ 
    for (unsigned int x = 0; x < nDataSize; x++) 
	{
		if (MaskCompare(lpData + x, lpPattern, pszMask)) 
		{
			return (DWORD)(lpData + x); 
		}
	}
    return 0; 
}
Ejemplo n.º 2
0
INT32 __stdcall FindPattern(PatternParas * paras)
{
	for (INT32 x = paras->startIndex; x < paras->stopIndex; x++)
	{
		if (MaskCompare( reinterpret_cast< unsigned char* >( (INT32)modinfo.lpBaseOfDll + x ), paras->lpPattern, paras->pszMask ))
		{
			retData[paras->sigNumber] = ( x );
			return 0;
		}
	}
	return 0;
}