Function at 0x4384c9
Capabilities:
Write file on windows

Disassembly:
push 0x20
mov eax, 0x4c02e8
call fcn.00492516
mov esi, ecx
xor ebx, ebx
cmp dword [esi + 0x860], ebx
je 0x4387ce
mov eax, dword [esi + 0x864]
mov edi, eax
cmp eax, 0xffffffff
jne 0x4384f5
mov edi, dword [ebp + 0xc]
mov eax, dword [esi]
xor ecx, ecx
cmp dword [ebp + 0x10], ebx
sete cl
add eax, 0x1014
cmp byte [eax + 7], 0xff
lea ecx, [ecx + ecx + 2]
jne 0x438510
mov eax, dword [eax]
push ebx
push 0x80
push ecx
push ebx
push ebx
push 0x40000000
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov dword [ebp + 0xc], eax
cmp eax, 0xffffffff
je 0x4387ce
push 2
push ebx
push ebx
push eax
call dword [sym.imp.KERNEL32.dll_SetFilePointer]
lea ecx, [ebp - 0x1c]
call fcn.004703d0
mov dword [ebp - 4], ebx
cmp edi, ebx
jne 0x438583
mov edi, dword [ebp + 8]
push edi
call fcn.00492a70
or dword [ebp + 8], 0xffffffff
cmp dword [0x4fa3c4], 0
pop ecx
mov ebx, eax
je 0x4385d2
lea eax, [ebp + 8]
push eax
push 0x4ff4b0
push ecx
push ecx
mov ecx, esp
mov dword [ebp + 0x10], esp
push edi
call fcn.00470680
mov ecx, esi
call fcn.00437af8
jmp 0x4385d2
cmp edi, 4
jne 0x4385e6
mov edi, dword [ebp + 8]
push edi
call fcn.00492a70
cmp dword [0x4fa3c4], 0
pop ecx
mov ebx, eax
je 0x4385d2
cmp byte [0x4ff4b7], 0xff
mov esi, 0x4ff4b0
je 0x4385b0
mov dword [ebp + 8], esi
jmp 0x4385b8
mov eax, dword [0x4ff4b0]
mov dword [ebp + 8], eax
push 0
lea eax, [ebp + 0x10]
push eax
mov ecx, esi
call fcn.004703e0
push eax
push dword [ebp + 8]
push dword [ebp + 0xc]
call dword [sym.imp.KERNEL32.dll_WriteFile]
xor eax, eax
cmp byte [ebx + edi - 1], 0xa
sete al
mov dword [0x4fa3c4], eax
jmp 0x4387a4
cmp edi, 3
jne 0x438636
mov edi, dword [ebp + 8]
push 0x4d03c8
push edi
call fcn.00491770
push 0x4cfa38
push edi
mov ebx, eax
call fcn.00491770
add esp, 0x10
test eax, eax
je 0x438613
cmp eax, ebx
jae 0x438613
mov ebx, eax
test ebx, ebx
je 0x43862b
sub ebx, edi
push 1
lea ecx, [esi + 0x548]
call fcn.004710f0
jmp 0x438799
push edi
call fcn.00492a70
pop ecx
mov ebx, eax
jmp 0x438619
cmp edi, 2
jne 0x438656
mov edi, dword [ebp + 8]
push 0x4cfb24
push edi
call fcn.00491770
pop ecx
pop ecx
cmp eax, ebx
je 0x43862b
sub eax, edi
lea ebx, [eax + 1]
jmp 0x438619
cmp edi, 1
mov edi, dword [ebp + 8]
jne 0x4387a1
lea eax, [ebp + 0x10]
push eax
lea eax, [ebp + 8]
push eax
push edi
mov ecx, esi
mov dword [ebp + 0x10], ebx
call fcn.00437ab2
push dword [ebp + 0x10]
lea ecx, [ebp - 0x24]
push dword [ebp + 8]
call fcn.00470c60
mov esi, 0x4ff4b0
push eax
mov ecx, esi
mov byte [ebp - 4], 1
call fcn.00470710
lea ecx, [ebp - 0x24]
mov byte [ebp - 4], 0
call fcn.00470660
mov ecx, esi
call fcn.004703e0
cmp byte [0x4ff4b7], 0xff
mov dword [ebp - 0x10], eax
mov ebx, esi
jne 0x4386bb
mov ebx, dword [0x4ff4b0]
push 0
lea eax, [ebp - 0x10]
push eax
mov ecx, esi
call fcn.004703e0
push eax
push ebx
push dword [ebp + 0xc]
call dword [sym.imp.KERNEL32.dll_WriteFile]
mov esi, str._____ORG:
push esi
push edi
call fcn.00491770
push 0x4d03c8
push edi
mov dword [ebp + 8], eax
call fcn.00491770
add esp, 0x10
test eax, eax
je 0x4386fb
cmp byte [eax - 1], 0xd
jne 0x4386fb
dec eax
mov ebx, eax
sub ebx, edi
cmp dword [ebp + 8], 0
je 0x4387a4
test eax, eax
je 0x438716
cmp eax, dword [ebp + 8]
jb 0x4387a4
push esi
call fcn.00492a70
mov esi, eax
add esi, dword [ebp + 8]
mov dword [esp], str.OOO____
push esi
call fcn.00491770
pop ecx
pop ecx
sub eax, esi
push eax
push esi
lea ecx, [ebp - 0x24]
call fcn.00470c60
lea eax, [ebp - 0x24]
push eax
lea eax, [ebp - 0x2c]
push eax
mov byte [ebp - 4], 2
call fcn.00412b40
pop ecx
pop ecx
push eax
lea ecx, [ebp - 0x1c]
mov byte [ebp - 4], 3
call fcn.00470710
lea ecx, [ebp - 0x2c]
mov byte [ebp - 4], 2
call fcn.00470660
push 1
lea ecx, [ebp - 0x1c]
call fcn.004710f0
lea ecx, [ebp - 0x1c]
mov edi, eax
call fcn.004703e0
lea ecx, [ebp - 0x24]
mov ebx, eax
mov byte [ebp - 4], 0
call fcn.00470660
jmp 0x4387a4
mov cl, byte [edi]
cmp cl, 0x20
je 0x438798
cmp cl, 9
jne 0x43879e
inc ebx
cmp edi, eax
dec edi
jae 0x43878c
inc edi
jmp 0x4387a4
mov ebx, dword [ebp + 8]
test edi, edi
je 0x4387b9
push 0
lea eax, [ebp - 0x14]
push eax
push ebx
push edi
push dword [ebp + 0xc]
call dword [sym.imp.KERNEL32.dll_WriteFile]
push dword [ebp + 0xc]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
or dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0x1c]
call fcn.00470660
call fcn.004925ee
ret 0xc