Function at 0x40dfde
Capabilities:
Connect to wmi namespace via wbemlocator
Reference sql statements

Disassembly:
push ebp
mov eax, 0x1834
lea ebp, [esp - 0x17b4]
call fcn.0042a090
mov eax, dword [0x44c750]
push ebx
push esi
xor ebx, ebx
push edi
push ebx
mov dword [ebp + 0x17b0], eax
mov dword [ebp - 0x68], ebx
mov dword [ebp - 0x60], ebx
mov dword [ebp - 0x6c], ebx
mov byte [ebp - 0x51], bl
call dword [sym.imp.ole32.dll_CoInitialize]
test eax, eax
lea eax, [ebp - 0x68]
push eax
push 0x43ebf4
push 1
push ebx
push 0x43ebe4
setge byte [ebp - 0x59]
call dword [sym.imp.ole32.dll_CoCreateInstance]
test eax, eax
jl 0x40e1c7
cmp dword [ebp - 0x68], ebx
je 0x40e1d7
mov esi, dword [sym.imp.OLEAUT32.dll_SysReAllocString]
push str.._rootcimv2ApplicationsGames
call esi
lea edx, [ebp - 0x60]
push edx
push ebx
push ebx
push ebx
push ebx
push ebx
mov dword [ebp - 0x70], eax
mov eax, dword [ebp - 0x68]
mov ecx, dword [eax]
push ebx
push dword [ebp - 0x70]
push eax
call dword [ecx + 0xc]
test eax, eax
jl 0x40e1a9
cmp dword [ebp - 0x60], ebx
je 0x40e1a9
push ebx
push ebx
push 3
push 3
push ebx
push ebx
push 0xa
push dword [ebp - 0x60]
call dword [sym.imp.ole32.dll_CoSetProxyBlanket]
push 0x43eb94
call esi
mov ecx, dword [ebp + 0x17bc]
mov dword [ebp - 0x64], eax
xor eax, eax
cmp word [ecx], bx
je 0x40e0cd
mov edx, ecx
cmp eax, 0x7d0
jg 0x40e0cd
mov cx, word [edx]
cmp cx, 0x5c
mov word [ebp + eax*2 + 0x7b0], cx
jne 0x40e0c5
inc eax
mov word [ebp + eax*2 + 0x7b0], cx
inc eax
inc edx
inc edx
cmp word [edx], bx
jne 0x40e0a4
mov word [ebp + eax*2 + 0x7b0], bx
lea eax, [ebp + 0x7b0]
push eax
push str.SELECT__FROM_GAME_WHERE_GDFBinaryPath____s_
lea eax, [ebp - 0x50]
push 0x400
push eax
call fcn.0040de1d
add esp, 0x10
lea eax, [ebp - 0x50]
push eax
call esi
mov ecx, dword [ebp - 0x60]
mov edx, dword [ecx]
lea edi, [ebp - 0x6c]
push edi
push ebx
push 0x30
push eax
push dword [ebp - 0x64]
push ecx
call dword [edx + 0x50]
test eax, eax
jl 0x40e199
mov eax, dword [ebp - 0x6c]
lea edx, [ebp - 0x64]
push edx
lea edx, [ebp - 0x58]
push edx
push 1
push 0x1388
mov dword [ebp - 0x58], ebx
mov dword [ebp - 0x64], ebx
mov ecx, dword [eax]
push eax
call dword [ecx + 0x10]
test eax, eax
jl 0x40e18c
cmp dword [ebp - 0x64], ebx
je 0x40e18c
cmp dword [ebp - 0x58], ebx
je 0x40e199
push str.InstanceID
call esi
push ebx
push ebx
lea edx, [ebp - 0x80]
push edx
mov esi, eax
mov eax, dword [ebp - 0x58]
mov ecx, dword [eax]
push ebx
push esi
push eax
call dword [ecx + 0x10]
test eax, eax
jl 0x40e181
cmp word [ebp - 0x80], 8
jne 0x40e181
cmp dword [ebp + 0x17c0], ebx
mov byte [ebp - 0x51], 1
je 0x40e181
push dword [ebp + 0x17c0]
push dword [ebp - 0x78]
call fcn.0040db2a
pop ecx
pop ecx
cmp esi, ebx
je 0x40e18c
push esi
call dword [sym.imp.OLEAUT32.dll_SysStringLen]
mov eax, dword [ebp - 0x58]
cmp eax, ebx
je 0x40e199
mov ecx, dword [eax]
push eax
call dword [ecx + 8]
mov eax, dword [ebp - 0x6c]
cmp eax, ebx
je 0x40e1a9
mov ecx, dword [eax]
push eax
call dword [ecx + 8]
mov dword [ebp - 0x6c], ebx
cmp dword [ebp - 0x70], ebx
je 0x40e1b7
push dword [ebp - 0x70]
call dword [sym.imp.OLEAUT32.dll_SysStringLen]
mov eax, dword [ebp - 0x60]
cmp eax, ebx
je 0x40e1c7
mov ecx, dword [eax]
push eax
call dword [ecx + 8]
mov dword [ebp - 0x60], ebx
mov eax, dword [ebp - 0x68]
cmp eax, ebx
je 0x40e1d7
mov ecx, dword [eax]
push eax
call dword [ecx + 8]
mov dword [ebp - 0x68], ebx
cmp byte [ebp - 0x59], bl
je 0x40e1e2
call dword [sym.imp.ole32.dll_CoUninitialize]
cmp byte [ebp - 0x51], bl
jne 0x40e27c
mov edi, dword [sym.imp.ADVAPI32.dll_RegCreateKeyExW]
lea eax, [ebp - 0x64]
push eax
lea eax, [ebp - 0x58]
push eax
push ebx
push 0x20019
push ebx
push ebx
push ebx
push str.SoftwareClassesSoftwareMicrosoftWindowsCurrentVersionGameUXGamesToFindOnWindowsUpgrade
push SysReAllocString
call edi
test eax, eax
mov esi, dword [sym.imp.ADVAPI32.dll_RegCloseKey]
jne 0x40e23c
push dword [ebp + 0x17c0]
push dword [ebp + 0x17bc]
push dword [ebp - 0x58]
call fcn.0040dbcb
add esp, 0xc
push dword [ebp - 0x58]
mov byte [ebp - 0x51], al
call esi
cmp byte [ebp - 0x51], bl
jne 0x40e27c
lea eax, [ebp - 0x64]
push eax
lea eax, [ebp - 0x58]
push eax
push ebx
push 0x20019
push ebx
push ebx
push ebx
push str.SoftwareMicrosoftWindowsCurrentVersionGameUXGamesToFindOnWindowsUpgrade
push reloc.OLEAUT32.dll_SysReAllocString
call edi
test eax, eax
jne 0x40e27c
push dword [ebp + 0x17c0]
push dword [ebp + 0x17bc]
push dword [ebp - 0x58]
call fcn.0040dbcb
add esp, 0xc
push dword [ebp - 0x58]
mov byte [ebp - 0x51], al
call esi
mov al, byte [ebp - 0x51]
mov ecx, dword [ebp + 0x17b0]
neg al
pop edi
pop esi
pop ebx
sbb eax, eax
and eax, 0x7fffbffb
add eax, 0x80004005
call fcn.0042a0fe
add ebp, 0x17b4
leave
ret 8