Function at 0x408760
Capabilities:
Query or enumerate registry value

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x418d80
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0x2c
push ebx
push esi
mov esi, dword [ebp + 8]
push edi
mov edi, esi
or ecx, 0xffffffff
xor eax, eax
xor ebx, ebx
repne scasb al, byte es:[edi]
not ecx
mov dword [ebp - 0x10], esp
push ecx
mov dword [ebp - 0x14], ebx
mov dword [ebp - 0x24], ebx
call fcn.0041122f
mov edx, eax
add esp, 4
cmp edx, ebx
mov dword [ebp - 0x18], edx
je 0x408990
mov edi, esi
or ecx, 0xffffffff
xor eax, eax
push 0x5c
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
push edx
mov eax, ecx
mov esi, edi
mov edi, edx
mov dword [ebp - 4], ebx
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
and ecx, 3
rep movsb byte es:[edi], byte [esi]
call fcn.00401310
mov esi, eax
add esp, 8
test esi, esi
je 0x40898d
mov edi, dword [ebp - 0x18]
push str.HKEY_LOCAL_MACHINE
push edi
mov byte [esi], bl
call fcn.004014c0
add esp, 8
test eax, eax
jne 0x408804
mov dword [ebp + 8], 0x80000002
jmp 0x408872
push str.HKEY_CLASSES_ROOT
push edi
call fcn.004014c0
add esp, 8
test eax, eax
jne 0x40881f
mov dword [ebp + 8], 0x80000000
jmp 0x408872
push str.HKEY_CURRENT_USER
push edi
call fcn.004014c0
add esp, 8
test eax, eax
jne 0x40883a
mov dword [ebp + 8], 0x80000001
jmp 0x408872
push str.HKEY_USERS
push edi
call fcn.004014c0
add esp, 8
test eax, eax
jne 0x408855
mov dword [ebp + 8], 0x80000003
jmp 0x408872
push str.HKEY_CURRENT_CONFIG
push edi
call fcn.004014c0
add esp, 8
test eax, eax
jne 0x40898d
mov dword [ebp + 8], 0x80000005
lea edi, [esi + 1]
xor esi, esi
push 0x7c
push edi
mov dword [ebp - 0x1c], esi
call fcn.00401310
add esp, 8
test eax, eax
je 0x4088a7
lea esi, [eax + 1]
push 0x7c
push esi
mov byte [eax], 0
call fcn.00401310
add esp, 8
test eax, eax
je 0x4088a7
lea ecx, [eax + 1]
mov byte [eax], 0
mov dword [ebp - 0x1c], ecx
mov eax, dword [ebp + 8]
lea edx, [ebp - 0x14]
push edx
push 1
push 0
push edi
push eax
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExA]
test eax, eax
jne 0x40897f
test esi, esi
je 0x408975
push 0x800
mov dword [ebp + 8], eax
call fcn.0040e3e0
add esp, 4
lea ecx, [ebp - 0x20]
mov edi, eax
mov eax, dword [ebp - 0x14]
push ecx
lea edx, [ebp + 8]
push edi
push edx
push 0
push esi
push eax
mov dword [ebp - 0x20], 0x800
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExA]
test eax, eax
jne 0x408964
mov esi, dword [ebp - 0x1c]
test esi, esi
je 0x40895f
mov eax, dword [ebp + 8]
cmp eax, 4
jne 0x40893d
mov ecx, dword [edi]
lea edx, [ebp - 0x38]
push ecx
push 0x41d4b8
push edx
call dword [sym.imp.USER32.dll_wsprintfA]
lea eax, [ebp - 0x38]
push esi
push eax
call fcn.004014c0
mov ebx, eax
add esp, 0x14
neg ebx
sbb ebx, ebx
push edi
inc ebx
call fcn.0040f9ad
add esp, 4
jmp 0x40897f
cmp eax, 1
jne 0x408964
push edi
push esi
call fcn.004118a0
mov ebx, eax
add esp, 8
neg ebx
sbb ebx, ebx
push edi
neg ebx
call fcn.0040f9ad
add esp, 4
jmp 0x40897f
mov ebx, 1
push edi
call fcn.0040f9ad
add esp, 4
jmp 0x40897f
mov ebx, 1
jmp 0x40897f
mov eax, dword [ebp - 0x14]
test eax, eax
je 0x40898d
push eax
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov edx, dword [ebp - 0x18]
push edx
call fcn.0040fdd6
mov ecx, dword [ebp - 0xc]
add esp, 4
mov eax, ebx
mov dword fs:[0], ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret