Function at 0x4a67e8
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x65c
mov eax, dword [0x549950]
xor eax, ebp
mov dword [ebp - 4], eax
mov eax, dword [ebp + 0xc]
push ebx
mov ebx, ecx
cmp dword [ebx + 4], 0xffffffff
push esi
push edi
mov dword [ebp - 0x650], ebx
mov dword [ebp - 0x654], eax
je 0x4a681c
mov edi, dword [ebx]
call fcn.004a5fa9
mov esi, dword [ebx]
mov edi, dword [ebp + 8]
or dword [ebx + 4], 0xffffffff
cmp edi, dword [esi + 4]
jl 0x4a6834
mov eax, 0x10000
jmp 0x4a6ab0
cmp edi, dword [esi + 0x10]
jge 0x4a6847
call fcn.004a59d9
jmp 0x4a6847
mov esi, dword [ebx]
call fcn.004a5a0e
mov eax, dword [ebx]
cmp dword [eax + 0x10], edi
jl 0x4a6840
push edi
mov edi, dword [ebp - 0x650]
lea ebx, [ebp - 0x648]
mov ecx, edi
call fcn.004a6189
test byte [ebp - 0x43c], 0x10
je 0x4a68a7
mov ecx, dword [ebp - 0x654]
movzx eax, word [ecx]
cmp ax, 0x2f
je 0x4a688c
cmp ax, 0x5c
je 0x4a688c
test ax, ax
je 0x4a6891
cmp word [ecx + 2], 0x3a
jne 0x4a6891
push ecx
push 0
jmp 0x4a6899
push ecx
add edi, 0x244
push edi
call fcn.004a66ce
pop ecx
pop ecx
xor eax, eax
jmp 0x4a6ab0
mov edx, dword [ebp - 0x654]
movzx eax, word [edx]
mov ebx, edx
mov ecx, edx
test ax, ax
je 0x4a68d5
movzx eax, ax
cmp ax, 0x2f
je 0x4a68c8
cmp ax, 0x5c
jne 0x4a68cb
lea ebx, [ecx + 2]
inc ecx
inc ecx
movzx eax, word [ecx]
test ax, ax
jne 0x4a68bc
lea esi, [ebp - 0x210]
mov eax, edx
sub esi, edx
movzx ecx, word [eax]
mov word [esi + eax], cx
inc eax
inc eax
test cx, cx
jne 0x4a68df
cmp ebx, edx
jne 0x4a6961
xor eax, eax
mov word [ebp - 0x210], ax
push ebx
lea eax, [ebp - 0x210]
push eax
lea esi, [edi + 0x244]
push esi
lea eax, [ebp - 0x418]
push str._s_s_s
push eax
call dword [sym.imp.USER32.dll_wsprintfW]
add esp, 0x14
lea eax, [ebp - 0x210]
push eax
push esi
call fcn.004a66ce
pop ecx
pop ecx
xor eax, eax
push eax
push dword [ebp - 0x43c]
push 2
push eax
push eax
push 0x40000000
lea eax, [ebp - 0x418]
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov dword [ebp - 0x654], eax
cmp eax, 0xffffffff
jne 0x4a69d0
mov eax, 0x200
jmp 0x4a6ab0
mov eax, ebx
sub eax, edx
sar eax, 1
xor ecx, ecx
mov word [ebp + eax*2 - 0x210], cx
cmp word [ebp - 0x210], 0x2f
je 0x4a69a0
cmp word [ebp - 0x210], 0x5c
je 0x4a69a0
cmp word [ebp - 0x210], cx
je 0x4a68fa
cmp word [ebp - 0x20e], 0x3a
jne 0x4a68fa
push ebx
lea eax, [ebp - 0x210]
push eax
lea eax, [ebp - 0x418]
push 0x52c6c0
push eax
call dword [sym.imp.USER32.dll_wsprintfW]
lea eax, [ebp - 0x210]
push eax
push 0
call fcn.004a66ce
add esp, 0x18
jmp 0x4a692d
push dword [edi + 0x23c]
mov ebx, dword [edi]
call fcn.004a5c22
cmp dword [edi + 0x240], 0
pop ecx
mov esi, 0x4000
jne 0x4a69f9
push esi
call fcn.004c0124
pop ecx
mov dword [edi + 0x240], eax
and dword [ebp - 0x650], 0
lea eax, [ebp - 0x649]
push eax
push dword [edi + 0x240]
mov eax, dword [edi]
mov ecx, esi
call fcn.004a5d77
mov ebx, eax
pop ecx
pop ecx
cmp ebx, 0xffffff96
je 0x4a6a5e
test ebx, ebx
jl 0x4a6a52
jle 0x4a6a45
push 0
lea eax, [ebp - 0x658]
push eax
push ebx
push dword [edi + 0x240]
push dword [ebp - 0x654]
call dword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
je 0x4a6a6a
cmp byte [ebp - 0x649], 0
jne 0x4a6a76
test ebx, ebx
jne 0x4a6a00
mov dword [ebp - 0x650], 0x5000000
jmp 0x4a6a97
mov dword [ebp - 0x650], 0x1000
jmp 0x4a6a97
mov dword [ebp - 0x650], 0x400
jmp 0x4a6a97
lea eax, [ebp - 0x428]
push eax
lea eax, [ebp - 0x438]
push eax
lea eax, [ebp - 0x430]
push eax
push dword [ebp - 0x654]
call dword [sym.imp.KERNEL32.dll_SetFileTime]
push dword [ebp - 0x654]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov edi, dword [edi]
call fcn.004a5fa9
mov eax, dword [ebp - 0x650]
mov ecx, dword [ebp - 4]
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.004df2ac
leave
ret 8