Function at 0x408700
Capabilities:
Query or enumerate registry key
Query or enumerate registry value
Set registry value

Disassembly:
sub esp, 0x288
mov eax, dword [0x57f970]
xor eax, esp
mov dword [esp + 0x284], eax
mov edx, dword [esp + 0x294]
mov eax, dword [esp + 0x28c]
mov ecx, dword [esp + 0x290]
push ebx
push esi
mov esi, dword [esp + 0x2a4]
push edi
xor ebx, ebx
push 0x206
mov dword [esp + 0x34], edx
mov dword [esp + 0x2c], eax
mov eax, dword [esp + 0x2a8]
mov dword [esp + 0x30], ecx
lea edx, [esp + 0x8e]
xor ecx, ecx
push ebx
push edx
mov dword [esp + 0x40], eax
mov dword [esp + 0x2c], ebx
mov dword [esp + 0x28], ebx
xor edi, edi
mov dword [esp + 0x18], ebx
mov dword [esp + 0x20], ebx
mov word [esp + 0x94], cx
call fcn.00508a80
push 0x3e
lea ecx, [esp + 0x5a]
xor eax, eax
push ebx
push ecx
mov dword [esp + 0x30], 0x104
mov word [esp + 0x60], ax
call fcn.00508a80
add esp, 0x18
xor eax, eax
push 1
push esi
mov byte [esp + 0x40], bl
mov dword [esp + 0x41], eax
mov dword [esp + 0x45], eax
mov dword [esp + 0x49], eax
mov word [esp + 0x4d], ax
mov byte [esp + 0x4f], al
call dword [sym.imp.KERNEL32.dll_IsBadReadPtr]
test eax, eax
jne 0x4089b5
lea edx, [esp + 0x1c]
push edx
lea eax, [esp + 0x2c]
push eax
call dword [sym.imp.ole32.dll_StringFromCLSID]
lea ecx, [esp + 0x3d]
push ecx
lea edx, [esp + 0x40]
push edx
lea eax, [esp + 0x43]
push eax
lea ecx, [esp + 0x46]
push ecx
lea edx, [esp + 0x49]
push edx
lea eax, [esp + 0x4c]
push eax
push str._02X__02X__02X__02X__02X__02X
push esi
call fcn.00507d60
movzx ecx, byte [esp + 0x5d]
movzx edx, byte [esp + 0x5c]
movzx eax, byte [esp + 0x5b]
push ecx
movzx ecx, byte [esp + 0x5e]
push edx
movzx edx, byte [esp + 0x61]
push eax
movzx eax, byte [esp + 0x64]
push ecx
push edx
push eax
lea ecx, [esp + 0x80]
push str._02X_02X_02X_02X_02X_02X
push ecx
lea edx, [ebx + 0x20]
call fcn.004089e0
add esp, 0x40
lea edx, [esp + 0xc]
push edx
push 0x2001f
push ebx
push 0x55c030
push reloc.OLEAUT32.dll_SysReAllocString
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExW]
test eax, eax
jne 0x4089b5
mov edx, dword [esp + 0xc]
push ebx
push ebx
push ebx
push ebx
lea eax, [esp + 0x28]
push eax
lea ecx, [esp + 0x9c]
push ecx
push ebx
push edx
call dword [sym.imp.ADVAPI32.dll_RegEnumKeyExW]
test eax, eax
jne 0x4089aa
push ebp
mov ebp, dword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
lea ebx, [ebx]
mov edx, dword [esp + 0x10]
lea eax, [esp + 0x18]
push eax
push 0x2001f
push ebx
lea ecx, [esp + 0x98]
push ecx
inc edi
push edx
mov dword [esp + 0x3c], edi
mov dword [esp + 0x30], 0x104
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExW]
test eax, eax
jne 0x40894b
mov edi, dword [esp + 0x18]
lea eax, [esp + 0x14]
push eax
push ebx
push 0x583650
push ebx
push 0x55c0cc
push edi
mov dword [esp + 0x2c], ebx
call ebp
test eax, eax
jne 0x40893c
mov eax, dword [esp + 0x14]
cmp eax, ebx
jbe 0x40893c
add eax, 4
push eax
mov dword [esp + 0x18], eax
call fcn.00408cb2
mov ecx, dword [esp + 0x18]
push ecx
mov esi, eax
push ebx
push esi
call fcn.00508a80
add esp, 0x10
lea edx, [esp + 0x14]
push edx
push esi
push 0x583650
push ebx
push 0x55c0cc
push edi
call ebp
cmp esi, ebx
je 0x40893c
mov eax, dword [esp + 0x20]
push eax
push esi
call fcn.00507f6d
add esp, 8
test eax, eax
je 0x408972
push esi
call fcn.00408cec
add esp, 4
mov ecx, dword [esp + 0x18]
push ecx
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov edi, dword [esp + 0x28]
mov ecx, dword [esp + 0x10]
push ebx
push ebx
push ebx
push ebx
lea edx, [esp + 0x2c]
push edx
lea eax, [esp + 0xa0]
push eax
push edi
push ecx
call dword [sym.imp.ADVAPI32.dll_RegEnumKeyExW]
test eax, eax
je 0x408890
jmp 0x4089a9
mov eax, dword [esp + 0x18]
push 0x1a
lea edx, [esp + 0x50]
push edx
push 1
push ebx
push 0x55c0f0
push eax
call dword [sym.imp.ADVAPI32.dll_RegSetValueExW]
mov ecx, dword [esp + 0x18]
neg eax
sbb eax, eax
inc eax
push ecx
mov dword [esp + 0x28], eax
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
push esi
call fcn.00408cec
add esp, 4
pop ebp
mov edx, dword [esp + 0xc]
push edx
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov eax, dword [esp + 0x1c]
push eax
call dword [sym.imp.ole32.dll_CoTaskMemFree]
mov ecx, dword [esp + 0x290]
mov eax, dword [esp + 0x20]
pop edi
pop esi
pop ebx
xor ecx, esp
call fcn.005072ec
add esp, 0x288
ret 0x14