Function at 0x49b820
Capabilities:
Write file on windows

Disassembly:
sub esp, 0x344
mov eax, dword [0x4ce724]
xor eax, esp
mov dword [esp + 0x340], eax
push ebx
push ebp
mov ebp, dword [esp + 0x350]
push esi
push edi
mov edi, ecx
mov dword [esp + 0x2c], edi
mov byte [0x4eea10], 1
call fcn.0049b7c0
call fcn.00497a90
mov esi, dword [sym.imp.KERNEL32.dll_GetSystemTimeAsFileTime]
xor ebx, ebx
lea ecx, [esp + 0x1c]
mov eax, 0x100
push ecx
mov byte [esp + 0x1f], bl
mov byte [esp + 0x17], bl
mov dword [esp + 0x28], ebx
mov dword [esp + 0x2c], ebx
mov byte [esp + 0x1e6], bl
mov byte [esp + 0x20e], bl
mov dword [esp + 0x1da], ebx
mov word [esp + 0x1d8], ax
call esi
mov edx, dword [esp + 0x1c]
mov eax, dword [esp + 0x20]
mov dword [esp + 0x1da], edx
lea edx, [esp + 0x1c]
mov ecx, 0x100
push edx
mov dword [esp + 0x1e2], eax
mov dword [esp + 0x24e], ebx
mov byte [esp + 0x6a], bl
mov byte [esp + 0x92], bl
mov dword [esp + 0x5e], ebx
mov word [esp + 0x5c], cx
call esi
mov eax, dword [esp + 0x1c]
mov ecx, dword [esp + 0x20]
mov dword [esp + 0x5e], eax
lea edx, [esp + 0x13]
push edx
lea eax, [esp + 0x1f]
push eax
push ebx
mov dword [esp + 0x6e], ecx
lea ecx, [esp + 0x50]
push ecx
lea edx, [esp + 0x68]
push edx
push ebx
lea eax, [esp + 0x48]
push eax
lea ecx, [esp + 0x1f0]
push ecx
lea edx, [esp + 0x34]
push edx
lea eax, [esp + 0x40]
push eax
push edi
lea edx, [esp + 0x54]
lea ecx, [esp + 0x50]
mov dword [esp + 0xfa], ebx
mov dword [esp + 0x48], ebx
mov dword [esp + 0x40], ebx
call fcn.00499f10
add esp, 0x2c
push ebx
call dword [sym.imp.KERNEL32.dll_SetLastError]
mov cl, byte [esp + 0x3c]
dec cl
mov byte [esp + 0x13], bl
cmp cl, 5
jbe 0x49b970
mov dl, byte [esp + 0x50]
dec dl
cmp dl, 5
jbe 0x49b970
mov esi, 2
mov dword [0x4eea14], esi
mov byte [0x4eea20], 1
mov byte [0x4eea21], 1
jmp 0x49bab2
mov edx, dword [esp + 0x14]
lea eax, [esp + 0x44]
push eax
lea ecx, [esp + 0x5c]
push ecx
push edx
lea esi, [esp + 0x3c]
lea edi, [esp + 0x1e0]
call fcn.0049a770
add esp, 0xc
push ebx
push 0x80
push 2
push ebx
push ebx
push 0x40000000
push ebp
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov ebp, eax
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov esi, eax
cmp esi, ebx
je 0x49b9c2
cmp esi, 0xb7
jne 0x49ba9a
cmp ebp, 0xffffffff
je 0x49ba9a
lea eax, [esp + 0x13]
push eax
push ebp
mov ecx, 0x4ee6f8
call fcn.0049aab0
mov esi, eax
cmp esi, ebx
jne 0x49ba94
cmp byte [esp + 0x13], bl
jne 0x49ba94
mov edi, dword [esp + 0x1c]
mov edx, dword [esp + 0x24]
push ebx
lea ecx, [esp + 0x18]
push ecx
dec edi
push edi
push edx
push ebp
mov byte [0x4eea20], 1
mov dword [esp + 0x28], ebx
call dword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
je 0x49ba85
cmp edi, dword [esp + 0x14]
jne 0x49ba7e
mov al, byte [esp + 0x3c]
dec al
cmp al, 5
ja 0x49ba68
mov cl, byte [esp + 0x50]
dec cl
cmp cl, 5
ja 0x49ba68
mov eax, dword [esp + 0x28]
push ebx
lea edx, [esp + 0x18]
push edx
push edi
push eax
push ebp
mov dword [esp + 0x28], ebx
call dword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
je 0x49ba85
cmp edi, dword [esp + 0x14]
jne 0x49ba7e
mov ecx, dword [esp + 0x2c]
push ecx
mov byte [0x4eea21], 1
call fcn.0049d9b0
add esp, 4
jmp 0x49baab
mov edx, dword [esp + 0x2c]
push edx
mov byte [0x4eea21], 1
call fcn.0049d9b0
add esp, 4
jmp 0x49baab
mov byte [esp + 0x13], 0x1a
jmp 0x49baab
mov byte [esp + 0x13], 0x19
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov esi, eax
jmp 0x49baab
mov al, byte [esp + 0x13]
jmp 0x49baa0
mov al, 6
mov byte [esp + 0x13], al
mov dword [0x4eea14], esi
mov byte [0x4eea11], al
push ebp
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, dword [esp + 0x24]
mov cl, byte [esp + 0x13]
mov byte [0x4eea18], bl
mov byte [0x4eea19], cl
mov dword [0x4eea1c], esi
cmp eax, ebx
je 0x49bad9
push eax
call fcn.00468a41
add esp, 4
mov eax, dword [esp + 0x28]
cmp eax, ebx
je 0x49baea
push eax
call fcn.00468a41
add esp, 4
mov ecx, dword [esp + 0x350]
pop edi
mov eax, esi
pop esi
pop ebp
pop ebx
xor ecx, esp
call fcn.00467d4f
add esp, 0x344
ret