Function at 0x407462
Capabilities:
Get common file path
Query or enumerate registry value
Read .ini file

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x134
mov eax, dword [0x4119c4]
push ebx
xor ebx, ebx
push esi
push edi
mov edi, dword [sym.imp.ADVAPI32.dll_RegOpenKeyExA]
cmp eax, ebx
je 0x4074df
mov ecx, dword [0x4119c8]
cmp ecx, 0x10
jb 0x407492
mov ecx, dword [0x40f1c0]
jmp 0x407499
mov ecx, dword [ecx*4 + 0x40f1bc]
lea edx, [ebp - 8]
push edx
push 0x20019
push ebx
push eax
push ecx
call edi
test eax, eax
jne 0x4075b8
lea eax, [ebp - 0xc]
mov dword [ebp - 0xc], 0x104
push eax
lea eax, [ebp - 0x10]
push dword [0x41193c]
push eax
push ebx
push dword [0x4119c0]
push dword [ebp - 8]
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExA]
push dword [ebp - 8]
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
jmp 0x40753f
cmp dword [0x4119bc], ebx
je 0x4075b8
cmp dword [0x4119b8], ebx
je 0x4075b8
cmp dword [0x4119b4], ebx
je 0x4075b8
push dword [0x41193c]
push dword [0x411930]
call fcn.00407cd0
pop ecx
pop ecx
push dword [0x4119bc]
push 0x104
push dword [0x41193c]
push dword [0x411930]
push dword [0x4119b4]
push dword [0x4119b8]
call dword [sym.imp.KERNEL32.dll_GetPrivateProfileStringA]
mov eax, dword [0x41193c]
mov cl, byte [eax]
cmp cl, 0x22
je 0x407550
cmp cl, 0x20
jne 0x40756b
push eax
call fcn.00407c50
push eax
mov eax, dword [0x41193c]
lea ecx, [eax + 1]
push ecx
push eax
call fcn.00408d60
add esp, 0x10
jmp 0x40753f
cmp byte [eax], bl
je 0x4076d5
push eax
call fcn.00408169
test eax, eax
pop ecx
je 0x40759f
push dword [0x41193c]
call fcn.00407c50
pop ecx
mov ecx, dword [0x41193c]
mov byte [eax + ecx - 1], bl
mov eax, dword [0x41193c]
cmp byte [eax], bl
jne 0x407573
jmp 0x4075a4
mov eax, dword [0x41193c]
cmp byte [eax], bl
je 0x4076d5
push eax
call fcn.004076da
pop ecx
jmp 0x4076d5
mov eax, dword [0x41193c]
cmp byte [eax], 0x23
jne 0x4076d5
inc eax
push 0x23
push eax
call fcn.00407e00
mov esi, eax
pop ecx
cmp esi, ebx
pop ecx
je 0x4076d5
inc esi
push str.Windows
mov byte [ebp - 0x134], bl
mov al, byte [esi]
mov byte [esi], bl
push dword [0x41193c]
mov byte [ebp - 1], al
call fcn.00408cd0
pop ecx
test eax, eax
pop ecx
jne 0x407616
lea eax, [ebp - 0x134]
push 0x104
push eax
call dword [sym.imp.KERNEL32.dll_GetWindowsDirectoryA]
jmp 0x40769d
push str.System
push dword [0x41193c]
call fcn.00408cd0
pop ecx
test eax, eax
pop ecx
jne 0x407640
lea eax, [ebp - 0x134]
push 0x104
push eax
call dword [sym.imp.KERNEL32.dll_GetSystemDirectoryA]
jmp 0x40769d
push str.Program_Files
push dword [0x41193c]
call fcn.00408cd0
pop ecx
test eax, eax
pop ecx
jne 0x40769d
lea eax, [ebp - 8]
push eax
push 0x20019
push ebx
push str.SoftwareMicrosoftWindowsCurrentVersion
push 0x80000002
call edi
lea eax, [ebp - 0xc]
mov dword [ebp - 0x10], ebx
push eax
lea eax, [ebp - 0x134]
push eax
lea eax, [ebp - 0x10]
push eax
push ebx
push str.ProgramFilesDir
mov dword [ebp - 0xc], 0x104
push dword [ebp - 8]
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExA]
push dword [ebp - 8]
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov al, byte [ebp - 1]
cmp al, 0x5c
mov byte [esi], al
jne 0x4076a7
inc esi
lea eax, [ebp - 0x134]
push eax
call fcn.00401e24
lea eax, [ebp - 0x134]
push esi
push eax
call fcn.00407ce0
lea eax, [ebp - 0x134]
push eax
push dword [0x41193c]
call fcn.00407cd0
add esp, 0x14
pop edi
pop esi
pop ebx
leave
ret