Function at 0x43f150
Capabilities:
Read file on windows

Disassembly:
sub esp, 0x20
push ebx
mov ebx, dword [esp + 0x28]
push ebp
mov ebp, dword [0x4f0b10]
push esi
mov esi, ecx
push edi
mov ecx, ebp
mov dword [esp + 0x18], ebp
call fcn.0041a480
or eax, 0xffffffff
mov dword [esp + 0x28], eax
mov dword [esp + 0x2c], eax
mov eax, dword [0x4ec48c]
mov eax, dword [eax + 0xdc]
and eax, 0x7fffffff
mov byte [esp + 0x16], 0
mov byte [esp + 0x20], 0
mov dword [esp + 0x24], eax
mov eax, esi
lea esp, [esp]
mov cl, byte [eax]
cmp cl, 0x20
je 0x43f1ac
cmp cl, 9
jne 0x43f1af
inc eax
jmp 0x43f1a0
cmp byte [eax], 0x2a
jne 0x43f28a
movzx edi, byte [eax + 1]
lea esi, [eax + 1]
test edi, 0xffffff80
jne 0x43f1d9
push 2
push edi
call fcn.004bb66e
add esp, 8
test eax, eax
je 0x43f1d9
and edi, 0xffffffdf
mov eax, edi
movsx eax, al
add eax, 0xffffffbd
cmp eax, 0x11
ja case.0x43f1f1.68
movzx ecx, byte [eax + 0x43f6f4]
jmp dword [ecx*4 + 0x43f6e0]
mov byte [esp + 0x20], 1
jmp case.0x43f1f1.68
lea edi, [esi + 1]
mov eax, edi
call fcn.0040dd50
movzx edx, al
neg edx
sbb edx, edx
and edx, 6
add edx, 0xa
push edx
push 0
push edi
call fcn.004bc2a6
mov dword [esp + 0x34], eax
add esp, 0xc
mov edi, 0x4d9558
mov eax, esi
mov dword [esp + 0x2c], edx
call fcn.004099e0
mov esi, eax
test esi, esi
je 0x43f657
dec esi
jmp case.0x43f1f1.68
lea eax, [esi + 1]
push eax
call fcn.004bb6b6
mov dword [esp + 0x28], eax
add esp, 4
mov edi, 0x4d9558
mov eax, esi
call fcn.004099e0
mov esi, eax
test esi, esi
je 0x43f68c
dec esi
jmp case.0x43f1f1.68
mov byte [esp + 0x16], 1
cmp byte [esi], 0
je 0x43f197
inc esi
cmp byte [esi], 0
je 0x43f197
inc esi
jmp 0x43f197
push 0
push 0x8000000
push 3
push 0
push 3
push SysReAllocString
push esi
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov ebx, eax
cmp ebx, 0xffffffff
jne 0x43f2ea
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov ecx, dword [0x4ec48c]
test byte [ecx + 0xe0], 1
mov dword [ecx + 0x30], eax
jne 0x43f2e1
mov eax, dword [0x4f13d8]
push 1
push 0
push ebx
push 0x4d9220
push eax
call fcn.004a5c20
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x20
ret 4
mov ecx, dword [esp + 0x34]
jmp 0x43f6c4
mov ecx, ebx
call fcn.004a3ee0
mov esi, eax
mov ecx, esi
and ecx, edx
cmp ecx, 0xffffffff
jne 0x43f326
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov edx, dword [0x4ec48c]
push ebx
mov dword [edx + 0x30], eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, dword [esp + 0x34]
push eax
call fcn.0042fa00
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x20
ret 4
mov eax, dword [esp + 0x2c]
cmp edx, eax
jb 0x43f33c
ja 0x43f336
cmp esi, dword [esp + 0x28]
jbe 0x43f33c
mov esi, dword [esp + 0x28]
mov edx, eax
test edx, edx
jne 0x43f345
cmp esi, 0xfffffffd
jbe 0x43f364
mov ecx, dword [esp + 0x34]
push 0x4d6959
push 0
push str.Out_of_memory.
call fcn.0042d2f0
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x20
ret 4
mov ecx, esi
or ecx, edx
jne 0x43f39e
push ebx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, dword [0x4f13d8]
mov edx, dword [0x4ec48c]
push 1
push 0
push 0xffffffffffffffff
push 0x4d69c8
push eax
mov dword [edx + 0x30], 0
call fcn.004a5c20
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x20
ret 4
cmp byte [esp + 0x20], 0
je 0x43f3f3
mov al, byte [ebp + 0x17]
test al, al
jne 0x43f3b2
mov ecx, dword [ebp + 0xc]
mov al, byte [ecx + 0x17]
cmp al, 2
je 0x43f3f3
push 0
push 1
lea edx, [esi + 1]
push edx
push 0
push ebp
mov byte [esp + 0x2b], 1
call fcn.004a5c20
cmp eax, 1
jne 0x43f3e0
push 0
push eax
mov ecx, ebp
call fcn.004016d0
mov edi, eax
test edi, edi
jne 0x43f431
push ebx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
xor eax, eax
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x20
ret 4
lea eax, [esi + 2]
push eax
mov byte [esp + 0x1b], 0
call fcn.004ba2ed
mov edi, eax
add esp, 4
test edi, edi
jne 0x43f431
mov ecx, dword [esp + 0x34]
push 0x4d6959
push eax
push str.Out_of_memory.
call fcn.0042d2f0
push ebx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
xor eax, eax
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x20
ret 4
push 0
lea ecx, [esp + 0x20]
push ecx
push esi
push edi
push ebx
call dword [sym.imp.KERNEL32.dll_ReadFile]
mov ebp, eax
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov edx, dword [0x4ec48c]
push ebx
mov dword [edx + 0x30], eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
test ebp, ebp
je 0x43f602
cmp byte [esp + 0x20], 0
jne 0x43f595
mov eax, dword [esp + 0x1c]
cmp eax, 3
jb 0x43f49d
cmp byte [edi], 0xef
jne 0x43f49d
cmp byte [edi + 1], 0xbb
jne 0x43f49d
cmp byte [edi + 2], 0xbf
jne 0x43f49d
lea ecx, [eax - 3]
mov eax, dword [esp + 0x18]
push 0xfde9
lea edx, [edi + 3]
push eax
call fcn.004a6780
jmp 0x43f4d8
cmp eax, 2
jb 0x43f544
cmp byte [edi], 0xff
jne 0x43f544
cmp byte [edi + 1], 0xfe
jne 0x43f544
mov dl, 1
mov ecx, edi
mov esi, eax
test dl, dl
je 0x43f4c9
lea ecx, [edi + 2]
lea esi, [eax - 2]
mov eax, dword [esp + 0x18]
push ecx
mov ebx, esi
shr ebx, 1
push eax
call fcn.004a6850
test eax, eax
jne 0x43f4de
xor ebp, ebp
test edi, edi
je 0x43f4eb
push edi
call fcn.004ba14c
add esp, 4
mov ecx, dword [esp + 0x18]
push 0
push 1
call fcn.004016d0
cmp byte [esp + 0x16], 0
mov esi, eax
je 0x43f624
mov ebx, dword [esp + 0x18]
mov eax, ebx
call fcn.0041a8f0
push 0
push 0xffffffffffffffff
push 1
push 0x4d9a10
mov dword [esp + 0x34], eax
push 0x4dd870
push esi
lea eax, [esp + 0x3c]
or ecx, 0xffffffff
call fcn.004a36d0
mov edi, dword [esp + 0x3c]
add esp, 0x18
mov eax, ebx
call fcn.0041a8b0
jmp 0x43f624
mov esi, dword [esp + 0x24]
xor dl, dl
cmp esi, 0x4b0
je 0x43f4bb
test esi, esi
je 0x43f57e
call dword [sym.imp.KERNEL32.dll_GetACP]
cmp esi, eax
je 0x43f57a
mov ecx, dword [esp + 0x18]
push esi
push ecx
mov ecx, dword [esp + 0x24]
mov edx, edi
call fcn.004a6780
jmp 0x43f4d8
mov eax, dword [esp + 0x1c]
mov byte [eax + edi], 0
mov edx, dword [esp + 0x1c]
mov eax, dword [esp + 0x18]
push edx
call fcn.004a6340
jmp 0x43f4eb
mov ecx, dword [esp + 0x18]
mov al, byte [ecx + 0x17]
test al, al
jne 0x43f5a6
mov edx, dword [ecx + 0xc]
mov al, byte [edx + 0x17]
cmp al, 2
mov eax, dword [esp + 0x1c]
jne 0x43f5f1
push eax
mov ecx, edi
call fcn.004a5a50
lea esi, [eax - 1]
add esp, 4
neg esi
push edi
sbb esi, esi
call fcn.004ba14c
add esp, 4
inc esi
je 0x43f3e7
mov ecx, dword [0x4f13d8]
push 1
push 0
push 0xffffffffffffffff
push 0x4d69c8
push ecx
call fcn.004a5c20
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x20
ret 4
mov esi, eax
mov byte [eax + edi], 0
mov eax, ecx
call fcn.0041a880
mov dword [eax], esi
jmp 0x43f624
mov eax, dword [esp + 0x18]
mov byte [edi], 0
call fcn.0041a880
cmp byte [esp + 0x17], 0
mov dword [eax], 0
jne 0x43f624
push edi
call fcn.004ba14c
add esp, 4
mov edx, dword [esp + 0x20]
mov eax, dword [esp + 0x18]
push edx
call fcn.0041a980
test eax, eax
je 0x43f3e7
mov edx, dword [esp + 0x34]
test ebp, ebp
sete al
movzx ecx, al
push ecx
push edx
call fcn.0042d120
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x20
ret 4
mov eax, dword [0x4ec48c]
test byte [eax + 0xe0], 1
mov dword [eax + 0x30], 0x57
jne 0x43f6c2
mov eax, dword [0x4f13d8]
push 1
push 0
push 0xffffffffffffffff
push 0x4d9220
push eax
call fcn.004a5c20
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x20
ret 4
mov eax, dword [0x4ec48c]
test byte [eax + 0xe0], 1
mov dword [eax + 0x30], 0x57
jne 0x43f6c2
mov ecx, dword [0x4f13d8]
push 1
push 0
push 0xffffffffffffffff
push 0x4d9220
push ecx
call fcn.004a5c20
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x20
ret 4
mov ecx, ebx
push 0x4d6959
push 0
push 0x4d9220
call fcn.0042d070
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x20
ret 4