Function at 0x409ec0
Capabilities:
Check if file exists
Copy file
Get common file path
Get file attributes

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x45cfa0
mov eax, dword fs:[0]
push eax
sub esp, 0x408
mov eax, dword [0x483ca0]
xor eax, ebp
mov dword [ebp - 0x14], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov dword [ebp - 0x10], esp
mov esi, ecx
lea edi, [esi + 0x800]
mov dword [ebp - 4], 0
mov ecx, 0x463384
mov eax, edi
mov dl, byte [eax]
cmp dl, byte [ecx]
jne 0x409f27
test dl, dl
je 0x409f23
mov dl, byte [eax + 1]
cmp dl, byte [ecx + 1]
jne 0x409f27
add eax, 2
add ecx, 2
test dl, dl
jne 0x409f07
xor eax, eax
jmp 0x409f2c
sbb eax, eax
or eax, 1
test eax, eax
jne 0x409f43
mov ax, word [0x46338c]
mov word [esi], ax
mov al, byte [0x46338e]
mov byte [esi + 2], al
jmp 0x409f6e
cmp byte [esi], 0
jne 0x409f6e
lea eax, [ebp - 0x414]
push eax
push 0x200
call dword [sym.imp.KERNEL32.dll_GetTempPathW]
push 0x200
push esi
lea eax, [ebp - 0x414]
mov ecx, esi
push eax
call fcn.0040a430
mov dword [esi + 0x123c], 0xfa000
mov eax, 0x463384
lea ecx, [ecx]
mov cl, byte [edi]
cmp cl, byte [eax]
jne 0x409fa0
test cl, cl
je 0x409f9c
mov cl, byte [edi + 1]
cmp cl, byte [eax + 1]
jne 0x409fa0
add edi, 2
add eax, 2
test cl, cl
jne 0x409f80
xor eax, eax
jmp 0x409fa5
sbb eax, eax
or eax, 1
lea edi, [esi + 0x200]
test eax, eax
jne 0x40a02a
push str.RunServerLog
push esi
push str._s_s.txt
push edi
call fcn.0043a459
push str.RunServerLog
push esi
lea ebx, [esi + 0x400]
push str._s_s.bak
push ebx
call fcn.0043a459
push str.RunServerLog
push esi
lea eax, [esi + 0x600]
push str._s_s.bak.bak
push eax
call fcn.0043a459
mov edx, 0x486c40
add esp, 0x30
mov ecx, edi
sub edx, edi
lea ebx, [ebx]
mov al, byte [ecx]
lea ecx, [ecx + 1]
mov byte [edx + ecx - 1], al
test al, al
jne 0x40a000
push esi
lea eax, [esi + 0x124c]
push str._sServerMemoryLog.txt
push eax
call fcn.0043a459
push esi
push str._sServerMemoryLog.bak
jmp 0x40a0ec
cmp byte [edi], 0
jne 0x40a073
push str.rsp1024h
push esi
push str._s_s.txt
push edi
call fcn.0043a459
push str.rsp1024h
push esi
lea ebx, [esi + 0x400]
push str._s_s.bak
push ebx
call fcn.0043a459
push str.rsp1024h
push esi
lea eax, [esi + 0x600]
push str._s_s.bak.bak
push eax
call fcn.0043a459
add esp, 0x30
jmp 0x40a0be
push edi
push esi
lea ebx, [esi + 0x400]
push str._s_s
push ebx
call fcn.0043a459
mov edx, edi
add esp, 0x10
mov ecx, ebx
sub edx, ebx
nop
mov al, byte [ecx]
lea ecx, [ecx + 1]
mov byte [edx + ecx - 1], al
test al, al
jne 0x40a090
push edi
push str._s.bak
push ebx
call fcn.0043a459
push edi
lea eax, [esi + 0x600]
push str._s.bak.bak
push eax
call fcn.0043a459
add esp, 0x18
mov edx, 0x486c40
mov ecx, edi
sub edx, edi
mov al, byte [ecx]
lea ecx, [ecx + 1]
mov byte [edx + ecx - 1], al
test al, al
jne 0x40a0c7
push esi
lea eax, [esi + 0x124c]
push str._sClientMemoryLog.txt
push eax
call fcn.0043a459
push esi
push str._sClientMemoryLog.bak
lea eax, [esi + 0x144c]
push eax
call fcn.0043a459
add esp, 0x18
lea eax, [esi + 0x164c]
mov ecx, esi
push 0x200
push eax
push edi
call fcn.0040a4a0
push 0x200
lea eax, [esi + 0x1a4c]
mov ecx, esi
push eax
push ebx
call fcn.0040a4a0
push 0x200
lea eax, [esi + 0x1e4c]
mov ecx, esi
push eax
lea eax, [esi + 0x600]
push eax
call fcn.0040a4a0
push 0x200
lea eax, [esi + 0x224c]
mov ecx, esi
push eax
lea eax, [esi + 0x124c]
push eax
call fcn.0040a4a0
push 0x200
lea eax, [esi + 0x264c]
mov ecx, esi
push eax
lea eax, [esi + 0x144c]
push eax
call fcn.0040a4a0
lea ebx, [esi + 0x1a4c]
push ebx
call dword [sym.imp.KERNEL32.dll_GetFileAttributesW]
cmp eax, 0xffffffff
je 0x40a197
push 0
lea eax, [esi + 0x1e4c]
push eax
push ebx
mov ebx, dword [sym.imp.KERNEL32.dll_CopyFileW]
call ebx
jmp 0x40a19d
mov ebx, dword [sym.imp.KERNEL32.dll_CopyFileW]
lea eax, [esi + 0x164c]
push eax
call dword [sym.imp.KERNEL32.dll_GetFileAttributesW]
cmp eax, 0xffffffff
je 0x40a1c1
push 0
lea eax, [esi + 0x1a4c]
push eax
lea eax, [esi + 0x164c]
push eax
call ebx
lea eax, [esi + 0x164c]
push 0x462720
push eax
call fcn.0043a8ac
add esp, 8
mov dword [esi + 0x1204], eax
test eax, eax
jne 0x40a261
mov dword [0x486e40], 3
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
mov esi, eax
push esi
call fcn.004031d0
add esp, 4
push eax
push esi
push edi
push str.failed_to_create_log_file__s_in_MyLog::GetWorkingDirectory_____d
push 0x486e48
call fcn.0043a459
add esp, 0x14
xor al, al
jmp 0x40a26c
push eax
call fcn.0043a309
add esp, 4
mov al, 1
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 0x14]
xor ecx, ebp
call fcn.004396df
mov esp, ebp
pop ebp
ret