Function at 0x40945a
Capabilities:
Get common file path
Get disk information
Get program files directory
Query or enumerate registry value

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x240
push ebx
push esi
push edi
mov esi, ecx
push 0x7f
xor ebx, ebx
pop ecx
xor eax, eax
lea edi, [ebp - 0x23e]
mov word [ebp - 0x240], bx
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
lea eax, [ebp - 0x240]
mov dword [ebp - 0x28], esi
push eax
push 0xff
lea edi, [ebp - 0x240]
call dword [sym.imp.KERNEL32.dll_GetLogicalDriveStringsW]
push 0x3ea
push dword [esi + 4]
call dword [sym.imp.USER32.dll_GetDlgItem]
mov dword [ebp - 8], eax
lea eax, [ebp - 0x20]
push eax
call fcn.0045fe53
cmp word [ebp - 0x240], bx
mov esi, dword [sym.imp.USER32.dll_SendMessageW]
pop ecx
je 0x4095fb
push edi
call dword [sym.imp.KERNEL32.dll_GetDriveTypeW]
cmp eax, 2
mov dword [ebp - 4], eax
jne 0x4094f7
mov ax, word [edi]
cmp ax, 0x41
je 0x4094e7
cmp ax, 0x42
jne 0x4094f7
push edi
call fcn.0049cb01
pop ecx
lea edi, [edi + eax*2 + 2]
jmp 0x4095f2
mov eax, dword [0x4af550]
push edi
mov dword [ebp - 0x14], eax
mov dword [ebp - 0xc], eax
call fcn.0049cb01
mov dword [ebp - 0x34], eax
mov eax, dword [ebp - 4]
cmp eax, 3
pop ecx
je 0x409527
cmp eax, 4
je 0x409527
cmp eax, 2
je 0x409527
cmp eax, 6
jne 0x4095db
movzx eax, word [edi]
push eax
lea eax, [ebp - 0x14]
push str._C:_
push eax
mov word [edi + 2], bx
call fcn.00403d66
add esp, 0xc
push ebx
push ebx
push 0x146
push dword [ebp - 8]
call esi
mov dword [ebp - 4], eax
lea eax, [ebp - 0x20]
push eax
lea eax, [ebp - 0x14]
push eax
lea eax, [ebp - 0x30]
push eax
call fcn.00403b20
push ebx
lea ecx, [ebp - 0x30]
call fcn.00403c58
push eax
push dword [ebp - 4]
push 0x14a
push dword [ebp - 8]
call esi
lea eax, [ebp - 0x20]
push eax
lea eax, [ebp - 0x14]
push str.SoftwareOK_
push eax
lea eax, [ebp - 0x38]
push eax
call fcn.0040a956
push eax
lea eax, [ebp - 0x40]
push eax
call fcn.00403b20
push eax
lea ecx, [ebp - 0x30]
call fcn.00403a8c
lea ecx, [ebp - 0x40]
call fcn.004038fb
lea ecx, [ebp - 0x38]
call fcn.004038fb
push ebx
lea ecx, [ebp - 0x30]
call fcn.00403c58
push eax
push dword [ebp - 4]
push 0x14a
push dword [ebp - 8]
call esi
push ebx
push ebx
push 0x146
push dword [ebp - 8]
call esi
lea ecx, [ebp - 0x30]
call fcn.004038fb
mov eax, dword [ebp - 0x34]
lea ecx, [ebp - 0xc]
lea edi, [edi + eax*2 + 2]
call fcn.004038fb
lea ecx, [ebp - 0x14]
call fcn.004038fb
cmp word [edi], bx
jne 0x4094c9
mov eax, dword [0x4af550]
push ebx
mov edi, 0x400
push 0x1a
push edi
lea ecx, [ebp - 0x1c]
mov dword [ebp - 0x1c], eax
mov dword [ebp - 0x24], eax
call fcn.00403c58
push eax
push ebx
call dword [sym.imp.SHELL32.dll_SHGetSpecialFolderPathW]
push 0xffffffffffffffff
lea ecx, [ebp - 0x1c]
call fcn.00403cd2
push 0x4b0300
lea ecx, [ebp - 4]
call fcn.00403927
lea eax, [ebp - 0x20]
push eax
lea eax, [ebp - 4]
push eax
lea eax, [ebp - 0xc]
push eax
call fcn.00403b20
mov eax, dword [eax]
lea ecx, [ebp - 0x1c]
push eax
push dword [eax - 8]
call fcn.00403bd8
lea ecx, [ebp - 0xc]
call fcn.004038fb
lea ecx, [ebp - 4]
call fcn.004038fb
push ebx
push 0x26
push edi
lea ecx, [ebp - 0x24]
call fcn.00403c58
push eax
push ebx
call dword [sym.imp.SHELL32.dll_SHGetSpecialFolderPathW]
push 0xffffffffffffffff
lea ecx, [ebp - 0x24]
call fcn.00403cd2
push 0x4b0300
lea ecx, [ebp - 4]
call fcn.00403927
lea eax, [ebp - 0x20]
push eax
lea eax, [ebp - 4]
push eax
lea eax, [ebp - 0xc]
push eax
call fcn.00403b20
mov eax, dword [eax]
lea ecx, [ebp - 0x24]
push eax
push dword [eax - 8]
call fcn.00403bd8
lea ecx, [ebp - 0xc]
call fcn.004038fb
lea ecx, [ebp - 4]
call fcn.004038fb
push ebx
lea ecx, [ebp - 0x24]
call fcn.00403c58
push eax
push ebx
push 0x14a
push dword [ebp - 8]
call esi
push ebx
lea ecx, [ebp - 0x1c]
call fcn.00403c58
push eax
push ebx
push 0x14a
push dword [ebp - 8]
call esi
push 0x4b1
mov eax, dword [ebp - 0x28]
push dword [eax + 4]
call dword [sym.imp.USER32.dll_GetDlgItem]
push ebx
push ebx
push 0xf0
push eax
call esi
push ebx
push eax
push 0x14e
mov dword [0x4bc7b0], eax
push dword [ebp - 8]
call esi
mov eax, dword [ebp - 0x28]
push 0x4b1
push dword [eax + 4]
call dword [sym.imp.USER32.dll_GetDlgItem]
push ebx
push ebx
push 0xf0
push eax
call esi
cmp eax, ebx
mov dword [0x4bc7b0], eax
mov dword [ebp - 4], reloc.SHELL32.dll_SHChangeNotifyRegister
jne 0x409747
mov dword [ebp - 4], SHChangeNotifyRegister
push 0x4c5710
lea eax, [ebp - 0xc]
push 0x4bc7a0
push eax
mov dword [ebp - 0x2c], ebx
call fcn.00403b20
mov eax, dword [eax]
lea ecx, [ebp - 0x14]
push ecx
push 0x20019
push ebx
push eax
push dword [ebp - 4]
mov dword [ebp - 0x14], ebx
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExW]
test eax, eax
jne 0x409788
lea ecx, [ebp - 0x2c]
call fcn.00405b3f
mov eax, dword [ebp - 0x14]
mov dword [ebp - 0x2c], eax
lea ecx, [ebp - 0xc]
call fcn.004038fb
mov eax, dword [0x4af550]
push edi
lea ecx, [ebp - 0x18]
mov dword [ebp - 0x3c], edi
mov dword [ebp - 0x18], eax
call fcn.00403c58
lea ecx, [ebp - 0x3c]
mov dword [ebp - 0xc], ebx
push ecx
push eax
lea eax, [ebp - 0xc]
push eax
push ebx
push str.UninstallString
push dword [ebp - 0x2c]
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
push 0xffffffffffffffff
lea ecx, [ebp - 0x18]
call fcn.00403cd2
mov eax, dword [ebp - 0x18]
push ecx
mov ecx, esp
cmp dword [eax - 0xc], ebx
jl 0x4097e5
mov dword [ecx], eax
mov eax, dword [ebp - 0x18]
add eax, 0xfffffff4
push eax
call dword [sym.imp.KERNEL32.dll_InterlockedIncrement]
jmp 0x4097f4
mov eax, dword [0x4af550]
mov dword [ecx], eax
push dword [ebp - 0x18]
call fcn.0040a750
lea eax, [ebp - 0x10]
push eax
call fcn.004600c4
mov eax, dword [ebp - 0x10]
pop ecx
pop ecx
cmp dword [eax - 8], 1
jle 0x40984e
mov edi, 0x100
lea ecx, [ebp - 0x10]
push edi
call fcn.00403c58
mov ecx, dword [ebp - 0x28]
push eax
call fcn.004098ba
push 0xffffffffffffffff
lea ecx, [ebp - 0x10]
call fcn.00403cd2
mov eax, dword [ebp - 0x10]
cmp dword [eax - 8], 1
jle 0x40984e
push edi
lea ecx, [ebp - 0x10]
call fcn.00403c58
mov ecx, dword [ebp - 0x28]
push eax
call fcn.004098ba
push 0xffffffffffffffff
lea ecx, [ebp - 0x10]
call fcn.00403cd2
mov eax, dword [ebp - 0x10]
cmp dword [eax - 8], ebx
je 0x409885
push ebx
push ebx
push 0x146
push dword [ebp - 8]
call esi
push ebx
lea ecx, [ebp - 0x10]
mov edi, eax
call fcn.00403c58
push eax
push edi
push 0x14a
push dword [ebp - 8]
call esi
push ebx
push edi
push 0x14e
push dword [ebp - 8]
call esi
lea ecx, [ebp - 0x10]
call fcn.004038fb
lea ecx, [ebp - 0x18]
call fcn.004038fb
lea ecx, [ebp - 0x2c]
call fcn.00405b3f
lea ecx, [ebp - 0x24]
call fcn.004038fb
lea ecx, [ebp - 0x1c]
call fcn.004038fb
lea ecx, [ebp - 0x20]
call fcn.004038fb
pop edi
pop esi
pop ebx
leave
ret