Function at 0x472115
Capabilities:
Get common file path
Query environment variable
Query or enumerate registry value

Disassembly:
push ebp
push ebx
push edi
push esi
sub esp, 0x220
mov esi, ecx
mov eax, dword [0x4c1074]
xor eax, esp
mov dword [esp + 0x21c], eax
mov dword [esp + 4], 0x105
lea eax, [esp + 0xc]
push eax
push str.SoftwareSimonTathamPuTTY
push 0x80000001
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyA]
test eax, eax
je 0x47218a
cmp byte [0x4c445c], 0
je 0x472164
mov ecx, dword [0x4c4464]
jmp 0x4721f6
push str.shell32.dll
call fcn.0046caa4
add esp, 4
mov dword [0x4c4460], eax
test eax, eax
je 0x4721e7
push str.SHGetFolderPathA
push eax
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
mov ecx, eax
jmp 0x4721e9
lea eax, [esp + 4]
lea ecx, [esp + 0x117]
lea edx, [esp + 0x10]
push eax
push ecx
push edx
push 0
push str.RandSeedFile
push dword [esp + 0x20]
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExA]
mov edi, eax
push dword [esp + 0xc]
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
test edi, edi
jne 0x472150
cmp dword [esp + 0x10], 1
jne 0x472150
lea eax, [esp + 8]
lea ecx, [esp + 0x117]
mov edx, esi
push eax
call fcn.00472835
add esp, 4
test al, al
je 0x472150
jmp 0x472378
xor ecx, ecx
mov dword [0x4c4464], ecx
mov byte [0x4c445c], 1
test ecx, ecx
je 0x4722a5
sub esp, 0x14
lea ebp, [esp + 0x12b]
mov dword [esp + 0x10], ebp
movaps xmm0, xmmword [0x4a1d80]
movups xmmword [esp], xmm0
call ecx
test eax, eax
js 0x472253
push 0
push str.PUTTY.RND
push ebp
call fcn.0045ac65
add esp, 0xc
mov edi, eax
lea eax, [esp + 8]
mov ecx, edi
mov edx, esi
push eax
call fcn.00472835
add esp, 4
mov ebx, eax
push edi
call fcn.00411645
add esp, 4
test bl, bl
jne 0x472378
sub esp, 0x14
mov dword [esp + 0x10], ebp
movaps xmm0, xmmword [0x4a1d90]
movups xmmword [esp], xmm0
call dword [0x4c4464]
test eax, eax
js 0x4722a5
push 0
push str.PUTTY.RND
push ebp
call fcn.0045ac65
add esp, 0xc
mov edi, eax
lea eax, [esp + 8]
mov ecx, edi
mov edx, esi
push eax
call fcn.00472835
add esp, 4
mov ebx, eax
push edi
call fcn.00411645
add esp, 4
test bl, bl
jne 0x472378
mov dword [esp], esi
mov esi, 0x104
lea eax, [esp + 0x117]
mov ebp, dword [sym.imp.KERNEL32.dll_GetEnvironmentVariableA]
push esi
push eax
push str.HOMEDRIVE
call ebp
mov edi, eax
lea ebx, [esp + 0x10]
push esi
push ebx
push str.HOMEPATH
call ebp
test edi, edi
jne 0x4722de
mov byte [esp + 0x117], 0
cmp edi, 0x103
mov esi, dword [esp]
ja 0x47232d
dec eax
cmp eax, 0x103
jae 0x47232d
push 0
push str.PUTTY.RND
push ebx
lea ebp, [esp + 0x123]
push ebp
call fcn.0045ac65
add esp, 0x10
mov edi, eax
lea eax, [esp + 8]
mov ecx, edi
mov edx, esi
push eax
call fcn.00472835
add esp, 4
mov ebx, eax
push edi
call fcn.00411645
add esp, 4
test bl, bl
je 0x472334
jmp 0x472378
lea ebp, [esp + 0x117]
mov esi, 0x104
push esi
push ebp
call dword [sym.imp.KERNEL32.dll_GetWindowsDirectoryA]
cmp eax, esi
jae 0x47237e
push 0
push str.PUTTY.RND
push ebp
call fcn.0045ac65
add esp, 0xc
mov edi, eax
lea eax, [esp + 8]
mov ecx, edi
mov edx, dword [esp]
push eax
call fcn.00472835
add esp, 4
mov ebx, eax
push edi
call fcn.00411645
add esp, 4
test bl, bl
je 0x47237e
mov esi, dword [esp + 8]
jmp 0x472381
xor esi, esi
dec esi
mov ecx, dword [esp + 0x21c]
xor ecx, esp
call fcn.00475526
mov eax, esi
add esp, 0x220
pop esi
pop edi
pop ebx
pop ebp
ret