Function at 0x499020
Capabilities:
Get disk information via ioctl
Get storage device properties
Link many functions at runtime
Resolve function by parsing pe exports

Disassembly:
sub esp, 0x29c
mov eax, dword [0x614b80]
xor eax, esp
mov dword [esp + 0x298], eax
mov eax, dword [esp + 0x2a4]
mov ecx, dword [esp + 0x2a8]
push ebx
push esi
mov esi, dword [sym.imp.KERNEL32.DLL_LoadLibraryA]
push edi
push str.setupapi.dll
mov dword [esp + 0x48], eax
mov dword [esp + 0x54], ecx
mov dword [esp + 0x40], 0
call esi
push str.cfgmgr32.dll
mov edi, eax
call esi
mov ebx, eax
test edi, edi
je 0x4993e4
test ebx, ebx
je 0x4993e4
mov esi, dword [sym.imp.KERNEL32.DLL_GetProcAddress]
push ebp
push str.SetupDiGetClassDevsA
push edi
call esi
push str.SetupDiDestroyDeviceInfoList
push edi
mov ebp, eax
call esi
push str.SetupDiEnumDeviceInterfaces
push edi
mov dword [esp + 0x28], eax
call esi
push str.SetupDiGetDeviceInterfaceDetailA
push edi
mov dword [esp + 0x24], eax
call esi
push str.SetupDiGetDeviceInstanceIdA
push edi
mov dword [esp + 0x40], eax
call esi
push str.CM_Locate_DevNodeA
mov edi, eax
push ebx
mov dword [esp + 0x3c], edi
call esi
push str.CM_Get_Parent
push ebx
mov dword [esp + 0x34], eax
call esi
push str.CM_Get_Device_ID_Size
push ebx
mov dword [esp + 0x44], eax
call esi
push str.CM_Get_Device_IDA
push ebx
mov dword [esp + 0x2c], eax
call esi
xor esi, esi
mov dword [esp + 0x4c], eax
cmp ebp, esi
je 0x4993e3
cmp dword [esp + 0x20], esi
je 0x4993e3
cmp dword [esp + 0x1c], esi
je 0x4993e3
mov ebx, dword [esp + 0x38]
cmp ebx, esi
je 0x4993e3
cmp edi, esi
je 0x4993e3
cmp dword [esp + 0x2c], esi
je 0x4993e3
cmp dword [esp + 0x3c], esi
je 0x4993e3
cmp dword [esp + 0x24], esi
je 0x4993e3
cmp eax, esi
je 0x4993e3
push 0x12
push esi
push esi
push 0x5a0fc4
call ebp
mov edi, eax
cmp edi, 0xffffffff
je 0x4993e3
lea edx, [esp + 0x70]
push edx
push esi
push 0x5a0fc4
mov eax, 0x1c
push esi
push edi
mov dword [esp + 0x84], eax
mov dword [esp + 0xa0], eax
mov dword [esp + 0x44], esi
call dword [esp + 0x30]
test eax, eax
je 0x4993de
jmp 0x499194
mov ebx, dword [esp + 0x38]
push esi
lea eax, [esp + 0x1c]
push eax
push esi
push esi
lea ecx, [esp + 0x80]
push ecx
push edi
call ebx
mov edx, dword [esp + 0x18]
push edx
call fcn.0057a62b
add esp, 4
mov ebp, eax
lea eax, [esp + 0x8c]
push eax
lea ecx, [esp + 0x1c]
push ecx
mov dword [ebp], 5
mov edx, dword [esp + 0x20]
push edx
push ebp
lea eax, [esp + 0x80]
push eax
push edi
call ebx
test eax, eax
je 0x4993b3
push esi
push esi
push 3
push esi
push 3
push 0xc0000000
lea ecx, [ebp + 4]
push ecx
call dword [sym.imp.KERNEL32.DLL_CreateFileA]
mov ebx, eax
cmp ebx, 0xffffffff
je 0x4993b3
push esi
lea edx, [esp + 0x48]
push edx
push 0x200
lea eax, [esp + 0xb4]
push eax
push 0xc
lea ecx, [esp + 0x78]
push ecx
push 0x2d1400
mov dword [esp + 0x2c], esi
mov dword [esp + 0x80], esi
mov dword [esp + 0x84], esi
mov esi, dword [sym.imp.KERNEL32.DLL_DeviceIoControl]
push ebx
call esi
test eax, eax
je 0x4993aa
cmp dword [esp + 0xc4], 7
jne 0x4993aa
push 0
lea edx, [esp + 0x48]
push edx
push 0xc
lea eax, [esp + 0x64]
push eax
push 0
push 0
push 0x2d1080
push ebx
call esi
test eax, eax
je 0x4993aa
mov ecx, dword [esp + 0x2b0]
cmp dword [esp + 0x5c], ecx
jne 0x4993aa
lea edx, [esp + 0x14]
push edx
push 0
push 0
lea eax, [esp + 0x98]
push eax
push edi
mov dword [esp + 0x28], 0
call dword [esp + 0x48]
mov ecx, dword [esp + 0x14]
push ecx
call fcn.0057a62b
add esp, 4
mov esi, eax
mov eax, dword [esp + 0x14]
lea edx, [esp + 0x14]
push edx
push eax
push esi
lea ecx, [esp + 0x98]
push ecx
push edi
call dword [esp + 0x48]
test eax, eax
je 0x4993a1
push 0
push esi
lea edx, [esp + 0x58]
push edx
call dword [esp + 0x38]
test eax, eax
jne 0x4993a1
push eax
mov eax, dword [esp + 0x54]
push eax
lea ecx, [esp + 0x30]
push ecx
call dword [esp + 0x48]
test eax, eax
jne 0x4993a1
mov edx, dword [esp + 0x28]
push eax
push edx
lea eax, [esp + 0x18]
push eax
call dword [esp + 0x30]
test eax, eax
jne 0x4993a1
mov eax, dword [esp + 0x10]
inc eax
mov dword [esp + 0x10], eax
cmp eax, dword [esp + 0x14]
jbe 0x49933a
push esi
call fcn.0057a735
mov ecx, dword [esp + 0x14]
push ecx
call fcn.0057a62b
add esp, 8
mov esi, eax
mov edx, dword [esp + 0x10]
mov eax, dword [esp + 0x28]
push 0
push edx
push esi
push eax
call dword [esp + 0x5c]
test eax, eax
jne 0x4993a1
push str.VID_
push esi
call fcn.0057a220
add esp, 8
test eax, eax
je 0x499374
mov ecx, dword [esp + 0x48]
push ecx
push str.VID__X
push eax
call fcn.0057a332
add esp, 0xc
push str.PID_
push esi
call fcn.0057a220
add esp, 8
test eax, eax
je 0x499399
mov edx, dword [esp + 0x54]
push edx
push str.PID__X
push eax
call fcn.0057a332
add esp, 0xc
mov dword [esp + 0x40], 1
push esi
call fcn.0057a735
add esp, 4
push ebx
call dword [sym.imp.KERNEL32.DLL_CloseHandle]
xor esi, esi
push ebp
call fcn.0057a735
mov eax, dword [esp + 0x34]
add esp, 4
lea ecx, [esp + 0x70]
push ecx
inc eax
push eax
push 0x5a0fc4
push esi
push edi
mov dword [esp + 0x44], eax
call dword [esp + 0x30]
test eax, eax
jne 0x499190
push edi
call dword [esp + 0x24]
pop ebp
mov ecx, dword [esp + 0x2a4]
mov eax, dword [esp + 0x3c]
pop edi
pop esi
pop ebx
xor ecx, esp
call fcn.0057943e
add esp, 0x29c
ret 0xc