Function at 0x140022b40
Capabilities:
Log keystrokes via polling

Disassembly:
mov rax, rsp
push rbx
push rbp
push rsi
push rdi
push r12
push r14
push r15
sub rsp, 0x30
and qword [rax + 0x20], 0
xor bpl, bpl
mov r8d, 1
mov rdi, rdx
mov r14, rcx
mov r12b, r8b
test rdx, rdx
jne 0x140022b77
mov ebx, 0x80070057
jmp 0x140022da8
xor ebx, ebx
cmp qword [rdx + 0x10], 0x1b
jne 0x140022bb1
add rcx, 0xffffffffffffffd8
mov byte [rsp + 0x78], bl
lea rdx, [rsp + 0x78]
call fcn.140021cb0
mov ebx, eax
test eax, eax
js 0x140022bab
cmp byte [rsp + 0x78], bpl
je 0x140022bab
xor r12b, r12b
lea rsi, [rdi + 8]
jmp 0x140022c4e
mov r8d, 1
lea r15, [rdi + 8]
mov ecx, dword [r15]
sub ecx, 0x100
je 0x140022be7
sub ecx, 1
je 0x140022bdf
sub ecx, 3
je 0x140022bd7
cmp ecx, 1
jne 0x140022c42
mov edx, dword [0x140044bc8]
jmp 0x140022bed
mov edx, dword [0x140044bd0]
jmp 0x140022bed
mov edx, dword [0x140044bc4]
jmp 0x140022bed
mov edx, dword [0x140044bcc]
mov rsi, r15
test edx, edx
je 0x140022c4e
cmp dword [r14 + 0x188], 0
lea rcx, [r14 - 0x28]
jne 0x140022c0d
cmp qword [r14 + 0x38], 0
jne 0x140022c0d
xor eax, eax
jmp 0x140022c10
mov al, r8b
mov r9, qword [rdi + 0x18]
mov r8, qword [rdi + 0x10]
mov byte [rsp + 0x20], al
call fcn.140002828
test rax, rax
jne 0x140022c3d
cmp dword [r14 + 0x188], 4
jne 0x140022c4e
call qword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0x5b4
jne 0x140022c4e
mov ebp, 1
mov rsi, r15
test bpl, bpl
jne 0x140022d9c
mov eax, dword [rsi]
mov r15d, 1
sub eax, 0x100
cmp eax, r15d
ja 0x140022c85
cmp qword [rdi + 0x10], 0x1b
jne 0x140022c85
cmp dword [r14 + 0x188], 0
jne 0x140022c85
cmp qword [r14 + 0x38], 0
jne 0x140022c85
test r12b, r12b
je 0x140022c85
mov bpl, r15b
jmp 0x140022d0d
lea rdx, [rsp + 0x88]
lea rcx, [r14 - 0x28]
call fcn.140021d8c
mov ebx, eax
test eax, eax
js 0x140022da8
cmp qword [rsp + 0x88], 0
jne 0x140022cb5
mov ebx, 0x8000ffff
jmp 0x140022da8
mov rcx, qword [rsp + 0x88]
mov rdx, rdi
mov rax, qword [rcx]
mov rax, qword [rax + 0x28]
call qword [case.0x140007cca.0]
test eax, eax
movzx ebp, bpl
mov ebx, eax
mov eax, r15d
cmove ebp, eax
cmp ebx, eax
jne 0x140022d0d
cmp dword [rsi], 0x100
jne 0x140022d0d
cmp qword [rdi + 0x10], 9
jne 0x140022d0d
lfence
mov r9, qword [rdi + 0x18]
lea rcx, [r14 - 0x28]
mov r8, qword [rdi + 0x10]
mov edx, dword [0x140044be0]
mov byte [rsp + 0x20], 0
call fcn.140002828
cmp dword [rsi], 0x104
jne 0x140022d45
cmp qword [rdi + 0x10], 0x79
jne 0x140022d45
mov ecx, reloc.OLEAUT32.dll_SafeArrayGetElemsize
call qword [sym.imp.USER32.dll_GetKeyState]
bt ax, 0xf
jae 0x140022d45
mov ecx, reloc.OLEAUT32.dll_SafeArrayGetDim
call qword [sym.imp.USER32.dll_GetKeyState]
bt ax, 0xf
jae 0x140022d45
mov bpl, r15b
jmp 0x140022d9c
and dword [rsp + 0x80], 0
lea rcx, [r14 + 8]
mov rax, qword [rcx]
lea r8, [rsp + 0x80]
xor edx, edx
mov rax, qword [rax + 0xa0]
call qword [case.0x140007cca.0]
cmp dword [rsp + 0x80], 0
je 0x140022d9c
cmp dword [rsi], 0x105
jne 0x140022d9c
cmp qword [rdi + 0x10], 0x79
jne 0x140022d9c
mov ecx, reloc.OLEAUT32.dll_SafeArrayGetDim
call qword [sym.imp.USER32.dll_GetKeyState]
bt ax, 0xf
movzx ebp, bpl
cmovb ebp, r15d
test ebx, ebx
js 0x140022da8
xor ebx, ebx
test bpl, bpl
sete bl
mov rcx, qword [rsp + 0x88]
test rcx, rcx
je 0x140022dc2
mov rdx, qword [rcx]
mov rax, qword [rdx + 0x10]
call qword [case.0x140007cca.0]
mov eax, ebx
add rsp, 0x30
pop r15
pop r14
pop r12
pop rdi
pop rsi
pop rbp
pop rbx
ret