Function at 0x4011b0
Capabilities:
Read file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x22c
mov eax, dword [0x40d004]
xor eax, ebp
mov dword [ebp - 4], eax
mov eax, dword [ebp + 8]
push esi
push edi
mov esi, ecx
push 0x104
lea ecx, [ebp - 0x20c]
push ecx
push 0
mov dword [ebp - 0x220], esi
mov dword [ebp - 0x218], eax
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameW]
push 0
push 0x80
push 3
push 0
push 1
push 0x80000000
lea edx, [ebp - 0x20c]
push edx
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov edi, eax
mov dword [ebp - 0x228], edi
cmp edi, 0xffffffff
je 0x40122f
push 2
push 0
push 0xfffffffffffffff8
push edi
call dword [sym.imp.KERNEL32.dll_SetFilePointer]
cmp eax, 0xffffffff
jne 0x401241
push edi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
pop edi
xor eax, eax
pop esi
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.00402b12
mov esp, ebp
pop ebp
ret
push ebx
mov ebx, dword [sym.imp.KERNEL32.dll_ReadFile]
push 0
lea eax, [ebp - 0x210]
push eax
push 4
push esi
push edi
mov dword [ebp - 0x210], 0
call ebx
test eax, eax
je 0x4014a3
cmp dword [ebp - 0x210], 4
jne 0x4014a3
mov eax, dword [esi]
test eax, eax
je 0x4014a3
cmp eax, 0x40
ja 0x4014a3
push 0
lea ecx, [ebp - 0x210]
push ecx
push 4
lea edx, [ebp - 0x214]
push edx
push edi
call ebx
test eax, eax
je 0x4014a3
cmp dword [ebp - 0x210], 4
jne 0x4014a3
cmp dword [ebp - 0x214], 0x4a534453
jne 0x4014a3
mov eax, dword [esi]
imul eax, eax, 0x20c
push 2
push 0
mov ecx, 0xfffffff4
sub ecx, eax
push ecx
push edi
call dword [sym.imp.KERNEL32.dll_SetFilePointer]
cmp eax, 0xffffffff
je 0x4014a3
push 0
lea edx, [ebp - 0x210]
push edx
push 4
lea eax, [ebp - 0x214]
push eax
push edi
call ebx
test eax, eax
je 0x4014a3
cmp dword [ebp - 0x210], 4
jne 0x4014a3
mov ecx, dword [ebp - 0x214]
mov eax, dword [esi]
xor ecx, eax
mov dword [ebp - 0x214], ecx
cmp ecx, 0x4a534453
jne 0x4014a3
imul eax, eax, 0x20c
push eax
call fcn.00402d97
mov ecx, dword [ebp - 0x218]
mov ebx, eax
mov dword [ecx], ebx
mov edx, dword [esi]
imul edx, edx, 0x20c
push edx
push 0
push ebx
mov dword [ebp - 0x224], ebx
call fcn.004064d0
mov ecx, dword [esi]
imul ecx, ecx, 0x20c
add esp, 0x10
push 0
lea eax, [ebp - 0x210]
push eax
push ecx
push ebx
push edi
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x40149a
mov esi, dword [esi]
mov edx, esi
imul edx, edx, 0x20c
cmp edx, dword [ebp - 0x210]
jne 0x40149a
xor eax, eax
mov dword [ebp - 0x21c], eax
mov dword [ebp - 0x218], eax
cmp esi, eax
jbe 0x40142c
lea esi, [ebx + 4]
mov edi, edi
mov eax, dword [esi - 4]
add dword [ebp - 0x21c], eax
cmp word [esi + 0x206], 0
jne 0x40149a
mov eax, esi
xor ebx, ebx
lea edx, [eax + 2]
mov edi, edi
mov cx, word [eax]
add eax, 2
test cx, cx
jne 0x4013d0
sub eax, edx
sar eax, 1
je 0x401409
mov ecx, esi
xor word [ecx], 9
mov eax, esi
inc ebx
add ecx, 2
lea edi, [eax + 2]
mov dx, word [eax]
add eax, 2
test dx, dx
jne 0x4013f0
sub eax, edi
sar eax, 1
cmp ebx, eax
jb 0x4013e3
mov edi, dword [ebp - 0x228]
mov eax, dword [ebp - 0x218]
mov ecx, dword [ebp - 0x220]
mov ebx, dword [ebp - 0x224]
inc eax
add esi, 0x20c
mov dword [ebp - 0x218], eax
cmp eax, dword [ecx]
jb 0x4013b0
push edi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
lea edx, [ebp - 0x20c]
push edx
lea esi, [ebp - 0x220]
call fcn.00401140
mov ecx, dword [ebp - 0x21c]
mov eax, dword [ebp - 0x220]
lea edx, [ecx + 0x1000]
add esp, 4
cmp eax, edx
jbe 0x40147e
add ecx, 0x40000
cmp eax, ecx
jae 0x40147e
pop ebx
pop edi
mov eax, 1
pop esi
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.00402b12
mov esp, ebp
pop ebp
ret
push ebx
call fcn.00402d5d
add esp, 4
pop ebx
pop edi
xor eax, eax
pop esi
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.00402b12
mov esp, ebp
pop ebp
ret
push ebx
call fcn.00402d5d
add esp, 4
push edi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov ecx, dword [ebp - 4]
pop ebx
pop edi
xor ecx, ebp
xor eax, eax
pop esi
call fcn.00402b12
mov esp, ebp
pop ebp
ret