Function at 0x40ed60
Capabilities:
Get file size
Read file on windows

Disassembly:
push ebp
sub esp, 0x298
lea ebp, [esp - 4]
mov eax, dword [0x47dad4]
xor eax, ebp
mov dword [ebp + 0x298], eax
push 0x8c
mov eax, 0x45f441
call fcn.0044a6d8
mov esi, dword [ebp + 0x2a4]
push 0x104
lea eax, [ebp + 0x90]
xor edi, edi
push eax
push edi
mov ebx, ecx
mov dword [ebp - 0x18], esi
mov dword [ebp - 0x1c], edi
call dword [sym.imp.KERNEL32.DLL_GetModuleFileNameW]
push edi
push edi
push 3
push edi
push 1
push SysReAllocStringLen
lea eax, [ebp + 0x90]
push eax
call dword [sym.imp.KERNEL32.DLL_CreateFileW]
mov dword [ebp - 0x14], eax
cmp eax, 0xffffffff
jne 0x40edde
push 0x4656f9
mov ecx, esi
call fcn.004088e0
mov eax, esi
jmp 0x40f0f5
push edi
push eax
call dword [sym.imp.KERNEL32.DLL_GetFileSize]
push edi
mov esi, eax
mov eax, 0x61a80
push edi
push eax
push dword [ebp - 0x14]
sub esi, eax
mov dword [ebp - 0x1c], esi
call dword [sym.imp.KERNEL32.DLL_SetFilePointer]
push esi
call fcn.0044b1fe
pop ecx
push edi
lea ecx, [ebp - 0x20]
push ecx
push esi
push eax
push dword [ebp - 0x14]
mov dword [ebx + 0x958], eax
call dword [sym.imp.KERNEL32.DLL_ReadFile]
test eax, eax
je 0x40ee28
mov byte [ebp - 0xd], 0
cmp dword [ebp - 0x20], esi
je 0x40ee2c
mov byte [ebp - 0xd], 1
push dword [ebp - 0x14]
call dword [sym.imp.KERNEL32.DLL_CloseHandle]
cmp byte [ebp - 0xd], 0
je 0x40ee4d
mov ecx, dword [ebp - 0x18]
push 0x4656f9
call fcn.004088e0
jmp 0x40f0f2
push str._attachedFile__
call fcn.00449db0
mov dword [ebp - 0x14], eax
mov dword [esp], str._parameters_
call fcn.00449db0
pop ecx
push edi
lea ecx, [ebp + 0x34]
mov dword [ebp - 0x24], eax
mov dword [ebp + 0x4c], 0xf
call fcn.004077ee
mov dword [ebp - 4], edi
cmp esi, edi
jbe 0x40f0db
mov esi, 0x47d8c8
push dword [ebp - 0x14]
mov eax, dword [ebx + 0x958]
add eax, edi
push str._attachedFile__
push eax
call fcn.0044872e
add esp, 0xc
test eax, eax
jne 0x40f043
push str.__attachedFile_.___attachedFile__
lea ecx, [ebp]
call fcn.00408e1a
push 0
lea ecx, [ebp + 0x74]
mov dword [ebp + 0x8c], 0xf
call fcn.004077ee
lea eax, [ebp + 0x74]
mov dword [ebp - 0x3c], eax
mov eax, dword [ebx + 0x958]
add eax, edi
push eax
lea ecx, [ebp - 0x54]
mov byte [ebp - 4], 2
mov dword [ebp - 0x38], 0x43c6f0
call fcn.00406e74
push esi
push esi
push esi
push esi
push esi
push esi
push esi
push esi
push esi
push esi
push esi
push esi
push esi
push esi
push esi
lea eax, [ebp - 0x3c]
push eax
lea eax, [ebp - 0x54]
push eax
lea ecx, [ebp]
call fcn.0043c1a0
test al, al
je 0x40f01f
push 0
lea ecx, [ebp + 0x50]
mov dword [ebp + 0x68], 0xf
call fcn.004077ee
and dword [ebp + 0x6c], 0
mov eax, dword [ebx + 0x958]
add eax, dword [ebp + 0x88]
lea ecx, [ebp - 0x5c]
add eax, edi
mov dword [ebp + 0x70], eax
lea eax, [ebp + 0x50]
mov dword [ebp - 0x44], eax
lea eax, [ebp + 0x74]
push eax
mov byte [ebp - 4], 3
mov dword [ebp - 0x40], 0x43c6f0
call fcn.0040b540
push str._name__.____name_
lea ecx, [ebp - 0x98]
call fcn.00408e1a
push esi
push esi
push esi
push esi
push esi
push esi
push esi
push esi
push esi
push esi
push esi
push esi
push esi
push esi
push esi
lea ecx, [ebp - 0x44]
push ecx
lea ecx, [ebp - 0x5c]
push ecx
mov ecx, eax
mov byte [ebp - 4], 4
call fcn.0043c1a0
lea ecx, [ebp - 0x98]
mov byte [ebp - 4], 3
call fcn.0043c5f0
lea eax, [ebp + 0x6c]
mov dword [ebp - 0x34], eax
lea eax, [ebp + 0x74]
push eax
lea ecx, [ebp - 0x64]
mov dword [ebp - 0x30], 0x43bed0
call fcn.0040b540
push str._size__d___size_
lea ecx, [ebp - 0x98]
call fcn.00408e1a
push esi
push esi
push esi
push esi
push esi
push esi
push esi
push esi
push esi
push esi
push esi
push esi
push esi
push esi
push esi
lea ecx, [ebp - 0x34]
push ecx
lea ecx, [ebp - 0x64]
push ecx
mov ecx, eax
mov byte [ebp - 4], 5
call fcn.0043c1a0
mov byte [ebp - 4], 3
lea ecx, [ebp - 0x98]
call fcn.0043c5f0
lea eax, [ebp + 0x50]
push eax
lea ecx, [ebx + 0x95c]
call fcn.0040e733
mov eax, dword [ebp + 0x6c]
mov ecx, dword [ebp + 0x88]
add ecx, eax
push 0
lea edi, [edi + ecx - 1]
push 1
lea ecx, [ebp + 0x50]
call fcn.00407efb
jmp 0x40f026
mov eax, dword [ebp - 0x14]
lea edi, [edi + eax - 1]
push 0
push 1
lea ecx, [ebp + 0x74]
call fcn.00407efb
lea ecx, [ebp]
mov byte [ebp - 4], 0
call fcn.0043c5f0
jmp 0x40f0cf
push dword [ebp - 0x24]
mov eax, dword [ebx + 0x958]
add eax, edi
push str._parameters_
push eax
call fcn.0044872e
add esp, 0xc
test eax, eax
jne 0x40f0cf
lea eax, [ebp + 0x34]
mov dword [ebp - 0x2c], eax
mov eax, dword [ebx + 0x958]
add eax, edi
push eax
lea ecx, [ebp - 0x4c]
mov dword [ebp - 0x28], 0x43c6f0
call fcn.00406e74
push str.__parameters_.___parameters__
lea ecx, [ebp - 0x98]
call fcn.00408e1a
push esi
push esi
push esi
push esi
push esi
push esi
push esi
push esi
push esi
push esi
push esi
push esi
push esi
push esi
push esi
lea ecx, [ebp - 0x2c]
push ecx
lea ecx, [ebp - 0x4c]
push ecx
mov ecx, eax
mov byte [ebp - 4], 6
call fcn.0043c1a0
lea ecx, [ebp - 0x98]
mov byte [ebp - 0xd], al
mov byte [ebp - 4], 0
call fcn.0043c5f0
cmp byte [ebp - 0xd], 0
je 0x40f0cf
mov eax, dword [ebp + 0x48]
lea edi, [edi + eax - 1]
inc edi
cmp edi, dword [ebp - 0x1c]
jb 0x40ee8a
xor edi, edi
mov ecx, dword [ebp - 0x18]
lea eax, [ebp + 0x34]
push eax
call fcn.004086e5
push edi
push 1
lea ecx, [ebp + 0x34]
call fcn.00407efb
mov eax, dword [ebp - 0x18]
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp + 0x298]
xor ecx, ebp
call fcn.0044a6c9
add ebp, 0x29c
leave
ret 4