Function at 0x409c60
Capabilities:
Check if file exists
Copy file
Delete file
Encode data using xor
Get file attributes
Read file on windows

Disassembly:
sub esp, 0x22c
push ebx
push ebp
push esi
mov esi, dword [sym.imp.MSVCRT.dll__snprintf]
push edi
push 0x5965b8
push str._sprofiles_accounts.ini
lea eax, [esp + 0x144]
xor ebx, ebx
push 0xff
mov ebp, ecx
push eax
mov byte [esp + 0x23], bl
call esi
add esp, 0x10
lea ecx, [esp + 0x3c]
push 0x5965b8
push str._sconfig_accounts.ini
push 0xff
push ecx
call esi
add esp, 0x10
lea edx, [esp + 0x13c]
push edx
call dword [sym.imp.KERNEL32.dll_GetFileAttributesA]
cmp eax, 0xffffffff
je 0x409ce2
lea eax, [esp + 0x3c]
push ebx
lea ecx, [esp + 0x140]
push eax
push ecx
call dword [sym.imp.KERNEL32.dll_CopyFileA]
lea edx, [esp + 0x13c]
push edx
call dword [sym.imp.KERNEL32.dll_DeleteFileA]
push ebp
call dword [sym.imp.KERNEL32.dll_EnterCriticalSection]
push 0x5965b8
lea edi, [ebp + 0x18]
push str._sconfig_accounts.ini
lea eax, [esp + 0x44]
push 0xff
push eax
mov dword [edi], ebx
mov dword [ebp + 0x20], ebx
call esi
lea ecx, [esp + 0x4c]
push 0x581660
push ecx
call dword [sym.imp.MSVCRT.dll_fopen]
mov esi, eax
add esp, 0x18
cmp esi, ebx
mov dword [esp + 0x14], esi
je 0x409f59
cmp dword [ebp + 0x1c], ebx
je 0x409f4f
push esi
push 1
push 4
push edi
call dword [sym.imp.MSVCRT.dll_fread]
add esp, 0x10
cmp eax, 1
jne 0x409d99
cmp dword [edi], 0x190
je 0x409d5b
push ebx
push ebx
push esi
call dword [sym.imp.MSVCRT.dll_fseek]
add esp, 0xc
jmp 0x409d99
push esi
push 1
lea edx, [esp + 0x24]
push 0x10
push edx
call dword [sym.imp.MSVCRT.dll_fread]
lea eax, [esp + 0x4c]
push 0x1e240
push eax
call fcn.00409920
add esp, 0x18
mov ecx, 4
lea edi, [esp + 0x1c]
lea esi, [esp + 0x3c]
xor edx, edx
repe cmpsd dword [esi], dword es:[edi]
je 0x409d95
mov byte [esp + 0x13], 1
mov esi, dword [esp + 0x14]
mov ecx, dword [ebp + 0x20]
push esi
push 1
push 0x37a0
lea eax, [ecx + ecx*4]
lea eax, [eax + eax*8]
shl eax, 1
sub eax, ecx
mov ecx, dword [ebp + 0x1c]
lea eax, [eax + eax*4]
shl eax, 5
add eax, ecx
push eax
call dword [sym.imp.MSVCRT.dll_fread]
add esp, 0x10
cmp eax, 1
jne 0x409f4f
mov ecx, dword [ebp + 0x20]
mov edi, dword [ebp + 0x1c]
mov edx, 0x37a0
lea eax, [ecx + ecx*4]
lea eax, [eax + eax*8]
shl eax, 1
sub eax, ecx
lea ecx, [eax + eax*4]
shl ecx, 5
add ecx, edi
call fcn.004339d0
mov ecx, dword [ebp + 0x20]
mov edx, dword [ebp + 0x1c]
lea eax, [ecx + ecx*4]
lea eax, [eax + eax*8]
shl eax, 1
sub eax, ecx
lea ecx, [eax + eax*4]
shl ecx, 5
mov byte [ecx + edx + 0xd7], bl
mov ecx, dword [ebp + 0x20]
lea eax, [ecx + ecx*4]
lea eax, [eax + eax*8]
shl eax, 1
sub eax, ecx
mov ecx, dword [ebp + 0x1c]
lea eax, [eax + eax*4]
shl eax, 5
mov byte [eax + ecx + 0x97], bl
mov ecx, dword [ebp + 0x20]
lea eax, [ecx + ecx*4]
lea eax, [eax + eax*8]
shl eax, 1
sub eax, ecx
lea edx, [eax + eax*4]
mov eax, dword [ebp + 0x1c]
shl edx, 5
mov byte [edx + eax + 0x233], bl
mov ecx, dword [ebp + 0x20]
mov edx, dword [ebp + 0x1c]
lea eax, [ecx + ecx*4]
lea eax, [eax + eax*8]
shl eax, 1
sub eax, ecx
lea ecx, [eax + eax*4]
shl ecx, 5
mov byte [ecx + edx + 0x17], bl
mov ecx, dword [ebp + 0x20]
lea eax, [ecx + ecx*4]
lea eax, [eax + eax*8]
shl eax, 1
sub eax, ecx
mov ecx, dword [ebp + 0x1c]
lea eax, [eax + eax*4]
shl eax, 5
lea esi, [eax + ecx]
mov eax, dword [eax + ecx + 4]
cmp eax, 1
jl 0x409f48
cmp byte [esi + 0x98], bl
je 0x409f48
fld qword [esi + 0x178]
fcomp qword [0x565ac0]
fnstsw ax
test ah, 1
jne 0x409f48
cmp dword [ebp + 0x18], 0x190
je 0x409ef0
mov edx, dword [esi + 4]
lea eax, [esp + 0x2c]
push edx
push eax
mov dword [esp + 0x20], ebx
call fcn.00409920
add esp, 8
xor eax, eax
mov ecx, eax
and ecx, 0xf
mov dl, byte [esp + ecx + 0x2c]
mov cl, byte [esp + 0x18]
add dl, cl
mov cl, byte [eax + esi + 8]
xor cl, dl
mov byte [eax + esi + 8], cl
inc eax
movsx ecx, cl
cmp eax, 0x10
mov dword [esp + 0x18], ecx
jb 0x409ec8
jmp 0x409f06
cmp byte [esp + 0x13], bl
je 0x409f06
xor edx, edx
add esi, 8
mov dword [esi], edx
mov dword [esi + 4], edx
mov dword [esi + 8], edx
mov dword [esi + 0xc], edx
mov ecx, dword [ebp + 0x20]
inc ecx
cmp ecx, 0x40
mov dword [ebp + 0x20], ecx
jge 0x409f4b
mov eax, dword [esp + 0x14]
mov edi, dword [ebp + 0x1c]
push eax
lea eax, [ecx + ecx*4]
push 1
push 0x37a0
lea eax, [eax + eax*8]
shl eax, 1
sub eax, ecx
lea ecx, [eax + eax*4]
shl ecx, 5
add ecx, edi
push ecx
call dword [sym.imp.MSVCRT.dll_fread]
add esp, 0x10
cmp eax, 1
je 0x409dcc
jmp 0x409f4b
mov dword [ebp + 0x20], ebx
mov esi, dword [esp + 0x14]
push esi
call dword [sym.imp.MSVCRT.dll_fclose]
add esp, 4
push ebp
mov dword [ebp + 0x18], 0x190
call dword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x22c
ret