Function at 0x1400125a0
Capabilities:
Create mailslot
Link many functions at runtime

Disassembly:
mov qword [rsp + 0x10], rbx
push rdi
sub rsp, 0x40
mov rdi, rcx
mov rbx, rdx
lea rcx, str.Advapi32.dll
call qword [sym.imp.KERNEL32.dll_LoadLibraryA]
mov qword [rdi + 0x6548], rax
test rax, rax
je 0x140012686
lea rdx, str.RegCreateKeyExA
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
mov rcx, qword [rdi + 0x6548]
lea rdx, [0x14010b280]
mov qword [rdi + 0x6550], rax
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
mov rcx, qword [rdi + 0x6548]
lea rdx, str.RegSetValueExA
mov qword [rdi + 0x6558], rax
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
mov rcx, qword [rdi + 0x6548]
lea rdx, [0x14010b2a0]
mov qword [rdi + 0x6560], rax
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
mov rcx, qword [rdi + 0x6548]
lea rdx, str.RegDeleteValueA
mov qword [rdi + 0x6568], rax
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
mov rcx, qword [rdi + 0x6548]
lea rdx, [0x14010b2c8]
mov qword [rdi + 0x6570], rax
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
mov rcx, qword [rdi + 0x6548]
lea rdx, str.RegDeleteKeyExA
mov qword [rdi + 0x6578], rax
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
mov qword [rdi + 0x6580], rax
xor r9d, r9d
lea rcx, str..mailslotyoctopuce_yapi
xor r8d, r8d
lea edx, [r9 + 8]
call qword [sym.imp.KERNEL32.dll_CreateMailslotA]
mov qword [rdi + 0x64e8], rax
cmp rax, 0xffffffffffffffff
jne 0x1400126ee
test rbx, rbx
je 0x1400126de
lea r9, str.ypkt_win
mov dword [rsp + 0x28], 0x121
mov qword [rsp + 0x20], r9
lea r8, str._s___s:_d_
lea r9, str.Another_process_is_already_using_yAPI
mov edx, 0x100
mov rcx, rbx
call fcn.1400217a0
mov eax, 0xfffffff5
mov rbx, qword [rsp + 0x58]
add rsp, 0x40
pop rdi
ret
lea rcx, str.HID.DLL
call qword [sym.imp.KERNEL32.dll_LoadLibraryA]
mov qword [rdi + 0x6510], rax
test rax, rax
jne 0x1400127ae
mov qword [rsp + 0x50], rsi
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov esi, eax
test rbx, rbx
je 0x140012799
mov dword [rsp + 0x30], eax
lea r9, str.ypkt_win
lea rax, [0x140079790]
mov edi, 0x100
mov qword [rsp + 0x28], rax
lea r8, str._s:_d:__s__d_
mov edx, edi
mov dword [rsp + 0x20], 0x141
mov rcx, rbx
call fcn.1400217a0
mov rax, 0xffffffffffffffff
nop dword [rax]
inc rax
cmp byte [rbx + rax], 0
jne 0x140012760
movsxd rcx, eax
sub edi, eax
add rcx, rbx
mov qword [rsp + 0x30], 0
mov dword [rsp + 0x28], edi
mov r9d, 0x400
mov qword [rsp + 0x20], rcx
mov r8d, esi
mov ecx, 0x1200
xor edx, edx
call qword [sym.imp.KERNEL32.dll_FormatMessageA]
mov rsi, qword [rsp + 0x50]
mov eax, 0xfffffff8
mov rbx, qword [rsp + 0x58]
add rsp, 0x40
pop rdi
ret
lea rdx, str.HidD_GetHidGuid
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
mov rcx, qword [rdi + 0x6510]
lea rdx, str.HidD_GetAttributes
mov qword [rdi + 0x6518], rax
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
mov rcx, qword [rdi + 0x6510]
lea rdx, str.HidD_GetManufacturerString
mov qword [rdi + 0x6520], rax
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
mov rcx, qword [rdi + 0x6510]
lea rdx, str.HidD_GetProductString
mov qword [rdi + 0x6528], rax
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
mov rcx, qword [rdi + 0x6510]
lea rdx, str.HidD_GetSerialNumberString
mov qword [rdi + 0x6530], rax
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
mov rcx, qword [rdi + 0x6510]
lea rdx, str.HidD_SetNumInputBuffers
mov qword [rdi + 0x6538], rax
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
mov ecx, 0x28
mov qword [rdi + 0x6540], rax
call fcn.140056e8c
mov rbx, rax
xor eax, eax
mov rcx, rbx
mov qword [rbx], rax
mov qword [rbx + 8], rax
mov qword [rbx + 0x10], rax
mov qword [rbx + 0x18], rax
mov qword [rbx + 0x20], rax
call qword [sym.imp.KERNEL32.dll_InitializeCriticalSection]
mov qword [rdi + 0x64f8], rbx
xor eax, eax
mov rbx, qword [rsp + 0x58]
add rsp, 0x40
pop rdi
ret