Function at 0x4865d0
Capabilities:
Get disk information via ioctl
Get storage device properties

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
push 0xffffffffffffffff
push 0x57d112
mov eax, dword fs:[0]
push eax
push ecx
mov eax, 0x279c
call fcn.0055d150
mov eax, dword [0x5f72d8]
xor eax, esp
mov dword [esp + 0x2798], eax
push ebx
push esi
push edi
mov eax, dword [0x5f72d8]
xor eax, esp
push eax
lea eax, [esp + 0x27b0]
mov dword fs:[0], eax
mov esi, ecx
xor ebx, ebx
mov dword [esp + 0x2c], esi
mov dword [esp + 0x14], ebx
push ebx
push str..PhysicalDrive_d
lea eax, [esp + 0x2424]
push 0x80
push eax
call fcn.0045ea70
add esp, 0x10
push 0
push 0x80
push 3
push 0
push 3
push 0xc0000000
lea ecx, [esp + 0x2434]
push ecx
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov edi, eax
mov dword [esp + 0x24], edi
cmp edi, 0xffffffff
je 0x48714d
xor ebx, ebx
push ebx
lea edx, [esp + 0x38]
push edx
push 0x200
lea eax, [esp + 0x24a8]
push eax
push 0xc
lea ecx, [esp + 0x64]
push ecx
push 0x2d1400
push edi
mov dword [esp + 0x70], ebx
mov dword [esp + 0x74], ebx
mov dword [esp + 0x40], ebx
call dword [sym.imp.KERNEL32.dll_DeviceIoControl]
test eax, eax
je 0x4866b9
mov ebx, dword [esp + 0x24b8]
lea edx, [esp + 0x249c]
mov dword [esp + 0x40], edx
mov dword [esp + 0x20], ebx
push 0
lea eax, [esp + 0x38]
push eax
push 0xc
lea ecx, [esp + 0x50]
push ecx
push 0
push 0
push 0x2d1080
push edi
mov dword [esp + 0x30], 0
call dword [sym.imp.KERNEL32.dll_DeviceIoControl]
test eax, eax
je 0x4866eb
mov edx, dword [esp + 0x48]
mov dword [esp + 0x10], edx
mov eax, ebx
sub eax, 7
je 0x486f5c
sub eax, 1
je 0x486b50
sub eax, 9
je 0x486a46
push 0x200
lea eax, [esp + 0x128]
push 0
push eax
call fcn.0055b160
mov edx, dword [esp + 0x20]
add esp, 0xc
push 0x200
lea ecx, [esp + 0x128]
push ecx
push 0
push 0xec
push edx
push edi
mov ecx, esi
call fcn.004b7130
test eax, eax
je 0x4867b1
push 0xb0
call fcn.0054993e
add esp, 4
mov dword [esp + 0x1c], eax
mov dword [esp + 0x27b8], 3
test eax, eax
je 0x486779
mov ecx, dword [esp + 0x10]
mov edx, dword [esp + 0x14]
push 0xffffffffffffffff
push ecx
push edx
mov ecx, eax
call fcn.004b79e0
jmp 0x48677b
xor eax, eax
push eax
mov ecx, esi
mov dword [esp + 0x1c], eax
mov dword [esp + 0x27bc], 0xffffffff
mov edi, eax
mov dword [eax + 0x94], ebx
call fcn.00485420
lea eax, [esp + 0x124]
push eax
mov ecx, edi
push ecx
mov ecx, esi
call fcn.00484f30
jmp 0x48697f
push 0x200
lea edx, [esp + 0x128]
push 0
push edx
call fcn.0055b160
mov ecx, dword [esp + 0x20]
add esp, 0xc
push 0x200
lea eax, [esp + 0x128]
push eax
push 0
push 0xec
push ecx
push edi
mov ecx, esi
call fcn.004b7000
test eax, eax
je 0x48685a
push 0xb0
call fcn.0054993e
add esp, 4
mov dword [esp + 0x1c], eax
mov dword [esp + 0x27b8], 4
test eax, eax
je 0x486822
mov edx, dword [esp + 0x10]
mov ecx, dword [esp + 0x14]
push 0xffffffffffffffff
push edx
push ecx
mov ecx, eax
call fcn.004b79e0
jmp 0x486824
xor eax, eax
push eax
mov ecx, esi
mov dword [esp + 0x1c], eax
mov dword [esp + 0x27bc], 0xffffffff
mov edi, eax
mov dword [eax + 0x94], ebx
call fcn.00485420
lea edx, [esp + 0x124]
push edx
mov eax, edi
push eax
mov ecx, esi
call fcn.00484f30
jmp 0x48697f
push 0x200
lea ecx, [esp + 0x128]
push 0
push ecx
call fcn.0055b160
mov eax, dword [esp + 0x20]
add esp, 0xc
push 0x200
lea edx, [esp + 0x128]
push edx
push 0
push 0xec
push eax
push edi
mov ecx, esi
call fcn.004b7270
push 0xb0
test eax, eax
je 0x486914
call fcn.0054993e
add esp, 4
mov dword [esp + 0x1c], eax
mov dword [esp + 0x27b8], 5
test eax, eax
je 0x4868cd
mov ecx, dword [esp + 0x10]
mov edx, dword [esp + 0x14]
push 0xffffffffffffffff
push ecx
push edx
mov ecx, eax
call fcn.004b79e0
mov edi, eax
jmp 0x4868cf
xor edi, edi
mov eax, dword [edi + 0x14]
mov ecx, dword [edi + 0x2c]
push eax
push str.HDD__d
push 0x200
push ecx
mov dword [esp + 0x27c8], 0xffffffff
mov dword [edi + 0x94], ebx
call fcn.0045ea70
add esp, 0x10
push edi
mov ecx, esi
call fcn.00485420
lea edx, [esp + 0x124]
push edx
push edi
mov ecx, esi
call fcn.00484f30
jmp 0x48697b
call fcn.0054993e
add esp, 4
mov dword [esp + 0x1c], eax
mov dword [esp + 0x27b8], 6
test eax, eax
je 0x486946
mov ecx, dword [esp + 0x10]
mov edx, dword [esp + 0x14]
push 0xffffffffffffffff
push ecx
push edx
mov ecx, eax
call fcn.004b79e0
mov edi, eax
jmp 0x486948
xor edi, edi
mov eax, dword [edi + 0x14]
mov ecx, dword [edi + 0x2c]
push eax
push str.HDD__d
push 0x200
push ecx
mov dword [esp + 0x27c8], 0xffffffff
mov dword [edi + 0x94], ebx
call fcn.0045ea70
add esp, 0x10
push edi
mov ecx, esi
call fcn.00485420
mov ebx, dword [esp + 0x20]
cmp ebx, 9
je 0x48698d
cmp ebx, 0xa
jne 0x48713e
push 0x44
lea edx, [esp + 0x60]
push 0
push edx
mov dword [edi + 0xa4], 0
call fcn.0055b160
mov ecx, dword [esp + 0x30]
add esp, 0xc
lea eax, [esp + 0x5c]
push eax
push 0
push ecx
mov ecx, esi
call fcn.004b7870
test eax, eax
je 0x48713e
movzx ebx, byte [esp + 0x5e]
movzx edx, byte [esp + 0x5f]
shl ebx, 8
add ebx, edx
cmp ebx, 0x40
jle 0x4869dc
mov ebx, 0x40
cmp dword [edi + 0xa8], 0
mov dword [edi + 0xa4], ebx
jne 0x486a0c
xor ecx, ecx
mov eax, ebx
mov edx, 8
mul edx
seto cl
neg ecx
or ecx, eax
push ecx
call fcn.0054996d
add esp, 4
mov dword [edi + 0xa8], eax
xor eax, eax
test ebx, ebx
jle 0x48713e
jmp 0x486a20
movzx ecx, byte [esp + eax + 0x60]
mov edx, dword [edi + 0xa8]
mov dword [edx + eax*8], ecx
mov ecx, dword [edi + 0xa8]
mov dword [ecx + eax*8 + 4], 0
inc eax
cmp eax, ebx
jl 0x486a20
jmp 0x48713e
push 0xb0
call fcn.0054993e
add esp, 4
mov dword [esp + 0x1c], eax
mov dword [esp + 0x27b8], 1
test eax, eax
je 0x486a7d
mov edx, dword [esp + 0x10]
mov ecx, dword [esp + 0x14]
push 0xffffffffffffffff
push edx
push ecx
mov ecx, eax
call fcn.004b79e0
mov edi, eax
jmp 0x486a7f
xor edi, edi
mov edx, dword [edi + 0x14]
mov eax, dword [edi + 0x2c]
push edx
push str.NVMe_Drive__d
push 0x200
push eax
mov dword [esp + 0x27c8], 0xffffffff
call fcn.0045ea70
or dword [edi + 0x24], 1
add esp, 0x10
push edi
mov ecx, esi
mov dword [edi + 0x94], 0x11
call fcn.00485420
mov ebx, dword [esp + 0x24]
lea ecx, [esp + 0xbfc]
push ecx
push ebx
mov ecx, esi
call fcn.004b87f0
mov ecx, esi
test eax, eax
je 0x486aee
lea edx, [esp + 0xbfc]
push edx
push edi
mov dword [edi + 0x28], 1
call fcn.004b92c0
jmp 0x48713e
lea eax, [esp + 0xbfc]
push eax
push ebx
call fcn.004b8a20
test eax, eax
je 0x486b1c
lea ecx, [esp + 0xbfc]
push ecx
push edi
mov ecx, esi
mov dword [edi + 0x28], 2
call fcn.004b92c0
jmp 0x48713e
lea edx, [esp + 0xbfc]
push edx
push ebx
mov ecx, esi
call fcn.004b8ee0
test eax, eax
je 0x48713e
lea eax, [esp + 0xbfc]
push eax
push edi
mov ecx, esi
mov dword [edi + 0x28], 3
call fcn.004b92c0
jmp 0x48713e
push 0
lea ecx, [esp + 0x38]
push ecx
push 0x200
lea edx, [esp + 0x24a8]
push edx
push 0
push 0
push 0x41018
push edi
call dword [sym.imp.KERNEL32.dll_DeviceIoControl]
test eax, eax
je 0x48713e
movzx eax, byte [esp + 0x24a0]
push eax
push str..Scsi_d:
lea ecx, [esp + 0x26a4]
push 0x104
push ecx
call fcn.0055b8cb
add esp, 0x10
push 0
push 0
push 3
push 0
push 3
push 0xc0000000
lea edx, [esp + 0x26b4]
push edx
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov edi, eax
mov dword [esp + 0x18], edi
cmp edi, 0xffffffff
je 0x48713e
xor ebx, ebx
push 0xc6
lea eax, [esp + 0x32c]
push ebx
push eax
mov dword [esp + 0x330], ebx
call fcn.0055b160
push 0x7c
lea ecx, [esp + 0xb8]
push ebx
push ecx
mov dword [esp + 0xbc], ebx
call fcn.0055b160
push 0x803
lea edx, [esp + 0x411]
push ebx
push edx
mov byte [esp + 0x418], bl
call fcn.0055b160
push 0x81c
lea eax, [esp + 0x1c28]
push ebx
push eax
mov dword [esp + 0x1c2c], ebx
call fcn.0055b160
add esp, 0x30
push 0xca
lea ecx, [esp + 0x328]
push ecx
push 1
push edi
mov ecx, esi
call fcn.004b73c0
test eax, eax
jne 0x486c56
call dword [sym.imp.KERNEL32.dll_GetLastError]
push 0x80
lea edx, [esp + 0xa8]
push edx
push 0xa
push edi
mov ecx, esi
call fcn.004b73c0
test eax, eax
je 0x486f50
push 0x820
lea eax, [esp + 0x1c00]
push eax
push 0x14
push edi
mov ecx, esi
call fcn.004b73c0
test eax, eax
je 0x486d21
mov ecx, 0x201
lea esi, [esp + 0x1c18]
lea edi, [esp + 0x3f4]
rep movsd dword es:[edi], dword [esi]
mov ecx, str.rcraid
lea eax, [esp + 0x340]
mov dl, byte [eax]
cmp dl, byte [ecx]
jne 0x486cd5
test dl, dl
je 0x486cd1
mov dl, byte [eax + 1]
cmp dl, byte [ecx + 1]
jne 0x486cd5
add eax, 2
add ecx, 2
test dl, dl
jne 0x486cb5
xor eax, eax
jmp 0x486cda
sbb eax, eax
sbb eax, 0xffffffff
test eax, eax
jne 0x486d21
mov ebx, dword [esp + 0xe4]
test ebx, ebx
jle 0x486d1a
lea edx, [esp + 0x414]
movzx ecx, byte [esp + 0x3f4]
cmp eax, ecx
jl 0x486d0f
lea edi, [edx - 0x1c]
mov ecx, 0x10
lea esi, [esp + 0x3f8]
rep movsd dword es:[edi], dword [esi]
mov byte [edx], al
mov byte [edx + 0x1c], al
inc eax
add edx, 0x40
cmp eax, ebx
jl 0x486cf0
mov byte [esp + 0x3f4], bl
mov eax, dword [esp + 0xc4]
imul eax, dword [esp + 0xc0]
imul eax, eax, 0x88
push 4
add eax, 0xc8
push 0x1000
push eax
push 0
mov dword [esp + 0x4c], eax
call dword [sym.imp.KERNEL32.dll_VirtualAlloc]
cmp dword [esp + 0xc0], 0
mov dword [esp + 0x10], eax
mov dword [esp + 0x28], 0
jle 0x486f36
lea esp, [esp]
mov eax, dword [esp + 0x3c]
mov esi, dword [esp + 0x10]
mov ecx, dword [esp + 0x18]
mov edx, dword [esp + 0x28]
push eax
push esi
push 0xb
push ecx
mov ecx, dword [esp + 0x3c]
mov dword [esi + 0x1c], edx
call fcn.004b73c0
test eax, eax
je 0x486f1a
cmp byte [esi + 0x2b], 0
mov dword [esp + 0x30], 0
jbe 0x486f20
movzx edx, byte [esp + 0x3f4]
mov eax, esi
add eax, 0xbc
mov dword [esp + 0x1c], edx
mov dword [esp + 0x20], eax
mov ecx, dword [esp + 0x20]
mov edi, dword [ecx]
push 0xb0
call fcn.0054993e
add esp, 4
mov dword [esp + 0x38], eax
mov dword [esp + 0x27b8], 2
test eax, eax
je 0x486e00
movzx edx, byte [esp + 0x24a0]
push edx
push 0xffffffffffffffff
push 0xffffffffffffffff
mov ecx, eax
call fcn.004b79e0
mov ebx, eax
jmp 0x486e02
xor ebx, ebx
mov ecx, dword [esp + 0x1c]
xor esi, esi
mov dword [esp + 0x27b8], 0xffffffff
test ecx, ecx
jle 0x486e51
lea eax, [esp + 0x414]
mov edi, edi
movzx edx, byte [eax]
cmp edx, edi
je 0x486e31
inc esi
add eax, 0x40
cmp esi, ecx
jl 0x486e20
jmp 0x486e51
push 0x40
call fcn.0054993e
add esp, 4
shl esi, 6
lea esi, [esp + esi + 0x3f8]
mov ecx, 0x10
mov edi, eax
mov dword [ebx + 0x20], eax
rep movsd dword es:[edi], dword [esi]
mov edi, dword [esp + 0x10]
mov esi, dword [esp + 0x2c]
mov dword [ebx + 0x94], 8
mov eax, dword [edi + 0x20]
mov dword [ebx + 0x8c], eax
cmp dword [esi + 0x1c], 0
jne 0x486e95
push 0xc
call fcn.0054993e
xor ecx, ecx
add esp, 4
cmp eax, ecx
je 0x486e90
mov dword [eax], vtable.CTList_class_CDevice_.0
mov dword [eax + 4], ecx
mov dword [eax + 8], ecx
jmp 0x486e92
xor eax, eax
mov dword [esi + 0x1c], eax
mov ecx, dword [esi + 0x1c]
push ebx
call fcn.00416944
call fcn.004605a0
mov ecx, dword [eax + 0x2c]
push ebx
call fcn.00416944
push 0x200
lea ecx, [esp + 0x128]
push 0
push ecx
call fcn.0055b160
mov eax, dword [ebx + 0x20]
mov ecx, dword [esp + 0x24]
add esp, 0xc
push 0x200
lea edx, [esp + 0x128]
push edx
push 0
push 0xec
push eax
push ecx
mov ecx, esi
call fcn.004b74a0
test eax, eax
je 0x486efb
lea edx, [esp + 0x124]
push edx
push ebx
mov ecx, esi
call fcn.00484f30
mov eax, dword [esp + 0x30]
movzx ecx, byte [edi + 0x2b]
add dword [esp + 0x20], 0x88
inc eax
cmp eax, ecx
mov dword [esp + 0x30], eax
jl 0x486dc2
jmp 0x486f20
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov eax, dword [esp + 0x28]
inc eax
cmp eax, dword [esp + 0xc0]
mov dword [esp + 0x28], eax
jl 0x486d70
mov edx, dword [esp + 0x10]
push 0x8000
push 0
push edx
call dword [sym.imp.KERNEL32.dll_VirtualFree]
mov edi, dword [esp + 0x18]
mov esi, dword [esp + 0x2c]
push edi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
jmp 0x48713e
test dword [esi + 8], 0x4000000
je 0x48713e
push 0xb0
call fcn.0054993e
add esp, 4
mov dword [esp + 0x38], eax
mov ebx, dword [esp + 0x14]
mov dword [esp + 0x27b8], 0
test eax, eax
je 0x486fa0
mov ecx, dword [esp + 0x10]
push 0xffffffffffffffff
push ecx
push ebx
mov ecx, eax
call fcn.004b79e0
mov edi, eax
jmp 0x486fa2
xor edi, edi
mov edx, dword [edi + 0x14]
mov eax, dword [edi + 0x2c]
push edx
push str.USB_Drive__d
push 0x200
push eax
mov dword [esp + 0x27c8], 0xffffffff
call fcn.0045ea70
add esp, 0x10
push edi
mov ecx, esi
mov dword [edi + 0x94], 7
call fcn.00485420
push 0x200
lea ecx, [esp + 0x128]
push 0
push ecx
call fcn.0055b160
mov eax, dword [esp + 0x30]
add esp, 0xc
push 0x200
lea edx, [esp + 0x128]
push edx
push 0
push 0xec
push 4
push ebx
push eax
mov ecx, esi
call fcn.004b75f0
test eax, eax
je 0x487033
lea ecx, [esp + 0x124]
push ecx
push edi
mov ecx, esi
mov dword [edi + 0x28], 4
call fcn.00484f30
jmp 0x48713e
mov eax, dword [esp + 0x24]
push 0x200
lea edx, [esp + 0x128]
push edx
push 0
push 0xec
push 5
push ebx
push eax
mov ecx, esi
call fcn.004b75f0
test eax, eax
je 0x487076
lea ecx, [esp + 0x124]
push ecx
push edi
mov ecx, esi
mov dword [edi + 0x28], 5
call fcn.00484f30
jmp 0x48713e
mov eax, dword [esp + 0x24]
push 0x200
lea edx, [esp + 0x128]
push edx
push 0
push 0xec
push 6
push ebx
push eax
mov ecx, esi
call fcn.004b75f0
test eax, eax
je 0x4870b9
lea ecx, [esp + 0x124]
push ecx
push edi
mov ecx, esi
mov dword [edi + 0x28], 6
call fcn.00484f30
jmp 0x48713e
mov ebx, dword [esp + 0x40]
mov eax, dword [ebx + 0xc]
test eax, eax
je 0x4870ed
cmp eax, dword [ebx + 4]
jae 0x4870ed
add eax, ebx
push eax
mov ecx, esi
mov dword [esp + 0x20], eax
call fcn.00484e90
mov edx, dword [esp + 0x1c]
mov eax, dword [edi + 0x2c]
push edx
push 0x200
push eax
call fcn.0055c215
add esp, 0xc
mov eax, dword [ebx + 0x10]
test eax, eax
je 0x48713e
cmp eax, dword [ebx + 4]
jae 0x48713e
add ebx, eax
push ebx
mov ecx, esi
call fcn.00484e90
mov eax, dword [edi + 0x2c]
cmp byte [eax], 0
je 0x48712f
push 0x590720
push 0x200
push eax
call fcn.0045eb50
mov ecx, dword [edi + 0x2c]
push ebx
push 0x200
push ecx
call fcn.0045eb50
add esp, 0x18
jmp 0x48713e
push ebx
push 0x200
push eax
call fcn.0055c215
add esp, 0xc
mov edx, dword [esp + 0x24]
push edx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov ebx, dword [esp + 0x14]
inc ebx
cmp ebx, 0x38
mov dword [esp + 0x14], ebx
jl 0x486621
mov eax, 1
mov ecx, dword [esp + 0x27b0]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [esp + 0x2798]
xor ecx, esp
call fcn.0055a90d
mov esp, ebp
pop ebp
ret