Function at 0x10018d58
Capabilities:
Get keyboard layout

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x10060eaa
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0x70
push esi
movzx eax, byte [ebp + 8]
test eax, eax
je 0x10018e59
mov eax, dword [ebp + 0x14]
mov dword [ebp - 0x4c], eax
lea eax, [ebp + 0xc]
mov dword [ebp - 0x48], eax
mov eax, dword [ebp + 0x10]
mov dword [ebp - 0x50], eax
mov eax, dword [ebp - 0x48]
movzx eax, byte [eax]
test eax, eax
je 0x10018e3f
mov eax, dword [ebp - 0x4c]
mov dword [ebp - 0x54], eax
mov eax, dword [ebp - 0x50]
mov dword [ebp - 0x58], eax
mov eax, dword [ebp - 0x54]
mov dword [ebp - 0x1c], eax
mov eax, dword [ebp - 0x58]
mov dword [ebp - 0x5c], eax
mov eax, dword [ebp - 0x1c]
mov dword [eax], 0
jmp 0x10018dce
mov eax, dword [ebp - 0x1c]
mov eax, dword [eax]
inc eax
mov ecx, dword [ebp - 0x1c]
mov dword [ecx], eax
mov eax, dword [ebp - 0x1c]
cmp dword [eax], 3
jg 0x10018e3d
mov dword [ebp - 0x18], 0xa137b189
mov dword [ebp - 0x18], 3
jmp 0x10018ded
mov eax, dword [ebp - 0x18]
dec eax
mov dword [ebp - 0x18], eax
cmp dword [ebp - 0x18], 0
jl 0x10018e0f
mov byte [ebp - 0xd], 0
movzx eax, byte [ebp - 0xd]
test eax, eax
je 0x10018e0d
push 1
push 0
push 0
push 0
call dword [sym.imp.KERNEL32.dll_GetOverlappedResult]
jmp 0x10018de6
mov dword [ebp - 0x18], 3
jmp 0x10018e1f
mov eax, dword [ebp - 0x18]
dec eax
mov dword [ebp - 0x18], eax
cmp dword [ebp - 0x18], 0
jl 0x10018e3b
mov eax, dword [ebp - 0x1c]
push dword [eax]
mov ecx, dword [ebp - 0x5c]
call fcn.1000f782
cmp dword [eax], 0
je 0x10018e39
jmp 0x10018e3b
jmp 0x10018e18
jmp 0x10018dc3
jmp 0x10018e54
push 0x18df
push 0x1ad0
push 0x259
call dword [sym.imp.KERNEL32.dll_HeapCreate]
jmp 0x100190de
mov eax, dword [ebp + 0x18]
mov dword [ebp - 0x70], eax
push 2
lea ecx, [ebp - 0x7c]
call fcn.1000f6e4
and dword [ebp - 4], 0
mov dword [ebp - 0x24], 0xdc5336de
mov dword [ebp - 0x20], 0
jmp 0x10018e84
mov eax, dword [ebp - 0x20]
inc eax
mov dword [ebp - 0x20], eax
cmp dword [ebp - 0x20], 2
jge 0x10018e9a
push dword [ebp - 0x20]
lea ecx, [ebp - 0x7c]
call fcn.1000f782
and dword [eax], 0
jmp 0x10018e7d
push 0
lea ecx, [ebp - 0x7c]
call fcn.1000f782
cmp dword [eax], 0xffffffff
jne 0x10018eb2
mov dword [ebp - 0x28], 1
jmp 0x10018eb6
and dword [ebp - 0x28], 0
push 1
lea ecx, [ebp - 0x7c]
call fcn.1000f782
mov eax, dword [eax]
cmp eax, dword [ebp - 0x28]
jle 0x10018ed5
xor eax, eax
inc eax
je 0x10018ed5
mov dword [ebp - 0x2c], 1
jmp 0x10018ed9
and dword [ebp - 0x2c], 0
push 1
lea ecx, [ebp - 0x7c]
call fcn.1000f782
mov ecx, dword [ebp - 0x2c]
cmp ecx, dword [eax]
jne 0x10018ef3
mov dword [ebp - 0x60], 1
jmp 0x10018ef7
and dword [ebp - 0x60], 0
push 1
lea ecx, [ebp - 0x7c]
call fcn.1000f782
push 0
lea ecx, [ebp - 0x7c]
call fcn.1000f782
cmp dword [eax], 0xfffffffe
jl 0x10018f19
mov dword [ebp - 0x30], 1
jmp 0x10018f1d
and dword [ebp - 0x30], 0
push 1
lea ecx, [ebp - 0x7c]
call fcn.1000f782
mov eax, dword [eax]
mov dword [ebp - 0x24], eax
mov esi, dword [ebp - 0x24]
add esi, 0x3ff14eb4
push 1
lea ecx, [ebp - 0x7c]
call fcn.1000f782
mov ecx, dword [ebp - 0x30]
add ecx, dword [eax]
cmp esi, ecx
jg 0x10018f51
mov dword [ebp - 0x64], 1
jmp 0x10018f55
and dword [ebp - 0x64], 0
push 1
lea ecx, [ebp - 0x7c]
call fcn.1000f782
push 1
lea ecx, [ebp - 0x7c]
call fcn.1000f782
mov ecx, dword [ebp - 0x24]
cmp dword [eax], ecx
je 0x10018f88
push 1
lea ecx, [ebp - 0x7c]
call fcn.1000f782
cmp dword [eax], 0
je 0x10018f88
mov dword [ebp - 0x68], 1
jmp 0x10018f8c
and dword [ebp - 0x68], 0
push 1
lea ecx, [ebp - 0x7c]
call fcn.1000f782
push 1
lea ecx, [ebp - 0x7c]
call fcn.1000f782
mov esi, eax
push 1
lea ecx, [ebp - 0x7c]
call fcn.1000f782
mov ecx, dword [esi]
cmp ecx, dword [eax]
je 0x10018fbb
mov dword [ebp - 0x34], 1
jmp 0x10018fbf
and dword [ebp - 0x34], 0
push 1
lea ecx, [ebp - 0x7c]
call fcn.1000f782
mov esi, dword [ebp - 0x34]
imul esi, dword [eax]
push 0
lea ecx, [ebp - 0x7c]
call fcn.1000f782
cmp esi, dword [eax]
jl 0x10018fe6
mov dword [ebp - 0x38], 1
jmp 0x10018fea
and dword [ebp - 0x38], 0
push 0
lea ecx, [ebp - 0x7c]
call fcn.1000f782
mov ecx, dword [ebp - 0x38]
cmp ecx, dword [eax]
je 0x10019004
mov dword [ebp - 0x3c], 1
jmp 0x10019008
and dword [ebp - 0x3c], 0
push 0
lea ecx, [ebp - 0x7c]
call fcn.1000f782
mov ecx, dword [ebp - 0x3c]
add ecx, dword [eax]
je 0x10019044
mov byte [ebp - 0xe], 0
movzx eax, byte [ebp - 0xe]
test eax, eax
je 0x1001902b
call dword [sym.imp.KERNEL32.dll_GetUserDefaultLCID]
mov byte [ebp - 0xf], 0
movzx eax, byte [ebp - 0xf]
test eax, eax
je 0x10019042
push 0x2132
call dword [sym.imp.GDI32.dll_RealizePalette]
jmp 0x100190bb
mov dword [ebp - 0x6c], 3
mov dword [ebp - 0x44], 0xfffffff7
push 1
lea ecx, [ebp - 0x7c]
call fcn.1000f782
mov ecx, dword [ebp - 0x6c]
cmp dword [eax], ecx
jl 0x1001906c
mov dword [ebp - 0x40], 1
jmp 0x10019070
and dword [ebp - 0x40], 0
mov eax, dword [ebp - 0x40]
mov dword [ebp - 0x44], eax
cmp dword [ebp - 0x44], 0
je 0x100190a4
mov byte [ebp - 0x10], 0
movzx eax, byte [ebp - 0x10]
test eax, eax
je 0x100190a2
push 0x10ff
push 0x1bbb
push 0x2124
push 0x773
call dword [sym.imp.GDI32.dll_CreateRectRgn]
jmp 0x100190bb
mov byte [ebp - 0x11], 0
movzx eax, byte [ebp - 0x11]
test eax, eax
je 0x100190bb
push 0xc37
call dword [sym.imp.USER32.dll_GetKeyboardLayout]
or dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0x7c]
call fcn.1000f766
push 0
push 0x2269
push dword [ebp - 0x70]
push 0x5f0e
call fcn.100180c8
add esp, 0x10
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop esi
mov esp, ebp
pop ebp
ret