Function at 0x40f1c0
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x4f9a90
mov eax, dword fs:[0]
push eax
sub esp, 0x50
mov eax, dword [0x53f084]
xor eax, ebp
mov dword [ebp - 0x10], eax
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov esi, ecx
lea edi, [esi + 8]
push edi
call fcn.0040fb40
add esp, 4
lea eax, [ebp - 0x28]
mov ecx, edi
push eax
call fcn.004061d0
mov eax, dword [0x543ffc]
test eax, eax
je 0x40f264
lea ecx, [ebp - 0x28]
push ecx
push dword [esi + 0xa0]
push dword [esi + 0xa8]
push dword [esi + 0xa4]
push dword [esi]
call eax
add esp, 0x14
test al, al
je 0x40f264
mov edx, dword [ebp - 0x14]
cmp edx, 0x10
jb 0x40f3f0
mov ecx, dword [ebp - 0x28]
inc edx
mov eax, ecx
cmp edx, 0x1000
jb 0x40f3e6
mov ecx, dword [ecx - 4]
add edx, 0x23
sub eax, ecx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x40f41e
jmp 0x40f3e6
cmp dword [esi], 2
jl 0x40f2a0
cmp dword [ebp - 0x14], 0x10
lea eax, [ebp - 0x28]
cmovae eax, dword [ebp - 0x28]
push eax
push 0x51a848
push 2
call fcn.004df52f
add esp, 4
push eax
call fcn.0040e670
add esp, 0xc
push 2
call fcn.004df52f
add esp, 4
push eax
call fcn.004e03c1
add esp, 4
call fcn.0040e7a0
cmp dword [0x54400c], 0
jne 0x40f2be
push 0xffffffffffffffff
push dword [0x543fe4]
call dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
jmp 0x40f2ca
push dword [0x543fe0]
call dword [sym.imp.KERNEL32.dll_EnterCriticalSection]
call fcn.0040e8f0
test al, al
je 0x40f306
push 2
push 0
push 0
push dword [0x543ff4]
call dword [sym.imp.KERNEL32.dll_SetFilePointer]
cmp dword [ebp - 0x14], 0x10
lea ecx, [ebp - 0x5c]
push 0
push ecx
push dword [ebp - 0x18]
lea eax, [ebp - 0x28]
cmovae eax, dword [ebp - 0x28]
push eax
push dword [0x543ff4]
call dword [sym.imp.KERNEL32.dll_WriteFile]
cmp dword [0x54400c], 0
jne 0x40f31d
push dword [0x543fe4]
call dword [sym.imp.KERNEL32.dll_ReleaseMutex]
jmp 0x40f329
push dword [0x543fe0]
call dword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
mov eax, dword [esi]
cmp eax, 4
jne 0x40f38f
call dword [sym.imp.KERNEL32.dll_IsDebuggerPresent]
test eax, eax
jne 0x40f423
cmp dword [0x544008], eax
je 0x40f423
lea eax, [ebp - 0x40]
mov ecx, edi
push eax
call fcn.004061d0
push eax
call dword [0x544008]
mov edx, dword [ebp - 0x2c]
add esp, 4
cmp edx, 0x10
jb 0x40f22d
mov ecx, dword [ebp - 0x40]
inc edx
mov eax, ecx
cmp edx, 0x1000
jb 0x40f3d7
mov ecx, dword [ecx - 4]
add edx, 0x23
sub eax, ecx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x40f428
jmp 0x40f3d7
cmp eax, 3
jne 0x40f22d
cmp dword [0x543ff0], 0
mov ecx, edi
je 0x40f3b5
lea eax, [ebp - 0x40]
push eax
call fcn.004061d0
push eax
call dword [0x543ff0]
jmp 0x40f35c
lea eax, [ebp - 0x58]
push eax
call fcn.004061d0
mov ecx, eax
call fcn.0040e9e0
mov edx, dword [ebp - 0x44]
cmp edx, 0x10
jb 0x40f22d
mov ecx, dword [ebp - 0x58]
inc edx
jmp 0x40f36f
push edx
push ecx
call fcn.004d1750
add esp, 8
jmp 0x40f22d
push edx
push ecx
call fcn.004d1750
add esp, 8
push dword [esi + 0xac]
call dword [sym.imp.KERNEL32.dll_SetLastError]
mov ecx, edi
call fcn.00404f80
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.004d170a
mov esp, ebp
pop ebp
ret
call fcn.004da89d
call fcn.0041c830
call fcn.004da89d
int3