Function at 0x4237b0
Capabilities:
Write file on windows

Disassembly:
push ebp
push edi
xor edi, edi
push esi
push ebx
sub esp, 0x5c
mov ebx, dword [esp + 0x70]
mov dword [esp], ebx
call sub.msvcrt.dll_strlen
add eax, 5
mov dword [esp], eax
call sub.msvcrt.dll_malloc
test eax, eax
mov esi, eax
je 0x4238c6
mov dword [esp], 0xc
call sub.msvcrt.dll_malloc
test eax, eax
mov edi, eax
je 0x4238c6
mov eax, dword [esp + 0x84]
mov dword [edi + 8], eax
mov dword [esp + 4], ebx
mov dword [esp], esi
call sub.msvcrt.dll_strcpy
mov dword [esp], esi
call sub.msvcrt.dll_strlen
add eax, esi
mov dword [eax], 0x6275732e
mov byte [eax + 4], 0
mov dword [esp + 4], 0xafa8a7
mov dword [esp], esi
call sub.msvcrt.dll_fopen
test eax, eax
mov dword [edi], eax
je 0x423b14
mov dword [esp + 4], ebx
mov dword [esp], esi
call sub.msvcrt.dll_strcpy
mov dword [esp], esi
call sub.msvcrt.dll_strlen
add eax, esi
mov dword [eax], 0x7864692e
mov byte [eax + 4], 0
mov dword [esp + 4], 0xafa8a7
mov dword [esp], esi
call sub.msvcrt.dll_fopen
test eax, eax
mov dword [edi + 4], eax
je 0x423ade
mov dword [esp], eax
call sub.msvcrt.dll_ftell
test eax, eax
je 0x4238d0
mov ebp, dword [esp + 0x80]
test ebp, ebp
je 0x423ace
mov eax, dword [esp + 0x84]
mov dword [esp + 4], 0xafaa7d
mov dword [esp + 0xc], eax
mov eax, dword [esp + 0x80]
mov dword [esp + 8], eax
mov eax, dword [edi + 4]
mov dword [esp], eax
call sub.msvcrt.dll_fprintf
mov eax, dword [edi + 4]
mov dword [esp], eax
call sub.msvcrt.dll_fflush
mov dword [esp], esi
call sub.msvcrt.dll_free
add esp, 0x5c
mov eax, edi
pop ebx
pop esi
pop edi
pop ebp
ret
mov eax, dword [esp + 0x7c]
mov dword [esp + 4], 0xafa8e0
mov dword [esp + 0xc], eax
mov eax, dword [esp + 0x78]
mov dword [esp + 8], eax
mov eax, dword [edi + 4]
mov dword [esp], eax
call sub.msvcrt.dll_fprintf
mov eax, dword [esp + 0x74]
test eax, eax
je 0x423a7e
mov eax, dword [edi + 4]
xor ebp, ebp
mov dword [esp + 8], 8
mov dword [esp + 4], 1
mov dword [esp], 0xafa9ec
mov dword [esp + 0xc], eax
call sub.msvcrt.dll_fwrite
mov eax, dword [esp + 0x74]
xor edx, edx
xor ebx, ebx
mov ecx, dword [eax + ebp*4]
push edx
xor edx, edx
mov eax, ecx
shr eax, 0x10
and eax, 0xff
push eax
movzx eax, ch
fild qword [esp]
add esp, 8
and ecx, 0xff
fstp qword [esp + 0x40]
push edx
push eax
fild qword [esp]
add esp, 8
fld dword [0xafaf34]
fsub st(1), st(0)
push ebx
push ecx
fild qword [esp]
add esp, 8
test ebp, ebp
fsubrp st(1)
je 0x42398c
mov edx, dword [edi + 4]
mov eax, dword [edx + 4]
sub eax, 1
test eax, eax
mov dword [edx + 4], eax
js 0x423aef
mov eax, dword [edx]
mov byte [eax], 0x2c
add eax, 1
mov dword [edx], eax
fld qword [0xafaf38]
fmul st(1)
fnstcw word [esp + 0x4e]
movzx eax, word [esp + 0x4e]
fadd qword [esp + 0x40]
mov ah, 0xc
mov word [esp + 0x4c], ax
fldcw word [esp + 0x4c]
fistp dword [esp + 0x48]
fldcw word [esp + 0x4e]
mov eax, dword [esp + 0x48]
test eax, 0xffffff00
movzx ebx, al
je 0x4239ca
neg eax
sar eax, 0x1f
movzx ebx, al
fmul qword [0xafaf40]
fadd qword [esp + 0x40]
fld qword [0xafaf48]
fmul st(2)
faddp st(1)
fldcw word [esp + 0x4c]
fistp dword [esp + 0x48]
fldcw word [esp + 0x4e]
mov eax, dword [esp + 0x48]
test eax, 0xffffff00
movzx ecx, al
je 0x423a00
neg eax
sar eax, 0x1f
movzx ecx, al
fmul qword [0xafaf50]
fadd qword [esp + 0x40]
fldcw word [esp + 0x4c]
fistp dword [esp + 0x48]
fldcw word [esp + 0x4e]
mov eax, dword [esp + 0x48]
test eax, 0xffffff00
movzx edx, al
je 0x423a2c
neg eax
sar eax, 0x1f
movzx edx, al
movzx eax, bl
add ebp, 1
mov dword [esp + 0x10], eax
movzx eax, cl
mov dword [esp + 0xc], eax
movzx eax, dl
mov dword [esp + 8], eax
mov dword [esp + 4], 0xafa9f5
mov eax, dword [edi + 4]
mov dword [esp], eax
call sub.msvcrt.dll_fprintf
cmp ebp, 0x10
jne 0x423924
mov edx, dword [edi + 4]
mov eax, dword [edx + 4]
sub eax, 1
test eax, eax
mov dword [edx + 4], eax
js 0x423b25
mov eax, dword [edx]
mov byte [eax], 0xa
add eax, 1
mov dword [edx], eax
mov eax, dword [edi + 4]
mov dword [esp + 8], 0x4d
mov dword [esp + 4], 1
mov dword [esp], 0xafaa04
mov dword [esp + 0xc], eax
call sub.msvcrt.dll_fwrite
mov eax, dword [esp + 0x84]
mov dword [esp + 4], 0xafaa54
mov dword [esp + 8], eax
mov eax, dword [edi + 4]
mov dword [esp], eax
call sub.msvcrt.dll_fprintf
mov ebp, dword [esp + 0x80]
test ebp, ebp
jne 0x42388a
mov dword [esp + 0x80], 0xafaa7a
jmp 0x42388a
mov dword [esp], 0xafaa94
call sub.msvcrt.dll_perror
jmp 0x4238be
fstp qword [esp + 0x30]
fstp qword [esp + 0x20]
mov dword [esp + 4], edx
mov dword [esp], 0x2c
call sub.msvcrt.dll__flsbuf
fld qword [esp + 0x20]
fld qword [esp + 0x30]
jmp 0x42398c
mov dword [esp], 0xafa8ac
call sub.msvcrt.dll_perror
jmp 0x423834
mov dword [esp + 4], edx
mov dword [esp], 0xa
call sub.msvcrt.dll__flsbuf
jmp 0x423a7e