Function at 0x404aa0
Capabilities:
Delete registry value
Query or enumerate registry value
Set registry value

Disassembly:
sub rsp, 0xa08
mov rax, qword [0x0042a560]
xor rax, rsp
mov qword [rsp + 0x9d0], rax
mov qword [rsp + 0x9f8], r12
mov r12, rcx
lea rcx, [rsp + 0x5b2]
xor edx, edx
mov r8d, 0x206
mov word [rsp + 0x5b0], 0
call fcn.0040e3f0
lea r8, str.Keyboard_LayoutPreload
lea rdx, [0x00421b28]
lea rcx, [rsp + 0x5b0]
call fcn.0040e620
lea r8, [rsp + 0x40]
lea rdx, [rsp + 0x5b0]
mov rcx, 0xffffffff80000001
call qword [sym.imp.ADVAPI32.dll_RegOpenKeyW]
test eax, eax
jne 0x404e7f
mov qword [rsp + 0xa00], rdi
mov qword [rsp + 0x9e8], r14
xor r14d, r14d
mov edi, r14d
mov dword [rsp + 0x4c], 1
nop
lea rcx, [rsp + 0x192]
xor edx, edx
mov r8d, 0x206
add edi, 1
mov word [rsp + 0x190], r14w
call fcn.0040e3f0
lea rcx, [rsp + 0x7c2]
xor edx, edx
mov r8d, 0x206
mov dword [rsp + 0x48], 0x104
mov word [rsp + 0x7c0], r14w
call fcn.0040e3f0
mov rcx, qword [rsp + 0x40]
lea rax, [rsp + 0x50]
lea r9, [rsp + 0x48]
mov qword [rsp + 0x38], rax
lea rax, [rsp + 0x7c0]
lea r8, [rsp + 0x190]
mov qword [rsp + 0x30], rax
lea rax, [rsp + 0x4c]
xor edx, edx
mov qword [rsp + 0x28], rax
mov qword [rsp + 0x20], r14
mov dword [rsp + 0x50], 0x104
call qword [sym.imp.ADVAPI32.dll_RegEnumValueW]
test eax, eax
jne 0x404bf2
mov rcx, qword [rsp + 0x40]
lea rdx, [rsp + 0x190]
call qword [sym.imp.ADVAPI32.dll_RegDeleteValueW]
cmp edi, 0x2710
jl 0x404b40
mov qword [rsp + 0xa20], rbp
lea rcx, [rsp + 0x3a2]
xor edx, edx
mov r8d, 0x206
mov qword [rsp + 0xa28], rsi
mov word [rsp + 0x3a0], r14w
mov qword [rsp + 0x9f0], r13
call fcn.0040e3f0
lea rcx, [rsp + 0x81]
xor edx, edx
mov r8d, 0x103
mov byte [rsp + 0x80], r14b
call fcn.0040e3f0
mov rbp, qword [r12 + 0x48]
mov r13d, 1
mov rsi, qword [rbp + 8]
cmp rsi, qword [rbp + 0x10]
jbe 0x404c5f
call fcn.0040ed00
mov qword [rsp + 0xa18], rbx
nop
nop
nop
mov rdi, qword [r12 + 0x48]
mov rbx, qword [rdi + 0x10]
cmp qword [rdi + 8], rbx
jbe 0x404c84
call fcn.0040ed00
cmp rbp, rdi
je 0x404c8e
call fcn.0040ed00
cmp rsi, rbx
je 0x404d67
cmp rsi, qword [rbp + 0x10]
jb 0x404ca2
call fcn.0040ed00
mov rbx, qword [rsi]
lea rdx, [0x00421b20]
lea rcx, [rsp + 0x3a0]
mov r8d, r13d
call fcn.0040e620
xor eax, eax
mov qword [rsp + 0x38], r14
mov qword [rsp + 0x30], r14
mov rcx, 0xffffffffffffffff
mov rdi, rbx
repne scasw ax, word [rdi]
lea r9d, [rax - 1]
mov r8, rbx
not rcx
xor edx, edx
mov dword [rsp + 0x28], r14d
lea rdi, [rcx - 1]
lea ecx, [rax + 1]
mov qword [rsp + 0x20], r14
call qword [sym.imp.KERNEL32.dll_WideCharToMultiByte]
mov qword [rsp + 0x38], r14
xor edx, edx
mov qword [rsp + 0x30], r14
mov dword [rsp + 0x28], eax
lea rax, [rsp + 0x80]
lea ecx, [rdx + 1]
mov r9d, 0xffffffff
mov r8, rbx
mov qword [rsp + 0x20], rax
call qword [sym.imp.KERNEL32.dll_WideCharToMultiByte]
mov rcx, qword [rsp + 0x40]
lea edx, [rdi + rdi]
mov r9d, 1
xor r8d, r8d
mov dword [rsp + 0x28], edx
lea rdx, [rsp + 0x3a0]
mov qword [rsp + 0x20], rbx
call qword [sym.imp.ADVAPI32.dll_RegSetValueExW]
add r13d, 1
cmp rsi, qword [rbp + 0x10]
jb 0x404d5e
call fcn.0040ed00
add rsi, 8
jmp 0x404c70
mov rcx, qword [rsp + 0x40]
call qword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov rcx, r12
call fcn.004042d0
mov rdi, qword [r12 + 0x48]
mov r14, qword [rsp + 0x9e8]
mov rbx, qword [rdi + 0x10]
mov r13, qword [rsp + 0x9f0]
cmp qword [rdi + 8], rbx
jbe 0x404d9e
call fcn.0040ed00
mov qword [rsp + 0x58], rdi
mov qword [rsp + 0x60], rbx
lea rcx, [rsp + 0x58]
mov rax, qword [rcx]
lea rdx, [rsp + 0x70]
mov qword [rdx], rax
mov rax, qword [rcx + 8]
mov qword [rdx + 8], rax
mov rbx, qword [rsp + 0x70]
mov rdi, qword [rsp + 0x78]
nop
nop
mov rsi, qword [r12 + 0x48]
mov rbp, qword [rsi + 8]
cmp rbp, qword [rsi + 0x10]
jbe 0x404de4
call fcn.0040ed00
test rbx, rbx
je 0x404dee
cmp rbx, rsi
je 0x404df3
call fcn.0040ed00
cmp rdi, rbp
je 0x404e5f
test rbx, rbx
lea rcx, [rsp + 0x70]
lea rdx, [rsp + 0x58]
mov rax, qword [rcx]
mov qword [rdx], rax
mov rax, qword [rcx + 8]
mov qword [rdx + 8], rax
jne 0x404e1a
call fcn.0040ed00
cmp rdi, qword [rbx + 8]
ja 0x404e25
call fcn.0040ed00
mov rax, qword [rsp + 0x58]
lea rsi, [rdi - 8]
cmp rsi, qword [rax + 0x10]
jb 0x404e39
call fcn.0040ed00
mov rcx, qword [rsi]
mov edx, 8
call qword [sym.imp.USER32.dll_LoadKeyboardLayoutW]
cmp rdi, qword [rbx + 8]
ja 0x404e52
call fcn.0040ed00
mov rdi, rsi
mov qword [rsp + 0x78], rsi
jmp 0x404dd0
mov rbx, qword [rsp + 0xa18]
mov rbp, qword [rsp + 0xa20]
mov rsi, qword [rsp + 0xa28]
mov rdi, qword [rsp + 0xa00]
mov r12, qword [rsp + 0x9f8]
mov rcx, qword [rsp + 0x9d0]
xor rcx, rsp
call fcn.0040e5d0
add rsp, 0xa08
ret