Function at 0x4065c0
Capabilities:
Connect to wmi namespace via wbemlocator

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x44c193
mov eax, dword fs:[0]
push eax
push ecx
mov eax, 0x1118
call fcn.00416240
mov eax, dword [0x46706c]
xor eax, ebp
mov dword [ebp - 0x14], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov dword [ebp - 0x10], esp
mov esi, dword [ebp + 0xc]
xor ebx, ebx
xor eax, eax
mov dword [ebp - 0x10ec], esi
mov dword [ebp - 0x10e4], 0
mov dword [ebp - 0x10f0], ebx
mov dword [ebp - 0x1038], ebx
mov dword [ebp - 0x1034], 7
mov word [ebp - 0x1048], ax
mov dword [ebp - 4], eax
mov dword [ebp - 0x1020], eax
mov dword [ebp - 0x101c], 7
mov word [ebp - 0x1030], ax
mov dword [ebp - 0x10b0], eax
mov dword [ebp - 0x10ac], 7
mov word [ebp - 0x10c0], ax
push eax
mov byte [ebp - 4], 2
call dword [sym.imp.ole32.dll_CoInitialize]
test eax, eax
jns 0x406718
call dword [sym.imp.ole32.dll_CoUninitialize]
mov edx, dword [ebp - 0x101c]
cmp edx, 8
jb 0x4066b4
mov ecx, dword [ebp - 0x1030]
lea edx, [edx*2 + 2]
mov eax, ecx
cmp edx, 0x1000
jb 0x4066aa
mov ecx, dword [ecx - 4]
add edx, 0x23
sub eax, ecx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x40724a
push edx
push ecx
call fcn.004154b6
add esp, 8
mov edx, dword [ebp - 0x1034]
xor eax, eax
mov dword [ebp - 0x1020], 0
mov dword [ebp - 0x101c], 7
mov word [ebp - 0x1030], ax
cmp edx, 8
jb 0x406711
mov ecx, dword [ebp - 0x1048]
lea edx, [edx*2 + 2]
mov eax, ecx
cmp edx, 0x1000
jb 0x406707
mov ecx, dword [ecx - 4]
add edx, 0x23
sub eax, ecx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x40724f
push edx
push ecx
call fcn.004154b6
add esp, 8
xor eax, eax
jmp 0x4068b1
push 0
push 0
push 0
push 3
push 0
push 0
push 0
push 0xffffffffffffffff
push 0
call dword [sym.imp.ole32.dll_CoInitializeSecurity]
cmp eax, 0x80010119
je 0x40673f
test eax, eax
js 0x40666e
lea eax, [ebp - 0x10dc]
mov dword [ebp - 0x10dc], 0
push eax
push 0x44e400
push 1
push 0
push 0x44e3f0
call dword [sym.imp.ole32.dll_CoCreateInstance]
test eax, eax
js 0x40666e
mov eax, dword [ebp - 0x10dc]
lea edx, [ebp - 0x10cc]
push edx
push 0
push 0
push 0
push 0
push 0
push 0
mov dword [ebp - 0x10cc], 0
mov ecx, dword [eax]
push str.ROOTCIMV2
push eax
call dword [ecx + 0xc]
test eax, eax
js 0x40666e
push 0
push 0
push 3
push 3
push 0
push 0
push 0xa
push dword [ebp - 0x10cc]
call dword [sym.imp.ole32.dll_CoSetProxyBlanket]
test eax, eax
js 0x40666e
push 0x800
lea eax, [ebp - 0x1018]
push 0
push eax
call fcn.0042d530
add esp, 0xc
lea eax, [ebp - 0x1018]
push str.Win32_DiskDrive
push str.select_DeviceID__PNPDeviceID__Caption__PNPDeviceID__Index__SCSIBus__SCSIPort__SCSILogicalUnit__SCSITargetId__Index_from__s
push 0x400
push eax
call fcn.004011f0
mov eax, dword [ebp - 0x10cc]
lea edx, [ebp - 0x10e0]
add esp, 0x10
mov dword [ebp - 0x10e0], 0
mov ecx, dword [eax]
push edx
push 0
push 0x30
lea edx, [ebp - 0x1018]
push edx
push 0x45cfbc
push eax
call dword [ecx + 0x50]
test eax, eax
js 0x40666e
mov dword [ebp - 0x10d0], 0
nop word [eax + eax]
mov ecx, dword [ebp - 0x10e0]
test ecx, ecx
je 0x406876
lea edx, [ebp - 0x1104]
mov dword [ebp - 0x1104], 0
mov eax, dword [ecx]
push edx
lea edx, [ebp - 0x10d0]
push edx
push 1
push 0xffffffffffffffff
push ecx
call dword [eax + 0x10]
test eax, eax
je 0x4068cf
call dword [sym.imp.KERNEL32.dll_GetLastError]
lea eax, [ebp - 0x1128]
push eax
call dword [sym.imp.OLEAUT32.dll_VariantCopy]
call dword [sym.imp.ole32.dll_CoUninitialize]
call fcn.00403470
lea ecx, [ebp - 0x10c0]
call fcn.00403740
lea ecx, [ebp - 0x1030]
call fcn.00403740
lea ecx, [ebp - 0x1048]
call fcn.00403740
mov eax, ebx
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 0x14]
xor ecx, ebp
call fcn.00414edc
mov esp, ebp
pop ebp
ret 8
mov eax, dword [ebp - 0x10d0]
lea edx, [ebp - 0x10c4]
push edx
push 0
push 0x70
mov dword [ebp - 0x10c4], 0
mov ecx, dword [eax]
push 0
push eax
call dword [ecx + 0x1c]
test eax, eax
jne 0x407232
lea eax, [ebp - 0x1108]
push eax
push 1
push dword [ebp - 0x10c4]
call dword [sym.imp.OLEAUT32.dll_SafeArrayLock]
lea eax, [ebp - 0x110c]
push eax
push 1
push dword [ebp - 0x10c4]
call dword [sym.imp.OLEAUT32.dll_SafeArrayGetLBound]
mov eax, dword [ebp - 0x1108]
mov dword [ebp - 0x10d8], eax
cmp eax, dword [ebp - 0x110c]
jg 0x407232
mov dword [ebp - 0x1110], eax
lea eax, [ebp - 0x10d4]
push eax
lea eax, [ebp - 0x1110]
mov dword [ebp - 0x10d4], 0
push eax
push dword [ebp - 0x10c4]
call dword [sym.imp.OLEAUT32.dll_SafeArrayPutElement]
lea eax, [ebp - 0x1100]
push eax
call dword [sym.imp.OLEAUT32.dll_VariantClear]
mov eax, dword [ebp - 0x10d0]
lea edx, [ebp - 0x1100]
push 0
push 0
push edx
mov ecx, dword [eax]
push 0
push dword [ebp - 0x10d4]
push eax
call dword [ecx + 0x10]
test eax, eax
js 0x406a4b
cmp word [ebp - 0x1100], 1
je 0x406a46
push dword [ebp - 0x10d4]
lea ecx, [ebp - 0x10a8]
call fcn.00403820
push 0x800
lea eax, [ebp - 0x818]
mov byte [ebp - 4], 3
push 0
push eax
call fcn.0042d530
add esp, 8
lea ecx, [ebp - 0x10a8]
push str.DeviceID
call fcn.004036b0
cmp eax, 0xffffffff
je 0x406a63
push dword [ebp - 0x10f8]
lea eax, [ebp - 0x818]
push 0x400
push eax
call fcn.004011f0
lea ecx, [ebp - 0x818]
add esp, 0xc
lea edx, [ecx + 2]
nop dword [eax + eax]
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x406a10
sub ecx, edx
lea eax, [ebp - 0x818]
sar ecx, 1
push ecx
imul ecx, ebx, 0x108
push eax
add ecx, 0x48
add ecx, esi
call fcn.00403ae0
lea ecx, [ebp - 0x10a8]
mov byte [ebp - 4], 2
call fcn.00403740
call fcn.00403470
mov eax, dword [ebp - 0x10d8]
mov ebx, dword [ebp - 0x10f0]
inc eax
mov esi, dword [ebp - 0x10ec]
jmp 0x40692a
push ecx
push str.PNPDeviceID
lea ecx, [ebp - 0x10a8]
call fcn.004036b0
cmp eax, 0xffffffff
je 0x406ac5
push dword [ebp - 0x10f8]
lea eax, [ebp - 0x818]
push 0x400
push eax
call fcn.004011f0
lea ecx, [ebp - 0x818]
add esp, 0xc
lea edx, [ecx + 2]
nop dword [eax]
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x406aa0
sub ecx, edx
lea eax, [ebp - 0x818]
sar ecx, 1
push ecx
imul ecx, ebx, 0x108
push eax
add ecx, 0x18
jmp 0x406a30
push ecx
push str.Caption
lea ecx, [ebp - 0x10a8]
call fcn.004036b0
cmp eax, 0xffffffff
je 0x406b25
push dword [ebp - 0x10f8]
lea eax, [ebp - 0x818]
push 0x400
push eax
call fcn.004011f0
lea eax, [ebp - 0x818]
add esp, 0xc
lea edx, [eax + 2]
nop
mov cx, word [eax]
add eax, 2
test cx, cx
jne 0x406b00
sub eax, edx
imul ecx, ebx, 0x108
sar eax, 1
push eax
lea eax, [ebp - 0x818]
push eax
add ecx, 0x60
jmp 0x406a30
push ecx
push str.Index
lea ecx, [ebp - 0x10a8]
call fcn.004036b0
cmp eax, 0xffffffff
je 0x406ba9
mov edx, dword [ebp - 0x10f8]
lea ecx, [ebp - 0x1090]
call fcn.00404a10
imul ecx, ebx, 0x108
push eax
add ecx, 0x90
add ecx, esi
call fcn.004037a0
mov edx, dword [ebp - 0x107c]
cmp edx, 8
jb 0x406a37
mov ecx, dword [ebp - 0x1090]
lea edx, [edx*2 + 2]
mov eax, ecx
cmp edx, 0x1000
jb 0x406b9a
mov ecx, dword [ecx - 4]
add edx, 0x23
sub eax, ecx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x40724a
push edx
push ecx
call fcn.004154b6
add esp, 8
jmp 0x406a37
push ecx
push str.SCSIBus
lea ecx, [ebp - 0x10a8]
call fcn.004036b0
cmp eax, 0xffffffff
je 0x406be2
mov edx, dword [ebp - 0x10f8]
lea ecx, [ebp - 0x1090]
call fcn.00404a10
imul ecx, ebx, 0x108
push eax
add ecx, 0xa8
jmp 0x406b59
push ecx
push str.SCSIPort
lea ecx, [ebp - 0x10a8]
call fcn.004036b0
cmp eax, 0xffffffff
je 0x406c1b
mov edx, dword [ebp - 0x10f8]
lea ecx, [ebp - 0x1090]
call fcn.00404a10
imul ecx, ebx, 0x108
push eax
add ecx, 0xc0
jmp 0x406b59
push ecx
push str.SCSILogicalUnit
lea ecx, [ebp - 0x10a8]
call fcn.004036b0
cmp eax, 0xffffffff
je 0x406c54
mov edx, dword [ebp - 0x10f8]
lea ecx, [ebp - 0x1090]
call fcn.00404a10
imul ecx, ebx, 0x108
push eax
add ecx, 0xf0
jmp 0x406b59
push ecx
push str.SCSITargetId
lea ecx, [ebp - 0x10a8]
call fcn.004036b0
cmp eax, 0xffffffff
je 0x406a37
push 0x45cc3c
lea ecx, [ebp - 0x1090]
call fcn.00403820
mov byte [ebp - 4], 4
lea ecx, [ebp - 0x1060]
mov edx, dword [ebp - 0x10f8]
call fcn.00404a10
imul ebx, ebx, 0x108
push eax
add ebx, esi
lea ecx, [ebx + 0xd8]
call fcn.004037a0
mov edx, dword [ebp - 0x104c]
cmp edx, 8
jb 0x406ce7
mov ecx, dword [ebp - 0x1060]
lea edx, [edx*2 + 2]
mov eax, ecx
cmp edx, 0x1000
jb 0x406cdd
mov ecx, dword [ecx - 4]
add edx, 0x23
sub eax, ecx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x40724a
push edx
push ecx
call fcn.004154b6
add esp, 8
mov byte [ebp - 4], 5
call fcn.00435653
cmp dword [ebx + 0xa4], 8
lea esi, [ebx + 0x90]
mov edi, eax
jb 0x406d03
mov esi, dword [esi]
push 0xa
lea eax, [ebp - 0x1114]
mov dword [edi], 0
push eax
push esi
call fcn.00434964
add esp, 0xc
mov dword [ebp - 0x10e8], eax
cmp esi, dword [ebp - 0x1114]
je 0x407254
cmp dword [edi], 0x22
je 0x407263
mov dword [ebp - 4], 4
cmp eax, 0xffffffff
je 0x407196
lea eax, [ebp - 0x1048]
push eax
push ebx
call fcn.00407f30
test eax, eax
jne 0x406eb5
mov dword [ebp - 0x1050], eax
mov dword [ebp - 0x104c], 7
mov word [ebp - 0x1060], ax
mov dword [ebp - 0x1068], eax
mov dword [ebp - 0x1064], 7
mov word [ebp - 0x1078], ax
mov esi, dword [ebp - 0x10e8]
lea eax, [ebp - 0x1078]
push eax
lea eax, [ebp - 0x1060]
mov byte [ebp - 4], 8
push eax
push esi
call fcn.00408430
test eax, eax
jne 0x406ddb
lea eax, [ebp - 0x1078]
push eax
lea eax, [ebp - 0x1060]
push eax
push ecx
call fcn.004086a0
test eax, eax
jne 0x406ddb
lea eax, [ebp - 0x1078]
push eax
lea eax, [ebp - 0x1060]
push eax
push esi
call fcn.004089c0
test eax, eax
je 0x406e10
cmp dword [ebp - 0x1064], 8
lea edx, [ebp - 0x1078]
cmovae edx, dword [ebp - 0x1078]
mov ecx, edx
lea esi, [ecx + 2]
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x406df4
sub ecx, esi
sar ecx, 1
push ecx
push edx
lea ecx, [ebp - 0x1048]
call fcn.00403c20
mov byte [ebp - 4], 7
mov edx, dword [ebp - 0x1064]
cmp edx, 8
jb 0x406e54
mov ecx, dword [ebp - 0x1078]
lea edx, [edx*2 + 2]
mov eax, ecx
cmp edx, 0x1000
jb 0x406e4a
mov ecx, dword [ecx - 4]
add edx, 0x23
sub eax, ecx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x40724a
push edx
push ecx
call fcn.004154b6
add esp, 8
xor eax, eax
mov byte [ebp - 4], 4
mov edx, dword [ebp - 0x104c]
mov dword [ebp - 0x1068], 0
mov dword [ebp - 0x1064], 7
mov word [ebp - 0x1078], ax
cmp edx, 8
jb 0x406eb5
mov ecx, dword [ebp - 0x1060]
lea edx, [edx*2 + 2]
mov eax, ecx
cmp edx, 0x1000
jb 0x406eab
mov ecx, dword [ecx - 4]
add edx, 0x23
sub eax, ecx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x40724a
push edx
push ecx
call fcn.004154b6
add esp, 8
mov eax, dword [ebp - 0x1038]
xor edx, edx
mov edi, dword [ebp - 0x1048]
mov dword [ebp - 0x10c8], eax
lea ecx, [eax - 1]
test ecx, ecx
js 0x406f46
mov esi, dword [ebp - 0x1034]
nop word [eax + eax]
cmp esi, 8
lea eax, [ebp - 0x1048]
cmovae eax, edi
movzx eax, word [eax + edx*2]
test eax, 0xffffff80
jne 0x406f00
mov eax, dword [eax*4 + 0x45dcf8]
jmp 0x406f02
xor eax, eax
shr eax, 1
test al, 1
je 0x406f0f
inc edx
cmp edx, ecx
jle 0x406ee0
jmp 0x406f40
cmp ecx, edx
jl 0x406f40
cmp esi, 8
lea eax, [ebp - 0x1048]
cmovae eax, edi
movzx eax, word [eax + ecx*2]
test eax, 0xffffff80
jne 0x406f33
mov eax, dword [eax*4 + 0x45dcf8]
jmp 0x406f35
xor eax, eax
shr eax, 1
test al, 1
je 0x406f40
dec ecx
cmp ecx, edx
jge 0x406f13
mov eax, dword [ebp - 0x10c8]
xor esi, esi
mov dword [ebp - 0x1050], 0
mov word [ebp - 0x1060], si
mov esi, dword [ebp - 0x1034]
mov dword [ebp - 0x104c], 7
cmp eax, edx
jb 0x40725e
sub ecx, edx
sub eax, edx
inc ecx
cmp eax, ecx
cmovb ecx, eax
cmp esi, 8
lea eax, [ebp - 0x1048]
cmovae eax, edi
push ecx
lea ecx, [ebp - 0x1060]
lea eax, [eax + edx*2]
push eax
call fcn.00403ae0
or dword [ebp - 0x10e4], 1
lea eax, [ebp - 0x1060]
push eax
lea ecx, [ebx + 0x78]
call fcn.004037a0
mov edx, dword [ebp - 0x104c]
cmp edx, 8
jb 0x406fed
mov ecx, dword [ebp - 0x1060]
lea edx, [edx*2 + 2]
mov eax, ecx
cmp edx, 0x1000
jb 0x406fe3
mov ecx, dword [ecx - 4]
add edx, 0x23
sub eax, ecx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x40724a
push edx
push ecx
call fcn.004154b6
add esp, 8
push str.Disk_drive
lea ecx, [ebx + 0x60]
call fcn.004044e0
test al, al
jne 0x407008
cmp dword [ebx + 0x70], 0
jne 0x407155
lea eax, [ebp - 0x1030]
push eax
push ebx
call fcn.00408f90
test eax, eax
jne 0x407146
mov dword [ebp - 0x1050], eax
mov dword [ebp - 0x104c], 7
mov word [ebp - 0x1060], ax
mov dword [ebp - 0x1068], eax
mov dword [ebp - 0x1064], 7
mov word [ebp - 0x1078], ax
lea eax, [ebp - 0x1078]
mov byte [ebp - 4], 0xa
push eax
lea eax, [ebp - 0x1060]
push eax
push dword [ebp - 0x10e8]
call fcn.004089c0
test eax, eax
je 0x4070a1
cmp dword [ebp - 0x104c], 8
lea edx, [ebp - 0x1060]
cmovae edx, dword [ebp - 0x1060]
mov ecx, edx
lea edi, [ecx + 2]
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x407085
sub ecx, edi
sar ecx, 1
push ecx
push edx
lea ecx, [ebp - 0x1030]
call fcn.00403c20
mov byte [ebp - 4], 9
mov edx, dword [ebp - 0x1064]
cmp edx, 8
jb 0x4070e5
mov ecx, dword [ebp - 0x1078]
lea edx, [edx*2 + 2]
mov eax, ecx
cmp edx, 0x1000
jb 0x4070db
mov ecx, dword [ecx - 4]
add edx, 0x23
sub eax, ecx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x40724a
push edx
push ecx
call fcn.004154b6
add esp, 8
xor eax, eax
mov byte [ebp - 4], 4
mov edx, dword [ebp - 0x104c]
mov dword [ebp - 0x1068], 0
mov dword [ebp - 0x1064], 7
mov word [ebp - 0x1078], ax
cmp edx, 8
jb 0x407146
mov ecx, dword [ebp - 0x1060]
lea edx, [edx*2 + 2]
mov eax, ecx
cmp edx, 0x1000
jb 0x40713c
mov ecx, dword [ecx - 4]
add edx, 0x23
sub eax, ecx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x40724a
push edx
push ecx
call fcn.004154b6
add esp, 8
lea eax, [ebp - 0x1030]
push eax
lea ecx, [ebx + 0x60]
call fcn.00403710
push 0
push 0x45cc3c
lea ecx, [ebp - 0x1030]
call fcn.00403ae0
push 0
push 0x45cc3c
lea ecx, [ebp - 0x1048]
call fcn.00403ae0
lea ecx, [ebp - 0x1090]
call fcn.00403740
jmp 0x406a37
mov byte [ebp - 4], 3
mov edx, dword [ebp - 0x107c]
cmp edx, 8
jb 0x4071d6
mov ecx, dword [ebp - 0x1090]
lea edx, [edx*2 + 2]
mov eax, ecx
cmp edx, 0x1000
jb 0x4071cc
mov ecx, dword [ecx - 4]
add edx, 0x23
sub eax, ecx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x40724a
push edx
push ecx
call fcn.004154b6
add esp, 8
mov byte [ebp - 4], 2
mov edx, dword [ebp - 0x1094]
cmp edx, 8
jb 0x406a4b
mov ecx, dword [ebp - 0x10a8]
lea edx, [edx*2 + 2]
mov eax, ecx
cmp edx, 0x1000
jb 0x407210
mov ecx, dword [ecx - 4]
add edx, 0x23
sub eax, ecx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x40724a
push edx
push ecx
call fcn.004154b6
mov eax, dword [ebp - 0x10d8]
add esp, 8
mov ebx, dword [ebp - 0x10f0]
inc eax
mov esi, dword [ebp - 0x10ec]
jmp 0x40692a
push dword [ebp - 0x10c4]
call dword [sym.imp.OLEAUT32.dll_SafeArrayGetDim]
inc ebx
mov dword [ebp - 0x10f0], ebx
jmp 0x406840
call fcn.004376e0
call fcn.004376e0
push str.invalid_stoi_argument
call fcn.0041347d
call fcn.00403f90
push str.stoi_argument_out_of_range
call fcn.004134bd
int3