Function at 0x140174830
Capabilities:
Get disk information
Get disk size
Get storage device properties

Disassembly:
push rbp
push rbx
push r13
push r14
push r15
lea rbp, [rsp - 0x3c0]
sub rsp, 0x4c0
mov rax, qword [0x140415a10]
xor rax, rsp
mov qword [rbp + 0x3b0], rax
mov eax, dword [0x140345f88]
movsd xmm0, qword [0x140345f80]
xor r15d, r15d
mov dword [rbp - 0x60], eax
movzx eax, word [0x140345f8c]
movzx r14d, cx
movsd qword [rbp - 0x68], xmm0
mov word [rsp + 0x48], cx
mov word [rbp - 0x60], cx
mov qword [rsp + 0x30], r15
lea r8d, [r15 + 3]
lea rcx, [rbp - 0x68]
xor r9d, r9d
mov edx, 0x100081
mov dword [rsp + 0x28], r15d
mov word [rbp - 0x5c], ax
or r13d, 0xffffffff
mov dword [rsp + 0x20], 3
call qword [sym.imp.KERNEL32.dll_CreateFileW]
mov rbx, rax
cmp rax, 0xffffffffffffffff
je 0x140174ddb
mov qword [rsp + 0x38], r15
lea rax, [rsp + 0x40]
xor r9d, r9d
mov qword [rsp + 0x30], rax
lea rax, [rbp + 0xb0]
xor r8d, r8d
mov edx, 0x560000
mov rcx, rbx
mov dword [rsp + 0x28], 0x100
mov qword [rsp + 0x20], rax
call qword [sym.imp.KERNEL32.dll_DeviceIoControl]
test eax, eax
je 0x140174914
cmp dword [rsp + 0x40], 0x20
jb 0x140174914
cmp dword [rbp + 0xb0], 1
cmove r13d, dword [rbp + 0xb8]
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_CloseHandle]
cmp r13d, 0xffffffff
je 0x140174ddb
lea r8, str..PhysicalDrive_d
lea rcx, [rbp + 0x80]
mov r9d, r13d
mov edx, 0x18
mov qword [rsp + 0x4f8], rsi
call fcn.1402ba928
xor r9d, r9d
mov qword [rsp + 0x30], r15
lea rcx, [rbp + 0x80]
lea r8d, [r9 + 3]
mov edx, 0x100003
mov dword [rsp + 0x28], r15d
mov dword [rsp + 0x20], 3
call qword [sym.imp.KERNEL32.dll_CreateFileW]
mov rsi, rax
mov qword [rsp + 0x60], rax
cmp rax, 0xffffffffffffffff
jne 0x1401749ac
xor eax, eax
mov rsi, qword [rsp + 0x4f8]
mov rcx, qword [rbp + 0x3b0]
xor rcx, rsp
call fcn.1402b6d40
add rsp, 0x4c0
pop r15
pop r14
pop r13
pop rbx
pop rbp
ret
lea rax, [rsp + 0x58]
mov qword [rsp + 0x38], r15
lea r8, [rbp - 0x80]
mov qword [rsp + 0x30], rax
mov eax, 0x200
mov r9d, 0xc
mov dword [rsp + 0x28], eax
lea rax, [rbp + 0x1b0]
mov edx, 0x2d1400
mov rcx, rsi
mov qword [rbp - 0x80], r15
mov qword [rsp + 0x20], rax
call qword [sym.imp.KERNEL32.dll_DeviceIoControl]
test eax, eax
je 0x140174dca
cmp dword [rbp + 0x1cc], 7
jne 0x140174dca
xor eax, eax
mov word [rbp - 0x10], r15w
mov word [rbp - 0x50], r15w
mov qword [rbp - 0xe], rax
mov qword [rbp - 6], rax
mov qword [rbp + 2], rax
mov qword [rbp + 0xa], rax
mov qword [rbp + 0x12], rax
mov qword [rbp + 0x1a], rax
mov qword [rbp + 0x22], rax
mov dword [rbp + 0x2a], eax
mov word [rbp + 0x2e], ax
mov qword [rbp - 0x4e], rax
mov qword [rbp - 0x46], rax
mov qword [rbp - 0x3e], rax
mov qword [rbp - 0x36], rax
mov qword [rbp - 0x2e], rax
mov qword [rbp - 0x26], rax
mov qword [rbp - 0x1e], rax
mov dword [rbp - 0x16], eax
mov word [rbp - 0x12], ax
mov eax, dword [rbp + 0x1bc]
test eax, eax
je 0x140174ac6
lea r9, [rbp + 0x1b0]
lea rdx, [rbp - 0x10]
lea rcx, [rsp + 0x40]
mov r8d, 0x20
add r9, rax
mov qword [rsp + 0x20], 0x20
call fcn.1402bbaf0
test eax, eax
jne 0x140174ac6
mov rax, qword [rsp + 0x40]
sub rax, 2
mov qword [rsp + 0x40], rax
lea rcx, [rax + rax]
cmp word [rbp + rcx - 0x10], 0x20
jne 0x140174ac6
cmp rcx, 0x40
jae 0x140174de2
dec rax
mov word [rbp + rcx - 0x10], r15w
lea rcx, [rax + rax]
mov qword [rsp + 0x40], rax
cmp word [rbp + rcx - 0x10], 0x20
je 0x140174aa2
mov eax, dword [rbp + 0x1c0]
test eax, eax
je 0x140174b39
lea r9, [rbp + 0x1b0]
lea rdx, [rbp - 0x50]
lea rcx, [rsp + 0x40]
mov r8d, 0x20
add r9, rax
mov qword [rsp + 0x20], 0x20
call fcn.1402bbaf0
test eax, eax
jne 0x140174b39
mov rax, qword [rsp + 0x40]
sub rax, 2
mov qword [rsp + 0x40], rax
lea rcx, [rax + rax]
cmp word [rbp + rcx - 0x50], 0x20
jne 0x140174b39
cmp rcx, 0x40
jae 0x140174de8
dec rax
mov word [rbp + rcx - 0x50], r15w
lea rcx, [rax + rax]
mov qword [rsp + 0x40], rax
cmp word [rbp + rcx - 0x50], 0x20
je 0x140174b15
lea r8, [rbp - 0x10]
lea rcx, [rbp + 0xb0]
mov edx, 0x40
call fcn.1402b6e28
cmp dword [rbp + 0x1c0], r15d
jbe 0x140174b84
lea r8, [0x14034cfc8]
lea rcx, [rbp + 0xb0]
mov edx, 0x40
call fcn.1402b9308
lea r8, [rbp - 0x50]
lea rcx, [rbp + 0xb0]
mov edx, 0x40
call fcn.1402b9308
cmp byte [rbp + 0x1ba], r15b
lea rax, str.removable
lea r9, str.fixed
lea r8, [rbp + 0xb0]
lea rcx, str._c:__s__s_disk__d_r_n
movzx edx, r14w
cmovne r9, rax
mov qword [rsp + 0x500], rdi
mov dword [rsp + 0x20], r13d
call fcn.1402b9694
cmp byte [rbp + 0x1ba], 1
sete al
test al, al
jne 0x140174c08
mov ebx, r15d
lea rdi, str.SanDisk_Cruzer
nop dword [rax]
mov rdx, qword [rdi]
lea rcx, [rbp + 0xb0]
call fcn.1401fa9b0
test rax, rax
jne 0x140174c08
inc ebx
add rdi, 8
movsxd rax, ebx
cmp rax, 1
jb 0x140174be0
jmp 0x140174dc2
mov dword [rsp + 0x38], r15d
movabs rax, 0x5c003a005f
mov qword [rsp + 0x30], r15
mov qword [rbp - 0x70], rax
xor eax, eax
lea rdx, [rbp + 0x30]
lea rcx, [rbp - 0x70]
lea r8d, [rax + 0x21]
xor r9d, r9d
mov qword [rsp + 0x28], r15
mov word [rbp + 0x30], r15w
mov qword [rbp + 0x32], rax
mov qword [rbp + 0x3a], rax
mov qword [rbp + 0x42], rax
mov qword [rbp + 0x4a], rax
mov qword [rbp + 0x52], rax
mov qword [rbp + 0x5a], rax
mov qword [rbp + 0x62], rax
mov qword [rbp + 0x6a], rax
mov word [rbp - 0x70], r14w
mov qword [rsp + 0x20], r15
call qword [sym.imp.KERNEL32.dll_GetVolumeInformationW]
test eax, eax
je 0x140174dc2
mov qword [rsp + 0x38], r15
lea rax, [rsp + 0x40]
xor r9d, r9d
mov qword [rsp + 0x30], rax
lea rax, [rsp + 0x68]
xor r8d, r8d
mov edx, 0x70000
mov rcx, rsi
mov dword [rsp + 0x28], 0x18
mov qword [rsp + 0x20], rax
call qword [sym.imp.KERNEL32.dll_DeviceIoControl]
test eax, eax
je 0x140174dc2
mov qword [rsp + 0x38], r15
lea rax, [rsp + 0x40]
xor r9d, r9d
mov qword [rsp + 0x30], rax
lea rax, [rsp + 0x50]
xor r8d, r8d
mov edx, 0x7405c
mov rcx, rsi
mov dword [rsp + 0x28], 8
mov qword [rsp + 0x20], rax
call qword [sym.imp.KERNEL32.dll_DeviceIoControl]
test eax, eax
je 0x140174dc2
mov r8, qword [rsp + 0x50]
lea rdx, [rbp + 0x30]
lea rcx, str.___USB_flash_drive__s_size__I64u_r_n
mov qword [rsp + 0x508], r12
call fcn.1402b9694
mov ecx, 0x80
call fcn.1402b6dbc
mov r12, rax
test rax, rax
je 0x140174dba
mov r14, qword [rsp + 0x50]
mov rsi, qword [rsp + 0x68]
movzx edi, word [rsp + 0x74]
movzx ebx, word [rsp + 0x78]
lea rax, vtable.HitmanPro35::USBDrive.0
lea rcx, [rbp + 0x30]
mov qword [r12], rax
movzx eax, word [rsp + 0x48]
mov word [r12 + 8], ax
call fcn.1402b9ff0
lea rcx, [rbp + 0xb0]
mov qword [r12 + 0x10], rax
call fcn.1402b9ff0
lea rcx, [r12 + 0x24]
lea r8, str..PhysicalDrive_d
mov r9d, r13d
mov edx, 0x18
mov qword [r12 + 0x18], rax
mov dword [r12 + 0x20], r13d
call fcn.1402ba928
mov eax, 0x200
mov qword [r12 + 0x60], rsi
mov rsi, qword [rsp + 0x60]
mov qword [r12 + 0x70], r15
mov qword [r12 + 0x78], r15
mov word [r12 + 0x54], ax
mov word [r12 + 0x56], bx
mov word [r12 + 0x58], di
mov qword [r12 + 0x68], r14
mov r15, r12
mov r12, qword [rsp + 0x508]
mov rdi, qword [rsp + 0x500]
mov rcx, rsi
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov rax, r15
jmp 0x140174985
xor eax, eax
jmp 0x14017498d
call fcn.1402b8d20
int3
call fcn.1402b8d20
int3