Function at 0x414f90
Capabilities:
Check if file exists
Copy file
Delete directory
Delete file
Move file
Set file attributes

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x4f9400
mov eax, dword fs:[0]
push eax
sub esp, 0x30
mov eax, dword [0x5365f0]
xor eax, ebp
mov dword [ebp - 0x10], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
push str.CAEEngine::CopyWinOSConfigToInstallLoc__.__Inside_CopyWinOSConfigToInstallLoc__
mov ecx, 0x53a2b8
call fcn.004015d0
mov eax, dword [0x5361b4]
mov edx, dword [eax + 0xc]
xor edi, edi
add esp, 4
mov ecx, 0x5361b4
mov dword [ebp - 0x3c], edi
call edx
add eax, 0x10
mov dword [ebp - 0x38], eax
mov ebx, 1
mov dword [ebp - 4], ebx
mov eax, dword [0x5361b4]
mov edx, dword [eax + 0xc]
mov ecx, 0x5361b4
call edx
lea esi, [eax + 0x10]
mov dword [ebp - 0x34], esi
mov byte [ebp - 4], 3
lea ecx, [ebp - 0x30]
mov dword [ebp - 0x30], edi
call fcn.00462560
test eax, eax
jne 0x415051
push str.CAEEngine::CopyWinOSConfigToInstallLoc__.__GetStorageSpaceConfigPath...Failed
mov ecx, 0x53a2b8
call fcn.004015d0
add esp, 4
mov byte [ebp - 4], bl
lea eax, [esi - 0x10]
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x41531d
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
jmp 0x41531d
mov edi, dword [ebp - 0x30]
test edi, edi
jne 0x41505c
xor eax, eax
jmp 0x415070
mov eax, edi
lea edx, [eax + 2]
mov cx, word [eax]
add eax, 2
test cx, cx
jne 0x415061
sub eax, edx
sar eax, 1
push edi
lea ecx, [ebp - 0x34]
push ecx
mov ebx, eax
call fcn.00402a30
push 0xb
push str._tempWinOS_
lea ebx, [ebp - 0x34]
call fcn.00402da0
mov ecx, dword [ebp - 0x34]
mov esi, dword [ebp - 0x38]
lea eax, [ecx - 0x10]
add esi, 0xfffffff0
cmp eax, esi
je 0x4150df
cmp dword [esi + 0xc], 0
lea ebx, [esi + 0xc]
jl 0x4150d2
mov edx, dword [eax]
cmp edx, dword [esi]
jne 0x4150d2
call fcn.00402ae0
mov edi, eax
or eax, 0xffffffff
lock xadd dword [ebx], eax
dec eax
test eax, eax
jg 0x4150c7
mov ecx, dword [esi]
mov edx, dword [ecx]
mov eax, dword [edx + 4]
push esi
call eax
add edi, 0x10
mov dword [ebp - 0x38], edi
mov edi, dword [ebp - 0x30]
jmp 0x4150df
mov ebx, dword [ecx - 0xc]
push ecx
lea ecx, [ebp - 0x38]
push ecx
call fcn.00402a30
push 0x11
push str.AEWinOsConfig.xml
lea ebx, [ebp - 0x34]
call fcn.00402da0
push edi
call fcn.004d632b
mov edi, dword [ebp - 0x34]
add esp, 4
push edi
call dword [sym.imp.SHLWAPI.dll_PathFileExistsW]
test eax, eax
jne 0x415130
push str.CAEEngine::CopyWinOSConfigToInstallLoc__._PathFileExists_failed
mov ecx, 0x53a2b8
call fcn.004015d0
add esp, 4
mov byte [ebp - 4], 1
lea eax, [edi - 0x10]
lea edx, [eax + 0xc]
or ecx, 0xffffffff
lock xadd dword [edx], ecx
dec ecx
test ecx, ecx
jmp 0x41503c
mov edx, dword [0x5361b4]
mov eax, dword [edx + 0xc]
mov ecx, 0x5361b4
call eax
lea esi, [eax + 0x10]
mov dword [ebp - 0x30], esi
mov byte [ebp - 4], 7
lea ebx, [ebp - 0x2c]
call fcn.004329e0
mov byte [ebp - 4], 8
cmp dword [ebp - 0x1c], 0
mov ecx, ebx
jne 0x415165
call fcn.004476a0
jmp 0x415171
push 1
mov eax, 0x504a74
call fcn.004021b0
cmp dword [ebp - 0x1c], 0
je 0x4151b8
cmp dword [ebp - 0x18], 8
jb 0x415188
mov eax, dword [ebp - 0x2c]
mov edx, eax
test eax, eax
jne 0x41518b
jmp 0x41519f
lea edx, [ebp - 0x2c]
mov eax, edx
lea esi, [eax + 2]
mov cx, word [eax]
add eax, 2
test cx, cx
jne 0x415190
sub eax, esi
sar eax, 1
push eax
push edx
lea ebx, [ebp - 0x30]
call fcn.00402da0
push 0x11
push str.AEWinOsConfig.xml
call fcn.00402da0
mov esi, dword [ebp - 0x30]
mov ebx, dword [sym.imp.KERNEL32.dll_SetFileAttributesW]
push 0x80
push edi
call ebx
push esi
push edi
push str.CAEEngine::CopyWinOSConfigToInstallLoc__._Going_to_Copy_file_from__s_to__s
mov ecx, 0x53a2b8
call fcn.004015d0
add esp, 0xc
push 0
push esi
push edi
call dword [sym.imp.KERNEL32.dll_CopyFileW]
test eax, eax
je 0x41529a
push str.CAEEngine::CopyWinOSConfigToInstallLoc__._Copy_Sucess___
mov ecx, 0x53a2b8
call fcn.004015d0
add esp, 4
push 0x80
push edi
call ebx
push edi
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
test eax, eax
jne 0x415235
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push str.CAEEngine::CopyWinOSConfigToInstallLoc__._Failed_to_Delete____error__d
mov ecx, 0x53a2b8
call fcn.004015d0
add esp, 8
push 4
push 0
push edi
call dword [sym.imp.KERNEL32.dll_MoveFileExW]
push str.CAEEngine::CopyWinOSConfigToInstallLoc__._ALL_Success
mov ecx, 0x53a2b8
call fcn.004015d0
mov ebx, 7
add esp, 4
mov dword [ebp - 0x3c], 1
mov byte [ebp - 4], bl
cmp dword [ebp - 0x18], 8
jb 0x415268
mov ecx, dword [ebp - 0x2c]
push ecx
call fcn.004d5559
add esp, 4
xor edx, edx
mov dword [ebp - 0x18], ebx
mov dword [ebp - 0x1c], 0
mov word [ebp - 0x2c], dx
mov byte [ebp - 4], 3
add esi, 0xfffffff0
lea eax, [esi + 0xc]
or ecx, 0xffffffff
lock xadd dword [eax], ecx
dec ecx
test ecx, ecx
jg 0x415298
mov ecx, dword [esi]
mov edx, dword [ecx]
mov eax, dword [edx + 4]
push esi
call eax
jmp 0x4152fd
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push str.CAEEngine::CopyWinOSConfigToInstallLoc__._Failed_to_copy____error__d
mov ecx, 0x53a2b8
call fcn.004015d0
mov ebx, 7
add esp, 8
mov byte [ebp - 4], bl
cmp dword [ebp - 0x18], 8
jb 0x4152cd
mov eax, dword [ebp - 0x2c]
push eax
call fcn.004d5559
add esp, 4
xor ecx, ecx
mov dword [ebp - 0x18], ebx
mov dword [ebp - 0x1c], 0
mov word [ebp - 0x2c], cx
mov byte [ebp - 4], 3
add esi, 0xfffffff0
lea edx, [esi + 0xc]
or eax, 0xffffffff
lock xadd dword [edx], eax
dec eax
test eax, eax
jg 0x4152fd
mov ecx, dword [esi]
mov edx, dword [ecx]
mov eax, dword [edx + 4]
push esi
call eax
mov byte [ebp - 4], 1
add edi, 0xfffffff0
or edx, 0xffffffff
lea ecx, [edi + 0xc]
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x41531d
mov ecx, dword [edi]
mov eax, dword [ecx]
mov edx, dword [eax + 4]
push edi
call edx
mov esi, dword [ebp - 0x38]
push esi
call dword [sym.imp.KERNEL32.dll_RemoveDirectoryW]
mov dword [ebp - 4], 0xffffffff
lea eax, [esi - 0x10]
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x41534a
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov eax, dword [ebp - 0x3c]
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.004d5564
mov esp, ebp
pop ebp
ret