Function at 0x4a3540
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x5ec3e8
mov eax, dword fs:[0]
push eax
sub esp, 0x7c
mov eax, dword [0x676580]
xor eax, ebp
mov dword [ebp - 0x20], eax
push ebx
push esi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov dword [ebp - 0x7c], ecx
call fcn.004a8320
mov dword [ebp - 0x44], eax
lea eax, [ebp + 8]
push eax
lea ecx, [ebp - 0x44]
push ecx
call fcn.004a8330
add esp, 8
movzx edx, al
test edx, edx
je 0x4a35a2
lea eax, [ebp + 8]
push eax
call fcn.004a82f0
add esp, 4
jmp 0x4a384d
mov ecx, dword [ebp - 0x7c]
call fcn.004a82d0
test eax, eax
je 0x4a35e9
mov ecx, dword [ebp - 0x7c]
call fcn.004a82d0
mov esi, eax
mov ecx, dword [ebp - 0x7c]
call fcn.004a4370
cmp esi, eax
jae 0x4a35e9
lea ecx, [ebp + 8]
push ecx
call fcn.004a8270
add esp, 4
mov bl, al
mov ecx, dword [ebp - 0x7c]
call fcn.004a8280
mov byte [eax], bl
mov eax, dword [ebp + 8]
jmp 0x4a384d
mov edx, dword [ebp - 0x7c]
cmp dword [edx + 0x4c], 0
jne 0x4a3601
call fcn.004a8320
jmp 0x4a384d
mov eax, dword [ebp - 0x7c]
cmp dword [eax + 0x3c], 0
jne 0x4a364a
mov ecx, dword [ebp - 0x7c]
mov edx, dword [ecx + 0x4c]
push edx
lea eax, [ebp + 8]
push eax
call fcn.004a8270
add esp, 4
push eax
call fcn.004a8250
add esp, 8
movzx ecx, al
test ecx, ecx
je 0x4a3635
mov edx, dword [ebp + 8]
mov dword [ebp - 0x80], edx
jmp 0x4a363d
call fcn.004a8320
mov dword [ebp - 0x80], eax
mov eax, dword [ebp - 0x80]
jmp 0x4a384d
mov dword [ebp - 0x10], 8
lea eax, [ebp + 8]
push eax
call fcn.004a8270
add esp, 4
mov byte [ebp - 0x15], al
push 0
push 8
lea ecx, [ebp - 0x3c]
call fcn.004a41e0
mov dword [ebp - 4], 0
lea ecx, [ebp - 0x1c]
push ecx
lea edx, [ebp - 0x4c]
push edx
lea ecx, [ebp - 0x3c]
call fcn.0049e5b0
mov ecx, eax
call fcn.004a43d0
mov esi, eax
lea ecx, [ebp - 0x3c]
call fcn.00446b40
add esi, eax
push esi
lea eax, [ebp - 0x54]
push eax
lea ecx, [ebp - 0x3c]
call fcn.0049e5b0
mov ecx, eax
call fcn.004a43d0
push eax
lea ecx, [ebp - 0x14]
push ecx
lea edx, [ebp - 0x14]
push edx
lea eax, [ebp - 0x15]
push eax
mov ecx, dword [ebp - 0x7c]
add ecx, 0x44
push ecx
mov edx, dword [ebp - 0x7c]
mov ecx, dword [edx + 0x3c]
call fcn.004a4c60
mov dword [ebp - 0x84], eax
cmp dword [ebp - 0x84], 0
jl 0x4a381d
cmp dword [ebp - 0x84], 1
jle 0x4a36f7
cmp dword [ebp - 0x84], 3
je 0x4a37d0
jmp 0x4a381d
lea eax, [ebp - 0x5c]
push eax
lea ecx, [ebp - 0x3c]
call fcn.0049e5b0
mov ecx, eax
call fcn.004a43d0
mov ecx, dword [ebp - 0x1c]
sub ecx, eax
mov dword [ebp - 0x40], ecx
je 0x4a3761
mov edx, dword [ebp - 0x7c]
mov eax, dword [edx + 0x4c]
push eax
mov ecx, dword [ebp - 0x40]
push ecx
push 1
lea edx, [ebp - 0x64]
push edx
lea ecx, [ebp - 0x3c]
call fcn.0049e5b0
mov ecx, eax
call fcn.004a43d0
push eax
call fcn.0052a93f
add esp, 0x10
cmp dword [ebp - 0x40], eax
je 0x4a3761
call fcn.004a8320
mov dword [ebp - 0x68], eax
mov dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0x3c]
call fcn.00401d60
mov eax, dword [ebp - 0x68]
jmp 0x4a384d
mov eax, dword [ebp - 0x7c]
mov byte [eax + 0x41], 1
mov ecx, dword [ebp - 0x14]
lea edx, [ebp - 0x15]
cmp ecx, edx
je 0x4a378f
mov eax, dword [ebp + 8]
mov dword [ebp - 0x6c], eax
mov dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0x3c]
call fcn.00401d60
mov eax, dword [ebp - 0x6c]
jmp 0x4a384d
cmp dword [ebp - 0x40], 0
jbe 0x4a3797
jmp 0x4a37ce
lea ecx, [ebp - 0x3c]
call fcn.00446b40
cmp eax, 0x20
jae 0x4a37b2
push 0
push 8
lea ecx, [ebp - 0x3c]
call fcn.0049b160
jmp 0x4a37ce
call fcn.004a8320
mov dword [ebp - 0x70], eax
mov dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0x3c]
call fcn.00401d60
mov eax, dword [ebp - 0x70]
jmp 0x4a384d
jmp 0x4a3839
mov ecx, dword [ebp - 0x7c]
mov edx, dword [ecx + 0x4c]
push edx
mov al, byte [ebp - 0x15]
push eax
call fcn.004a8250
add esp, 8
movzx ecx, al
test ecx, ecx
je 0x4a37f5
mov edx, dword [ebp + 8]
mov dword [ebp - 0x88], edx
jmp 0x4a3800
call fcn.004a8320
mov dword [ebp - 0x88], eax
mov eax, dword [ebp - 0x88]
mov dword [ebp - 0x74], eax
mov dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0x3c]
call fcn.00401d60
mov eax, dword [ebp - 0x74]
jmp 0x4a384d
call fcn.004a8320
mov dword [ebp - 0x78], eax
mov dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0x3c]
call fcn.00401d60
mov eax, dword [ebp - 0x78]
jmp 0x4a384d
jmp 0x4a3673
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop esi
pop ebx
mov ecx, dword [ebp - 0x20]
xor ecx, ebp
call fcn.005236f2
mov esp, ebp
pop ebp
ret 4