Function at 0x4339c6
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
mov eax, 0x4240
call fcn.0042d040
mov eax, dword [0x4572b4]
xor eax, ebp
mov dword [ebp - 4], eax
cmp dword [ebp + 0x14], 3
push ebx
mov ebx, dword [ebp + 0xc]
push esi
push edi
mov edi, ecx
je 0x433c33
cmp dword [ebp + 0x14], 2
je 0x433a05
cmp dword [ebp + 0x14], 1
je 0x433a05
mov eax, 0x10000
jmp 0x433caf
cmp dword [edi + 4], 0xffffffff
je 0x433a13
push dword [edi]
call fcn.00436177
pop ecx
mov eax, dword [edi]
mov esi, dword [ebp + 8]
or dword [edi + 4], 0xffffffff
cmp esi, dword [eax + 4]
jge 0x4339fb
cmp esi, dword [eax + 0x10]
jge 0x433a36
push eax
call fcn.00436208
jmp 0x433a35
push dword [edi]
call fcn.00436247
pop ecx
mov eax, dword [edi]
cmp dword [eax + 0x10], esi
jl 0x433a2e
lea eax, [ebp - 0x4234]
push eax
push esi
mov ecx, edi
call fcn.004334db
test byte [ebp - 0x412c], 0x10
je 0x433a7d
cmp dword [ebp + 0x14], 1
jne 0x433a62
xor eax, eax
jmp 0x433caf
lea eax, [ebp - 0x4230]
push eax
lea eax, [edi + 0x138]
push eax
call fcn.00433369
pop ecx
xor eax, eax
jmp 0x433cae
xor eax, eax
cmp dword [ebp + 0x14], 1
mov dword [ebp - 0x423c], eax
je 0x433b71
mov cl, byte [ebx]
mov esi, ebx
mov edx, ebx
test cl, cl
je 0x433b58
cmp cl, 0x2f
je 0x433aa7
cmp cl, 0x5c
jne 0x433aaa
lea esi, [edx + 1]
inc edx
mov cl, byte [edx]
test cl, cl
jne 0x433a9d
cmp esi, ebx
je 0x433b58
lea eax, [ebp - 0x108]
push ebx
push eax
call fcn.00439030
sub esi, ebx
dec esi
pop ecx
pop ecx
cmp esi, 0x104
jae 0x433cc0
xor eax, eax
mov byte [ebp + esi - 0x108], al
mov cl, byte [ebp - 0x108]
cmp cl, 0x2f
je 0x433aff
cmp cl, 0x5c
je 0x433aff
cmp byte [ebp - 0x107], 0x3a
mov byte [ebp - 0x4235], al
jne 0x433b06
mov byte [ebp - 0x4235], 1
lea eax, [ebp - 0x108]
push 0x44d0f4
push eax
call fcn.00438f36
mov esi, eax
lea eax, [ebp - 0x108]
push 0x44d0f8
push eax
call fcn.00438f36
add esp, 0x10
test eax, eax
setne cl
test esi, esi
setne al
or cl, al
or cl, byte [ebp - 0x4235]
jne 0x433b56
lea eax, [ebp - 0x108]
push eax
lea eax, [edi + 0x138]
push eax
call fcn.00433369
pop ecx
pop ecx
xor eax, eax
push eax
push dword [ebp - 0x412c]
push 2
push eax
push eax
push 0x40000000
push ebx
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov ebx, eax
cmp ebx, 0xffffffff
jne 0x433b80
mov eax, 0x200
jmp 0x433caf
push dword [edi]
call fcn.00436387
mov esi, 0x4000
push esi
lea eax, [ebp - 0x4108]
push eax
push dword [edi]
call fcn.004365f2
add esp, 0x10
jmp 0x433bd0
je 0x433bdb
push 0
lea ecx, [ebp - 0x4240]
push ecx
push eax
lea eax, [ebp - 0x4108]
push eax
push ebx
call dword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
je 0x433bd4
push esi
lea eax, [ebp - 0x4108]
push eax
push dword [edi]
call fcn.004365f2
add esp, 0xc
test eax, eax
jns 0x433ba0
mov byte [ebp - 0x423c], 1
push ebx
call dword [sym.imp.KERNEL32.dll_GetFileType]
cmp eax, 1
jne 0x433c0c
cmp byte [ebp - 0x423c], 0
jne 0x433c0c
lea eax, [ebp - 0x4118]
push eax
lea eax, [ebp - 0x4128]
push eax
lea eax, [ebp - 0x4120]
push eax
push ebx
call dword [sym.imp.KERNEL32.dll_SetFileTime]
cmp dword [ebp + 0x14], 1
je 0x433c19
push ebx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
push dword [edi]
call fcn.00436177
xor eax, eax
cmp byte [ebp - 0x423c], al
pop ecx
mov ecx, 0x400
cmovne eax, ecx
jmp 0x433caf
mov esi, dword [ebp + 8]
cmp esi, dword [edi + 4]
je 0x433c7c
cmp dword [edi + 4], 0xffffffff
je 0x433c49
push dword [edi]
call fcn.00436177
pop ecx
mov eax, dword [edi]
or dword [edi + 4], 0xffffffff
cmp esi, dword [eax + 4]
jge 0x4339fb
cmp esi, dword [eax + 0x10]
jge 0x433c6b
push eax
call fcn.00436208
jmp 0x433c6a
call fcn.00436247
pop ecx
mov eax, dword [edi]
push eax
cmp dword [eax + 0x10], esi
jl 0x433c65
call fcn.00436387
pop ecx
mov dword [edi + 4], esi
push dword [ebp + 0x10]
push ebx
push dword [edi]
call fcn.004365f2
mov esi, eax
add esp, 0xc
test esi, esi
jle 0x433c97
mov eax, 0x600
jmp 0x433caf
push dword [edi]
call fcn.00436177
or dword [edi + 4], 0xffffffff
neg esi
sbb esi, esi
and esi, 0x5000000
mov eax, esi
pop ecx
mov ecx, dword [ebp - 4]
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.0041e77a
leave
ret 0x10
call fcn.00420746
int3