Function at 0x140001e80
Capabilities:
Terminate process

Disassembly:
mov qword [rsp + 8], rbx
push rbp
lea rbp, [rsp - 0x57]
sub rsp, 0xa0
mov rax, qword [0x140053040]
xor rax, rsp
mov qword [rbp + 0x4f], rax
xorps xmm0, xmm0
movups xmmword [rbp - 9], xmm0
xorps xmm1, xmm1
movdqu xmmword [rbp + 7], xmm1
mov r8d, 0x10
lea rdx, str.USB_SERIAL_CH340
lea rcx, [rbp - 9]
call fcn.140001500
nop
lea rdx, [rbp - 9]
lea rcx, [rbp + 0x2f]
call fcn.140001600
nop
mov rdx, qword [rbp + 0xf]
cmp rdx, 0xf
jbe 0x140001f12
inc rdx
mov rcx, qword [rbp - 9]
mov rax, rcx
cmp rdx, 0x1000
jb 0x140001f0d
add rdx, 0x27
mov rcx, qword [rcx - 8]
sub rax, rcx
add rax, 0xfffffffffffffff8
cmp rax, 0x1f
jbe 0x140001f0d
call qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__invalid_parameter_noinfo_noreturn]
int3
call fcn.1400411f0
cmp qword [rbp + 0x3f], 0
jne 0x140001f44
lea rdx, str._n_t____no_port_found..._try_reconnecting_your_kmbox._exiting...
mov rcx, qword [sym.imp.MSVCP140.dll_class_std::basic_ostream_char__struct_std::char_traits_char___std::cout]
call fcn.140002420
mov rcx, rax
lea rdx, [0x140043d04]
call fcn.140002420
xor ecx, ecx
call qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll_exit]
int3
lea rcx, [rbp + 0x2f]
cmp qword [rbp + 0x47], 0xf
cmova rcx, qword [rbp + 0x2f]
xor ebx, ebx
mov qword [rsp + 0x30], rbx
mov dword [rsp + 0x28], 0x80
mov dword [rsp + 0x20], 3
xor r9d, r9d
xor r8d, r8d
mov edx, 0xc0000000
call qword [sym.imp.KERNEL32.dll_CreateFileA]
mov qword [0x1400542b0], rax
cmp rax, 0xffffffffffffffff
je 0x140002040
xorps xmm0, xmm0
movdqu xmmword [rbp - 5], xmm0
mov qword [rbp + 0xb], rbx
mov dword [rbp - 9], 0x1c
lea rdx, [rbp - 9]
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_GetCommState]
mov rcx, qword [0x1400542b0]
test eax, eax
je 0x14000203a
mov dword [rbp - 5], 0x1c200
mov word [rbp + 9], 8
mov byte [rbp + 0xb], bl
lea rdx, [rbp - 9]
call qword [sym.imp.KERNEL32.dll_SetCommState]
mov rcx, qword [0x1400542b0]
test eax, eax
je 0x14000203a
mov dword [rbp + 0x17], 5
mov dword [rbp + 0x1f], 5
mov dword [rbp + 0x1b], 5
mov dword [rbp + 0x27], 5
mov dword [rbp + 0x23], 5
lea rdx, [rbp + 0x17]
call qword [sym.imp.KERNEL32.dll_SetCommTimeouts]
test eax, eax
jne 0x14000205c
lea rdx, str.Error_setting_timeouts_
mov rcx, qword [sym.imp.MSVCP140.dll_class_std::basic_ostream_char__struct_std::char_traits_char___std::cerr]
call fcn.140002420
lea rdx, [0x1400025f0]
mov rcx, rax
call qword [sym.imp.MSVCP140.dll_public:_class_std::basic_ostream_char__struct_std::char_traits_char______ptr64___cdecl_std::basic_ostream_char__struct_std::char_traits_char__::operator___class_std::basic_ostream_char__struct_std::char_traits_char______ptr64____cdecl___class_std::basic_ostream_char__struct_std::char_traits_char______ptr64_____ptr64]
mov rcx, qword [0x1400542b0]
call qword [sym.imp.KERNEL32.dll_CloseHandle]
lea rdx, str._n_t____opening_the_kmbox_port_failed..._exiting
mov rcx, qword [sym.imp.MSVCP140.dll_class_std::basic_ostream_char__struct_std::char_traits_char___std::cout]
call fcn.140002420
xor ecx, ecx
call qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll_exit]
int3
mov rbx, qword [sym.imp.MSVCP140.dll_class_std::basic_ostream_char__struct_std::char_traits_char___std::cout]
lea r8, [rbp + 0x2f]
lea rcx, [rbp - 9]
call fcn.140002630
nop
mov r8, qword [rax + 0x10]
cmp qword [rax + 0x18], 0xf
jbe 0x14000207f
mov rax, qword [rax]
mov rdx, rax
mov rcx, rbx
call fcn.140002c40
mov rcx, rax
lea rdx, [0x140043d04]
call fcn.140002420
nop
mov rdx, qword [rbp + 0xf]
cmp rdx, 0xf
jbe 0x1400020d9
inc rdx
mov rcx, qword [rbp - 9]
mov rax, rcx
cmp rdx, 0x1000
jb 0x1400020d3
add rdx, 0x27
mov rcx, qword [rcx - 8]
sub rax, rcx
add rax, 0xfffffffffffffff8
cmp rax, 0x1f
jbe 0x1400020d3
call qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__invalid_parameter_noinfo_noreturn]
int3
call fcn.1400411f0
nop
mov rdx, qword [rbp + 0x47]
cmp rdx, 0xf
jbe 0x140002117
inc rdx
mov rcx, qword [rbp + 0x2f]
mov rax, rcx
cmp rdx, 0x1000
jb 0x140002112
add rdx, 0x27
mov rcx, qword [rcx - 8]
sub rax, rcx
add rax, 0xfffffffffffffff8
cmp rax, 0x1f
jbe 0x140002112
call qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__invalid_parameter_noinfo_noreturn]
int3
call fcn.1400411f0
mov rcx, qword [rbp + 0x4f]
xor rcx, rsp
call fcn.140040cb0
mov rbx, qword [rsp + 0xb0]
add rsp, 0xa0
pop rbp
ret