Function at 0x40ed70
Capabilities:
Read file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x428
push ebx
mov ebx, ecx
push esi
push edi
mov eax, dword [ebx + 0x40]
test eax, eax
jne 0x40ed94
lea esp, [ebp - 0x434]
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 4
push 0x250
push eax
mov eax, dword [ebx]
push eax
call dword [sym.imp.MSVCRT.dll__read]
add esp, 0xc
cmp eax, 0x250
je 0x40edc5
mov dword [ebx + 8], 1
xor eax, eax
lea esp, [ebp - 0x434]
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 4
push 0
mov ecx, ebx
call fcn.0040ec20
mov eax, dword [ebp + 8]
xor ecx, ecx
mov dword [ebp - 0xf], ecx
mov byte [ebp - 0x10], 0
mov dword [ebp - 0xb], ecx
mov dword [ebp - 7], ecx
mov word [ebp - 3], cx
test eax, eax
mov byte [ebp - 1], cl
je 0x40ef33
lea ecx, [ebx + 0x24]
call fcn.0040f270
mov edi, eax
test edi, edi
jne 0x40ee02
mov dword [ebp - 0x14], eax
jmp 0x40ee38
push edi
call dword [sym.imp.KERNEL32.dll_lstrlenW]
lea eax, [eax + eax + 2]
mov dword [ebp + 8], eax
add eax, 3
and al, 0xfc
call fcn.004096b0
mov edx, dword [ebp + 8]
mov esi, esp
push 0
push 0
push edx
push esi
push 0xffffffffffffffff
push edi
push 0
push 0
mov byte [esi], 0
call dword [sym.imp.KERNEL32.dll_WideCharToMultiByte]
mov dword [ebp - 0x14], esi
lea ecx, [ebx + 0x1c]
call fcn.0040f270
test eax, eax
mov dword [ebp + 8], eax
jne 0x40ee4c
mov dword [ebp - 0x18], eax
jmp 0x40ee81
push eax
call dword [sym.imp.KERNEL32.dll_lstrlenW]
lea edi, [eax + eax + 2]
mov eax, edi
add eax, 3
and al, 0xfc
call fcn.004096b0
mov eax, dword [ebp + 8]
mov esi, esp
push 0
push 0
push edi
push esi
push 0xffffffffffffffff
push eax
push 0
push 0
mov byte [esi], 0
call dword [sym.imp.KERNEL32.dll_WideCharToMultiByte]
mov dword [ebp - 0x18], esi
lea ecx, [ebx + 0x14]
call fcn.0040f270
test eax, eax
mov dword [ebp + 8], eax
jne 0x40ee94
xor esi, esi
jmp 0x40eec6
push eax
call dword [sym.imp.KERNEL32.dll_lstrlenW]
lea edi, [eax + eax + 2]
mov eax, edi
add eax, 3
and al, 0xfc
call fcn.004096b0
mov ecx, dword [ebp + 8]
mov esi, esp
push 0
push 0
push edi
push esi
push 0xffffffffffffffff
push ecx
push 0
push 0
mov byte [esi], 0
call dword [sym.imp.KERNEL32.dll_WideCharToMultiByte]
mov edx, dword [ebp - 0x14]
mov eax, dword [ebp - 0x18]
push edx
push eax
push esi
lea ecx, [ebp - 0x428]
push str._s:_s:_s
push ecx
call dword [sym.imp.MSVCRT.dll_sprintf]
lea edi, [ebp - 0x428]
or ecx, 0xffffffff
xor eax, eax
add esp, 0x14
repne scasb al, byte es:[edi]
not ecx
lea edx, [ebp - 0x10]
dec ecx
push edx
lea eax, [ebp - 0x428]
push ecx
push eax
mov ecx, ebx
call fcn.0040efd0
mov edi, dword [ebx + 0x40]
mov ecx, 4
add edi, 0x18
lea esi, [ebp - 0x10]
xor edx, edx
repe cmpsd dword [esi], dword es:[edi]
je 0x40ef33
mov dword [ebx + 8], 1
xor eax, eax
lea esp, [ebp - 0x434]
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 4
mov eax, dword [ebx + 0x40]
mov ecx, eax
mov edx, dword [ecx]
mov dword [ebp - 0x10], edx
mov edx, dword [ecx + 4]
mov dword [ebp - 0xc], edx
mov edx, dword [ecx + 8]
mov dword [ebp - 8], edx
xor edx, edx
mov ecx, dword [ecx + 0xc]
mov dword [ebp - 4], ecx
mov dword [eax], edx
mov dword [eax + 4], edx
mov dword [eax + 8], edx
mov dword [eax + 0xc], edx
mov ecx, dword [ebx + 0x40]
lea eax, [ebp - 0x28]
push eax
push 0x250
push ecx
mov ecx, ebx
call fcn.0040efd0
mov ecx, 0x10
lea edi, [ebp - 0x28]
lea esi, [ebp - 0x10]
xor eax, eax
repe cmpsb byte [esi], byte es:[edi]
je 0x40ef86
sbb eax, eax
sbb eax, 0xffffffff
test eax, eax
je 0x40efa2
mov dword [ebx + 8], 1
xor eax, eax
lea esp, [ebp - 0x434]
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 4
mov eax, dword [ebx + 0x40]
lea esp, [ebp - 0x434]
mov edx, dword [eax + 0x28]
pop edi
mov dword [ebx + 0x34], edx
mov eax, dword [eax + 0x2c]
mov dword [ebx + 0x38], eax
pop esi
mov eax, 1
pop ebx
mov esp, ebp
pop ebp
ret 4