Function at 0x140060d40
Capabilities:
Get disk information via ioctl

Disassembly:
push rsi
push r12
sub rsp, 0x4d8
mov rax, qword [0x140197b10]
xor rax, rsp
mov qword [rsp + 0x4c0], rax
mov rsi, r8
mov r12d, ecx
test r8, r8
jne 0x140060d7e
cmp edx, 2
jb 0x140060db3
cmp edx, 3
jbe 0x140060daa
cmp edx, 5
jne 0x140060db3
lea rsi, [0x140147640]
mov r9d, 0x12
xor r8d, r8d
xor edx, edx
mov rcx, rsi
mov qword [rsp + 0x508], rdi
call qword [0x14019bfd8]
mov rdi, rax
cmp rax, 0xffffffffffffffff
jne 0x140060dba
xor eax, eax
jmp 0x140060fc3
lea rsi, [0x140147630]
jmp 0x140060d7e
xor eax, eax
jmp 0x140060fcb
xor eax, eax
mov qword [rsp + 0x4f0], rbx
mov qword [rsp + 0x4f8], rbp
mov qword [rsp + 0x60], rax
mov qword [rsp + 0x68], rax
mov qword [rsp + 0x70], rax
lea rax, [rsp + 0x58]
mov qword [rsp + 0x4d0], r13
xor r13d, r13d
xor r9d, r9d
mov r8, rsi
xor edx, edx
mov rcx, rdi
mov qword [rsp + 0x20], rax
mov ebp, r13d
mov dword [rsp + 0x58], 0x20
mov dword [rsp + 0x5c], r13d
mov dword [rsp + 0x40], r13d
mov dword [rsp + 0x98], 0x20
call qword [sym.imp.SETUPAPI.dll_SetupDiEnumDeviceInterfaces]
test eax, eax
je 0x140060fa0
nop dword [rax]
lea rax, [rsp + 0x98]
mov r9d, ebp
mov r8, rsi
xor edx, edx
mov rcx, rdi
mov qword [rsp + 0x20], rax
call qword [sym.imp.SETUPAPI.dll_SetupDiEnumDeviceInterfaces]
lea rax, [rsp + 0x40]
lea rdx, [rsp + 0x98]
xor r9d, r9d
xor r8d, r8d
mov rcx, rdi
mov qword [rsp + 0x28], r13
mov dword [rsp + 0x40], r13d
mov qword [rsp + 0x20], rax
call qword [sym.imp.SETUPAPI.dll_SetupDiGetDeviceInterfaceDetailW]
mov r9d, dword [rsp + 0x40]
test r9d, r9d
je 0x140060f7b
cmp r9d, 0x400
ja 0x140060f7b
xor eax, eax
lea r8, [rsp + 0xc0]
lea rdx, [rsp + 0x98]
mov qword [rsp + 0x78], rax
mov qword [rsp + 0x80], rax
mov qword [rsp + 0x88], rax
mov qword [rsp + 0x90], rax
lea rax, [rsp + 0x78]
mov rcx, rdi
mov qword [rsp + 0x28], rax
lea rax, [rsp + 0x40]
mov dword [rsp + 0xc0], 8
mov qword [rsp + 0x20], rax
mov dword [rsp + 0x78], 0x20
call qword [sym.imp.SETUPAPI.dll_SetupDiGetDeviceInterfaceDetailW]
test eax, eax
je 0x140060f7b
xor r9d, r9d
mov qword [rsp + 0x30], r13
lea rcx, [rsp + 0xc4]
lea r8d, [r9 + 3]
xor edx, edx
mov dword [rsp + 0x28], r13d
mov dword [rsp + 0x20], 3
call qword [sym.imp.KERNEL32.dll_CreateFileW]
mov rbx, rax
cmp rax, 0xffffffffffffffff
je 0x140060f7b
mov qword [rsp + 0x38], r13
lea rax, [rsp + 0x44]
xor r9d, r9d
mov qword [rsp + 0x30], rax
lea rax, [rsp + 0x48]
xor r8d, r8d
mov edx, 0x2d1080
mov rcx, rbx
mov dword [rsp + 0x28], reloc.OLEAUT32.dll_VariantTimeToDosDateTime
mov qword [rsp + 0x20], rax
mov dword [rsp + 0x44], r13d
call qword [sym.imp.KERNEL32.dll_DeviceIoControl]
test eax, eax
je 0x140060f72
cmp r12d, dword [rsp + 0x4c]
je 0x140060fe6
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_CloseHandle]
lea rax, [rsp + 0x58]
inc ebp
mov r8, rsi
xor edx, edx
mov rcx, rdi
mov r9d, ebp
mov qword [rsp + 0x20], rax
call qword [sym.imp.SETUPAPI.dll_SetupDiEnumDeviceInterfaces]
test eax, eax
jne 0x140060e30
mov rcx, rdi
call qword [sym.imp.SETUPAPI.dll_SetupDiDestroyDeviceInfoList]
xor eax, eax
mov rbx, qword [rsp + 0x4f0]
mov rbp, qword [rsp + 0x4f8]
mov r13, qword [rsp + 0x4d0]
mov rdi, qword [rsp + 0x508]
mov rcx, qword [rsp + 0x4c0]
xor rcx, rsp
call fcn.14010bcc0
add rsp, 0x4d8
pop r12
pop rsi
ret
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov rcx, rdi
call qword [sym.imp.SETUPAPI.dll_SetupDiDestroyDeviceInfoList]
mov eax, dword [rsp + 0x8c]
jmp 0x140060fab