Added a more complex VMProtect Ultra test.

This commit is contained in:
Can Bölük 2020-06-13 02:52:00 +02:00
parent 1773dcd7b0
commit fd8f294be2
2 changed files with 33 additions and 0 deletions

View file

@ -0,0 +1,33 @@
#pragma pack(push, 1)
struct much_complex_object
{
uint32_t a;
uint8_t b;
uint8_t c;
uint16_t d;
__declspec( noinline ) int32_t wow()
{
return c * b + a;
}
};
#pragma pack(pop)
__declspec( dllexport, noinline ) uint64_t test_entry_point( uint64_t r )
{
much_complex_object wow = {
r & 0xFF00FF00,
(r >> 16) % 0xA3,
r & 0x000000FF,
uint16_t( r * r )
};
volatile int lol = wow.wow();
if ( printf( "{%d}!\n", lol ) && lol < 5 )
return wow.a & ~lol + 0x3545fa1;
for ( int i = 0; i < 4; i++ )
lol = ( ( lol ^ i ) * 0x100003B );
return lol;
}

Binary file not shown.