Function at 0x40c0c0
Capabilities:
Get keyboard layout

Disassembly:
sub esp, 0x210
push ebx
push ebp
push esi
mov esi, dword [esp + 0x224]
xor ebp, ebp
mov dword [esp + 0x14], edx
mov byte [esp + 0xf], 0
push edi
lea eax, [esi + 0x12]
mov edi, ecx
test esi, esi
jne 0x40c0e9
lea eax, [esp + 0x1f]
cmp byte [esp + 0x224], 0
mov dword [esp + 0x14], eax
jne 0x40c13c
mov edx, 0x49e8b4
call fcn.00409840
mov ebx, eax
test ebx, ebx
je 0x40c13c
mov ecx, ebx
lea esp, [esp]
mov dl, byte [ecx]
cmp dl, 0x20
je 0x40c11c
cmp dl, 9
jne 0x40c11f
inc ecx
jmp 0x40c110
push 0x49cdac
push ecx
call fcn.00484212
add esp, 8
test eax, eax
jne 0x40c13c
test esi, esi
je 0x40c139
mov byte [esi + 0x16], 1
mov byte [ebx], 0
push 0
call dword [sym.imp.USER32.dll_GetKeyboardLayout]
push eax
push ecx
push 1
lea edx, [esp + 0x1f]
mov ecx, edi
call fcn.00412340
mov bl, al
add esp, 0xc
test bl, bl
je 0x40c243
cmp byte [esp + 0x224], 0
je 0x40c1e4
lea ecx, [ebx + 0x64]
cmp cl, 3
ja 0x40c200
cmp byte [esp + 0x22c], 0
je 0x40c1a3
mov ecx, dword [0x4ad0c8]
push 1
push 0
push 0xffffffffffffffff
push 0x49e8b8
call fcn.004744e0
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
add esp, 0x210
ret
push edi
push str.__s__is_not_allowed_as_a_prefix_key.
lea eax, [esp + 0x28]
push 0x200
push eax
call fcn.004715d0
add esp, 0x10
lea eax, [esp + 0x20]
mov ecx, 0x4ae9b0
push dword [esp + 0x18]
push eax
call fcn.0042ce80
test esi, esi
jne 0x40c292
pop edi
lea eax, [esi + 4]
pop esi
pop ebp
pop ebx
add esp, 0x210
ret
test esi, esi
je 0x40c200
push 2
push 0x49e8e4
push edi
call fcn.00484c8d
add esp, 0xc
test eax, eax
sete al
mov byte [esi + 0x17], al
mov al, bl
dec al
cmp al, 5
ja 0x40c20d
cmp bl, 3
jne 0x40c215
mov al, bl
add al, 0x66
cmp al, 5
ja 0x40c219
mov dl, 1
jmp 0x40c21b
xor dl, dl
mov cl, byte [esp + 0x13]
test cl, 0x30
je 0x40c22f
mov al, bl
sub al, 0x41
cmp al, 0x19
ja 0x40c22f
and cl, 0xcf
test dl, dl
je 0x40c31e
mov eax, dword [esp + 0x14]
mov byte [eax], 2
jmp 0x40c31e
mov ecx, edi
call fcn.00412290
movzx ebp, ax
test bp, bp
jne 0x40c31a
push 1
lea edx, [esp + 0x1c]
mov ecx, edi
call fcn.0044c1b0
movzx ebp, ax
add esp, 4
test bp, bp
jne 0x40c302
cmp byte [esp + 0x22c], 0
je 0x40c29f
mov ecx, dword [0x4ad0c8]
push 1
push 0
push 0xffffffffffffffff
push 0x49e8e8
call fcn.004744e0
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
add esp, 0x210
ret
cmp byte [edi + 1], 0
jne 0x40c2c5
cmp byte [0x4aefc4], 0
jne 0x40c2c5
pop edi
xor eax, eax
mov ecx, 3
test esi, esi
pop esi
pop ebp
cmove eax, ecx
pop ebx
add esp, 0x210
ret
test esi, esi
je 0x40c292
push edi
push str.__s__is_not_a_valid_key_name.
lea eax, [esp + 0x28]
push 0x200
push eax
call fcn.004715d0
add esp, 0x10
lea eax, [esp + 0x20]
mov ecx, 0x4ae9b0
push 0x49bc4d
push eax
call fcn.0042ce80
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
add esp, 0x210
ret
mov eax, dword [esp + 0x14]
mov ebx, dword [esp + 0x18]
inc dword [0x4adb48]
mov byte [eax], 4
mov byte [ebx + 0x4adb30], 1
mov cl, byte [esp + 0x13]
cmp byte [esp + 0x224], 0
je 0x40c343
test esi, esi
je 0x40c380
pop edi
mov byte [esi + 0x11], bl
mov eax, 1
mov word [esi + 0xa], bp
pop esi
pop ebp
pop ebx
add esp, 0x210
ret
test esi, esi
je 0x40c380
mov dl, cl
mov byte [esi + 0x10], bl
and dl, 0xd5
mov word [esi + 8], bp
xor eax, eax
mov edi, 8
test dl, 0xc0
cmovne eax, edi
test dl, 0xc
je 0x40c368
or eax, 1
test dl, 0x30
je 0x40c370
or eax, 4
test dl, 3
je 0x40c378
or eax, 2
or dword [esi], eax
and cl, 0x2a
or byte [esi + 0xe], cl
pop edi
pop esi
pop ebp
mov eax, 1
pop ebx
add esp, 0x210
ret