Function at 0x4399c0
Capabilities:
Get keyboard layout

Disassembly:
push ebp
mov ebp, esp
mov eax, 0x855c
call fcn.004ab360
mov eax, dword [0x4ddf18]
mov dword [ebp - 0x14], ecx
mov dword [ebp - 0x28], eax
push ebx
push esi
push edi
test eax, eax
jne 0x439a0b
cmp dword [0x4de090], 1
mov dword [0x4de090], 0
sete al
xor al, 1
movzx eax, al
push eax
call fcn.00434f60
lea esp, [ebp - 0x8568]
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
mov eax, dword [0x4ddf74]
mov ebx, dword [0x4ddf6c]
mov edi, dword [0x4ddf70]
mov dword [ebp - 0x24], eax
xor eax, eax
mov dword [0x4de090], 0
mov dword [0x4de0bc], 1
mov word [0x4de0c0], 0
mov dword [0x4de0cc], 0x3fff
mov dword [ebp - 0x1c], eax
mov byte [ebp - 2], al
movzx eax, word [ebx]
mov dword [ebp - 0x20], edi
test ax, ax
je 0x439b27
lea ecx, [ebx + 2]
mov dword [ebp - 8], ecx
movzx esi, ax
test esi, 0xffffff80
jne 0x439a80
push 2
push esi
call fcn.00498ea3
add esp, 8
test eax, eax
je 0x439a80
and esi, 0xffffffdf
movzx eax, si
add eax, 0xffffffd6
cmp eax, 0x2c
ja case.0x439a96.43
movzx eax, byte [eax + 0x43a320]
jmp dword [eax*4 + 0x43a2f8]
mov byte [0x4de0bc], 0
jmp case.0x439a96.43
mov byte [0x4de0bd], 1
jmp case.0x439a96.43
mov byte [0x4de0be], 1
jmp case.0x439a96.43
mov byte [0x4de0bf], 1
jmp case.0x439a96.43
push dword [ebp - 8]
call fcn.00495cca
add esp, 4
mov dword [0x4de0cc], eax
cmp eax, 0x3fff
jle case.0x439a96.43
mov dword [0x4de0cc], 0x3fff
jmp case.0x439a96.43
mov ecx, dword [ebp - 8]
call fcn.00417e30
mulsd xmm0, qword [0x4d3108]
cvttsd2si eax, xmm0
mov dword [ebp - 0x1c], eax
jmp case.0x439a96.43
mov byte [0x4de0c0], 1
jmp case.0x439a96.43
mov byte [0x4de0c1], 1
jmp case.0x439a96.43
mov byte [ebp - 2], 1
movzx eax, word [ebx + 2]
add ebx, 2
add dword [ebp - 8], 2
test ax, ax
jne 0x439a63
push 0x100
lea eax, [ebp - 0x25c]
push 0
push eax
call fcn.00493930
push 0x200
lea eax, [ebp - 0x55c]
push 0
push eax
call fcn.00493930
xor eax, eax
xor edx, edx
add esp, 0x18
mov word [ebp - 0xe], ax
mov ebx, edi
mov dword [ebp - 8], edx
cmp word [edi], ax
je 0x439bef
lea edi, [edx + 0x7d]
nop dword [eax]
xor eax, eax
mov word [ebp - 0x10], ax
movzx ecx, word [ebx]
mov eax, ecx
sub eax, 0x7b
je 0x439bb8
sub eax, 2
je 0x439be3
cmp byte [ebp - 2], 0
je 0x439b91
inc edx
mov dword [ebp - 8], edx
jmp 0x439be3
push 0
mov word [ebp - 0x10], cx
mov byte [ebp - 1], 0
call dword [sym.imp.USER32.dll_GetKeyboardLayout]
push eax
push ecx
push 1
lea edx, [ebp - 1]
lea ecx, [ebp - 0x10]
call fcn.00416d70
add esp, 0xc
jmp 0x439cab
lea eax, [ebx + 2]
push 0x7d
push eax
mov dword [ebp - 0x18], eax
call fcn.00492ca4
mov esi, eax
add esp, 8
test esi, esi
je 0x439be0
sub eax, ebx
sar eax, 1
sub eax, 1
jne 0x439c42
add esi, 2
cmp word [esi], di
je 0x439c47
mov edx, dword [ebp - 8]
add ebx, 2
cmp word [ebx], 0
jne 0x439b70
mov edi, dword [ebp - 0x20]
mov dword [0x4de09c], 0x4c602c
test edx, edx
je 0x439d44
lea eax, [edx*2 + 2]
call fcn.004ab330
mov esi, esp
mov dword [0x4de09c], esi
cmp word [edi], 0
je 0x439d3f
nop
movzx ecx, word [edi]
mov eax, ecx
sub eax, 0x7b
je 0x439cfd
sub eax, 2
je 0x439d32
mov word [esi], cx
add esi, 2
jmp 0x439d32
cmp eax, 1
jne 0x439c62
cmp byte [ebp - 2], 0
je 0x439c56
mov edx, dword [ebp - 8]
inc edx
mov dword [ebp - 8], edx
jmp 0x439be3
mov ebx, dword [ebp - 0x18]
mov ax, word [ebx]
mov word [ebp - 0x10], ax
jmp 0x439c65
mov ebx, dword [ebp - 0x18]
xor eax, eax
push eax
mov word [esi], ax
mov byte [ebp - 1], al
call dword [sym.imp.USER32.dll_GetKeyboardLayout]
push eax
push ecx
push 1
lea edx, [ebp - 1]
mov ecx, ebx
call fcn.00416d70
add esp, 0xc
mov byte [ebp - 9], al
test al, al
jne 0x439ca6
mov ecx, ebx
call fcn.00416cc0
movzx eax, ax
test ax, ax
je 0x439ca3
mov byte [ebp + eax - 0x55c], 1
mov al, byte [ebp - 9]
mov word [esi], di
mov ebx, esi
test al, al
je 0x439be0
movzx esi, al
or byte [ebp + esi - 0x25c], 1
cmp word [ebp - 0x10], 0
je 0x439be0
push dword [ebp - 0x10]
call dword [sym.imp.USER32.dll_IsCharAlphaW]
test eax, eax
jne 0x439be0
test byte [ebp - 1], 0x30
mov edx, dword [ebp - 8]
je 0x439cf0
or byte [ebp + esi - 0x25c], 2
jmp 0x439be3
or byte [ebp + esi - 0x25c], 4
jmp 0x439be3
lea ebx, [edi + 2]
push 0x7d
push ebx
call fcn.00492ca4
mov edx, eax
add esp, 8
test edx, edx
je 0x439d32
cmp edx, ebx
jne 0x439d20
cmp word [edx + 2], 0x7d
lea ecx, [edx + 2]
cmove edx, ecx
lea eax, [edi + 4]
cmp edx, eax
jne 0x439d30
mov ax, word [ebx]
mov word [esi], ax
add esi, 2
mov edi, edx
add edi, 2
cmp word [edi], 0
jne 0x439c20
xor eax, eax
mov word [esi], ax
mov ebx, dword [ebp - 0x24]
mov dword [0x4de0ac], 0
cmp word [ebx], 0
je 0x439f0e
cmp dword [0x4de0a8], 0
jne 0x439da5
push 0x1000
call fcn.00495d48
add esp, 4
mov dword [0x4de0a8], eax
test eax, eax
jne 0x439d9b
mov ecx, dword [ebp - 0x14]
push 0x4c602c
push 0
push str.Out_of_memory.
call fcn.004351a0
lea esp, [ebp - 0x8568]
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
mov dword [0x4de0b0], 0x400
mov esi, dword [ebp - 0x14]
mov ecx, esi
push 3
call fcn.00428950
lea ecx, [eax + 1]
cmp ecx, dword [0x4de0b8]
jbe 0x439e1e
mov eax, 0x1000
cmp ecx, eax
cmova eax, ecx
mov ecx, dword [0x4de0b4]
mov dword [0x4de0b8], eax
test ecx, ecx
je 0x439de3
push ecx
call fcn.00495d53
mov eax, dword [0x4de0b8]
add esp, 4
add eax, eax
push eax
call fcn.00495d48
mov edx, eax
add esp, 4
mov dword [0x4de0b4], edx
test edx, edx
jne 0x439e24
push 0x4c602c
push eax
push str.Out_of_memory.
mov ecx, esi
mov dword [0x4de0b8], eax
call fcn.004351a0
lea esp, [ebp - 0x8568]
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
mov edx, dword [0x4de0b4]
mov ecx, dword [0x4de0ac]
mov eax, dword [0x4de0a8]
mov dword [eax + ecx*4], edx
cmp word [ebx], 0
mov esi, dword [0x4de0b4]
je 0x439eee
mov ecx, 0x2c
movzx eax, word [ebx]
cmp eax, 0x2c
je 0x439e5a
mov word [esi], ax
add esi, 2
jmp 0x439ee1
cmp word [ebx + 2], 0x2c
jne 0x439e6c
mov word [esi], cx
add esi, 2
add ebx, 2
jmp 0x439ee1
xor eax, eax
mov word [esi], ax
mov edi, dword [0x4de0a8]
mov ecx, dword [0x4de0ac]
mov eax, dword [edi + ecx*4]
cmp word [eax], 0
je 0x439ea4
inc ecx
add esi, 2
mov dword [0x4de0ac], ecx
xor eax, eax
mov dword [edi + ecx*4], esi
mov word [esi], ax
mov ecx, dword [0x4de0ac]
mov edi, dword [0x4de0a8]
cmp word [ebx + 2], 0
je 0x439edc
mov eax, dword [0x4de0b0]
cmp ecx, eax
jb 0x439edc
lea eax, [eax*4 + 0x1000]
push eax
push edi
call fcn.00495d58
add esp, 8
test eax, eax
je 0x439d7a
add dword [0x4de0b0], 0x400
mov dword [0x4de0a8], eax
mov ecx, 0x2c
add ebx, 2
cmp word [ebx], 0
jne 0x439e47
xor eax, eax
mov word [esi], ax
mov ecx, dword [0x4de0ac]
mov eax, dword [0x4de0a8]
mov eax, dword [eax + ecx*4]
cmp word [eax], 0
je 0x439f0e
inc ecx
mov dword [0x4de0ac], ecx
cmp byte [0x4db43c], 0
mov ebx, dword [sym.imp.USER32.dll_KillTimer]
mov esi, dword [sym.imp.USER32.dll_GetQueueStatus]
je 0x439f59
push 0xc
push dword [0x4db780]
call ebx
movzx ecx, byte [0x4db43c]
xor edx, edx
test eax, eax
push 0x10
cmovne ecx, edx
mov byte [0x4db43c], cl
call esi
shr eax, 0x10
test al, 0x10
je 0x439f59
mov edx, 1
or ecx, 0xffffffff
call fcn.004016e0
or byte [0x4dd212], 1
xor eax, eax
cmp dword [0x4db79c], 0
mov word [ebp - 0x855c], ax
lea eax, [ebp - 0x855c]
mov dword [0x4de0c4], eax
lea eax, [ebp - 0x25c]
mov dword [0x4de094], eax
lea eax, [ebp - 0x55c]
mov dword [0x4de0c8], 0
mov dword [0x4de098], eax
mov dword [0x4de090], 1
mov byte [0x4db791], 1
jne 0x439fc0
movzx edx, word [0x4dd210]
sub esp, 8
call fcn.0040ce30
add esp, 8
mov eax, dword [ebp - 0x1c]
test eax, eax
jle 0x43a000
cmp byte [0x4db43c], 0
jne 0x43a000
mov ecx, 0xa
cmp eax, ecx
push 0x403c90
cmovl eax, ecx
push eax
push 0xc
push dword [0x4db780]
call dword [sym.imp.USER32.dll_SetTimer]
test eax, eax
setne byte [0x4db43c]
nop word [eax + eax]
mov edx, 1
mov ecx, 0x8000012f
call fcn.004016e0
mov eax, dword [0x4de090]
cmp eax, 1
je 0x43a000
add eax, 0xfffffffe
cmp eax, 3
ja case.default.0x43a025
jmp dword [eax*4 + 0x43a350]
push 1
push 0
push 0xffffffffffffffff
push str.Timeout
jmp 0x43a283
push 1
push 0
push 0xffffffffffffffff
push str.Match
jmp 0x43a283
movups xmm0, xmmword [str.EndKey:]
push 0xf0
lea eax, [ebp - 0x11c]
push 0
push eax
movups xmmword [ebp - 0x12c], xmm0
call fcn.00493930
mov ax, word [0x4de0a4]
add esp, 0xc
test ax, ax
je 0x43a090
mov word [ebp - 0x11e], ax
xor eax, eax
mov word [ebp - 0x11c], ax
jmp 0x43a24b
cmp byte [0x4de0a7], 0
je 0x43a157
push 0x100
lea eax, [ebp - 0x35c]
push 0
push eax
call fcn.00493930
or byte [ebp - 0x34c], 0x80
add esp, 0xc
call dword [sym.imp.USER32.dll_GetForegroundWindow]
xor esi, esi
test eax, eax
je 0x43a0ff
mov edi, dword [sym.imp.USER32.dll_GetWindowThreadProcessId]
push esi
push eax
call edi
mov esi, eax
mov dword [ebp - 0x15c], 0x30
lea eax, [ebp - 0x15c]
push eax
push esi
call dword [sym.imp.USER32.dll_GetGUIThreadInfo]
test eax, eax
je 0x43a0ff
mov eax, dword [ebp - 0x150]
test eax, eax
je 0x43a0ff
push 0
push eax
call edi
mov esi, eax
push esi
call dword [sym.imp.USER32.dll_GetKeyboardLayout]
mov cl, byte [0x4de0a0]
push eax
xor eax, eax
cmp dword [0x4db444], eax
setne al
xor dl, dl
push eax
push 2
lea eax, [ebp - 0x11e]
push eax
lea eax, [ebp - 0x35c]
push eax
call fcn.004172e0
movzx eax, ax
push eax
movzx eax, byte [0x4de0a0]
push eax
call dword [sym.imp.USER32.dll_ToUnicodeEx]
mov esi, dword [sym.imp.USER32.dll_GetQueueStatus]
xor ecx, ecx
mov word [ebp + eax*2 - 0x11e], cx
jmp 0x43a24b
xor eax, eax
cmp byte [0x4de0a6], al
je 0x43a1aa
mov cx, word [0x4de0a2]
nop dword [eax + eax]
cmp word [eax*8 + 0x4d89d4], cx
je 0x43a19f
inc eax
cmp eax, 0xd
jl 0x43a170
movzx eax, cx
push eax
push str.sc_03X
lea eax, [ebp - 0x11e]
push 0x79
push eax
call fcn.004782d0
add esp, 0x10
jmp 0x43a226
push 0x78
push dword [eax*8 + 0x4d89d0]
jmp 0x43a211
mov bl, byte [0x4de0a0]
cmp byte [eax*8 + 0x4d8a3c], bl
je 0x43a208
inc eax
cmp eax, 0x6d
jl 0x43a1b0
mov cl, bl
call fcn.00416bb0
mov word [ebp - 0x11e], ax
test ax, ax
je 0x43a1dd
xor eax, eax
mov word [ebp - 0x11c], ax
jmp 0x43a226
test bl, bl
je 0x43a1fd
movzx eax, bl
push eax
push str.vk_02X
lea eax, [ebp - 0x11e]
push 0x79
push eax
call fcn.004782d0
add esp, 0x10
jmp 0x43a226
xor eax, eax
mov word [ebp - 0x11e], ax
jmp 0x43a24b
push 0x78
push dword [eax*8 + 0x4d8a38]
lea eax, [ebp - 0x11e]
push eax
call fcn.0049ef24
add esp, 0xc
xor eax, eax
mov word [ebp - 0x2e], ax
mov eax, dword [ebp - 0x11e]
add eax, 0xffffff9f
cmp ax, 0x19
ja 0x43a24b
cmp word [ebp - 0x11c], 0
jne 0x43a24b
mov eax, 0xffe0
add word [ebp - 0x11e], ax
mov ecx, dword [0x4db768]
lea eax, [ebp - 0x12c]
push 1
push 0
push 0xffffffffffffffff
push eax
call fcn.0047b2f0
mov ebx, dword [sym.imp.USER32.dll_KillTimer]
jmp 0x43a28e
push 1
push 0
push 0xffffffffffffffff
push 0x4cadb4
jmp 0x43a283
push 1
push 0
push 0xffffffffffffffff
push str.NewInput
mov ecx, dword [0x4db768]
call fcn.0047b2f0
cmp byte [0x4db43c], 0
mov dword [0x4de090], 0
je 0x43a2d5
push 0xc
push dword [0x4db780]
call ebx
movzx ecx, byte [0x4db43c]
xor edi, edi
test eax, eax
push 0x10
cmovne ecx, edi
mov byte [0x4db43c], cl
call esi
shr eax, 0x10
test al, 0x10
je 0x43a2d5
lea edx, [edi + 1]
or ecx, 0xffffffff
call fcn.004016e0
mov ecx, dword [ebp - 0x28]
lea eax, [ebp - 0x855c]
push 1
push 0
push 0xffffffffffffffff
push eax
call fcn.0047b2f0
lea esp, [ebp - 0x8568]
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret