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

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x5bbdfa
mov eax, dword fs:[0]
push eax
sub esp, 0x4c
mov eax, dword [0x629688]
xor eax, ebp
mov dword [ebp - 0x10], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov bl, dl
mov dword [ebp - 0x48], ecx
push 0
push 0
call dword [sym.imp.ole32.dll_CoInitializeEx]
xor ecx, ecx
mov dword [ebp - 0x14], 7
mov dword [ebp - 0x18], 0
mov word [ebp - 0x28], cx
mov dword [ebp - 4], ecx
test eax, eax
je 0x4c19b5
cmp eax, 1
je 0x4c19b5
cmp eax, 0x80010106
je 0x4c19b5
push eax
push str.Failed_to_Coinitialize_in_getHardDiskSerialNumber._Error_code__0x_x
push 0x5e96ac
push ecx
call fcn.00449220
add esp, 4
push eax
call fcn.00449f70
add esp, 0x10
xor bl, bl
jmp 0x4c1dc1
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]
mov esi, eax
test esi, esi
jns 0x4c1a11
cmp esi, 0x80010119
je 0x4c1a11
mov ecx, dword [0x634974]
test cl, 1
jne 0x4c1a09
or ecx, 1
mov dword [0x634974], ecx
mov byte [ebp - 4], 1
call fcn.00448ef0
push 0x5c0980
call fcn.00586165
add esp, 4
mov byte [ebp - 4], 0
push esi
push str.Failed_to_initialize_security._Error_code__0x_x
jmp 0x4c1a6a
lea eax, [ebp - 0x30]
push eax
push 0x5c92ec
push 1
push 0
push 0x5c928c
mov dword [ebp - 0x30], 0
call dword [sym.imp.ole32.dll_CoCreateInstance]
mov esi, eax
test esi, esi
jns 0x4c1a83
mov ecx, dword [0x634974]
test cl, 1
jne 0x4c1a64
or ecx, 1
mov dword [0x634974], ecx
mov byte [ebp - 4], 2
call fcn.00448ef0
push 0x5c0980
call fcn.00586165
add esp, 4
mov byte [ebp - 4], 0
push esi
push str.Failed_to_create_IWbemLocator_object._Err_code__0x_x
push 0x5e96ac
push 0x6348e0
call fcn.00449f70
add esp, 0x10
xor bl, bl
jmp 0x4c1dc1
push str.ROOTCIMV2
lea ecx, [ebp - 0x3c]
mov dword [ebp - 0x2c], 0
call fcn.004c1820
mov byte [ebp - 4], 3
mov eax, dword [eax]
test eax, eax
je 0x4c1aa5
mov edx, dword [eax]
jmp 0x4c1aa7
xor edx, edx
mov eax, dword [ebp - 0x30]
lea esi, [ebp - 0x2c]
mov ecx, dword [eax]
push esi
push 0
push 0
push 0
push 0
push 0
push 0
push edx
push eax
call dword [ecx + 0xc]
mov byte [ebp - 4], 0
mov esi, dword [ebp - 0x3c]
mov edi, eax
test esi, esi
je 0x4c1b13
lea ecx, [esi + 8]
push ecx
call dword [sym.imp.KERNEL32.dll_InterlockedDecrement]
test eax, eax
jne 0x4c1b13
test esi, esi
je 0x4c1b13
mov eax, dword [esi]
test eax, eax
je 0x4c1af3
push eax
call dword [sym.imp.OLEAUT32.dll_SysStringLen]
mov dword [esi], 0
mov eax, dword [esi + 4]
test eax, eax
je 0x4c1b0a
push eax
call fcn.00586d16
add esp, 4
mov dword [esi + 4], 0
push esi
call fcn.0058603b
add esp, 4
test edi, edi
jns 0x4c1b44
push edi
push str.Could_not_connect_while_getting_hdd_serial_number._Error_code__0x_x
push 0x5e96ac
push ecx
call fcn.00449220
add esp, 4
push eax
call fcn.00449f70
mov eax, dword [ebp - 0x30]
add esp, 0x10
mov ecx, dword [eax]
push eax
call dword [ecx + 8]
xor bl, bl
jmp 0x4c1dc1
push 0
push 0
push 3
push 3
push 0
push 0
push 0xa
push dword [ebp - 0x2c]
call dword [sym.imp.ole32.dll_CoSetProxyBlanket]
test eax, eax
jns 0x4c1b95
push eax
push str.Could_not_set_proxy_blanket._Error_code__0x_x
push 0x5e96ac
push ecx
call fcn.00449220
add esp, 4
push eax
call fcn.00449f70
mov eax, dword [ebp - 0x2c]
add esp, 0x10
mov ecx, dword [eax]
push eax
call dword [ecx + 8]
mov eax, dword [ebp - 0x30]
push eax
mov ecx, dword [eax]
call dword [ecx + 8]
xor bl, bl
jmp 0x4c1dc1
mov ecx, str.SELECT__FROM_Win32_DiskDrive_where_interfaceType___USB
mov eax, str.SELECT__FROM_Win32_DiskDrive_where_interfaceType__USB
test bl, bl
cmove eax, ecx
push eax
lea ecx, [ebp - 0x3c]
call fcn.004c1790
mov byte [ebp - 4], 4
push 0x5f32c0
lea ecx, [ebp - 0x44]
mov dword [ebp - 0x34], 0
call fcn.004c1790
mov byte [ebp - 4], 5
mov esi, dword [ebp - 0x3c]
test esi, esi
je 0x4c1bd4
mov edi, dword [esi]
jmp 0x4c1bd6
xor edi, edi
mov eax, dword [eax]
test eax, eax
je 0x4c1be0
mov edx, dword [eax]
jmp 0x4c1be2
xor edx, edx
mov eax, dword [ebp - 0x2c]
lea ebx, [ebp - 0x34]
mov ecx, dword [eax]
push ebx
push 0
push 0x30
push edi
push edx
push eax
call dword [ecx + 0x50]
mov byte [ebp - 4], 4
mov edi, dword [ebp - 0x44]
mov ebx, eax
test edi, edi
je 0x4c1c47
lea ecx, [edi + 8]
push ecx
call dword [sym.imp.KERNEL32.dll_InterlockedDecrement]
test eax, eax
jne 0x4c1c47
test edi, edi
je 0x4c1c47
mov eax, dword [edi]
test eax, eax
je 0x4c1c27
push eax
call dword [sym.imp.OLEAUT32.dll_SysStringLen]
mov dword [edi], 0
mov eax, dword [edi + 4]
test eax, eax
je 0x4c1c3e
push eax
call fcn.00586d16
add esp, 4
mov dword [edi + 4], 0
push edi
call fcn.0058603b
add esp, 4
test ebx, ebx
jns 0x4c1c81
push ebx
push str.Query_for_operating_system_name_failed._Error_code__0x_x
push 0x5e96ac
push ecx
call fcn.00449220
add esp, 4
push eax
call fcn.00449f70
mov eax, dword [ebp - 0x2c]
add esp, 0x10
mov ecx, dword [eax]
push eax
call dword [ecx + 8]
mov eax, dword [ebp - 0x30]
push eax
mov ecx, dword [eax]
call dword [ecx + 8]
xor bl, bl
jmp 0x4c1d7c
mov ecx, dword [ebp - 0x34]
xor bl, bl
mov dword [ebp - 0x38], 0
mov dword [ebp - 0x40], 0
test ecx, ecx
je 0x4c1d64
mov edi, dword [sym.imp.KERNEL32.dll_GetLastError]
mov eax, dword [ecx]
lea edx, [ebp - 0x40]
push edx
lea edx, [ebp - 0x38]
push edx
push 1
push 0xffffffffffffffff
push ecx
call dword [eax + 0x10]
cmp dword [ebp - 0x40], 0
je 0x4c1d61
mov eax, dword [ebp - 0x38]
push 0
mov ecx, dword [eax]
push 0
lea edx, [ebp - 0x58]
push edx
push 0
push str.SerialNumber
push eax
call dword [ecx + 0x10]
test eax, eax
jns 0x4c1d21
mov eax, dword [0x634974]
test al, 1
jne 0x4c1d05
or eax, 1
mov dword [0x634974], eax
mov byte [ebp - 4], 6
call fcn.00448ef0
push 0x5c0980
call fcn.00586165
add esp, 4
mov byte [ebp - 4], 4
call edi
push eax
push str._Failed_in_getting_serial_Error_is_:_d
push 0x5e96ac
push 0x6348e0
call fcn.00449f70
add esp, 0x10
jmp 0x4c1d4b
cmp word [ebp - 0x58], 8
jne 0x4c1d41
push dword [ebp - 0x50]
lea ecx, [ebp - 0x28]
call fcn.00408040
mov ecx, dword [ebp - 0x48]
lea eax, [ebp - 0x28]
push eax
call fcn.004438e0
mov bl, 1
lea eax, [ebp - 0x58]
push eax
call dword [sym.imp.OLEAUT32.dll_VariantCopy]
mov eax, dword [ebp - 0x38]
push eax
mov ecx, dword [eax]
call dword [ecx + 8]
mov ecx, dword [ebp - 0x34]
test ecx, ecx
jne 0x4c1ca2
jmp 0x4c1d64
mov ecx, dword [ebp - 0x34]
mov eax, dword [ecx]
push ecx
call dword [eax + 8]
mov eax, dword [ebp - 0x30]
push eax
mov ecx, dword [eax]
call dword [ecx + 8]
mov eax, dword [ebp - 0x2c]
push eax
mov ecx, dword [eax]
call dword [ecx + 8]
test esi, esi
je 0x4c1dc1
lea eax, [esi + 8]
push eax
call dword [sym.imp.KERNEL32.dll_InterlockedDecrement]
test eax, eax
jne 0x4c1dc1
mov eax, dword [esi]
test eax, eax
je 0x4c1da1
push eax
call dword [sym.imp.OLEAUT32.dll_SysStringLen]
mov dword [esi], 0
mov eax, dword [esi + 4]
test eax, eax
je 0x4c1db8
push eax
call fcn.00586d16
add esp, 4
mov dword [esi + 4], 0
push esi
call fcn.0058603b
add esp, 4
cmp dword [ebp - 0x14], 8
jb 0x4c1dd2
push dword [ebp - 0x28]
call fcn.0058603b
add esp, 4
mov al, bl
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.00586d1b
mov esp, ebp
pop ebp
ret