Function at 0x4130d0
Capabilities:
Query or enumerate registry value

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x458328
mov eax, dword fs:[0]
push eax
sub esp, 0x58
push ebx
push esi
push edi
mov eax, dword [0x47c9a0]
xor eax, ebp
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov dword [ebp - 0x34], edx
mov ebx, ecx
call fcn.00412d20
test al, al
jne 0x413118
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
mov edx, ebx
lea ecx, [ebp - 0x24]
call fcn.00416db0
push 0x46b7d0
lea eax, [ebp - 0x28]
mov dword [ebp - 4], 0
push 0x4da7d8
push eax
call fcn.004040b0
lea ecx, [ebp - 0x24]
mov byte [ebp - 4], 1
push ecx
push eax
lea eax, [ebp - 0x20]
push eax
call fcn.00403960
add esp, 0x18
mov byte [ebp - 4], 3
or edi, 0xffffffff
mov edx, dword [ebp - 0x28]
mov eax, edi
add edx, 0xfffffff0
lea ecx, [edx + 0xc]
lock xadd dword [ecx], eax
dec eax
test eax, eax
jg 0x413174
mov ecx, dword [edx]
push edx
mov eax, dword [ecx]
call dword [eax + 4]
lea eax, [ebp - 0x14]
mov dword [ebp - 0x14], 0
push eax
push 0x20019
push 0
push dword [ebp - 0x20]
push reloc.OLEAUT32.dll_SysReAllocString
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExW]
test eax, eax
jne 0x4131c4
push eax
push eax
lea eax, [ebp - 0x18]
push eax
push 0
push 0
push 0
push 0
push 0
push 0
push 0
push 0
push dword [ebp - 0x14]
call dword [sym.imp.ADVAPI32.dll_RegQueryInfoKeyW]
test eax, eax
je 0x41321b
push dword [ebp - 0x14]
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
xor bl, bl
mov byte [ebp - 4], 0
mov ecx, edi
mov edx, dword [ebp - 0x20]
add edx, 0xfffffff0
lea eax, [edx + 0xc]
lock xadd dword [eax], ecx
dec ecx
test ecx, ecx
jg 0x4131e6
mov ecx, dword [edx]
push edx
mov eax, dword [ecx]
call dword [eax + 4]
mov dword [ebp - 4], 0xffffffff
mov esi, dword [ebp - 0x24]
add esi, 0xfffffff0
lea eax, [esi + 0xc]
lock xadd dword [eax], edi
dec edi
test edi, edi
jg 0x413207
mov ecx, dword [esi]
push esi
mov edx, dword [ecx]
call dword [edx + 4]
mov al, bl
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
lea ecx, [ebp - 0x48]
call fcn.0042fb6f
mov byte [ebp - 4], 4
lea ecx, [ebp - 0x48]
mov eax, dword [ebp - 0x18]
push 0xffffffffffffffff
inc eax
push eax
call fcn.0042fccb
mov esi, dword [ebp - 0x44]
lea ecx, [ebp - 0x64]
call fcn.00411760
mov byte [ebp - 4], 5
mov eax, dword [ebp - 0x18]
mov dword [ebp - 0x1c], eax
inc eax
push eax
push 0
push esi
mov dword [ebp - 0x64], ebx
call fcn.00442490
mov edi, dword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
lea eax, [ebp - 0x1c]
add esp, 0xc
push eax
push esi
lea eax, [ebp - 0x10]
push eax
push 0
push str.Created_by_KbdEdit
push dword [ebp - 0x14]
call edi
test eax, eax
jne 0x413284
cmp dword [ebp - 0x10], 1
mov byte [ebp - 0x60], 1
je 0x413288
mov byte [ebp - 0x60], 0
mov eax, dword [ebp - 0x18]
mov dword [ebp - 0x1c], eax
inc eax
push eax
push 0
push esi
call fcn.00442490
add esp, 0xc
lea eax, [ebp - 0x1c]
push eax
push esi
lea eax, [ebp - 0x10]
push eax
push 0
push str.Layout_File
push dword [ebp - 0x14]
call edi
test eax, eax
jne 0x4132c3
cmp dword [ebp - 0x10], 1
jne 0x4132c3
push esi
lea ecx, [ebp - 0x5c]
call fcn.004046b0
mov eax, dword [ebp - 0x18]
mov dword [ebp - 0x1c], eax
inc eax
push eax
push 0
push esi
call fcn.00442490
add esp, 0xc
lea eax, [ebp - 0x1c]
push eax
push esi
lea eax, [ebp - 0x10]
push eax
push 0
push str.Layout_Text
push dword [ebp - 0x14]
call edi
test eax, eax
jne 0x4132fe
cmp dword [ebp - 0x10], 1
jne 0x4132fe
push esi
lea ecx, [ebp - 0x58]
call fcn.004046b0
mov eax, dword [ebp - 0x18]
mov dword [ebp - 0x10], eax
inc eax
push eax
push 0
push esi
call fcn.00442490
add esp, 0xc
lea eax, [ebp - 0x10]
push eax
push esi
lea eax, [ebp - 0x1c]
push eax
push 0
push str.charset
push dword [ebp - 0x14]
call edi
test eax, eax
jne 0x41333b
cmp dword [ebp - 0x1c], 4
jne 0x41333b
cmp dword [ebp - 0x10], 4
jne 0x41333b
mov eax, dword [esi]
mov dword [ebp - 0x54], eax
mov eax, dword [ebp - 0x18]
mov dword [ebp - 0x2c], eax
inc eax
push eax
push 0
push esi
call fcn.00442490
add esp, 0xc
lea eax, [ebp - 0x2c]
push eax
push esi
lea eax, [ebp - 0x30]
push eax
push 0
push str.Layout_Id
push dword [ebp - 0x14]
call edi
test eax, eax
jne 0x4133a4
cmp dword [ebp - 0x30], 1
jne 0x4133a4
push esi
lea ecx, [ebp - 0x1c]
call fcn.00404700
lea eax, [ebp - 0x10]
push eax
push 0x46b760
push dword [ebp - 0x1c]
call fcn.00441b55
movzx edx, word [ebp - 0x50]
add esp, 0xc
movzx ecx, word [ebp - 0x10]
cmp eax, 1
cmove edx, ecx
lea ecx, [ebp - 0x1c]
mov word [ebp - 0x50], dx
call fcn.004049c0
mov eax, dword [ebp - 0x18]
mov dword [ebp - 0x30], eax
inc eax
push eax
push 0
push esi
call fcn.00442490
add esp, 0xc
lea eax, [ebp - 0x30]
push eax
push esi
lea eax, [ebp - 0x2c]
push eax
push 0
push str.IME_File
push dword [ebp - 0x14]
call edi
test eax, eax
jne 0x4133df
cmp dword [ebp - 0x2c], 1
jne 0x4133df
push esi
lea ecx, [ebp - 0x4c]
call fcn.004046b0
push dword [ebp - 0x14]
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov ecx, dword [ebp - 0x34]
lea eax, [ebp - 0x64]
push eax
call fcn.004118d0
lea ecx, [ebp - 0x64]
mov bl, 1
call fcn.00411870
lea ecx, [ebp - 0x48]
mov byte [ebp - 4], 3
call fcn.0042fb86
or edi, 0xffffffff
jmp 0x4131c6