Function at 0x40e8d0
Capabilities:
Check if file exists
Copy file
Delete file
Get common file path
Get disk information
Set file attributes

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x54758b
mov eax, dword fs:[0]
push eax
sub esp, 0xcc
mov eax, dword [0x5a10e0]
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
mov eax, dword [ebp + 0x24]
mov ebx, ecx
xor edx, edx
mov dword [ebp - 0x94], ebx
mov dword [ebp - 0x90], eax
mov dword [ebp - 0x98], edx
mov dword [ebp - 4], edx
mov dword [eax], edx
mov ecx, 8
mov esi, str.__overrideFile_
lea edi, [ebp - 0xd8]
rep movsd dword es:[edi], dword [esi]
xor eax, eax
movsw word es:[edi], word [esi]
mov dword [ebp - 0xb6], eax
mov dword [ebp - 0xb2], eax
mov dword [ebp - 0xae], eax
mov dword [ebp - 0xaa], eax
mov dword [ebp - 0xa6], eax
mov dword [ebp - 0xa2], eax
mov dword [ebp - 0x9e], eax
mov word [ebp - 0x9a], ax
lea eax, [ebp - 0xd8]
lea esi, [eax + 2]
lea esp, [esp]
mov cx, word [eax]
add eax, 2
cmp cx, dx
jne 0x40e970
sub eax, esi
sar eax, 1
mov ecx, eax
push 0xffffffffffffffff
lea eax, [ebp - 0x54]
lea edx, [ebp + 8]
call fcn.00411550
mov byte [ebp - 4], 1
mov eax, dword [ebp - 0x44]
dec eax
push eax
xor ecx, ecx
lea eax, [ebp - 0x8c]
lea edx, [ebp - 0x54]
call fcn.00411550
mov edi, eax
lea esi, [ebp - 0x54]
mov byte [ebp - 4], 2
call fcn.00404200
mov esi, 8
mov byte [ebp - 4], 1
cmp dword [ebp - 0x78], esi
jb 0x40e9d2
mov ecx, dword [ebp - 0x8c]
push ecx
call fcn.004166f8
add esp, 4
xor edx, edx
push edx
lea eax, [ebp - 0x54]
push eax
or eax, 0xffffffff
lea edi, [ebp - 0x8c]
mov dword [ebp - 0x78], 7
mov dword [ebp - 0x7c], 0
mov word [ebp - 0x8c], dx
call fcn.004015e0
mov eax, dword [ebp - 0x8c]
cmp dword [ebp - 0x78], esi
jae 0x40ea09
mov eax, edi
push eax
call dword [sym.imp.SHLWAPI.dll_PathGetDriveNumberW]
add eax, 0x41
push eax
lea ecx, [ebp - 0x1c]
push str._c:_
push ecx
call fcn.00516945
add esp, 0xc
lea edx, [ebp - 0x1c]
push edx
call dword [sym.imp.KERNEL32.dll_GetDriveTypeW]
xor ecx, ecx
cmp eax, 3
setne cl
mov edi, ecx
cmp dword [ebp - 0x78], esi
jb 0x40ea4d
mov edx, dword [ebp - 0x8c]
push edx
call fcn.004166f8
add esp, 4
xor esi, esi
cmp edi, esi
jne 0x40eab6
mov eax, dword [ebp - 0x90]
mov dword [eax], esi
mov dword [ebx + 0x10], esi
xor ecx, ecx
mov dword [ebx + 0x14], 7
lea edi, [ebp - 0x54]
mov esi, ebx
mov word [ebx], cx
call fcn.00404200
mov esi, 8
cmp dword [ebp - 0x40], esi
jb 0x40ea8a
mov edx, dword [ebp - 0x54]
push edx
call fcn.004166f8
add esp, 4
xor eax, eax
mov dword [ebp - 0x40], 7
mov dword [ebp - 0x44], 0
mov word [ebp - 0x54], ax
cmp dword [ebp + 0x1c], esi
jb 0x40eaaf
mov ecx, dword [ebp + 8]
push ecx
call fcn.004166f8
add esp, 4
mov eax, ebx
jmp 0x40eccd
push 0x208
call fcn.00416703
add esp, 4
mov edi, eax
push edi
push 0x104
call dword [sym.imp.KERNEL32.dll_GetTempPathW]
push edi
call dword [sym.imp.SHLWAPI.dll_PathRemoveBackslashW]
xor edx, edx
push esi
mov eax, 0x576984
lea ecx, [ebp - 0x70]
mov dword [ebp - 0x5c], 7
mov dword [ebp - 0x60], esi
mov word [ebp - 0x70], dx
call fcn.00403230
lea ebx, [ebp - 0x70]
mov byte [ebp - 4], 3
call fcn.0040dec0
xor eax, eax
mov word [ebp - 0x38], ax
mov eax, edi
mov dword [ebp - 0x24], 7
mov dword [ebp - 0x28], 0
lea edx, [eax + 2]
jmp 0x40eb20
mov cx, word [eax]
add eax, 2
test cx, cx
jne 0x40eb20
sub eax, edx
sar eax, 1
push eax
mov eax, edi
lea ecx, [ebp - 0x38]
call fcn.00403230
push 1
mov eax, 0x5770cc
lea ecx, [ebp - 0x38]
mov byte [ebp - 4], 4
call fcn.004089c0
mov eax, dword [ebp - 0x70]
mov ebx, 8
cmp dword [ebp - 0x5c], ebx
jae 0x40eb5d
lea eax, [ebp - 0x70]
mov ecx, eax
lea esi, [ecx + 2]
mov dx, word [ecx]
add ecx, 2
test dx, dx
jne 0x40eb62
sub ecx, esi
sar ecx, 1
push ecx
lea ecx, [ebp - 0x38]
call fcn.004089c0
push 0xa
mov eax, str..Overrides
lea ecx, [ebp - 0x38]
call fcn.004089c0
mov eax, dword [ebp - 0x38]
cmp dword [ebp - 0x24], ebx
jae 0x40eb94
lea eax, [ebp - 0x38]
push eax
call dword [sym.imp.SHLWAPI.dll_PathFileExistsW]
test eax, eax
je 0x40ebc5
mov eax, dword [ebp - 0x38]
cmp dword [ebp - 0x24], ebx
jae 0x40ebaa
lea eax, [ebp - 0x38]
push 0
push eax
call dword [sym.imp.KERNEL32.dll_SetFileAttributesW]
mov eax, dword [ebp - 0x38]
cmp dword [ebp - 0x24], ebx
jae 0x40ebbe
lea eax, [ebp - 0x38]
push eax
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
mov ecx, dword [ebp - 0x38]
cmp dword [ebp - 0x24], ebx
jae 0x40ebd0
lea ecx, [ebp - 0x38]
mov eax, dword [ebp - 0x54]
cmp dword [ebp - 0x40], ebx
jae 0x40ebdb
lea eax, [ebp - 0x54]
push 1
push ecx
push eax
call dword [sym.imp.KERNEL32.dll_CopyFileW]
test eax, eax
je 0x40ec1f
mov ecx, dword [ebp - 0x90]
mov eax, dword [ebp - 0x38]
mov dword [ecx], 1
cmp dword [ebp - 0x24], ebx
jae 0x40ec00
lea eax, [ebp - 0x38]
mov ecx, eax
lea esi, [ecx + 2]
mov dx, word [ecx]
add ecx, 2
test dx, dx
jne 0x40ec05
sub ecx, esi
sar ecx, 1
push ecx
lea ecx, [ebp - 0x54]
call fcn.00403230
jmp 0x40ec2b
mov edx, dword [ebp - 0x90]
mov dword [edx], 0
push edi
call fcn.004166f8
mov esi, dword [ebp - 0x94]
xor eax, eax
mov dword [esi + 0x14], 7
mov dword [esi + 0x10], 0
add esp, 4
lea edi, [ebp - 0x54]
mov word [esi], ax
call fcn.00404200
cmp dword [ebp - 0x24], ebx
jb 0x40ec66
mov ecx, dword [ebp - 0x38]
push ecx
call fcn.004166f8
add esp, 4
xor edi, edi
xor edx, edx
mov dword [ebp - 0x24], 7
mov dword [ebp - 0x28], edi
mov word [ebp - 0x38], dx
cmp dword [ebp - 0x5c], ebx
jb 0x40ec89
mov eax, dword [ebp - 0x70]
push eax
call fcn.004166f8
add esp, 4
xor ecx, ecx
mov dword [ebp - 0x5c], 7
mov dword [ebp - 0x60], edi
mov word [ebp - 0x70], cx
cmp dword [ebp - 0x40], ebx
jb 0x40ecaa
mov edx, dword [ebp - 0x54]
push edx
call fcn.004166f8
add esp, 4
xor eax, eax
mov dword [ebp - 0x40], 7
mov dword [ebp - 0x44], edi
mov word [ebp - 0x54], ax
cmp dword [ebp + 0x1c], ebx
jb 0x40eccb
mov ecx, dword [ebp + 8]
push ecx
call fcn.004166f8
add esp, 4
mov eax, esi
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.00515d64
mov esp, ebp
pop ebp
ret 0x20