Function at 0x434060
Capabilities:
Get keyboard layout

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
mov eax, 0x851c
call fcn.00494440
mov eax, dword [0x4c1e68]
push ebx
push esi
push edi
xor edi, edi
mov dword [esp + 0x20], eax
cmp eax, edi
jne 0x4340ad
cmp dword [0x4c3fe8], 1
mov edx, dword [ebp + 8]
sete al
test al, al
sete al
movzx ecx, al
push ecx
push edx
mov dword [0x4c3fe8], edi
call fcn.0042f250
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 4
mov eax, dword [0x4c1e1c]
mov esi, dword [0x4c1e24]
mov ebx, dword [0x4c1e20]
push 0xff
lea ecx, [esp + 0x22d]
push edi
push ecx
mov dword [esp + 0x20], eax
mov dword [esp + 0x24], esi
mov dword [0x4c3fe8], edi
mov byte [esp + 0x234], 0
call fcn.00491b20
add esp, 0xc
push 0x1ff
lea edx, [esp + 0x32d]
push edi
push edx
mov byte [esp + 0x334], 0
call fcn.00491b20
xor eax, eax
add esp, 0xc
mov word [esp + 0x12], ax
cmp word [ebx], di
je 0x43424a
xor ecx, ecx
mov word [esp + 0x10], cx
movzx ecx, word [ebx]
mov eax, ecx
sub eax, 0x7b
je 0x43415f
sub eax, 2
je 0x434239
push 0
mov word [esp + 0x14], cx
mov byte [esp + 0x12], 0
call dword [sym.imp.USER32.dll_GetKeyboardLayout]
push 1
mov ecx, eax
push 1
lea edx, [esp + 0x16]
lea eax, [esp + 0x18]
call fcn.00411b60
add esp, 8
jmp 0x4341fd
lea eax, [ebx + 2]
push 0x7d
push eax
mov dword [esp + 0x2c], eax
call fcn.00489be1
mov edi, eax
add esp, 8
test edi, edi
je 0x434239
mov esi, edi
sub esi, ebx
sar esi, 1
dec esi
jne 0x434197
cmp word [edi + 2], 0x7d
jne 0x434239
add edi, 2
mov esi, 1
xor edx, edx
push edx
mov word [edi], dx
mov byte [esp + 0x12], dl
call dword [sym.imp.USER32.dll_GetKeyboardLayout]
mov ebx, dword [esp + 0x24]
push 1
mov ecx, eax
push 1
lea edx, [esp + 0x16]
mov eax, ebx
call fcn.00411b60
add esp, 8
mov byte [esp + 0xf], al
test al, al
je 0x4341d6
cmp esi, 1
jne 0x4341ef
mov ax, word [ebx]
mov word [esp + 0x10], ax
jmp 0x4341ef
mov eax, ebx
call fcn.00411ac0
movzx eax, ax
test ax, ax
je 0x4341ef
mov ecx, eax
mov byte [esp + ecx + 0x328], 1
mov al, byte [esp + 0xf]
mov edx, 0x7d
mov word [edi], dx
mov ebx, edi
test al, al
je 0x434239
movzx esi, al
or byte [esp + esi + 0x228], 1
cmp word [esp + 0x10], 0
lea esi, [esp + esi + 0x228]
je 0x434239
mov eax, dword [esp + 0x10]
push eax
call dword [sym.imp.USER32.dll_IsCharAlphaW]
test eax, eax
jne 0x434239
test byte [esp + 0xe], 0x30
je 0x434236
or byte [esi], 2
jmp 0x434239
or byte [esi], 4
add ebx, 2
cmp word [ebx], 0
jne 0x434118
mov esi, dword [esp + 0x18]
mov dword [0x4c4000], 0
cmp word [esi], 0
je 0x43440a
cmp dword [0x4c3ffc], 0
jne 0x4342a4
push 0x1000
call fcn.00488ea4
add esp, 4
mov dword [0x4c3ffc], eax
test eax, eax
jne 0x43429a
mov ecx, dword [ebp + 8]
push 0x4a6b2c
push 0
push str.Out_of_memory.
call fcn.0042f490
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 4
mov dword [0x4c4004], 0x400
mov ebx, dword [ebp + 8]
mov edi, 3
mov ecx, ebx
call fcn.004202e0
inc eax
cmp eax, dword [0x4c400c]
jbe 0x43431f
mov dword [0x4c400c], eax
cmp eax, 0x1000
ja 0x4342d2
mov dword [0x4c400c], 0x1000
mov eax, dword [0x4c4008]
test eax, eax
je 0x4342e4
push eax
call fcn.0048a46f
add esp, 4
mov ecx, dword [0x4c400c]
lea edx, [ecx + ecx]
push edx
call fcn.00488ea4
add esp, 4
mov dword [0x4c4008], eax
test eax, eax
jne 0x434324
push 0x4a6b2c
push eax
push str.Out_of_memory.
mov ecx, ebx
mov dword [0x4c400c], eax
call fcn.0042f490
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 4
mov eax, dword [0x4c4008]
mov ecx, dword [0x4c4000]
mov edx, dword [0x4c3ffc]
mov dword [edx + ecx*4], eax
cmp word [esi], 0
mov edi, dword [0x4c4008]
mov ebx, esi
je 0x4343ea
movzx eax, word [ebx]
cmp eax, 0x2c
je 0x434358
mov word [edi], ax
add edi, 2
jmp 0x4343dd
cmp word [ebx + 2], 0x2c
jne 0x43436f
mov eax, 0x2c
mov word [edi], ax
add edi, 2
add ebx, 2
jmp 0x4343dd
xor ecx, ecx
mov word [edi], cx
mov ecx, dword [0x4c3ffc]
mov eax, dword [0x4c4000]
mov edx, dword [ecx + eax*4]
cmp word [edx], 0
je 0x4343a4
inc eax
mov dword [0x4c4000], eax
add edi, 2
mov dword [ecx + eax*4], edi
xor eax, eax
mov word [edi], ax
mov eax, dword [0x4c4000]
mov ecx, dword [0x4c3ffc]
cmp word [ebx + 2], 0
je 0x4343dd
mov edx, dword [0x4c4004]
cmp eax, edx
jb 0x4343dd
lea edx, [edx*4 + 0x1000]
push edx
push ecx
call fcn.0048a0c7
add esp, 8
test eax, eax
je 0x43427d
add dword [0x4c4004], 0x400
mov dword [0x4c3ffc], eax
add ebx, 2
cmp word [ebx], 0
jne 0x434345
xor eax, eax
mov word [edi], ax
mov ecx, dword [0x4c3ffc]
mov edx, dword [0x4c4000]
mov eax, dword [ecx + edx*4]
cmp word [eax], 0
je 0x43440a
inc dword [0x4c4000]
cmp byte [0x4c201c], 0
je 0x434448
mov ecx, dword [0x4c1ec8]
push 0xc
push ecx
call dword [sym.imp.USER32.dll_KillTimer]
test eax, eax
je 0x43442d
mov byte [0x4c201c], 0
push 0x10
call dword [sym.imp.USER32.dll_GetQueueStatus]
shr eax, 0x10
test al, 0x10
je 0x434448
push 1
push 0xffffffffffffffff
call fcn.004012b0
add esp, 8
push 0x7ffe
xor esi, esi
lea eax, [esp + 0x52e]
xor edx, edx
push esi
push eax
mov dword [0x4c4010], 1
mov word [0x4c4014], 0
mov word [esp + 0x534], dx
call fcn.00491b20
mov edx, dword [esp + 0x20]
lea ecx, [esp + 0x534]
add esp, 0xc
mov dword [0x4c4018], ecx
mov dword [0x4c401c], esi
mov dword [0x4c4020], 0x3fff
cmp word [edx], si
je 0x4345a2
mov ebx, edx
add ebx, 2
lea esp, [esp]
movzx edi, word [ebx - 2]
test edi, 0xffffff80
jne 0x4344ce
push 2
push edi
call fcn.0048a05e
add esp, 8
test eax, eax
je 0x4344ce
and edi, 0xffffffdf
movzx eax, di
add eax, 0xffffffd6
cmp eax, 0x2c
ja case.0x4344e4.43
movzx eax, byte [eax + 0x4348ac]
jmp dword [eax*4 + 0x434888]
mov byte [0x4c4010], 0
jmp case.0x4344e4.43
mov byte [0x4c4011], 1
jmp case.0x4344e4.43
mov byte [0x4c4012], 1
jmp case.0x4344e4.43
mov byte [0x4c4013], 1
jmp case.0x4344e4.43
push ebx
call fcn.0048a0a6
add esp, 4
mov dword [0x4c4020], eax
cmp eax, 0x3fff
jle case.0x4344e4.43
mov dword [0x4c4020], 0x3fff
jmp case.0x4344e4.43
mov eax, ebx
call fcn.0040cb80
test al, al
je 0x43456c
push 0x10
push 0
push ebx
call fcn.0048a7d7
mov dword [esp + 0x24], eax
mov dword [esp + 0x28], edx
fild qword [esp + 0x24]
add esp, 0xc
fmul qword [0x4b8d40]
call fcn.00497570
mov esi, eax
jmp case.0x4344e4.43
push ebx
call fcn.0048a8b6
fmul qword [0x4b8d40]
add esp, 4
call fcn.00497570
mov esi, eax
jmp case.0x4344e4.43
mov byte [0x4c4014], 1
jmp case.0x4344e4.43
mov byte [0x4c4015], 1
add ebx, 2
cmp word [ebx - 2], 0
jne 0x4344b0
or byte [0x4c28dd], 1
cmp dword [0x4c1ff8], 0
lea ecx, [esp + 0x228]
lea edx, [esp + 0x328]
mov dword [0x4c3fec], ecx
mov dword [0x4c3ff0], edx
mov dword [0x4c3fe8], 1
mov byte [0x4c1feb], 1
jne 0x4345ee
mov eax, dword [0x4bf634]
movzx ecx, word [eax]
push ecx
call fcn.00407bd0
add esp, 4
test esi, esi
jle 0x434630
cmp byte [0x4c201c], 0
jne 0x434630
mov eax, 0xa
cmp esi, 0xa
jl 0x434607
mov eax, esi
mov edx, dword [0x4c1ec8]
push 0x403360
push eax
push 0xc
push edx
call dword [sym.imp.USER32.dll_SetTimer]
test eax, eax
setne al
mov byte [0x4c201c], al
jmp 0x434630
push 1
push 0x8000012f
call fcn.004012b0
mov eax, dword [0x4c3fe8]
add esp, 8
cmp eax, 1
je 0x434630
add eax, 0xfffffffe
cmp eax, 3
ja case.default.0x434655
jmp dword [eax*4 + 0x4348dc]
push 1
push 0
push 0xffffffffffffffff
push str.Timeout
jmp 0x434813
push 1
push 0
push 0xffffffffffffffff
push str.Match
jmp 0x434813
mov edx, dword [0x4a54e4]
mov ecx, dword [str.EndKey:]
mov eax, dword [0x4a54e8]
push 0xf0
mov dword [esp + 0x30], edx
mov dword [esp + 0x2c], ecx
mov ecx, dword [0x4a54ec]
lea edx, [esp + 0x3c]
push 0
push edx
mov dword [esp + 0x3c], eax
mov dword [esp + 0x40], ecx
call fcn.00491b20
add esp, 0xc
cmp byte [0x4c3ff9], 0
je 0x43475f
push 0xff
lea eax, [esp + 0x12d]
push 0
push eax
mov byte [esp + 0x134], 0
call fcn.00491b20
or byte [esp + 0x144], 0x80
add esp, 0xc
call dword [sym.imp.USER32.dll_GetForegroundWindow]
test eax, eax
je 0x434700
push 0
push eax
call dword [sym.imp.USER32.dll_GetWindowThreadProcessId]
jmp 0x434702
xor eax, eax
push eax
call dword [sym.imp.USER32.dll_GetKeyboardLayout]
xor ecx, ecx
cmp dword [0x4c2054], ecx
push eax
setne cl
lea edx, [esp + 0x3a]
lea eax, [esp + 0x12c]
xor bl, bl
push ecx
movzx ecx, byte [0x4c3ff4]
push 2
push edx
push eax
push ecx
call fcn.00411fc0
movzx edx, ax
movzx eax, byte [0x4c3ff4]
add esp, 4
push edx
push eax
call dword [sym.imp.USER32.dll_ToUnicodeEx]
push 1
xor ecx, ecx
push ecx
mov word [esp + eax*2 + 0x3e], cx
push 0xffffffffffffffff
lea eax, [esp + 0x34]
push eax
jmp 0x434813
cmp byte [0x4c3ff8], 0
je 0x4347d5
mov cx, word [0x4c3ff6]
xor eax, eax
cmp word [eax*8 + 0x4bf5cc], cx
je 0x4347a8
inc eax
cmp eax, 0xd
jl 0x434771
movzx edx, cx
push edx
push str.sc_03X
mov esi, 0x79
lea edi, [esp + 0x3e]
call fcn.004700a0
add esp, 8
push 1
push 0
push 0xffffffffffffffff
lea eax, [esp + 0x34]
push eax
jmp 0x434813
mov edx, dword [eax*8 + 0x4bf5c8]
push 0x78
push edx
lea eax, [esp + 0x3e]
push eax
call fcn.0048b9c4
add esp, 0xc
push 1
xor ecx, ecx
push ecx
push 0xffffffffffffffff
lea eax, [esp + 0x34]
mov word [esp + 0x132], cx
push eax
jmp 0x434813
mov bl, byte [0x4c3ff4]
push 1
mov eax, 0x79
lea ecx, [esp + 0x3a]
call fcn.00411a30
add esp, 4
push 1
push 0
push 0xffffffffffffffff
lea eax, [esp + 0x34]
push eax
jmp 0x434813
push 1
push 0
push 0xffffffffffffffff
push 0x4a54f0
jmp 0x434813
push 1
push 0
push 0xffffffffffffffff
push str.NewInput
mov ecx, dword [0x4c26cc]
call fcn.00472b80
cmp byte [0x4c201c], 0
mov dword [0x4c3fe8], 0
je 0x434866
mov ecx, dword [0x4c1ec8]
push 0xc
push ecx
call dword [sym.imp.USER32.dll_KillTimer]
test eax, eax
je 0x43484b
mov byte [0x4c201c], 0
push 0x10
call dword [sym.imp.USER32.dll_GetQueueStatus]
shr eax, 0x10
test al, 0x10
je 0x434866
push 1
push 0xffffffffffffffff
call fcn.004012b0
add esp, 8
mov ecx, dword [esp + 0x20]
push 1
push 0
push 0xffffffffffffffff
lea edx, [esp + 0x534]
push edx
call fcn.00472b80
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 4