Function at 0x4047c0
Capabilities:
Check os version
Get common file path
Query or enumerate registry value

Disassembly:
sub esp, 0x4cc
push ebx
push ebp
push esi
push edi
xor ebx, ebx
mov ecx, 0x1f
xor eax, eax
lea edi, [esp + 0x4d]
mov dword [esp + 0x38], 0x94
mov dword [esp + 0x3c], ebx
mov dword [esp + 0x40], ebx
mov dword [esp + 0x44], ebx
mov dword [esp + 0x48], ebx
mov byte [esp + 0x4c], bl
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
stosb byte es:[edi], al
mov eax, dword [esp + 0x4e4]
lea ecx, [esp + 0x38]
push ecx
mov dword [esp + 0x20], ebx
mov dword [eax], ebx
mov dword [esp + 0x28], 0x14
mov dword [esp + 0x2c], ebx
call dword [sym.imp.KERNEL32.dll_GetVersionExA]
test eax, eax
jne 0x404838
push 4
push ebx
call fcn.00403f30
add esp, 8
xor eax, eax
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x4cc
ret
mov eax, dword [esp + 0x3c]
cmp eax, 4
jb 0x404846
mov dword [0x4162d8], eax
cmp dword [esp + 0x48], 2
jne 0x404941
mov dword [0x4162dc], eax
lea edx, [esp + 0x2d4]
lea eax, [esp + 0x1d0]
push edx
push eax
mov dword [0x4162d4], 1
call fcn.004034c0
add esp, 8
test eax, eax
je 0x404941
lea ecx, [esp + 0x1d0]
push ecx
call fcn.004041f0
lea edx, [esp + 0x2d8]
mov ebp, eax
push edx
call fcn.004041f0
mov edi, eax
mov eax, dword [0x4162dc]
add esp, 8
cmp eax, ebp
jne 0x4048b0
cmp edi, ebx
ja 0x4048b6
cmp eax, ebp
jae 0x404946
xor esi, esi
cmp edi, ebx
jbe 0x404923
lea eax, [esp + 0x10]
push eax
push 1
push ebx
push str.SystemCurrentControlSetControlWindows
push 0x80000002
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExA]
test eax, eax
jne 0x40491e
mov eax, dword [esp + 0x10]
lea ecx, [esp + 0x14]
lea edx, [esp + 0x18]
push ecx
push edx
push ebx
push ebx
push str.CSDVersion
push eax
mov dword [esp + 0x2c], 4
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExA]
test eax, eax
jne 0x40490f
mov ecx, dword [esp + 0x18]
and ecx, 0xffff
cmp ecx, edi
sbb esi, esi
inc esi
mov edx, dword [esp + 0x10]
push edx
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
cmp esi, ebx
jne 0x404941
mov eax, dword [0x4162dc]
cmp eax, ebp
jne 0x404934
mov eax, dword [esp + 0x4e4]
mov dword [eax], 1
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
add esp, 0x4cc
ret
mov eax, dword [0x4162dc]
cmp dword [0x4162d4], ebx
je 0x404971
cmp eax, 4
jae 0x404960
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
add esp, 0x4cc
ret
cmp dword [0x416804], ebx
jne 0x404971
cmp eax, 5
jae 0x404acc
lea ecx, [esp + 0x3d8]
push 0x104
push ecx
call dword [sym.imp.KERNEL32.dll_GetSystemDirectoryA]
lea edx, [esp + 0x3d8]
lea eax, [esp + 0xcc]
push edx
push eax
call dword [sym.imp.KERNEL32.dll_lstrcpyA]
lea ecx, [esp + 0xcc]
push str.MSI.DLL
push ecx
call dword [sym.imp.KERNEL32.dll_lstrcatA]
lea edx, [esp + 0xcc]
push edx
call dword [sym.imp.KERNEL32.dll_LoadLibraryA]
mov esi, eax
cmp esi, ebx
je 0x4049eb
push str.DllGetVersion
push esi
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
cmp eax, ebx
je 0x4049e4
lea ecx, [esp + 0x24]
push ecx
call eax
test eax, eax
jne 0x4049e4
mov dword [esp + 0x1c], 1
push esi
call dword [sym.imp.KERNEL32.dll_FreeLibrary]
mov edi, dword [esp + 0x4e4]
cmp edi, ebx
je 0x404acc
xor eax, eax
cmp esi, ebx
sete al
cmp eax, ebx
mov dword [edi], eax
jne 0x404acc
lea edx, [esp + 0x10]
lea eax, [esp + 0x20]
push edx
push eax
call fcn.00404780
add esp, 8
neg eax
sbb eax, eax
inc eax
jne 0x404a54
cmp dword [esp + 0x1c], ebx
jne 0x404a54
lea ecx, [esp + 0x18]
lea edx, [esp + 0x14]
push ecx
push edx
lea eax, [esp + 0xd4]
push ebx
push eax
call fcn.004045a0
mov edx, dword [esp + 0x28]
mov ecx, dword [esp + 0x24]
add esp, 0x10
neg eax
sbb eax, eax
inc eax
jmp 0x404a74
mov ecx, dword [esp + 0x28]
mov edx, dword [esp + 0x30]
mov esi, dword [esp + 0x10]
mov ebp, dword [esp + 0x2c]
shl ecx, 0x10
shl edx, 0x10
and esi, 0xffff
or ecx, ebp
or edx, esi
mov esi, dword [esp + 0x20]
cmp esi, 0x10032
sbb ebp, ebp
neg ebp
mov dword [0x41684c], ebp
mov ebp, dword [0x4162d4]
cmp ebp, ebx
je 0x404a9b
cmp dword [0x4162dc], 5
jae 0x404acc
cmp eax, ebx
jne 0x404aaf
cmp ecx, esi
jb 0x404aaf
jne 0x404aab
cmp edx, dword [esp + 0x10]
jb 0x404aaf
xor edx, edx
jmp 0x404ab4
mov edx, 1
mov esi, dword [edi]
or esi, edx
cmp eax, ebx
mov dword [edi], esi
jne 0x404acc
shr ecx, 0x10
neg ecx
sbb ecx, ecx
inc ecx
mov dword [0x416848], ecx
pop edi
pop esi
pop ebp
mov eax, 1
pop ebx
add esp, 0x4cc
ret