Function at 0x415ca0
Capabilities:
Get keyboard layout

Disassembly:
sub esp, 0x210
push ebx
push ebp
push esi
mov esi, dword [esp + 0x224]
mov ebp, ecx
mov byte [esp + 0xf], 0
push edi
mov edi, edx
mov dword [esp + 0x14], edi
lea eax, [esi + 0x12]
test esi, esi
jne 0x415cc9
lea eax, [esp + 0x1b]
cmp byte [esp + 0x224], 0
mov dword [esp + 0x1c], eax
jne 0x415d0f
mov edi, ebp
test ebp, ebp
je 0x415db5
mov dl, byte [ebp]
test dl, dl
je 0x415d0b
nop dword [eax + eax]
mov ecx, 0x4e902c
mov al, 0x20
cmp dl, al
je 0x415d7a
mov al, byte [ecx + 1]
inc ecx
test al, al
jne 0x415cf7
mov dl, byte [edi + 1]
inc edi
test dl, dl
jne 0x415cf0
mov edi, dword [esp + 0x14]
push 0
call dword [sym.imp.USER32.dll_GetKeyboardLayout]
push eax
push ecx
push 1
lea edx, [esp + 0x1f]
mov ecx, ebp
call fcn.0041d8d0
mov bl, al
add esp, 0xc
test bl, bl
je 0x415e63
cmp byte [esp + 0x224], 0
je 0x415dfa
lea ecx, [ebx + 0x64]
cmp cl, 3
ja 0x415e16
cmp byte [esp + 0x22c], 0
je 0x415dbc
mov ecx, dword [0x4fb94c]
push 1
push 0
push 0xffffffffffffffff
push 0x4e9030
call fcn.004b01a0
xor eax, eax
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x210
ret
mov eax, edi
nop dword [eax]
mov cl, byte [eax]
cmp cl, 0x20
je 0x415d8c
cmp cl, 9
jne 0x415d8f
inc eax
jmp 0x415d80
push 0x4e88c8
push eax
call fcn.004c408e
add esp, 8
test eax, eax
jne 0x415d0b
test esi, esi
je 0x415dad
mov byte [esi + 0x16], 1
mov byte [edi], 0
jmp 0x415d0b
mov edi, edx
jmp 0x415d0f
push ebp
push str.__s__is_not_allowed_as_a_prefix_key.
lea eax, [esp + 0x28]
push 0x200
push eax
call fcn.004aba90
add esp, 0x10
lea eax, [esp + 0x20]
mov ecx, 0x4fda88
push edi
push eax
call fcn.0044dd10
test esi, esi
jne 0x415f11
lea eax, [esi + 4]
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x210
ret
test esi, esi
je 0x415e16
push 2
push 0x4e905c
push ebp
call fcn.004c4e4b
add esp, 0xc
test eax, eax
sete al
mov byte [esi + 0x17], al
mov al, bl
dec al
cmp al, 5
ja 0x415e23
cmp bl, 3
jne 0x415e2b
mov al, bl
add al, 0x66
cmp al, 5
ja 0x415e2f
mov dl, 1
jmp 0x415e31
xor dl, dl
mov cl, byte [esp + 0x13]
mov byte [esp + 0x13], cl
test cl, 0x30
je 0x415e4d
mov al, bl
sub al, 0x41
cmp al, 0x19
ja 0x415e4d
and cl, 0xcf
mov byte [esp + 0x13], cl
xor eax, eax
test dl, dl
je 0x415f3e
mov edx, dword [esp + 0x1c]
mov byte [edx], 2
jmp 0x415f3e
xor edx, edx
mov ecx, ebp
call fcn.0041d7e0
movzx eax, ax
test ax, ax
jne 0x415f36
push 1
lea edx, [esp + 0x18]
mov ecx, ebp
call fcn.00477660
movzx eax, ax
add esp, 4
test ax, ax
jne 0x415f1e
cmp byte [esp + 0x22c], al
je 0x415ec0
mov ecx, dword [0x4fb94c]
push 1
push 0
push 0xffffffffffffffff
push 0x4e9060
call fcn.004b01a0
xor eax, eax
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x210
ret
cmp byte [ebp + 1], 0
jne 0x415ee1
cmp byte [0x4fe0b8], 0
jne 0x415ee1
test esi, esi
jne 0x415f11
lea eax, [esi + 3]
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x210
ret
test esi, esi
je 0x415f11
push ebp
push str.__s__is_not_a_valid_key_name.
lea eax, [esp + 0x28]
push 0x200
push eax
call fcn.004aba90
add esp, 0x10
lea eax, [esp + 0x20]
mov ecx, 0x4fda88
push 0x4e3371
push eax
call fcn.0044dd10
xor eax, eax
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x210
ret
mov edx, dword [esp + 0x1c]
mov ebx, dword [esp + 0x14]
inc dword [0x4fc440]
mov byte [edx], 4
mov byte [ebx + 0x4fc428], 1
mov cl, byte [esp + 0x13]
mov byte [esp + 0x13], cl
test esi, esi
je 0x415fab
cmp byte [esp + 0x224], 0
je 0x415f63
mov word [esi + 0xa], ax
mov eax, 1
mov byte [esi + 0x11], bl
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x210
ret
mov word [esi + 8], ax
mov byte [esi + 0x10], bl
mov bl, cl
and bl, 0xd5
mov al, bl
and al, 0xc0
movzx ecx, al
mov al, bl
neg ecx
sbb ecx, ecx
and ecx, 8
mov edx, ecx
or edx, 1
and al, 0xc
mov al, bl
cmove edx, ecx
mov ecx, edx
or ecx, 4
and al, 0x30
cmove ecx, edx
mov eax, ecx
or eax, 2
and bl, 3
cmove eax, ecx
or dword [esi], eax
mov al, byte [esp + 0x13]
and al, 0x2a
or byte [esi + 0xe], al
pop edi
pop esi
pop ebp
mov eax, 1
pop ebx
add esp, 0x210
ret