Function at 0x4af4c0
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x57dd2b
mov eax, dword fs:[0]
push eax
sub esp, 0x1e8
push ebx
push esi
push edi
push ecx
lea edi, [ebp - 0x1f4]
mov ecx, 0x7a
mov eax, 0xcccccccc
rep stosd dword es:[edi], eax
pop ecx
mov eax, dword [0x5ddc34]
xor eax, ebp
mov dword [ebp - 0x10], eax
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov dword [ebp - 0x18], ecx
mov dword [ebp - 0x12c], 0
mov eax, dword [ebp - 0x18]
cmp dword [eax + 0x40], 0
je 0x4af523
mov eax, dword [ebp - 0x18]
movzx ecx, byte [eax + 0x45]
test ecx, ecx
jne 0x4af52f
mov al, 1
jmp 0x4af81f
mov dword [ebp - 0x24], 8
call fcn.00401555
mov esi, esp
push eax
mov eax, dword [ebp - 0x18]
mov edx, dword [eax]
mov ecx, dword [ebp - 0x18]
mov eax, dword [edx + 0xc]
call eax
cmp esi, esp
call fcn.004f4cf0
mov dword [ebp - 0x1dc], eax
call fcn.00401555
mov dword [ebp - 0x1d0], eax
lea ecx, [ebp - 0x1dc]
push ecx
lea edx, [ebp - 0x1d0]
push edx
call fcn.0040148d
add esp, 8
movzx eax, al
test eax, eax
je 0x4af587
xor al, al
jmp 0x4af81f
push 0
push 8
lea ecx, [ebp - 0x54]
call fcn.00401aa5
mov dword [ebp - 4], 0
lea eax, [ebp - 0x30]
push eax
lea ecx, [ebp - 0x1b8]
push ecx
lea ecx, [ebp - 0x54]
call fcn.00401537
mov dword [ebp - 0x1e4], eax
mov edx, dword [ebp - 0x1e4]
mov dword [ebp - 0x1e8], edx
mov byte [ebp - 4], 1
mov ecx, dword [ebp - 0x1e8]
call fcn.00401785
mov esi, eax
lea ecx, [ebp - 0x54]
call fcn.00401a87
add esi, eax
push esi
lea eax, [ebp - 0x1a4]
push eax
lea ecx, [ebp - 0x54]
call fcn.00401537
mov dword [ebp - 0x1ec], eax
mov ecx, dword [ebp - 0x1ec]
mov dword [ebp - 0x1f0], ecx
mov byte [ebp - 4], 2
mov ecx, dword [ebp - 0x1f0]
call fcn.00401785
push eax
mov edx, dword [ebp - 0x18]
add edx, 0x48
push edx
mov eax, dword [ebp - 0x18]
mov ecx, dword [eax + 0x40]
call fcn.00401cd0
mov dword [ebp - 0x1c4], eax
mov byte [ebp - 4], 1
lea ecx, [ebp - 0x1a4]
call fcn.0040137a
mov byte [ebp - 4], 0
lea ecx, [ebp - 0x1b8]
call fcn.0040137a
mov ecx, dword [ebp - 0x1c4]
mov dword [ebp - 0x1f4], ecx
cmp dword [ebp - 0x1f4], 0
je 0x4af672
cmp dword [ebp - 0x1f4], 1
je 0x4af679
cmp dword [ebp - 0x1f4], 3
je 0x4af7cf
jmp 0x4af7ed
mov eax, dword [ebp - 0x18]
mov byte [eax + 0x45], 0
lea eax, [ebp - 0x190]
push eax
lea ecx, [ebp - 0x54]
call fcn.00401537
mov dword [ebp - 0x1e4], eax
mov ecx, dword [ebp - 0x1e4]
mov dword [ebp - 0x1e8], ecx
mov byte [ebp - 4], 3
mov ecx, dword [ebp - 0x1e8]
call fcn.00401785
mov edx, dword [ebp - 0x30]
sub edx, eax
mov dword [ebp - 0x60], edx
mov byte [ebp - 4], 0
lea ecx, [ebp - 0x190]
call fcn.0040137a
cmp dword [ebp - 0x60], 0
jbe 0x4af72c
mov eax, dword [ebp - 0x18]
mov ecx, dword [eax + 0x50]
push ecx
mov edx, dword [ebp - 0x60]
push edx
push 1
lea eax, [ebp - 0x170]
push eax
lea ecx, [ebp - 0x54]
call fcn.00401537
mov dword [ebp - 0x1e4], eax
mov ecx, dword [ebp - 0x1e4]
mov dword [ebp - 0x1e8], ecx
mov byte [ebp - 4], 4
mov edx, dword [ebp - 0x12c]
or edx, 1
mov dword [ebp - 0x12c], edx
mov ecx, dword [ebp - 0x1e8]
call fcn.00401785
push eax
call fcn.004fb5b0
add esp, 0x10
cmp dword [ebp - 0x60], eax
je 0x4af72c
mov dword [ebp - 0x1ec], 1
jmp 0x4af736
mov dword [ebp - 0x1ec], 0
mov al, byte [ebp - 0x1ec]
mov byte [ebp - 0x179], al
mov dword [ebp - 4], 0
mov ecx, dword [ebp - 0x12c]
and ecx, 1
je 0x4af766
and dword [ebp - 0x12c], 0xfffffffe
lea ecx, [ebp - 0x170]
call fcn.0040137a
movzx edx, byte [ebp - 0x179]
test edx, edx
je 0x4af792
mov byte [ebp - 0x159], 0
mov dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0x54]
call fcn.00401a41
mov al, byte [ebp - 0x159]
jmp 0x4af81f
mov eax, dword [ebp - 0x18]
movzx ecx, byte [eax + 0x45]
test ecx, ecx
jne 0x4af7bb
mov byte [ebp - 0x14d], 1
mov dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0x54]
call fcn.00401a41
mov al, byte [ebp - 0x14d]
jmp 0x4af81f
cmp dword [ebp - 0x60], 0
jne 0x4af7cd
push 0
push 8
lea ecx, [ebp - 0x54]
call fcn.00401ae6
jmp 0x4af80b
mov byte [ebp - 0x141], 1
mov dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0x54]
call fcn.00401a41
mov al, byte [ebp - 0x141]
jmp 0x4af81f
mov byte [ebp - 0x135], 0
mov dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0x54]
call fcn.00401a41
mov al, byte [ebp - 0x135]
jmp 0x4af81f
jmp 0x4af59a
push edx
mov ecx, ebp
push eax
lea edx, [0x4af85c]
call fcn.004f4c90
pop eax
pop edx
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.004f4d70
add esp, 0x1f4
cmp ebp, esp
call fcn.004f4cf0
mov esp, ebp
pop ebp
ret