Function at 0x589d70
Capabilities:
Delete registry key
Query or enumerate registry value

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x5f6f6c
mov eax, dword fs:[0]
push eax
sub esp, 0x23c
mov eax, dword [0x6670f4]
xor eax, ebp
mov dword [ebp - 0x10], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
call fcn.004b4040
mov ecx, eax
test ecx, ecx
je 0x58a1a2
mov eax, dword [ecx]
call dword [eax + 0xc]
add eax, 0x10
mov dword [ebp - 0x21c], eax
mov dword [ebp - 4], 0
call fcn.004b4040
mov ecx, eax
test ecx, ecx
je 0x58a1ac
mov eax, dword [ecx]
call dword [eax + 0xc]
add eax, 0x10
mov dword [ebp - 0x220], eax
mov esi, dword [ebp + 8]
lea eax, [ebp - 0x21c]
push esi
push str._08x
push eax
mov byte [ebp - 4], 1
call fcn.004c7330
mov edi, dword [ebp + 0xc]
lea eax, [ebp - 0x220]
push edi
push str._08x
push eax
call fcn.004c7330
add esp, 0x18
mov byte [ebp - 0x211], 0
test esi, esi
je 0x589e1f
test edi, edi
jne 0x589e26
mov byte [ebp - 0x211], 1
mov edi, dword [ebp - 0x220]
xor ebx, ebx
mov dword [ebp - 0x22c], ebx
mov dword [ebp - 0x240], ebx
mov dword [ebp - 0x244], ebx
mov dword [ebp - 0x248], 0
mov byte [ebp - 4], 2
call fcn.004b4040
mov ecx, eax
test ecx, ecx
je 0x58a1a2
mov eax, dword [ecx]
call dword [eax + 0xc]
add eax, 0x10
mov dword [ebp - 0x224], eax
mov eax, dword [0x66712c]
add eax, ebx
mov byte [ebp - 4], 3
push eax
push str.SoftwareMicrosoftCTFDirectSwitchHotkeys_
lea eax, [ebp - 0x224]
push str._s_08x
push eax
call fcn.004c7330
mov esi, dword [ebp - 0x224]
lea eax, [ebp - 0x218]
add esp, 0x10
mov dword [ebp - 0x218], 0
push eax
push 0x2001f
push 0
push esi
push SysReAllocString
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExW]
test eax, eax
jne 0x58a12b
mov ebx, dword [ebp - 0x218]
push 0x80
push eax
lea eax, [ebp - 0x190]
mov dword [ebp - 0x248], ebx
push eax
call fcn.0058c8f0
push 0x80
lea eax, [ebp - 0x210]
push 0
push eax
call fcn.0058c8f0
push 0x80
lea eax, [ebp - 0x90]
push 0
push eax
call fcn.0058c8f0
push 0x80
lea eax, [ebp - 0x110]
push 0
push eax
call fcn.0058c8f0
add esp, 0x30
mov dword [ebp - 0x218], 0x80
cmp byte [ebp - 0x211], 0
lea eax, [ebp - 0x218]
push eax
je 0x589ffe
lea eax, [ebp - 0x90]
push eax
lea eax, [ebp - 0x230]
push eax
push 0
push str.CLSID
push ebx
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
test eax, eax
jne 0x589f7c
mov eax, dword [ebp - 0x230]
cmp eax, 1
je 0x589f6a
cmp eax, 2
jne 0x589f7c
cmp dword [ebp - 0x218], 0
jne 0x589f7c
xor eax, eax
mov word [ebp - 0x90], ax
lea eax, [ebp - 0x218]
mov dword [ebp - 0x218], 0x80
push eax
lea eax, [ebp - 0x110]
push eax
lea eax, [ebp - 0x234]
push eax
push 0
push str.Profile
push ebx
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
test eax, eax
jne 0x589fcf
mov eax, dword [ebp - 0x234]
cmp eax, 1
je 0x589fbd
cmp eax, 2
jne 0x589fcf
cmp dword [ebp - 0x218], 0
jne 0x589fcf
xor eax, eax
mov word [ebp - 0x110], ax
lea eax, [ebp - 0x90]
push eax
push dword [0x667130]
call fcn.005ad849
add esp, 8
test eax, eax
jne 0x58a0df
lea eax, [ebp - 0x110]
push eax
push dword [0x667134]
jmp 0x58a0b4
lea eax, [ebp - 0x190]
push eax
lea eax, [ebp - 0x238]
push eax
push 0
push str.Modifiers
push ebx
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
test eax, eax
jne 0x58a040
mov eax, dword [ebp - 0x238]
cmp eax, 1
je 0x58a02e
cmp eax, 2
jne 0x58a040
cmp dword [ebp - 0x218], 0
jne 0x58a040
xor eax, eax
mov word [ebp - 0x190], ax
lea eax, [ebp - 0x228]
mov dword [ebp - 0x228], 0x80
push eax
lea eax, [ebp - 0x210]
push eax
lea eax, [ebp - 0x23c]
push eax
push 0
push str.VirtualKey
push ebx
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
test eax, eax
jne 0x58a093
mov eax, dword [ebp - 0x23c]
cmp eax, 1
je 0x58a081
cmp eax, 2
jne 0x58a093
cmp dword [ebp - 0x228], 0
jne 0x58a093
xor eax, eax
mov word [ebp - 0x210], ax
lea eax, [ebp - 0x190]
push eax
push dword [ebp - 0x21c]
call fcn.005ad849
add esp, 8
test eax, eax
jne 0x58a0df
lea eax, [ebp - 0x210]
push eax
push edi
call fcn.005ad849
add esp, 8
test eax, eax
jne 0x58a0df
test ebx, ebx
je 0x58a0d3
push ebx
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
xor ebx, ebx
mov dword [ebp - 0x248], ebx
push esi
push SysReAllocString
call dword [sym.imp.ADVAPI32.dll_RegDeleteKeyW]
mov byte [ebp - 4], 2
add esi, 0xfffffff0
or eax, 0xffffffff
lock xadd dword [esi + 0xc], eax
dec eax
test eax, eax
jg 0x58a0fb
mov ecx, dword [esi]
push esi
mov eax, dword [ecx]
call dword [eax + 4]
test ebx, ebx
je 0x58a110
push ebx
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov dword [ebp - 0x248], 0
mov ebx, dword [ebp - 0x22c]
inc ebx
mov dword [ebp - 0x22c], ebx
cmp ebx, 0x64
jl 0x589e40
or ebx, 0xffffffff
jmp 0x58a149
or ebx, 0xffffffff
mov byte [ebp - 4], 2
add esi, 0xfffffff0
mov eax, ebx
lock xadd dword [esi + 0xc], eax
dec eax
test eax, eax
jg 0x58a149
mov ecx, dword [esi]
push esi
mov eax, dword [ecx]
call dword [eax + 4]
mov byte [ebp - 4], 0
add edi, 0xfffffff0
mov eax, ebx
lock xadd dword [edi + 0xc], eax
dec eax
test eax, eax
jg 0x58a164
mov ecx, dword [edi]
push edi
mov eax, dword [ecx]
call dword [eax + 4]
mov edx, dword [ebp - 0x21c]
mov dword [ebp - 4], 0xffffffff
add edx, 0xfffffff0
lock xadd dword [edx + 0xc], ebx
dec ebx
test ebx, ebx
jg 0x58a186
mov ecx, dword [edx]
push edx
mov eax, dword [ecx]
call dword [eax + 4]
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.0050ed5c
mov esp, ebp
pop ebp
ret
push 0x80004005
call fcn.004b3510
push 0x80004005
call fcn.004b3510
int3