Function at 0x100142474
Capabilities:
Get storage device properties

Disassembly:
mov qword [rsp + 0x18], rbx
push rbp
push rsi
push rdi
push r12
push r15
sub rsp, 0x90
mov rax, qword [0x100165138]
xor rax, rsp
mov qword [rsp + 0x80], rax
mov rsi, rdx
mov rbp, rcx
mov rcx, qword [0x1001653b8]
lea r15, [0x1001653b8]
mov eax, 4
cmp rcx, r15
je 0x1001424d5
test byte [rcx + 0x1c], 1
je 0x1001424d5
cmp byte [rcx + 0x19], al
jb 0x1001424d5
mov rcx, qword [rcx + 0x10]
lea edx, [rax + 6]
lea r8, [0x100002dc0]
call fcn.10001c854
xor ebx, ebx
lea rcx, [rsp + 0x54]
xor edx, edx
and dword [rsp + 0x50], ebx
lea r8d, [rbx + 0x1c]
call sub.msvcrt.dll_memset
and qword [rsp + 0x30], rbx
and dword [rsp + 0x28], ebx
and dword [rsi], ebx
lea r8d, [rbx + 1]
xor r9d, r9d
mov edx, 0xc0000000
mov rcx, rbp
mov dword [rsp + 0x20], 3
call qword [sym.imp.KERNEL32.dll_CreateFileW]
mov r12, rax
cmp rax, 0xffffffffffffffff
jne 0x100142573
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov esi, eax
mov rcx, qword [0x1001653b8]
lea edi, [rbx + 2]
cmp rcx, r15
je 0x100142560
test byte [rcx + 0x1c], 1
je 0x100142560
cmp byte [rcx + 0x19], dil
jb 0x100142560
mov rcx, qword [rcx + 0x10]
lea edx, [rbx + 0xb]
lea r8, [0x100002dc0]
mov r9, rbp
mov dword [rsp + 0x20], eax
call fcn.10001ddb0
mov rcx, qword [0x1001653b8]
movzx ebx, si
or ebx, 0x80070000
test esi, esi
cmovle ebx, esi
jmp 0x100142774
xor eax, eax
lea r8, [rsp + 0x70]
mov r9d, 0xc
and qword [rsp + 0x38], rax
mov dword [rsp + 0x74], eax
and dword [rsp + 0x74], eax
mov dword [rsp + 0x70], eax
mov dword [rsp + 0x78], eax
lea rax, [rsp + 0x40]
mov qword [rsp + 0x30], rax
lea rax, [rsp + 0x50]
mov edx, 0x2d1400
mov rcx, r12
mov dword [rsp + 0x28], 0x20
mov dword [rsp + 0x70], 1
mov qword [rsp + 0x20], rax
call qword [sym.imp.KERNEL32.dll_DeviceIoControl]
test eax, eax
jne 0x100142604
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov esi, eax
mov rcx, qword [0x1001653b8]
mov edi, 2
cmp rcx, r15
je 0x1001426a8
test byte [rcx + 0x1c], 1
je 0x1001426a8
cmp byte [rcx + 0x19], dil
jb 0x1001426a8
lea edx, [rdi + 0xa]
jmp 0x100142691
cmp dword [rsp + 0x40], 0x20
je 0x100142623
lea r8, [0x1000153b8]
lea rcx, [0x1000153d8]
mov edx, 0x4d
call fcn.10009a050
xor eax, eax
xor r9d, r9d
xor r8d, r8d
and qword [rsp + 0x38], rax
lea edi, [rax + 8]
mov dword [rsp + 0x48], eax
mov dword [rsp + 0x4c], eax
lea rax, [rsp + 0x40]
mov edx, 0x2d0c14
mov qword [rsp + 0x30], rax
lea rax, [rsp + 0x48]
mov rcx, r12
mov dword [rsp + 0x28], edi
mov dword [rsp + 0x48], edi
mov qword [rsp + 0x20], rax
call qword [sym.imp.KERNEL32.dll_DeviceIoControl]
test eax, eax
jne 0x1001426bb
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov esi, eax
mov rcx, qword [0x1001653b8]
mov edi, 2
cmp rcx, r15
je 0x1001426a8
test byte [rcx + 0x1c], 1
je 0x1001426a8
cmp byte [rcx + 0x19], dil
jb 0x1001426a8
lea edx, [rdi + 0xb]
mov rcx, qword [rcx + 0x10]
lea r8, [0x100002dc0]
mov r9, rbp
mov dword [rsp + 0x20], eax
call fcn.10001ddb0
movzx ebx, si
or ebx, 0x80070000
test esi, esi
cmovle ebx, esi
jmp 0x100142764
cmp dword [rsp + 0x40], edi
je 0x1001426d9
lea r8, [0x100015410]
lea rcx, [0x1000153d8]
mov edx, 0x61
call fcn.10009a050
mov dl, byte [rsp + 0x68]
mov r10b, byte [rsp + 0x4e]
xor ecx, ecx
lea edi, [rcx + 2]
cmp dl, 7
cmove ecx, edi
xor eax, eax
lea r8d, [rdi + 2]
cmp dl, r8b
cmove eax, r8d
or ecx, eax
xor eax, eax
test r10b, r10b
setne al
or ecx, eax
or dword [rsi], ecx
mov r11d, dword [rsi]
mov rcx, qword [0x1001653b8]
cmp rcx, r15
je 0x100142764
test byte [rcx + 0x1c], 1
je 0x100142764
cmp byte [rcx + 0x19], r8b
jb 0x100142764
mov rcx, qword [rcx + 0x10]
xor r9d, r9d
cmp dl, r8b
sete r9b
xor r8d, r8d
mov dword [rsp + 0x38], r11d
mov dword [rsp + 0x30], r9d
cmp dl, 7
movzx eax, r10b
sete r8b
lea edx, [rdi + 0xc]
mov r9, rbp
mov dword [rsp + 0x28], r8d
lea r8, [0x100002dc0]
mov dword [rsp + 0x20], eax
call fcn.100142398
mov rcx, r12
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov rcx, qword [0x1001653b8]
test ebx, ebx
jns 0x1001427ac
cmp rcx, r15
je 0x1001427d2
test byte [rcx + 0x1c], 1
je 0x1001427ac
cmp byte [rcx + 0x19], dil
jb 0x1001427ac
mov rcx, qword [rcx + 0x10]
lea r8, [0x100002dc0]
mov edx, 0xf
mov r9, rbp
mov dword [rsp + 0x20], ebx
call fcn.10001ddb0
mov rcx, qword [0x1001653b8]
cmp rcx, r15
je 0x1001427d2
test byte [rcx + 0x1c], 1
je 0x1001427d2
cmp byte [rcx + 0x19], 4
jb 0x1001427d2
mov rcx, qword [rcx + 0x10]
lea r8, [0x100002dc0]
mov edx, 0x10
call fcn.10001c854
mov eax, ebx
mov rcx, qword [rsp + 0x80]
xor rcx, rsp
call fcn.10014e600
mov rbx, qword [rsp + 0xd0]
add rsp, 0x90
pop r15
pop r12
pop rdi
pop rsi
pop rbp
ret