Function at 0x407d60
Capabilities:
Get common file path
Read .ini file

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x50b78b
mov eax, dword fs:[0]
push eax
sub esp, 0x5b0
mov eax, dword [0x557460]
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 0x208
lea eax, [ebp - 0x298]
push 0
push eax
call fcn.004d49e0
add esp, 0xc
lea eax, [ebp - 0x298]
push eax
push 0
push 0
push 0x1a
push 0
call dword [sym.imp.SHELL32.dll_SHGetFolderPathW]
lea eax, [ebp - 0x5ac]
push eax
lea ecx, [ebp - 0x5a5]
call fcn.00405ee0
push dword [eax]
lea eax, [ebp - 0x298]
push eax
call dword [sym.imp.SHLWAPI.dll_PathAppendW]
mov edx, dword [ebp - 0x5ac]
or eax, 0xffffffff
add edx, 0xfffffff0
lock xadd dword [edx + 0xc], eax
dec eax
test eax, eax
jg 0x407df8
mov ecx, dword [edx]
push edx
mov eax, dword [ecx]
call dword [eax + 4]
mov ecx, 0x82
lea esi, [ebp - 0x298]
lea edi, [ebp - 0x5a4]
rep movsd dword es:[edi], dword [esi]
mov edi, dword [ebp + 8]
mov edi, dword [edi + 4]
mov eax, dword [edi]
mov dword [ebp - 0x5ac], eax
cmp eax, edi
je 0x408053
lea ebx, [eax + 0x10]
xor cl, cl
lea eax, [ebx + 0x18]
mov dword [ebp - 0x5bc], eax
mov eax, dword [eax]
sub eax, 1
je 0x407e46
sub eax, 1
jne 0x40802b
mov cl, 1
jmp 0x40802b
cmp dword [ebx + 0x14], 0x10
jb 0x407e4e
mov ebx, dword [ebx]
lea eax, [ebp - 0x398]
mov dword [ebp - 0x39c], eax
test ebx, ebx
jne 0x407e6b
xor esi, esi
mov dword [ebp - 0x39c], esi
jmp 0x407f30
mov ecx, ebx
lea edx, [ecx + 1]
mov al, byte [ecx]
inc ecx
test al, al
jne 0x407e70
sub ecx, edx
lea eax, [ebp - 0x398]
push 0x80
push eax
lea eax, [ebp - 0x39c]
lea esi, [ecx + 1]
push esi
push eax
mov dword [ebp - 0x5b4], esi
call fcn.00403f90
add esp, 0x10
push esi
push dword [ebp - 0x39c]
push esi
push ebx
push 0
push 3
call dword [sym.imp.KERNEL32.dll_MultiByteToWideChar]
xor ecx, ecx
test eax, eax
sete cl
mov dword [ebp - 0x5b0], ecx
test eax, eax
jne 0x407f22
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0x7a
jne 0x407f1c
push 0
push 0
push esi
push ebx
push 0
push 3
call dword [sym.imp.KERNEL32.dll_MultiByteToWideChar]
mov esi, eax
lea eax, [ebp - 0x398]
push 0x80
push eax
lea eax, [ebp - 0x39c]
push esi
push eax
call fcn.00403f90
add esp, 0x10
push esi
push dword [ebp - 0x39c]
push dword [ebp - 0x5b4]
push ebx
push 0
push 3
call dword [sym.imp.KERNEL32.dll_MultiByteToWideChar]
mov ecx, eax
neg ecx
sbb ecx, ecx
inc ecx
jmp 0x407f22
mov ecx, dword [ebp - 0x5b0]
test ecx, ecx
jne 0x408071
mov esi, dword [ebp - 0x39c]
push 0x80
lea eax, [ebp - 0x90]
mov dword [ebp - 4], 0
push 0
push eax
call fcn.004d49e0
add esp, 0xc
lea eax, [ebp - 0x5b8]
lea ecx, [ebp - 0x5a5]
push eax
call fcn.00405e60
lea eax, [ebp - 0x5a4]
push eax
push 0x40
lea eax, [ebp - 0x90]
push eax
push 0x5179ac
push esi
mov esi, dword [ebp - 0x5b8]
push esi
call dword [sym.imp.KERNEL32.dll_GetPrivateProfileStringW]
lea eax, [ebp - 0x90]
lea edx, [eax + 2]
nop dword [eax + eax]
mov cx, word [eax]
add eax, 2
test cx, cx
jne 0x407f90
sub eax, edx
sar eax, 1
je 0x407fe6
mov ecx, 0x517ad8
lea eax, [ebp - 0x90]
nop dword [eax]
mov dx, word [eax]
cmp dx, word [ecx]
jne 0x407fd6
test dx, dx
je 0x407fd2
mov dx, word [eax + 2]
cmp dx, word [ecx + 2]
jne 0x407fd6
add eax, 4
add ecx, 4
test dx, dx
jne 0x407fb0
xor eax, eax
jmp 0x407fdb
sbb eax, eax
or eax, 1
mov byte [ebp - 0x5a5], 0
test eax, eax
jne 0x407fed
mov byte [ebp - 0x5a5], 1
add esi, 0xfffffff0
or eax, 0xffffffff
lock xadd dword [esi + 0xc], eax
dec eax
test eax, eax
jg 0x408005
mov ecx, dword [esi]
push esi
mov eax, dword [ecx]
call dword [eax + 4]
mov eax, dword [ebp - 0x39c]
lea ecx, [ebp - 0x398]
mov dword [ebp - 4], 0xffffffff
cmp eax, ecx
je 0x408025
push eax
call fcn.004d7ea4
add esp, 4
mov cl, byte [ebp - 0x5a5]
xor eax, eax
test cl, cl
mov ecx, dword [ebp - 0x5bc]
setne al
mov dword [ecx], eax
lea ecx, [ebp - 0x5ac]
call fcn.00405ab0
mov eax, dword [ebp - 0x5ac]
cmp eax, edi
jne 0x407e21
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.0044042c
mov esp, ebp
pop ebp
ret 4
push 0x80
lea eax, [ebp - 0x398]
push eax
push dword [ebp - 0x39c]
call fcn.00404010
add esp, 0xc
call fcn.004062c0
int3