Function at 0x416100
Capabilities:
Read file on windows

Disassembly:
push 0xffffffffffffffff
push 0x4786c4
mov eax, dword fs:[0]
push eax
sub esp, 0x120
mov eax, dword [0x4a5eb0]
xor eax, esp
mov dword [esp + 0x11c], eax
push ebx
push esi
push edi
mov eax, dword [0x4a5eb0]
xor eax, esp
push eax
lea eax, [esp + 0x130]
mov dword fs:[0], eax
mov edi, dword [esp + 0x140]
mov dword [esp + 0x1c], edi
mov dword [esp + 0x20], 0
push 0x480de0
lea ecx, [esp + 0x18]
mov dword [esp + 0x13c], 0
call fcn.00406300
push 0x104
lea eax, [esp + 0x2c]
push 0
mov bl, 1
push eax
mov byte [esp + 0x144], bl
mov dword [esp + 0x30], 0x104
call sub.MSVCR90.dll_memset
add esp, 0xc
push 0x480de0
lea ecx, [esp + 0x14]
call fcn.00406300
mov ecx, dword [esp + 0x144]
push 0
push 0x80
push 3
push 0
push 0
push SysReAllocString
push ecx
mov byte [esp + 0x154], 2
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov esi, eax
cmp esi, 0xffffffff
jne 0x416265
mov eax, dword [esp + 0x14]
add eax, 0xfffffff0
push eax
call fcn.004014f0
add eax, 0x10
mov dword [edi], eax
mov eax, dword [esp + 0x14]
add eax, 0xfffffff0
or ecx, 0xffffffff
lea edx, [eax + 0xc]
mov byte [esp + 0x13c], bl
add esp, 4
lock xadd dword [edx], ecx
dec ecx
test ecx, ecx
jg 0x416208
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov eax, dword [esp + 0x14]
add eax, 0xfffffff0
or edx, 0xffffffff
lea ecx, [eax + 0xc]
mov byte [esp + 0x138], 0
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x416230
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov eax, dword [esp + 0x144]
add eax, 0xfffffff0
mov dword [esp + 0x138], 0xffffffff
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x41625e
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov eax, edi
jmp 0x41646d
mov edx, dword [esp + 0x24]
push 0
lea ecx, [esp + 0x28]
push ecx
push edx
lea eax, [esp + 0x34]
push eax
push esi
call dword [sym.imp.KERNEL32.dll_ReadFile]
lea ecx, [esp + 0x28]
push ecx
lea ecx, [esp + 0x14]
call fcn.004085e0
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, dword [esp + 0x10]
cmp dword [eax - 0xc], 0
jl 0x4161cc
push str._CDFS_
push eax
call dword [sym.imp.MSVCR90.dll_wcsstr]
add esp, 8
test eax, eax
je 0x4161cc
mov ecx, dword [esp + 0x10]
sub eax, ecx
sar eax, 1
js 0x4161cc
mov edx, dword [ecx - 0xc]
cmp eax, edx
mov edi, dword [sym.imp.MSVCR90.dll_wcschr]
jge 0x4162eb
lea ecx, [ecx + eax*2]
push 0xa
push ecx
call edi
mov ecx, dword [esp + 0x18]
add esp, 8
test eax, eax
je 0x4162eb
sub eax, ecx
sar eax, 1
jmp 0x4162ee
or eax, 0xffffffff
lea esi, [eax + 1]
mov eax, dword [ecx - 0xc]
test esi, esi
jl 0x416319
cmp esi, eax
jge 0x416319
lea edx, [ecx + esi*2]
push 0xa
push edx
call edi
add esp, 8
test eax, eax
je 0x416319
sub eax, dword [esp + 0x10]
sar eax, 1
test eax, eax
jge 0x4163b8
mov eax, dword [esp + 0x14]
add eax, 0xfffffff0
push eax
call fcn.004014f0
mov esi, dword [esp + 0x20]
add eax, 0x10
mov dword [esi], eax
mov eax, dword [esp + 0x14]
add eax, 0xfffffff0
add esp, 4
mov byte [esp + 0x138], bl
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x416359
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov eax, dword [esp + 0x14]
add eax, 0xfffffff0
mov byte [esp + 0x138], 0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x416381
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov eax, dword [esp + 0x144]
add eax, 0xfffffff0
mov dword [esp + 0x138], 0xffffffff
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x41646b
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
jmp 0x41646b
sub eax, esi
push eax
push esi
lea ecx, [esp + 0x20]
push ecx
lea ecx, [esp + 0x1c]
call fcn.00407c70
mov esi, dword [esp + 0x18]
cmp dword [esi - 0xc], 0
mov byte [esp + 0x138], 3
jg 0x4163e1
or eax, 0xffffffff
jmp 0x4163f6
push 0x3d
push esi
call edi
add esp, 8
test eax, eax
jne 0x4163f2
or eax, 0xffffffff
jmp 0x4163f6
sub eax, esi
sar eax, 1
add eax, 1
jns 0x416402
lea edx, [esp + 0x14]
push edx
jmp 0x416439
push eax
lea eax, [esp + 0x24]
push eax
lea ecx, [esp + 0x20]
call fcn.004083a0
push eax
lea ecx, [esp + 0x18]
mov byte [esp + 0x13c], 4
call fcn.00404450
lea ecx, [esp + 0x20]
mov byte [esp + 0x138], 3
call fcn.004023d0
lea ecx, [esp + 0x14]
push ecx
mov esi, dword [esp + 0x20]
mov ecx, esi
call fcn.00402410
lea ecx, [esp + 0x18]
call fcn.004023d0
lea ecx, [esp + 0x10]
call fcn.004023d0
lea ecx, [esp + 0x14]
call fcn.004023d0
lea ecx, [esp + 0x144]
call fcn.004023d0
mov eax, esi
mov ecx, dword [esp + 0x130]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [esp + 0x11c]
xor ecx, esp
call fcn.00475d76
add esp, 0x12c
ret 8