Function at 0x408870
Capabilities:
Get file size
Read file on windows

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x456608
push 0x44bffc
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0x50
push ebx
push esi
push edi
mov dword [ebp - 0x18], esp
xor eax, eax
mov dword [ebp - 0x5c], eax
mov dword [ebp - 0x34], eax
mov dword [ebp - 0x3c], eax
mov dword [ebp - 0x44], eax
mov dword [ebp - 4], eax
push 0x104
call fcn.0044c0d4
mov ebx, eax
mov dword [ebp - 0x3c], ebx
push 0x104
call fcn.0044c0d4
add esp, 8
mov dword [ebp - 0x44], eax
push ebx
mov eax, dword [ebp + 0xc]
push eax
push 0x189
mov esi, dword [ebp + 8]
push esi
mov edi, dword [sym.imp.USER32.dll_SendMessageA]
call edi
push 0
mov ecx, dword [ebp + 0xc]
push ecx
push 0x199
push esi
call edi
shr eax, 0x10
and eax, 0x1f
mov dword [ebp - 0x50], eax
push 0
push 1
push 3
push 1
push 0x80000000
push ebx
call fcn.0044a650
mov ebx, eax
mov dword [ebp - 0x58], ebx
cmp ebx, 0xffffffff
jne 0x408922
push 0x30
push 0x26
mov edx, dword [ebp - 0x3c]
push edx
call fcn.00448b60
jmp 0x408b00
push 0
push ebx
call dword [sym.imp.KERNEL32.dll_GetFileSize]
mov dword [ebp - 0x48], eax
cmp eax, 0x17a
jae 0x40894e
push 0x30
push 0x26
mov eax, dword [ebp - 0x3c]
push eax
call fcn.00448b60
push ebx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
jmp 0x408b00
push eax
call fcn.0044c0d4
add esp, 4
mov dword [ebp - 0x34], eax
push 0
lea ecx, [ebp - 0x5c]
push ecx
mov edx, dword [ebp - 0x48]
push edx
push eax
push ebx
call dword [sym.imp.KERNEL32.dll_ReadFile]
push ebx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov ebx, dword [ebp - 0x34]
mov dword [ebp - 0x1c], ebx
add ebx, 0x155
mov dword [ebp - 0x40], ebx
push 0
mov eax, dword [ebp + 0xc]
push eax
push 0x199
push esi
call edi
mov dword [ebp - 0x48], eax
and eax, 0xffe5ffff
or eax, 0x50000
mov dword [ebp - 0x48], eax
push eax
mov ecx, dword [ebp + 0xc]
push ecx
push 0x19a
push esi
call edi
mov edx, dword [ebp + 0xc]
mov dword [ebp - 0x4c], edx
mov dword [ebp - 0x5c], 0
mov eax, dword [ebp - 0x1c]
mov ecx, dword [ebp - 0x5c]
cmp ecx, dword [eax + 4]
jae 0x408a6b
inc dword [ebp - 0x4c]
mov dword [ebp - 0x48], 0
push 3
mov dl, byte [ebx + 0x24]
push edx
mov eax, dword [ebx + 0x20]
push eax
call fcn.00432f00
mov ecx, eax
mov dword [ebp - 0x38], ecx
test ecx, ecx
jne 0x4089f9
mov dword [ebp - 0x48], 0x4000000
mov eax, 0x400ffff
jmp 0x4089fe
xor eax, eax
mov ax, word [ecx]
mov dword [ebp - 0x48], eax
mov cl, byte [ebx + 0x24]
test cl, 0x10
je 0x408a15
and eax, 0xffe2ffff
or eax, 0x20000
jmp 0x408a30
test cl, 0x40
je 0x408a26
and eax, 0xffe3ffff
or eax, 0x30000
jmp 0x408a30
and eax, 0xffe1ffff
or eax, 0x10000
mov dword [ebp - 0x48], eax
and eax, 0xff3fffff
or eax, 0x200000
mov dword [ebp - 0x48], eax
push ebx
mov ecx, dword [ebp - 0x4c]
push ecx
push 0x181
push esi
call edi
mov edx, dword [ebp - 0x48]
push edx
mov eax, dword [ebp - 0x4c]
push eax
push 0x19a
push esi
call edi
add ebx, 0x25
mov dword [ebp - 0x40], ebx
inc dword [ebp - 0x5c]
jmp 0x4089ba
mov ecx, dword [eax + 4]
mov dword [ebp - 0x5c], ecx
lea edx, [ebp - 0x30]
push edx
push esi
call dword [sym.imp.USER32.dll_GetClientRect]
push 0
push 0
push 0x18e
push esi
call edi
mov ebx, eax
mov dword [ebp - 0x54], ebx
push 0
push ebx
push 0x1a1
push esi
call edi
mov ecx, eax
mov eax, dword [ebp - 0x24]
sub eax, dword [ebp - 0x2c]
cdq
idiv ecx
mov dword [ebp - 0x20], eax
lea edx, [eax + ebx - 1]
mov ecx, dword [ebp + 0xc]
mov ebx, dword [ebp - 0x5c]
add ebx, ecx
cmp edx, ebx
jae 0x408ad6
mov edx, dword [ebp - 0x5c]
sub edx, eax
lea eax, [edx + ecx + 1]
mov dword [ebp - 0x54], eax
cmp eax, ecx
jbe 0x408acb
mov eax, ecx
mov dword [ebp - 0x54], eax
push 0
push eax
push 0x197
push esi
call edi
cmp esi, dword [0x4773dc]
jne 0x408b00
call fcn.0040be90
jmp 0x408b00
mov dword [ebp - 4], 0xffffffff
mov eax, dword [ebp - 0x34]
test eax, eax
je 0x408b17
push eax
call fcn.0044c186
add esp, 4
mov eax, dword [ebp - 0x3c]
test eax, eax
je 0x408b27
push eax
call fcn.0044c186
add esp, 4
mov eax, dword [ebp - 0x44]
test eax, eax
je 0x408b37
push eax
call fcn.0044c186
add esp, 4
mov eax, dword [ebp - 0x5c]
mov ecx, dword [ebp - 0x10]
mov dword fs:[0], ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 8