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

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x24
push ebx
push esi
push dword [ebp + 8]
call sub.IMM32.dll_ImmGetContext
mov esi, eax
xor ebx, ebx
cmp esi, ebx
mov dword [ebp - 0xc], esi
je 0x1005382
mov ecx, dword [ebp + 0x10]
mov dword [ebp - 0x10], ecx
and dword [ebp - 0x10], 8
je 0x100519d
push ebx
push ebx
push 8
push esi
call sub.IMM32.dll_ImmGetCompositionStringW
cmp eax, ebx
mov dword [ebp - 4], eax
jl 0x10051b6
test byte [ebp + 0x10], 0x10
je 0x1005198
push ebx
push ebx
push 0x10
push esi
call sub.IMM32.dll_ImmGetCompositionStringW
cmp eax, ebx
mov dword [ebp - 8], eax
jge 0x10051d2
jmp 0x10051cf
mov dword [ebp - 8], eax
jmp 0x10051d2
mov eax, 0x800
test eax, ecx
je 0x10051c4
push ebx
push ebx
push eax
push esi
call sub.IMM32.dll_ImmGetCompositionStringW
cmp eax, ebx
mov dword [ebp - 4], eax
jge 0x10051cf
push esi
push dword [ebp + 8]
call sub.IMM32.dll_ImmReleaseContext
jmp 0x1005382
cmp ecx, ebx
jne 0x1005382
mov dword [ebp - 4], ebx
mov dword [ebp - 8], ebx
mov eax, dword [ebp - 8]
mov ecx, dword [ebp - 4]
mov esi, dword [ebp + 0xc]
push edi
lea edi, [eax + ecx + 0x2f]
mov eax, dword [esi + 0x240]
cmp eax, ebx
je 0x10051fb
cmp edi, dword [eax]
jbe 0x10051fb
push eax
call dword [sym.imp.KERNEL32.dll_LocalFree]
mov dword [esi + 0x240], ebx
cmp dword [esi + 0x240], ebx
jne 0x100521c
push edi
push 0x40
call dword [sym.imp.KERNEL32.dll_LocalAlloc]
cmp eax, ebx
mov dword [esi + 0x240], eax
je 0x1005376
mov dword [eax], edi
mov ebx, dword [esi + 0x240]
mov ecx, dword [ebx]
sub ecx, 4
mov edx, ecx
shr ecx, 2
lea edi, [ebx + 4]
mov dword [ebp - 0x18], edi
xor eax, eax
rep stosd dword es:[edi], eax
mov ecx, edx
and ecx, 3
rep stosb byte es:[edi], al
mov ecx, dword [ebp - 4]
add esi, 0x244
test byte [ebp + 0x11], 0x20
lea edi, [ebx + 0x1c]
movsd dword es:[edi], dword [esi]
movsd dword es:[edi], dword [esi]
movsd dword es:[edi], dword [esi]
movsd dword es:[edi], dword [esi]
mov dword [ebp - 0x24], 0x4b425930
mov edx, dword [ebx]
lea ecx, [ebx + ecx + 0x2e]
lea eax, [ebx + 0x2c]
mov dword [ebp - 0x14], ecx
mov dword [ebp - 0x20], edx
mov dword [ebp - 0x1c], ebx
je 0x100528c
mov dx, word [ebp + 0x14]
mov word [eax], dx
mov edx, dword [ebp - 4]
shr edx, 1
and word [eax + edx*2], 0
mov eax, dword [ebp - 8]
mov byte [ecx], 1
mov byte [ecx + eax], 0
jmp 0x1005364
xor esi, esi
cmp dword [ebp - 0x10], esi
je 0x100530e
mov edi, dword [ebp - 4]
push edi
push eax
push 8
push dword [ebp - 0xc]
call sub.IMM32.dll_ImmGetCompositionStringW
mov ecx, edi
shr ecx, 1
lea eax, [ebx + 0x2c]
mov word [eax + ecx*2], si
mov esi, dword [ebp - 8]
test esi, esi
je 0x10052f1
test byte [ebp + 0x10], 0x10
je 0x10052d1
push esi
push dword [ebp - 0x14]
push 0x10
push dword [ebp - 0xc]
call sub.IMM32.dll_ImmGetCompositionStringW
mov eax, dword [ebp - 0x14]
mov byte [eax + esi], 0
jmp 0x10052f1
test esi, esi
jl 0x10052f1
mov edi, dword [ebp - 0x14]
lea ecx, [esi + 1]
mov edx, ecx
shr ecx, 2
mov eax, 0x1010101
rep stosd dword es:[edi], eax
mov ecx, edx
and ecx, 3
rep stosb byte es:[edi], al
mov edi, dword [ebp - 4]
test edi, edi
mov dword [ebx + 0xc], edi
je 0x10052ff
mov dword [ebx + 0x10], 0x2c
test esi, esi
mov dword [ebx + 4], esi
je 0x1005364
add edi, 0x2e
mov dword [ebx + 8], edi
jmp 0x1005364
mov edx, 0x800
test dword [ebp + 0x10], edx
je 0x1005342
mov edi, dword [ebp - 4]
push edi
push eax
push edx
push dword [ebp - 0xc]
call sub.IMM32.dll_ImmGetCompositionStringW
mov ecx, edi
shr ecx, 1
lea eax, [ebx + 0x2c]
and word [eax + ecx*2], 0
test edi, edi
mov dword [ebx + 0x14], edi
je 0x1005364
mov dword [ebx + 0x18], 0x2c
jmp 0x1005364
cmp dword [ebp + 0x10], esi
jne 0x1005364
mov edx, dword [ebp - 4]
mov edi, edx
shr edi, 1
mov word [eax + edi*2], si
mov eax, dword [ebp - 8]
mov byte [ecx + eax], 0
mov ecx, dword [ebp - 0x18]
mov dword [ebx + 0x14], edx
mov dword [ebx + 0xc], edx
mov dword [ecx], eax
lea eax, [ebp - 0x24]
push eax
push dword [ebp + 8]
mov eax, dword [ebp + 0xc]
push dword [eax + 4]
call fcn.01001981
push dword [ebp - 0xc]
push dword [ebp + 8]
call sub.IMM32.dll_ImmReleaseContext
pop edi
pop esi
pop ebx
leave
ret 0x10