Function at 0x140126f70
Capabilities:
Get storage device properties

Disassembly:
mov qword [rsp + 0x10], rbx
mov qword [rsp + 0x20], rdi
push rbp
push r12
push r13
push r14
push r15
lea rbp, [rsp - 0x37]
sub rsp, 0x90
mov rax, qword [0x140173708]
xor rax, rsp
mov qword [rbp + 0x2f], rax
and dword [rbp - 0x19], 0
xorps xmm0, xmm0
xor edi, edi
mov dword [rbp - 0x15], edx
mov qword [rbp - 9], rcx
mov r12, r8
mov rbx, rcx
movups xmmword [rbp + 0xf], xmm0
movups xmmword [rbp + 0x1f], xmm0
test r8, r8
jne 0x140126fd8
lea r8, str.ppHeader
mov edx, 0x456
lea rcx, str.base_stor_blbengine_blbengutils_blbdeviceutils.cpp
call fcn.1400906e0
and qword [rsp + 0x38], rdi
lea rax, [rbp - 0x19]
and qword [r12], rdi
lea r8, [rbp - 1]
and dword [rbp + 7], edi
mov r9d, 0xc
and dword [rbp + 3], edi
mov edx, 0x2d1400
mov qword [rsp + 0x30], rax
mov rcx, rbx
lea rax, [rbp + 0xf]
mov dword [rsp + 0x28], 0x20
mov qword [rsp + 0x20], rax
mov dword [rbp - 1], 1
call qword [sym.imp.KERNEL32.dll_DeviceIoControl]
nop dword [rax + rax]
lea r14, [0x140173048]
test eax, eax
jne 0x140127093
call qword [sym.imp.KERNEL32.dll_GetLastError]
nop dword [rax + rax]
mov ebx, eax
mov rcx, qword [0x140173048]
cmp rcx, r14
je 0x140127076
test byte [rcx + 0x1c], 1
je 0x140127076
cmp byte [rcx + 0x19], 2
jb 0x140127076
mov rcx, qword [rcx + 0x10]
lea r8, [0x1401612a0]
mov edx, 0x38
mov r9d, eax
call fcn.14000c47c
mov rcx, qword [0x140173048]
lea r15, [0x140173048]
test ebx, ebx
jle 0x14012735e
movzx ebx, bx
or ebx, 0x80070000
jmp 0x14012735c
mov ecx, dword [rbp + 0x1f]
mov r15d, 0x108
mov eax, ecx
not eax
lea r14d, [rcx + 0x50]
and r14d, eax
mov dword [rbp - 0x11], r14d
lea r13d, [r15 + 0x50]
mov ebx, 0x38
add r13d, ecx
test rdi, rdi
je 0x1401270cb
mov rcx, rdi
call qword [sym.imp.ole32.dll_CoTaskMemFree]
nop dword [rax + rax]
mov ecx, r13d
call qword [sym.imp.ole32.dll_CoTaskMemAlloc]
nop dword [rax + rax]
mov rdi, rax
test rax, rax
je 0x140127362
mov r8d, r13d
xor edx, edx
mov rcx, rax
call sub.msvcrt.dll_memset
mov al, byte [rdi + 0x25]
mov r9d, r13d
mov ecx, dword [rbp - 0x15]
and al, 0xfe
and qword [rsp + 0x38], 0
or al, 2
mov byte [rdi + 0x25], al
mov r8, rdi
mov eax, ecx
mov word [rdi], bx
sar eax, 8
mov edx, 0x4d004
mov byte [rdi + 0x26], al
mov eax, r15d
shr eax, 8
mov byte [rdi + 0x2b], al
lea rax, [rbp - 0x19]
mov qword [rsp + 0x30], rax
mov dword [rdi + 0x20], ebx
mov byte [rdi + 0x27], cl
mov rcx, qword [rbp - 9]
mov ebx, r14d
mov dword [rsp + 0x28], r13d
mov qword [rsp + 0x20], rdi
mov word [rdi + 7], VarUI4FromDisp
mov dword [rdi + 0xc], r15d
mov dword [rdi + 0x10], 0x14
mov qword [rdi + 0x18], rbx
mov byte [rdi + 6], 0xa
mov byte [rdi + 0x24], 0x46
mov byte [rdi + 0x2c], r15b
call qword [sym.imp.KERNEL32.dll_DeviceIoControl]
nop dword [rax + rax]
test eax, eax
je 0x1401272f4
test byte [rdi + 0x3a], 0xf
jne 0x14012729e
lea r13, [rbx + rdi]
movzx eax, byte [r13 + 1]
movzx ecx, byte [r13]
shl ecx, 8
or ecx, eax
movzx eax, byte [r13 + 2]
shl ecx, 8
or ecx, eax
movzx eax, byte [r13 + 3]
shl ecx, 8
or ecx, eax
lea r14d, [rcx + 4]
cmp r14d, 4
jb 0x140127258
xor ebx, ebx
cmp r14d, r15d
jbe 0x1401271cf
mov ecx, dword [rbp + 0x1f]
mov r15d, r14d
mov r14d, dword [rbp - 0x11]
jmp 0x1401270ab
mov ecx, r14d
call qword [sym.imp.ole32.dll_CoTaskMemAlloc]
nop dword [rax + rax]
mov r15, rax
test rax, rax
jne 0x1401271f7
mov ebx, 0x8007000e
lea r15, [0x140173048]
jmp 0x140127346
mov r8d, r14d
mov rdx, r13
mov rcx, r15
call sub.msvcrt.dll_memcpy
mov qword [r12], r15
mov rcx, qword [0x140173048]
lea r15, [0x140173048]
cmp rcx, r15
je 0x140127346
test byte [rcx + 0x1c], 1
je 0x140127346
cmp byte [rcx + 0x19], 5
jb 0x140127346
mov eax, dword [rbp - 0x15]
lea r8, [0x1401612a0]
mov rcx, qword [rcx + 0x10]
mov edx, 0x3d
mov r9d, r14d
mov dword [rsp + 0x20], eax
call fcn.140040778
jmp 0x140127346
mov rax, qword [0x140173048]
lea r15, [0x140173048]
cmp rax, r15
je 0x140127294
test byte [rax + 0x1c], 1
je 0x140127294
cmp byte [rax + 0x19], 2
jb 0x140127294
mov edx, 0x3b
mov dword [rsp + 0x20], ecx
mov rcx, qword [rax + 0x10]
lea r8, [0x1401612a0]
lea r9d, [rdx - 0x37]
call fcn.14003f558
mov ebx, 0x8000ffff
jmp 0x140127346
mov rcx, qword [0x140173048]
lea r15, [0x140173048]
cmp rcx, r15
je 0x1401272ed
test byte [rcx + 0x1c], 1
je 0x1401272ed
cmp byte [rcx + 0x19], 2
jb 0x1401272ed
movzx r8d, byte [rdi + 0x44]
mov edx, 0x3a
movzx eax, byte [rdi + 0x45]
movzx r9d, byte [rdi + 0x3a]
mov rcx, qword [rcx + 0x10]
and r9d, 0xf
mov dword [rsp + 0x28], eax
mov dword [rsp + 0x20], r8d
lea r8, [0x1401612a0]
call fcn.140112e30
mov ebx, 1
jmp 0x140127346
call qword [sym.imp.KERNEL32.dll_GetLastError]
nop dword [rax + rax]
mov ebx, eax
mov rcx, qword [0x140173048]
lea r15, [0x140173048]
cmp rcx, r15
je 0x140127339
test byte [rcx + 0x1c], 1
je 0x140127339
cmp byte [rcx + 0x19], 2
jb 0x140127339
mov rcx, qword [rcx + 0x10]
lea r8, [0x1401612a0]
mov edx, 0x39
mov r9d, eax
call fcn.14000c47c
test ebx, ebx
jle 0x140127346
movzx ebx, bx
or ebx, 0x80070000
mov rcx, rdi
call qword [sym.imp.ole32.dll_CoTaskMemFree]
nop dword [rax + rax]
mov rcx, qword [0x140173048]
test ebx, ebx
jns 0x14012739e
jmp 0x140127375
mov rcx, qword [0x140173048]
lea r15, [0x140173048]
mov ebx, 0x8007000e
cmp rcx, r15
je 0x14012739e
test byte [rcx + 0x1c], 1
je 0x14012739e
cmp byte [rcx + 0x19], 2
jb 0x14012739e
mov rcx, qword [rcx + 0x10]
lea r8, [0x1401612a0]
mov edx, 0x3e
mov r9d, ebx
call fcn.14000c47c
mov eax, ebx
mov rcx, qword [rbp + 0x2f]
xor rcx, rsp
call fcn.140007410
lea r11, [rsp + 0x90]
mov rbx, qword [r11 + 0x38]
mov rdi, qword [r11 + 0x48]
mov rsp, r11
pop r15
pop r14
pop r13
pop r12
pop rbp
ret