Function at 0x405960
Capabilities:
Query or enumerate registry value

Disassembly:
push 0xffffffffffffffff
push 0x40c0ed
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0x298
push ebx
push ebp
xor ebx, ebx
push esi
push edi
mov dword [esp + 0x14], ebx
mov eax, dword [esp + 0x2bc]
mov esi, dword [sym.imp.MSVCRT.dll__mbscmp]
mov ebp, 1
push str.2002
push eax
mov dword [esp + 0x2b8], ebp
mov dword [esp + 0x24], ebp
mov dword [esp + 0x28], 0x100
call esi
add esp, 8
test eax, eax
jne 0x4059f7
mov edi, str.SoftwareAutodeskAutoCADR15.0
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
lea edx, [esp + 0x28]
mov eax, ecx
mov esi, edi
mov edi, edx
lea edx, [esp + 0x28]
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
and ecx, 3
rep movsb byte es:[edi], byte [esi]
lea ecx, [esp + 0x10]
push ecx
push 0x20019
push ebx
push edx
push 0x80000002
jmp 0x405aaf
mov eax, dword [esp + 0x2bc]
push str.2004
push eax
call esi
add esp, 8
test eax, eax
jne 0x405a18
lea edx, [esp + 0x28]
mov edi, str.SoftwareAutodeskAutoCADR16.0
jmp 0x405a7d
mov eax, dword [esp + 0x2bc]
push str.2005
push eax
call esi
add esp, 8
test eax, eax
jne 0x405a39
lea edx, [esp + 0x28]
mov edi, str.SoftwareAutodeskAutoCADR16.1
jmp 0x405a7d
mov eax, dword [esp + 0x2bc]
push str.2006
push eax
call esi
add esp, 8
test eax, eax
jne 0x405a5a
lea edx, [esp + 0x28]
mov edi, str.SoftwareAutodeskAutoCADR16.2
jmp 0x405a7d
mov eax, dword [esp + 0x2bc]
push str.2007
push eax
call esi
add esp, 8
test eax, eax
jne 0x405bf5
lea edx, [esp + 0x28]
mov edi, str.SoftwareAutodeskAutoCADR17.0
or ecx, 0xffffffff
xor eax, eax
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov eax, ecx
mov esi, edi
mov edi, edx
lea edx, [esp + 0x28]
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
and ecx, 3
rep movsb byte es:[edi], byte [esi]
lea ecx, [esp + 0x10]
push ecx
push 0x20019
push ebx
push edx
push 0x80000001
mov esi, dword [sym.imp.ADVAPI32.dll_RegOpenKeyExA]
call esi
cmp eax, ebx
jne 0x405bdc
mov ebp, dword [sym.imp.ADVAPI32.dll_RegQueryValueExA]
lea eax, [esp + 0x20]
lea ecx, [esp + 0x1a8]
push eax
mov eax, dword [esp + 0x14]
lea edx, [esp + 0x20]
push ecx
push edx
push ebx
push str.CurVer
push eax
call ebp
test eax, eax
je 0x405b13
mov ecx, dword [esp + 0x10]
push ecx
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov esi, dword [esp + 0x2b8]
push 0x412ad8
mov ecx, esi
call fcn.0040b2e8
mov dword [esp + 0x14], 1
jmp 0x405c0c
mov edx, dword [esp + 0x10]
mov edi, dword [sym.imp.ADVAPI32.dll_RegCloseKey]
push edx
call edi
lea ecx, [esp + 0x18]
call sub.MFC42.DLL_CString::CString_1
lea eax, [esp + 0x1a8]
lea ecx, [esp + 0x28]
push eax
push ecx
lea edx, [esp + 0x20]
push str._s_s
push edx
mov byte [esp + 0x2c0], 2
mov dword [esp + 0x34], 0x100
call sub.MFC42.DLL_CString::Format
mov ecx, dword [esp + 0x28]
add esp, 0x10
lea eax, [esp + 0x10]
push eax
push 0x20019
push ebx
push ecx
push 0x80000002
call esi
cmp eax, ebx
jne 0x405bab
lea edx, [esp + 0x24]
lea eax, [esp + 0xa8]
push edx
mov edx, dword [esp + 0x14]
lea ecx, [esp + 0x20]
push eax
push ecx
push ebx
push str.AcadLocation
push edx
call ebp
cmp eax, ebx
je 0x405ba4
mov eax, dword [esp + 0x10]
push eax
call edi
push 0x412ad8
jmp 0x405bb3
mov ecx, dword [esp + 0x10]
push ecx
call edi
lea edx, [esp + 0xa8]
push edx
mov esi, dword [esp + 0x2bc]
mov ecx, esi
call fcn.0040b2e8
lea ecx, [esp + 0x18]
mov dword [esp + 0x14], 1
mov byte [esp + 0x2b0], 1
call sub.MFC42.DLL_CString::CString
jmp 0x405c0c
mov esi, dword [esp + 0x2b8]
push 0x412ad8
mov ecx, esi
call fcn.0040b2e8
mov dword [esp + 0x14], ebp
jmp 0x405c0c
mov esi, dword [esp + 0x2b8]
push 0x412ad8
mov ecx, esi
call fcn.0040b2e8
mov dword [esp + 0x14], ebp
lea ecx, [esp + 0x2bc]
mov byte [esp + 0x2b0], bl
call sub.MFC42.DLL_CString::CString
mov ecx, dword [esp + 0x2a8]
mov eax, esi
pop edi
pop esi
pop ebp
pop ebx
mov dword fs:[0], ecx
add esp, 0x2a4
ret