Function at 0x40da00
Capabilities:
Read file on windows
Resolve function by parsing pe exports

Disassembly:
push 0xffffffffffffffff
push 0x41e606
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0x68
mov edx, dword [esp + 0x84]
push ebx
push ebp
push esi
mov esi, dword [esp + 0x94]
push edi
mov dword [esp + 0x2c], ecx
mov eax, edx
or edi, 0xffffffff
sub eax, 0x7d000
mov ecx, esi
mov ebx, 0
sbb ecx, ebx
mov dword [esp + 0x54], edi
mov dword [esp + 0x58], edi
mov dword [esp + 0x5c], edi
mov dword [esp + 0x60], edi
js 0x40da61
jg 0x40da59
cmp eax, ebx
jbe 0x40da61
mov ebp, eax
mov dword [esp + 0x34], ebp
jmp 0x40da69
xor ebp, ebp
xor ecx, ecx
mov dword [esp + 0x34], ebp
mov eax, edx
mov dword [esp + 0x38], ecx
sub eax, ebp
mov dword [esp + 0x4c], eax
mov eax, esi
sbb eax, ecx
mov ecx, dword [esp + 0x8c]
mov dword [esp + 0x50], eax
xor eax, eax
cmp ecx, ebx
sete al
mov dword [esp + 0x24], eax
mov eax, dword [esp + 0x90]
xor ecx, ecx
cmp eax, ebx
sete cl
mov dword [esp + 0x28], ecx
mov edx, dword [esp + 0x38]
mov eax, dword [esp + 0x34]
mov ecx, dword [esp + 0x88]
push ebx
push edx
push eax
push ecx
call fcn.00407150
mov edx, dword [esp + 0x3c]
add esp, 0x10
mov eax, dword [edx + 0x181c]
cmp eax, 1
je 0x40db04
cmp eax, 3
je 0x40db04
cmp eax, 2
je 0x40dade
cmp eax, 4
jne 0x40e012
push 8
call sub.MSVCRT.dll_void____cdecl_operator_new_unsigned_int_
add esp, 4
mov dword [esp + 0x30], eax
cmp eax, ebx
mov dword [esp + 0x80], 1
je 0x40db26
mov ecx, eax
call fcn.00401b20
jmp 0x40db28
push 8
call sub.MSVCRT.dll_void____cdecl_operator_new_unsigned_int_
add esp, 4
mov dword [esp + 0x30], eax
cmp eax, ebx
mov dword [esp + 0x80], ebx
je 0x40db26
mov ecx, eax
call fcn.00401820
jmp 0x40db28
xor eax, eax
mov dword [esp + 0x80], edi
mov edi, eax
cmp edi, ebx
mov dword [esp + 0x1c], edi
je 0x40e012
mov eax, dword [edi]
push 1
mov ecx, edi
call dword [eax + 8]
mov dword [esp + 0x3c], ebx
mov dword [esp + 0x40], ebx
xor ebp, ebp
mov esi, 0x10000
lea ecx, [esp + 0x64]
mov dword [esp + 0x80], 2
mov dword [esp + 0x44], ebx
mov dword [esp + 0x48], ebp
mov dword [esp + 0x10], ebx
mov dword [esp + 0x20], esi
call fcn.00401000
push esi
push 0x50000
lea ecx, [esp + 0x6c]
mov byte [esp + 0x88], 3
call fcn.00401020
lea ecx, [esp + 0x64]
call fcn.00401110
mov edx, dword [esp + 0x88]
lea ecx, [esp + 0x10]
push ebx
push ecx
push esi
push eax
push edx
call dword [sym.imp.KERNEL32.dll_ReadFile]
cmp ebp, dword [esp + 0x50]
jg 0x40dda5
jl 0x40dbcb
mov eax, dword [esp + 0x4c]
mov ecx, dword [esp + 0x44]
cmp ecx, eax
jae 0x40dda5
mov eax, dword [esp + 0x10]
cmp eax, ebx
je 0x40dda5
push eax
lea ecx, [esp + 0x68]
call fcn.00401120
lea ecx, [esp + 0x14]
mov dword [esp + 0x14], ebx
push ecx
lea ecx, [esp + 0x68]
call fcn.00401140
mov ecx, dword [esp + 0x14]
cmp ecx, ebx
jle 0x40dd6c
mov edx, dword [edi]
lea esi, [esp + 0x3c]
push ebx
push esi
push ecx
push eax
mov ecx, edi
call dword [edx + 4]
mov ebp, dword [esp + 0x40]
mov esi, eax
cmp ebp, ebx
mov dword [esp + 0x30], esi
jle 0x40dd45
mov edi, dword [esp + 0x3c]
mov dword [esp + 0x18], ebp
cmp edi, ebx
mov eax, edi
lea ecx, [ebp - 1]
je 0x40dc3d
cmp ecx, ebx
jle 0x40dc3f
mov eax, dword [eax + 4]
dec ecx
cmp eax, ebx
jne 0x40dc31
cmp ecx, ebx
jne 0x40dcb8
cmp eax, ebx
je 0x40dcb8
mov ecx, dword [eax]
cmp ecx, ebx
je 0x40dcb8
cmp dword [esp + 0x24], ebx
jne 0x40dc84
cmp byte [ecx + 0x14], bl
je 0x40dc84
cmp byte [ecx + 0x17], bl
je 0x40dc84
cmp byte [ecx + 0x16], bl
je 0x40dc84
mov eax, dword [ecx + 0x18]
mov esi, dword [esp + 0x44]
cdq
add eax, esi
mov esi, dword [esp + 0x48]
adc edx, esi
mov esi, dword [esp + 0x34]
add eax, esi
mov dword [esp + 0x54], eax
mov eax, dword [esp + 0x38]
adc edx, eax
mov dword [esp + 0x58], edx
cmp dword [esp + 0x28], ebx
jne 0x40dcb8
cmp byte [ecx + 0x15], bl
je 0x40dcb8
cmp byte [ecx + 0x16], bl
je 0x40dcb8
mov eax, dword [ecx + 0x18]
mov ecx, dword [esp + 0x44]
mov esi, dword [esp + 0x48]
cdq
add eax, ecx
mov ecx, dword [esp + 0x34]
adc edx, esi
add eax, ecx
mov dword [esp + 0x5c], eax
mov eax, dword [esp + 0x38]
adc edx, eax
mov dword [esp + 0x60], edx
cmp ebp, 1
jne 0x40dce7
mov eax, dword [edi]
cmp eax, ebx
je 0x40dcd0
push eax
call sub.MSVCRT.dll_void___cdecl_operator_delete_void__
mov edi, dword [esp + 0x40]
add esp, 4
push edi
call sub.MSVCRT.dll_void___cdecl_operator_delete_void__
add esp, 4
xor edi, edi
xor ebp, ebp
mov dword [esp + 0x3c], edi
mov dword [esp + 0x40], ebp
jmp 0x40dd2e
cmp edi, ebx
mov esi, edi
lea eax, [ebp - 2]
je 0x40dcfc
cmp eax, ebx
jle 0x40dcfc
mov esi, dword [esi + 4]
dec eax
cmp esi, ebx
jne 0x40dcf0
mov eax, dword [esi + 4]
cmp eax, ebx
je 0x40dd2e
mov eax, dword [eax]
cmp eax, ebx
je 0x40dd12
push eax
call sub.MSVCRT.dll_void___cdecl_operator_delete_void__
add esp, 4
mov eax, dword [esi + 4]
push eax
call sub.MSVCRT.dll_void___cdecl_operator_delete_void__
mov dword [esi + 4], ebx
mov ebp, dword [esp + 0x44]
mov edi, dword [esp + 0x40]
add esp, 4
dec ebp
mov dword [esp + 0x40], ebp
mov eax, dword [esp + 0x18]
dec eax
mov dword [esp + 0x18], eax
jne 0x40dc28
mov edi, dword [esp + 0x1c]
mov esi, dword [esp + 0x30]
push esi
lea ecx, [esp + 0x68]
call fcn.004010b0
mov ecx, dword [esp + 0x44]
mov eax, esi
cdq
mov esi, dword [esp + 0x20]
add ecx, eax
mov eax, dword [esp + 0x48]
mov dword [esp + 0x44], ecx
adc eax, edx
mov dword [esp + 0x48], eax
mov ebp, eax
mov edx, dword [esp + 0x4c]
mov eax, dword [esp + 0x44]
mov ecx, edx
sub ecx, eax
mov eax, dword [esp + 0x50]
sbb eax, ebp
cmp eax, ebx
jg 0x40db90
jl 0x40dd94
cmp ecx, 0x10000
jae 0x40db90
mov eax, dword [esp + 0x44]
mov esi, edx
sub esi, eax
mov dword [esp + 0x20], esi
jmp 0x40db90
lea ecx, [esp + 0x64]
call fcn.00401080
mov edx, dword [edi]
push 1
mov ecx, edi
call dword [edx]
mov esi, dword [esp + 0x54]
mov ecx, dword [esp + 0x58]
mov eax, esi
and eax, ecx
cmp eax, 0xffffffff
je 0x40ddcf
mov dword [esp + 0x24], 1
mov edi, dword [esp + 0x5c]
mov ebp, dword [esp + 0x60]
mov edx, edi
and edx, ebp
cmp edx, 0xffffffff
je 0x40dde8
mov dword [esp + 0x28], 1
mov eax, dword [esp + 0x8c]
cmp eax, ebx
mov eax, dword [esp + 0x90]
je 0x40df61
cmp eax, ebx
je 0x40deb8
mov eax, esi
and eax, ecx
cmp eax, 0xffffffff
je 0x40de1c
mov edx, edi
and edx, ebp
cmp edx, 0xffffffff
jne 0x40e019
mov eax, dword [esp + 0x34]
mov ecx, dword [esp + 0x38]
sub eax, 0x7d000
sbb ecx, ebx
js 0x40de39
jg 0x40de33
cmp eax, ebx
jbe 0x40de39
mov dword [esp + 0x34], eax
jmp 0x40de41
xor eax, eax
xor ecx, ecx
mov dword [esp + 0x34], eax
mov edx, dword [esp + 0x94]
mov dword [esp + 0x38], ecx
sub edx, eax
mov eax, dword [esp + 0x98]
sbb eax, ecx
lea ecx, [esp + 0x64]
mov dword [esp + 0x4c], edx
mov dword [esp + 0x50], eax
mov byte [esp + 0x80], 2
call fcn.0041d4b0
mov eax, dword [esp + 0x3c]
mov dword [esp + 0x80], 0xffffffff
cmp eax, ebx
je 0x40deac
mov esi, eax
mov eax, dword [eax + 4]
mov dword [esp + 0x3c], eax
mov eax, dword [esi]
cmp eax, ebx
je 0x40de9b
push eax
call sub.MSVCRT.dll_void___cdecl_operator_delete_void__
add esp, 4
push esi
call sub.MSVCRT.dll_void___cdecl_operator_delete_void__
mov eax, dword [esp + 0x40]
add esp, 4
cmp eax, ebx
jne 0x40de83
mov dword [esp + 0x40], ebx
or edi, 0xffffffff
jmp 0x40daa1
mov edx, esi
and edx, ecx
cmp edx, 0xffffffff
jne 0x40e042
mov eax, dword [esp + 0x34]
mov ecx, dword [esp + 0x38]
sub eax, 0x7d000
sbb ecx, ebx
js 0x40dee2
jg 0x40dedc
cmp eax, ebx
jbe 0x40dee2
mov dword [esp + 0x34], eax
jmp 0x40deea
xor eax, eax
xor ecx, ecx
mov dword [esp + 0x34], eax
mov edx, dword [esp + 0x94]
mov dword [esp + 0x38], ecx
sub edx, eax
mov eax, dword [esp + 0x98]
sbb eax, ecx
lea ecx, [esp + 0x64]
mov dword [esp + 0x4c], edx
mov dword [esp + 0x50], eax
mov byte [esp + 0x80], 2
call fcn.0041d4b0
mov eax, dword [esp + 0x3c]
mov dword [esp + 0x80], 0xffffffff
cmp eax, ebx
je 0x40df55
mov esi, eax
mov eax, dword [eax + 4]
mov dword [esp + 0x3c], eax
mov eax, dword [esi]
cmp eax, ebx
je 0x40df44
push eax
call sub.MSVCRT.dll_void___cdecl_operator_delete_void__
add esp, 4
push esi
call sub.MSVCRT.dll_void___cdecl_operator_delete_void__
mov eax, dword [esp + 0x40]
add esp, 4
cmp eax, ebx
jne 0x40df2c
mov dword [esp + 0x40], ebx
or edi, 0xffffffff
jmp 0x40daa1
cmp eax, ebx
je 0x40e064
mov ecx, edi
and ecx, ebp
cmp ecx, 0xffffffff
jne 0x40e054
mov eax, dword [esp + 0x34]
mov ecx, dword [esp + 0x38]
sub eax, 0x7d000
sbb ecx, ebx
js 0x40df93
jg 0x40df8d
cmp eax, ebx
jbe 0x40df93
mov dword [esp + 0x34], eax
jmp 0x40df9b
xor eax, eax
xor ecx, ecx
mov dword [esp + 0x34], eax
mov edx, dword [esp + 0x94]
mov dword [esp + 0x38], ecx
sub edx, eax
mov eax, dword [esp + 0x98]
sbb eax, ecx
lea ecx, [esp + 0x64]
mov dword [esp + 0x4c], edx
mov dword [esp + 0x50], eax
mov byte [esp + 0x80], 2
call fcn.0041d4b0
mov eax, dword [esp + 0x3c]
mov dword [esp + 0x80], 0xffffffff
cmp eax, ebx
je 0x40e006
mov edx, dword [eax + 4]
mov esi, eax
mov dword [esp + 0x3c], edx
mov eax, dword [esi]
cmp eax, ebx
je 0x40dff5
push eax
call sub.MSVCRT.dll_void___cdecl_operator_delete_void__
add esp, 4
push esi
call sub.MSVCRT.dll_void___cdecl_operator_delete_void__
mov eax, dword [esp + 0x40]
add esp, 4
cmp eax, ebx
jne 0x40dfdd
mov dword [esp + 0x40], ebx
or edi, 0xffffffff
jmp 0x40daa1
xor eax, eax
jmp 0x40e0b6
mov edx, dword [esp + 0x9c]
cmp edx, ebx
je 0x40e064
cmp ebp, ecx
jg 0x40e039
jl 0x40e02e
cmp edi, esi
jae 0x40e039
mov eax, edi
mov ecx, ebp
mov dword [edx], eax
mov dword [edx + 4], ecx
jmp 0x40e064
mov eax, esi
mov dword [edx], eax
mov dword [edx + 4], ecx
jmp 0x40e064
mov eax, dword [esp + 0x9c]
cmp eax, ebx
je 0x40e064
mov dword [eax], esi
mov dword [eax + 4], ecx
jmp 0x40e064
mov eax, dword [esp + 0x9c]
cmp eax, ebx
je 0x40e064
mov dword [eax], edi
mov dword [eax + 4], ebp
lea ecx, [esp + 0x64]
mov byte [esp + 0x80], 2
call fcn.0041d4b0
mov eax, dword [esp + 0x3c]
mov dword [esp + 0x80], 0xffffffff
cmp eax, ebx
je 0x40e0b1
mov esi, eax
mov eax, dword [eax + 4]
mov dword [esp + 0x3c], eax
mov eax, dword [esi]
cmp eax, ebx
je 0x40e0a0
push eax
call sub.MSVCRT.dll_void___cdecl_operator_delete_void__
add esp, 4
push esi
call sub.MSVCRT.dll_void___cdecl_operator_delete_void__
mov eax, dword [esp + 0x40]
add esp, 4
cmp eax, ebx
jne 0x40e088
mov eax, 1
mov ecx, dword [esp + 0x78]
pop edi
pop esi
pop ebp
pop ebx
mov dword fs:[0], ecx
add esp, 0x74
ret 0x18