Function at 0x45d440
Capabilities:
Get disk information
Get disk information via ioctl

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x300
mov eax, dword [0x48794c]
xor eax, ebp
mov dword [ebp - 4], eax
mov dword [ebp - 0x300], ecx
cmp dword [0x499ec0], 0
jne 0x45d467
jmp 0x45d9a0
push 0x12
push 0
push 0
push 0x478204
call dword [sym.imp.SETUPAPI.dll_SetupDiGetClassDevsW]
mov dword [ebp - 0x24], eax
mov dword [ebp - 0x20], 0x1c
mov dword [ebp - 0x28], 1
mov dword [ebp - 0x2c], 0
jmp 0x45d49b
mov eax, dword [ebp - 0x2c]
add eax, 1
mov dword [ebp - 0x2c], eax
lea ecx, [ebp - 0x20]
push ecx
mov edx, dword [ebp - 0x2c]
push edx
push 0x478204
push 0
mov eax, dword [ebp - 0x24]
push eax
call dword [sym.imp.SETUPAPI.dll_SetupDiEnumDeviceInterfaces]
test eax, eax
je 0x45d996
cmp dword [ebp - 0x28], 0
je 0x45d996
mov dword [ebp - 0x244], 0
push 0
lea ecx, [ebp - 0x244]
push ecx
push 0
push 0
lea edx, [ebp - 0x20]
push edx
mov eax, dword [ebp - 0x24]
push eax
call dword [sym.imp.SETUPAPI.dll_SetupDiGetDeviceInterfaceDetailW]
mov ecx, dword [ebp - 0x244]
push ecx
call fcn.0040e234
add esp, 4
mov dword [ebp - 0x2ec], eax
mov edx, dword [ebp - 0x2ec]
mov dword [ebp - 0x240], edx
mov eax, dword [ebp - 0x240]
mov dword [ebp - 0x26c], eax
mov ecx, dword [ebp - 0x26c]
mov dword [ecx], 6
mov dword [ebp - 0x264], 0x1c
lea edx, [ebp - 0x264]
push edx
lea eax, [ebp - 0x244]
push eax
mov ecx, dword [ebp - 0x244]
push ecx
mov edx, dword [ebp - 0x26c]
push edx
lea eax, [ebp - 0x20]
push eax
mov ecx, dword [ebp - 0x24]
push ecx
call dword [sym.imp.SETUPAPI.dll_SetupDiGetDeviceInterfaceDetailW]
mov dword [ebp - 0x28], eax
cmp dword [ebp - 0x28], 0
jne 0x45d581
mov edx, dword [ebp - 0x240]
mov dword [ebp - 0x2f0], edx
mov eax, dword [ebp - 0x2f0]
push eax
call fcn.0040e26e
add esp, 4
jmp 0x45d996
mov ecx, dword [ebp - 0x26c]
add ecx, 4
push ecx
lea edx, [ebp - 0x238]
push edx
call fcn.0045e190
add esp, 8
push 0x4744f8
lea eax, [ebp - 0x238]
push eax
call fcn.0040b9a0
add esp, 8
push 0x104
lea ecx, [ebp - 0x238]
push ecx
lea edx, [ebp - 0x238]
push edx
call dword [sym.imp.KERNEL32.dll_GetVolumeNameForVolumeMountPointW]
lea eax, [ebp - 0x244]
push eax
push 0x104
lea ecx, [ebp - 0x238]
push ecx
lea edx, [ebp - 0x238]
push edx
call dword [sym.imp.KERNEL32.dll_GetVolumePathNamesForVolumeNameW]
lea eax, [ebp - 0x238]
push eax
call dword [sym.imp.KERNEL32.dll_GetDriveTypeW]
mov dword [ebp - 0x23c], eax
mov dword [ebp - 0x268], 0
mov dword [ebp - 0x248], 0
cmp dword [ebp - 0x23c], 5
jne 0x45d75e
mov ecx, dword [ebp - 0x250]
mov dword [ebp - 0x270], ecx
push 0
mov edx, dword [ebp - 0x270]
push edx
lea eax, [ebp - 0x270]
push eax
call dword [sym.imp.SETUPAPI.dll_CM_Get_Parent]
test eax, eax
jne 0x45d759
cmp dword [ebp - 0x268], 0
jne 0x45d759
mov dword [ebp - 0x2cc], 0x58
push 0
lea ecx, [ebp - 0x2cc]
push ecx
lea edx, [ebp - 0x2c8]
push edx
push 0
push 0xa
mov eax, dword [ebp - 0x270]
push eax
call dword [sym.imp.SETUPAPI.dll_CM_Get_DevNode_Registry_PropertyW]
mov dword [ebp - 0x2d0], eax
cmp dword [ebp - 0x2d0], 0
je 0x45d68e
jmp 0x45d627
mov ecx, dword [0x499eb8]
mov dword [ebp - 0x268], ecx
cmp dword [ebp - 0x268], 0
je 0x45d754
mov edx, dword [ebp - 0x268]
add edx, 0x12
push edx
lea eax, [ebp - 0x2c8]
push eax
call fcn.00440f5c
add esp, 8
test eax, eax
jne 0x45d73d
push 0x218
call fcn.0040e234
add esp, 4
mov dword [ebp - 0x2f4], eax
mov ecx, dword [ebp - 0x2f4]
mov dword [ebp - 0x248], ecx
mov edx, dword [ebp - 0x248]
mov dword [edx + 0x214], 0
mov eax, dword [ebp - 0x248]
mov cx, word [ebp - 0x238]
mov word [eax], cx
mov edx, dword [ebp - 0x248]
mov eax, dword [ebp - 0x23c]
mov dword [edx + 4], eax
mov ecx, dword [ebp - 0x248]
mov dword [ecx + 8], 0xffffffff
mov edx, dword [ebp - 0x26c]
add edx, 4
push edx
mov eax, dword [ebp - 0x248]
add eax, 0xc
push eax
call fcn.0045e190
add esp, 8
jmp 0x45d754
mov ecx, dword [ebp - 0x268]
mov edx, dword [ecx + 0x81c]
mov dword [ebp - 0x268], edx
jmp 0x45d69a
jmp 0x45d627
jmp 0x45d8d3
push 0
push 0
push 3
push 0
push 3
push 0
mov eax, dword [ebp - 0x26c]
add eax, 4
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov dword [ebp - 0x2d4], eax
cmp dword [ebp - 0x2d4], 0xffffffff
je 0x45d8d3
push 0
lea ecx, [ebp - 0x244]
push ecx
push 0xc
lea edx, [ebp - 0x2e0]
push edx
push 0
push 0
push 0x2d1080
mov eax, dword [ebp - 0x2d4]
push eax
call dword [sym.imp.KERNEL32.dll_DeviceIoControl]
mov dword [ebp - 0x2e4], eax
mov ecx, dword [0x499eb8]
mov dword [ebp - 0x268], ecx
cmp dword [ebp - 0x2e4], 0
je 0x45d8c6
cmp dword [ebp - 0x268], 0
je 0x45d8c6
mov dword [ebp - 0x2e8], 0
jmp 0x45d7fc
mov edx, dword [ebp - 0x2e8]
add edx, 1
mov dword [ebp - 0x2e8], edx
cmp dword [ebp - 0x2e8], 4
jge 0x45d8a4
mov eax, dword [ebp - 0x2e8]
mov ecx, dword [ebp - 0x268]
mov edx, dword [ebp - 0x2dc]
cmp edx, dword [ecx + eax*4 + 0x398]
jne 0x45d89f
push 0x218
call fcn.0040e234
add esp, 4
mov dword [ebp - 0x2f8], eax
mov eax, dword [ebp - 0x2f8]
mov dword [ebp - 0x248], eax
mov ecx, dword [ebp - 0x248]
mov dword [ecx + 0x214], 0
mov edx, dword [ebp - 0x248]
mov ax, word [ebp - 0x238]
mov word [edx], ax
mov ecx, dword [ebp - 0x248]
mov edx, dword [ebp - 0x23c]
mov dword [ecx + 4], edx
mov eax, dword [ebp - 0x248]
mov ecx, dword [ebp - 0x2dc]
mov dword [eax + 8], ecx
mov edx, dword [ebp - 0x26c]
add edx, 4
push edx
mov eax, dword [ebp - 0x248]
add eax, 0xc
push eax
call fcn.0045e190
add esp, 8
jmp 0x45d8a4
jmp 0x45d7ed
cmp dword [ebp - 0x248], 0
je 0x45d8af
jmp 0x45d8c6
mov ecx, dword [ebp - 0x268]
mov edx, dword [ecx + 0x81c]
mov dword [ebp - 0x268], edx
jmp 0x45d7c7
mov eax, dword [ebp - 0x2d4]
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov ecx, dword [ebp - 0x240]
mov dword [ebp - 0x2fc], ecx
mov edx, dword [ebp - 0x2fc]
push edx
call fcn.0040e26e
add esp, 4
cmp dword [ebp - 0x268], 0
je 0x45d900
cmp dword [ebp - 0x248], 0
jne 0x45d905
jmp 0x45d492
mov eax, dword [ebp - 0x268]
cmp dword [eax + 0x80c], 0
jne 0x45d94c
mov ecx, dword [ebp - 0x268]
mov edx, dword [ebp - 0x248]
mov dword [ecx + 0x80c], edx
mov eax, dword [ebp - 0x268]
mov ecx, dword [ebp - 0x248]
mov dword [eax + 0x810], ecx
mov edx, dword [ebp - 0x268]
mov eax, dword [ebp - 0x248]
mov dword [edx + 0x5b4], eax
jmp 0x45d976
mov ecx, dword [ebp - 0x268]
mov edx, dword [ecx + 0x810]
mov eax, dword [ebp - 0x248]
mov dword [edx + 0x214], eax
mov ecx, dword [ebp - 0x268]
mov edx, dword [ebp - 0x248]
mov dword [ecx + 0x810], edx
mov eax, dword [ebp - 0x268]
mov ecx, dword [eax + 0x814]
add ecx, 1
mov edx, dword [ebp - 0x268]
mov dword [edx + 0x814], ecx
jmp 0x45d492
mov eax, dword [ebp - 0x24]
push eax
call dword [sym.imp.SETUPAPI.dll_SetupDiDestroyDeviceInfoList]
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.0043ea11
mov esp, ebp
pop ebp
ret