Function at 0x403287
Capabilities:
Get common file path
Persist via run registry key
Query or enumerate registry value
Read .ini file

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x834
mov eax, dword [ebp + 0xc]
push ebx
push esi
xor esi, esi
mov al, byte [eax]
test al, al
je 0x4035fb
mov ebx, dword [ebp + 8]
push edi
cmp al, 0x24
jne 0x4035e5
push str._PROGRAMFILES
push dword [ebp + 0xc]
call fcn.00403268
pop ecx
test eax, eax
pop ecx
jne 0x403377
mov esi, str.C:Program_Files
lea edi, [ebp - 0x110]
movsd dword es:[edi], dword [esi]
movsd dword es:[edi], dword [esi]
movsd dword es:[edi], dword [esi]
movsd dword es:[edi], dword [esi]
movsb byte es:[edi], byte [esi]
push 0x3c
lea edi, [ebp - 0xff]
pop ecx
add dword [ebp + 0xc], 0xd
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
stosb byte es:[edi], al
lea eax, [ebp - 8]
push eax
push 0x20019
push 0
push 0x4063ec
push 0x80000002
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExA]
test eax, eax
jne 0x403358
push 1
lea eax, [ebp - 4]
pop esi
mov dword [ebp - 4], 0x104
push eax
lea eax, [ebp - 0x318]
push eax
lea eax, [ebp + 8]
push eax
push 0
push 0x406418
mov dword [ebp + 8], esi
push dword [ebp - 8]
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExA]
test eax, eax
jne 0x40334f
cmp dword [ebp + 8], esi
jne 0x40334f
lea eax, [ebp - 0x318]
push eax
lea eax, [ebp - 0x110]
push eax
call fcn.00402fad
pop ecx
pop ecx
push dword [ebp - 8]
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
lea eax, [ebp - 0x110]
push eax
push ebx
call fcn.00402fad
pop ecx
pop ecx
cmp byte [ebx], 0
je 0x40336f
inc ebx
jmp 0x403367
push 1
pop esi
jmp 0x4035eb
push str._DESKTOP
push dword [ebp + 0xc]
call fcn.00403268
pop ecx
test eax, eax
pop ecx
jne 0x403437
mov eax, dword [0x406434]
push 0x40
mov dword [ebp - 0x214], eax
pop ecx
xor eax, eax
lea edi, [ebp - 0x210]
rep stosd dword es:[edi], eax
add dword [ebp + 0xc], 8
lea eax, [ebp - 0xc]
push eax
push 0x20019
push 0
push str.SoftwareMicrosoftWindowsCurrentVersionExplorerShell_Folders
push 0x80000001
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExA]
test eax, eax
jne 0x40341c
push 1
lea eax, [ebp - 4]
pop esi
mov dword [ebp - 4], 0x104
push eax
lea eax, [ebp - 0x520]
push eax
lea eax, [ebp + 8]
push eax
push 0
push str.Desktop
mov dword [ebp + 8], esi
push dword [ebp - 0xc]
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExA]
test eax, eax
jne 0x403413
cmp dword [ebp + 8], esi
jne 0x403413
lea eax, [ebp - 0x520]
push eax
lea eax, [ebp - 0x214]
push eax
call fcn.00402fad
pop ecx
pop ecx
push dword [ebp - 0xc]
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
lea eax, [ebp - 0x214]
push eax
push ebx
call fcn.00402fad
pop ecx
pop ecx
cmp byte [ebx], 0
je 0x40336f
inc ebx
jmp 0x40342b
push str._INSTDIR
push dword [ebp + 0xc]
call fcn.00403268
pop ecx
test eax, eax
pop ecx
jne 0x403468
push dword [0x4067c8]
add dword [ebp + 0xc], 8
push ebx
call fcn.00402fad
pop ecx
pop ecx
cmp byte [ebx], 0
je 0x40336f
inc ebx
jmp 0x40345c
push str._VISDIR
push dword [ebp + 0xc]
call fcn.00403268
pop ecx
test eax, eax
pop ecx
jne 0x4034e0
push dword [0x4067c8]
mov esi, dword [sym.imp.USER32.dll_wsprintfA]
add dword [ebp + 0xc], 7
lea eax, [ebp - 0x72c]
push 0x406498
push eax
call esi
add esp, 0xc
lea eax, [ebp - 0x72c]
push eax
push 0x104
push ebx
push 0x4067b8
push str.VISDir
push 0x4064b0
call dword [sym.imp.KERNEL32.dll_GetPrivateProfileStringA]
cmp byte [ebx], 0
jne 0x4034dd
push dword [0x4067c8]
push 0x4064b8
push ebx
call esi
add esp, 0xc
cmp byte [ebx], 0
je 0x40336f
inc ebx
jmp 0x4034d4
push str._DSPDIR
push dword [ebp + 0xc]
call fcn.00403268
pop ecx
test eax, eax
pop ecx
jne 0x403558
push dword [0x4067c8]
mov esi, dword [sym.imp.USER32.dll_wsprintfA]
add dword [ebp + 0xc], 7
lea eax, [ebp - 0x41c]
push str._swinamp.ini
push eax
call esi
add esp, 0xc
lea eax, [ebp - 0x41c]
push eax
push 0x104
push ebx
push 0x4067bc
push str.DSPDir
push 0x4064e4
call dword [sym.imp.KERNEL32.dll_GetPrivateProfileStringA]
cmp byte [ebx], 0
jne 0x403555
push dword [0x4067c8]
push str._sPlugins
push ebx
call esi
add esp, 0xc
cmp byte [ebx], 0
je 0x40336f
inc ebx
jmp 0x40354c
push str._WINDIR
push dword [ebp + 0xc]
call fcn.00403268
pop ecx
test eax, eax
pop ecx
jne 0x40359c
add dword [ebp + 0xc], 7
lea eax, [ebp - 0x628]
push 0x104
push eax
call dword [sym.imp.KERNEL32.dll_GetWindowsDirectoryA]
lea eax, [ebp - 0x628]
push eax
push ebx
call fcn.00402fad
pop ecx
pop ecx
cmp byte [ebx], 0
je 0x40336f
inc ebx
jmp 0x403590
push str._SYSDIR
push dword [ebp + 0xc]
call fcn.00403268
pop ecx
test eax, eax
pop ecx
jne 0x4035e0
add dword [ebp + 0xc], 7
lea eax, [ebp - 0x834]
push 0x104
push eax
call dword [sym.imp.KERNEL32.dll_GetSystemDirectoryA]
lea eax, [ebp - 0x834]
push eax
push ebx
call fcn.00402fad
pop ecx
pop ecx
cmp byte [ebx], 0
je 0x40336f
inc ebx
jmp 0x4035d4
mov eax, dword [ebp + 0xc]
mov al, byte [eax]
mov byte [ebx], al
inc ebx
inc dword [ebp + 0xc]
mov eax, dword [ebp + 0xc]
mov al, byte [eax]
test al, al
jne 0x4032a5
pop edi
jmp 0x4035fe
mov ebx, dword [ebp + 8]
and byte [ebx], 0
mov eax, esi
pop esi
pop ebx
leave
ret