Function at 0x431f70
Capabilities:
Access peb ldr_data
Check for peb ntglobalflag flag

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
push 0xffffffffffffffff
push 0x4a43f0
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0x70
push ebx
push esi
push edi
lea ecx, [esp + 0x30]
call fcn.00488638
mov edi, dword [ebp + 8]
mov ecx, dword [edi + 4]
lea eax, [esp + 0x60]
push eax
push 0x18
xor esi, esi
push ecx
mov dword [esp + 0x90], esi
call dword [sym.imp.GDI32.dll_GetObjectW]
mov ebx, dword [sym.imp.GDI32.dll_CreateCompatibleDC]
push esi
call ebx
push eax
lea ecx, [esp + 0x34]
call fcn.00488b14
mov edi, dword [edi + 4]
mov edx, dword [esp + 0x34]
push edi
push edx
call fcn.00488e9a
lea ecx, [esp + 0x40]
mov dword [esp + 0x1c], eax
call fcn.00488638
mov dword [esp + 0x24], esi
mov dword [esp + 0x20], vtable.CBrush.0
mov dword [esp + 0x2c], esi
mov dword [esp + 0x28], vtable.CBitmap.0
push esi
mov byte [esp + 0x88], 3
call ebx
push eax
lea ecx, [esp + 0x44]
call fcn.00488b14
mov eax, dword [esp + 0x68]
mov ecx, dword [esp + 0x64]
mov edx, dword [esp + 0x34]
push eax
push ecx
push edx
call dword [sym.imp.GDI32.dll_CreateCompatibleBitmap]
push eax
lea ecx, [esp + 0x2c]
call fcn.00488e11
mov ebx, dword [sym.imp.USER32.dll_GetSysColor]
push 0xf
call ebx
push eax
call dword [sym.imp.GDI32.dll_CreateSolidBrush]
push eax
lea ecx, [esp + 0x24]
call fcn.00488e11
mov eax, dword [esp + 0x2c]
mov ecx, dword [esp + 0x44]
push eax
push ecx
call fcn.00488e9a
mov edx, dword [esp + 0x64]
mov ecx, dword [esp + 0x24]
mov edi, eax
mov eax, dword [esp + 0x68]
mov dword [esp + 0x58], edx
push ecx
lea edx, [esp + 0x54]
mov dword [esp + 0x60], eax
mov eax, dword [esp + 0x48]
push edx
push eax
mov dword [esp + 0x5c], esi
mov dword [esp + 0x60], esi
call dword [sym.imp.USER32.dll_FillRect]
push 1
push 1
mov ecx, dword [esp + 0x4c]
push ecx
call dword [sym.imp.GDI32.dll_GetPixel]
lea ecx, [esp + 0x20]
mov dword [esp + 0xc], eax
call fcn.00488e68
cmp edi, esi
jne 0x4320ae
xor edi, edi
jmp 0x4320b1
mov edi, dword [edi + 4]
mov edx, dword [esp + 0x44]
push edi
push edx
call fcn.00488e9a
push 0x10
call ebx
mov dword [esp + 0x18], eax
mov eax, dword [esp + 0x64]
xor edi, edi
cmp eax, esi
jle 0x432177
mov ebx, dword [sym.imp.GDI32.dll_SetPixel]
mov eax, dword [esp + 0x68]
lea esp, [esp]
test eax, eax
jle 0x432168
mov eax, dword [esp + 0x34]
push esi
push edi
push eax
call dword [sym.imp.GDI32.dll_GetPixel]
cmp eax, dword [esp + 0xc]
je 0x43214e
mov ecx, eax
shr ecx, 0x10
movzx ecx, cl
movzx edx, ah
add ecx, edx
movzx eax, al
add ecx, eax
mov eax, 0x55555556
imul ecx
mov ecx, edx
shr ecx, 0x1f
add edx, ecx
mov ecx, dword [esp + 0x18]
mov dword [esp + 0x10], edx
fild dword [esp + 0x10]
fmul qword [0x4ad218]
fstp qword [esp + 0x10]
mov edx, dword [esp + 0x14]
mov eax, dword [esp + 0x10]
push edx
push eax
push ecx
call fcn.00430410
mov edx, dword [esp + 0x40]
add esp, 0xc
push eax
push esi
push edi
push edx
jmp 0x43215d
mov eax, dword [ebp + 0xc]
test eax, eax
je 0x43215f
push eax
mov eax, dword [esp + 0x38]
push esi
push edi
push eax
call ebx
mov eax, dword [esp + 0x68]
inc esi
cmp esi, eax
jl 0x4320e8
mov ecx, dword [esp + 0x64]
inc edi
xor esi, esi
cmp edi, ecx
jl 0x4320e0
mov eax, dword [esp + 0x1c]
cmp eax, esi
je 0x432182
mov esi, dword [eax + 4]
mov ecx, dword [esp + 0x34]
push esi
push ecx
call fcn.00488e9a
mov esi, vtable.CGdiObject.0
lea ecx, [esp + 0x28]
mov byte [esp + 0x84], 2
mov dword [esp + 0x28], esi
call fcn.00488e68
lea ecx, [esp + 0x20]
mov byte [esp + 0x84], 1
mov dword [esp + 0x20], esi
call fcn.00488e68
lea ecx, [esp + 0x40]
mov byte [esp + 0x84], 0
call fcn.00488b92
lea ecx, [esp + 0x30]
mov dword [esp + 0x84], 0xffffffff
call fcn.00488b92
mov ecx, dword [esp + 0x7c]
pop edi
pop esi
mov dword fs:[0], ecx
pop ebx
mov esp, ebp
pop ebp
ret 8