Function at 0x40f520
Capabilities:
Read file on windows

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x442652
mov eax, dword fs:[0]
push eax
mov eax, 0x4990
call fcn.00425cd0
mov eax, dword [0x45a024]
xor eax, ebp
mov dword [ebp - 0x14], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov eax, dword [ebp + 8]
xor ebx, ebx
push 0x103
lea ecx, [ebp - 0x11b]
push ebx
push ecx
mov dword [ebp - 0x4998], eax
mov byte [ebp - 0x11c], bl
call fcn.004212c0
add esp, 0xc
push 0x104
lea edx, [ebp - 0x11c]
push edx
push ebx
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameA]
lea eax, [ebp - 0x11c]
push eax
call dword [sym.imp.SHLWAPI.dll_PathRemoveFileSpecA]
lea eax, [ebp - 0x11c]
dec eax
nop
mov cl, byte [eax + 1]
inc eax
cmp cl, bl
jne 0x40f5a0
mov ecx, dword [str.ZgRenceCon.ini]
mov edx, dword [0x450d90]
mov dword [eax], ecx
mov ecx, dword [0x450d94]
mov dword [eax + 4], edx
mov edx, dword [0x450d98]
mov dword [eax + 8], ecx
push 0x4717
mov dword [eax + 0xc], edx
lea eax, [ebp - 0x4833]
push ebx
push eax
mov byte [ebp - 0x4834], bl
call fcn.004212c0
add esp, 0xc
lea ecx, [ebp - 0x11c]
push 0x45029c
push ecx
call fcn.0041be39
mov esi, eax
add esp, 8
cmp esi, ebx
je 0x40f623
push esi
push 0x270f
lea edx, [ebp - 0x4834]
push 1
push edx
call fcn.0041c09a
push esi
mov edi, eax
call fcn.0041c293
add esp, 0x14
cmp edi, ebx
ja 0x40f62a
xor eax, eax
jmp 0x40f7f5
mov dword [ebp - 0x483c], 0xf
mov dword [ebp - 0x4840], ebx
mov byte [ebp - 0x4850], bl
lea esi, [ebp - 0x4994]
mov dword [ebp - 4], ebx
call fcn.00403b30
lea eax, [ebp - 0x4834]
mov byte [ebp - 4], 1
lea edx, [eax + 1]
jmp 0x40f660
mov cl, byte [eax]
inc eax
cmp cl, bl
jne 0x40f660
sub eax, edx
push eax
lea eax, [ebp - 0x4994]
push eax
lea edx, [ebp - 0x4834]
lea ecx, [ebp - 0x486c]
call fcn.00403bd0
mov edi, eax
lea esi, [ebp - 0x4850]
mov byte [ebp - 4], 2
call fcn.004048e0
mov byte [ebp - 4], 1
cmp dword [ebp - 0x4858], 0x10
jb 0x40f6af
mov ecx, dword [ebp - 0x486c]
push ecx
call fcn.0041afda
add esp, 4
mov ecx, dword [ebp - 0x4840]
lea edx, [ebp - 0x4850]
add ecx, 0xfffffff8
push edx
lea eax, [ebp - 0x486c]
call fcn.004070a0
mov edi, eax
lea esi, [ebp - 0x4850]
mov byte [ebp - 4], 3
call fcn.004048e0
mov esi, 0x10
mov byte [ebp - 4], 1
cmp dword [ebp - 0x4858], esi
jb 0x40f6fb
mov eax, dword [ebp - 0x486c]
push eax
call fcn.0041afda
add esp, 4
mov edx, dword [ebp - 0x4850]
cmp dword [ebp - 0x483c], esi
jae 0x40f70f
lea edx, [ebp - 0x4850]
mov ecx, dword [ebp - 0x4840]
push ecx
lea eax, [ebp - 0x4994]
push eax
lea ecx, [ebp - 0x486c]
call fcn.00403bd0
mov edi, eax
lea esi, [ebp - 0x4850]
mov byte [ebp - 4], 4
call fcn.004048e0
mov byte [ebp - 4], 1
cmp dword [ebp - 0x4858], 0x10
jb 0x40f755
mov ecx, dword [ebp - 0x486c]
push ecx
call fcn.0041afda
add esp, 4
lea edx, [ebp - 0x4850]
push edx
lea eax, [ebp - 0x4888]
push eax
call fcn.00405d60
mov edi, dword [ebp - 0x4998]
sub esp, 0x14
mov ecx, esp
mov dword [ebp - 0x4998], esp
mov byte [ebp - 4], 5
push ebx
lea eax, [ebp - 0x4888]
xor edx, edx
push eax
mov dword [ecx + 0x14], 7
mov dword [ecx + 0x10], ebx
or eax, 0xffffffff
mov word [ecx], dx
call fcn.00403f70
push edi
lea ecx, [edi + 0x564]
call fcn.0040f820
cmp dword [ebp - 0x4874], 8
mov esi, eax
jb 0x40f7c2
mov ecx, dword [ebp - 0x4888]
push ecx
call fcn.0041afda
add esp, 4
xor edx, edx
cmp dword [ebp - 0x483c], 0x10
mov dword [ebp - 0x4874], 7
mov dword [ebp - 0x4878], ebx
mov word [ebp - 0x4888], dx
jb 0x40f7f3
mov eax, dword [ebp - 0x4850]
push eax
call fcn.0041afda
add esp, 4
mov eax, esi
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 0x14]
xor ecx, ebp
call fcn.0041af7a
mov esp, ebp
pop ebp
ret 4