Function at 0x1400145f0
Capabilities:
Get keyboard layout
Log keystrokes via polling

Disassembly:
mov qword [rsp + 0x10], rbx
mov qword [rsp + 0x18], rsi
mov qword [rsp + 0x20], rdi
mov qword [rsp + 8], rcx
push rbp
push r12
push r13
push r14
push r15
lea rbp, [rsp - 0xb0]
sub rsp, 0x1b0
mov rbx, qword [0x14012bb70]
xor dil, dil
movzx r12d, r8w
movzx r15d, r9b
movzx r14d, dl
mov rax, rcx
mov esi, 1
test rbx, rbx
je 0x140014727
movabs r13, 0xffffffff003c2c17
nop dword [rax]
cmp dword [rbx], esi
jne 0x14001471a
movzx r9d, byte [rbx + 0x5c]
test r9b, r9b
je 0x14001468f
mov rax, qword [rax + 0x10]
dec r9b
mov r8d, 0xffc3d44d
mov ecx, reloc.WSOCK32.dll_WSAAsyncSelect
sub r8d, eax
lea rdx, [rax + r13]
movzx eax, r9b
cmp rdx, 0x66
cmovbe ecx, r8d
cmp ecx, eax
jle 0x140014713
test r15b, r15b
je 0x140014708
mov rax, qword [rbx + 0x10]
test rax, rax
je 0x1400146e9
cmp qword [rax + 0x3b0], 0
je 0x1400146e9
movzx edx, byte [r14 + rbx + 0x74]
movzx ecx, dl
or cl, byte [r12 + rbx + 0x174]
test cl, 0x20
jne 0x1400146c8
cmp byte [rbx + 0x62], 0
je 0x1400146e9
test dl, 0x40
jne 0x1400146e9
mov rcx, qword [0x14012bb88]
mov eax, r12d
shl eax, 0x10
mov r8, rbx
movsxd r9, eax
mov edx, 0x41e
or r9, r14
call qword [sym.imp.USER32.dll_PostMessageW]
movzx eax, byte [r12 + rbx + 0x174]
test al, al
js 0x140014808
movzx eax, byte [r14 + rbx + 0x74]
test al, al
js 0x1400147fa
cmp byte [rbx + 0x5f], 0
movzx edi, dil
cmovne edi, esi
mov rax, qword [rbp + 0xe0]
mov rbx, qword [rbx + 8]
test rbx, rbx
jne 0x140014650
test r15b, r15b
jne 0x140014c87
movzx eax, byte [0x14012bd89]
xor ebx, ebx
movzx r15d, sil
test al, 0xcf
je 0x14001475a
test dil, dil
jne 0x14001475a
test al, 0xc
movzx r15d, sil
setne cl
test al, 3
setne al
test al, cl
cmove r15d, ebx
call qword [sym.imp.USER32.dll_GetForegroundWindow]
mov qword [rsp + 0x50], rax
mov edi, ebx
test rax, rax
je 0x1400147a6
xor edx, edx
mov rcx, rax
call qword [sym.imp.USER32.dll_GetWindowThreadProcessId]
lea rdx, [rsp + 0x60]
mov dword [rsp + 0x60], 0x48
mov ecx, eax
mov edi, eax
call qword [sym.imp.USER32.dll_GetGUIThreadInfo]
test eax, eax
je 0x1400147a6
mov rcx, qword [rsp + 0x70]
test rcx, rcx
je 0x1400147a6
xor edx, edx
call qword [sym.imp.USER32.dll_GetWindowThreadProcessId]
mov edi, eax
mov ecx, edi
call qword [sym.imp.USER32.dll_GetKeyboardLayout]
mov r13, rax
mov rax, qword [rsp + 0x50]
cmp qword [0x14012e1b0], rax
je 0x140014819
mov r8d, 0x1c
mov qword [0x14012e1b0], rax
lea rdx, [rsp + 0x60]
mov rcx, rax
call qword [sym.imp.USER32.dll_GetClassNameW]
lea rdx, str.ApplicationFrameWindow
lea rcx, [rsp + 0x60]
call fcn.1400c5794
test eax, eax
sete r8b
mov byte [0x14012e1ad], r8b
jmp 0x140014821
and al, 0x7f
mov byte [r14 + rbx + 0x74], al
xor al, al
jmp 0x140014c89
and al, 0x7f
mov byte [r12 + rbx + 0x174], al
xor al, al
jmp 0x140014c89
movzx r8d, byte [0x14012e1ad]
xor eax, eax
lea rcx, [0x14012be80]
mov dword [rsp + 0x40], eax
mov edx, 2
mov word [rsp + 0x44], ax
lea rax, [rbp - 0x50]
nop dword [rax]
lea rax, [rax + 0x80]
movups xmm0, xmmword [rcx]
movups xmm1, xmmword [rcx + 0x10]
lea rcx, [rcx + 0x80]
movups xmmword [rax - 0x80], xmm0
movups xmm0, xmmword [rcx - 0x60]
movups xmmword [rax - 0x70], xmm1
movups xmm1, xmmword [rcx - 0x50]
movups xmmword [rax - 0x60], xmm0
movups xmm0, xmmword [rcx - 0x40]
movups xmmword [rax - 0x50], xmm1
movups xmm1, xmmword [rcx - 0x30]
movups xmmword [rax - 0x40], xmm0
movups xmm0, xmmword [rcx - 0x20]
movups xmmword [rax - 0x30], xmm1
movups xmm1, xmmword [rcx - 0x10]
movups xmmword [rax - 0x20], xmm0
movups xmmword [rax - 0x10], xmm1
sub rdx, rsi
jne 0x140014840
movzx edi, byte [0x14012e1ac]
test dil, dil
je 0x14001493d
test r8b, r8b
je 0x14001493d
cmp r14b, 0xe7
je 0x14001493d
movzx eax, byte [0x14012e1aa]
neg al
movzx eax, byte [0x14012e1ab]
sbb dl, dl
and dl, 0x20
neg al
sbb cl, cl
and cl, 9
or dl, cl
lea rcx, [rbp - 0x50]
call fcn.140022c30
movzx edx, word [0x14012e1a8]
lea r9, [rsp + 0x40]
mov qword [rsp + 0x30], r13
lea r8, [rbp - 0x50]
mov dword [rsp + 0x28], ebx
mov ecx, edi
mov dword [rsp + 0x20], 2
call qword [sym.imp.USER32.dll_ToUnicodeEx]
test eax, eax
jle 0x140014937
movzx edx, word [0x14012e1a8]
lea r9, [rsp + 0x40]
movzx ecx, byte [0x14012e1ac]
lea r8, [rbp - 0x50]
mov qword [rsp + 0x30], r13
mov dword [rsp + 0x28], ebx
mov dword [rsp + 0x20], 2
call qword [sym.imp.USER32.dll_ToUnicodeEx]
mov byte [0x14012e1ac], bl
movzx edx, byte [0x14012bd89]
lea rcx, [rbp - 0x50]
call fcn.140022c30
mov ecx, reloc.OLEAUT32.dll_SafeArrayLock
call qword [sym.imp.USER32.dll_GetKeyState]
test sil, al
je 0x140014963
or byte [rbp - 0x3c], sil
jmp 0x140014967
and byte [rbp - 0x3c], 0xfe
mov edi, 0xa
cmp r14b, 0xe7
jne 0x140014988
mov r15, qword [rbp + 0xe0]
movzx eax, word [r15 + 4]
mov word [rsp + 0x40], ax
jmp 0x140014a0d
test r15b, r15b
mov r15, qword [rbp + 0xe0]
je 0x1400149ed
cmp dword [0x14012bb3c], ebx
lea r9, [rsp + 0x40]
mov edx, dword [r15 + 4]
lea r8, [rbp - 0x50]
mov eax, ebx
mov qword [rsp + 0x30], r13
setne al
mov ecx, r14d
mov dword [rsp + 0x28], eax
mov dword [rsp + 0x20], 2
call qword [sym.imp.USER32.dll_ToUnicodeEx]
test byte [0x14012bd89], 3
mov esi, eax
jne 0x1400149ef
cmp word [rsp + 0x40], 0xd
jne 0x1400149de
mov word [rsp + 0x40], di
cmp word [rsp + 0x42], 0xd
jne 0x1400149ef
mov word [rsp + 0x42], di
jmp 0x1400149ef
mov esi, ebx
cmp r14b, 8
jne 0x140014a0d
test esi, esi
je 0x140014a0d
cmp byte [0x14012e1ad], bl
je 0x140014a0b
mov esi, ebx
mov byte [0x14012e1ac], bl
jmp 0x140014a0d
dec esi
lea r9, [rsp + 0x40]
mov dword [rsp + 0x20], esi
movzx r8d, r12w
movzx edx, r14b
mov rcx, r15
call fcn.140015170
test al, al
je 0x140014812
cmp byte [0x14012e1ac], bl
je 0x140014a7f
test esi, esi
jle 0x140014a7f
mov r15b, 1
cmp dword [0x14012bffc], ebx
je 0x140014b80
cmp byte [rbp + 0x100], bl
jne 0x140014b80
lea eax, [r14 - 8]
cmp eax, 0x20
ja case.0x140014a7d.9
lea rdx, [0x140000000]
cdqe
movzx eax, byte [rdx + rax + 0x14cb8]
mov ecx, dword [rdx + rax*4 + 0x14cac]
add rcx, rdx
jmp rcx
xor r15b, r15b
test esi, esi
jns 0x140014a3d
movzx eax, byte [0x14012bd89]
lea r9, [rsp + 0x40]
test al, 0x30
mov qword [rsp + 0x30], r13
lea r8, [rbp - 0x50]
mov byte [0x14012e1ac], r14b
setne byte [0x14012e1aa]
mov word [0x14012e1a8], r12w
test al, 0xc
setne cl
test al, 3
setne al
and cl, al
mov rax, qword [rbp + 0xe0]
cmp dword [0x14012bb3c], ebx
mov byte [0x14012e1ab], cl
mov ecx, r14d
setne bl
mov edx, dword [rax + 4]
mov dword [rsp + 0x28], ebx
mov dword [rsp + 0x20], 2
call qword [sym.imp.USER32.dll_ToUnicodeEx]
jmp 0x140014c87
cmp dword [0x14012bcb8], ebx
je case.0x140014a7d.9
mov word [0x14012bcc0], bx
mov dword [0x14012bcb8], ebx
jmp case.0x140014a7d.9
cmp byte [0x14012bd89], bl
jne case.0x140014a7d.9
mov eax, dword [0x14012bcb8]
test eax, eax
je case.0x140014a7d.9
dec eax
mov dword [0x14012bcb8], eax
cdqe
mov word [rdx + rax*2 + 0x12bcc0], bx
mov r12, qword [rbp + 0xe0]
test esi, esi
jle 0x140014b87
mov rax, qword [rbp + 0x118]
lea rdx, [rsp + 0x40]
mov r9, qword [rsp + 0x50]
mov r8d, esi
mov qword [rsp + 0x30], rax
mov rcx, r12
mov rax, qword [rbp + 0x110]
mov qword [rsp + 0x28], rax
mov rax, qword [rbp + 0x108]
mov qword [rsp + 0x20], rax
call fcn.140014ce0
test al, al
jne 0x140014b87
mov byte [0x14012e1ac], bl
jmp 0x140014c89
mov r12, qword [rbp + 0xe0]
test r15b, r15b
je 0x140014c87
cmp dword [0x14012bb3c], ebx
lea r9, [rsp + 0x48]
mov edx, dword [r12 + 4]
lea r8, [rbp - 0x50]
mov eax, ebx
mov qword [rsp + 0x30], r13
setne al
mov ecx, r14d
mov dword [rsp + 0x28], eax
mov r15d, r14d
mov dword [rsp + 0x20], 2
call qword [sym.imp.USER32.dll_ToUnicodeEx]
mov r14d, eax
test eax, eax
jns 0x140014c00
cmp dword [0x14012bb3c], ebx
lea r9, [rsp + 0x48]
mov edx, ebx
mov qword [rsp + 0x30], r13
setne dl
lea r8, [rbp - 0x50]
mov dword [rsp + 0x28], edx
mov ecx, r15d
mov edx, dword [r12 + 4]
mov dword [rsp + 0x20], 2
call qword [sym.imp.USER32.dll_ToUnicodeEx]
cmp r14d, esi
jne 0x140014c1b
mov eax, dword [rsp + 0x48]
cmp ax, 0xd
je 0x140014c12
movzx edi, ax
movzx eax, word [rsp + 0x40]
cmp eax, edi
je 0x140014c87
xor edx, edx
lea rcx, [rbp - 0x50]
mov r8d, 0x100
call fcn.1400e3010
movzx eax, byte [0x14012e1aa]
neg al
movzx eax, byte [0x14012e1ab]
sbb dl, dl
and dl, 0x20
neg al
sbb cl, cl
and cl, 9
or dl, cl
lea rcx, [rbp - 0x50]
call fcn.140022c30
movzx edx, word [0x14012e1a8]
lea r9, [rsp + 0x50]
movzx ecx, byte [0x14012e1ac]
lea r8, [rbp - 0x50]
mov qword [rsp + 0x30], r13
mov dword [rsp + 0x28], ebx
mov dword [rsp + 0x20], 2
call qword [sym.imp.USER32.dll_ToUnicodeEx]
mov byte [0x14012e1ac], bl
mov al, 1
lea r11, [rsp + 0x1b0]
mov rbx, qword [r11 + 0x38]
mov rsi, qword [r11 + 0x40]
mov rdi, qword [r11 + 0x48]
mov rsp, r11
pop r15
pop r14
pop r13
pop r12
pop rbp
ret