Function at 0x4c6ef0
Capabilities:
Create directory
Write file on windows

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x4cb611
mov eax, dword fs:[0]
push eax
push ecx
sub esp, 0x4c
push ebx
push esi
push edi
mov eax, dword [0x5142b0]
xor eax, ebp
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov dword [ebp - 0x10], esp
mov dword [ebp - 0x44], ecx
mov dword [ebp - 4], 1
mov dword [ebp - 0x14], 0
mov dword [ebp - 0x18], 0
mov byte [ebp - 4], 2
cmp dword [ebp + 8], 0
jne 0x4c6f68
mov dword [ebp - 0x20], 0xc0000003
mov byte [ebp - 4], 0
lea ecx, [ebp + 0xc]
call fcn.00401ed0
mov dword [ebp - 4], 0xffffffff
lea ecx, [ebp + 0x10]
call fcn.00401ed0
mov eax, dword [ebp - 0x20]
jmp 0x4c71f5
push 0
lea ecx, [ebp + 0xc]
call fcn.00402650
push eax
call dword [sym.imp.KERNEL32.dll_CreateDirectoryW]
test eax, eax
jne 0x4c6ff7
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0xb7
je 0x4c6ff7
push 0
lea eax, [ebp - 0x24]
push eax
call fcn.004be580
add esp, 8
mov dword [ebp - 0x48], eax
mov ecx, dword [ebp - 0x48]
mov dword [ebp - 0x4c], ecx
mov byte [ebp - 4], 3
mov edx, dword [ebp - 0x4c]
mov eax, dword [edx]
push eax
lea ecx, [ebp + 0xc]
call fcn.004041b0
push eax
push str.CreateDirectory____S_Failed_due_to__S_n
call fcn.00423ad0
add esp, 0xc
mov byte [ebp - 4], 2
lea ecx, [ebp - 0x24]
call fcn.00401ed0
mov dword [ebp - 0x28], 0xc0000008
mov byte [ebp - 4], 0
lea ecx, [ebp + 0xc]
call fcn.00401ed0
mov dword [ebp - 4], 0xffffffff
lea ecx, [ebp + 0x10]
call fcn.00401ed0
mov eax, dword [ebp - 0x28]
jmp 0x4c71f5
lea ecx, [ebp + 0x10]
push ecx
lea ecx, [ebp + 0xc]
call fcn.00409290
push 0
push 0x80
push 2
push 0
push 1
push 2
lea ecx, [ebp + 0xc]
call fcn.00402650
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov dword [ebp - 0x1c], eax
cmp dword [ebp - 0x1c], 0xffffffff
jne 0x4c709a
push 0
lea edx, [ebp - 0x2c]
push edx
call fcn.004be580
add esp, 8
mov dword [ebp - 0x50], eax
mov eax, dword [ebp - 0x50]
mov dword [ebp - 0x54], eax
mov byte [ebp - 4], 4
mov ecx, dword [ebp - 0x54]
call fcn.004041b0
push eax
lea ecx, [ebp + 0xc]
call fcn.004041b0
push eax
push str.Could_not_Open_a_file____S_errcode_:__S_n
call fcn.00423db0
add esp, 0xc
mov byte [ebp - 4], 2
lea ecx, [ebp - 0x2c]
call fcn.00401ed0
mov dword [ebp - 0x30], 0xc0000005
mov byte [ebp - 4], 0
lea ecx, [ebp + 0xc]
call fcn.00401ed0
mov dword [ebp - 4], 0xffffffff
lea ecx, [ebp + 0x10]
call fcn.00401ed0
mov eax, dword [ebp - 0x30]
jmp 0x4c71f5
mov ecx, dword [ebp + 8]
push ecx
call fcn.0048f020
add esp, 4
add eax, 1
mov dword [ebp - 0x14], eax
push 0
lea edx, [ebp - 0x18]
push edx
mov eax, dword [ebp - 0x14]
push eax
mov ecx, dword [ebp + 8]
push ecx
mov edx, dword [ebp - 0x1c]
push edx
call dword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
jne 0x4c7153
push 0
lea eax, [ebp - 0x34]
push eax
call fcn.004be580
add esp, 8
mov dword [ebp - 0x58], eax
mov ecx, dword [ebp - 0x58]
mov dword [ebp - 0x5c], ecx
mov byte [ebp - 4], 5
mov ecx, dword [ebp - 0x5c]
call fcn.004041b0
push eax
lea ecx, [ebp + 0xc]
call fcn.004041b0
push eax
push str.Could_not_write_a_file____S_errcode_:__S_n
call fcn.00423db0
add esp, 0xc
mov byte [ebp - 4], 2
lea ecx, [ebp - 0x34]
call fcn.00401ed0
cmp dword [ebp - 0x1c], 0xffffffff
je 0x4c7129
mov edx, dword [ebp - 0x1c]
push edx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov dword [ebp - 0x1c], 0xffffffff
mov dword [ebp - 0x38], 0xc0000008
mov byte [ebp - 4], 0
lea ecx, [ebp + 0xc]
call fcn.00401ed0
mov dword [ebp - 4], 0xffffffff
lea ecx, [ebp + 0x10]
call fcn.00401ed0
mov eax, dword [ebp - 0x38]
jmp 0x4c71f5
lea ecx, [ebp + 0xc]
call fcn.004041b0
push eax
push str.SuccessFully_write_a_XML_file____S_n
call fcn.00423db0
add esp, 8
cmp dword [ebp - 0x1c], 0xffffffff
je 0x4c7180
mov eax, dword [ebp - 0x1c]
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov dword [ebp - 0x1c], 0xffffffff
mov dword [ebp - 0x3c], 0
mov byte [ebp - 4], 0
lea ecx, [ebp + 0xc]
call fcn.00401ed0
mov dword [ebp - 4], 0xffffffff
lea ecx, [ebp + 0x10]
call fcn.00401ed0
mov eax, dword [ebp - 0x3c]
jmp 0x4c71f5
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0xc