Function at 0x1400072ed
Capabilities:
Read file on windows

Disassembly:
push r15
push r14
push r13
push r12
push rbp
push rdi
push rsi
push rbx
sub rsp, 0x1c8
xor r8d, r8d
xor edx, edx
mov r9d, 0x12
mov r14, rcx
mov rcx, qword [0x1400b1120]
call qword [sym.imp.SETUPAPI.dll_SetupDiGetClassDevsA]
mov qword [rsp + 0x40], rax
inc rax
jne 0x14000733e
call fcn.140036bd7
lea rcx, str.SetupDiGetClassDevs__Interface__failed:__s
mov rdx, rax
call fcn.140036717
jmp 0x14000773b
mov rax, qword [sym.imp.SETUPAPI.dll_SetupDiEnumDeviceInfo]
xor r11d, r11d
or rbx, 0xffffffffffffffff
mov dword [rsp + 0x80], 0x20
mov dword [rsp + 0x54], r11d
mov qword [rsp + 0x58], rax
lea rax, [rsp + 0x80]
mov edx, dword [rsp + 0x54]
mov rcx, qword [rsp + 0x40]
mov qword [rsp + 0x48], rax
mov r8, rax
mov rax, qword [rsp + 0x58]
call rax
test eax, eax
je 0x14000773b
lea r12, [0x1400fa3e0]
xor eax, eax
mov ecx, 0x41
mov rdx, qword [rsp + 0x48]
mov rdi, r12
lea rsi, [rsp + 0x78]
lea r8, [rsp + 0x7c]
mov r9, r12
rep stosd dword [rdi], eax
mov qword [rsp + 0x20], rsi
mov rcx, qword [rsp + 0x40]
call fcn.140006da4
test eax, eax
jne 0x140007408
call fcn.140036bd7
lea rcx, str.SetupDiGetDeviceRegistryProperty__Friendly_Name__failed:__s
mov rdx, rax
call fcn.140036717
movabs rax, 0x20636972656e6547
movabs rdx, 0x206c61636974704f
mov qword [0x1400fa3e0], rax
movabs rax, 0x6576697244206c
mov qword [0x1400fa3e8], rdx
mov qword [0x1400fa3ee], rax
mov rdx, r12
lea rcx, str.Found__s_optical_device
xor ebp, ebp
call fcn.140036717
mov rax, qword [0x1400b1120]
xor r10d, r10d
mov dword [rsp + 0xa0], 0x20
mov dword [rsp + 0x68], r10d
mov rdi, qword [sym.imp.SETUPAPI.dll_SetupDiEnumDeviceInterfaces]
mov qword [rsp + 0x60], rax
lea rax, [rbx - 1]
cmp rax, 0xfffffffffffffffd
ja 0x140007456
mov rcx, rbx
or rbx, 0xffffffffffffffff
call qword [sym.imp.KERNEL32.DLL_CloseHandle]
mov rcx, rbp
lea r13, [rsp + 0xa0]
call sub.msvcrt.dll_free
mov qword [rsp + 0x20], r13
mov r9d, dword [rsp + 0x68]
mov r8, qword [rsp + 0x60]
mov rdx, qword [rsp + 0x48]
mov rcx, qword [rsp + 0x40]
call rdi
test eax, eax
jne 0x1400074af
call qword [sym.imp.KERNEL32.DLL_GetLastError]
cmp eax, 0x103
je 0x140007732
call fcn.140036bd7
lea rcx, str.SetupDiEnumDeviceInterfaces_failed:__s
mov rdx, rax
call fcn.140036717
jmp 0x140007732
xor r9d, r9d
xor r8d, r8d
mov qword [rsp + 0x20], rsi
mov rcx, qword [rsp + 0x40]
mov qword [rsp + 0x28], r9
mov r15, qword [sym.imp.SETUPAPI.dll_SetupDiGetDeviceInterfaceDetailA]
xor r9d, r9d
mov rdx, r13
call r15
test eax, eax
jne 0x140007566
call qword [sym.imp.KERNEL32.DLL_GetLastError]
cmp eax, 0x7a
jne 0x14000754b
mov edx, dword [rsp + 0x78]
mov ecx, 1
mov dword [rsp + 0x6c], edx
call sub.msvcrt.dll_calloc
mov r9d, dword [rsp + 0x6c]
lea rcx, str.Unable_to_allocate_data_for_SP_DEVICE_INTERFACE_DETAIL_DATA
test rax, rax
mov rbp, rax
je 0x14000756d
xor r8d, r8d
mov dword [rax], 8
mov rcx, qword [rsp + 0x40]
mov rdx, r13
mov qword [rsp + 0x28], r8
mov r8, rax
mov qword [rsp + 0x20], rsi
call r15
test eax, eax
jne 0x140007574
call fcn.140036bd7
lea rcx, str.SetupDiGetDeviceInterfaceDetail__actual__failed:__s
mov rdx, rax
call fcn.140036717
jmp 0x140007729
call fcn.140036bd7
lea rcx, str.SetupDiGetDeviceInterfaceDetail__dummy__failed:__s
mov rdx, rax
call fcn.140036717
xor ebp, ebp
jmp 0x140007729
lea rcx, str.SetupDiGetDeviceInterfaceDetail__dummy____no_data_was_allocated
call fcn.140036717
jmp 0x14000755f
xor ecx, ecx
lea r15, [rbp + 4]
xor r9d, r9d
mov r8d, 1
mov qword [rsp + 0x30], rcx
mov edx, 0x80000000
mov rcx, r15
mov dword [rsp + 0x28], 0x8000000
mov dword [rsp + 0x20], 3
call qword [sym.imp.KERNEL32.DLL_CreateFileA]
mov rbx, rax
cmp rax, 0xffffffffffffffff
je 0x140007729
xor edx, edx
lea rax, [rsp + 0xc0]
xor r9d, r9d
xor r8d, r8d
mov qword [rsp + 0x38], rdx
mov rcx, rbx
mov edx, 0x700a0
mov qword [rsp + 0x30], rsi
mov dword [rsp + 0x28], 0x100
mov qword [rsp + 0x20], rax
call qword [sym.imp.KERNEL32.DLL_DeviceIoControl]
test eax, eax
je 0x140007729
cmp qword [rsp + 0xd8], 0x1000
jle 0x140007729
mov ecx, 0x800
call sub.msvcrt.dll_malloc
mov r13, rax
test rax, rax
je 0x1400076a6
xor r9d, r9d
xor r8d, r8d
mov edx, 0x8000
mov rcx, rbx
call qword [sym.imp.KERNEL32.DLL_SetFilePointerEx]
test eax, eax
je 0x1400076a6
xor eax, eax
mov r9, rsi
mov r8d, 0x800
mov rdx, r13
mov qword [rsp + 0x20], rax
mov rcx, rbx
call qword [sym.imp.KERNEL32.DLL_ReadFile]
test eax, eax
je 0x1400076a6
cmp dword [rsp + 0x78], 0x800
jne 0x1400076a6
movups xmm0, xmmword [r13 + 0x28]
movups xmm1, xmmword [r13 + 0x38]
lea rsi, [0x1400fa3a0]
mov byte [0x1400fa3c0], 0
mov rcx, rsi
movups xmmword [0x1400fa3a0], xmm0
movups xmmword [0x1400fa3b0], xmm1
call sub.msvcrt.dll_strlen
dec eax
cdqe
cmp eax, 0xffffffff
jne 0x140007697
mov qword [r14 + 0x28], rsi
jmp 0x1400076a6
cmp byte [rsi + rax], 0x20
jne 0x140007691
mov byte [rsi + rax], 0
dec rax
jmp 0x14000768c
mov rcx, r15
lea rdi, [0x1400fa3e0]
mov rsi, r15
call sub.msvcrt.dll_strlen
lea rcx, [rax + 1]
mov eax, 0x104
cmp rcx, rax
cmova rcx, rax
mov ecx, ecx
rep movsb byte [rdi], byte [rsi]
mov rcx, r15
call sub.msvcrt.dll_strlen
lea rdx, [0x1400fa4e3]
lea rcx, [rax + 1]
cmp rcx, 0x103
ja 0x1400076ec
lea rdx, [r12 + rax]
mov rax, qword [rsp + 0xd8]
mov byte [rdx], 0
mov qword [r14 + 0x18], r12
mov qword [r14 + 0x10], rax
lea rax, [rbx - 1]
cmp rax, 0xfffffffffffffffd
ja 0x140007712
mov rcx, rbx
call qword [sym.imp.KERNEL32.DLL_CloseHandle]
mov rcx, rbp
call sub.msvcrt.dll_free
mov rcx, r13
call sub.msvcrt.dll_free
mov eax, 1
jmp 0x14000773d
inc dword [rsp + 0x68]
jmp 0x14000743f
inc dword [rsp + 0x54]
jmp 0x140007361
xor eax, eax
add rsp, 0x1c8
pop rbx
pop rsi
pop rdi
pop rbp
pop r12
pop r13
pop r14
pop r15
ret