Function at 0x4322f0
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
push edi
push esi
push ebx
sub esp, 0x2c
mov eax, dword [ebp + 8]
mov edx, dword [ebp + 0x10]
mov dword [ebp - 0x24], eax
mov eax, edx
dec eax
mov esi, dword [ebp + 0xc]
mov dword [ebp - 0x28], edx
cmp eax, 0x20
ja 0x432317
mov dword [ebp - 0x28], 0x22
mov eax, dword [ebp - 0x24]
mov edi, 1
mov ebx, dword [eax + 4]
test ebx, ebx
je 0x4323fc
mov eax, dword [ebp - 0x24]
sub esp, 0xc
xor edi, edi
mov ebx, dword [eax]
mov eax, dword [ebx]
push eax
call sub.msvcrt.dll_strlen
add esp, 0x10
mov dword [ebp - 0x10], eax
mov dword [ebp - 0x20], 0
lea esi, [esi]
push eax
push eax
push esi
inc edi
mov edx, dword [ebp - 0x20]
mov eax, dword [edx + ebx]
push eax
call sub.msvcrt.dll_fputs
mov eax, dword [ebp - 0x24]
add esp, 0x10
cmp dword [eax + 4], edi
jbe 0x4323f8
mov eax, dword [ebp - 0x24]
lea edx, [edi*4]
sub esp, 0xc
mov dword [ebp - 0x20], edx
mov ebx, dword [eax]
mov ecx, dword [ebx + edx]
push ecx
call sub.msvcrt.dll_strlen
mov edx, dword [ebp - 0x10]
add esp, 0x10
add edx, eax
mov dword [ebp - 0x2c], eax
mov dword [ebp - 0x10], edx
test edi, edi
je 0x432350
mov ebx, dword [ebp - 0x28]
test ebx, ebx
je 0x4323d0
mov edx, dword [ebp - 0x28]
cmp dword [ebp - 0x10], edx
jbe 0x4323d0
push esi
push 4
push 1
push str.__n
call sub.msvcrt.dll_fwrite
mov edx, dword [ebp - 0x24]
mov eax, dword [ebp - 0x2c]
add esp, 0x10
inc eax
mov ebx, dword [edx]
mov dword [ebp - 0x10], eax
jmp 0x432350
mov eax, dword [esi + 4]
dec eax
mov dword [esi + 4], eax
test eax, eax
js 0x4324e8
mov eax, dword [esi]
mov byte [eax], 0x20
inc eax
mov dword [esi], eax
mov eax, dword [ebp - 0x24]
mov edx, dword [ebp - 0x10]
inc edx
mov ebx, dword [eax]
mov dword [ebp - 0x10], edx
jmp 0x432350
mov edi, dword [ebp - 0x10]
inc edi
mov eax, dword [esi + 4]
dec eax
mov dword [esi + 4], eax
test eax, eax
js 0x432510
mov eax, dword [esi]
mov byte [eax], 0x3a
inc eax
mov dword [esi], eax
mov edx, dword [ebp - 0x24]
mov eax, dword [edx + 0x10]
test eax, eax
je 0x4324ba
mov eax, dword [ebp - 0x28]
mov dword [ebp - 0x14], 0
test eax, eax
setne byte [ebp - 0x19]
jmp 0x43247a
cmp byte [ebp - 0x19], 0
je 0x4324a4
push esi
push 4
push 1
push str.__n
lea edi, [ebx + 1]
call sub.msvcrt.dll_fwrite
add esp, 0x10
nop
push ecx
push ecx
push esi
mov edx, dword [ebp - 0x24]
mov eax, dword [edx + 0xc]
mov edx, dword [ebp - 0x18]
mov edx, dword [eax + edx]
push edx
call sub.msvcrt.dll_fputs
mov eax, dword [ebp - 0x14]
mov edx, dword [ebp - 0x24]
inc eax
add esp, 0x10
mov dword [ebp - 0x14], eax
mov eax, dword [ebp - 0x14]
cmp dword [edx + 0x10], eax
jbe 0x4324ba
mov eax, dword [ebp - 0x14]
mov edx, dword [ebp - 0x24]
shl eax, 2
sub esp, 0xc
mov dword [ebp - 0x18], eax
mov eax, dword [edx + 0xc]
mov edx, dword [ebp - 0x18]
mov eax, dword [eax + edx]
push eax
call sub.msvcrt.dll_strlen
add edi, eax
add esp, 0x10
mov ebx, eax
cmp edi, dword [ebp - 0x28]
ja 0x432433
mov eax, dword [esi + 4]
dec eax
mov dword [esi + 4], eax
test eax, eax
js 0x4324d5
mov eax, dword [esi]
inc edi
mov byte [eax], 0x20
inc eax
mov dword [esi], eax
jmp 0x432450
mov eax, dword [esi + 4]
dec eax
mov dword [esi + 4], eax
test eax, eax
js 0x4324fa
mov eax, dword [esi]
mov byte [eax], 0xa
inc eax
mov dword [esi], eax
lea esp, [ebp - 0xc]
pop ebx
pop esi
pop edi
pop ebp
ret
push ebx
push ebx
push esi
push 0x20
call sub.msvcrt.dll__flsbuf
inc edi
add esp, 0x10
jmp 0x432450
push ecx
push ecx
push esi
push 0x20
call sub.msvcrt.dll__flsbuf
add esp, 0x10
jmp 0x4323e7
mov dword [ebp + 0xc], esi
mov dword [ebp + 8], 0xa
lea esp, [ebp - 0xc]
pop ebx
pop esi
pop edi
pop ebp
jmp sub.msvcrt.dll__flsbuf
push eax
push eax
push esi
push 0x3a
call sub.msvcrt.dll__flsbuf
add esp, 0x10
jmp 0x432413