Function at 0x40a4b0
Capabilities:
Check if file exists
Get installed programs

Disassembly:
push 0xffffffffffffffff
push 0x442f00
mov eax, dword fs:[0]
push eax
sub esp, 0x30
push ebx
push ebp
push esi
push edi
mov eax, dword [0x457600]
xor eax, esp
push eax
lea eax, [esp + 0x44]
mov dword fs:[0], eax
mov eax, dword [esp + 0x54]
mov ecx, dword [eax + 0x10]
sub ecx, dword [eax + 0xc]
xor ebx, ebx
sar ecx, 2
mov dword [esp + 0x2c], ebx
test ecx, ecx
jbe 0x40a8b8
or ebp, 0xffffffff
call fcn.00409820
mov esi, dword [eax]
cmp dword [esi], 1
jne 0x40a5e7
lea edi, [esi + 0x620]
lea ebx, [esp + 0x34]
call fcn.0040bd10
call fcn.0041160a
xor ecx, ecx
test eax, eax
setne cl
test ecx, ecx
je 0x40a8d0
mov edx, dword [eax]
mov ecx, eax
mov eax, dword [edx + 0xc]
call eax
add eax, 0x10
mov dword [esp + 0x20], eax
mov dword [esp + 0x4c], 0
mov eax, dword [esp + 0x34]
movzx ecx, ax
push ecx
shr eax, 0x10
push eax
mov eax, dword [esp + 0x40]
movzx edx, ax
push edx
shr eax, 0x10
push eax
lea eax, [esp + 0x30]
push str._u._u._u._u
push eax
call fcn.00406360
xor ecx, ecx
add esp, 0x18
lea eax, [esi + 0x828]
test eax, eax
setne cl
test ecx, ecx
je 0x40a8d0
mov edi, dword [esp + 0x20]
push eax
push edi
call fcn.0042dea5
add esp, 8
test eax, eax
jne 0x40a5c1
lea ecx, [esi + 8]
push ecx
push str.MSG:_lib_s__module_already_installed.
call fcn.0040c990
lea eax, [edi - 0x10]
add esp, 8
mov dword [esi + 4], 2
mov dword [esp + 0x4c], ebp
lea edx, [eax + 0xc]
mov ecx, ebp
lock xadd dword [edx], ecx
dec ecx
test ecx, ecx
jmp 0x40a88e
lea eax, [edi - 0x10]
mov dword [esi + 4], 1
mov dword [esp + 0x4c], ebp
lea ecx, [eax + 0xc]
mov edx, ebp
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x40a5e7
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
cmp dword [esi], 2
jne 0x40a796
lea ecx, [esi + 0x620]
push ecx
lea ecx, [esp + 0x28]
call fcn.00406b70
mov dword [esp + 0x4c], 1
xor ebx, ebx
lea ebx, [ebx]
call fcn.0041160a
xor ecx, ecx
test eax, eax
setne cl
test ecx, ecx
je 0x40a8d0
mov edx, dword [eax]
mov ecx, eax
mov eax, dword [edx + 0xc]
call eax
add eax, 0x10
mov dword [esp + 0x18], eax
mov byte [esp + 0x4c], 2
call fcn.0041160a
xor ecx, ecx
test eax, eax
setne cl
test ecx, ecx
je 0x40a8d0
mov edx, dword [eax]
mov ecx, eax
mov eax, dword [edx + 0xc]
call eax
lea edi, [eax + 0x10]
mov dword [esp + 0x20], edi
push 0x7c
mov byte [esp + 0x50], 3
mov ecx, dword [esp + 0x28]
push ebx
push ecx
lea edx, [esp + 0x24]
push edx
call fcn.0041158d
mov eax, dword [esp + 0x18]
cmp dword [eax - 0xc], 0
je 0x40a72f
push eax
lea eax, [esp + 0x24]
push str.SOFTWAREMicrosoftWindowsCurrentVersionUninstall_s
push eax
call fcn.00406360
mov edi, dword [esp + 0x2c]
add esp, 0xc
lea ecx, [esp + 0x30]
push ecx
push 0x20019
push 0
push edi
push reloc.OLEAUT32.dll_SysReAllocString
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExW]
test eax, eax
je 0x40a70c
lea eax, [edi - 0x10]
mov dword [esi + 4], 1
mov byte [esp + 0x4c], 2
lea edx, [eax + 0xc]
mov ecx, ebp
lock xadd dword [edx], ecx
dec ecx
test ecx, ecx
jg 0x40a6dc
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov byte [esp + 0x4c], 1
mov eax, dword [esp + 0x18]
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
mov edx, ebp
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x40a700
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
inc ebx
cmp ebx, 0xa
jl 0x40a610
jmp 0x40a773
mov ecx, dword [esp + 0x30]
push ecx
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
lea ecx, [esi + 8]
push ecx
push str.MSG:_lib_s__module_already_installed.
call fcn.0040c990
add esp, 8
mov dword [esi + 4], 2
lea eax, [edi - 0x10]
mov ecx, ebp
lea edx, [eax + 0xc]
mov byte [esp + 0x4c], 2
lock xadd dword [edx], ecx
dec ecx
test ecx, ecx
jg 0x40a74f
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov byte [esp + 0x4c], 1
mov eax, dword [esp + 0x18]
add eax, 0xfffffff0
mov edx, ebp
lea ecx, [eax + 0xc]
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x40a773
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov dword [esp + 0x4c], ebp
mov eax, dword [esp + 0x24]
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
mov edx, ebp
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x40a796
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
cmp dword [esi], 3
jne 0x40a89a
lea ecx, [esi + 0x620]
push ecx
lea ecx, [esp + 0x2c]
call fcn.00406b70
mov ebx, 4
mov dword [esp + 0x4c], ebx
xor edi, edi
lea ebx, [ebx]
call fcn.0041160a
xor ecx, ecx
test eax, eax
setne cl
test ecx, ecx
je 0x40a8d0
mov edx, dword [eax]
mov ecx, eax
mov eax, dword [edx + 0xc]
call eax
add eax, 0x10
mov dword [esp + 0x1c], eax
push 0x7c
mov byte [esp + 0x50], 5
mov ecx, dword [esp + 0x2c]
push edi
push ecx
lea edx, [esp + 0x28]
push edx
call fcn.0041158d
mov eax, dword [esp + 0x1c]
push eax
call dword [sym.imp.SHLWAPI.dll_PathFileExistsW]
test eax, eax
jne 0x40a83c
mov byte [esp + 0x4c], bl
mov eax, dword [esp + 0x1c]
add eax, 0xfffffff0
mov dword [esi + 4], 1
lea ecx, [eax + 0xc]
mov edx, ebp
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x40a834
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
inc edi
cmp edi, 0xa
jl 0x40a7c0
jmp 0x40a877
lea ecx, [esi + 8]
push ecx
push str.MSG:_lib_s__module_already_installed.
call fcn.0040c990
mov byte [esp + 0x54], bl
mov eax, dword [esp + 0x24]
add eax, 0xfffffff0
add esp, 8
mov dword [esi + 4], 2
lea edx, [eax + 0xc]
mov ecx, ebp
lock xadd dword [edx], ecx
dec ecx
test ecx, ecx
jg 0x40a877
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov dword [esp + 0x4c], ebp
mov eax, dword [esp + 0x28]
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
mov edx, ebp
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x40a89a
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov eax, dword [esp + 0x54]
mov ecx, dword [eax + 0x10]
sub ecx, dword [eax + 0xc]
mov ebx, dword [esp + 0x2c]
inc ebx
sar ecx, 2
mov dword [esp + 0x2c], ebx
cmp ebx, ecx
jb 0x40a4f5
mov al, 1
mov ecx, dword [esp + 0x44]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x3c
ret 4
push 0x80004005
call fcn.004069f0
int3