Function at 0x14017e590
Capabilities:
Resolve function by parsing pe exports

Disassembly:
endbr64
push r15
push r14
push r13
push r12
push rbp
push rdi
push rsi
push rbx
sub rsp, 0x78
mov rsi, qword [0x140485900]
mov rax, qword [rsp + 0xf0]
mov rbp, qword [rsp + 0xe0]
mov r15, qword [rsp + 0xe8]
mov rdi, qword [rsp + 0xf8]
mov qword [rsp + 0x28], rax
lea r14, [rcx + 0x30]
mov rbx, rcx
mov r13, rdx
mov rax, qword [rsi]
mov qword [rsp + 0x68], rax
xor eax, eax
lea rsi, [rcx + 0x48]
mov rcx, r14
mov qword [rsp + 0x20], r9
mov rdx, rsi
mov r12, r8
call method.void_boost::detail::lock_impl_boost::recursive_mutex__boost.mutex__boost::recursive_mutex__boost::mutex__boost::detail::is_mutex_type_wrapper_true____clone_.isra.0_
mov rcx, rbx
mov r8d, 0x20
call method.hw::ledger::device_ledger.reset_buffer__
mov byte [rbx + 0x90], 0
lea rcx, [rbx + 0x92]
mov rdx, r13
mov dword [rbx + 0x8c], 0xa004
movzx eax, byte [rbp]
mov byte [rbx + 0x91], al
call sym.memmove
lea rcx, [rbx + 0xb2]
mov r8d, 0x20
mov rdx, r12
call sym.memmove
mov rdx, qword [rsp + 0x20]
lea rcx, [rbx + 0xd2]
mov r8d, 0x20
call sym.memmove
cmp byte [rbp], 0
mov dword [rsp + 0x3c], 0x66
je 0x14017e758
lea rdx, [rbp + 1]
lea rcx, [rbx + 0xf2]
mov r8d, 0x20
call sym.memmove
lea rcx, [rbx + 0x112]
mov r8d, 0x20
mov rdx, r15
call sym.memmove
mov rdx, qword [rsp + 0x28]
mov rcx, rbx
lea r8, [rsp + 0x3c]
mov dword [rsp + 0x3c], 0xa6
call method.hw::ledger::device_ledger.send_secret_unsigned_char_const__int_
mov eax, dword [rsp + 0x3c]
mov r8d, 0xffff
mov rcx, rbx
lea edx, [rax - 5]
mov dword [rbx + 0x88], eax
mov byte [rbx + 0x90], dl
mov edx, 0x9000
call method.hw::ledger::device_ledger.exchange_unsigned_int__unsigned_int_
lea rdx, [rbx + 0x198]
mov rcx, rdi
mov r8d, 0x20
call sym.memmove
lea rdx, [rbx + 0x1b8]
lea rcx, [rdi + 0x20]
mov r8d, 0x20
call sym.memmove
mov eax, 0x80000000
lock xadd dword [rsi], eax
test eax, 0x40000000
jne 0x14017e71e
cmp eax, 0x80000000
jne 0x14017e770
mov eax, dword [rbx + 0x30]
sub eax, 1
mov dword [rbx + 0x30], eax
je 0x14017e7b8
mov rdi, qword [0x140485900]
mov rax, qword [rsp + 0x68]
sub rax, qword [rdi]
jne 0x14017e828
add rsp, 0x78
pop rbx
pop rsi
pop rdi
pop rbp
pop r12
pop r13
pop r14
pop r15
ret
pxor xmm0, xmm0
movups xmmword [rbx + 0xf2], xmm0
movups xmmword [rbx + 0x102], xmm0
jmp 0x14017e687
mov edx, dword [rbx + 0x48]
nop dword [rax + rax]
mov ecx, edx
mov eax, edx
or ecx, 0x40000000
lock cmpxchg dword [rsi], ecx
mov ecx, edx
mov edx, eax
cmp ecx, eax
jne 0x14017e778
and edx, 0x40000000
jne 0x14017e71e
mov rsi, qword [rbx + 0x50]
lea rdi, [rbx + 0x50]
test rsi, rsi
je 0x14017e7d0
mov rcx, rsi
call qword [sym.imp.KERNEL32.dll_SetEvent]
jmp 0x14017e71e
xchg dword [rbx + 0x34], eax
lea rcx, [rbx + 0x38]
call method.boost::detail::basic_timed_mutex.unlock__
jmp 0x14017e72d
xor ecx, ecx
xor r9d, r9d
xor r8d, r8d
xor edx, edx
call qword [sym.imp.KERNEL32.dll_CreateEventA]
mov rcx, rax
test rax, rax
je 0x14017e82d
mov rax, rsi
lock cmpxchg qword [rdi], rcx
mov rsi, rax
test rax, rax
je 0x14017e7a6
call qword [sym.imp.KERNEL32.dll_CloseHandle]
jmp 0x14017e7a3
call dbg.__stack_chk_fail
lea rbx, [rsp + 0x40]
lea r8, [0x1403b051a]
mov edx, 0xb
mov rcx, rbx
call method.boost::thread_exception.thread_exception_int__char_const_
mov rdi, qword [0x140485900]
lea rax, method.boost::thread_resource_error.thread_resource_error__
mov qword [rsp + 0x40], rax
mov rax, qword [rsp + 0x68]
sub rax, qword [rdi]
jne 0x14017e828
mov rcx, rbx
call method.void_boost::throw_exception_boost.thread_resource_error__boost::thread_resource_error_const_
endbr64
lea rax, method.boost::system::system_error.system_error__
mov rcx, rbx
mov qword [rsp + 0x40], rax
call sym.std::runtime_error::runtime_error__
call sym.std::terminate__
mov rcx, rbx
call sym._Unwind_Resume
nop
nop
nop word cs:[rax + rax]
nop dword [rax]