Function at 0x180007ac4
Capabilities:
Check if file exists
Get common file path
Read .ini file

Disassembly:
push rbp
sub rsp, 0x3d0
lea rbp, [rsp + 0x30]
mov qword [rsp], rax
mov rax, 0x3cc
mov dword [rsp + rax], 0xcccccccc
sub rax, 4
cmp rax, 4
jg 0x180007adc
mov rax, qword [rsp]
mov dword [rsp], 0xcccccccc
mov dword [rsp + 4], 0xcccccccc
mov qword [rbp + 0x140], rsi
mov qword [rbp + 0x138], rbx
mov qword [rbp + 0x3b0], rcx
mov rax, qword [0x1800f4ae8]
xor rax, rbp
mov qword [rbp + 0x390], rax
mov byte [rbp + 0x28], 0
mov byte [rbp + 0x2a], 0
mov byte [rbp + 0x29], 0
mov dword [rbp + 0x2c], 0
mov rax, qword [sym.imp.KERNEL32.dll_GetCurrentThread]
call rax
mov qword [rbp + 0x88], rax
mov byte [rbp + 0x28], 1
mov rax, qword [rbp + 0x88]
mov edx, 8
mov ecx, 1
lea rbx, [rbp + 0x18]
mov rsi, qword [sym.imp.ADVAPI32.dll_OpenThreadToken]
mov dword [rbp + 0xf0], ecx
mov rcx, rax
mov eax, dword [rbp + 0xf0]
mov r8d, eax
mov r9, rbx
call rsi
mov dword [rbp + 0x30], eax
mov byte [rbp + 0x29], 1
mov eax, dword [rbp + 0x30]
mov dword [rbp + 0x34], eax
movzx eax, byte [rbp + 0x29]
test eax, eax
jne 0x180007ba4
lea rax, [0x1801011ac]
mov rcx, rax
call fcn.180064a90
mov eax, dword [rbp + 0x34]
test eax, eax
jne 0x180007c0f
mov rax, qword [sym.imp.KERNEL32.dll_GetLastError]
call rax
mov dword [rbp + 0x38], eax
mov eax, dword [rbp + 0x38]
cmp eax, 0x3f0
jne 0x180007c0f
mov rax, qword [sym.imp.KERNEL32.dll_GetCurrentProcess]
call rax
mov qword [rbp + 0x90], rax
mov byte [rbp + 0x28], 1
mov rax, qword [rbp + 0x90]
mov edx, 8
lea rcx, [rbp + 0x18]
mov rbx, qword [sym.imp.ADVAPI32.dll_OpenProcessToken]
mov qword [rbp + 0xf8], rcx
mov rcx, rax
mov rax, qword [rbp + 0xf8]
mov r8, rax
call rbx
mov dword [rbp + 0x3c], eax
mov byte [rbp + 0x29], 1
mov eax, dword [rbp + 0x3c]
mov dword [rbp + 0x34], eax
movzx eax, byte [rbp + 0x29]
test eax, eax
jne 0x180007c26
lea rax, [0x1801011ac]
mov rcx, rax
call fcn.180064a90
mov eax, dword [rbp + 0x34]
test eax, eax
jne 0x180007c73
mov eax, 0
mov dword [rbp + 0x74], eax
lea rax, reloc.WS2_32.dll_getpeername
mov rdx, rax
mov rcx, rbp
call fcn.180061140
mov rax, qword [rbp + 0x390]
xor rax, rbp
mov rcx, rax
call fcn.1800612f0
mov eax, dword [rbp + 0x74]
mov rbx, qword [rbp + 0x138]
mov rsi, qword [rbp + 0x140]
lea rsp, [rbp + 0x3a0]
pop rbp
ret
mov byte [rbp + 0x2a], 1
mov dword [rbp + 8], 0x104
movzx eax, byte [rbp + 0x28]
test eax, eax
jne 0x180007c95
lea rax, [0x1801011b0]
mov rcx, rax
call fcn.180064a90
mov byte [rbp + 0x2a], 1
mov rax, qword [rbp + 0x18]
lea rdx, [rbp + 0x150]
lea rcx, [rbp + 8]
mov rbx, qword [sym.imp.USERENV.dll_GetUserProfileDirectoryA]
mov qword [rbp + 0x100], rcx
mov rcx, rax
mov rax, qword [rbp + 0x100]
mov r8, rax
call rbx
mov dword [rbp + 0x40], eax
mov eax, dword [rbp + 0x40]
test eax, eax
jne 0x180007d3f
movzx eax, byte [rbp + 0x28]
test eax, eax
jne 0x180007ce6
lea rax, [0x1801011b0]
mov rcx, rax
call fcn.180064a90
mov rax, qword [rbp + 0x18]
mov rdx, qword [sym.imp.KERNEL32.dll_CloseHandle]
mov rcx, rax
call rdx
mov dword [rbp + 0x44], eax
mov eax, 0
mov dword [rbp + 0x78], eax
lea rax, reloc.WS2_32.dll_getpeername
mov rdx, rax
mov rcx, rbp
call fcn.180061140
mov rax, qword [rbp + 0x390]
xor rax, rbp
mov rcx, rax
call fcn.1800612f0
mov eax, dword [rbp + 0x78]
mov rbx, qword [rbp + 0x138]
mov rsi, qword [rbp + 0x140]
lea rsp, [rbp + 0x3a0]
pop rbp
ret
movzx eax, byte [rbp + 0x28]
test eax, eax
jne 0x180007d56
lea rax, [0x1801011b0]
mov rcx, rax
call fcn.180064a90
mov rax, qword [rbp + 0x18]
mov rdx, qword [sym.imp.KERNEL32.dll_CloseHandle]
mov rcx, rax
call rdx
mov dword [rbp + 0x48], eax
mov rax, qword [rbp + 0x3b0]
lea rax, [rax + 0x10c]
lea rdx, [rbp + 0x150]
mov rcx, rax
call fcn.180067120
mov qword [rbp + 0x98], rax
mov rax, qword [rbp + 0x3b0]
lea rax, [rax + 0x10c]
lea rdx, [0x1801011b6]
mov rcx, rax
call fcn.180067080
mov qword [rbp + 0xa0], rax
mov rax, qword [rbp + 0x3b0]
lea rax, [rax + 0x10c]
lea rdx, [0x1801011b8]
mov rcx, rax
call fcn.180067080
mov qword [rbp + 0xa8], rax
mov rax, qword [rbp + 0x3b0]
lea rax, [rax + 0x10c]
lea rdx, [0x1801011d9]
mov rcx, rax
call fcn.180067080
mov qword [rbp + 0xb0], rax
mov rax, qword [rbp + 0x3b0]
lea rax, [rax + 0x10c]
mov rdx, qword [sym.imp.KERNEL32.dll_GetFileAttributesA]
mov rcx, rax
call rdx
mov dword [rbp + 0x4c], eax
mov eax, dword [rbp + 0x4c]
cmp eax, 0xffffffff
jne 0x180007e64
mov eax, 0
mov dword [rbp + 0x7c], eax
lea rax, reloc.WS2_32.dll_getpeername
mov rdx, rax
mov rcx, rbp
call fcn.180061140
mov rax, qword [rbp + 0x390]
xor rax, rbp
mov rcx, rax
call fcn.1800612f0
mov eax, dword [rbp + 0x7c]
mov rbx, qword [rbp + 0x138]
mov rsi, qword [rbp + 0x140]
lea rsp, [rbp + 0x3a0]
pop rbp
ret
mov rax, qword [rbp + 0x3b0]
lea rax, [rax + 0x210]
lea rdx, [rbp + 0x150]
mov rcx, rax
call fcn.180067120
mov qword [rbp + 0xb8], rax
mov rax, qword [rbp + 0x3b0]
lea rax, [rax + 0x210]
lea rdx, [0x1801011e7]
mov rcx, rax
call fcn.180067080
mov qword [rbp + 0xc0], rax
mov rax, qword [rbp + 0x3b0]
lea rax, [rax + 0x210]
lea rdx, [0x1801011e9]
mov rcx, rax
call fcn.180067080
mov qword [rbp + 0xc8], rax
lea rax, [0x18010120a]
lea rdx, [0x180101212]
mov ecx, 1
mov rbx, qword [rbp + 0x3b0]
lea rbx, [rbx + 0x10c]
mov rsi, qword [sym.imp.KERNEL32.dll_GetPrivateProfileIntA]
mov dword [rbp + 0x108], ecx
mov rcx, rax
mov eax, dword [rbp + 0x108]
mov r8d, eax
mov r9, rbx
call rsi
mov dword [rbp + 0x50], eax
mov eax, dword [rbp + 0x50]
mov dword [rbp + 0x54], eax
lea rax, [rbp + 0x25c]
lea rdx, [0x180101227]
mov ecx, dword [rbp + 0x54]
mov dword [rbp + 0x110], ecx
mov rcx, rax
mov eax, dword [rbp + 0x110]
mov r8d, eax
call fcn.1800674d0
mov dword [rbp + 0x58], eax
lea rax, [rbp + 0x25c]
lea rdx, [0x180101231]
mov ecx, 1
mov rbx, qword [rbp + 0x3b0]
lea rbx, [rbx + 0x10c]
mov rsi, qword [sym.imp.KERNEL32.dll_GetPrivateProfileIntA]
mov dword [rbp + 0x118], ecx
mov rcx, rax
mov eax, dword [rbp + 0x118]
mov r8d, eax
mov r9, rbx
call rsi
mov dword [rbp + 0x5c], eax
mov eax, dword [rbp + 0x5c]
mov dword [rbp + 0x60], eax
lea rax, [rbp + 0x25c]
lea rdx, [0x18010123c]
lea rcx, [0x180101241]
lea rbx, [rbp + 0x284]
mov dword [rsp + 0x20], 0x104
mov rsi, qword [rbp + 0x3b0]
lea rsi, [rsi + 0x10c]
mov qword [rsp + 0x28], rsi
mov rsi, qword [sym.imp.KERNEL32.dll_GetPrivateProfileStringA]
mov qword [rbp + 0x120], rcx
mov rcx, rax
mov rax, qword [rbp + 0x120]
mov r8, rax
mov r9, rbx
call rsi
mov dword [rbp + 0x64], eax
mov byte [rbp + 0x29], 1
mov eax, dword [rbp + 0x64]
mov dword [rbp + 0x34], eax
movzx eax, byte [rbp + 0x29]
test eax, eax
jne 0x180008006
lea rax, [0x1801011ac]
mov rcx, rax
call fcn.180064a90
mov eax, dword [rbp + 0x34]
test eax, eax
jne 0x1800080bd
lea rax, [0x180101242]
lea rdx, [0x18010124b]
mov ecx, 1
mov rbx, qword [rbp + 0x3b0]
lea rbx, [rbx + 0x10c]
mov rsi, qword [sym.imp.KERNEL32.dll_GetPrivateProfileIntA]
mov dword [rbp + 0x128], ecx
mov rcx, rax
mov eax, dword [rbp + 0x128]
mov r8d, eax
mov r9, rbx
call rsi
mov dword [rbp + 0x68], eax
mov eax, dword [rbp + 0x68]
mov dword [rbp + 0x60], eax
lea rax, [0x180101256]
lea rdx, [0x18010125f]
lea rcx, [0x180101264]
lea rbx, [rbp + 0x284]
mov dword [rsp + 0x20], 0x104
mov rsi, qword [rbp + 0x3b0]
lea rsi, [rsi + 0x10c]
mov qword [rsp + 0x28], rsi
mov rsi, qword [sym.imp.KERNEL32.dll_GetPrivateProfileStringA]
mov qword [rbp + 0x130], rcx
mov rcx, rax
mov rax, qword [rbp + 0x130]
mov r8, rax
mov r9, rbx
call rsi
mov dword [rbp + 0x6c], eax
mov byte [rbp + 0x29], 1
mov eax, dword [rbp + 0x6c]
mov dword [rbp + 0x34], eax
movzx eax, byte [rbp + 0x29]
test eax, eax
jne 0x1800080d4
lea rax, [0x1801011ac]
mov rcx, rax
call fcn.180064a90
mov eax, dword [rbp + 0x34]
test eax, eax
jle 0x1800081bd
mov dword [rbp + 0x70], 0
lea rax, [rbp + 0x284]
mov rcx, rax
call fcn.180066b50
mov qword [rbp + 0xd0], rax
mov eax, dword [rbp + 0x70]
mov rdx, qword [rbp + 0xd0]
cmp rax, rdx
jae 0x180008141
lea rax, [rbp + 0x284]
mov edx, dword [rbp + 0x70]
add rax, rdx
movsx eax, byte [rax]
movsx rax, al
cmp eax, 0x2f
jne 0x180008134
lea rax, [rbp + 0x284]
mov edx, dword [rbp + 0x70]
add rax, rdx
mov byte [rax], 0x5c
mov eax, 1
add eax, dword [rbp + 0x70]
mov dword [rbp + 0x70], eax
jmp 0x1800080e6
mov eax, dword [rbp + 0x60]
test eax, eax
je 0x180008192
mov rax, qword [rbp + 0x3b0]
lea rax, [rax + 0x210]
lea rdx, [0x180101265]
mov rcx, rax
call fcn.180067080
mov qword [rbp + 0xd8], rax
mov rax, qword [rbp + 0x3b0]
lea rax, [rax + 0x210]
lea rdx, [rbp + 0x284]
mov rcx, rax
call fcn.180067080
mov qword [rbp + 0xe8], rax
jmp 0x1800081b6
mov rax, qword [rbp + 0x3b0]
lea rax, [rax + 0x210]
lea rdx, [rbp + 0x284]
mov rcx, rax
call fcn.180067120
mov qword [rbp + 0xe0], rax
mov dword [rbp + 0x2c], 1
mov eax, dword [rbp + 0x2c]
mov dword [rbp + 0x80], eax
lea rax, reloc.WS2_32.dll_getpeername
mov rdx, rax
mov rcx, rbp
call fcn.180061140
mov rax, qword [rbp + 0x390]
xor rax, rbp
mov rcx, rax
call fcn.1800612f0
mov eax, dword [rbp + 0x80]
mov rbx, qword [rbp + 0x138]
mov rsi, qword [rbp + 0x140]
lea rsp, [rbp + 0x3a0]
pop rbp
ret