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

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x5ac
mov eax, dword [0x551580]
xor eax, ebp
mov dword [ebp - 4], eax
push esi
push edi
push 0x208
lea eax, [ebp - 0x28c]
push 0
push eax
call fcn.004cfda0
add esp, 0xc
lea eax, [ebp - 0x28c]
push eax
push 0
push 0
push 0x1a
push 0
call dword [sym.imp.SHELL32.dll_SHGetFolderPathW]
push 0x512b98
lea eax, [ebp - 0x28c]
push eax
call dword [sym.imp.SHLWAPI.dll_PathAppendW]
mov ecx, 0x82
lea esi, [ebp - 0x28c]
lea edi, [ebp - 0x598]
rep movsd dword es:[edi], dword [esi]
mov esi, dword [ebp + 8]
mov esi, dword [esi + 4]
mov eax, dword [esi]
mov dword [ebp - 0x5a0], eax
cmp eax, esi
je 0x4072a5
push ebx
nop dword [eax]
lea ebx, [eax + 0x10]
xor cl, cl
lea eax, [ebx + 0x18]
mov dword [ebp - 0x5ac], eax
mov eax, dword [eax]
sub eax, 1
je 0x4070d5
sub eax, 1
jne 0x40727c
mov cl, 1
jmp 0x40727c
cmp dword [ebx + 0x14], 0x10
jb 0x4070dd
mov ebx, dword [ebx]
lea eax, [ebp - 0x38c]
mov dword [ebp - 0x390], eax
test ebx, ebx
jne 0x4070fa
xor edi, edi
mov dword [ebp - 0x390], edi
jmp 0x4071c0
mov ecx, ebx
lea edx, [ecx + 1]
nop
mov al, byte [ecx]
inc ecx
test al, al
jne 0x407100
sub ecx, edx
lea eax, [ebp - 0x38c]
push 0x80
push eax
lea eax, [ebp - 0x390]
lea edi, [ecx + 1]
push edi
push eax
mov dword [ebp - 0x5a8], edi
call fcn.004037b0
add esp, 0x10
push edi
push dword [ebp - 0x390]
push edi
push ebx
push 0
push 3
call dword [sym.imp.KERNEL32.dll_MultiByteToWideChar]
xor ecx, ecx
test eax, eax
sete cl
mov dword [ebp - 0x5a4], ecx
test eax, eax
jne 0x4071b2
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0x7a
jne 0x4071ac
push 0
push 0
push edi
push ebx
push 0
push 3
call dword [sym.imp.KERNEL32.dll_MultiByteToWideChar]
mov edi, eax
lea eax, [ebp - 0x38c]
push 0x80
push eax
lea eax, [ebp - 0x390]
push edi
push eax
call fcn.004037b0
add esp, 0x10
push edi
push dword [ebp - 0x390]
push dword [ebp - 0x5a8]
push ebx
push 0
push 3
call dword [sym.imp.KERNEL32.dll_MultiByteToWideChar]
mov ecx, eax
neg ecx
sbb ecx, ecx
inc ecx
jmp 0x4071b2
mov ecx, dword [ebp - 0x5a4]
test ecx, ecx
jne 0x4072b7
mov edi, dword [ebp - 0x390]
push 0x80
lea eax, [ebp - 0x84]
push 0
push eax
call fcn.004cfda0
add esp, 0xc
lea eax, [ebp - 0x598]
push eax
push 0x40
lea eax, [ebp - 0x84]
push eax
push 0x5129c0
push edi
push 0x512b8c
call dword [sym.imp.KERNEL32.dll_GetPrivateProfileStringW]
lea eax, [ebp - 0x84]
lea edx, [eax + 2]
mov cx, word [eax]
add eax, 2
test cx, cx
jne 0x407200
sub eax, edx
sar eax, 1
je 0x407256
mov ecx, 0x512b94
lea eax, [ebp - 0x84]
nop dword [eax]
mov dx, word [eax]
cmp dx, word [ecx]
jne 0x407246
test dx, dx
je 0x407242
mov dx, word [eax + 2]
cmp dx, word [ecx + 2]
jne 0x407246
add eax, 4
add ecx, 4
test dx, dx
jne 0x407220
xor eax, eax
jmp 0x40724b
sbb eax, eax
or eax, 1
mov byte [ebp - 0x599], 0
test eax, eax
jne 0x40725d
mov byte [ebp - 0x599], 1
mov eax, dword [ebp - 0x390]
lea ecx, [ebp - 0x38c]
cmp eax, ecx
je 0x407276
push eax
call fcn.004d3264
add esp, 4
mov cl, byte [ebp - 0x599]
xor eax, eax
test cl, cl
mov ecx, dword [ebp - 0x5ac]
setne al
mov dword [ecx], eax
lea ecx, [ebp - 0x5a0]
call fcn.004057e0
mov eax, dword [ebp - 0x5a0]
cmp eax, esi
jne 0x4070b0
pop ebx
mov ecx, dword [ebp - 4]
pop edi
xor ecx, ebp
pop esi
call fcn.0043b31f
mov esp, ebp
pop ebp
ret 4
push 0x80
lea eax, [ebp - 0x38c]
push eax
push dword [ebp - 0x390]
call fcn.00403830
add esp, 0xc
call fcn.00405930
int3