Function at 0x40eff0
Capabilities:
Read file on windows
Write file on windows

Disassembly:
push ebx
mov ebx, esp
sub esp, 8
and esp, 0xfffffff8
add esp, 4
push ebp
mov ebp, dword [ebx + 4]
mov dword [esp + 4], ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x49b754
mov eax, dword fs:[0]
push eax
push ebx
sub esp, 0xf8
mov eax, dword [0x4da080]
xor eax, ebp
mov dword [ebp - 0x14], eax
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov edi, dword [ebx + 8]
mov eax, accept
mov dword [ebp - 0x70], 0
mov dword [ecx + 4], 0xa
add ecx, 0xc
mov dword [ebp - 0x6c], edi
mov esi, dword [edi + 0x10]
mov edx, dword [ecx + 0x10]
sub eax, edx
cmp eax, esi
jb 0x40f8af
cmp dword [ecx + 0x14], 0x10
jb 0x40f065
mov ecx, dword [ecx]
cmp dword [edi + 0x14], 0x10
mov eax, edi
jb 0x40f06f
mov eax, dword [edi]
push esi
push eax
push edx
push ecx
push ecx
push dword [ebp - 0x6c]
lea ecx, [ebp - 0xd4]
call fcn.00408f70
push 0x4b5c68
lea ecx, [ebp - 0xd4]
mov dword [ebp - 4], 0
call fcn.00406440
mov dword [ebp - 0x50], 0
mov dword [ebp - 0x40], 0
mov dword [ebp - 0x3c], 0
movups xmm0, xmmword [eax]
movups xmmword [ebp - 0x50], xmm0
movq xmm0, qword [eax + 0x10]
movq qword [ebp - 0x40], xmm0
mov esi, 0x18
mov dword [eax + 0x10], 0
mov dword [eax + 0x14], 0xf
mov byte [eax], 0
mov dword [ebp - 0x60], esi
mov byte [ebp - 4], 4
mov edx, dword [ebp - 0xc0]
cmp edx, 0x10
jb 0x40f116
mov ecx, dword [ebp - 0xd4]
inc edx
mov eax, ecx
cmp edx, 0x1000
jb 0x40f10c
mov ecx, dword [ecx - 4]
add edx, 0x23
sub eax, ecx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x40f8b4
push edx
push ecx
call fcn.00472dd6
add esp, 8
push edi
push 8
push 0x4b5fec
lea edx, [ebp - 0x50]
mov dword [ebp - 0xc4], 0
lea ecx, [ebp - 0xec]
mov dword [ebp - 0xc0], 0xf
mov byte [ebp - 0xd4], 0
mov dword [ebp - 0x34], 0
call fcn.004124e0
add esp, 0xc
cmp dword [eax + 0x14], 0x10
jb 0x40f159
mov eax, dword [eax]
push 0
push 0x80
push 3
push 0
push 1
push 1
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov edx, dword [ebp - 0xd8]
mov edi, eax
mov dword [ebp - 0x64], edi
cmp edx, 0x10
jb 0x40f1ae
mov ecx, dword [ebp - 0xec]
inc edx
mov eax, ecx
cmp edx, 0x1000
jb 0x40f1a4
mov ecx, dword [ecx - 4]
add edx, 0x23
sub eax, ecx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x40f8b9
push edx
push ecx
call fcn.00472dd6
add esp, 8
push dword [ebp - 0x6c]
lea edx, [ebp - 0x50]
mov dword [ebp - 0xdc], 0
push 8
push 0x4b5ff8
lea ecx, [ebp - 0x104]
mov dword [ebp - 0xd8], 0xf
mov byte [ebp - 0xec], 0
call fcn.004124e0
add esp, 0xc
cmp dword [eax + 0x14], 0x10
jb 0x40f1ec
mov eax, dword [eax]
push 0
push 0x80
push 3
push 0
push 1
push 1
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov edx, dword [ebp - 0xf0]
mov dword [ebp - 0x68], eax
cmp edx, 0x10
jb 0x40f242
mov ecx, dword [ebp - 0x104]
inc edx
mov eax, ecx
cmp edx, 0x1000
jb 0x40f235
mov ecx, dword [ecx - 4]
add edx, 0x23
sub eax, ecx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x40f8be
push edx
push ecx
call fcn.00472dd6
mov eax, dword [ebp - 0x68]
add esp, 8
mov dword [ebp - 0xf4], 0
mov dword [ebp - 0xf0], 0xf
mov byte [ebp - 0x104], 0
cmp edi, 0xffffffff
je 0x40f85f
cmp eax, 0xffffffff
je 0x40f85f
push 0
lea eax, [ebp - 0x18]
mov dword [ebp - 0x18], 0
push eax
push 4
lea eax, [ebp - 0x34]
push eax
push edi
mov edi, dword [sym.imp.KERNEL32.dll_ReadFile]
call edi
cmp eax, 1
jne 0x40f74f
cmp dword [ebp - 0x34], 0
mov dword [ebp - 0x74], 0
jbe 0x40f74f
nop word [eax + eax]
push 0
lea eax, [ebp - 0x18]
mov dword [ebp - 0x58], 0
push eax
push 4
lea eax, [ebp - 0x58]
push eax
push dword [ebp - 0x64]
call edi
test eax, eax
je 0x40f74f
mov dword [ebp - 0x30], 0
push 0
mov byte [ebp - 4], 4
lea ecx, [ebp - 0x30]
push dword [ebp - 0x58]
mov dword [ebp - 0x20], 0
mov dword [ebp - 0x1c], 0xf
mov byte [ebp - 0x30], 0
call fcn.004072e0
push 0
mov byte [ebp - 4], 6
lea ecx, [ebp - 0x18]
cmp dword [ebp - 0x1c], 0x10
lea eax, [ebp - 0x30]
push ecx
push dword [ebp - 0x58]
cmovae eax, dword [ebp - 0x30]
push eax
push dword [ebp - 0x64]
call edi
test eax, eax
je 0x40f7be
push 0
lea eax, [ebp - 0x18]
mov dword [ebp - 0x38], 0
push eax
push 4
lea eax, [ebp - 0x38]
mov dword [ebp - 0x54], 0
push eax
push dword [ebp - 0x64]
call edi
test eax, eax
je 0x40f717
push 0
lea eax, [ebp - 0x18]
push eax
push 4
lea eax, [ebp - 0x54]
push eax
push dword [ebp - 0x64]
call edi
test eax, eax
je 0x40f717
cmp dword [ebp - 0x1c], 0x10
lea ecx, [ebp - 0x30]
mov edx, dword [ebp - 0x20]
cmovae ecx, dword [ebp - 0x30]
push 1
push 0x4b5c68
push 0
call fcn.004083e0
add esp, 0xc
cmp eax, 0xffffffff
je 0x40f4ba
lea eax, [ebp - 0x30]
push eax
push 4
push 0x4b6004
lea edx, [ebp - 0x50]
lea ecx, [ebp - 0xbc]
call fcn.00412550
add esp, 0xc
mov edx, eax
or esi, 1
cmp dword [edx + 0x14], 0x10
mov dword [ebp - 0x70], esi
jb 0x40f3b4
mov edx, dword [edx]
mov dword [ebp - 0xa4], 0
mov ecx, edx
mov dword [ebp - 4], 8
mov dword [ebp - 0x94], 0
mov dword [ebp - 0x90], 0xf
mov byte [ebp - 0xa4], 0
mov byte [ebp - 4], 7
lea edi, [ecx + 1]
nop dword [eax]
mov al, byte [ecx]
inc ecx
test al, al
jne 0x40f3f0
sub ecx, edi
push ecx
push edx
lea ecx, [ebp - 0xa4]
call fcn.00402970
push dword [ebp - 0x6c]
or esi, 2
lea ecx, [ebp - 0xa4]
cmp dword [ebp - 0x90], 0x10
push 2
cmovae ecx, dword [ebp - 0xa4]
setae byte [ebp - 0x59]
sub esp, 8
mov dword [ebp - 0x60], esi
mov dword [ebp - 0x70], esi
mov esi, dword [ebp - 0x94]
mov edx, esi
call fcn.00408320
add esp, 0x10
mov dword [ebp - 0x8c], 0
mov ecx, eax
cmp esi, ecx
mov dword [ebp - 4], 0xa
mov byte [ebp - 4], 9
lea eax, [ebp - 0xa4]
cmovb ecx, esi
mov dword [ebp - 0x7c], 0
cmp byte [ebp - 0x59], 0
push ecx
cmovne eax, dword [ebp - 0xa4]
lea ecx, [ebp - 0x8c]
push eax
mov dword [ebp - 0x78], 0xf
mov byte [ebp - 0x8c], 0
call fcn.00402970
mov eax, dword [ebp - 0x60]
or eax, 0x300
or eax, 4
mov dword [ebp - 4], 0xb
mov dword [ebp - 0x60], eax
mov dword [ebp - 0x70], eax
lea eax, [ebp - 0x8c]
push eax
call fcn.00410580
mov byte [ebp - 0x59], 1
test eax, eax
je 0x40f4be
mov byte [ebp - 0x59], 0
mov dword [ebp - 4], 9
mov eax, dword [ebp - 0x60]
test al, 4
je 0x40f521
mov edx, dword [ebp - 0x78]
and eax, 0xfffffffb
mov dword [ebp - 0x60], eax
cmp edx, 0x10
jb 0x40f50c
mov ecx, dword [ebp - 0x8c]
inc edx
mov eax, ecx
cmp edx, 0x1000
jb 0x40f4ff
mov ecx, dword [ecx - 4]
add edx, 0x23
sub eax, ecx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x40f8b4
push edx
push ecx
call fcn.00472dd6
mov eax, dword [ebp - 0x60]
add esp, 8
mov dword [ebp - 0x7c], 0
mov dword [ebp - 0x78], 0xf
mov byte [ebp - 0x8c], 0
mov dword [ebp - 4], 7
test al, 2
je 0x40f58a
mov edx, dword [ebp - 0x90]
and eax, 0xfffffffd
mov dword [ebp - 0x60], eax
cmp edx, 0x10
jb 0x40f56f
mov ecx, dword [ebp - 0xa4]
inc edx
mov eax, ecx
cmp edx, 0x1000
jb 0x40f562
mov ecx, dword [ecx - 4]
add edx, 0x23
sub eax, ecx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x40f8b4
push edx
push ecx
call fcn.00472dd6
mov eax, dword [ebp - 0x60]
add esp, 8
mov dword [ebp - 0x94], 0
mov dword [ebp - 0x90], 0xf
mov byte [ebp - 0xa4], 0
mov dword [ebp - 4], 6
test al, 1
je 0x40f5d5
mov edx, dword [ebp - 0xa8]
and eax, 0xfffffffe
mov dword [ebp - 0x60], eax
cmp edx, 0x10
jb 0x40f5d5
mov ecx, dword [ebp - 0xbc]
inc edx
mov eax, ecx
cmp edx, 0x1000
jb 0x40f5cb
mov ecx, dword [ecx - 4]
add edx, 0x23
sub eax, ecx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x40f8b4
push edx
push ecx
call fcn.00472dd6
add esp, 8
cmp byte [ebp - 0x59], 0
jne 0x40f6c5
lea eax, [ebp - 0x30]
push eax
push 4
push 0x4b6004
lea edx, [ebp - 0x50]
lea ecx, [ebp - 0x8c]
call fcn.00412550
add esp, 0xc
cmp dword [eax + 0x14], 0x10
jb 0x40f603
mov eax, dword [eax]
push 0
push 0x80
push 2
push 0
push 1
push 2
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov edx, dword [ebp - 0x78]
mov esi, eax
cmp edx, 0x10
jb 0x40f652
mov ecx, dword [ebp - 0x8c]
inc edx
mov eax, ecx
cmp edx, 0x1000
jb 0x40f648
mov ecx, dword [ecx - 4]
add edx, 0x23
sub eax, ecx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x40f8b4
push edx
push ecx
call fcn.00472dd6
add esp, 8
mov dword [ebp - 0x7c], 0
mov dword [ebp - 0x78], 0xf
mov byte [ebp - 0x8c], 0
cmp esi, 0xffffffff
je 0x40f6c5
push 0
push 0
push dword [ebp - 0x38]
push dword [ebp - 0x68]
call dword [sym.imp.KERNEL32.dll_SetFilePointer]
push dword [ebp - 0x54]
call fcn.00472de4
add esp, 4
mov edi, eax
lea eax, [ebp - 0x18]
push 0
push eax
push dword [ebp - 0x54]
push edi
push dword [ebp - 0x68]
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x40f6c5
push 0
lea eax, [ebp - 0x18]
push eax
push dword [ebp - 0x54]
push edi
push esi
call dword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
je 0x40f6c5
push edi
call fcn.00472d9c
add esp, 4
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov byte [ebp - 4], 4
mov edx, dword [ebp - 0x1c]
cmp edx, 0x10
jb 0x40f6fd
mov ecx, dword [ebp - 0x30]
inc edx
mov eax, ecx
cmp edx, 0x1000
jb 0x40f6f3
mov ecx, dword [ecx - 4]
add edx, 0x23
sub eax, ecx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x40f8c8
push edx
push ecx
call fcn.00472dd6
add esp, 8
mov eax, dword [ebp - 0x74]
inc eax
mov dword [ebp - 0x74], eax
cmp eax, dword [ebp - 0x34]
jae 0x40f74f
mov esi, dword [ebp - 0x60]
mov edi, dword [sym.imp.KERNEL32.dll_ReadFile]
jmp 0x40f2b0
mov byte [ebp - 4], 4
mov edx, dword [ebp - 0x1c]
cmp edx, 0x10
jb 0x40f74f
mov ecx, dword [ebp - 0x30]
inc edx
mov eax, ecx
cmp edx, 0x1000
jb 0x40f745
mov ecx, dword [ecx - 4]
add edx, 0x23
sub eax, ecx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x40f8c8
push edx
push ecx
call fcn.00472dd6
add esp, 8
push dword [ebp - 0x64]
mov esi, dword [sym.imp.KERNEL32.dll_CloseHandle]
call esi
push dword [ebp - 0x68]
call esi
mov esi, dword [ebp - 0x6c]
lea edx, [ebp - 0x50]
push esi
push 8
push 0x4b5fec
lea ecx, [ebp - 0xbc]
call fcn.004124e0
add esp, 0xc
cmp dword [eax + 0x14], 0x10
jb 0x40f783
mov eax, dword [eax]
push eax
call fcn.0047b49c
mov edx, dword [ebp - 0xa8]
add esp, 4
cmp edx, 0x10
jb 0x40f7ff
mov ecx, dword [ebp - 0xbc]
inc edx
mov eax, ecx
cmp edx, 0x1000
jb 0x40f7f5
mov ecx, dword [ecx - 4]
add edx, 0x23
sub eax, ecx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x40f8c3
jmp 0x40f7f5
mov byte [ebp - 4], 4
mov edx, dword [ebp - 0x1c]
cmp edx, 0x10
jb 0x40f74f
mov ecx, dword [ebp - 0x30]
inc edx
mov eax, ecx
cmp edx, 0x1000
jb 0x40f745
mov ecx, dword [ecx - 4]
add edx, 0x23
sub eax, ecx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x40f8c8
jmp 0x40f745
push edx
push ecx
call fcn.00472dd6
add esp, 8
push esi
push 8
push 0x4b5ff8
lea edx, [ebp - 0x50]
lea ecx, [ebp - 0xbc]
call fcn.004124e0
add esp, 0xc
cmp dword [eax + 0x14], 0x10
jb 0x40f820
mov eax, dword [eax]
push eax
call fcn.0047b49c
mov edx, dword [ebp - 0xa8]
add esp, 4
cmp edx, 0x10
jb 0x40f85f
mov ecx, dword [ebp - 0xbc]
inc edx
mov eax, ecx
cmp edx, 0x1000
jb 0x40f855
mov ecx, dword [ecx - 4]
add edx, 0x23
sub eax, ecx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x40f8cd
push edx
push ecx
call fcn.00472dd6
add esp, 8
mov edx, dword [ebp - 0x3c]
cmp edx, 0x10
jb 0x40f88f
mov ecx, dword [ebp - 0x50]
inc edx
mov eax, ecx
cmp edx, 0x1000
jb 0x40f885
mov ecx, dword [ecx - 4]
add edx, 0x23
sub eax, ecx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x40f8d2
push edx
push ecx
call fcn.00472dd6
add esp, 8
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
mov ecx, dword [ebp - 0x14]
xor ecx, ebp
call fcn.00472d8e
mov esp, ebp
pop ebp
mov esp, ebx
pop ebx
ret 4
call fcn.004017f0
call fcn.0047a550
call fcn.0047a550
call fcn.0047a550
call fcn.0047a550
call fcn.0047a550
call fcn.0047a550
call fcn.0047a550
int3