Function at 0x4e79c0
Capabilities:
Read file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x40
mov dword [ebp - 0x40], ecx
mov eax, dword [ebp - 0x40]
cmp dword [eax + 8], 0
je 0x4e79d7
jmp 0x4e7c12
mov ecx, dword [ebp - 0x40]
movzx edx, byte [ecx + 0x17]
cmp edx, 1
jne 0x4e7a40
mov eax, dword [ebp - 0x40]
cmp dword [eax + 4], 0xffff
jae 0x4e7a1b
push 0x2000
push 0
push 0
push 0
mov ecx, dword [ebp - 0x40]
movzx edx, word [ecx + 4]
push edx
mov ecx, 0x5f1980
call fcn.004296a0
push eax
call dword [sym.imp.USER32.dll_LoadImageW]
mov ecx, dword [ebp - 0x40]
mov dword [ecx + 8], eax
jmp 0x4e7a3b
push 0x2010
push 0
push 0
push 0
mov edx, dword [ebp - 0x40]
mov eax, dword [edx + 4]
push eax
push 0
call dword [sym.imp.USER32.dll_LoadImageW]
mov ecx, dword [ebp - 0x40]
mov dword [ecx + 8], eax
jmp 0x4e7b8d
mov edx, dword [ebp - 0x40]
cmp dword [edx + 4], 0xffff
jae 0x4e7aba
lea ecx, [ebp - 8]
call fcn.004e7c40
mov eax, dword [ebp - 0x40]
movzx ecx, byte [eax + 0x17]
cmp ecx, 2
jne 0x4e7aad
push ecx
mov ecx, esp
mov edx, dword [ebp - 0x40]
mov eax, dword [edx + 4]
push eax
call fcn.004e7c20
push ecx
mov ecx, esp
push 0x5b131c
call fcn.004e6ac0
lea ecx, [ebp - 8]
call fcn.004e7c90
movzx ecx, al
test ecx, ecx
je 0x4e7aad
push 1
lea ecx, [ebp - 8]
call fcn.004e7d00
push eax
lea ecx, [ebp - 8]
call fcn.004e7d20
push eax
call fcn.004e7d80
add esp, 0xc
mov edx, dword [ebp - 0x40]
mov dword [edx + 8], eax
lea ecx, [ebp - 8]
call fcn.004e7c70
jmp 0x4e7b8d
mov dword [ebp - 0xc], 0
push 0x5b1314
mov eax, dword [ebp - 0x40]
mov ecx, dword [eax + 4]
push ecx
lea edx, [ebp - 0xc]
push edx
call fcn.00562b47
add esp, 0xc
test eax, eax
jne 0x4e7b8d
cmp dword [ebp - 0xc], 0
je 0x4e7b8d
push 2
push 0
mov eax, dword [ebp - 0xc]
push eax
call fcn.005629e5
add esp, 0xc
mov ecx, dword [ebp - 0xc]
push ecx
call fcn.005628ed
add esp, 4
mov dword [ebp - 0x14], eax
push 0
push 0
mov edx, dword [ebp - 0xc]
push edx
call fcn.005629e5
add esp, 0xc
mov eax, dword [ebp - 0x14]
push eax
call fcn.0055d3e0
add esp, 4
mov dword [ebp - 0x38], eax
mov ecx, dword [ebp - 0x38]
mov dword [ebp - 0x10], ecx
cmp dword [ebp - 0x10], 0
je 0x4e7b81
mov edx, dword [ebp - 0xc]
push edx
mov eax, dword [ebp - 0x14]
push eax
push 1
mov ecx, dword [ebp - 0x10]
push ecx
call fcn.005625a0
add esp, 0x10
mov edx, dword [ebp - 0x40]
movzx eax, byte [edx + 0x17]
cmp eax, 2
jne 0x4e7b6f
push 1
mov ecx, dword [ebp - 0x14]
push ecx
mov edx, dword [ebp - 0x10]
push edx
call fcn.004e7d80
add esp, 0xc
mov ecx, dword [ebp - 0x40]
mov dword [ecx + 8], eax
mov edx, dword [ebp - 0x10]
mov dword [ebp - 0x3c], edx
mov eax, dword [ebp - 0x3c]
push eax
call fcn.0055e5cc
add esp, 4
mov ecx, dword [ebp - 0xc]
push ecx
call fcn.005621d9
add esp, 4
mov edx, dword [ebp - 0x40]
cmp dword [edx + 8], 0
jne 0x4e7bbc
xor eax, eax
mov ecx, dword [ebp - 0x40]
mov word [ecx + 0x14], ax
mov edx, dword [ebp - 0x40]
mov dword [edx + 0xc], 0
mov eax, dword [ebp - 0x40]
mov dword [eax + 0x10], 0
mov ecx, dword [ebp - 0x40]
mov byte [ecx + 0x16], 0
jmp 0x4e7c12
lea edx, [ebp - 0x2c]
push edx
push 0x18
mov eax, dword [ebp - 0x40]
mov ecx, dword [eax + 8]
push ecx
call dword [sym.imp.GDI32.dll_GetObjectW]
mov edx, dword [ebp - 0x40]
movzx eax, word [edx + 0x14]
test eax, eax
je 0x4e7bef
mov ecx, dword [ebp - 0x40]
movzx ecx, word [ecx + 0x14]
mov eax, dword [ebp - 0x28]
cdq
idiv ecx
mov edx, dword [ebp - 0x40]
mov dword [edx + 0xc], eax
jmp 0x4e7bf9
mov eax, dword [ebp - 0x40]
mov dword [eax + 0xc], 0
mov ecx, dword [ebp - 0x40]
mov edx, dword [ebp - 0x24]
mov dword [ecx + 0x10], edx
movzx eax, word [ebp - 0x1a]
cmp eax, 0x20
sete cl
mov edx, dword [ebp - 0x40]
mov byte [edx + 0x16], cl
mov esp, ebp
pop ebp
ret