Function at 0x43327e
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x4c61c7
mov eax, dword fs:[0]
push eax
mov eax, 0x4344
call fcn.004aa8d0
mov eax, dword [0x4f7f44]
xor eax, ebp
mov dword [ebp - 0x10], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov ebx, dword [ebp + 0xc]
mov edi, ecx
lea esi, [edi + 0x340]
push esi
mov dword [ebp - 0x4348], ebx
mov dword [ebp - 0x434c], esi
call dword [sym.imp.KERNEL32.dll_EnterCriticalSection]
and dword [ebp - 4], 0
cmp dword [ebp + 0x14], 3
je 0x433314
cmp dword [ebp + 0x14], 2
je 0x4333b0
cmp dword [ebp + 0x14], 1
je 0x4333b0
push esi
call dword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
mov eax, 0x10000
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.004a79cb
leave
ret 0x10
mov eax, dword [edi + 4]
mov esi, dword [ebp + 8]
cmp esi, eax
je 0x433376
cmp eax, 0xffffffff
je 0x43332b
push dword [edi]
call fcn.004315e4
pop ecx
mov eax, dword [edi]
or dword [edi + 4], 0xffffffff
cmp esi, dword [eax + 4]
jl 0x43334b
mov esi, 0x10000
push dword [ebp - 0x434c]
call dword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
mov eax, esi
jmp 0x4332f8
cmp esi, dword [eax + 0x10]
jge 0x433365
push eax
call fcn.004312b9
pop ecx
jmp 0x433365
push dword [edi]
call fcn.004312fa
pop ecx
test eax, eax
jne 0x433391
mov eax, dword [edi]
cmp dword [eax + 0x10], esi
jl 0x433359
push eax
call fcn.00432f62
pop ecx
mov dword [edi + 4], esi
push dword [ebp + 0x10]
push ebx
push dword [edi]
call fcn.00433053
mov esi, eax
add esp, 0xc
test esi, esi
jle 0x433395
mov esi, 0x600
jmp 0x43333b
mov esi, eax
jmp 0x43333b
push dword [edi]
call fcn.004315e4
or dword [edi + 4], 0xffffffff
pop ecx
test esi, esi
jne 0x4333a9
xor esi, esi
jmp 0x43333b
mov esi, 0x5000000
jmp 0x43333b
cmp dword [edi + 4], 0xffffffff
je 0x4333be
push dword [edi]
call fcn.004315e4
pop ecx
mov eax, dword [edi]
mov esi, dword [ebp + 8]
or dword [edi + 4], 0xffffffff
cmp esi, dword [eax + 4]
jge 0x433336
cmp esi, dword [eax + 0x10]
jge 0x4333e5
push eax
call fcn.004312b9
jmp 0x4333e4
push dword [edi]
call fcn.004312fa
pop ecx
mov eax, dword [edi]
cmp dword [eax + 0x10], esi
jl 0x4333dd
lea eax, [ebp - 0x4344]
push eax
push esi
mov ecx, edi
call fcn.004316f2
test byte [ebp - 0x423c], 0x10
je 0x43343d
cmp dword [ebp + 0x14], 1
je 0x4333a5
lea eax, [ebp - 0x218]
push eax
lea eax, [ebp - 0x4340]
push eax
mov esi, 0x103
call fcn.00430a84
lea eax, [ebp - 0x218]
push eax
add edi, 0x138
push edi
call fcn.00431bcf
add esp, 0x10
jmp 0x4333a5
cmp dword [ebp + 0x14], 1
jne 0x43344e
mov dword [ebp - 0x4348], ebx
jmp 0x433532
movzx eax, word [ebx]
mov esi, ebx
mov ecx, ebx
test ax, ax
je 0x433513
cmp ax, 0x2f
je 0x43346a
cmp ax, 0x5c
jne 0x43346d
lea esi, [ecx + 2]
add ecx, 2
movzx eax, word [ecx]
test ax, ax
jne 0x43345e
cmp esi, ebx
je 0x433513
lea eax, [ebp - 0x218]
push ebx
push eax
call fcn.004a9b7a
sub esi, ebx
sar esi, 1
xor eax, eax
pop ecx
mov word [ebp + esi*2 - 0x21a], ax
cmp word [ebp - 0x218], 0x2f
pop ecx
je 0x4334bf
cmp word [ebp - 0x218], 0x5c
je 0x4334bf
cmp word [ebp - 0x216], 0x3a
je 0x4334bf
xor bl, bl
jmp 0x4334c1
mov bl, 1
lea eax, [ebp - 0x218]
push 0x4cf700
push eax
call fcn.004a98f9
mov esi, eax
lea eax, [ebp - 0x218]
push 0x4cf6f8
push eax
call fcn.004a98f9
add esp, 0x10
test eax, eax
setne al
test esi, esi
setne cl
or al, cl
or al, bl
jne 0x43350d
lea eax, [ebp - 0x218]
push eax
lea eax, [edi + 0x138]
push eax
call fcn.00431bcf
pop ecx
pop ecx
mov ebx, dword [ebp - 0x4348]
xor eax, eax
push eax
push dword [ebp - 0x423c]
push 2
push eax
push eax
push 0x40000000
push ebx
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov dword [ebp - 0x4348], eax
cmp dword [ebp - 0x4348], 0xffffffff
jne 0x433545
mov esi, 0x200
jmp 0x43333b
push dword [edi]
call fcn.00432f62
mov esi, 0x4000
push esi
lea eax, [ebp - 0x4218]
push eax
push dword [edi]
xor bl, bl
call fcn.00433053
add esp, 0x10
jmp 0x43359c
je 0x4335a2
push 0
lea ecx, [ebp - 0x4350]
push ecx
push eax
lea eax, [ebp - 0x4218]
push eax
push dword [ebp - 0x4348]
call dword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
je 0x4335a0
push esi
lea eax, [ebp - 0x4218]
push eax
push dword [edi]
call fcn.00433053
add esp, 0xc
test eax, eax
jns 0x433567
mov bl, 1
push dword [ebp - 0x4348]
call dword [sym.imp.KERNEL32.dll_GetFileType]
cmp eax, 1
jne 0x4335d8
test bl, bl
jne 0x4335d8
lea eax, [ebp - 0x4228]
push eax
lea eax, [ebp - 0x4238]
push eax
lea eax, [ebp - 0x4230]
push eax
push dword [ebp - 0x4348]
call dword [sym.imp.KERNEL32.dll_SetFileTime]
cmp dword [ebp + 0x14], 1
je 0x4335ea
push dword [ebp - 0x4348]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
push dword [edi]
call fcn.004315e4
pop ecx
test bl, bl
je 0x4333a5
mov esi, 0x400
jmp 0x43333b