Function at 0x512300
Capabilities:
Write file on windows

Disassembly:
push ebp
lea ebp, [esp - 0x74]
sub esp, 0x74
push 0xffffffffffffffff
push 0x6a9e3c
mov eax, dword fs:[0]
push eax
sub esp, 0x80
mov eax, dword [0x7a1070]
xor eax, ebp
mov dword [ebp + 0x70], eax
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov dword [ebp + 0x54], ecx
mov dword [ebp - 0x54], 0xffffffff
mov eax, dword [ebp - 0x54]
cmp eax, dword [ebp + 0x7c]
jne 0x51234b
mov dword [ebp + 0x34], 1
jmp 0x512352
mov dword [ebp + 0x34], 0
mov cl, byte [ebp + 0x34]
mov byte [ebp + 0x51], cl
movzx edx, byte [ebp + 0x51]
test edx, edx
je 0x5123ad
mov dword [ebp + 0x1c], 0xffffffff
mov eax, dword [ebp + 0x7c]
cmp eax, dword [ebp + 0x1c]
je 0x512377
mov ecx, dword [ebp + 0x7c]
mov dword [ebp + 0x2c], ecx
jmp 0x51239a
mov dword [ebp + 0x18], 0xffffffff
cmp dword [ebp + 0x18], 0
jne 0x51238d
mov dword [ebp + 0x30], 1
jmp 0x512394
mov dword [ebp + 0x30], 0
mov edx, dword [ebp + 0x30]
mov dword [ebp + 0x2c], edx
mov eax, dword [ebp + 0x2c]
mov dword [ebp + 0x14], eax
mov eax, dword [ebp + 0x14]
jmp 0x512757
mov ecx, dword [ebp + 0x54]
mov edx, dword [ecx + 0x20]
mov eax, dword [edx]
mov dword [ebp + 0x10], eax
cmp dword [ebp + 0x10], 0
je 0x512427
mov ecx, dword [ebp + 0x54]
mov edx, dword [ecx + 0x20]
mov eax, dword [edx]
mov dword [ebp + 0xc], eax
mov ecx, dword [ebp + 0x54]
mov edx, dword [ecx + 0x30]
mov eax, dword [ebp + 0x54]
mov ecx, dword [eax + 0x20]
mov eax, dword [ecx]
add eax, dword [edx]
cmp dword [ebp + 0xc], eax
jae 0x512427
mov cl, byte [ebp + 0x7c]
mov byte [ebp + 0x50], cl
mov edx, dword [ebp + 0x54]
mov eax, dword [edx + 0x30]
mov ecx, dword [eax]
sub ecx, 1
mov edx, dword [ebp + 0x54]
mov eax, dword [edx + 0x30]
mov dword [eax], ecx
mov ecx, dword [ebp + 0x54]
mov edx, dword [ecx + 0x20]
mov eax, dword [edx]
mov dword [ebp + 8], eax
mov ecx, dword [ebp + 0x54]
mov edx, dword [ecx + 0x20]
mov eax, dword [edx]
add eax, 1
mov ecx, dword [ebp + 0x54]
mov edx, dword [ecx + 0x20]
mov dword [edx], eax
mov eax, dword [ebp + 8]
mov cl, byte [ebp + 0x50]
mov byte [eax], cl
mov eax, dword [ebp + 0x7c]
jmp 0x512757
mov edx, dword [ebp + 0x54]
cmp dword [edx + 0x4c], 0
jne 0x51243f
mov dword [ebp + 4], 0xffffffff
mov eax, dword [ebp + 4]
jmp 0x512757
mov ecx, dword [ebp + 0x54]
call fcn.00513960
mov eax, dword [ebp + 0x54]
cmp dword [eax + 0x38], 0
jne 0x5124b2
mov cl, byte [ebp + 0x7c]
mov byte [ebp + 0x4f], cl
mov edx, dword [ebp + 0x54]
mov eax, dword [edx + 0x4c]
mov dword [ebp], eax
mov ecx, dword [ebp]
push ecx
movsx edx, byte [ebp + 0x4f]
push edx
call fcn.0067c0e9
add esp, 8
cmp eax, 0xffffffff
je 0x51247e
mov dword [ebp + 0x28], 1
jmp 0x512485
mov dword [ebp + 0x28], 0
movzx eax, byte [ebp + 0x28]
test eax, eax
je 0x512495
mov ecx, dword [ebp + 0x7c]
mov dword [ebp + 0x40], ecx
jmp 0x5124a5
mov edx, dword [ebp - 0x8c]
mov dword [ebp + 0x40], edx
mov dword [ebp + 0x40], 0xffffffff
mov eax, dword [ebp + 0x40]
jmp 0x512757
mov dword [ebp - 0x74], 8
mov al, byte [ebp + 0x7c]
mov byte [ebp + 0x52], al
push 0
push 8
lea ecx, [ebp + 0x58]
call fcn.00511590
mov dword [ebp - 4], 0
lea ecx, [ebp - 0x78]
push ecx
lea ecx, [ebp + 0x58]
call fcn.004b0e60
mov dword [ebp - 0x10], eax
mov edx, dword [ebp - 0x10]
mov eax, dword [edx]
mov dword [ebp - 0x24], eax
lea ecx, [ebp + 0x58]
mov dword [ebp - 0x14], ecx
mov edx, dword [ebp - 0x14]
mov dword [ebp - 0x18], edx
mov eax, dword [ebp - 0x18]
add eax, 0x10
mov dword [ebp - 0x1c], eax
mov ecx, dword [ebp - 0x1c]
mov edx, dword [ecx]
mov dword [ebp - 0x28], edx
lea eax, [ebp - 0x7c]
push eax
lea ecx, [ebp + 0x58]
call fcn.004b0e60
mov dword [ebp - 0x20], eax
mov ecx, dword [ebp - 0x20]
mov edx, dword [ecx]
mov dword [ebp - 0x2c], edx
mov eax, dword [ebp + 0x54]
mov ecx, dword [eax + 0x38]
mov dword [ebp + 0x24], ecx
mov edx, dword [ebp + 0x24]
mov eax, dword [edx]
lea ecx, [ebp - 0x34]
push ecx
mov edx, dword [ebp - 0x24]
add edx, dword [ebp - 0x28]
push edx
mov ecx, dword [ebp - 0x2c]
push ecx
lea edx, [ebp - 0x48]
push edx
lea ecx, [ebp + 0x53]
push ecx
lea edx, [ebp + 0x52]
push edx
mov ecx, dword [ebp + 0x54]
add ecx, 0x40
push ecx
mov ecx, dword [ebp + 0x24]
mov edx, dword [eax + 0x1c]
call edx
mov dword [ebp + 0x3c], eax
cmp dword [ebp + 0x3c], 0
jl 0x512712
cmp dword [ebp + 0x3c], 1
jle 0x512577
cmp dword [ebp + 0x3c], 3
je 0x512698
jmp 0x512712
lea eax, [ebp - 0x80]
push eax
lea ecx, [ebp + 0x58]
call fcn.004b0e60
mov dword [ebp - 0x30], eax
mov ecx, dword [ebp - 0x30]
mov edx, dword [ecx]
mov dword [ebp - 0x38], edx
mov eax, dword [ebp - 0x34]
sub eax, dword [ebp - 0x38]
mov dword [ebp + 0x44], eax
je 0x5125fa
lea ecx, [ebp - 0x84]
push ecx
lea ecx, [ebp + 0x58]
call fcn.004b0e60
mov dword [ebp - 0x3c], eax
mov edx, dword [ebp - 0x3c]
mov eax, dword [edx]
mov dword [ebp - 0x40], eax
mov ecx, dword [ebp + 0x54]
mov edx, dword [ecx + 0x4c]
push edx
mov eax, dword [ebp + 0x44]
push eax
push 1
mov ecx, dword [ebp - 0x40]
push ecx
call fcn.0067d4bc
add esp, 0x10
cmp dword [ebp + 0x44], eax
je 0x5125fa
mov dword [ebp - 0x44], 0xffffffff
mov dword [ebp - 4], 1
push 0
push 1
lea ecx, [ebp + 0x58]
call fcn.004b1670
mov dword [ebp - 4], 0xffffffff
mov eax, dword [ebp - 0x44]
jmp 0x512757
mov edx, dword [ebp + 0x54]
mov byte [edx + 0x3d], 1
lea eax, [ebp + 0x52]
cmp dword [ebp - 0x48], eax
je 0x512631
mov ecx, dword [ebp + 0x7c]
mov dword [ebp - 0x4c], ecx
mov dword [ebp - 4], 2
push 0
push 1
lea ecx, [ebp + 0x58]
call fcn.004b1670
mov dword [ebp - 4], 0xffffffff
mov eax, dword [ebp - 0x4c]
jmp 0x512757
cmp dword [ebp + 0x44], 0
jbe 0x512639
jmp 0x512693
lea edx, [ebp + 0x58]
mov dword [ebp - 0x50], edx
mov eax, dword [ebp - 0x50]
mov dword [ebp - 0x70], eax
mov ecx, dword [ebp - 0x70]
add ecx, 0x10
mov dword [ebp - 0x58], ecx
mov edx, dword [ebp - 0x58]
mov eax, dword [edx]
mov dword [ebp - 0x5c], eax
cmp dword [ebp - 0x5c], 0x20
jae 0x51266a
push 0
push 8
lea ecx, [ebp + 0x58]
call fcn.00513620
jmp 0x512693
mov dword [ebp - 0x60], 0xffffffff
mov dword [ebp - 4], 3
push 0
push 1
lea ecx, [ebp + 0x58]
call fcn.004b1670
mov dword [ebp - 4], 0xffffffff
mov eax, dword [ebp - 0x60]
jmp 0x512757
jmp 0x512738
mov ecx, dword [ebp + 0x54]
mov edx, dword [ecx + 0x4c]
mov dword [ebp - 0x64], edx
mov al, byte [ebp + 0x52]
mov byte [ebp + 0x48], al
mov ecx, dword [ebp - 0x64]
push ecx
movsx edx, byte [ebp + 0x48]
push edx
call fcn.0067c0e9
add esp, 8
cmp eax, 0xffffffff
je 0x5126c6
mov dword [ebp + 0x20], 1
jmp 0x5126cd
mov dword [ebp + 0x20], 0
movzx eax, byte [ebp + 0x20]
test eax, eax
je 0x5126dd
mov ecx, dword [ebp + 0x7c]
mov dword [ebp + 0x38], ecx
jmp 0x5126ed
mov edx, dword [ebp - 0x88]
mov dword [ebp + 0x38], edx
mov dword [ebp + 0x38], 0xffffffff
mov eax, dword [ebp + 0x38]
mov dword [ebp - 0x68], eax
mov dword [ebp - 4], 4
push 0
push 1
lea ecx, [ebp + 0x58]
call fcn.004b1670
mov dword [ebp - 4], 0xffffffff
mov eax, dword [ebp - 0x68]
jmp 0x512757
mov dword [ebp - 0x6c], 0xffffffff
mov dword [ebp - 4], 5
push 0
push 1
lea ecx, [ebp + 0x58]
call fcn.004b1670
mov dword [ebp - 4], 0xffffffff
mov eax, dword [ebp - 0x6c]
jmp 0x512757
jmp 0x5124d2
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
mov ecx, dword [ebp + 0x70]
xor ecx, ebp
call fcn.0065c160
add ebp, 0x74
mov esp, ebp
pop ebp
ret 4