Function at 0x14006aaf0
Capabilities:
Log keystrokes via input method manager

Disassembly:
mov qword [rsp + 8], rbx
mov qword [rsp + 0x20], r9
mov qword [rsp + 0x18], r8
mov qword [rsp + 0x10], rdx
push rbp
push rsi
push rdi
push r12
push r13
push r14
push r15
mov rbp, rsp
sub rsp, 0x50
mov r14, r9
mov rdi, r8
mov r13, rcx
mov rcx, rdx
call fcn.1401c8250
mov r12, rax
test rax, rax
je 0x14006ae88
mov rcx, rdi
call qword [sym.imp.IMM32.dll_ImmGetContext]
mov rdi, rax
mov qword [rbp - 0x28], rax
test rax, rax
je 0x14006ae88
cmp dword [r13], 0
jge 0x14006ab75
mov rcx, qword [r12]
mov r8, qword [rcx + 0x10]
lea rdx, [rbp - 0x10]
mov rcx, r12
call r8
mov ecx, dword [rax]
mov dword [rbp - 0x20], ecx
mov dword [rbp - 0x1c], ecx
mov rax, qword [rbp - 0x20]
mov qword [r13], rax
bt r14, 0xb
jae 0x14006ac17
mov r9d, 0x800
mov r8, rdi
lea rdx, [rbp - 0x28]
call fcn.14006aea0
nop
mov rbx, 0xffffffffffffffff
mov r9, rbx
mov r8, rax
mov rdx, r12
mov rcx, r13
call fcn.14006b110
nop
mov rcx, qword [rbp - 0x28]
add rcx, 0xfffffffffffffff0
lea rax, [0x140592ec8]
cmp rcx, rax
je 0x14006abd1
mov eax, ebx
lock xadd dword [rcx], eax
dec eax
cmp eax, ebx
jne 0x14006abd1
call fcn.1400c9d7c
mov qword [rbp - 0x20], 0xffffffffffffffff
mov rax, qword [rbp - 0x20]
mov qword [r13], rax
mov byte [r13 + 8], 0
mov rax, qword [r12]
xorps xmm0, xmm0
movups xmmword [rbp - 0x10], xmm0
xor esi, esi
mov qword [rbp - 0x10], rsi
mov qword [rbp - 8], rsi
lea rdx, [rbp - 0x10]
mov rcx, r12
call qword [rax + 0x20]
nop
mov dword [rbp - 4], esi
mov rcx, qword [rbp - 0x10]
call fcn.1400d4bdc
jmp 0x14006ae6c
test r14b, 8
je 0x14006ae6c
xor esi, esi
mov ebx, esi
mov r15d, esi
test r14b, 0x10
je 0x14006acb8
xor r9d, r9d
xor r8d, r8d
lea edx, [rsi + 0x10]
mov rcx, rdi
call qword [sym.imp.IMM32.dll_ImmGetCompositionStringW]
mov dword [rbp - 0x30], eax
test eax, eax
jle 0x14006acb8
movsxd r14, eax
mov rcx, r14
call fcn.1400de56c
mov rdi, rax
mov r9d, dword [rbp - 0x30]
mov r8, rax
lea edx, [rsi + 0x10]
mov rcx, qword [rbp - 0x28]
call qword [sym.imp.IMM32.dll_ImmGetCompositionStringW]
test r14, r14
jle 0x14006ac88
mov ecx, esi
movzx eax, byte [rcx + rdi]
dec al
test al, 0xfd
je 0x14006ac88
inc ebx
inc rcx
cmp rcx, r14
jl 0x14006ac74
mov r15d, ebx
movsxd rdx, ebx
cmp rdx, r14
jge 0x14006aca8
movzx eax, byte [rdx + rdi]
dec al
test al, 0xfd
jne 0x14006aca8
inc r15d
inc rdx
cmp rdx, r14
jl 0x14006ac93
mov rcx, rdi
call fcn.1400d4bdc
mov rdi, qword [rbp - 0x28]
mov r14, qword [rbp + 0x58]
mov r8d, ebx
cmp ebx, r15d
cmovl r8d, r15d
mov ecx, dword [r13]
lea eax, [r8 + rcx]
lea edx, [rcx + rbx]
cmp edx, eax
cmovl ebx, r8d
add ebx, ecx
shl rbx, 0x20
mov eax, edx
or rbx, rax
mov r9d, 8
mov r8, rdi
lea rdx, [rbp - 0x18]
call fcn.14006aea0
nop
mov r9, rbx
mov r8, rax
mov rdx, r12
mov rcx, r13
call fcn.14006b110
nop
mov rcx, qword [rbp - 0x18]
add rcx, 0xfffffffffffffff0
lea rax, [0x140592ec8]
cmp rcx, rax
je 0x14006ad2e
mov rbx, 0xffffffffffffffff
lock xadd dword [rcx], ebx
dec ebx
cmp ebx, 0xffffffff
jne 0x14006ad2e
call fcn.1400c9d7c
mov rax, qword [r12]
mov rcx, qword [rax + 0x20]
mov qword [rbp - 0x18], rcx
mov qword [rbp - 0x10], rsi
mov qword [rbp - 8], rsi
test r14b, 0x20
je 0x14006ae50
xor r9d, r9d
xor r8d, r8d
lea edx, [r9 + 0x20]
mov rcx, rdi
call qword [sym.imp.IMM32.dll_ImmGetCompositionStringW]
movsxd rbx, eax
test eax, eax
jle 0x14006ae50
mov r14, rbx
shr r14, 2
lea rcx, [r14*4]
test rcx, rcx
jne 0x14006ad83
mov r15, rsi
jmp 0x14006ad8b
call fcn.1400de56c
mov r15, rax
mov qword [rbp - 0x20], r15
mov r9d, ebx
mov r8, r15
mov edx, 0x20
mov rcx, rdi
call qword [sym.imp.IMM32.dll_ImmGetCompositionStringW]
test eax, eax
jle 0x14006ae47
cmp r14, 1
jbe 0x14006ae47
mov edi, 1
mov rbx, r15
nop dword [rax]
lea r15, [rbx + 4]
mov ebx, dword [rbx]
mov edx, ebx
cmp ebx, dword [r15]
cmovl edx, dword [r15]
mov ecx, dword [r13]
lea eax, [rdx + rcx]
lea r8d, [rcx + rbx]
mov dword [rbp - 0x30], r8d
cmp r8d, eax
cmovl ebx, edx
add ebx, ecx
mov edx, dword [rbp - 4]
lea ecx, [rdx + 1]
cmp ecx, dword [rbp - 8]
jle 0x14006ae14
mov eax, ecx
test ecx, ecx
jns 0x14006adfa
lea eax, [rcx + 1]
sar eax, 1
lea edx, [rcx + 8]
add edx, eax
and edx, 0xfffffff8
lea rcx, [rbp - 0x10]
call fcn.140017ea0
mov edx, dword [rbp - 4]
mov r8d, dword [rbp - 0x30]
lea eax, [rdx + 1]
mov dword [rbp - 4], eax
movsxd rcx, edx
mov rax, qword [rbp - 0x10]
lea rdx, [rax + rcx*8]
mov ecx, ebx
shl rcx, 0x20
mov eax, r8d
or rcx, rax
mov qword [rdx], rcx
mov rbx, r15
inc rdi
cmp rdi, r14
jb 0x14006adc0
mov rdi, qword [rbp - 0x28]
mov r15, qword [rbp - 0x20]
mov rcx, r15
call fcn.1400d4bdc
nop
lea rdx, [rbp - 0x10]
mov rcx, r12
call qword [rbp - 0x18]
nop
mov dword [rbp - 4], esi
mov rcx, qword [rbp - 0x10]
call fcn.1400d4bdc
mov byte [r13 + 8], 1
mov r9, r12
mov r8, qword [rbp + 0x48]
mov rdx, rdi
call fcn.14006b1e0
mov rdx, rdi
mov rcx, qword [rbp + 0x50]
call qword [sym.imp.IMM32.dll_ImmReleaseContext]
mov rbx, qword [rsp + 0x90]
add rsp, 0x50
pop r15
pop r14
pop r13
pop r12
pop rdi
pop rsi
pop rbp
ret