Function at 0x40afc0
Capabilities:
Reference wmi statements

Disassembly:
push rbp
push rbx
push rsi
push rdi
push r12
lea rbp, [rsp - 0x37]
sub rsp, 0xb0
mov qword [rbp + 0x1f], 0xfffffffffffffffe
xor edx, edx
xor ecx, ecx
call qword [sym.imp.ole32.dll_CoInitializeEx]
mov ebx, eax
test eax, eax
jns 0x40b033
lea rdx, str.Failed_to_initialize_COM_library._Error_code__0x
mov rcx, qword [sym.imp.MSVCP100.dll_class_std::basic_ostream_char__struct_std::char_traits_char___std::cout]
call fcn.00402790
mov rcx, rax
lea rdx, [0x00406130]
call qword [sym.imp.MSVCP100.dll_public:_class_std::basic_ostream_char__struct_std::char_traits_char______ptr64___cdecl_std::basic_ostream_char__struct_std::char_traits_char__::operator___class_std::ios_base____ptr64____cdecl___class_std::ios_base____ptr64_____ptr64]
mov rcx, rax
mov edx, ebx
call qword [sym.imp.MSVCP100.dll_public:_class_std::basic_ostream_char__struct_std::char_traits_char______ptr64___cdecl_std::basic_ostream_char__struct_std::char_traits_char__::operator___long_int____ptr64]
mov rcx, rax
mov rdx, qword [sym.imp.MSVCP100.dll_class_std::basic_ostream_char__struct_std::char_traits_char______ptr64___cdecl_std::endl_class_std::basic_ostream_char__struct_std::char_traits_char______ptr64_]
call qword [sym.imp.MSVCP100.dll_public:_class_std::basic_ostream_char__struct_std::char_traits_char______ptr64___cdecl_std::basic_ostream_char__struct_std::char_traits_char__::operator___class_std::basic_ostream_char__struct_std::char_traits_char______ptr64____cdecl___class_std::basic_ostream_char__struct_std::char_traits_char______ptr64_____ptr64]
mov eax, 1
jmp 0x40b525
xor r12d, r12d
mov qword [rsp + 0x40], r12
mov dword [rsp + 0x38], r12d
mov qword [rsp + 0x30], r12
mov dword [rsp + 0x28], 3
mov dword [rsp + 0x20], r12d
xor r9d, r9d
xor r8d, r8d
or edx, 0xffffffff
xor ecx, ecx
call qword [sym.imp.ole32.dll_CoInitializeSecurity]
mov ebx, eax
test eax, eax
jns 0x40b0b7
lea rdx, str.Failed_to_initialize_security._Error_code__0x
mov rcx, qword [sym.imp.MSVCP100.dll_class_std::basic_ostream_char__struct_std::char_traits_char___std::cout]
call fcn.00402790
mov rcx, rax
lea rdx, [0x00406130]
call qword [sym.imp.MSVCP100.dll_public:_class_std::basic_ostream_char__struct_std::char_traits_char______ptr64___cdecl_std::basic_ostream_char__struct_std::char_traits_char__::operator___class_std::ios_base____ptr64____cdecl___class_std::ios_base____ptr64_____ptr64]
mov rcx, rax
mov edx, ebx
call qword [sym.imp.MSVCP100.dll_public:_class_std::basic_ostream_char__struct_std::char_traits_char______ptr64___cdecl_std::basic_ostream_char__struct_std::char_traits_char__::operator___long_int____ptr64]
mov rcx, rax
mov rdx, qword [sym.imp.MSVCP100.dll_class_std::basic_ostream_char__struct_std::char_traits_char______ptr64___cdecl_std::endl_class_std::basic_ostream_char__struct_std::char_traits_char______ptr64_]
call qword [sym.imp.MSVCP100.dll_public:_class_std::basic_ostream_char__struct_std::char_traits_char______ptr64___cdecl_std::basic_ostream_char__struct_std::char_traits_char__::operator___class_std::basic_ostream_char__struct_std::char_traits_char______ptr64____cdecl___class_std::basic_ostream_char__struct_std::char_traits_char______ptr64_____ptr64]
call qword [sym.imp.ole32.dll_CoUninitialize]
mov eax, 1
jmp 0x40b525
mov qword [rbp + 0x77], r12
lea rax, [rbp + 0x77]
mov qword [rsp + 0x20], rax
lea r9, [0x00415f28]
xor edx, edx
lea r8d, [rdx + 5]
lea rcx, [0x00416080]
call qword [sym.imp.ole32.dll_CoCreateInstance]
mov ebx, eax
test eax, eax
jns 0x40b0ed
lea rdx, str.Failed_to_create_IWbemLocator_object._Err_code__0x
jmp 0x40b070
mov qword [rbp - 0x21], r12
mov ecx, 0x18
call sub.MSVCR100.dll_void____ptr64___cdecl_operator_new_unsigned_long_long_unsigned___int64__
mov rbx, rax
mov qword [rbp + 0x6f], rax
test rax, rax
je 0x40b132
mov qword [rax + 8], r12
mov dword [rax + 0x10], 1
lea rcx, str.rootcimv2
call qword [sym.imp.OLEAUT32.dll_SysReAllocString]
mov qword [rbx], rax
test rax, rax
jne 0x40b135
mov ecx, 0x8007000e
call fcn.0040f550
int3
mov rbx, r12
mov qword [rbp + 0x17], rbx
test rbx, rbx
jne 0x40b149
mov ecx, 0x8007000e
call fcn.0040f550
nop
mov rcx, qword [rbp + 0x77]
mov rax, qword [rcx]
lea rdx, [rbp - 0x21]
mov qword [rsp + 0x40], rdx
mov qword [rsp + 0x38], r12
mov qword [rsp + 0x30], r12
mov dword [rsp + 0x28], r12d
mov qword [rsp + 0x20], r12
xor r9d, r9d
xor r8d, r8d
mov rdx, qword [rbx]
call qword [rax + 0x18]
mov edi, eax
or ecx, 0xffffffff
lock xadd dword [rbx + 0x10], ecx
dec ecx
jne 0x40b1ab
mov rcx, qword [rbx]
test rcx, rcx
je 0x40b195
call qword [sym.imp.OLEAUT32.dll_SysStringLen]
mov rcx, qword [rbx + 8]
test rcx, rcx
je 0x40b1a3
call sub.MSVCR100.dll_void___cdecl_operator_delete___void____ptr64_
mov rcx, rbx
call sub.MSVCR100.dll_void___cdecl_operator_delete_void____ptr64_
test edi, edi
jns 0x40b1fc
lea rdx, str.Could_not_connect._Error_code__0x
mov rcx, qword [sym.imp.MSVCP100.dll_class_std::basic_ostream_char__struct_std::char_traits_char___std::cout]
call fcn.00402790
mov rcx, rax
lea rdx, [0x00406130]
call qword [sym.imp.MSVCP100.dll_public:_class_std::basic_ostream_char__struct_std::char_traits_char______ptr64___cdecl_std::basic_ostream_char__struct_std::char_traits_char__::operator___class_std::ios_base____ptr64____cdecl___class_std::ios_base____ptr64_____ptr64]
mov rcx, rax
mov edx, edi
call qword [sym.imp.MSVCP100.dll_public:_class_std::basic_ostream_char__struct_std::char_traits_char______ptr64___cdecl_std::basic_ostream_char__struct_std::char_traits_char__::operator___long_int____ptr64]
mov rcx, rax
mov rdx, qword [sym.imp.MSVCP100.dll_class_std::basic_ostream_char__struct_std::char_traits_char______ptr64___cdecl_std::endl_class_std::basic_ostream_char__struct_std::char_traits_char______ptr64_]
call qword [sym.imp.MSVCP100.dll_public:_class_std::basic_ostream_char__struct_std::char_traits_char______ptr64___cdecl_std::basic_ostream_char__struct_std::char_traits_char__::operator___class_std::basic_ostream_char__struct_std::char_traits_char______ptr64____cdecl___class_std::basic_ostream_char__struct_std::char_traits_char______ptr64_____ptr64]
mov rcx, qword [rbp + 0x77]
mov rax, qword [rcx]
call qword [rax + 0x10]
jmp 0x40b0a7
mov qword [rbp - 0x29], r12
mov ecx, 0x18
call sub.MSVCR100.dll_void____ptr64___cdecl_operator_new_unsigned_long_long_unsigned___int64__
mov rbx, rax
mov qword [rbp + 0x6f], rax
test rax, rax
je 0x40b232
mov qword [rax + 8], r12
mov dword [rax + 0x10], 1
lea rcx, str.SELECT__FROM_Win32_VideoController
call fcn.0040f3c0
mov qword [rbx], rax
jmp 0x40b235
mov rbx, r12
mov qword [rbp + 0x2f], rbx
test rbx, rbx
jne 0x40b249
mov ecx, 0x8007000e
call fcn.0040f550
nop
mov ecx, 0x18
call sub.MSVCR100.dll_void____ptr64___cdecl_operator_new_unsigned_long_long_unsigned___int64__
mov rdi, rax
mov qword [rbp + 0x6f], rax
test rax, rax
je 0x40b27b
mov qword [rax + 8], r12
mov dword [rax + 0x10], 1
lea rcx, [0x00414120]
call fcn.0040f3c0
mov qword [rdi], rax
jmp 0x40b27e
mov rdi, r12
mov qword [rbp + 0x27], rdi
test rdi, rdi
jne 0x40b292
mov ecx, 0x8007000e
call fcn.0040f550
nop
mov rcx, qword [rbp - 0x21]
mov rax, qword [rcx]
lea rdx, [rbp - 0x29]
mov qword [rsp + 0x28], rdx
mov qword [rsp + 0x20], r12
mov r9d, 0x30
mov r8, qword [rbx]
mov rdx, qword [rdi]
call qword [rax + 0xa0]
mov esi, eax
or ecx, 0xffffffff
lock xadd dword [rdi + 0x10], ecx
dec ecx
jne 0x40b2ec
mov rcx, qword [rdi]
test rcx, rcx
je 0x40b2d5
call qword [sym.imp.OLEAUT32.dll_SysStringLen]
mov rcx, qword [rdi + 8]
test rcx, rcx
je 0x40b2e3
call sub.MSVCR100.dll_void___cdecl_operator_delete___void____ptr64_
mov rcx, rdi
call sub.MSVCR100.dll_void___cdecl_operator_delete_void____ptr64_
nop
or eax, 0xffffffff
lock xadd dword [rbx + 0x10], eax
dec eax
jne 0x40b31c
mov rcx, qword [rbx]
test rcx, rcx
je 0x40b306
call qword [sym.imp.OLEAUT32.dll_SysStringLen]
mov rcx, qword [rbx + 8]
test rcx, rcx
je 0x40b314
call sub.MSVCR100.dll_void___cdecl_operator_delete___void____ptr64_
mov rcx, rbx
call sub.MSVCR100.dll_void___cdecl_operator_delete_void____ptr64_
test esi, esi
jns 0x40b377
lea rdx, str.Query_for_video_controllers_failed._Error_code__0x
mov rcx, qword [sym.imp.MSVCP100.dll_class_std::basic_ostream_char__struct_std::char_traits_char___std::cout]
call fcn.00402790
mov rcx, rax
lea rdx, [0x00406130]
call qword [sym.imp.MSVCP100.dll_public:_class_std::basic_ostream_char__struct_std::char_traits_char______ptr64___cdecl_std::basic_ostream_char__struct_std::char_traits_char__::operator___class_std::ios_base____ptr64____cdecl___class_std::ios_base____ptr64_____ptr64]
mov edx, esi
mov rcx, rax
call qword [sym.imp.MSVCP100.dll_public:_class_std::basic_ostream_char__struct_std::char_traits_char______ptr64___cdecl_std::basic_ostream_char__struct_std::char_traits_char__::operator___long_int____ptr64]
mov rcx, rax
mov rdx, qword [sym.imp.MSVCP100.dll_class_std::basic_ostream_char__struct_std::char_traits_char______ptr64___cdecl_std::endl_class_std::basic_ostream_char__struct_std::char_traits_char______ptr64_]
call qword [sym.imp.MSVCP100.dll_public:_class_std::basic_ostream_char__struct_std::char_traits_char______ptr64___cdecl_std::basic_ostream_char__struct_std::char_traits_char__::operator___class_std::basic_ostream_char__struct_std::char_traits_char______ptr64____cdecl___class_std::basic_ostream_char__struct_std::char_traits_char______ptr64_____ptr64]
mov rcx, qword [rbp - 0x21]
mov rax, qword [rcx]
call qword [rax + 0x10]
mov rcx, qword [rbp + 0x77]
mov rax, qword [rcx]
call qword [rax + 0x10]
jmp 0x40b0a7
mov qword [rbp + 0x7f], r12
mov rcx, qword [rbp - 0x29]
mov rax, qword [rcx]
call qword [rax + 0x18]
mov rcx, qword [rbp - 0x29]
mov rax, qword [rcx]
lea rdx, [rbp + 0x67]
mov qword [rsp + 0x20], rdx
lea r9, [rbp + 0x7f]
mov r8d, 1
or edx, 0xffffffff
call qword [rax + 0x20]
cmp dword [rbp + 0x67], 0
je 0x40b4ff
nop
lea rcx, [rbp - 0x19]
call qword [sym.imp.OLEAUT32.dll_VariantClear]
lea rcx, [rbp - 1]
call qword [sym.imp.OLEAUT32.dll_VariantClear]
lea rcx, str.AdapterRAM
call qword [sym.imp.OLEAUT32.dll_SysReAllocString]
mov rbx, rax
mov rcx, qword [rbp + 0x7f]
mov r10, qword [rcx]
mov qword [rsp + 0x28], r12
mov qword [rsp + 0x20], r12
lea r9, [rbp - 0x19]
xor r8d, r8d
mov rdx, rax
call qword [r10 + 0x20]
mov rcx, rbx
call qword [sym.imp.OLEAUT32.dll_SysStringLen]
lea rcx, str.Caption
call qword [sym.imp.OLEAUT32.dll_SysReAllocString]
mov rbx, rax
mov rcx, qword [rbp + 0x7f]
mov r10, qword [rcx]
mov qword [rsp + 0x28], r12
mov qword [rsp + 0x20], r12
lea r9, [rbp - 1]
xor r8d, r8d
mov rdx, rax
call qword [r10 + 0x20]
mov edi, eax
mov rcx, rbx
call qword [sym.imp.OLEAUT32.dll_SysStringLen]
mov rcx, qword [rbp + 0x7f]
mov rdx, qword [rcx]
call qword [rdx + 0x10]
mov rcx, qword [sym.imp.MSVCP100.dll_class_std::basic_ostream_char__struct_std::char_traits_char___std::cout]
test edi, edi
js 0x40b4dc
lea rdx, str.Device:
call fcn.00402790
mov rcx, rax
mov rdx, qword [rbp + 7]
call qword [sym.imp.MSVCP100.dll_public:_class_std::basic_ostream_char__struct_std::char_traits_char______ptr64___cdecl_std::basic_ostream_char__struct_std::char_traits_char__::operator___void_const____ptr64____ptr64]
mov ebx, dword [rbp - 0x11]
shr ebx, 0x14
lea rdx, str._has_video_RAM_MB_:
mov rcx, qword [sym.imp.MSVCP100.dll_class_std::basic_ostream_char__struct_std::char_traits_char___std::cout]
call fcn.00402790
mov rcx, rax
mov edx, ebx
call qword [sym.imp.MSVCP100.dll_public:_class_std::basic_ostream_char__struct_std::char_traits_char______ptr64___cdecl_std::basic_ostream_char__struct_std::char_traits_char__::operator___unsigned_int____ptr64]
mov rcx, rax
mov rdx, qword [sym.imp.MSVCP100.dll_class_std::basic_ostream_char__struct_std::char_traits_char______ptr64___cdecl_std::endl_class_std::basic_ostream_char__struct_std::char_traits_char______ptr64_]
call qword [sym.imp.MSVCP100.dll_public:_class_std::basic_ostream_char__struct_std::char_traits_char______ptr64___cdecl_std::basic_ostream_char__struct_std::char_traits_char__::operator___class_std::basic_ostream_char__struct_std::char_traits_char______ptr64____cdecl___class_std::basic_ostream_char__struct_std::char_traits_char______ptr64_____ptr64]
lea rcx, [rbp - 1]
call qword [sym.imp.OLEAUT32.dll_VariantCopy]
lea rcx, [rbp - 0x19]
call qword [sym.imp.OLEAUT32.dll_VariantCopy]
mov rcx, qword [rbp - 0x29]
mov rax, qword [rcx]
lea rdx, [rbp + 0x67]
mov qword [rsp + 0x20], rdx
lea r9, [rbp + 0x7f]
mov r8d, 1
or edx, 0xffffffff
call qword [rax + 0x20]
cmp dword [rbp + 0x67], 0
jne 0x40b3b0
jmp 0x40b4ff
lea rdx, str.Query_adapter_ram_failed._Error_code__0x
call fcn.00402790
mov rcx, rax
lea rdx, [0x00406130]
call qword [sym.imp.MSVCP100.dll_public:_class_std::basic_ostream_char__struct_std::char_traits_char______ptr64___cdecl_std::basic_ostream_char__struct_std::char_traits_char__::operator___class_std::ios_base____ptr64____cdecl___class_std::ios_base____ptr64_____ptr64]
mov edx, edi
jmp 0x40b345
mov rcx, qword [rbp - 0x21]
mov rax, qword [rcx]
call qword [rax + 0x10]
mov rcx, qword [rbp + 0x77]
mov rax, qword [rcx]
call qword [rax + 0x10]
mov rcx, qword [rbp - 0x29]
mov rax, qword [rcx]
call qword [rax + 0x10]
call qword [sym.imp.ole32.dll_CoUninitialize]
xor eax, eax
add rsp, 0xb0
pop r12
pop rdi
pop rsi
pop rbx
pop rbp
ret